Skip to content
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!: spectrum 2 #2352

Draft
wants to merge 57 commits into
base: main
Choose a base branch
from
Draft

feat!: spectrum 2 #2352

wants to merge 57 commits into from

Conversation

pfulton
Copy link
Collaborator

@pfulton pfulton commented Dec 8, 2023

🚨 DO NOT MERGE 🚨

Spectrum 2 migration branch

s2-gitflow

To-do:

  • Merge custom Spectrum & Express custom properties
  • Merge custom dark and darkest custom properties
  • Take in latest release of @adobe/spectrum-tokens

Copy link
Contributor

github-actions bot commented Dec 8, 2023

🚀 Deployed on https://pr-2352--spectrum-css.netlify.app

Copy link
Contributor

github-actions bot commented Dec 8, 2023

File metrics

Summary

Total size: 4.23 MB*
Total change (Δ): ⬇ 254.18 KB (-5.54%)

Table reports on changes to a package's main file. Other changes can be found in the collapsed Details section below.

Package Size Δ
actionbutton 41.64 KB ⬆ 0.48 KB
actiongroup 5.65 KB ⬇ 2.75 KB
button 30.18 KB ⬇ 53.16 KB
buttongroup 1.39 KB ⬇ 0.24 KB
card 21.17 KB ⬆ 0.34 KB
checkbox 24.61 KB ⬆ 0.16 KB
closebutton 11.16 KB ⬇ 4.76 KB
dial 11.78 KB ⬇ < 0.01 KB
fieldlabel 6.31 KB ⬇ 0.26 KB
modal 5.40 KB ⬇ < 0.01 KB
opacitycheckerboard 1.68 KB ⬆ 0.18 KB
page 0.72 KB ⬇ < 0.01 KB
progressbar 10.88 KB ⬇ 0.06 KB
slider 32.79 KB ⬇ 0.01 KB
splitview 11.26 KB ⬇ < 0.01 KB
switch 25.27 KB ⬆ 0.70 KB
table 47.02 KB ⬇ < 0.01 KB
tokens 205.74 KB ⬆ 6.53 KB

Details

actionbutton

File Head Base Δ
index-base.css 30.45 KB 29.99 KB ⬆ 0.48 KB (1.56%)
index-theme.css 11.77 KB 11.77 KB -
index-vars.css 41.64 KB 41.17 KB ⬆ 0.48 KB (1.13%)
index.css 41.64 KB 41.17 KB ⬆ 0.48 KB (1.13%)
metadata.json 17.66 KB 17.44 KB ⬆ 0.23 KB (1.27%)
themes/express.css 9.01 KB 9.01 KB -
themes/spectrum.css 9.20 KB 9.20 KB -

actiongroup

File Head Base Δ
index-base.css 5.65 KB 7.91 KB ⬇ 2.26 KB (-28.59%)
index-theme.css 0.59 KB 1.07 KB ⬇ 0.50 KB (-45.60%)
index-vars.css 5.65 KB 8.39 KB ⬇ 2.75 KB (-32.73%)
index.css 5.65 KB 8.39 KB ⬇ 2.75 KB (-32.73%)
metadata.json 2.61 KB 3.42 KB ⬇ 0.82 KB (-23.52%)
themes/express.css 0.59 KB 0.90 KB ⬇ 0.30 KB (-33.63%)
themes/spectrum.css 0.59 KB 0.79 KB ⬇ 0.20 KB (-24.91%)

button

File Head Base Δ
index-base.css 30.18 KB 53.08 KB ⬇ 22.89 KB (-43.13%)
index-vars.css 30.18 KB 83.35 KB ⬇ 53.16 KB (-63.78%)
index.css 30.18 KB 83.35 KB ⬇ 53.16 KB (-63.78%)
metadata.json 11.52 KB 33.56 KB ⬇ 22.04 KB (-65.68%)
index-theme.css - 30.85 KB 🚨 deleted, moved, or renamed
themes/express.css - 29.64 KB 🚨 deleted, moved, or renamed
themes/spectrum.css - 29.71 KB 🚨 deleted, moved, or renamed

buttongroup

