Add lightbox option in gallery block link control#64014
Conversation
|
Size Change: +223 B (+0.01%) Total Size: 1.77 MB
ℹ️ View Unchanged
|
|
Flaky tests detected in a39977f. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/10420044127
|
…update/gallery-block-image-link-control-options
…update/gallery-block-image-link-control-options
…update/gallery-block-image-link-control-options
|
@dcalhoun I might need your assistance once more with mobile unit test failure here. It ask me to update snapshots with default |
👋🏻 @akasunil thanks for the mention. It took me a little while to identify the root issue, but it relates to the lack of full support for I opened #64448 addressing the issue. Please feel free to merge it into your branch as you see fit. |
Currently, `__experimentalFeatures` is only partially implemented for the native mobile editor. Recent changes to the shared Gallery block component included a reference to this missing key via the `useSettings` Hook. Setting a default, empty value ensure exceptions are not thrown. Co-authored-by: dcalhoun <dpcalhoun@git.wordpress.org> Co-authored-by: akasunil <sunil25393@git.wordpress.org>
…update/gallery-block-image-link-control-options
…update/gallery-block-image-link-control-options
…update/gallery-block-image-link-control-options
…llery-block-image-link-control-options
|
Thank you @madhusudhand @t-hamano and @dcalhoun. I'll merge this PR. |
* Add link control as toolbar option in gallery * Add link option constant for lightbox * Add expand on lick option in link control * Add class into menugroup component for info text style * Add styles for info text in link control of popover of gallery block * Add info text for lightbox option in link control for gallery block * Add action for lightbox option in gallery block link control * Show lightbox option only when lightbox UI is enabled * Disable lightbox when other link option is selected in gallery block * Remove unneccessory constant * Conditionally apply the lightbox attribute based on defatult setting * Fix lightbox default option issue for gallery block on page load * Highlight link to option in gallery block when selected * update condition to Highlight link to option * Fix lightbox attribute issue for default state of linkTo option * fix: Set empty default `block` settings value (WordPress#64448) Currently, `__experimentalFeatures` is only partially implemented for the native mobile editor. Recent changes to the shared Gallery block component included a reference to this missing key via the `useSettings` Hook. Setting a default, empty value ensure exceptions are not thrown. Co-authored-by: dcalhoun <dpcalhoun@git.wordpress.org> Co-authored-by: akasunil <sunil25393@git.wordpress.org> * Change lightbox option lable and address other feedback * Move lightbox logic to getHrefAndDestination function * Remove highlight of LinkTo option in gallery block * Remove css for info text of lightbox option * Refactor getHrefAndDestination function to for lightbox additional attributes --------- Co-authored-by: akasunil <sunil25393@git.wordpress.org> Co-authored-by: dcalhoun <dpcalhoun@git.wordpress.org> Co-authored-by: t-hamano <wildworks@git.wordpress.org> Co-authored-by: youknowriad <youknowriad@git.wordpress.org> Co-authored-by: madhusudhand <madhudollu@git.wordpress.org>
|
"First do it, then make it. Then make it work" - this is nightmare, as only theme.json could disable this and we NEED to disable this whole pseudo-lightbox zooming as it's not even in alpha, but in Core. I would rather want to see how to block it until it's ready. THAT would be NICE. |
|
@bystrzan You can also disable lightbox from global styles of image block. see below video for more info. Dashboard-.-gutenberg-.-WordPress.webm |
What?
Expand on clickoption is missing from gallery blockLink Tocontrol.Why?
Image block link control have
Expand on clickoption which basically enables the lightbox on image. Gallery block link control have all other option from image block, ExceptExpand on clickoption.How?
Add
Expand on clickoption in gallery blockLink Tocontrol.Testing Instructions
Expand on clickoption is available under link controlExpand on clickoption function and compare it withImageblock's lightbox functionalityTesting Instructions for Keyboard
Screenshots or screencast