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(link): new typography tokens, focus color and design, WHCM focus state #3570

Open
wants to merge 106 commits into
base: spectrum-two
Choose a base branch
from

Conversation

aramos-adobe
Copy link
Collaborator

@aramos-adobe aramos-adobe commented Feb 20, 2025

Link S2 migration

New tokens

Color

spectrum-link-focus-indicator-color
spectrum-link-focus-indicator-thickness
spectrum-link-focus-indicator-gap
spectrum-link-corner-radius

Typography

spectrum-link-line-height
spectrum-link-line-height-cjk-100
spectrum-link-font-size
spectrum-link-font-style
spectrum-link-font-weight
spectrum-link-text-underline-thickness
spectrum-link-text-underline-gap

How and where has this been tested?

Please tag yourself on the tests you've marked complete to confirm the tests have been run by someone other than the author.

Validation steps

Regression testing

Validate:

  1. The documentation pages for at least two other components are still loading, including:
  • The pages render correctly, are accessible, and are responsive.
  1. If components have been modified, VRTs have been run on this branch:
  • VRTs have been run and looked at.
  • Any VRT changes have been accepted (by reviewer and/or PR author), or there are no changes.

Screenshots

Screenshot 2025-02-20 at 2 16 30 PM Screenshot 2025-02-20 at 2 16 50 PM

To-do list

  • I have read the contribution guidelines.
  • I have updated relevant storybook stories and templates.
  • I have tested these changes in Windows High Contrast mode.
  • If my change impacts other components, I have tested to make sure they don't break.
  • If my change impacts documentation, I have updated the documentation accordingly.
  • ✨ This pull request is ready to merge. ✨

castastrophe and others added 30 commits February 11, 2025 09:14
Expanding the existing themes system to support the new S2 mappings.

---
Co-authored-by: castastrophe <[email protected]>
Co-authored-by: Patrick Fulton <[email protected]>
Co-authored-by: Cory Dransfeldt <[email protected]>
Co-authored-by: Aziz Ramos <[email protected]>
Co-authored-by: Josh Winn <[email protected]>
Co-authored-by: Rise Erpelding <[email protected]>
Co-authored-by: Marissa Huysentruyt <[email protected]>
Co-authored-by: Rajdeep Chandra <[email protected]>
Co-authored-by: TarunAdobe <[email protected]>
Co-authored-by: Dragan Eror<[email protected]>
Expanding the existing themes system to support the new S2 mappings.

---
Co-authored-by: castastrophe <[email protected]>
Co-authored-by: Patrick Fulton <[email protected]>
Co-authored-by: Cory Dransfeldt <[email protected]>
Co-authored-by: Aziz Ramos <[email protected]>
Co-authored-by: Josh Winn <[email protected]>
Co-authored-by: Rise Erpelding <[email protected]>
Co-authored-by: Marissa Huysentruyt <[email protected]>
Co-authored-by: Rajdeep Chandra <[email protected]>
Co-authored-by: TarunAdobe <[email protected]>
Co-authored-by: Dragan Eror<[email protected]>
Expanding the existing themes system to support the new S2 mappings.

---
Co-authored-by: castastrophe <[email protected]>
Co-authored-by: Patrick Fulton <[email protected]>
Co-authored-by: Cory Dransfeldt <[email protected]>
Co-authored-by: Aziz Ramos <[email protected]>
Co-authored-by: Josh Winn <[email protected]>
Co-authored-by: Rise Erpelding <[email protected]>
Co-authored-by: Marissa Huysentruyt <[email protected]>
Co-authored-by: Rajdeep Chandra <[email protected]>
Co-authored-by: TarunAdobe <[email protected]>
Co-authored-by: Dragan Eror<[email protected]>
* feat: s2 foundations non-gray-800 colors update

* add changeset
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>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* docs(assetcard): remove MDX file

- adds some missing documentation regarding stories, classes and custom
properties
- corrects sentence-casing of story names

* docs(avatar): remove MDX file

- adds some missing documentation regarding stories
- reorganizes some information to sit with appropriate story/variant
- migrates documentation from MDX file to the stories file instead

* chore(avatar): fix disabled test arguments

* docs(badge): remove MDX file

- adds notice badge variants to semantic story
- adds sizing story to docs page
- migrates documentation in MDX to stories.js instead

* docs(badge): pr fixes

- remove empty doc block line
- remove html wrapper in favor of content array
- add notice badge to test coverage
Includes new color values for Spectrum 2
BREAKING CHANGE: migrates `Action Group` to Spectrum 2, Removes some mod properties
BREAKING CHANGE: migrates Button Group to Spectrum 2

Also:
* docs(buttongroup): expand chromatic coverage
* refactor(buttongroup): remove extra css classes
BREAKING CHANGE: uses Spectrum 2 tokens
 - @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]