File Head Base Δ
index-base.css 1.39 KB 1.62 KB ⬇ 0.24 KB (-14.43%)
index-vars.css 1.39 KB 1.62 KB ⬇ 0.24 KB (-14.43%)
index.css 1.39 KB 1.62 KB ⬇ 0.24 KB (-14.43%)
metadata.json 0.53 KB 0.63 KB ⬇ 0.10 KB (-15.66%)

card

File Head Base Δ
index-base.css 21.17 KB 20.84 KB ⬆ 0.34 KB (1.58%)
index-vars.css 21.17 KB 20.84 KB ⬆ 0.34 KB (1.58%)
index.css 21.17 KB 20.84 KB ⬆ 0.34 KB (1.58%)
metadata.json 9.94 KB 9.73 KB ⬆ 0.22 KB (2.18%)

checkbox

File Head Base Δ
index-base.css 23.98 KB 23.83 KB ⬆ 0.16 KB (0.64%)
index-theme.css 1.21 KB 1.21 KB -
index-vars.css 24.61 KB 24.46 KB ⬆ 0.16 KB (0.63%)
index.css 24.61 KB 24.46 KB ⬆ 0.16 KB (0.63%)
metadata.json 13.27 KB 12.92 KB ⬆ 0.36 KB (2.71%)
themes/express.css 0.92 KB 0.92 KB -
themes/spectrum.css 0.91 KB 0.91 KB -

closebutton

File Head Base Δ
index-base.css 11.16 KB 15.27 KB ⬇ 4.11 KB (-26.92%)
index-theme.css 0.93 KB 1.23 KB ⬇ 0.33 KB (-26.15%)
index-vars.css 11.16 KB 15.92 KB ⬇ 4.76 KB (-29.91%)
index.css 11.16 KB 15.92 KB ⬇ 4.76 KB (-29.91%)
metadata.json 4.78 KB 8.11 KB ⬇ 3.33 KB (-41.09%)
themes/express.css 0.93 KB 0.93 KB -
themes/spectrum.css 0.92 KB 0.92 KB -

dial

File Head Base Δ
index-base.css 11.78 KB 11.78 KB ⬇ < 0.01 KB (-0.01%)
index-vars.css 11.78 KB 11.78 KB ⬇ < 0.01 KB (-0.01%)
index.css 11.78 KB 11.78 KB ⬇ < 0.01 KB (-0.01%)
metadata.json 5.23 KB 5.24 KB ⬇ < 0.01 KB (-0.02%)

fieldlabel

File Head Base Δ
index-base.css 6.31 KB 6.56 KB ⬇ 0.26 KB (-3.90%)
index-vars.css 6.31 KB 6.56 KB ⬇ 0.26 KB (-3.90%)
index.css 6.31 KB 6.56 KB ⬇ 0.26 KB (-3.90%)
metadata.json 3.59 KB 3.41 KB ⬆ 0.18 KB (5.27%)

modal

File Head Base Δ
index-base.css 5.40 KB 5.40 KB ⬇ < 0.01 KB (-0.02%)
index-vars.css 5.40 KB 5.40 KB ⬇ < 0.01 KB (-0.02%)
index.css 5.40 KB 5.40 KB ⬇ < 0.01 KB (-0.02%)
metadata.json 1.82 KB 1.82 KB ⬇ < 0.01 KB (-0.05%)

opacitycheckerboard

File Head Base Δ
index-base.css 1.68 KB 1.51 KB ⬆ 0.18 KB (11.54%)
index-vars.css 1.68 KB 1.51 KB ⬆ 0.18 KB (11.54%)
index.css 1.68 KB 1.51 KB ⬆ 0.18 KB (11.54%)
metadata.json 0.73 KB 0.61 KB ⬆ 0.12 KB (18.86%)

page

File Head Base Δ
index-base.css 0.72 KB 0.72 KB ⬇ < 0.01 KB (-0.14%)
index-vars.css 0.72 KB 0.72 KB ⬇ < 0.01 KB (-0.14%)
index.css 0.72 KB 0.72 KB ⬇ < 0.01 KB (-0.14%)
metadata.json 0.15 KB 0.15 KB ⬇ < 0.01 KB (-0.68%)

progressbar

File Head Base Δ
index-base.css 10.88 KB 10.93 KB ⬇ 0.06 KB (-0.49%)
index-vars.css 10.88 KB 10.93 KB ⬇ 0.06 KB (-0.49%)
index.css 10.88 KB 10.93 KB ⬇ 0.06 KB (-0.49%)
metadata.json 6.01 KB 5.93 KB ⬆ 0.08 KB (1.38%)

slider

File Head Base Δ
index-base.css 30.45 KB 30.45 KB ⬇ < 0.01 KB (-0.01%)
index-theme.css 2.92 KB 2.92 KB ⬇ < 0.01 KB (-0.10%)
index-vars.css 32.79 KB 32.79 KB ⬇ 0.01 KB (-0.01%)
index.css 32.79 KB 32.79 KB ⬇ 0.01 KB (-0.01%)
metadata.json 14.12 KB 14.12 KB ⬇ < 0.01 KB (-0.01%)
themes/express.css 1.76 KB 1.76 KB -
themes/spectrum.css 1.73 KB 1.73 KB ⬇ < 0.01 KB (-0.17%)

splitview

File Head Base Δ
index-base.css 11.26 KB 11.26 KB ⬇ < 0.01 KB (-0.01%)
index-vars.css 11.26 KB 11.26 KB ⬇ < 0.01 KB (-0.01%)
index.css 11.26 KB 11.26 KB ⬇ < 0.01 KB (-0.01%)
metadata.json 4.58 KB 4.58 KB ⬇ < 0.01 KB (-0.02%)

switch

File Head Base Δ
index-base.css 25.27 KB 23.23 KB ⬆ 2.04 KB (8.79%)
index-vars.css 25.27 KB 24.59 KB ⬆ 0.70 KB (2.77%)
index.css 25.27 KB 24.59 KB ⬆ 0.70 KB (2.77%)
metadata.json 12.60 KB 12.95 KB ⬇ 0.35 KB (-2.63%)
index-theme.css - 1.94 KB 🚨 deleted, moved, or renamed
themes/express.css - 1.26 KB 🚨 deleted, moved, or renamed
themes/spectrum.css - 1.26 KB 🚨 deleted, moved, or renamed

table

File Head Base Δ
index-base.css 47.02 KB 47.02 KB ⬇ < 0.01 KB (-0.00%)
index-vars.css 47.02 KB 47.02 KB ⬇ < 0.01 KB (-0.00%)
index.css 47.02 KB 47.02 KB ⬇ < 0.01 KB (-0.00%)
metadata.json 21.87 KB 21.88 KB ⬇ < 0.01 KB (-0.00%)

tokens

File Head Base Δ
css/dark-vars.css 36.32 KB 24.57 KB ⬆ 11.74 KB (47.79%)
css/express/custom-dark-vars.css 0.59 KB 0.59 KB -
css/express/custom-darkest-vars.css 0.59 KB 0.59 KB -
css/express/custom-large-vars.css 0.50 KB 0.50 KB -
css/express/custom-light-vars.css 0.63 KB 0.63 KB -
css/express/custom-medium-vars.css 0.48 KB 0.48 KB -
css/express/custom-vars.css 0.04 KB 0.04 KB -
css/global-vars.css 52.96 KB 38.23 KB ⬆ 14.73 KB (38.55%)
css/large-vars.css 27.98 KB 24.40 KB ⬆ 3.58 KB (14.68%)
css/light-vars.css 36.31 KB 24.55 KB ⬆ 11.76 KB (47.90%)
css/medium-vars.css 27.91 KB 24.33 KB ⬆ 3.58 KB (14.71%)
css/spectrum/custom-dark-vars.css 3.40 KB 3.40 KB -
css/spectrum/custom-darkest-vars.css 3.40 KB 3.40 KB -
css/spectrum/custom-large-vars.css 4.68 KB 4.68 KB -
css/spectrum/custom-light-vars.css 3.40 KB 3.40 KB -
css/spectrum/custom-medium-vars.css 4.92 KB 4.92 KB -
css/spectrum/custom-vars.css 2.18 KB 2.04 KB ⬆ 0.15 KB (7.00%)
index.css 205.74 KB 199.21 KB ⬆ 6.53 KB (3.28%)
css/darkest-vars.css - 24.53 KB 🚨 deleted, moved, or renamed
css/express/global-vars.css - 2.39 KB 🚨 deleted, moved, or renamed
css/express/large-vars.css - 2.52 KB 🚨 deleted, moved, or renamed
css/express/medium-vars.css - 2.51 KB 🚨 deleted, moved, or renamed
css/spectrum/global-vars.css - 2.74 KB 🚨 deleted, moved, or renamed
css/spectrum/large-vars.css - 2.32 KB 🚨 deleted, moved, or renamed
css/spectrum/medium-vars.css - 2.32 KB 🚨 deleted, moved, or renamed
* Size determined by adding together the size of the main file for all packages in the library.
* Results are not gzipped or minified.
* An ASCII character in UTF-8 is 8 bits or 1 byte.

