Repository navigation
feat(advanced-accordion): add Image Fit & Position controls for Media Accordion image - #855
Open
nahidthenh wants to merge 3 commits into
Open
nahidthenh wants to merge 3 commits into
nahidthenh wants to merge 3 commits into
Conversation
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Adds built-in Image Fit (
object-fit) and Image Position (object-position) controls for the Media Accordion image in the Advanced Accordion widget, so users can control how the tab image adapts to its container without writing custom CSS.Card: https://projects.startise.com//fbs-84095
Help Scout: 286173
Problem
The Media Accordion image was locked to
object-fit: cover(hard-coded in Pro'sadvanced-accordion.scss), so tall/wide images were always cropped to fill. The only workaround was custom CSS.Changes
SELECT: Cover · Contain · Fill · Scale Down · None (Original Size)SELECT(9 anchor points), shown when Fit is cover/contain/scale-down/noneeael_adv_accordion_type = accordion_mediaWhy this placement
The sibling media-image style controls (Height, Border Radius) already live in Lite and are inert unless the Pro Media Accordion type is active, so no Pro↔Lite bridge hook is needed. Selector specificity cleanly overrides the base SCSS
object-fit: cover(which has no!important).Backwards compatibility
Default is
cover→ existing widgets render identically. Purely additive, no regression.Testing
.eael-accordion_media-imageclass)cover)Notes
src/assets touched) → no rebuild / compiled-asset churnphp -lclean🤖 Generated with Claude Code