BREAKING CHANGE: migrates Close Button to Spectrum 2

Additionally:
* test: increase chromatic coverage
* fix(closebutton): pass staticColor as arg for SB display
* chore(closebutton): remove themes dir
* docs(closebutton): adds s2 migration notes
* chore(closebutton): specify s2 tokens release for dependency

---------

Co-authored-by: Patrick Fulton <[email protected]>
* chore: migrate gray-50 to gray-25

Migrates any instance of `--spectrum-gray-50` to use
`--spectrum-gray-25` as per the S2 migration guide

* chore: migrate gray-75 to gray-50

Migrates usages of `--spectrum-gray-75` to use
`--spectrum-gray-50` as per the s2 migration guide.

* chore: migrate gray-100 to gray-75

Migrates usages of `--spectrum-gray-100` to use
`--spectrum-gray-75` as per the s2 migration guide

* chore: migrate gray-200 to gray-100

Migrates usages of `--spectrum-gray-200` to use
`--spectrum-gray-100` as per the s2 migration guide

* chore: migrate gray-300 to gray-200

Migrates usages of `--spectrum-gray-300` to use
`spectrum-gray-200` as per the s2 migration guide

* chore(infieldbutton): gray-300 to gray-200
* fix(commons): remove renamed mods marked for deprecation

Remove mods that were renamed and previously marked for deprecation,
and regenerate mods lists. This will help in reviewing the accuracy of
other components' mods lists as they are being migrated to s2.

* docs: migration guide notes for mod property deprecations

Add notes to components affected by mod property changes in the commons
basebutton.

* docs(closebutton): updated docs for migration guide and icon size

- Removes the "Icon size" variant options, as noted in the closebutton
  PR. Per Figma changelog "removed icon size as a property".
- Updates migration guide with a more organized history.

* fix(commons): remove another mod referencing global token

Deprecates an additional mod name that was referencing a global token,
and updates migration notes for all affected components.
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.
Takes in the latest beta release for S2 tokens
 - @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]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
* feat(downstate): docs + implementation for example components
* docs: update mdx
* docs: reorg, stories live within foundations
* docs: decorator for down state dimension tokens
* docs: fix mdx hierarchy console error
* fix: small iconOnly button gets min perspective
* docs: use markdown, update language
* fix: disabled, readonly checkbox doesnt have down state
* chore(button,checkbox): update package versions
* feat(tokens): use spectrum tokens beta 21
* chore(tokens): add custom token for corner rounding
 - @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]
 - @spectrum-css/[email protected]
 - @spectrum-css/[email protected]
marissahuysentruyt and others added 10 commits February 11, 2025 13:00
feat(popover): new S2 popover styles
- new tokens and token values used for popover
- create changeset
- rebuild metadata.json
- adjust popoverWidth and popoverHeight args to accommodate new padding
- update test file with new popoverWidth and popoverHeight
- correct side aligned popovers distance to source

* fix(coachmark): nested popover style updates
- update the border radius of the popover nested in coachmark to match
S2 popover specs
- update popover `--mod-popover-content-area-spacing` variable name
(previously --mod-popover-content-area-spacing-vertical)
- rebuild metadata.json

* fix(picker): update popover selector class
- with the new default position for popover, the selector class for the
popover in picker also needed to be updated. (--bottom-start)
- create changeset
- rebuild metadata.json

* docs(popover): fixup some docs wording
- add down state link
Migrates component to Spectrum 2. Includes renaming of variants and new
large t-shirt size, changed token usage to match spec, additional
storybook options, etc.

docs(breadcrumb): new controls for nested and improved nested docs

Adds controls so a user is able to display the nested truncated menu,
root context, set disabled items, and item text. This also clears
up and moves around some of the documentation about the truncated menu
and root context.

docs(breadcrumb): refactor tests

Update VRTs tests file to use new refactored controls and updated s2
variants. More options can now live in the state data.

docs(breadcrumb): add hover and focus-visible to tests
feat(illustratedmessage): updating token version

feat(illustratedmessage): work in progress

feat(illustratedmessage): adding new tokens, tshirt sizes, orientation, button group

feat(illustratedmessage): updating CSS structure and adding conditional buttons

feat(illustratedmessage): update tokens

feat(illustratedmessage): changeset, styles, dropzone mods

feat(illustratedmessage): work in progress

feat(illustratedmessage): updating mods

feat(illustratedmessage): removing message accent color selector

chore(illustratedmessage): updating changeset

docs(illustratedmessage): heading controls

fix(illustratedmessage): fixing cjk tokens and removing heading and base classes

fix(illustratedmessage): fixing cjk tokens and removing heading and base classes

feat(illustratedmessage): new mods

docs(illustratedmessage): adding horizontal story context

feat(illustratedmessage): removing extra dashes, reverting dropzone

chore(fix): adding stylelint disable desc

chore(fix): removing unused highcontrast accent color token

feat(illustratedmessage): adding grid display

chore(im): removing unused import

chore(im): removing more unused imports

chore(illustratedmessage): updating testing env

fix(dropzone): removing unused controls

feat(illustratedmessage): reviewing comments

feat(illustratedmessage): adjusting story horiz copy

fix(illustratedmessage): resolving changes

chore(im): bringing back to center

fix: removing lint line

chore: restore stepper index css file

chore(illustratedmessage): removing one liner in dropzone)

chore(illustratedmessage): removing stylelint line

chore(illustratedmessage): removing unused custom props in dropzone
…gress circle (#3430)

* feat(infieldprogress): add new component

feat(infieldcircle): new component

feat(ifpc): updating template and vrts

chore(ifpc): updating story changes

chore(ifpc): cleaning up build files

feat(ifpc): add infield loader to components

feat(infieldprogress): add new component

feat(ifpc): updating template and vrts

feat(ifpc): updating package, story, template

chore(ifpc): spectrum two updates

chore(ifpc): adding dist files

chore(ifpc): changing button id

chore(ifpc): updating bundle

chore(ifpc): updating package

chore(ifpc): testing out files

chore(ifpc): adding missing dist files

chore(ifpc): removing index css in dist

fix(ifpc): fixing typos

fix(ifpc): update mods in changeset

chore(ifpc): removing mods from ifpc components in changeset

* chore(ifpc): update package json)
- removes --spectrum-statuslight-semantic-accent-color from CSS
- removes deprecated accent variant from template and tests
- adds changeset
- update metadata.json
* feat(icon): updated s2 icons - workflow and ui

Uses and updates to the latest icon sets for S2.

==== Workflow icons ====
Uses the latest version of this package. There is a large difference
between the set of icons available for S1 and S2. These differences are
documented separately from this work.

==== UI icons ====
Updates the ui-icons package with the latest set of icons. This includes
deprecations and some new icons. See the change log for a full list of
changes.

The UI icons no longer contain both a medium and a large SVG asset. The
file structure and loading have been changed to use the single asset.

Co-authored-by: [ Cassondra ] <[email protected]>

Also includes:
* build(storybook): use latest 4.0.0 version of workflow icons
* feat(icon): remove guessing of icon set if not provided
* refactor(icon): refactors, cleans up, and documents template logic and utilities
* feat(icon): exclude new ui icons not yet ready for production (CSS-1115)
* feat(icon): exclude 22x20 workflow icons (CSS-1116)
Copy link

changeset-bot bot commented Feb 20, 2025

🦋 Changeset detected

Latest commit: 226c4bf

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@spectrum-css/link Major
@spectrum-css/contextualhelp Major
@spectrum-css/dropzone Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@@ -2,7 +2,8 @@ import { Template as ButtonGroup } from "@spectrum-css/buttongroup/stories/templ
import { Template as Checkbox } from "@spectrum-css/checkbox/stories/template.js";
import { Template as CloseButton } from "@spectrum-css/closebutton/stories/template.js";
import { Template as Modal } from "@spectrum-css/modal/stories/template.js";
import { getRandomId, renderContent } from "@spectrum-css/preview/decorators";
import { getRandomId } from "@spectrum-css/preview/decorators";
import { Template as Typography } from "@spectrum-css/typography/stories/template.js";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚫 [eslint] <no-unused-vars> reported by reviewdog 🐶
'Typography' is defined but never used.

@aramos-adobe aramos-adobe force-pushed the aramos-adobe/css1019-link-s2-migration branch from 9a2a1e9 to 773de88 Compare February 20, 2025 19:40
Copy link
Contributor

github-actions bot commented Feb 20, 2025

File metrics

Summary

Total size: 1.42 MB*
Total change (Δ): 🔴 ⬆ 1.26 KB (0.09%)

Table reports on changes to a package's main file.

Package Size Minified Gzipped Δ
link 4.52 KB - - 🔴 ⬆ 1.26 KB

link

Filename Head Minified Gzipped Compared to base
index.css 4.52 KB - - 🔴 ⬆ 1.26 KB
metadata.json 2.34 KB - - 🔴 ⬆ 0.87 KB
* Size is the sum of all main files for packages in the library.
* An ASCII character in UTF-8 is 8 bits or 1 byte.

Copy link
Contributor

github-actions bot commented Feb 20, 2025

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

@castastrophe castastrophe added the S2 Spectrum 2 label Feb 21, 2025
@castastrophe castastrophe force-pushed the spectrum-two branch 5 times, most recently from d5e72d4 to 0f14273 Compare February 24, 2025 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants