Bound the configurator basket panel and fix an invalid overflow value - #223
Draft
Jamesr51d wants to merge 1 commit into
Draft
Bound the configurator basket panel and fix an invalid overflow value#223Jamesr51d wants to merge 1 commit into
Jamesr51d wants to merge 1 commit into
Conversation
The selected-properties panel is positioned at bottom:100% of the footer and grows upward, and .g-basket__status is positioned relative to that growing panel. So with many properties selected the panel covered the whole option list and pushed its own collapse tab off the top of the viewport, leaving no way to close it again. The open state now bounds the content box with max-height:30vh and overflow-y:auto, so the panel stops growing and the tab stops being pushed away. It previously said overflow:none, which is not a valid CSS value and was discarded by the parser, so the panel had no scroll container at all. That is the only occurrence of an invalid overflow value in the pattern library. Viewport units are safe here because the enclosing layout is fixed at 100vh and never body scrolls, the same reason the search dropdown uses max-height:50vh. box-sizing is set because there is no global border-box reset, so without it the bound would exclude the padding. Also takes the basket arrow to 18x12, matching the weight of the filter arrows above it. The configurator pricing journey review asked for that on 22 July 2026 and until now it had only ever been patched into the configurator's own stylesheet, so anyone compiling this pattern library still got the smaller arrow. Reported as 51Degrees/configurator#68. The configurator carries compiled CSS rather than this sass, so the same fix was made there in 51Degrees/configurator#89 to fix the running application. This change is that fix at the source, so the two cannot drift.
Contributor
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.
Two changes to
03-groups/02-conf-basket/00-basket.scss, the configurator'sselected-properties panel.
Reported as 51Degrees/configurator#68.
The problem
The panel is
position:absoluteatbottom:100%of the footer, so it isanchored to the footer's top edge and grows upward with nothing bounding it. Its
own collapse tab,
.g-basket__status, is absolutely positioned relative to thatgrowing panel. Every extra row of property pills therefore pushes the tab
further up, and once the panel is taller than the viewport the tab is off the top
of the screen. That is the reported symptom, the user being unable to collapse
the panel again.
The open state also set
overflow:none. That is not a valid CSS value, so theparser discards the declaration and the panel has no scroll container at all.
Grepping the whole pattern library, this was the only occurrence.
Separately, the arrow on the collapse tab is still
14x9. The configuratorpricing journey review of 22 July 2026 asked for
18x12to match the weight ofthe filter arrows above it, but that was only ever patched into the
configurator's own stylesheet, so anyone compiling this pattern library still got
the small one.
The fix
The open state bounds the content box with
max-height:30vhandoverflow-y:auto, which fixes both symptoms at once. The panel stops growing,and because the tab is positioned relative to the panel it stops being pushed
away.
Viewport units are safe here because the enclosing layout is fixed at
100vhandnever body scrolls, which is the same reason
02-components/03-main/04-search.scssalready uses
max-height: 50vh.box-sizing:border-boxis set because there isno global border-box reset, so without it the bound would exclude the
1remofpadding.
overscroll-behavior:containstops scrolling past the end of the panelfrom chaining into the option list behind it.
The arrow goes to
18x12.Testing
Compiled the partial with sass 1.83.4, the version this project pins, against the
abstracts and base mixins it depends on. The output is:
which is byte for byte the rule already verified in a running configurator. No
overflow: noneremains in the compiled output. The only warnings are theproject's existing
@importdeprecation notices, unrelated to this change.Behaviour was measured in the configurator against the built application, at
375x812 with 53 properties selected:
Rollout
Scoped to the configurator.
.g-basket*is only used by the configuratorstylesheet,
conf-main.scssbeing the one entry point that globs03-groups/*conf*, so the docs and examples stylesheets are unaffected.Worth knowing about the relationship between the two repositories, because it is
the reason this PR exists. The configurator does not consume this sass. It
carries a compiled copy of
conf-main.cssfor Storybook plus a separate, oldercompiled
main.cssthat the application actually imports, and the same fix wasmade there in 51Degrees/configurator#89 so the running application is fixed now.
This change is that fix at the source, so the two cannot drift.
That split is itself a problem worth solving properly. The configurator's
main.csshas accumulated 69 selectors that exist in neither this sass nor itsown copy of
conf-main.css, so it can no longer be regenerated from the patternlibrary without losing them. Bringing the configurator's styling source into sass
is being tracked separately.
🤖 Generated with Claude Code