@cloudscape-design/components 3.0.1071 → 3.0.1073

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 (157) hide show
  1. package/alert/interfaces.d.ts +0 -16
  2. package/alert/interfaces.d.ts.map +1 -1
  3. package/alert/interfaces.js.map +1 -1
  4. package/alert/styles.css.js +27 -27
  5. package/alert/styles.scoped.css +46 -46
  6. package/alert/styles.selectors.js +27 -27
  7. package/annotation-context/annotation/styles.css.js +24 -24
  8. package/annotation-context/annotation/styles.scoped.css +32 -32
  9. package/annotation-context/annotation/styles.selectors.js +24 -24
  10. package/app-layout/notifications/styles.css.js +3 -3
  11. package/app-layout/notifications/styles.scoped.css +7 -7
  12. package/app-layout/notifications/styles.selectors.js +3 -3
  13. package/app-layout/visual-refresh/styles.css.js +86 -86
  14. package/app-layout/visual-refresh/styles.scoped.css +258 -258
  15. package/app-layout/visual-refresh/styles.selectors.js +86 -86
  16. package/app-layout/visual-refresh-toolbar/drawer/styles.css.js +17 -17
  17. package/app-layout/visual-refresh-toolbar/drawer/styles.scoped.css +39 -39
  18. package/app-layout/visual-refresh-toolbar/drawer/styles.selectors.js +17 -17
  19. package/app-layout/visual-refresh-toolbar/navigation/styles.css.js +4 -4
  20. package/app-layout/visual-refresh-toolbar/navigation/styles.scoped.css +7 -7
  21. package/app-layout/visual-refresh-toolbar/navigation/styles.selectors.js +4 -4
  22. package/app-layout/visual-refresh-toolbar/skeleton/styles.css.js +23 -23
  23. package/app-layout/visual-refresh-toolbar/skeleton/styles.scoped.css +46 -46
  24. package/app-layout/visual-refresh-toolbar/skeleton/styles.selectors.js +23 -23
  25. package/attribute-editor/styles.css.js +15 -15
  26. package/attribute-editor/styles.scoped.css +28 -28
  27. package/attribute-editor/styles.selectors.js +15 -15
  28. package/badge/interfaces.d.ts +0 -9
  29. package/badge/interfaces.d.ts.map +1 -1
  30. package/badge/interfaces.js.map +1 -1
  31. package/breadcrumb-group/item/styles.css.js +7 -7
  32. package/breadcrumb-group/item/styles.scoped.css +28 -28
  33. package/breadcrumb-group/item/styles.selectors.js +7 -7
  34. package/button/interfaces.d.ts +6 -12
  35. package/button/interfaces.d.ts.map +1 -1
  36. package/button/interfaces.js.map +1 -1
  37. package/button/style.d.ts.map +1 -1
  38. package/button/style.js +17 -12
  39. package/button/style.js.map +1 -1
  40. package/button/styles.css.js +22 -22
  41. package/button/styles.scoped.css +256 -212
  42. package/button/styles.selectors.js +22 -22
  43. package/button-dropdown/item-element/styles.css.js +16 -16
  44. package/button-dropdown/item-element/styles.scoped.css +27 -27
  45. package/button-dropdown/item-element/styles.selectors.js +16 -16
  46. package/button-group/index.d.ts.map +1 -1
  47. package/button-group/index.js +11 -44
  48. package/button-group/interfaces.d.ts +41 -1
  49. package/button-group/interfaces.d.ts.map +1 -1
  50. package/button-group/interfaces.js.map +1 -1
  51. package/button-group/internal-do-not-use-core.js +51 -0
  52. package/button-group/internal-do-not-use-core.js.map +1 -0
  53. package/button-group/internal.d.ts.map +1 -1
  54. package/button-group/internal.js +5 -3
  55. package/button-group/internal.js.map +1 -1
  56. package/button-group/item-element.d.ts +1 -0
  57. package/button-group/item-element.d.ts.map +1 -1
  58. package/button-group/item-element.js +4 -2
  59. package/button-group/item-element.js.map +1 -1
  60. package/button-group/style.d.ts +12 -0
  61. package/button-group/style.d.ts.map +1 -0
  62. package/button-group/style.js +37 -0
  63. package/button-group/style.js.map +1 -0
  64. package/checkbox/interfaces.d.ts +0 -1
  65. package/checkbox/interfaces.d.ts.map +1 -1
  66. package/checkbox/interfaces.js.map +1 -1
  67. package/checkbox/styles.css.js +3 -3
  68. package/checkbox/styles.scoped.css +11 -11
  69. package/checkbox/styles.selectors.js +3 -3
  70. package/container/interfaces.d.ts +0 -15
  71. package/container/interfaces.d.ts.map +1 -1
  72. package/container/interfaces.js.map +1 -1
  73. package/content-layout/styles.css.js +14 -14
  74. package/content-layout/styles.scoped.css +27 -27
  75. package/content-layout/styles.selectors.js +14 -14
  76. package/date-range-picker/time-offset.js +3 -3
  77. package/date-range-picker/time-offset.js.map +1 -1
  78. package/flashbar/collapsible-flashbar.d.ts.map +1 -1
  79. package/flashbar/collapsible-flashbar.js +3 -5
  80. package/flashbar/collapsible-flashbar.js.map +1 -1
  81. package/flashbar/common.d.ts.map +1 -1
  82. package/flashbar/common.js +2 -5
  83. package/flashbar/common.js.map +1 -1
  84. package/flashbar/flash.d.ts +1 -1
  85. package/flashbar/flash.d.ts.map +1 -1
  86. package/flashbar/flash.js +4 -2
  87. package/flashbar/flash.js.map +1 -1
  88. package/flashbar/interfaces.d.ts +0 -24
  89. package/flashbar/interfaces.d.ts.map +1 -1
  90. package/flashbar/interfaces.js.map +1 -1
  91. package/flashbar/styles.css.js +50 -50
  92. package/flashbar/styles.scoped.css +187 -187
  93. package/flashbar/styles.selectors.js +50 -50
  94. package/flashbar/utils.d.ts +1 -1
  95. package/flashbar/utils.d.ts.map +1 -1
  96. package/flashbar/utils.js +1 -1
  97. package/flashbar/utils.js.map +1 -1
  98. package/help-panel/styles.css.js +6 -6
  99. package/help-panel/styles.scoped.css +73 -73
  100. package/help-panel/styles.selectors.js +6 -6
  101. package/internal/base-component/styles.scoped.css +1 -1
  102. package/internal/components/drag-handle-wrapper/styles.css.js +21 -21
  103. package/internal/components/drag-handle-wrapper/styles.scoped.css +44 -44
  104. package/internal/components/drag-handle-wrapper/styles.selectors.js +21 -21
  105. package/internal/components/dropdown/styles.css.js +20 -20
  106. package/internal/components/dropdown/styles.scoped.css +38 -38
  107. package/internal/components/dropdown/styles.selectors.js +20 -20
  108. package/internal/components/token-list/styles.css.js +10 -10
  109. package/internal/components/token-list/styles.scoped.css +25 -25
  110. package/internal/components/token-list/styles.selectors.js +10 -10
  111. package/internal/environment.js +2 -2
  112. package/internal/environment.json +2 -2
  113. package/internal/generated/custom-css-properties/index.d.ts +4 -0
  114. package/internal/generated/custom-css-properties/index.d.ts.map +1 -1
  115. package/internal/generated/custom-css-properties/index.js +83 -79
  116. package/internal/generated/custom-css-properties/index.js.map +1 -1
  117. package/internal/manifest.json +1 -1
  118. package/internal/utils/date-time/format-time-offset.d.ts +11 -0
  119. package/internal/utils/date-time/format-time-offset.d.ts.map +1 -1
  120. package/internal/utils/date-time/format-time-offset.js +17 -0
  121. package/internal/utils/date-time/format-time-offset.js.map +1 -1
  122. package/internal/utils/date-time/index.d.ts +1 -1
  123. package/internal/utils/date-time/index.d.ts.map +1 -1
  124. package/internal/utils/date-time/index.js +1 -1
  125. package/internal/utils/date-time/index.js.map +1 -1
  126. package/link/interfaces.d.ts +0 -6
  127. package/link/interfaces.d.ts.map +1 -1
  128. package/link/interfaces.js.map +1 -1
  129. package/link/styles.css.js +20 -20
  130. package/link/styles.scoped.css +103 -103
  131. package/link/styles.selectors.js +20 -20
  132. package/package.json +1 -1
  133. package/radio-group/interfaces.d.ts +0 -1
  134. package/radio-group/interfaces.d.ts.map +1 -1
  135. package/radio-group/interfaces.js.map +1 -1
  136. package/radio-group/styles.css.js +10 -10
  137. package/radio-group/styles.scoped.css +22 -22
  138. package/radio-group/styles.selectors.js +10 -10
  139. package/slider/styles.css.js +26 -26
  140. package/slider/styles.scoped.css +86 -86
  141. package/slider/styles.selectors.js +26 -26
  142. package/spinner/styles.css.js +13 -13
  143. package/spinner/styles.scoped.css +39 -39
  144. package/spinner/styles.selectors.js +13 -13
  145. package/tag-editor/styles.css.js +3 -3
  146. package/tag-editor/styles.scoped.css +13 -13
  147. package/tag-editor/styles.selectors.js +3 -3
  148. package/text-content/styles.css.js +1 -1
  149. package/text-content/styles.scoped.css +66 -66
  150. package/text-content/styles.selectors.js +1 -1
  151. package/toggle/interfaces.d.ts +0 -1
  152. package/toggle/interfaces.d.ts.map +1 -1
  153. package/toggle/interfaces.js.map +1 -1
  154. package/toggle/styles.css.js +10 -10
  155. package/toggle/styles.scoped.css +23 -23
  156. package/toggle/styles.selectors.js +10 -10
  157. package/button-group/index.js.map +0 -1
@@ -142,27 +142,27 @@
142
142
  */
143
143
  /* Style used for links in slots/components that are text heavy, to help links stand out among
144
144
  surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F73#description */
145
- .awsui_link_1kosq_1s9qb_145:not(#\9):after {
145
+ .awsui_link_1kosq_1kaoe_145:not(#\9):after {
146
146
  display: none;
147
147
  }
148
148
 
149
- .awsui_breadcrumb_1kosq_1s9qb_149:not(#\9),
150
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150:not(#\9) {
149
+ .awsui_breadcrumb_1kosq_1kaoe_149:not(#\9),
150
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150:not(#\9) {
151
151
  display: flex;
152
152
  }
153
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_icon_1kosq_1s9qb_153:not(#\9),
154
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_icon_1kosq_1s9qb_153:not(#\9) {
153
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_icon_1kosq_1kaoe_153:not(#\9),
154
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_icon_1kosq_1kaoe_153:not(#\9) {
155
155
  margin-block: 0;
156
156
  margin-inline: var(--space-xs-ymlm0b, 8px);
157
157
  color: var(--color-text-breadcrumb-icon-9j48ot, #8c8c94);
158
158
  }
159
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9),
160
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9) {
159
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9),
160
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9) {
161
161
  min-inline-size: 0;
162
162
  overflow: hidden;
163
163
  text-underline-offset: 0.25em;
164
164
  text-decoration-thickness: 1px;
165
- color: var(--awsui-style-color-default-mdigke, var(--color-text-link-default-1dmm7z, #006ce0));
165
+ color: var(--awsui-style-color-default-kiajpc, var(--color-text-link-default-1dmm7z, #006ce0));
166
166
  font-weight: inherit;
167
167
  letter-spacing: normal;
168
168
  text-decoration-line: underline;
@@ -173,42 +173,42 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
173
173
  transition-duration: var(--motion-duration-refresh-only-medium-5rbn3k, 165ms);
174
174
  }
175
175
  @media (prefers-reduced-motion: reduce) {
176
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9),
177
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9) {
176
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9),
177
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9) {
178
178
  animation: none;
179
179
  transition: none;
180
180
  }
181
181
  }
182
- .awsui-motion-disabled .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9), .awsui-mode-entering .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9), .awsui-motion-disabled .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9), .awsui-mode-entering .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9) {
182
+ .awsui-motion-disabled .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9), .awsui-mode-entering .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9), .awsui-motion-disabled .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9), .awsui-mode-entering .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9) {
183
183
  animation: none;
184
184
  transition: none;
185
185
  }
186
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):hover,
187
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):hover {
186
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):hover,
187
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):hover {
188
188
  cursor: pointer;
189
- color: var(--awsui-style-color-hover-mdigke, var(--color-text-link-hover-sq1gxg, #002b66));
189
+ color: var(--awsui-style-color-hover-kiajpc, var(--color-text-link-hover-sq1gxg, #002b66));
190
190
  }
191
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus,
192
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus {
191
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus,
192
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus {
193
193
  outline: none;
194
194
  }
195
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):active,
196
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):active {
197
- color: var(--awsui-style-color-active-mdigke, var(--color-text-link-hover-sq1gxg, #002b66));
195
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):active,
196
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):active {
197
+ color: var(--awsui-style-color-active-kiajpc, var(--color-text-link-hover-sq1gxg, #002b66));
198
198
  }
199
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):active, .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus, .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):hover, .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):active, .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus, .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):hover {
199
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):active, .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus, .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):hover, .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):active, .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus, .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):hover {
200
200
  text-decoration-line: underline;
201
201
  text-decoration-color: currentColor;
202
202
  }
203
- .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159 > .awsui_text_1kosq_1s9qb_206:not(#\9),
204
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159 > .awsui_text_1kosq_1s9qb_206:not(#\9) {
203
+ .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159 > .awsui_text_1kosq_1kaoe_206:not(#\9),
204
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159 > .awsui_text_1kosq_1kaoe_206:not(#\9) {
205
205
  overflow: hidden;
206
206
  text-overflow: ellipsis;
207
207
  white-space: nowrap;
208
208
  display: block;
209
209
  }
210
- body[data-awsui-focus-visible=true] .awsui_breadcrumb_1kosq_1s9qb_149 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus,
211
- body[data-awsui-focus-visible=true] .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .awsui_anchor_1kosq_1s9qb_159:not(#\9):focus {
210
+ body[data-awsui-focus-visible=true] .awsui_breadcrumb_1kosq_1kaoe_149 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus,
211
+ body[data-awsui-focus-visible=true] .awsui_ghost-breadcrumb_1kosq_1kaoe_150 > .awsui_anchor_1kosq_1kaoe_159:not(#\9):focus {
212
212
  outline: thin dotted;
213
213
  outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
214
214
  outline-offset: 2px;
@@ -219,12 +219,12 @@ body[data-awsui-focus-visible=true] .awsui_ghost-breadcrumb_1kosq_1s9qb_150 > .a
219
219
  border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
220
220
  box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
221
221
  }
222
- .awsui_breadcrumb_1kosq_1s9qb_149.awsui_last_1kosq_1s9qb_225 > .awsui_icon_1kosq_1s9qb_153:not(#\9),
223
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150.awsui_last_1kosq_1s9qb_225 > .awsui_icon_1kosq_1s9qb_153:not(#\9) {
222
+ .awsui_breadcrumb_1kosq_1kaoe_149.awsui_last_1kosq_1kaoe_225 > .awsui_icon_1kosq_1kaoe_153:not(#\9),
223
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150.awsui_last_1kosq_1kaoe_225 > .awsui_icon_1kosq_1kaoe_153:not(#\9) {
224
224
  display: none;
225
225
  }
226
- .awsui_breadcrumb_1kosq_1s9qb_149.awsui_last_1kosq_1s9qb_225 > .awsui_anchor_1kosq_1s9qb_159:not(#\9),
227
- .awsui_ghost-breadcrumb_1kosq_1s9qb_150.awsui_last_1kosq_1s9qb_225 > .awsui_anchor_1kosq_1s9qb_159:not(#\9) {
226
+ .awsui_breadcrumb_1kosq_1kaoe_149.awsui_last_1kosq_1kaoe_225 > .awsui_anchor_1kosq_1kaoe_159:not(#\9),
227
+ .awsui_ghost-breadcrumb_1kosq_1kaoe_150.awsui_last_1kosq_1kaoe_225 > .awsui_anchor_1kosq_1kaoe_159:not(#\9) {
228
228
  color: var(--color-text-breadcrumb-current-2mqnkk, #656871);
229
229
  font-weight: 700;
230
230
  text-decoration: none;
@@ -2,12 +2,12 @@
2
2
  // es-module interop with Babel and Typescript
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  module.exports.default = {
5
- "link": "awsui_link_1kosq_1s9qb_145",
6
- "breadcrumb": "awsui_breadcrumb_1kosq_1s9qb_149",
7
- "ghost-breadcrumb": "awsui_ghost-breadcrumb_1kosq_1s9qb_150",
8
- "icon": "awsui_icon_1kosq_1s9qb_153",
9
- "anchor": "awsui_anchor_1kosq_1s9qb_159",
10
- "text": "awsui_text_1kosq_1s9qb_206",
11
- "last": "awsui_last_1kosq_1s9qb_225"
5
+ "link": "awsui_link_1kosq_1kaoe_145",
6
+ "breadcrumb": "awsui_breadcrumb_1kosq_1kaoe_149",
7
+ "ghost-breadcrumb": "awsui_ghost-breadcrumb_1kosq_1kaoe_150",
8
+ "icon": "awsui_icon_1kosq_1kaoe_153",
9
+ "anchor": "awsui_anchor_1kosq_1kaoe_159",
10
+ "text": "awsui_text_1kosq_1kaoe_206",
11
+ "last": "awsui_last_1kosq_1kaoe_225"
12
12
  };
13
13
 
@@ -181,18 +181,6 @@ export interface ButtonProps extends BaseComponentProps, BaseButtonProps {
181
181
  */
182
182
  iconAlt?: string;
183
183
  /**
184
- * Specifies an object of selectors and properties that are used to apply custom styles.
185
- *
186
- * - `root.background` {active, default, disabled, hover} - (Optional) Background for component states.
187
- * - `root.borderColor` {active, default, disabled, hover} - (Optional) Border color for component states.
188
- * - `root.borderRadius` (string) - (Optional) Border radius style.
189
- * - `root.borderWidth` (string) - (Optional) Border width style.
190
- * - `root.color` {active, default, disabled, hover} - (Optional) Color for component states.
191
- * - `root.focusRing.borderColor` (string) - (Optional) Focus ring border color.
192
- * - `root.focusRing.borderRadius` (string) - (Optional) Focus ring border radius.
193
- * - `root.focusRing.borderWidth` (string) - (Optional) Focus ring border width.
194
- * - `root.paddingBlock` (string) - (Optional) Block dimension padding.
195
- * - `root.paddingInline` (string) - (Optional) Inline dimension padding.
196
184
  * @awsuiSystem core
197
185
  */
198
186
  }
@@ -230,6 +218,12 @@ export declare namespace ButtonProps {
230
218
  };
231
219
  borderRadius?: string;
232
220
  borderWidth?: string;
221
+ boxShadow?: {
222
+ active?: string;
223
+ default?: string;
224
+ disabled?: string;
225
+ hover?: string;
226
+ };
233
227
  color?: {
234
228
  active?: string;
235
229
  default?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/button/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,WAAW,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC/G;;GAEG;AACH,OAAO,EAAE,gBAAgB,EAAE,MAAM,0CAA0C,CAAC;AAE5E,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM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,CAAC,EAAE,MAAM,CAAC;aAChB,CAAC;YACF,WAAW,CAAC,EAAE;gBACZ,MAAM,CAAC,EAAE,MAAM,CAAC;gBAChB,OAAO,CAAC,EAAE,MAAM,CAAC;gBACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;gBAClB,KAAK,CAAC,EAAE,MAAM,CAAC;aAChB,CAAC;YACF,YAAY,CAAC,EAAE,MAAM,CAAC;YACtB,WAAW,CAAC,EAAE,MAAM,CAAC;YACrB,SAAS,CAAC,EAAE;gBACV,MAAM,CAAC,EAAE,MAAM,CAAC;gBAChB,OAAO,CAAC,EAAE,MAAM,CAAC;gBACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;gBAClB,KAAK,CAAC,EAAE,MAAM,CAAC;aAChB,CAAC;YACF,KAAK,CAAC,EAAE;gBACN,MAAM,CAAC,EAAE,MAAM,CAAC;gBAChB,OAAO,CAAC,EAAE,MAAM,CAAC;gBACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;gBAClB,KAAK,CAAC,EAAE,MAAM,CAAC;aAChB,CAAC;YACF,SAAS,CAAC,EAAE;gBACV,WAAW,CAAC,EAAE,MAAM,CAAC;gBACrB,YAAY,CAAC,EAAE,MAAM,CAAC;gBACtB,WAAW,CAAC,EAAE,MAAM,CAAC;aACtB,CAAC;YACF,YAAY,CAAC,EAAE,MAAM,CAAC;YACtB,aAAa,CAAC,EAAE,MAAM,CAAC;SACxB,CAAC;KACH;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../src/button/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\n\nimport { IconProps } from '../icon/interfaces';\nimport { BaseComponentProps } from '../internal/base-component';\nimport { BaseNavigationDetail, CancelableEventHandler, ClickDetail as _ClickDetail } from '../internal/events';\n/**\n * @awsuiSystem core\n */\nimport { NativeAttributes } from '../internal/utils/with-native-attributes';\n\nexport interface BaseButtonProps {\n /**\n * Renders the button as disabled and prevents clicks.\n */\n disabled?: boolean;\n /**\n * Provides a reason why the button is disabled (only when `disabled` is `true`).\n * If provided, the button becomes focusable.\n * Applicable for all button variants, except link.\n */\n disabledReason?: string;\n /**\n * Renders the button as being in a loading state. It takes precedence over the `disabled` if both are set to `true`.\n * It prevents users from clicking the button, but it can still be focused.\n */\n loading?: boolean;\n /**\n * Specifies the text that screen reader announces when the button is in a loading state.\n */\n loadingText?: string;\n /**\n * Displays an icon next to the text. You can use the `iconAlign` property to position the icon.\n */\n iconName?: IconProps.Name;\n /**\n * Specifies the URL of a custom icon. Use this property if the icon you want isn't available.\n *\n * If you set both `iconUrl` and `iconSvg`, `iconSvg` will take precedence.\n */\n iconUrl?: string;\n /**\n * Specifies the SVG of a custom icon.\n *\n * Use this property if you want your custom icon to inherit colors dictated by variant or hover states.\n * When this property is set, the component will be decorated with `aria-hidden=\"true\"`. Ensure that the `svg` element:\n * - has attribute `focusable=\"false\"`.\n * - has `viewBox=\"0 0 16 16\"`.\n *\n * If you set the `svg` element as the root node of the slot, the component will automatically\n * - set `stroke=\"currentColor\"`, `fill=\"none\"`, and `vertical-align=\"top\"`.\n * - set the stroke width based on the size of the icon.\n * - set the width and height of the SVG element based on the size of the icon.\n *\n * If you don't want these styles to be automatically set, wrap the `svg` element into a `span`.\n * You can still set the stroke to `currentColor` to inherit the color of the surrounding elements.\n *\n * If you set both `iconUrl` and `iconSvg`, `iconSvg` will take precedence.\n *\n * *Note:* Remember to remove any additional elements (for example: `defs`) and related CSS classes from SVG files exported from design software.\n * In most cases, they aren't needed, as the `svg` element inherits styles from the icon component.\n */\n iconSvg?: React.ReactNode;\n\n /**\n * Adds `aria-label` to the button element. Use this to provide an accessible name for buttons\n * that don't have visible text, and to distinguish between multiple buttons with identical visible text.\n * The text will also be added to the `title` attribute of the button.\n */\n ariaLabel?: string;\n\n /**\n * Adds `aria-describedby` to the button.\n */\n ariaDescribedby?: string;\n\n /**\n * Specifies if the `text` content wraps. If you set it to `false`, it prevents the text from wrapping.\n */\n wrapText?: boolean;\n\n /**\n * Text displayed in the button element.\n * @displayname text\n */\n children?: React.ReactNode;\n\n /**\n * Adds `aria-controls` to the button. Use when the button controls the contents or presence of an element.\n */\n ariaControls?: string;\n\n /**\n * Adds an external icon after the button label text.\n * If an href is provided, it opens the link in a new tab.\n */\n external?: boolean;\n\n /**\n * An object containing all the necessary localized strings required by the component. The object should contain:\n *\n * * `externalIconAriaLabel` - (optional) Specifies the aria-label for the external icon when `external` is set to `true`.\n * @i18n\n */\n i18nStrings?: ButtonProps.I18nStrings;\n\n /**\n * Attributes to add to the native `button` element.\n * Some attributes will be automatically combined with internal attribute values:\n * - `className` will be appended.\n * - Event handlers will be chained, unless the default is prevented.\n *\n * We do not support using this attribute to apply custom styling.\n *\n * @awsuiSystem core\n */\n nativeButtonAttributes?: NativeAttributes<React.ButtonHTMLAttributes<HTMLButtonElement>>;\n\n /**\n * Attributes to add to the native `a` element (when `href` is provided).\n * Some attributes will be automatically combined with internal attribute values:\n * - `className` will be appended.\n * - Event handlers will be chained, unless the default is prevented.\n *\n * We do not support using this attribute to apply custom styling.\n *\n * @awsuiSystem core\n */\n nativeAnchorAttributes?: NativeAttributes<React.AnchorHTMLAttributes<HTMLAnchorElement>>;\n}\n\nexport interface ButtonProps extends BaseComponentProps, BaseButtonProps {\n /**\n * Specifies the alignment of the icon.\n */\n iconAlign?: ButtonProps.IconAlign;\n\n /**\n * The form action that is performed by a button click.\n */\n formAction?: ButtonProps.FormAction;\n\n /**\n * Applies button styling to a link. Use this property if you need a link styled as a button (`variant=link`).\n * For example, if you have a 'help' button that links to a documentation page.\n */\n href?: string;\n\n /**\n * Specifies where to open the linked URL (for example, to open in a new browser window or tab use `_blank`).\n * This property only applies when an `href` is provided.\n */\n target?: string;\n\n /**\n * Adds a `rel` attribute to the link. By default, the component sets the `rel` attribute to \"noopener noreferrer\" when `target` is `\"_blank\"`.\n * If the `rel` property is provided, it overrides the default behavior.\n */\n rel?: string;\n\n /**\n * Specifies whether the linked URL, when selected, will prompt the user to download instead of navigate.\n * You can specify a string value that will be suggested as the name of the downloaded file.\n * This property only applies when an `href` is provided.\n **/\n download?: boolean | string;\n\n /** The id of the <form> element to associate with the button. The value of this attribute must be the id of a <form> in the same document.\n * Use when a button is not the descendant of a form element, such as when used in a modal.\n */\n form?: string;\n\n /**\n * Adds aria-expanded to the button element. Use when the button controls an expandable element.\n */\n ariaExpanded?: boolean;\n\n /**\n * Called when the user clicks on the button and the button is not disabled or in loading state.\n */\n onClick?: CancelableEventHandler<ButtonProps.ClickDetail>;\n\n /**\n * Called when the user clicks on the button with the left mouse button without pressing\n * modifier keys (that is, CTRL, ALT, SHIFT, META), and the button has an `href` set.\n */\n onFollow?: CancelableEventHandler<ButtonProps.FollowDetail>;\n\n /**\n * Sets the button width to be 100% of the parent container width. Button content is centered.\n */\n fullWidth?: boolean;\n\n /** Determines the general styling of the button as follows:\n * * `primary` for primary buttons.\n * * `normal` for secondary buttons.\n * * `link` for tertiary buttons.\n * * `icon` to display an icon only (no text).\n * * `inline-icon` to display an icon-only (no text) button within a text context.\n * * `inline-link` to display a tertiary button with no outer padding.\n */\n variant?: ButtonProps.Variant;\n\n /**\n * Specifies alternate text for a custom icon. We recommend that you provide this for accessibility.\n * This property is ignored if you use a predefined icon or if you set your custom icon using the `iconSvg` slot.\n */\n iconAlt?: string;\n\n /**\n * Specifies an object of selectors and properties that are used to apply custom styles.\n *\n * - `root.background` {active, default, disabled, hover} - (Optional) Background for component states.\n * - `root.borderColor` {active, default, disabled, hover} - (Optional) Border color for component states.\n * - `root.borderRadius` (string) - (Optional) Border radius style.\n * - `root.borderWidth` (string) - (Optional) Border width style.\n * - `root.color` {active, default, disabled, hover} - (Optional) Color for component states.\n * - `root.focusRing.borderColor` (string) - (Optional) Focus ring border color.\n * - `root.focusRing.borderRadius` (string) - (Optional) Focus ring border radius.\n * - `root.focusRing.borderWidth` (string) - (Optional) Focus ring border width.\n * - `root.paddingBlock` (string) - (Optional) Block dimension padding.\n * - `root.paddingInline` (string) - (Optional) Inline dimension padding.\n * @awsuiSystem core\n */\n style?: ButtonProps.Style;\n}\n\nexport namespace ButtonProps {\n export type Variant = 'normal' | 'primary' | 'link' | 'icon' | 'inline-icon' | 'inline-link';\n export type ClickDetail = _ClickDetail;\n export type FollowDetail = BaseNavigationDetail;\n\n export type FormAction = 'submit' | 'none';\n\n export type IconAlign = 'left' | 'right';\n\n export interface I18nStrings {\n /**\n * Specifies the aria-label for the external icon when `external` is set to `true`.\n */\n externalIconAriaLabel?: string;\n }\n\n export interface Ref {\n /**\n * Focuses the underlying native button.\n */\n focus(options?: FocusOptions): void;\n }\n\n export interface Style {\n root?: {\n background?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n borderColor?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n borderRadius?: string;\n borderWidth?: string;\n color?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n focusRing?: {\n borderColor?: string;\n borderRadius?: string;\n borderWidth?: string;\n };\n paddingBlock?: string;\n paddingInline?: string;\n };\n }\n}\n"]}
1
+ {"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../src/button/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React from 'react';\n\nimport { IconProps } from '../icon/interfaces';\nimport { BaseComponentProps } from '../internal/base-component';\nimport { BaseNavigationDetail, CancelableEventHandler, ClickDetail as _ClickDetail } from '../internal/events';\n/**\n * @awsuiSystem core\n */\nimport { NativeAttributes } from '../internal/utils/with-native-attributes';\n\nexport interface BaseButtonProps {\n /**\n * Renders the button as disabled and prevents clicks.\n */\n disabled?: boolean;\n /**\n * Provides a reason why the button is disabled (only when `disabled` is `true`).\n * If provided, the button becomes focusable.\n * Applicable for all button variants, except link.\n */\n disabledReason?: string;\n /**\n * Renders the button as being in a loading state. It takes precedence over the `disabled` if both are set to `true`.\n * It prevents users from clicking the button, but it can still be focused.\n */\n loading?: boolean;\n /**\n * Specifies the text that screen reader announces when the button is in a loading state.\n */\n loadingText?: string;\n /**\n * Displays an icon next to the text. You can use the `iconAlign` property to position the icon.\n */\n iconName?: IconProps.Name;\n /**\n * Specifies the URL of a custom icon. Use this property if the icon you want isn't available.\n *\n * If you set both `iconUrl` and `iconSvg`, `iconSvg` will take precedence.\n */\n iconUrl?: string;\n /**\n * Specifies the SVG of a custom icon.\n *\n * Use this property if you want your custom icon to inherit colors dictated by variant or hover states.\n * When this property is set, the component will be decorated with `aria-hidden=\"true\"`. Ensure that the `svg` element:\n * - has attribute `focusable=\"false\"`.\n * - has `viewBox=\"0 0 16 16\"`.\n *\n * If you set the `svg` element as the root node of the slot, the component will automatically\n * - set `stroke=\"currentColor\"`, `fill=\"none\"`, and `vertical-align=\"top\"`.\n * - set the stroke width based on the size of the icon.\n * - set the width and height of the SVG element based on the size of the icon.\n *\n * If you don't want these styles to be automatically set, wrap the `svg` element into a `span`.\n * You can still set the stroke to `currentColor` to inherit the color of the surrounding elements.\n *\n * If you set both `iconUrl` and `iconSvg`, `iconSvg` will take precedence.\n *\n * *Note:* Remember to remove any additional elements (for example: `defs`) and related CSS classes from SVG files exported from design software.\n * In most cases, they aren't needed, as the `svg` element inherits styles from the icon component.\n */\n iconSvg?: React.ReactNode;\n\n /**\n * Adds `aria-label` to the button element. Use this to provide an accessible name for buttons\n * that don't have visible text, and to distinguish between multiple buttons with identical visible text.\n * The text will also be added to the `title` attribute of the button.\n */\n ariaLabel?: string;\n\n /**\n * Adds `aria-describedby` to the button.\n */\n ariaDescribedby?: string;\n\n /**\n * Specifies if the `text` content wraps. If you set it to `false`, it prevents the text from wrapping.\n */\n wrapText?: boolean;\n\n /**\n * Text displayed in the button element.\n * @displayname text\n */\n children?: React.ReactNode;\n\n /**\n * Adds `aria-controls` to the button. Use when the button controls the contents or presence of an element.\n */\n ariaControls?: string;\n\n /**\n * Adds an external icon after the button label text.\n * If an href is provided, it opens the link in a new tab.\n */\n external?: boolean;\n\n /**\n * An object containing all the necessary localized strings required by the component. The object should contain:\n *\n * * `externalIconAriaLabel` - (optional) Specifies the aria-label for the external icon when `external` is set to `true`.\n * @i18n\n */\n i18nStrings?: ButtonProps.I18nStrings;\n\n /**\n * Attributes to add to the native `button` element.\n * Some attributes will be automatically combined with internal attribute values:\n * - `className` will be appended.\n * - Event handlers will be chained, unless the default is prevented.\n *\n * We do not support using this attribute to apply custom styling.\n *\n * @awsuiSystem core\n */\n nativeButtonAttributes?: NativeAttributes<React.ButtonHTMLAttributes<HTMLButtonElement>>;\n\n /**\n * Attributes to add to the native `a` element (when `href` is provided).\n * Some attributes will be automatically combined with internal attribute values:\n * - `className` will be appended.\n * - Event handlers will be chained, unless the default is prevented.\n *\n * We do not support using this attribute to apply custom styling.\n *\n * @awsuiSystem core\n */\n nativeAnchorAttributes?: NativeAttributes<React.AnchorHTMLAttributes<HTMLAnchorElement>>;\n}\n\nexport interface ButtonProps extends BaseComponentProps, BaseButtonProps {\n /**\n * Specifies the alignment of the icon.\n */\n iconAlign?: ButtonProps.IconAlign;\n\n /**\n * The form action that is performed by a button click.\n */\n formAction?: ButtonProps.FormAction;\n\n /**\n * Applies button styling to a link. Use this property if you need a link styled as a button (`variant=link`).\n * For example, if you have a 'help' button that links to a documentation page.\n */\n href?: string;\n\n /**\n * Specifies where to open the linked URL (for example, to open in a new browser window or tab use `_blank`).\n * This property only applies when an `href` is provided.\n */\n target?: string;\n\n /**\n * Adds a `rel` attribute to the link. By default, the component sets the `rel` attribute to \"noopener noreferrer\" when `target` is `\"_blank\"`.\n * If the `rel` property is provided, it overrides the default behavior.\n */\n rel?: string;\n\n /**\n * Specifies whether the linked URL, when selected, will prompt the user to download instead of navigate.\n * You can specify a string value that will be suggested as the name of the downloaded file.\n * This property only applies when an `href` is provided.\n **/\n download?: boolean | string;\n\n /** The id of the <form> element to associate with the button. The value of this attribute must be the id of a <form> in the same document.\n * Use when a button is not the descendant of a form element, such as when used in a modal.\n */\n form?: string;\n\n /**\n * Adds aria-expanded to the button element. Use when the button controls an expandable element.\n */\n ariaExpanded?: boolean;\n\n /**\n * Called when the user clicks on the button and the button is not disabled or in loading state.\n */\n onClick?: CancelableEventHandler<ButtonProps.ClickDetail>;\n\n /**\n * Called when the user clicks on the button with the left mouse button without pressing\n * modifier keys (that is, CTRL, ALT, SHIFT, META), and the button has an `href` set.\n */\n onFollow?: CancelableEventHandler<ButtonProps.FollowDetail>;\n\n /**\n * Sets the button width to be 100% of the parent container width. Button content is centered.\n */\n fullWidth?: boolean;\n\n /** Determines the general styling of the button as follows:\n * * `primary` for primary buttons.\n * * `normal` for secondary buttons.\n * * `link` for tertiary buttons.\n * * `icon` to display an icon only (no text).\n * * `inline-icon` to display an icon-only (no text) button within a text context.\n * * `inline-link` to display a tertiary button with no outer padding.\n */\n variant?: ButtonProps.Variant;\n\n /**\n * Specifies alternate text for a custom icon. We recommend that you provide this for accessibility.\n * This property is ignored if you use a predefined icon or if you set your custom icon using the `iconSvg` slot.\n */\n iconAlt?: string;\n\n /**\n * @awsuiSystem core\n */\n style?: ButtonProps.Style;\n}\n\nexport namespace ButtonProps {\n export type Variant = 'normal' | 'primary' | 'link' | 'icon' | 'inline-icon' | 'inline-link';\n export type ClickDetail = _ClickDetail;\n export type FollowDetail = BaseNavigationDetail;\n\n export type FormAction = 'submit' | 'none';\n\n export type IconAlign = 'left' | 'right';\n\n export interface I18nStrings {\n /**\n * Specifies the aria-label for the external icon when `external` is set to `true`.\n */\n externalIconAriaLabel?: string;\n }\n\n export interface Ref {\n /**\n * Focuses the underlying native button.\n */\n focus(options?: FocusOptions): void;\n }\n\n export interface Style {\n root?: {\n background?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n borderColor?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n borderRadius?: string;\n borderWidth?: string;\n boxShadow?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n color?: {\n active?: string;\n default?: string;\n disabled?: string;\n hover?: string;\n };\n focusRing?: {\n borderColor?: string;\n borderRadius?: string;\n borderWidth?: string;\n };\n paddingBlock?: string;\n paddingInline?: string;\n };\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../src/button/style.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,wBAAgB,eAAe,CAAC,KAAK,EAAE,WAAW,CAAC,OAAO,CAAC;;;;;cAqC1D"}
1
+ {"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../src/button/style.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,wBAAgB,eAAe,CAAC,KAAK,EAAE,WAAW,CAAC,OAAO,CAAC;;;;;cA2C1D"}
package/button/style.js CHANGED
@@ -3,11 +3,11 @@
3
3
  import { SYSTEM } from '../internal/environment';
4
4
  import customCssProps from '../internal/generated/custom-css-properties';
5
5
  export function getButtonStyles(style) {
6
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
6
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5;
7
7
  if (SYSTEM !== 'core' || !(style === null || style === void 0 ? void 0 : style.root)) {
8
8
  return undefined;
9
9
  }
10
- return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ borderRadius: (_a = style === null || style === void 0 ? void 0 : style.root) === null || _a === void 0 ? void 0 : _a.borderRadius, borderWidth: (_b = style === null || style === void 0 ? void 0 : style.root) === null || _b === void 0 ? void 0 : _b.borderWidth, paddingBlock: (_c = style === null || style === void 0 ? void 0 : style.root) === null || _c === void 0 ? void 0 : _c.paddingBlock, paddingInline: (_d = style === null || style === void 0 ? void 0 : style.root) === null || _d === void 0 ? void 0 : _d.paddingInline }, (((_e = style === null || style === void 0 ? void 0 : style.root) === null || _e === void 0 ? void 0 : _e.background) && {
10
+ return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ borderRadius: (_a = style === null || style === void 0 ? void 0 : style.root) === null || _a === void 0 ? void 0 : _a.borderRadius, borderWidth: (_b = style === null || style === void 0 ? void 0 : style.root) === null || _b === void 0 ? void 0 : _b.borderWidth, paddingBlock: (_c = style === null || style === void 0 ? void 0 : style.root) === null || _c === void 0 ? void 0 : _c.paddingBlock, paddingInline: (_d = style === null || style === void 0 ? void 0 : style.root) === null || _d === void 0 ? void 0 : _d.paddingInline }, (((_e = style === null || style === void 0 ? void 0 : style.root) === null || _e === void 0 ? void 0 : _e.background) && {
11
11
  [customCssProps.styleBackgroundActive]: (_f = style.root.background) === null || _f === void 0 ? void 0 : _f.active,
12
12
  [customCssProps.styleBackgroundDefault]: (_g = style.root.background) === null || _g === void 0 ? void 0 : _g.default,
13
13
  [customCssProps.styleBackgroundDisabled]: (_h = style.root.background) === null || _h === void 0 ? void 0 : _h.disabled,
@@ -17,16 +17,21 @@ export function getButtonStyles(style) {
17
17
  [customCssProps.styleBorderColorDefault]: (_m = style.root.borderColor) === null || _m === void 0 ? void 0 : _m.default,
18
18
  [customCssProps.styleBorderColorDisabled]: (_o = style.root.borderColor) === null || _o === void 0 ? void 0 : _o.disabled,
19
19
  [customCssProps.styleBorderColorHover]: (_p = style.root.borderColor) === null || _p === void 0 ? void 0 : _p.hover,
20
- })), (((_q = style === null || style === void 0 ? void 0 : style.root) === null || _q === void 0 ? void 0 : _q.color) && {
21
- [customCssProps.styleColorActive]: (_r = style.root.color) === null || _r === void 0 ? void 0 : _r.active,
22
- [customCssProps.styleColorDefault]: (_s = style.root.color) === null || _s === void 0 ? void 0 : _s.default,
23
- [customCssProps.styleColorDisabled]: (_t = style.root.color) === null || _t === void 0 ? void 0 : _t.disabled,
24
- [customCssProps.styleColorHover]: (_u = style.root.color) === null || _u === void 0 ? void 0 : _u.hover,
25
- })), (((_v = style === null || style === void 0 ? void 0 : style.root) === null || _v === void 0 ? void 0 : _v.focusRing) && {
26
- [customCssProps.styleFocusRingBorderColor]: (_w = style.root.focusRing) === null || _w === void 0 ? void 0 : _w.borderColor,
27
- [customCssProps.styleFocusRingBorderRadius]: (_x = style.root.focusRing) === null || _x === void 0 ? void 0 : _x.borderRadius,
28
- [customCssProps.styleFocusRingBorderWidth]: (_y = style.root.focusRing) === null || _y === void 0 ? void 0 : _y.borderWidth,
29
- })), (((_0 = (_z = style === null || style === void 0 ? void 0 : style.root) === null || _z === void 0 ? void 0 : _z.focusRing) === null || _0 === void 0 ? void 0 : _0.borderRadius) && {
20
+ })), (((_q = style === null || style === void 0 ? void 0 : style.root) === null || _q === void 0 ? void 0 : _q.boxShadow) && {
21
+ [customCssProps.styleBoxShadowActive]: (_r = style.root.boxShadow) === null || _r === void 0 ? void 0 : _r.active,
22
+ [customCssProps.styleBoxShadowDefault]: (_s = style.root.boxShadow) === null || _s === void 0 ? void 0 : _s.default,
23
+ [customCssProps.styleBoxShadowDisabled]: (_t = style.root.boxShadow) === null || _t === void 0 ? void 0 : _t.disabled,
24
+ [customCssProps.styleBoxShadowHover]: (_u = style.root.boxShadow) === null || _u === void 0 ? void 0 : _u.hover,
25
+ })), (((_v = style === null || style === void 0 ? void 0 : style.root) === null || _v === void 0 ? void 0 : _v.color) && {
26
+ [customCssProps.styleColorActive]: (_w = style.root.color) === null || _w === void 0 ? void 0 : _w.active,
27
+ [customCssProps.styleColorDefault]: (_x = style.root.color) === null || _x === void 0 ? void 0 : _x.default,
28
+ [customCssProps.styleColorDisabled]: (_y = style.root.color) === null || _y === void 0 ? void 0 : _y.disabled,
29
+ [customCssProps.styleColorHover]: (_z = style.root.color) === null || _z === void 0 ? void 0 : _z.hover,
30
+ })), (((_0 = style === null || style === void 0 ? void 0 : style.root) === null || _0 === void 0 ? void 0 : _0.focusRing) && {
31
+ [customCssProps.styleFocusRingBorderColor]: (_1 = style.root.focusRing) === null || _1 === void 0 ? void 0 : _1.borderColor,
32
+ [customCssProps.styleFocusRingBorderRadius]: (_2 = style.root.focusRing) === null || _2 === void 0 ? void 0 : _2.borderRadius,
33
+ [customCssProps.styleFocusRingBorderWidth]: (_3 = style.root.focusRing) === null || _3 === void 0 ? void 0 : _3.borderWidth,
34
+ })), (((_5 = (_4 = style === null || style === void 0 ? void 0 : style.root) === null || _4 === void 0 ? void 0 : _4.focusRing) === null || _5 === void 0 ? void 0 : _5.borderRadius) && {
30
35
  [customCssProps.styleFocusRingBorderRadius]: style.root.focusRing.borderRadius,
31
36
  }));
32
37
  }
@@ -1 +1 @@
1
- {"version":3,"file":"style.js","sourceRoot":"","sources":["../../../src/button/style.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,cAAc,MAAM,6CAA6C,CAAC;AAGzE,MAAM,UAAU,eAAe,CAAC,KAA2B;;IACzD,IAAI,MAAM,KAAK,MAAM,IAAI,CAAC,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,CAAA,EAAE;QACrC,OAAO,SAAS,CAAC;KAClB;IAED,+EACE,YAAY,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,YAAY,EACvC,WAAW,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,WAAW,EACrC,YAAY,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,YAAY,EACvC,aAAa,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,aAAa,IACtC,CAAC,CAAA,MAAA,KAAK,a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AC,EAAE,MAAA,KAAK,CAAC,IAAI,CAAC,KAAK,0CAAE,QAAQ;QAC/D,CAAC,cAAc,CAAC,eAAe,CAAC,EAAE,MAAA,KAAK,CAAC,IAAI,CAAC,KAAK,0CAAE,KAAK;KAC1D,CAAC,GACC,CAAC,CAAA,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,SAAS,KAAI;QAC5B,CAAC,cAAc,CAAC,yBAAyB,CAAC,EAAE,MAAA,KAAK,CAAC,IAAI,CAAC,SAAS,0CAAE,WAAW;QAC7E,CAAC,cAAc,CAAC,0BAA0B,CAAC,EAAE,MAAA,KAAK,CAAC,IAAI,CAAC,SAAS,0CAAE,YAAY;QAC/E,CAAC,cAAc,CAAC,yBAAyB,CAAC,EAAE,MAAA,KAAK,CAAC,IAAI,CAAC,SAAS,0CAAE,WAAW;KAC9E,CAAC,GACC,CAAC,CAAA,MAAA,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,SAAS,0CAAE,YAAY,KAAI;QAC1C,CAAC,cAAc,CAAC,0BAA0B,CAAC,EAAE,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY;KAC/E,CAAC,EACF;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { SYSTEM } from '../internal/environment';\nimport customCssProps from '../internal/generated/custom-css-properties';\nimport { ButtonProps } from './interfaces';\n\nexport function getButtonStyles(style: ButtonProps['style']) {\n if (SYSTEM !== 'core' || !style?.root) {\n return undefined;\n }\n\n return {\n borderRadius: style?.root?.borderRadius,\n borderWidth: style?.root?.borderWidth,\n paddingBlock: style?.root?.paddingBlock,\n paddingInline: style?.root?.paddingInline,\n ...(style?.root?.background && {\n [customCssProps.styleBackgroundActive]: style.root.background?.active,\n [customCssProps.styleBackgroundDefault]: style.root.background?.default,\n [customCssProps.styleBackgroundDisabled]: style.root.background?.disabled,\n [customCssProps.styleBackgroundHover]: style.root.background?.hover,\n }),\n ...(style?.root?.borderColor && {\n [customCssProps.styleBorderColorActive]: style.root.borderColor?.active,\n [customCssProps.styleBorderColorDefault]: style.root.borderColor?.default,\n [customCssProps.styleBorderColorDisabled]: style.root.borderColor?.disabled,\n [customCssProps.styleBorderColorHover]: style.root.borderColor?.hover,\n }),\n ...(style?.root?.color && {\n [customCssProps.styleColorActive]: style.root.color?.active,\n [customCssProps.styleColorDefault]: style.root.color?.default,\n [customCssProps.styleColorDisabled]: style.root.color?.disabled,\n [customCssProps.styleColorHover]: style.root.color?.hover,\n }),\n ...(style?.root?.focusRing && {\n [customCssProps.styleFocusRingBorderColor]: style.root.focusRing?.borderColor,\n [customCssProps.styleFocusRingBorderRadius]: style.root.focusRing?.borderRadius,\n [customCssProps.styleFocusRingBorderWidth]: style.root.focusRing?.borderWidth,\n }),\n ...(style?.root?.focusRing?.borderRadius && {\n [customCssProps.styleFocusRingBorderRadius]: style.root.focusRing.borderRadius,\n }),\n };\n}\n"]}
1
+ {"version":3,"file":"style.js","sourceRoot":"","sources":["../../../src/button/style.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACjD,OAAO,cAAc,MAAM,6CAA6C,CAAC;AAGzE,MAAM,UAAU,eAAe,CAAC,KAA2B;;IACzD,IAAI,MAAM,KAAK,MAAM,IAAI,CAAC,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,CAAA,EAAE;QACrC,OAAO,SAAS,CAAC;KAClB;IAED,6FACE,YAAY,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,YAAY,EACvC,WAAW,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,0CAAE,WAAW,EACrC,YAAY,EAAE,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,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AE,SAAS,0CAAE,YAAY,KAAI;QAC1C,CAAC,cAAc,CAAC,0BAA0B,CAAC,EAAE,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY;KAC/E,CAAC,EACF;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { SYSTEM } from '../internal/environment';\nimport customCssProps from '../internal/generated/custom-css-properties';\nimport { ButtonProps } from './interfaces';\n\nexport function getButtonStyles(style: ButtonProps['style']) {\n if (SYSTEM !== 'core' || !style?.root) {\n return undefined;\n }\n\n return {\n borderRadius: style?.root?.borderRadius,\n borderWidth: style?.root?.borderWidth,\n paddingBlock: style?.root?.paddingBlock,\n paddingInline: style?.root?.paddingInline,\n ...(style?.root?.background && {\n [customCssProps.styleBackgroundActive]: style.root.background?.active,\n [customCssProps.styleBackgroundDefault]: style.root.background?.default,\n [customCssProps.styleBackgroundDisabled]: style.root.background?.disabled,\n [customCssProps.styleBackgroundHover]: style.root.background?.hover,\n }),\n ...(style?.root?.borderColor && {\n [customCssProps.styleBorderColorActive]: style.root.borderColor?.active,\n [customCssProps.styleBorderColorDefault]: style.root.borderColor?.default,\n [customCssProps.styleBorderColorDisabled]: style.root.borderColor?.disabled,\n [customCssProps.styleBorderColorHover]: style.root.borderColor?.hover,\n }),\n ...(style?.root?.boxShadow && {\n [customCssProps.styleBoxShadowActive]: style.root.boxShadow?.active,\n [customCssProps.styleBoxShadowDefault]: style.root.boxShadow?.default,\n [customCssProps.styleBoxShadowDisabled]: style.root.boxShadow?.disabled,\n [customCssProps.styleBoxShadowHover]: style.root.boxShadow?.hover,\n }),\n ...(style?.root?.color && {\n [customCssProps.styleColorActive]: style.root.color?.active,\n [customCssProps.styleColorDefault]: style.root.color?.default,\n [customCssProps.styleColorDisabled]: style.root.color?.disabled,\n [customCssProps.styleColorHover]: style.root.color?.hover,\n }),\n ...(style?.root?.focusRing && {\n [customCssProps.styleFocusRingBorderColor]: style.root.focusRing?.borderColor,\n [customCssProps.styleFocusRingBorderRadius]: style.root.focusRing?.borderRadius,\n [customCssProps.styleFocusRingBorderWidth]: style.root.focusRing?.borderWidth,\n }),\n ...(style?.root?.focusRing?.borderRadius && {\n [customCssProps.styleFocusRingBorderRadius]: style.root.focusRing.borderRadius,\n }),\n };\n}\n"]}
@@ -1,27 +1,27 @@
1
1
 
2
2
  import './styles.scoped.css';
3
3
  export default {
4
- "content": "awsui_content_vjswe_18qm7_153",
5
- "button": "awsui_button_vjswe_18qm7_157",
6
- "variant-normal": "awsui_variant-normal_vjswe_18qm7_206",
7
- "disabled": "awsui_disabled_vjswe_18qm7_224",
8
- "variant-primary": "awsui_variant-primary_vjswe_18qm7_231",
9
- "variant-link": "awsui_variant-link_vjswe_18qm7_256",
10
- "variant-icon": "awsui_variant-icon_vjswe_18qm7_281",
11
- "variant-inline-icon": "awsui_variant-inline-icon_vjswe_18qm7_306",
12
- "variant-inline-icon-pointer-target": "awsui_variant-inline-icon-pointer-target_vjswe_18qm7_331",
13
- "variant-inline-link": "awsui_variant-inline-link_vjswe_18qm7_356",
14
- "variant-modal-dismiss": "awsui_variant-modal-dismiss_vjswe_18qm7_385",
15
- "variant-flashbar-icon": "awsui_variant-flashbar-icon_vjswe_18qm7_410",
16
- "variant-breadcrumb-group": "awsui_variant-breadcrumb-group_vjswe_18qm7_435",
17
- "variant-menu-trigger": "awsui_variant-menu-trigger_vjswe_18qm7_465",
18
- "button-no-text": "awsui_button-no-text_vjswe_18qm7_557",
19
- "button-no-wrap": "awsui_button-no-wrap_vjswe_18qm7_561",
20
- "full-width": "awsui_full-width_vjswe_18qm7_564",
21
- "icon-left": "awsui_icon-left_vjswe_18qm7_586",
22
- "icon-right": "awsui_icon-right_vjswe_18qm7_591",
23
- "icon": "awsui_icon_vjswe_18qm7_586",
24
- "link": "awsui_link_vjswe_18qm7_610",
25
- "disabled-with-reason": "awsui_disabled-with-reason_vjswe_18qm7_610"
4
+ "content": "awsui_content_vjswe_1copn_153",
5
+ "button": "awsui_button_vjswe_1copn_157",
6
+ "variant-normal": "awsui_variant-normal_vjswe_1copn_206",
7
+ "disabled": "awsui_disabled_vjswe_1copn_227",
8
+ "variant-primary": "awsui_variant-primary_vjswe_1copn_235",
9
+ "variant-link": "awsui_variant-link_vjswe_1copn_264",
10
+ "variant-icon": "awsui_variant-icon_vjswe_1copn_293",
11
+ "variant-inline-icon": "awsui_variant-inline-icon_vjswe_1copn_322",
12
+ "variant-inline-icon-pointer-target": "awsui_variant-inline-icon-pointer-target_vjswe_1copn_351",
13
+ "variant-inline-link": "awsui_variant-inline-link_vjswe_1copn_380",
14
+ "variant-modal-dismiss": "awsui_variant-modal-dismiss_vjswe_1copn_413",
15
+ "variant-flashbar-icon": "awsui_variant-flashbar-icon_vjswe_1copn_442",
16
+ "variant-breadcrumb-group": "awsui_variant-breadcrumb-group_vjswe_1copn_471",
17
+ "variant-menu-trigger": "awsui_variant-menu-trigger_vjswe_1copn_505",
18
+ "button-no-text": "awsui_button-no-text_vjswe_1copn_601",
19
+ "button-no-wrap": "awsui_button-no-wrap_vjswe_1copn_605",
20
+ "full-width": "awsui_full-width_vjswe_1copn_608",
21
+ "icon-left": "awsui_icon-left_vjswe_1copn_630",
22
+ "icon-right": "awsui_icon-right_vjswe_1copn_635",
23
+ "icon": "awsui_icon_vjswe_1copn_630",
24
+ "link": "awsui_link_vjswe_1copn_654",
25
+ "disabled-with-reason": "awsui_disabled-with-reason_vjswe_1copn_654"
26
26
  };
27
27