Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Statamic Responsive Images Laravel Package

spatie/statamic-responsive-images

Statamic addon that generates responsive images and variants on demand. Includes a “responsive” fieldtype for art-directed images with configurable breakpoints, ratios, and fit options, plus an Antlers tag to render the correct sources for each breakpoint.

View on GitHub
Deep Wiki
Context7
v5.2.2

What's Changed

New Contributors

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v5.2.1...v5.2.2

v5.2.0
  • Add a way to configure the dimension calculator threshold

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v5.1.1...v5.2.0

v5.1.1
  • Also dispatch a generate job for the default src when generating images

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v5.1.0...v5.1.1

v5.0.1

What's Changed

New Contributors

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v5.0.0...v5.0.1

v4.1.1

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v4.1.0...v4.1.1

v4.1.0

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v4.0.3...v4.1.0

v4.0.3

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v4.0.2...v4.0.3

v4.0.2

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v4.0.1...v4.0.2

v4.0.1

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v4.0.0...v4.0.1

v4.0.0

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v3.1.3...v4.0.0

v3.1.3

What's Changed

  • Rethrow Unable to read file exception for placeholder generation in SSG context by @ncla in https://github.com/spatie/statamic-responsive-images/pull/209. Developers must be aware of failed placeholder generation when running SSG due to a SSG bug. Workaround and discussion about it can be found here, alternatively just disable placeholder generation.

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v3.1.2...v3.1.3

v3.1.2

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v3.1.1...v3.1.2

v3.1.1

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v3.1.0...v3.1.1

v3.1.0

What's Changed

GraphQL improvements by @ncla in https://github.com/spatie/statamic-responsive-images/pull/203

  • Support way more arguments in responsive field, add all of them for each breakpoint
  • Accept fieldtype data into GraphQL responsive field

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v3.0.0...v3.1.0

v3.0.0

This is a breaking change release, as such please see UPGRADE.md for instructions on how to upgrade from 2.x version to 3.x.

What's Changed

  • Extensible dimension calculators by @ncla in https://github.com/spatie/statamic-responsive-images/pull/193

    • Developers now can customize the amount of images that get generated and their exact dimensions through a custom DimensionCalculator that developers bind in ServiceProvider. Calculations can be done for each breakpoint and source, and receive Breakpoint / Source in the calculation methods, which allows to access breakpoint parameters, original asset and more. For motivation and examples of this, please see the PR and the original issue associated with it.
  • Fix max widths config value or glide width param not being respected in some cases

  • Fix floating numbers being output for width and height values for Glide endpoint, they are now rounded integers

  • Placeholder now can be toggled per breakpoint

  • <img> tag src will now go through Glide instead of pointing to the original asset file, due to DimensionCalculators ability to return specific widths and heights for <img> tag

  • Empty media attributes will no longer be outputted

  • Properties have been renamed to be more descriptive:

    • value to minWidth
    • unit to widthUnit
  • Add mimeType property to explicitly help browsers determine what images does the <source> contain

  • Housekeeping: add additional tests for dimension calculator and GraphQL

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.15.2...v3.0.0

v2.15.2

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.15.1...v2.15.2

v2.15.1

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.15.0...v2.15.1

v2.15.0

What's Changed

New Contributors

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.14.5...v2.15.0

v2.14.5

What's Changed

New Contributors

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.14.4...v2.14.5

v2.14.4
v2.14.3

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.14.2...v2.14.3

v2.14.2

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.14.1...v2.14.2

v2.14.1

What's Changed

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.14.0...v2.14.1

v2.14.0

What's Changed

New Contributors

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.13.1...v2.14.0

v2.12.4

What's changed

  • Try another fix for alt tags
  • The responsive blade directive can now handle augmented fieldtype data (array)
  • Fix an exception with OrderedQueryBuilder

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.12.3...v2.12.4

v2.12.3
v2.12.2
v2.12.1
  • Fix an issue where images could get upscaled #134

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.12.0...v2.12.1

v2.12.0
v2.11.2
v2.11.1
v2.11.0
  • Fix Statamic 3.3 support
  • Drop support for 3.2 and 3.1

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.10.1...v2.11.0

v2.10.1
  • Fix the fieldtype not saving values correctly

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.10.0...v2.10.1

v2.9.3
v2.10.0
  • Add support for Statamic 3.3
  • Drop support for Statamic 3.1

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.9.3...v2.10.0

v2.9.2
  • Fix default breakpoint ratio not working

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.9.1...v2.9.2

v2.9.1
  • Fix an issue with asset height not being calculated correctly

Full Changelog: https://github.com/spatie/statamic-responsive-images/compare/v2.9.0...v2.9.1

v2.9.0
2.8.5
2.8.4
2.8.3
2.8.2
2.8.1
2.8.0

What's new

  • Allow Statamic 3.2
2.7.1

What's fixed

  • We now throw our own exception with more information when a corrupt image is being handled (#71)
2.7.0

What's new

  • Added GraphQL support (docs)
2.6.0

What's new

  • We now use ResizeObserver instead of an inline script to set the sizes attribute on the images
2.5.5

What's fixed

  • Prevent the fieldtype from generating too many breakpoints (#66)
2.5.4

What's fixed

  • Assets can be retrieved from an augmented asset's array values
2.5.3

What's fixed

  • Fixed an issue when using the fieldtype inside a replicator or Bard set - #51
2.5.2

What's fixed

  • Fixed an issue with invalid asset exception - #58
2.5.1

What's fixed

  • Fixed an issue where the placeholder ratio was not always correct
2.5.0

What's fixed

  • Fixed an issue with images not being output
  • Wrapped the components in Statamic.booting to prevent loading issues
  • Reworked how assets are generated on upload & with the command which should result in them being used again instead of regenerating when visiting the page.

What's new

  • Added a config option to disable image generation on upload
2.4.4

What's fixed

  • Cache placeholder generation
2.4.3

What's fixed

  • The breakpoint no longer forces a relative URL
2.4.2

What's fixed

  • Fix config registration
2.4.1

What's fixed

  • Fix assets not being published
2.4.0

What's new

  • The generate image job is now configurable
2.3.0

What's new

  • The placeholder is now available in the view
  • The global config now contains global webp and placeholder config settings

What's fixed

  • Gifs are now treated the same as SVGs, they don't generate variants
  • Fixed the Blade directive
2.2.1

What's fixed

  • Fixed an issue where passing a null ratio would break
2.2.0

What's new

  • Added a fieldtype that allows full art direction.
2.1.1
  • [new] Responsive images now supports true Art direction with the possibility to add a different src for each breakpoint.
2.0.1
  • [fix] Fix the order of picture sources
2.0.0

Breaking

  • The \Spatie\ResponsiveImages\Responsive class has been renamed to \Spatie\ResponsiveImages\ResponsiveTag
  • The views have been changed to Blade views instead of Antlers views.

Changes

  • [new] Added the possibility for Art Direction [#32]
1.8.0
  • [new] Added a config option for a global max width on generated images
1.6.0
  • [new] Added a Responsive::render() function
  • [new] Added a [@responsive](https://github.com/responsive) Blade directive
  • [new] You can now pass an asset url as parameter instead of needing to pass an asset object
1.5.1
  • [fix] Register the command
1.5.0
  • [new] Adds a generate command to generate responsive images without clearing the glide cache
1.4.0
  • [new] Share the asset data with the views
1.3.2
  • [fix] Improve exception handling in command
1.3.1
  • [fix] Fix an issue with small images
  • [fix] Make sure the placeholder respects the image ratio
1.3.0
  • [new] Added GenerateImageJob queue specification via config
1.2.3
  • [fix] Fix publishing & loading of the views
1.2.2
  • [fix] Fix compatibility with latest Statamic Beta
1.2.1
  • [fix] Fix a bug where webp images weren't being shown
1.2.0
  • [new] Responsive tag now accepts a ratio parameter
  • [new] Glide parameters are passed through using a glide: prefix
1.1.0
  • [new] Now generates responsive versions after asset upload
  • [new] Added a command to regenerate responsive image versions
1.0.0
  • initial release
What's
  • Fix the field not being localizable
1.7.1
  • [fix] The max width parameter now generates an image correctly when only 1 size was calculated [#27]
1.7.0
  • [new] Allow non-integer ratios
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport