@adobe/spectrum-design-data 0.4.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. package/components/accordion.json +108 -194
  2. package/components/action-bar.json +64 -97
  3. package/components/action-button.json +95 -230
  4. package/components/action-group.json +88 -86
  5. package/components/alert-banner.json +104 -76
  6. package/components/alert-dialog.json +78 -126
  7. package/components/avatar-group.json +61 -119
  8. package/components/avatar.json +98 -212
  9. package/components/badge.json +138 -256
  10. package/components/breadcrumbs.json +95 -89
  11. package/components/button-group.json +57 -48
  12. package/components/button.json +151 -368
  13. package/components/calendar.json +97 -34
  14. package/components/cards.json +109 -250
  15. package/components/checkbox-group.json +50 -58
  16. package/components/checkbox.json +121 -186
  17. package/components/close-button.json +61 -124
  18. package/components/coach-indicator.json +63 -72
  19. package/components/coach-mark.json +89 -93
  20. package/components/color-area.json +68 -94
  21. package/components/color-handle.json +39 -79
  22. package/components/color-loupe.json +35 -52
  23. package/components/color-slider.json +95 -116
  24. package/components/color-wheel.json +67 -73
  25. package/components/combo-box.json +243 -331
  26. package/components/contextual-help.json +86 -175
  27. package/components/date-picker.json +139 -179
  28. package/components/divider.json +30 -69
  29. package/components/drop-zone.json +51 -92
  30. package/components/field-label.json +75 -117
  31. package/components/help-text.json +81 -105
  32. package/components/illustrated-message.json +106 -73
  33. package/components/in-line-alert.json +50 -83
  34. package/components/link.json +63 -85
  35. package/components/list-view.json +107 -146
  36. package/components/menu.json +180 -274
  37. package/components/meter.json +72 -118
  38. package/components/number-field.json +213 -305
  39. package/components/picker.json +208 -320
  40. package/components/popover.json +94 -129
  41. package/components/progress-bar.json +94 -131
  42. package/components/progress-circle.json +45 -72
  43. package/components/radio-button.json +87 -156
  44. package/components/radio-group.json +107 -74
  45. package/components/rating.json +66 -99
  46. package/components/search-field.json +132 -202
  47. package/components/segmented-control.json +94 -109
  48. package/components/select-box.json +119 -179
  49. package/components/side-navigation.json +108 -118
  50. package/components/slider.json +143 -228
  51. package/components/standard-dialog.json +96 -114
  52. package/components/standard-panel.json +105 -53
  53. package/components/status-light.json +104 -240
  54. package/components/steplist.json +77 -161
  55. package/components/swatch-group.json +42 -58
  56. package/components/swatch.json +75 -162
  57. package/components/switch.json +101 -189
  58. package/components/table.json +97 -102
  59. package/components/tabs.json +77 -104
  60. package/components/tag-field.json +86 -150
  61. package/components/tag-group.json +50 -44
  62. package/components/tag.json +81 -198
  63. package/components/takeover-dialog.json +59 -57
  64. package/components/text-area.json +200 -323
  65. package/components/text-field.json +183 -304
  66. package/components/thumbnail.json +63 -105
  67. package/components/toast.json +97 -83
  68. package/components/tooltip.json +104 -96
  69. package/components/tree-view.json +169 -181
  70. package/guidelines/app-frame-content-area.json +81 -0
  71. package/guidelines/app-frame-creating-bluelines.json +58 -0
  72. package/guidelines/app-frame-header.json +72 -0
  73. package/guidelines/app-frame-overview.json +167 -0
  74. package/guidelines/app-frame-side-navigation.json +138 -0
  75. package/guidelines/attention-hierarchy.json +42 -0
  76. package/guidelines/background-layers.json +38 -0
  77. package/guidelines/brand.json +50 -0
  78. package/guidelines/colors.json +62 -0
  79. package/guidelines/containers.json +62 -0
  80. package/guidelines/developer-overview.json +35 -0
  81. package/guidelines/faqs.json +35 -0
  82. package/guidelines/fonts.json +58 -0
  83. package/guidelines/grays.json +66 -0
  84. package/guidelines/icon-fundamentals.json +45 -0
  85. package/guidelines/illustrations.json +111 -0
  86. package/guidelines/introduction.json +31 -0
  87. package/guidelines/manifest.json +204 -0
  88. package/guidelines/motion.json +41 -0
  89. package/guidelines/object-styles.json +102 -0
  90. package/guidelines/principles.json +30 -0
  91. package/guidelines/resources.json +59 -0
  92. package/guidelines/spacing.json +25 -0
  93. package/guidelines/states.json +34 -0
  94. package/guidelines/typography-fundamentals.json +142 -0
  95. package/guidelines/using-icons.json +107 -0
  96. package/package.json +4 -2
@@ -9,126 +9,154 @@
9
9
  "category": "feedback",
10
10
  "documentationUrl": "https://spectrum.adobe.com/page/alert-banner/"
11
11
  },
12
- "options": {
13
- "text": {
14
- "type": "string"
15
- },
16
- "variant": {
17
- "type": "string",
18
- "default": "neutral",
19
- "values": [
20
- {
21
- "value": "neutral"
22
- },
23
- {
24
- "value": "informative"
25
- },
26
- {
27
- "value": "negative"
28
- },
29
- {
30
- "value": "accent"
31
- }
32
- ]
12
+ "documentBlocks": [
13
+ {
14
+ "type": "purpose",
15
+ "content": "Alert banners show pressing and high-signal messages, such as system alerts. They're meant to be noticed and prompt users to take action."
33
16
  },
34
- "actionLabel": {
35
- "type": "string",
36
- "description": "If undefined, this button does not appear."
17
+ {
18
+ "type": "guideline",
19
+ "content": "Alert banners communicate high-priority messages that need immediate attention. They appear prominently in the interface and often prompt an action."
37
20
  },
38
- "isDismissible": {
39
- "type": "boolean",
40
- "default": false
41
- }
42
- },
43
- "lifecycle": {
44
- "introduced": "1.0.0-draft"
45
- },
46
- "tokenBindings": [
47
21
  {
48
- "token": "workflow-icon-size-100",
49
- "context": "Icon asset"
22
+ "type": "guideline",
23
+ "content": "An alert banner can include an icon-only close button to dismiss it."
50
24
  },
51
25
  {
52
- "token": "alert-banner-minimum-height",
53
- "context": "Height"
26
+ "type": "guideline",
27
+ "content": "An alert banner ideally provides a way for a user to address an issue in-line with an action. It can have both an icon-only close button and a button with a contextual action to take. There should never be more than one button with a contextual action in an alert banner."
54
28
  },
55
29
  {
56
- "token": "alert-banner-width",
57
- "context": "Width"
30
+ "type": "guideline",
31
+ "content": "An alert banner always has a semantic meaning and uses semantic colors. Only gray (neutral), blue (informative), and red (negative) are available as options."
58
32
  },
59
33
  {
60
- "token": "text-to-visual-300",
61
- "context": "Spacing (icon to text)"
34
+ "type": "guideline",
35
+ "content": "Text is required for all alert banners. The message should be concise and, if applicable, describe the next step that a user can take."
62
36
  },
63
37
  {
64
- "token": "spacing-300",
65
- "context": "Spacing (start edge to text and icon)"
38
+ "type": "guideline",
39
+ "content": "When the text is too long for the available horizontal space, it wraps to form another line. In actionable alert banners, the button moves below the text prior to text wrapping."
66
40
  },
67
41
  {
68
- "token": "spacing-100",
69
- "context": "Spacing (close button to end edge)"
42
+ "type": "guideline",
43
+ "content": "Whenever possible, add an in-line action button if there's a way for a user to quickly address the issue associated with an alert."
70
44
  },
71
45
  {
72
- "token": "spacing-200",
73
- "context": "Spacing (close button to end edge)"
46
+ "type": "guideline",
47
+ "content": "The close button is optional, depending on context. Consider adding one to let a user easily dismiss the alert."
74
48
  },
75
49
  {
76
- "token": "alert-banner-top-to-workflow-icon",
77
- "context": "Spacing (top/bottom edge to icon)"
50
+ "type": "guideline",
51
+ "content": "Alert banners should be reserved only for high-signal, system-level alert messages, such as internet connection issues, expirations of subscriptions, or major changes."
78
52
  },
79
53
  {
80
- "token": "alert-banner-top-to-text",
81
- "context": "Spacing (top/bottom edge to text)"
54
+ "type": "guideline",
55
+ "content": "Don’t use yellow or orange colors for errors because the contrast is not accessible."
82
56
  },
83
57
  {
84
- "token": "alert-banner-bottom-to-text",
85
- "context": "Spacing (top/bottom edge to text)"
58
+ "type": "guideline",
59
+ "content": "If you need to show a “notice” message or other non-critical communication, use the gray (neutral) or blue (informative) semantic color options. Reserve the red (negative) option only for errors that directly interrupt or block a user’s experience — not for nice-to-know information."
86
60
  },
87
61
  {
88
- "token": "neutral-subdued-background-color-default",
89
- "context": "Background"
62
+ "type": "guideline",
63
+ "content": "Don't include more than one action in an alert banner. Having more than one action to choose from can be overwhelming, and it can become difficult for users to decide what to do next in such a small space."
90
64
  },
91
65
  {
92
- "token": "informative-background-color-default",
93
- "context": "Background"
66
+ "type": "guideline",
67
+ "content": "Alert banners should appear at the top of a page, below the header."
94
68
  },
95
69
  {
96
- "token": "negative-background-color-default",
97
- "context": "Background"
70
+ "type": "guideline",
71
+ "content": "Don't show multiple alert banners at the same time. If a new alert banner appears with a higher priority message, it should replace an existing alert banner of lesser importance until the higher priority one has been addressed."
98
72
  },
99
73
  {
100
- "token": "default-font-family",
101
- "context": "Text"
74
+ "type": "guideline",
75
+ "content": "Overlay an alert banner when it's expected to fade in and out without impacting the content underneath it, and when it's not hiding any important actions or information by being there. An alert banner should only overlay content if it is dismissible."
102
76
  },
103
77
  {
104
- "token": "regular-font-weight",
105
- "context": "Text"
78
+ "type": "guideline",
79
+ "content": "Push an alert banner when it's expected to stay in place, when it's not dismissible, or when no information should be hidden from the view."
106
80
  },
107
81
  {
108
- "token": "default-font-style",
109
- "context": "Text"
82
+ "type": "guideline",
83
+ "content": "If a user dismisses an alert banner without addressing an error that needs to be resolved, it should come back into view at the next possible occasion."
110
84
  },
111
85
  {
112
- "token": "font-size-100",
113
- "context": "Text"
86
+ "type": "guideline",
87
+ "content": "Never allow alert banners to time out. Since these are system-level messages, they should not dismiss on their own unless there is a change in the system that resolves an issue (e.g., regaining internet connectivity after losing it)."
114
88
  },
115
89
  {
116
- "token": "line-height-100",
117
- "context": "Text"
90
+ "type": "guideline",
91
+ "content": "When used in the app frame, the alert banner appears above the Top App Bar (TAB) and header, or above the header if the TAB isn’t active."
118
92
  },
119
93
  {
120
- "token": "cjk-line-height-100",
121
- "context": "Text"
94
+ "type": "guideline",
95
+ "content": "Learn more about how the Top App Bar (TAB) works in the app frame."
122
96
  }
123
97
  ],
98
+ "options": {
99
+ "text": { "type": "string" },
100
+ "variant": {
101
+ "type": "string",
102
+ "default": "neutral",
103
+ "values": [
104
+ { "value": "neutral" },
105
+ { "value": "informative" },
106
+ { "value": "negative" },
107
+ { "value": "accent" }
108
+ ]
109
+ },
110
+ "actionLabel": {
111
+ "type": "string",
112
+ "description": "If undefined, this button does not appear."
113
+ },
114
+ "isDismissible": { "type": "boolean", "default": false }
115
+ },
116
+ "lifecycle": { "introduced": "1.0.0-draft" },
117
+ "tokenBindings": [
118
+ { "token": "workflow-icon-size-100", "context": "Icon asset" },
119
+ { "token": "alert-banner-minimum-height", "context": "Height" },
120
+ { "token": "alert-banner-width", "context": "Width" },
121
+ { "token": "text-to-visual-300", "context": "Spacing (icon to text)" },
122
+ {
123
+ "token": "spacing-300",
124
+ "context": "Spacing (start edge to text and icon)"
125
+ },
126
+ { "token": "spacing-100", "context": "Spacing (close button to end edge)" },
127
+ { "token": "spacing-200", "context": "Spacing (close button to end edge)" },
128
+ {
129
+ "token": "alert-banner-top-to-workflow-icon",
130
+ "context": "Spacing (top/bottom edge to icon)"
131
+ },
132
+ {
133
+ "token": "alert-banner-top-to-text",
134
+ "context": "Spacing (top/bottom edge to text)"
135
+ },
136
+ {
137
+ "token": "alert-banner-bottom-to-text",
138
+ "context": "Spacing (top/bottom edge to text)"
139
+ },
140
+ {
141
+ "token": "neutral-subdued-background-color-default",
142
+ "context": "Background"
143
+ },
144
+ {
145
+ "token": "informative-background-color-default",
146
+ "context": "Background"
147
+ },
148
+ { "token": "negative-background-color-default", "context": "Background" },
149
+ { "token": "default-font-family", "context": "Text" },
150
+ { "token": "regular-font-weight", "context": "Text" },
151
+ { "token": "default-font-style", "context": "Text" },
152
+ { "token": "font-size-100", "context": "Text" },
153
+ { "token": "line-height-100", "context": "Text" },
154
+ { "token": "cjk-line-height-100", "context": "Text" }
155
+ ],
124
156
  "accessibility": {
125
157
  "focusable": false,
126
158
  "wcag": [
127
- {
128
- "criterion": "4.1.3",
129
- "level": "AA",
130
- "title": "Status Messages"
131
- }
159
+ { "criterion": "4.1.3", "level": "AA", "title": "Status Messages" }
132
160
  ]
133
161
  }
134
162
  }
@@ -9,155 +9,115 @@
9
9
  "category": "feedback",
10
10
  "documentationUrl": "https://spectrum.adobe.com/page/alert-dialog/"
11
11
  },
12
- "options": {
13
- "title": {
14
- "type": "string"
15
- },
16
- "description": {
17
- "type": "string"
18
- },
19
- "variant": {
20
- "type": "string",
21
- "default": "confirmation",
22
- "values": [
23
- {
24
- "value": "confirmation"
25
- },
26
- {
27
- "value": "information"
28
- },
29
- {
30
- "value": "warning"
31
- },
32
- {
33
- "value": "destructive"
34
- },
35
- {
36
- "value": "error"
37
- }
38
- ]
39
- },
40
- "primaryActionLabel": {
41
- "type": "string"
42
- },
43
- "secondaryActionLabel": {
44
- "type": "string",
45
- "description": "If undefined, this button does not appear."
46
- },
47
- "cancelActionLabel": {
48
- "type": "string",
49
- "default": "cancel",
50
- "description": "If undefined, this button does not appear."
51
- }
52
- },
53
- "lifecycle": {
54
- "introduced": "1.0.0-draft"
55
- },
56
- "tokenBindings": [
57
- {
58
- "token": "heading-sans-serif-font-family",
59
- "context": "Title"
60
- },
12
+ "documentBlocks": [
61
13
  {
62
- "token": "heading-sans-serif-font-weight",
63
- "context": "Title"
14
+ "type": "purpose",
15
+ "content": "Alert dialogs display important information that users need to acknowledge. They appear over the interface and block further interactions until an action is selected."
64
16
  },
65
17
  {
66
- "token": "heading-sans-serif-font-style",
67
- "context": "Title"
18
+ "type": "guideline",
19
+ "content": "Alert dialogs present critical information that must be acknowledged. They appear over the interface and block further interaction until an action is selected."
68
20
  },
69
21
  {
70
- "token": "alert-dialog-title-font-size",
71
- "context": "Title"
22
+ "type": "guideline",
23
+ "content": "By default, an alert dialog that includes a button to cancel or go back will be labeled “Cancel.”"
72
24
  },
73
25
  {
74
- "token": "heading-line-height",
75
- "context": "Title"
26
+ "type": "guideline",
27
+ "content": "Alert dialogs can include up to three buttons if a secondary outline button label is defined. If no label is defined, the button won’t appear. The secondary outline button should use a short, actionable phrase that clearly communicates the result of selecting the action—typically describing the previous step or an alternative choice."
76
28
  },
77
29
  {
78
- "token": "heading-color",
79
- "context": "Title"
30
+ "type": "guideline",
31
+ "content": "An alert dialog must include at least one button. The primary action label refers to the rightmost button in the dialog footer for languages that read left to right. It should use a short, actionable phrase that clearly communicates the result of selecting the action—whether that means moving forward or dismissing the dialog."
80
32
  },
81
33
  {
82
- "token": "body-sans-serif-font-family",
83
- "context": "Description"
34
+ "type": "guideline",
35
+ "content": "Use the appropriate variant based on the context of the message:"
84
36
  },
85
37
  {
86
- "token": "body-sans-serif-font-weight",
87
- "context": "Description"
38
+ "type": "guideline",
39
+ "content": "Alert dialogs should include a description when available. The description briefly communicates any additional information or context a user needs to make a decision based on the options presented."
88
40
  },
89
41
  {
90
- "token": "body-sans-serif-font-style",
91
- "context": "Description"
42
+ "type": "guideline",
43
+ "content": "All alert dialogs must have a title. The title appears at the top of the dialog and uses a few words to convey the outcome of what will happen if a user continues with the primary action."
92
44
  },
93
45
  {
94
- "token": "alert-dialog-body-font-size",
95
- "context": "Description"
46
+ "type": "guideline",
47
+ "content": "When the title and description text are too long for the available horizontal space, they wrap to form another line."
96
48
  },
97
49
  {
98
- "token": "line-height-200",
99
- "context": "Description"
50
+ "type": "guideline",
51
+ "content": "Alert dialogs can include up to three buttons. When horizontal space is limited, the buttons stack vertically. Buttons should be ordered by ascending importance, with the most critical action placed at the end or bottom of the stack."
100
52
  },
101
53
  {
102
- "token": "body-color",
103
- "context": "Description"
54
+ "type": "guideline",
55
+ "content": "Alert dialogs are interruptive, so they should be reserved for important information that users must acknowledge before continuing a task or workflow. Use them only when absolutely necessary—not for low-priority notifications or excessive confirmations."
104
56
  },
105
57
  {
106
- "token": "alert-dialog-maximum-width",
107
- "context": "Maximum width"
108
- },
109
- {
110
- "token": "alert-dialog-minimum-width",
111
- "context": "Minimum width"
112
- },
113
- {
114
- "token": "corner-radius-extra-large-default",
115
- "context": "Rounding"
116
- },
117
- {
118
- "token": "spacing-500",
119
- "context": "Spacing (edge to content)"
58
+ "type": "guideline",
59
+ "content": "Alert dialogs are designed to pause the experience until a decision is made, so only one should appear at a time. Avoid opening an alert dialog from within another. If a situation seems to require a sequence of decisions, consider using a different design pattern."
60
+ }
61
+ ],
62
+ "options": {
63
+ "title": { "type": "string" },
64
+ "description": { "type": "string" },
65
+ "variant": {
66
+ "type": "string",
67
+ "default": "confirmation",
68
+ "values": [
69
+ { "value": "confirmation" },
70
+ { "value": "information" },
71
+ { "value": "warning" },
72
+ { "value": "destructive" },
73
+ { "value": "error" }
74
+ ]
120
75
  },
121
- {
122
- "token": "spacing-400",
123
- "context": "Spacing (edge to content)"
76
+ "primaryActionLabel": { "type": "string" },
77
+ "secondaryActionLabel": {
78
+ "type": "string",
79
+ "description": "If undefined, this button does not appear."
124
80
  },
81
+ "cancelActionLabel": {
82
+ "type": "string",
83
+ "default": "cancel",
84
+ "description": "If undefined, this button does not appear."
85
+ }
86
+ },
87
+ "lifecycle": { "introduced": "1.0.0-draft" },
88
+ "tokenBindings": [
89
+ { "token": "heading-sans-serif-font-family", "context": "Title" },
90
+ { "token": "heading-sans-serif-font-weight", "context": "Title" },
91
+ { "token": "heading-sans-serif-font-style", "context": "Title" },
92
+ { "token": "alert-dialog-title-font-size", "context": "Title" },
93
+ { "token": "heading-line-height", "context": "Title" },
94
+ { "token": "heading-color", "context": "Title" },
95
+ { "token": "body-sans-serif-font-family", "context": "Description" },
96
+ { "token": "body-sans-serif-font-weight", "context": "Description" },
97
+ { "token": "body-sans-serif-font-style", "context": "Description" },
98
+ { "token": "alert-dialog-body-font-size", "context": "Description" },
99
+ { "token": "line-height-200", "context": "Description" },
100
+ { "token": "body-color", "context": "Description" },
101
+ { "token": "alert-dialog-maximum-width", "context": "Maximum width" },
102
+ { "token": "alert-dialog-minimum-width", "context": "Minimum width" },
103
+ { "token": "corner-radius-extra-large-default", "context": "Rounding" },
104
+ { "token": "spacing-500", "context": "Spacing (edge to content)" },
105
+ { "token": "spacing-400", "context": "Spacing (edge to content)" },
125
106
  {
126
107
  "token": "alert-dialog-top-to-alert-icon",
127
108
  "context": "Icon asset (error and warning variants)"
128
109
  },
129
- {
130
- "token": "spacing-300",
131
- "context": "Spacing (title to description)"
132
- },
110
+ { "token": "spacing-300", "context": "Spacing (title to description)" },
133
111
  {
134
112
  "token": "workflow-icon-size-100",
135
113
  "context": "Icon (error and warning variants)"
136
114
  },
137
- {
138
- "token": "spacing-100",
139
- "context": "Minimum spacing (title to icon)"
140
- },
141
- {
142
- "token": "background-color-layer2",
143
- "context": "Background"
144
- },
145
- {
146
- "token": "overlay-color",
147
- "context": "Overlay"
148
- },
149
- {
150
- "token": "overlay-opacity",
151
- "context": "Overlay"
152
- },
153
- {
154
- "token": "notice-visual-color",
155
- "context": "Icon (warning variant)"
156
- },
157
- {
158
- "token": "negative-visual-color",
159
- "context": "Icon (error variant)"
160
- }
115
+ { "token": "spacing-100", "context": "Minimum spacing (title to icon)" },
116
+ { "token": "background-color-layer2", "context": "Background" },
117
+ { "token": "overlay-color", "context": "Overlay" },
118
+ { "token": "overlay-opacity", "context": "Overlay" },
119
+ { "token": "notice-visual-color", "context": "Icon (warning variant)" },
120
+ { "token": "negative-visual-color", "context": "Icon (error variant)" }
161
121
  ],
162
122
  "accessibility": {
163
123
  "role": "dialog",
@@ -165,16 +125,8 @@
165
125
  "focusable": false,
166
126
  "keyboardIntents": ["dismiss"],
167
127
  "wcag": [
168
- {
169
- "criterion": "2.4.3",
170
- "level": "A",
171
- "title": "Focus Order"
172
- },
173
- {
174
- "criterion": "4.1.2",
175
- "level": "A",
176
- "title": "Name, Role, Value"
177
- }
128
+ { "criterion": "2.4.3", "level": "A", "title": "Focus Order" },
129
+ { "criterion": "4.1.2", "level": "A", "title": "Name, Role, Value" }
178
130
  ]
179
131
  }
180
132
  }