spectrum-css
spectrum-css copied to clipboard
[Swatch|Swatch Group] First Swatch selected interacts poorly with `display: inline-flex`
Description
display: inline-flex sometimes adds the trailing "space", but selecting the first Swatch in the Swatch Group causes the "space" to collapse.
Steps to reproduce
- Go to https://opensource.adobe.com/spectrum-css/swatchgroup.html#density-compact
- Add a
<div>with content AFTER the.spectrum-SwatchGroupelement - Remove the width of the
.spectrum-SwatchGroupelement, so the Swatches all display on a single row. - Add
.is-selectedto the FIRST Swatch element. - See the "space" between the Group and the
<div>change.
Expected behavior
Default styles are not effected by the selection of Swatches in the group.
Screenshots
With selection:

Without selection:

synced to jira: https://jira.corp.adobe.com/browse/CSS-202