-
Notifications
You must be signed in to change notification settings - Fork 10.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(gatsby-transformer-sharp): Resolver API changes #27783
Merged
Merged
Changes from all commits
Commits
Show all changes
184 commits
Select commit
Hold shift + click to select a range
4814d60
Add static image plugin
ascorbic 5509d90
Parse static image files
ascorbic 6585d84
Fix package.json
ascorbic 83b0321
Better static analysis
ascorbic b430e5a
Use jsx utils package
ascorbic 96df1b8
Fix typings
ascorbic f98f56a
Typecheck fix
ascorbic e48da0a
Fix repo fields
ascorbic c11c2a4
Helpful warning
ascorbic 7f16e80
Re-enable duotone
ascorbic 146bd6e
Update readme
ascorbic f46f3e0
Improve typings
ascorbic 65d06a4
Merge branch 'master' into feat/static-image-babel
ascorbic 45a223f
wip fixed image fields for tracedSVG and webP
gillkyle 836fe1d
handle fluid images as well
gillkyle 97a5b77
Use require rather than JSON import
ascorbic 46e5807
Watch files for changes, and use relative paths
ascorbic 0d66f40
Merge branch 'add-missing-static-image-fields' into feat/static-image…
ascorbic 5e41c30
Improve types
ascorbic 0ebbf06
Add type
ascorbic 41a3cce
Merge branch 'master' into feat/static-image-babel
ascorbic 12597fa
Update yarn.lock
ascorbic 4036bb3
Add lots of comments and remove unused stuff
ascorbic b548429
Create and watch our own nodes
ascorbic 3242599
Update readme
ascorbic 935e91a
Merge remote-tracking branch 'origin/master' into feat/static-image-b…
ascorbic 70616e2
Update deps
ascorbic 67ea9ef
Only watch in develop
ascorbic 4f68363
Rename to gatsby-plugin-image
ascorbic f5dc9f7
Rearrange, ready for merger
ascorbic 13e1ca8
Import @wardpeet 's gatsby-image-netxtgen
ascorbic 6569d06
Update typings and further merge packages
ascorbic f3598f0
Build babel plugin
ascorbic 94e4b7e
More merging
ascorbic 7635d59
Add server/browser static image variants
ascorbic 5060df6
include webpack changes
812ab51
change error message to use gatsby-plugin-image
80c9155
Merge remote-tracking branch 'origin/master' into feat/static-image-b…
ascorbic 5f1aa5a
Fix compat compilation
ascorbic 4f8824e
Fix SSR
ascorbic 5155374
Merge readmes
ascorbic e93480f
Build browser bundle
ascorbic e581396
Export correctly from browser entry point
ascorbic f6e1156
Remove hook import
ascorbic 24ffaa2
Apply suggestions from code review
ascorbic ff4d0a9
Merge branch 'feat/static-image-babel' of github.com:gatsbyjs/gatsby …
ascorbic ea4bf65
Changes from review
ascorbic 2e5912f
add path prefix, static image do e2e test
aee3dc9
Add prepare script
ascorbic 9ecea93
Apply README suggestions from code review
ascorbic 284d34c
Fix image component in e2e test
ascorbic 8badae4
Better error messages
ascorbic 121e344
Merge branch 'feat/static-image-babel' of github.com:gatsbyjs/gatsby …
ascorbic 618bd75
Prefer svg over base64. Warn for unsupported art direction
ascorbic e2d84d8
Fix type
ascorbic f84853f
Use "layout" instead of fixed/fluid
ascorbic 31b8594
add static images to production runtime site
cc7c571
add path prefix tests
5426dcf
Reorg types. Change private prop name
ascorbic a3305a9
Merge branch 'feat/static-image-babel' of github.com:gatsbyjs/gatsby …
ascorbic a80fa20
initial gatsby static image tests
3f15544
add test suite to circle ci
d891b8d
add test suite to circle ci
0a19484
add test suite to circle ci
c97041c
remove unused imports, use valid fluid setting
1c2c89e
Use new fluid props syntax
ascorbic 127840e
Better var name
ascorbic 8e93857
update tests
8125d34
remove tests that no longer match the expected DOM
a76ea81
Merge branch 'feat/static-image-babel' of github.com:gatsbyjs/gatsby …
ascorbic 5aa7ec6
Merge remote-tracking branch 'origin/master' into feat/static-image-b…
ascorbic f999a45
More compat-fixes
ascorbic 81e7ee7
Change classname to match old version
ascorbic df2e14b
Compat improvements
ascorbic a4d991e
Update tests to match new classname
ascorbic 2a8d141
Merge remote-tracking branch 'upstream/master' into feat/static-image…
6d05bc1
Merge remote-tracking branch 'origin/master' into feat/static-image-b…
ascorbic 46f33b7
v0.0.1
ascorbic b2620c7
Add readme caveat
ascorbic 870ceff
Update version in packages
ascorbic 5db8d30
Remove forcewrapper
ascorbic c095f4b
wip
ascorbic 02e6495
have static image use gatsbyImageProps function
4de8330
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic 683b57a
Upgrade sharp
ascorbic 559b571
Fix static image type
ascorbic d52c4a0
First steps to update API
ascorbic 13e3423
Add descriptions
ascorbic 1d440ce
Merge remote-tracking branch 'origin/master' into feat/static-image-b…
ascorbic 03e894a
Merge branch 'feat/static-image-babel' into feat/image-resolvers
ascorbic 60d554f
TypeScript fixes
ascorbic d5b1f1a
Compile ts
ascorbic f78bb88
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic 6a0c0b0
Add @gillkyle's calculateImageSizes util funciton
ascorbic 86f9af0
remove unused file
9e1f556
unbump sharp until sharp PR is merged
ffddd6f
comment out import
70cdb59
update snapshots
c1558f2
change JSX to take image prop
3127a0a
static image uses new image props
4a31afb
Rename all the things
ascorbic 4b57129
Turns out it wasn't all of them
ascorbic a1d967d
Update schema
ascorbic b601e9d
fix intrinsic issue 1px problem, still doesn't seem to reach the corr…
a5ba190
Fix layout
ascorbic 1e1dba6
Update readme
ascorbic e1b3b62
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic edb5a7a
Fix dep
ascorbic 8449710
Shouldn;t be in this
ascorbic 1888a2f
Fix sharp function name
ascorbic 8568329
Version
ascorbic 483adb8
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic 6abf47d
What is this snapshot out of date?
ascorbic f30d823
Add a helper funciton
ascorbic abd9052
Make backgroundColor work
ascorbic b0e1a39
update layout for images
dc905ac
no longer using base64 so remove that test
6307d9b
placeholder not getting passed from static, so this is still busted
cde4d27
Fix passing of props
ascorbic 267af4d
Merge branch 'feat/image-resolvers' of github.com:gatsbyjs/gatsby int…
ascorbic a02fadb
Add TODO comments
ascorbic 03e26e8
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic 2a78089
Merge remote-tracking branch 'origin/master' into feat/image-resolvers
ascorbic 087d792
Export batch queue function
ascorbic 48ffac8
Handle the default sizes elsewhere, as it depends on layout
ascorbic 99d5c77
feat(gatsby-plugin-sharp): create image sizes helper (#27554)
gillkyle dd903e7
Use passed-in reporter
ascorbic 6f96517
Use shared function to handle fit calculation
ascorbic b048019
Return presentationW/H and aspect ratio from sizes function
ascorbic 0924270
Round sizes
ascorbic 050450d
Use new resizing functions
ascorbic b49e8c8
default layout wasn't passed to createImageSizes
0809801
add fixed width default and round calculated height
f65ed05
reversed logic for aspect ratio calculations
gillkyle 2a08433
Merge remote-tracking branch 'origin' into feat/image-resolvers
ascorbic ee0f51a
Correct description for outputPixelDensities resolver
ascorbic 22f4e8a
Remove log
ascorbic 9523fc3
Handle null image in SSR
ascorbic d6c0b3b
Version fix
ascorbic 59ee72c
fix(gatsby-plugin-utils): skip libcheck during typegen
ascorbic 046a614
Remove unused func
ascorbic 35df109
Remove dominantColor from fixed and fluid
ascorbic 0108c2c
sizing code for KG to drive refactor
130ba02
remove isSmaller
gillkyle 8fbca1d
fix tests
gillkyle 3c264eb
Merge remote-tracking branch 'origin' into feat/image-resolvers
ascorbic 838b01a
Fix sizes and srcset generation
ascorbic 781af53
Merge branch 'feat/image-resolvers' of github.com:gatsbyjs/gatsby int…
ascorbic 92768e1
Add object-fit
ascorbic 72645ad
rename placeholder function for consistency
2f73b31
Update readme
ascorbic d7d8617
Merge branch 'feat/image-resolvers' of github.com:gatsbyjs/gatsby int…
ascorbic abda06a
fix path prefix images
a086ef7
Merge branch 'feat/image-resolvers' of https://github.com/gatsbyjs/ga…
2a9b0fe
fix sizing when larger image dimensions are requested, fix warning as…
f3e114a
rename file to match constrained naming
b5c546a
Changes from review
ascorbic 89764a8
Merge remote-tracking branch 'origin' into feat/image-resolvers
ascorbic 950b131
Add alpha warning
ascorbic 2568f00
Change from review
ascorbic 43bb48b
fix placeholder opacity
fb616c3
fix placeholder bug
3508808
only change placeholder size for background color div
d66f3b2
tests: Add visual regression tests (#27619)
ascorbic 9c3b7cb
Fix e2e test
ascorbic d0ff2c8
Merge branch 'feat/image-resolvers' of github.com:gatsbyjs/gatsby int…
ascorbic f9e36bb
Merge remote-tracking branch 'origin' into feat/image-resolvers
ascorbic 4cfc7c3
Merge remote-tracking branch 'origin' into feat/image-resolvers
ascorbic de6c6a1
dont flash placeholder image when removing opacity
gillkyle b0c27ec
Merge branch 'feat/image-resolvers' of github.com:gatsbyjs/gatsby int…
gillkyle d8675ce
Fix dependency
ascorbic fd702cf
Continue moving options into options objects
ascorbic 8bddbf7
Merge remote-tracking branch 'origin' into resolver-api-changes
ascorbic 9232ba9
Update API
ascorbic ee1cd08
Default to blurred
ascorbic 61b0f95
Fix test
ascorbic e00256f
Fix default
ascorbic eff996b
Change from review
ascorbic 5ae0918
Updates to fixed sizing
ascorbic abe9a35
Update snapshots
ascorbic 4871108
Merge remote-tracking branch 'origin' into resolver-api-changes
ascorbic 91b4838
fix readme, clean up unused variable
23afa88
fix lint
248abf3
weird readme lint issue
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file modified
BIN
+404 Bytes
(100%)
...s/image.js/GatsbyImage -- fixed image -- renders correctly on 1027x768.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+414 Bytes
(100%)
...ots/image.js/GatsbyImage -- fixed image -- renders correctly on ipad-2.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+936 Bytes
(100%)
...s/image.js/GatsbyImage -- fixed image -- renders correctly on iphone-6.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-1.61 KB
(100%)
...xed image smaller than requested size -- renders correctly on 1027x768.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-1.61 KB
(100%)
...fixed image smaller than requested size -- renders correctly on ipad-2.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-3.05 KB
(99%)
...xed image smaller than requested size -- renders correctly on iphone-6.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-3.77 KB
(90%)
...s/image.js/StaticImage -- fixed image -- renders correctly on 1027x768.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-3.77 KB
(90%)
...ots/image.js/StaticImage -- fixed image -- renders correctly on ipad-2.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-3.76 KB
(90%)
...s/image.js/StaticImage -- fixed image -- renders correctly on iphone-6.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-4.35 KB
(99%)
...xed image smaller than requested size -- renders correctly on 1027x768.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-4.35 KB
(99%)
...fixed image smaller than requested size -- renders correctly on ipad-2.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-290 Bytes
(100%)
...xed image smaller than requested size -- renders correctly on iphone-6.snap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤦♂️