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(picker): migrate to spectrum 2 #2697

Open
wants to merge 17 commits into
base: spectrum-two
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 11 additions & 0 deletions .changeset/hot-books-fail.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"@spectrum-css/picker": major
---

#### Spectrum 2 migration
Picker now uses Spectrum 2 tokens and specifications. A few notable changes:
- The mod custom property `--mod-line-height-100` has been renamed to `--mod-button-line-height`.
- The mod custom property `--mod-sans-font-family-stack` has been renamed to `--mod-button-font-family`.
- The mod custom property `--mod-animation-duration-100` has been renamed to `--mod-button-animation-duration`.
- The mod custom property `--mod-picker-spacing-text-to-alert-icon-inline-start` has been renamed to `--mod-picker-spacing-text-to-icon-inline-end`. This removed the fallback that was marked as deprecated in a previous version.
- The mod custom property `--mod-picker-spacing-text-to-icon` has been removed. Use `--mod-picker-spacing-text-to-icon-inline-end` for the spacing between text and visual (indicator or disclosure), or `--mod-picker-spacing-starting-icon-to-text` for the space between the optional workflow icon and the text.
898 changes: 451 additions & 447 deletions components/picker/index.css

Large diffs are not rendered by default.

142 changes: 71 additions & 71 deletions components/picker/metadata/mods.md
Original file line number Diff line number Diff line change
@@ -1,71 +1,71 @@
| Modifiable custom properties |
| ------------------------------------------------------ |
| `--mod-animation-duration-100` |
| `--mod-button-animation-duration` |
| `--mod-button-font-family` |
| `--mod-button-line-height` |
| `--mod-line-height-100` |
| `--mod-picker-animation-duration` |
| `--mod-picker-background-color-active` |
| `--mod-picker-background-color-default` |
| `--mod-picker-background-color-default-open` |
| `--mod-picker-background-color-disabled` |
| `--mod-picker-background-color-hover` |
| `--mod-picker-background-color-hover-open` |
| `--mod-picker-background-color-key-focus` |
| `--mod-picker-block-size` |
| `--mod-picker-border-active` |
| `--mod-picker-border-color-default` |
| `--mod-picker-border-color-error-active` |
| `--mod-picker-border-color-error-default` |
| `--mod-picker-border-color-error-default-open` |
| `--mod-picker-border-color-error-hover` |
| `--mod-picker-border-color-error-hover-open` |
| `--mod-picker-border-color-error-key-focus` |
| `--mod-picker-border-color-hover` |
| `--mod-picker-border-color-hover-open` |
| `--mod-picker-border-color-key-focus` |
| `--mod-picker-border-default-open` |
| `--mod-picker-border-radius` |
| `--mod-picker-border-width` |
| `--mod-picker-focus-indicator-color` |
| `--mod-picker-focus-indicator-gap` |
| `--mod-picker-focus-indicator-thickness` |
| `--mod-picker-font-color-active` |
| `--mod-picker-font-color-default` |
| `--mod-picker-font-color-default-open` |
| `--mod-picker-font-color-disabled` |
| `--mod-picker-font-color-hover` |
| `--mod-picker-font-color-hover-open` |
| `--mod-picker-font-color-key-focus` |
| `--mod-picker-font-size` |
| `--mod-picker-font-weight` |
| `--mod-picker-icon-color-active` |
| `--mod-picker-icon-color-default` |
| `--mod-picker-icon-color-default-open` |
| `--mod-picker-icon-color-disabled` |
| `--mod-picker-icon-color-error` |
| `--mod-picker-icon-color-hover` |
| `--mod-picker-icon-color-hover-open` |
| `--mod-picker-icon-color-key-focus` |
| `--mod-picker-inline-size` |
| `--mod-picker-line-height` |
| `--mod-picker-placeholder-font-style` |
| `--mod-picker-placeholder-font-weight` |
| `--mod-picker-spacing-bottom-to-text` |
| `--mod-picker-spacing-edge-to-disclosure-icon` |
| `--mod-picker-spacing-edge-to-disclosure-icon-quiet` |
| `--mod-picker-spacing-edge-to-text` |
| `--mod-picker-spacing-edge-to-text-quiet` |
| `--mod-picker-spacing-icon-to-disclosure-icon` |
| `--mod-picker-spacing-label-to-picker` |
| `--mod-picker-spacing-label-to-picker-quiet` |
| `--mod-picker-spacing-picker-to-popover` |
| `--mod-picker-spacing-text-to-alert-icon-inline-start` |
| `--mod-picker-spacing-text-to-icon` |
| `--mod-picker-spacing-text-to-icon-inline-end` |
| `--mod-picker-spacing-top-to-alert-icon` |
| `--mod-picker-spacing-top-to-disclosure-icon` |
| `--mod-picker-spacing-top-to-progress-circle` |
| `--mod-picker-spacing-top-to-text` |
| `--mod-sans-font-family-stack` |
| Modifiable custom properties |
| ---------------------------------------------------- |
| `--mod-button-animation-duration` |
| `--mod-button-font-family` |
| `--mod-button-line-height` |
| `--mod-picker-animation-duration` |
| `--mod-picker-background-color-active` |
| `--mod-picker-background-color-default` |
| `--mod-picker-background-color-default-open` |
| `--mod-picker-background-color-disabled` |
| `--mod-picker-background-color-hover` |
| `--mod-picker-background-color-hover-open` |
| `--mod-picker-background-color-key-focus` |
| `--mod-picker-block-size` |
| `--mod-picker-border-active` |
| `--mod-picker-border-color-default` |
| `--mod-picker-border-color-error-active` |
| `--mod-picker-border-color-error-default` |
| `--mod-picker-border-color-error-default-open` |
| `--mod-picker-border-color-error-hover` |
| `--mod-picker-border-color-error-hover-open` |
| `--mod-picker-border-color-error-key-focus` |
| `--mod-picker-border-color-hover` |
| `--mod-picker-border-color-hover-open` |
| `--mod-picker-border-color-key-focus` |
| `--mod-picker-border-default-open` |
| `--mod-picker-border-radius` |
| `--mod-picker-border-width` |
| `--mod-picker-focus-indicator-color` |
| `--mod-picker-focus-indicator-gap` |
| `--mod-picker-focus-indicator-thickness` |
| `--mod-picker-font-color-active` |
| `--mod-picker-font-color-default` |
| `--mod-picker-font-color-default-open` |
| `--mod-picker-font-color-disabled` |
| `--mod-picker-font-color-hover` |
| `--mod-picker-font-color-hover-open` |
| `--mod-picker-font-color-key-focus` |
| `--mod-picker-font-size` |
| `--mod-picker-font-weight` |
| `--mod-picker-icon-color-active` |
| `--mod-picker-icon-color-default` |
| `--mod-picker-icon-color-default-open` |
| `--mod-picker-icon-color-disabled` |
| `--mod-picker-icon-color-error` |
| `--mod-picker-icon-color-hover` |
| `--mod-picker-icon-color-hover-open` |
| `--mod-picker-icon-color-key-focus` |
| `--mod-picker-inline-size` |
| `--mod-picker-inline-size-quiet` |
| `--mod-picker-line-height` |
| `--mod-picker-line-height-cjk` |
| `--mod-picker-min-inline-size` |
| `--mod-picker-min-inline-size-quiet` |
| `--mod-picker-placeholder-font-style` |
| `--mod-picker-placeholder-font-weight` |
| `--mod-picker-spacing-bottom-to-text` |
| `--mod-picker-spacing-edge-to-disclosure-icon` |
| `--mod-picker-spacing-edge-to-disclosure-icon-quiet` |
| `--mod-picker-spacing-edge-to-text` |
| `--mod-picker-spacing-edge-to-text-quiet` |
| `--mod-picker-spacing-icon-to-disclosure-icon` |
| `--mod-picker-spacing-label-to-picker` |
| `--mod-picker-spacing-label-to-picker-quiet` |
| `--mod-picker-spacing-picker-to-popover` |
| `--mod-picker-spacing-starting-icon-to-text` |
| `--mod-picker-spacing-text-to-icon-inline-end` |
| `--mod-picker-spacing-top-to-alert-icon` |
| `--mod-picker-spacing-top-to-disclosure-icon` |
| `--mod-picker-spacing-top-to-progress-circle` |
| `--mod-picker-spacing-top-to-text` |
2 changes: 2 additions & 0 deletions components/picker/metadata/picker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ sections:
- The mod custom property `--mod-line-height-100` has been renamed to `--mod-button-line-height`.
- The mod custom property `--mod-sans-font-family-stack` has been renamed to `--mod-button-font-family`.
- The mod custom property `--mod-animation-duration-100` has been renamed to `--mod-button-animation-duration`.
- The mod custom property `--mod-picker-spacing-text-to-alert-icon-inline-start` has been renamed to `--mod-picker-spacing-text-to-icon-inline-end`. This removed the fallback that was marked as deprecated in a previous version.
- The mod custom property `--mod-picker-spacing-text-to-icon` has been removed. Use `--mod-picker-spacing-text-to-icon-inline-end` for the spacing between text and visual (indicator or disclosure), or `--mod-picker-spacing-starting-icon-to-text` for the space between the optional workflow icon and the text.

### Versions prior to 8.0
#### Component renamed
Expand Down
2 changes: 1 addition & 1 deletion components/picker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
}
},
"devDependencies": {
"@spectrum-css/commons": "^10.0.0"
"@spectrum-css/commons": "^9.1.4-next.1"
},
"keywords": [
"spectrum",
Expand Down