@pfulton pfulton added wip This is a work in progress, don't judge. do not merge A flag for a branch indicating it should not be merged. skip_vrt Add to a PR to skip running VRT (but still pass the action) labels Dec 8, 2023
@pfulton pfulton force-pushed the spectrum-two branch 3 times, most recently from 5ec70af to c4aa5f5 Compare December 13, 2023 15:52
@pfulton pfulton mentioned this pull request Jan 8, 2024
12 tasks
@pfulton pfulton force-pushed the spectrum-two branch 2 times, most recently from d2ac17c to b2fee42 Compare January 11, 2024 14:31
@pfulton pfulton force-pushed the spectrum-two branch 4 times, most recently from 31afc05 to 909f232 Compare January 22, 2024 20:15
@pfulton pfulton force-pushed the spectrum-two branch 3 times, most recently from 9a01c5a to 1b959b3 Compare February 5, 2024 21:12
@pfulton pfulton force-pushed the spectrum-two branch 2 times, most recently from 98335ab to fec70b3 Compare February 26, 2024 19:47
@pfulton pfulton force-pushed the spectrum-two branch 2 times, most recently from 7c86724 to 0a218bc Compare March 28, 2024 14:22
@castastrophe castastrophe force-pushed the spectrum-two branch 4 times, most recently from 13e54aa to 0f20c5b Compare April 4, 2024 21:01
jawinn and others added 14 commits May 9, 2024 14:09
* feat: add example gradients for static black and white

Add new gradient backgrounds, displayed for static black and static
white variants. These are used for examples only. This adds CSS custom
properties available globally within Storybook and sets them on the
existing decorator.

* docs(fieldlabel): support static colors decorator in storybook

Change Field label stories that show static black and static white,
so they work with the recently added decorator that changes the main
Storybook background.

* docs(button): adjust static colors template

Adjust static colors template to better handle the static color
decorator and gradients.

* chore(fieldlabel): apply eslint indentation changes to stories
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
* feat(switch): s2 migration

* chore: remove themes

* fix: animation

* fix: whcm light mode unchecked handle shows

* docs(storybook): align chromatic setup with new standard

* fix: checked corners for non-retina display

* fix: whcm handle selected color

* fix: namespace mods, use semantic tokens instead of global

* fix: handle state colors
* chore: release (next)

* docs: reset changes to changelog

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Patrick Fulton <[email protected]>
* feat(fieldlabel)!: s2 migration (#2569)

BREAKING CHANGE: uses Spectrum 2 tokens

Also:
* feat(fieldlabel): medium as default and 100 sizing tokens

- Use the correct "100" sized tokens for medium.
- Make medium styles the default, to conform with existing pattern.
  .spectrum-FieldLabel--sizeM class removed as it is no longer
  necessary.

* feat(fieldlabel): use correct font size tokens

The font-size tokens used for large and extra large needed to be shifted
up to match the s2 spec.

* refactor(fieldlabel): remove deprecated mods

Remove renamed mods marked as deprecated for S2 release.

* docs(fieldlabel): spectrum 2 noted in migration notes

Updates some docs and adds migration notes. Clarifies some docs around
"left" and "right", and fixes duplicate ID warnings from examples code.

* docs(fieldlabel): form - docs update and regenerate mods

Add migration guide section to "Form", that currently lives within the
Field label component. Regenerates mods to include the removal of
deprecated renamed mods.

* fix(fieldlabel): rename mod property referencing global token

A mod custom property was referencing a global token instead of the
component itself. Renames this and adds a note to the migration guide.

* feat(fieldlabel): use correct sizing tokens

Use correct tokens for some large and extra large custom properties,
to matching with design.

* style(fieldlabel): applying linter formatting adjustments

Run linter fix on the fieldlabel component, which rearranges a few
declarations.

* docs(fieldlabel): document asterisk icon size

Add documentation about asterisk UI icon sizes specified on the design.
These sizes are already handled in the Storybook template, but were not
really explained to the user.

* feat(fieldlabel): black and white static color variants

Add classes for static colors, as defined on the designs. And adds
examples of these variants to the documentation.

* build(fieldlabel): specify s2 tokens release for dependency

Use Spectrum 2 version of tokens package in dependencies list.

* chore: rebase against main and update components to use prerelease tokens

* chore: run branch through format; update pathing and fix errors

* chore: add changeset for css update

---------

Co-authored-by: Josh Winn <[email protected]>
Co-authored-by: Patrick Fulton <[email protected]>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* refactor(button): spectrum 2 styles and cleanup

Spectrum 2 changes to CSS:
- integrate themes css into main css
- use s2 corner rounding
- use s2 colors

Cleanup items of note:
- make medium size the default
- consolidate and organize focus indicator styles. Some declarations
  were repeated.
- Rename mod for font weight that was referencing a global token instead
  of a component specific name.
- simplify repetitive disabled custom properties
- removed some unused css; static variant declarations at the end of the
  file were being overridden by more specific styles
- remove unused is-selected, emphasized, and quiet classes that are not
  used on this component
- remove the spectrum-Button--fill class. it was already the default.

* fix(button): high contrast - ensure matching color pairs for accent

Ensures that a matching background and foreground color pair is used for
the high contrast colors, for Accent hover, down, and focus. Changes
the content color to HighlightText to ensure contrast when these have a
background set to Highlight.

* docs(button): update documentation and storybook for s2

- Some improvements and additions to the spectrum 2 release notes.
- Updates migration guide notes to include version and dates for the
  previous notes.
- Removes spectrum-Button--sizeM class from examples. Excludes the
  spectrum-Button--sizeM class in the storybook template.
- Removes medium size class from storybook
- Fixes default flex alignment stretching buttons vertically in
  Storybook to the tallest button.

* fix(button): calculate corner rounding to support wrapping design

Calculate corner rounding based on the component height, so that the
rounding looks correct when there is wrapping text.

Otherwise, when the button wraps, it has too much rounding as compared
to the design when using the corner-radius-full token.

* feat(button): outline option removals and use accent as the default

Removes the outline option for the accent and negative variants, and
makes sure that the accent variant is the default.

== outline option removal ==

Per design feedback and updated design spec changelog, the outline
treatment (style) is no longer supported for the Accent and Negative
color variants:

"Outline buttons are no longer available in accent and negative options
— use the filled variant instead"

This removes their CSS, lists the change in the migration notes, and
disables the treatment control for the Accent and Negative stories. It
also removes the outline example in the template for those two stories.

== use accent as the default ==

Use accent styles for the default button when there is no variant class
applied, to match the default defined on the guidelines.

* fix(button): additional s2 style adjustments and organization

- make usage of edge to visual values consistent
- use full corner rounding on icon-only variant, which does not need to
  account for wrapping text
- correct static white secondary outline background color, per PR review
- chore: apply linter formatting

* docs(button): custom mdx docs page

Create an MDX "Docs" page that works as a replacement for the YML docs
pages, and covers the important Button options from there and the
guidelines.

Adds the tag "is-hidden-story" for excluding Storybook sidebar items.

* chore(button): add changeset

* build(button): use beta version of commons dependency

Since the commons version on main was updated to 10.0, the Button
started building with the wrong version of commons when importing
basebutton.css and listing mods that have been removed in the version
of commons in the spectrum-two branch.

* chore(button): clear up linter warnings

Fixes warnings and errors from stylelint and eslint.

* fix(button): correct focus indicator rounding and basebutton mod

The focus indicator rounding needed an additional calc in order to
have the correct rounding.

While testing --mod-button-focus-ring-gap and some other mods, it was
also noticed that a declaration being imported from basebutton was
causing some of the mod names to be different and the mod to not work
correctly (basebutton is generating a selector for the margin of
.spectrum-Button:focus-visible::after).
* chore: release s2 button (next)

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Patrick Fulton <[email protected]>
* chore: release (next)

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Patrick Fulton <[email protected]>
pfulton and others added 15 commits May 30, 2024 14:21
* chore(tokens): use [email protected]

Uses the latest tokens release.

* chore: add changeset
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
The styles had previously diverged from what this placeholder class was
providing, which was causing an issue with needing to override styles
with unnecessary CSS. This cleans that up by integrating the small
number of styles from spectrum-ButtonWithFocusRing that were not already
present, and removing that "extend".
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Migrates the Picker component to Spectrum 2, based on the updated Figma specs.

- Integrate themes CSS files into index.css
- Uses new S2 tokens for field width and corner rounding
- Add down state with new calculated perspective
- The top to alert icon in Spectrum 2 now uses the
  component-top-to-workflow-icon-* tokens as defined on the design.
- Adds the CJK line-height token defined on the design specs.
- Uses border-width-200 instead of border-width-100

* fix(picker): use correct spacing between icons and value text

The spacing between alert icon and disclosure icon was incorrect
because it was being overridden by a selector that shouldn't have been
affecting this scenario (which was using the subsequent-sibling
combinator ~). Some mods around the spacing for the three different
types of icons were also not working as expected.

Fixes this spacing and clarifies which spacing is which. Renames the mod
that applies to the optional workflow icon to the left of the value.

Simplifies quiet styles by changing custom property values instead of
adding extra styles.

* feat(picker): storybook - expanded and improved chromatic template

Expands the Chromatic-only template in Storybook to increase coverage
of different options.

Organizes the stories into sections using the formatting and typography
previously established with Action button. States in each section are
based on the grid of options in the Desktop S2 design Figma, with some
additions such as the loading state. And the Switch examples from the
existing template.

Removes the "Open" story which is now covered in the Chromatic template.

Adds missing icon (to left of value/placeholder text) option to
Storybook, along with VRT coverage.

Improves display of Popover within these different contexts; fixes how
it is aligned on the side label example. Changes the side label example
to use flex row instead of using inline-block which could wrap as the
screen shrunk.

=== Other Storybook fixes and additions ===

- Adds aria-labelledby and unique ids to make sure the label is associated
  with the Picker.
- Includes downstate dimension capture
- Popover does not show when in the loading state (per design feedback)
- Makes sure HelpText appears below the Picker when using side label, by
  adjusting its wrapper markup.
- Adds conditional controls to disabled and loading states, per the PR
  feedback that disabled + loading should not be a possible combo.
* refactor: remove --sizeM modifier and make "medium" default size

* refactor:remove accent semantic variant

* refactor: add/update new colors/tokens

* refactor: update typography styles

* refactor: generate new mod properties

* docs: add migration notes/changes to yml

* feat: add chromatic vr coverage

* fix: high contrast changes (utilizes changes from PR#2771 to clean up
legacy vendor prefixes)

* docs: add changeset and update yml
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore(s2-avatar): initial commit

* chore(s2-avatar): add sizing and border tokens
* feat(thumbnail): migrate to S2

* feat(thumbnail): add customstyles to scope change to thumbnail
* feat(colorarea): s2 migration

* feat(colorarea): remove redundant property

* feat(colorarea): clarify color + rgb implementation

* feat(colorarea): fix gradient border-radius

* feat(colorarea): move forced-colors media query

* feat(colorarea): update changeset
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do not merge A flag for a branch indicating it should not be merged. skip_vrt Add to a PR to skip running VRT (but still pass the action) wip This is a work in progress, don't judge.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants