Replies: 2 comments
-
From an iOS point of view, I don't think there will be huge consequences here, we're using tokens from |
Beta Was this translation helpful? Give feedback.
-
Decision: From the design team's perspective, we can move forward with overwriting S1 token data with S2 values. There are some accessibility issues that we want to address in S1 in the future but we will fix those at the implementation or product level. DACI:
|
Beta Was this translation helpful? Give feedback.
-
Problem statement
Currently, Spectrum 1 data has been released in @adobe/spectrum-tokens. This data can be found in the
latest
npm tag (v12.25.0) and themain
GitHub branch in this repo. Spectrum 2 data can be found in thebeta
npm tagged releases (13.0.0-beta.34) and thebeta
branch in this repo.As the data is defined in these branches today, we don't have a very clear migration path from S1 to S2.
History
Initially, the plan for S2 was to release foundational changes that would impact every component (changes to colors, corner-radius, icon sizing, and corresponding spacing). Since the original work was done, more changes have been introduced to these foundations while working on S2 components. As a result, there isn't a clear migration path in the release notes of the different beta releases of the S2 tokens.
Additionally, because of some velocity differences, Spectrum Design has been working on S2 changes without the benefit of having an implementation, like Spectrum Web Components (SWC), to verify the updated S2 token values. As SWC has started exploring the implementation of these S2 changes, they have recommended some changes that would make it easier for products to migrate to these breaking changes.
Proposal
To reduce the complexity of this S1 to S2 migration, we propose gathering the foundation S2 changes and start making a smaller initial release of S2 into the
main
branch on this repo and thelatest
tag on npm.Even though the foundational changes would be considered a breaking change, this would be a v13.0.0, which could be considered confusing because it would be a somewhat separate effort from the v13.0.0-beta releases up to this point.
To accomplish design verification of the changes in a fully interactive implementation, I have published a snapshot release of an initial pass of the S2 color changes. This is version 0.0.0-s2-foundations-colors-20240503210338 with a
s2-foundations
tag. Spectrum CSS and SWC have been working to test this smaller set of data. After it is verified with Spectrum Design, we will release the next set of foundational changes as a snapshot until Spectrum Design, Spectrum Engineering, and leadership have come to a consensus on what should be included in this S2 foundations work, which will then be moved to themain
branch, andlatest
tag in npm.Diagram
I've included a simplified diagram of the current relationship of the S1 and S2 data and the proposed S2 Foundations workflow.
Alternatives considered
Before we came to the idea of this smaller initial S2 stable release, the plan was to work to a larger S2 completion with a
beta
branch before moving the work tomain
. It would be a much cleaner break with S1 data. It could lead to longer-term maintenance of multiple versions while also creating a more difficult migration path for any implementation not currently testing the S2beta
releases.Consequences or Required Actions
As a result of breaking up the S2 verification work in implementations like SWC into smaller releases, the S2 data that will go into the
main
/latest
releases will likely diverge from what is currently inbeta
. As a result, implementations like Spectrum iOS and React Spectrum, which have been working with the S2beta
branch work, will need to put in some additional work to verify and adjust. It is unclear at this time how far they will diverge, and we won't know until the S2main
work is done.Also, we would likely have more than one set of breaking changes to get closer to the S2 design work. However, this is not seen as necessarily being a negative consequence. Ideally, we would like the products and implementations to be prepared to handle smaller breaking changes, and the Spectrum Engineering team will work to provide migration guides and potentially something like codemods/fastmods to reduce the strain on product teams.
Finally, the snapshot releases currently have our design token authoring process disrupted, and Spectrum Engineering will need to work with Spectrum Design to resolve it. However, this shouldn't be disruptive to implementations or products in the short term.
Beta Was this translation helpful? Give feedback.
All reactions