@cloudscape-design/components 3.0.1303 → 3.0.1305

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 (123) hide show
  1. package/app-layout/visual-refresh-toolbar/skeleton/styles.css.js +29 -27
  2. package/app-layout/visual-refresh-toolbar/skeleton/styles.scoped.css +115 -46
  3. package/app-layout/visual-refresh-toolbar/skeleton/styles.selectors.js +29 -27
  4. package/app-layout/visual-refresh-toolbar/state/props-merger.js +3 -3
  5. package/app-layout/visual-refresh-toolbar/state/props-merger.js.map +1 -1
  6. package/app-layout/visual-refresh-toolbar/state/use-app-layout.d.ts.map +1 -1
  7. package/app-layout/visual-refresh-toolbar/state/use-app-layout.js +2 -1
  8. package/app-layout/visual-refresh-toolbar/state/use-app-layout.js.map +1 -1
  9. package/app-layout/visual-refresh-toolbar/widget-areas/before-main-slot.d.ts.map +1 -1
  10. package/app-layout/visual-refresh-toolbar/widget-areas/before-main-slot.js +5 -0
  11. package/app-layout/visual-refresh-toolbar/widget-areas/before-main-slot.js.map +1 -1
  12. package/calendar/styles.css.js +21 -21
  13. package/calendar/styles.scoped.css +44 -44
  14. package/calendar/styles.selectors.js +21 -21
  15. package/collection-preferences/content-display/index.d.ts.map +1 -1
  16. package/collection-preferences/content-display/index.js +1 -1
  17. package/collection-preferences/content-display/index.js.map +1 -1
  18. package/container/interfaces.d.ts +0 -1
  19. package/container/interfaces.d.ts.map +1 -1
  20. package/container/interfaces.js.map +1 -1
  21. package/date-range-picker/calendar/grids/styles.css.js +30 -30
  22. package/date-range-picker/calendar/grids/styles.scoped.css +56 -56
  23. package/date-range-picker/calendar/grids/styles.selectors.js +30 -30
  24. package/dropdown/index.d.ts +0 -3
  25. package/dropdown/index.d.ts.map +1 -1
  26. package/dropdown/index.js +0 -3
  27. package/dropdown/index.js.map +1 -1
  28. package/i18n/messages/all.all.js +1 -1
  29. package/i18n/messages/all.all.json +1 -1
  30. package/i18n/messages/all.ar.js +1 -1
  31. package/i18n/messages/all.ar.json +1 -1
  32. package/i18n/messages/all.de.js +1 -1
  33. package/i18n/messages/all.de.json +1 -1
  34. package/i18n/messages/all.en-GB.js +1 -1
  35. package/i18n/messages/all.en-GB.json +1 -1
  36. package/i18n/messages/all.en.js +1 -1
  37. package/i18n/messages/all.en.json +1 -1
  38. package/i18n/messages/all.es.js +1 -1
  39. package/i18n/messages/all.es.json +1 -1
  40. package/i18n/messages/all.fr.js +1 -1
  41. package/i18n/messages/all.fr.json +1 -1
  42. package/i18n/messages/all.id.js +1 -1
  43. package/i18n/messages/all.id.json +1 -1
  44. package/i18n/messages/all.it.js +1 -1
  45. package/i18n/messages/all.it.json +1 -1
  46. package/i18n/messages/all.ja.js +1 -1
  47. package/i18n/messages/all.ja.json +1 -1
  48. package/i18n/messages/all.ko.js +1 -1
  49. package/i18n/messages/all.ko.json +1 -1
  50. package/i18n/messages/all.pt-BR.js +1 -1
  51. package/i18n/messages/all.pt-BR.json +1 -1
  52. package/i18n/messages/all.zh-CN.js +1 -1
  53. package/i18n/messages/all.zh-CN.json +1 -1
  54. package/i18n/messages/all.zh-TW.js +1 -1
  55. package/i18n/messages/all.zh-TW.json +1 -1
  56. package/icon-provider/index.d.ts +0 -3
  57. package/icon-provider/index.d.ts.map +1 -1
  58. package/icon-provider/index.js +0 -3
  59. package/icon-provider/index.js.map +1 -1
  60. package/index.d.ts +1 -0
  61. package/index.d.ts.map +1 -1
  62. package/index.js +1 -0
  63. package/index.js.map +1 -1
  64. package/internal/base-component/styles.scoped.css +13 -2
  65. package/internal/components/drag-handle/button.d.ts.map +1 -1
  66. package/internal/components/drag-handle/button.js +1 -1
  67. package/internal/components/drag-handle/button.js.map +1 -1
  68. package/internal/components/sortable-area/index.d.ts.map +1 -1
  69. package/internal/components/sortable-area/index.js +1 -0
  70. package/internal/components/sortable-area/index.js.map +1 -1
  71. package/internal/environment.d.ts +2 -1
  72. package/internal/environment.js +4 -3
  73. package/internal/environment.json +4 -3
  74. package/internal/generated/styles/tokens.d.ts +2 -0
  75. package/internal/generated/styles/tokens.js +2 -0
  76. package/internal/generated/theming/index.cjs +68 -0
  77. package/internal/generated/theming/index.cjs.d.ts +27 -0
  78. package/internal/generated/theming/index.d.ts +27 -0
  79. package/internal/generated/theming/index.js +68 -0
  80. package/internal/manifest.json +1 -1
  81. package/manifest.json +2 -2
  82. package/navigable-group/index.d.ts +0 -3
  83. package/navigable-group/index.d.ts.map +1 -1
  84. package/navigable-group/index.js +0 -3
  85. package/navigable-group/index.js.map +1 -1
  86. package/package.json +2 -1
  87. package/radio-button/index.d.ts +0 -3
  88. package/radio-button/index.d.ts.map +1 -1
  89. package/radio-button/index.js +0 -3
  90. package/radio-button/index.js.map +1 -1
  91. package/test-utils/dom/index.d.ts +28 -0
  92. package/test-utils/dom/index.js +20 -1
  93. package/test-utils/dom/index.js.map +1 -1
  94. package/test-utils/dom/truncated-text/index.d.ts +6 -0
  95. package/test-utils/dom/truncated-text/index.js +17 -0
  96. package/test-utils/dom/truncated-text/index.js.map +1 -0
  97. package/test-utils/selectors/index.d.ts +18 -0
  98. package/test-utils/selectors/index.js +15 -1
  99. package/test-utils/selectors/index.js.map +1 -1
  100. package/test-utils/selectors/truncated-text/index.d.ts +6 -0
  101. package/test-utils/selectors/truncated-text/index.js +17 -0
  102. package/test-utils/selectors/truncated-text/index.js.map +1 -0
  103. package/toggle-button/styles.css.js +3 -3
  104. package/toggle-button/styles.scoped.css +6 -2
  105. package/toggle-button/styles.selectors.js +3 -3
  106. package/truncated-text/index.d.ts +7 -0
  107. package/truncated-text/index.d.ts.map +1 -0
  108. package/truncated-text/index.js +18 -0
  109. package/truncated-text/index.js.map +1 -0
  110. package/truncated-text/interfaces.d.ts +16 -0
  111. package/truncated-text/interfaces.d.ts.map +1 -0
  112. package/truncated-text/interfaces.js +2 -0
  113. package/truncated-text/interfaces.js.map +1 -0
  114. package/truncated-text/internal.d.ts +10 -0
  115. package/truncated-text/internal.d.ts.map +1 -0
  116. package/truncated-text/internal.js +47 -0
  117. package/truncated-text/internal.js.map +1 -0
  118. package/truncated-text/styles.css.js +6 -0
  119. package/truncated-text/styles.scoped.css +177 -0
  120. package/truncated-text/styles.selectors.js +7 -0
  121. package/truncated-text/test-classes/styles.css.js +6 -0
  122. package/truncated-text/test-classes/styles.scoped.css +7 -0
  123. package/truncated-text/test-classes/styles.selectors.js +7 -0
@@ -6,7 +6,7 @@
6
6
  Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
7
7
  SPDX-License-Identifier: Apache-2.0
8
8
  */
9
- @layer cloudscape-base-theme {
9
+ @layer awsui-base-theme {
10
10
  body {
11
11
  --color-primary-50-1y05xv:#f0fbff;
12
12
  --color-primary-100-f62fz9:#d1f1ff;
@@ -248,6 +248,7 @@
248
248
  --color-background-button-normal-disabled-hl039l:var(--color-white-p1zlvy);
249
249
  --color-background-button-normal-hover-53op9s:var(--color-primary-50-1y05xv);
250
250
  --color-background-toggle-button-normal-pressed-4khex7:var(--color-primary-100-f62fz9);
251
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
251
252
  --color-background-button-primary-active-5cqoqt:var(--color-primary-900-a5kqrr);
252
253
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
253
254
  --color-background-button-primary-disabled-sgo4zo:var(--color-neutral-250-vs1is4);
@@ -446,6 +447,7 @@
446
447
  --color-text-button-primary-default-mwl31m:var(--color-white-p1zlvy);
447
448
  --color-text-button-primary-hover-pw12ep:var(--color-white-p1zlvy);
448
449
  --color-text-calendar-date-hover-3fcriv:var(--color-text-dropdown-item-default-f1jr9u);
450
+ --color-text-calendar-date-selected-m18pgv:var(--color-background-control-default-4jb21l);
449
451
  --color-text-calendar-month-ea0e93:var(--color-neutral-600-fln1ww);
450
452
  --color-text-code-editor-gutter-active-line-2addhd:var(--color-white-p1zlvy);
451
453
  --color-text-code-editor-gutter-default-nlshs8:var(--color-neutral-950-lxybh8);
@@ -1434,6 +1436,7 @@
1434
1436
  --color-icon-action-card-disabled-wm3kyf:var(--color-neutral-600-fln1ww);
1435
1437
  --color-background-skeleton-sjxg4n:var(--color-neutral-750-pi9qqd);
1436
1438
  --color-background-skeleton-wave-1dy97d:var(--color-neutral-700-qw8ats);
1439
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
1437
1440
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
1438
1441
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
1439
1442
  --color-text-direction-button-disabled-2jds36:var(--color-text-interactive-disabled-1bqmrl);
@@ -1505,6 +1508,7 @@
1505
1508
  --color-text-button-link-disabled-12wh7a:var(--color-text-interactive-disabled-1bqmrl);
1506
1509
  --color-text-button-link-hover-kvrc36:var(--color-text-button-normal-hover-gusgyv);
1507
1510
  --color-text-calendar-date-hover-3fcriv:var(--color-text-dropdown-item-default-f1jr9u);
1511
+ --color-text-calendar-date-selected-m18pgv:var(--color-background-control-default-4jb21l);
1508
1512
  --color-text-column-sorting-icon-fngn77:var(--color-text-column-header-e6urd1);
1509
1513
  --color-text-control-disabled-upk9lz:var(--color-text-interactive-disabled-1bqmrl);
1510
1514
  --color-text-dropdown-footer-umcot2:var(--color-text-form-secondary-1nm780);
@@ -1709,6 +1713,7 @@
1709
1713
  --shadow-sticky-embedded-jmny8n:0px 2px 0px 0px #414d5c, 0px 16px 16px -12px rgba(0, 7, 22, 1);
1710
1714
  --shadow-sticky-column-first-trcd2o:0px 4px 8px 1px rgba(0, 7, 22, 0.5);
1711
1715
  --shadow-sticky-column-last-qgh697:0px 4px 8px 1px rgba(0, 7, 22, 0.5);
1716
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
1712
1717
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
1713
1718
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
1714
1719
  --color-text-direction-button-disabled-2jds36:var(--color-text-interactive-disabled-1bqmrl);
@@ -1776,6 +1781,7 @@
1776
1781
  --color-text-button-link-disabled-12wh7a:var(--color-text-interactive-disabled-1bqmrl);
1777
1782
  --color-text-button-link-hover-kvrc36:var(--color-text-button-normal-hover-gusgyv);
1778
1783
  --color-text-calendar-date-hover-3fcriv:var(--color-text-dropdown-item-default-f1jr9u);
1784
+ --color-text-calendar-date-selected-m18pgv:var(--color-background-control-default-4jb21l);
1779
1785
  --color-text-column-sorting-icon-fngn77:var(--color-text-column-header-e6urd1);
1780
1786
  --color-text-control-disabled-upk9lz:var(--color-text-interactive-disabled-1bqmrl);
1781
1787
  --color-text-dropdown-footer-umcot2:var(--color-text-form-secondary-1nm780);
@@ -1826,6 +1832,7 @@
1826
1832
  --color-text-link-hover-2hfec2:var(--color-white-p1zlvy);
1827
1833
  --color-text-tutorial-hotspot-default-xfv3ow:var(--color-neutral-300-08wi6k);
1828
1834
  --color-text-tutorial-hotspot-hover-92pxog:var(--color-neutral-100-gk3lvf);
1835
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
1829
1836
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
1830
1837
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
1831
1838
  --color-background-segment-default-b0r494:var(--color-background-button-normal-default-7f99mv);
@@ -1886,6 +1893,7 @@
1886
1893
  --color-text-notification-default-1iey72:var(--color-text-notification-yellow-vjtdxk);
1887
1894
  --color-text-tutorial-hotspot-default-xfv3ow:var(--color-neutral-600-fln1ww);
1888
1895
  --color-text-tutorial-hotspot-hover-92pxog:var(--color-neutral-900-v0mtoc);
1896
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
1889
1897
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
1890
1898
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
1891
1899
  --color-background-segment-default-b0r494:var(--color-background-button-normal-default-7f99mv);
@@ -1930,6 +1938,7 @@
1930
1938
  --color-text-expandable-section-default-ynw8my:var(--color-text-button-normal-default-nzalii);
1931
1939
  --color-text-expandable-section-hover-ojzwhd:var(--color-text-button-normal-hover-gusgyv);
1932
1940
  --font-expandable-heading-size-0uk059:14px;
1941
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
1933
1942
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
1934
1943
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
1935
1944
  --color-background-segment-default-b0r494:var(--color-background-button-normal-default-7f99mv);
@@ -2121,6 +2130,7 @@
2121
2130
  --color-icon-action-card-disabled-wm3kyf:var(--color-neutral-600-fln1ww);
2122
2131
  --color-background-skeleton-sjxg4n:var(--color-neutral-750-pi9qqd);
2123
2132
  --color-background-skeleton-wave-1dy97d:var(--color-neutral-700-qw8ats);
2133
+ --color-background-toggle-button-normal-default-ipnqr5:var(--color-background-button-normal-default-7f99mv);
2124
2134
  --color-background-button-primary-default-vdt0fu:var(--color-border-button-normal-default-glqfp1);
2125
2135
  --color-background-button-primary-hover-mo85i6:var(--color-border-button-normal-hover-6a2tdq);
2126
2136
  --color-text-direction-button-disabled-2jds36:var(--color-text-interactive-disabled-1bqmrl);
@@ -2190,6 +2200,7 @@
2190
2200
  --color-text-button-link-disabled-12wh7a:var(--color-text-interactive-disabled-1bqmrl);
2191
2201
  --color-text-button-link-hover-kvrc36:var(--color-text-button-normal-hover-gusgyv);
2192
2202
  --color-text-calendar-date-hover-3fcriv:var(--color-text-dropdown-item-default-f1jr9u);
2203
+ --color-text-calendar-date-selected-m18pgv:var(--color-background-control-default-4jb21l);
2193
2204
  --color-text-column-sorting-icon-fngn77:var(--color-text-column-header-e6urd1);
2194
2205
  --color-text-control-disabled-upk9lz:var(--color-text-interactive-disabled-1bqmrl);
2195
2206
  --color-text-dropdown-footer-umcot2:var(--color-text-form-secondary-1nm780);
@@ -2280,5 +2291,5 @@
2280
2291
  }
2281
2292
  }
2282
2293
  :root {
2283
- --awsui-version-info-d6bd1774: true;
2294
+ --awsui-version-info-5325301e: true;
2284
2295
  }
@@ -1 +1 @@
1
- {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/drag-handle/button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAOlD,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAM/C,QAAA,MAAM,gBAAgB,kaA0ErB,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/drag-handle/button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAOlD,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAM/C,QAAA,MAAM,gBAAgB,kaA2ErB,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
@@ -31,7 +31,7 @@ const DragHandleButton = forwardRef(({ variant = 'drag-indicator', size = 'norma
31
31
  // (See https://bugs.webkit.org/show_bug.cgi?id=22261)
32
32
  // Otherwise, we can't reliably catch keyboard events coming from the handle
33
33
  // when it is being dragged.
34
- React.createElement("div", { ref: useMergeRefs(ref, dragHandleRefObject), role: ariaValue ? 'slider' : 'application', tabIndex: 0, className: clsx(className, styles.handle, testUtilsStyles.root, styles[`handle-${variant}`], styles[`handle-size-${size}`], disabled && styles['handle-disabled'], active && styles.active), "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedby, "aria-disabled": disabled, "aria-valuemax": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueMax, "aria-valuemin": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueMin, "aria-valuenow": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueNow, onPointerDown: onPointerDown, onClick: onClick, onKeyDown: onKeyDown },
34
+ React.createElement("div", { ref: useMergeRefs(ref, dragHandleRefObject), role: ariaValue ? 'slider' : 'button', tabIndex: 0, className: clsx(className, styles.handle, testUtilsStyles.root, styles[`handle-${variant}`], styles[`handle-size-${size}`], disabled && styles['handle-disabled'], active && styles.active), "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedby, "aria-disabled": disabled, "aria-pressed": ariaValue ? undefined : active, "aria-valuemax": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueMax, "aria-valuemin": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueMin, "aria-valuenow": ariaValue === null || ariaValue === void 0 ? void 0 : ariaValue.valueNow, onPointerDown: onPointerDown, onClick: onClick, onKeyDown: onKeyDown },
35
35
  React.createElement("div", { className: styles['prevent-pointer'] },
36
36
  React.createElement(InternalIcon, { ...iconProps }))));
37
37
  });
@@ -1 +1 @@
1
- {"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../../src/internal/components/drag-handle/button.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,+CAA+C,CAAC;AAG7E,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAElD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,eAAe,MAAM,8BAA8B,CAAC;AAE3D,MAAM,gBAAgB,GAAG,UAAU,CACjC,CACE,EACE,OAAO,GAAG,gBAAgB,EAC1B,IAAI,GAAG,QAAQ,EACf,MAAM,GAAG,KAAK,EACd,SAAS,EACT,SAAS,EACT,cAAc,EACd,eAAe,EACf,SAAS,EACT,QAA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,iBAAiB,CAAC,EACrC,MAAM,IAAI,MAAM,CAAC,MAAM,CACxB,gBACW,SAAS,qBACJ,cAAc,sBACb,eAAe,mBAClB,QAAQ,mBACR,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,mBACnB,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,mBACnB,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,EAClC,aAAa,EAAE,aAAa,EAC5B,OAAO,EAAE,OAAO,EAChB,SAAS,EAAE,SAAS;QAGpB,6BAAK,SAAS,EAAE,MAAM,CAAC,iBAAiB,CAAC;YACvC,oBAAC,YAAY,OAAK,SAAS,GAAI,CAC3B,CACF,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,gBAAgB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { forwardRef, useRef } from 'react';\nimport clsx from 'clsx';\n\nimport { useMergeRefs } from '@cloudscape-design/component-toolkit/internal';\n\nimport { IconProps } from '../../../icon/interfaces';\nimport InternalIcon from '../../../icon/internal';\nimport { DragHandleProps } from './interfaces';\nimport { ResizeIcon } from './resize-icon';\n\nimport styles from './styles.css.js';\nimport testUtilsStyles from './test-classes/styles.css.js';\n\nconst DragHandleButton = forwardRef(\n (\n {\n variant = 'drag-indicator',\n size = 'normal',\n active = false,\n className,\n ariaLabel,\n ariaLabelledBy,\n ariaDescribedby,\n ariaValue,\n disabled,\n onPointerDown,\n onClick,\n onKeyDown,\n }: DragHandleProps,\n ref: React.Ref<Element>\n ) => {\n const dragHandleRefObject = useRef<HTMLDivElement>(null);\n\n const iconProps: IconProps = (() => {\n const shared = {\n variant: disabled ? ('disabled' as const) : undefined,\n size,\n };\n switch (variant) {\n case 'drag-indicator':\n return { ...shared, name: 'drag-indicator' };\n case 'resize-area':\n return { ...shared, name: 'resize-area' };\n case 'resize-horizontal':\n return { ...shared, svg: <ResizeIcon variant=\"horizontal\" /> };\n case 'resize-vertical':\n return { ...shared, svg: <ResizeIcon variant=\"vertical\" /> };\n }\n })();\n\n return (\n // We need to use a div with button role instead of a button\n // so that Safari will focus on it when clicking it.\n // (See https://bugs.webkit.org/show_bug.cgi?id=22261)\n // Otherwise, we can't reliably catch keyboard events coming from the handle\n // when it is being dragged.\n <div\n ref={useMergeRefs(ref, dragHandleRefObject)}\n role={ariaValue ? 'slider' : 'application'}\n tabIndex={0}\n className={clsx(\n className,\n styles.handle,\n testUtilsStyles.root,\n styles[`handle-${variant}`],\n styles[`handle-size-${size}`],\n disabled && styles['handle-disabled'],\n active && styles.active\n )}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-describedby={ariaDescribedby}\n aria-disabled={disabled}\n aria-valuemax={ariaValue?.valueMax}\n aria-valuemin={ariaValue?.valueMin}\n aria-valuenow={ariaValue?.valueNow}\n onPointerDown={onPointerDown}\n onClick={onClick}\n onKeyDown={onKeyDown}\n >\n {/* ensure that events happen on the parent div, not the icon */}\n <div className={styles['prevent-pointer']}>\n <InternalIcon {...iconProps} />\n </div>\n </div>\n );\n }\n);\n\nexport default DragHandleButton;\n"]}
1
+ {"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../../src/internal/components/drag-handle/button.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,+CAA+C,CAAC;AAG7E,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAElD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,eAAe,MAAM,8BAA8B,CAAC;AAE3D,MAAM,gBAAgB,GAAG,UAAU,CACjC,CACE,EACE,OAAO,G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C,IAAI,EACpB,MAAM,CAAC,UAAU,OAAO,EAAE,CAAC,EAC3B,MAAM,CAAC,eAAe,IAAI,EAAE,CAAC,EAC7B,QAAQ,IAAI,MAAM,CAAC,iBAAiB,CAAC,EACrC,MAAM,IAAI,MAAM,CAAC,MAAM,CACxB,gBACW,SAAS,qBACJ,cAAc,sBACb,eAAe,mBAClB,QAAQ,kBACT,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,mBAC7B,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,mBACnB,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,mBACnB,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,QAAQ,EAClC,aAAa,EAAE,aAAa,EAC5B,OAAO,EAAE,OAAO,EAChB,SAAS,EAAE,SAAS;QAGpB,6BAAK,SAAS,EAAE,MAAM,CAAC,iBAAiB,CAAC;YACvC,oBAAC,YAAY,OAAK,SAAS,GAAI,CAC3B,CACF,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,gBAAgB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { forwardRef, useRef } from 'react';\nimport clsx from 'clsx';\n\nimport { useMergeRefs } from '@cloudscape-design/component-toolkit/internal';\n\nimport { IconProps } from '../../../icon/interfaces';\nimport InternalIcon from '../../../icon/internal';\nimport { DragHandleProps } from './interfaces';\nimport { ResizeIcon } from './resize-icon';\n\nimport styles from './styles.css.js';\nimport testUtilsStyles from './test-classes/styles.css.js';\n\nconst DragHandleButton = forwardRef(\n (\n {\n variant = 'drag-indicator',\n size = 'normal',\n active = false,\n className,\n ariaLabel,\n ariaLabelledBy,\n ariaDescribedby,\n ariaValue,\n disabled,\n onPointerDown,\n onClick,\n onKeyDown,\n }: DragHandleProps,\n ref: React.Ref<Element>\n ) => {\n const dragHandleRefObject = useRef<HTMLDivElement>(null);\n\n const iconProps: IconProps = (() => {\n const shared = {\n variant: disabled ? ('disabled' as const) : undefined,\n size,\n };\n switch (variant) {\n case 'drag-indicator':\n return { ...shared, name: 'drag-indicator' };\n case 'resize-area':\n return { ...shared, name: 'resize-area' };\n case 'resize-horizontal':\n return { ...shared, svg: <ResizeIcon variant=\"horizontal\" /> };\n case 'resize-vertical':\n return { ...shared, svg: <ResizeIcon variant=\"vertical\" /> };\n }\n })();\n\n return (\n // We need to use a div with button role instead of a button\n // so that Safari will focus on it when clicking it.\n // (See https://bugs.webkit.org/show_bug.cgi?id=22261)\n // Otherwise, we can't reliably catch keyboard events coming from the handle\n // when it is being dragged.\n <div\n ref={useMergeRefs(ref, dragHandleRefObject)}\n role={ariaValue ? 'slider' : 'button'}\n tabIndex={0}\n className={clsx(\n className,\n styles.handle,\n testUtilsStyles.root,\n styles[`handle-${variant}`],\n styles[`handle-size-${size}`],\n disabled && styles['handle-disabled'],\n active && styles.active\n )}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-describedby={ariaDescribedby}\n aria-disabled={disabled}\n aria-pressed={ariaValue ? undefined : active}\n aria-valuemax={ariaValue?.valueMax}\n aria-valuemin={ariaValue?.valueMin}\n aria-valuenow={ariaValue?.valueNow}\n onPointerDown={onPointerDown}\n onClick={onClick}\n onKeyDown={onKeyDown}\n >\n {/* ensure that events happen on the parent div, not the icon */}\n <div className={styles['prevent-pointer']}>\n <InternalIcon {...iconProps} />\n </div>\n </div>\n );\n }\n);\n\nexport default DragHandleButton;\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/sortable-area/index.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAOjD,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,IAAI,EAAE,EACzC,KAAK,EACL,cAAc,EACd,UAAU,EACV,aAAa,EACb,cAAc,EACd,WAAW,GACZ,EAAE,iBAAiB,CAAC,IAAI,CAAC,eAiFzB;AA+FD,wBAAgB,sBAAsB,CACpC,cAAc,EAAE,iBAAiB,CAAC,cAAc,CAAC,GAAG,CAAC,GACpD,iBAAiB,CAAC,mBAAmB,CAEvC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/sortable-area/index.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAOjD,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,IAAI,EAAE,EACzC,KAAK,EACL,cAAc,EACd,UAAU,EACV,aAAa,EACb,cAAc,EACd,WAAW,GACZ,EAAE,iBAAiB,CAAC,IAAI,CAAC,eAiFzB;AAgGD,wBAAgB,sBAAsB,CACpC,cAAc,EAAE,iBAAiB,CAAC,cAAc,CAAC,GAAG,CAAC,GACpD,iBAAiB,CAAC,mBAAmB,CAEvC"}
@@ -105,6 +105,7 @@ function DraggableItem({ item, itemDefinition, dragHandleAriaLabel, showDirectio
105
105
  isDragGhost: false,
106
106
  dragHandleProps: {
107
107
  ...dragHandleListeners,
108
+ active: isDragging,
108
109
  ariaLabel: (_a = joinStrings(dragHandleAriaLabel, itemDefinition.label(item))) !== null && _a !== void 0 ? _a : '',
109
110
  ariaDescribedby: attributes['aria-describedby'],
110
111
  disabled: attributes['aria-disabled'],
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/internal/components/sortable-area/index.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,W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CAAC,CAAC,SAAS;YACb,gBAAgB,EAAE,SAAS,CAAC,EAAE;;gBAC5B,MAAM,KAAK,GAAG,IAAI,KAAK,CAAC,SAAS,KAAK,aAAa,CAAC,CAAC,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC,UAAU,EAAE;oBAC/F,OAAO,EAAE,IAAI;oBACb,UAAU,EAAE,IAAI;iBACjB,CAAC,CAAC;gBACH,SAAS,CAAC,KAAY,CAAC,CAAC;gBACxB,MAAA,aAAa,CAAC,OAAO,0CAAE,aAAa,CAAC,KAAK,CAAC,CAAC;YAC9C,CAAC;SACF;KACF,CAAC,CACD,CACJ,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB,CACpC,cAAqD;;IAErD,OAAO,MAAA,cAAc,CAAC,YAAY,mCAAI,MAAM,CAAC;AAC/C,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport React, { useEffect, useRef } from 'react';\nimport { DndContext, DragOverlay } from '@dnd-kit/core';\nimport { arrayMove, SortableContext, useSortable, verticalListSortingStrategy } from '@dnd-kit/sortable';\nimport { CSS } from '@dnd-kit/utilities';\nimport clsx from 'clsx';\n\nimport { Portal } from '@cloudscape-design/component-toolkit/internal';\n\nimport { fireNonCancelableEvent } from '../../events';\nimport { joinStrings } from '../../utils/strings';\nimport { SortableAreaProps } from './interfaces';\nimport { EventName } from './keyboard-sensor/utilities/events';\nimport useDragAndDropReorder from './use-drag-and-drop-reorder';\nimport useLiveAnnouncements from './use-live-announcements';\n\nimport styles from './styles.css.js';\n\nexport { SortableAreaProps };\n\nexport default function SortableArea<Item>({\n items,\n itemDefinition,\n renderItem,\n onItemsChange,\n disableReorder,\n i18nStrings,\n}: SortableAreaProps<Item>) {\n const { activeItemId, setActiveItemId, collisionDetection, handleKeyDown, sensors, isKeyboard } =\n useDragAndDropReorder({\n items,\n itemDefinition,\n });\n const activeItem = activeItemId ? items.find(item => itemDefinition.id(item) === activeItemId) : null;\n const isDragging = activeItemId !== null;\n const announcements = useLiveAnnouncements({ items, itemDefinition, isDragging, ...i18nStrings });\n const portalContainer = usePortalContainer();\n return (\n <DndContext\n sensors={sensors}\n collisionDetection={collisionDetection}\n accessibility={{\n announcements,\n restoreFocus: false,\n screenReaderInstructions: i18nStrings?.dragHandleAriaDescription\n ? { draggable: i18nStrings.dragHandleAriaDescription }\n : undefined,\n container: portalContainer ?? undefined,\n }}\n onDragStart={({ active }) => setActiveItemId(active.id)}\n onDragEnd={event => {\n setActiveItemId(null);\n const { active, over } = event;\n if (over && active.id !== over.id) {\n const movedItem = items.find(item => itemDefinition.id(item) === active.id)!;\n const oldIndex = items.findIndex(item => itemDefinition.id(item) === active.id);\n const newIndex = items.findIndex(item => itemDefinition.id(item) === over.id);\n fireNonCancelableEvent(onItemsChange, { items: arrayMove([...items], oldIndex, newIndex), movedItem });\n }\n }}\n onDragCancel={() => setActiveItemId(null)}\n >\n <SortableContext\n disabled={disableReorder}\n items={items.map(item => itemDefinition.id(item))}\n strategy={verticalListSortingStrategy}\n >\n {items.map(item => (\n <DraggableItem\n key={itemDefinition.id(item)}\n item={item}\n itemDefinition={itemDefinition}\n showDirectionButtons={item === activeItem && isKeyboard.current}\n renderItem={renderItem}\n onKeyDown={handleKeyDown}\n dragHandleAriaLabel={i18nStrings?.dragHandleAriaLabel}\n />\n ))}\n </SortableContext>\n\n <Portal container={portalContainer}>\n {/* Make sure that the drag overlay is above the modal by assigning the z-index as inline style\n so that it prevails over dnd-kit's inline z-index of 999 */}\n <DragOverlay\n className={clsx(styles['drag-overlay'], styles[`drag-overlay-${getBorderRadiusVariant(itemDefinition)}`])}\n dropAnimation={null}\n style={{ zIndex: 5000 }}\n transition={isKeyboard.current ? 'transform 250ms' : ''}\n >\n {activeItem &&\n renderItem({\n item: activeItem,\n id: activeItemId!.toString(),\n style: {},\n className: styles.active,\n isDropPlaceholder: true,\n isSortingActive: false,\n isDragGhost: true,\n dragHandleProps: {\n ariaLabel: joinStrings(i18nStrings?.dragHandleAriaLabel, itemDefinition.label(activeItem)) ?? '',\n active: true,\n onKeyDown: handleKeyDown,\n },\n })}\n </DragOverlay>\n </Portal>\n </DndContext>\n );\n}\n\nfunction usePortalContainer() {\n const portalContainerRef = useRef(typeof document !== 'undefined' ? document.createElement('div') : null);\n useEffect(() => {\n const container = portalContainerRef.current;\n if (container && !container.isConnected) {\n document.body.appendChild(container);\n }\n return () => {\n if (container && container.isConnected) {\n document.body.removeChild(container);\n }\n };\n }, []);\n return portalContainerRef.current;\n}\n\nfunction DraggableItem<Item>({\n item,\n itemDefinition,\n dragHandleAriaLabel,\n showDirectionButtons,\n onKeyDown,\n renderItem,\n}: {\n item: Item;\n itemDefinition: SortableAreaProps.ItemDefinition<Item>;\n dragHandleAriaLabel?: string;\n showDirectionButtons: boolean;\n onKeyDown: (event: React.KeyboardEvent) => void;\n renderItem: (props: SortableAreaProps.RenderItemProps<Item>) => React.ReactNode;\n}) {\n const id = itemDefinition.id(item);\n const { isDragging, isSorting, listeners, setNodeRef, transform, attributes } = useSortable({\n id,\n });\n const style = { transform: CSS.Translate.toString(transform) };\n const dragHandleListeners = attributes['aria-disabled']\n ? {}\n : {\n ...listeners,\n onKeyDown: (event: React.KeyboardEvent) => {\n if (onKeyDown) {\n onKeyDown(event);\n }\n if (listeners?.onKeyDown) {\n listeners.onKeyDown(event);\n }\n },\n };\n const className = clsx(\n isDragging && clsx(styles.placeholder, styles[`placeholder-${getBorderRadiusVariant(itemDefinition)}`]),\n isSorting && styles.sorting\n );\n const dragHandleRef = useRef<HTMLElement>(null);\n return (\n <>\n {renderItem({\n item,\n id,\n ref: setNodeRef,\n style,\n className,\n isDropPlaceholder: isDragging,\n isSortingActive: isSorting,\n isDragGhost: false,\n dragHandleProps: {\n ...dragHandleListeners,\n ariaLabel: joinStrings(dragHandleAriaLabel, itemDefinition.label(item)) ?? '',\n ariaDescribedby: attributes['aria-describedby'],\n disabled: attributes['aria-disabled'],\n triggerMode: 'controlled',\n controlledShowButtons: showDirectionButtons,\n ref: dragHandleRef,\n directions: showDirectionButtons\n ? {\n 'block-start': 'active',\n 'block-end': 'active',\n }\n : undefined,\n onDirectionClick: direction => {\n const event = new Event(direction === 'block-start' ? EventName.CustomUp : EventName.CustomDown, {\n bubbles: true,\n cancelable: true,\n });\n onKeyDown(event as any);\n dragHandleRef.current?.dispatchEvent(event);\n },\n },\n })}\n </>\n );\n}\n\nexport function getBorderRadiusVariant(\n itemDefinition: SortableAreaProps.ItemDefinition<any>\n): SortableAreaProps.BorderRadiusVariant {\n return itemDefinition.borderRadius ?? 'item';\n}\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/internal/components/sortable-area/index.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,WAAW,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAC;AACzG,OAAO,EAAE,GAAG,EAAE,MAAM,oBAAoB,CAAC;AACzC,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,MAAM,EAAE,MAAM,+CAA+C,CAAC;AAEvE,OAAO,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAElD,OAAO,EAAE,SAAS,EAAE,MAAM,oCAAoC,CAAC;AAC/D,OAAO,qBAAqB,MAAM,6BAA6B,CAAC;AAChE,OAAO,oBAAoB,MAAM,0BAA0B,CAAC;AAE5D,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAIrC,MAAM,CAAC,OAAO,UAAU,YAAY,CAAO,EACzC,KAAK,EACL,cAAc,EAC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AY,mCAAI,MAAM,CAAC;AAC/C,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport React, { useEffect, useRef } from 'react';\nimport { DndContext, DragOverlay } from '@dnd-kit/core';\nimport { arrayMove, SortableContext, useSortable, verticalListSortingStrategy } from '@dnd-kit/sortable';\nimport { CSS } from '@dnd-kit/utilities';\nimport clsx from 'clsx';\n\nimport { Portal } from '@cloudscape-design/component-toolkit/internal';\n\nimport { fireNonCancelableEvent } from '../../events';\nimport { joinStrings } from '../../utils/strings';\nimport { SortableAreaProps } from './interfaces';\nimport { EventName } from './keyboard-sensor/utilities/events';\nimport useDragAndDropReorder from './use-drag-and-drop-reorder';\nimport useLiveAnnouncements from './use-live-announcements';\n\nimport styles from './styles.css.js';\n\nexport { SortableAreaProps };\n\nexport default function SortableArea<Item>({\n items,\n itemDefinition,\n renderItem,\n onItemsChange,\n disableReorder,\n i18nStrings,\n}: SortableAreaProps<Item>) {\n const { activeItemId, setActiveItemId, collisionDetection, handleKeyDown, sensors, isKeyboard } =\n useDragAndDropReorder({\n items,\n itemDefinition,\n });\n const activeItem = activeItemId ? items.find(item => itemDefinition.id(item) === activeItemId) : null;\n const isDragging = activeItemId !== null;\n const announcements = useLiveAnnouncements({ items, itemDefinition, isDragging, ...i18nStrings });\n const portalContainer = usePortalContainer();\n return (\n <DndContext\n sensors={sensors}\n collisionDetection={collisionDetection}\n accessibility={{\n announcements,\n restoreFocus: false,\n screenReaderInstructions: i18nStrings?.dragHandleAriaDescription\n ? { draggable: i18nStrings.dragHandleAriaDescription }\n : undefined,\n container: portalContainer ?? undefined,\n }}\n onDragStart={({ active }) => setActiveItemId(active.id)}\n onDragEnd={event => {\n setActiveItemId(null);\n const { active, over } = event;\n if (over && active.id !== over.id) {\n const movedItem = items.find(item => itemDefinition.id(item) === active.id)!;\n const oldIndex = items.findIndex(item => itemDefinition.id(item) === active.id);\n const newIndex = items.findIndex(item => itemDefinition.id(item) === over.id);\n fireNonCancelableEvent(onItemsChange, { items: arrayMove([...items], oldIndex, newIndex), movedItem });\n }\n }}\n onDragCancel={() => setActiveItemId(null)}\n >\n <SortableContext\n disabled={disableReorder}\n items={items.map(item => itemDefinition.id(item))}\n strategy={verticalListSortingStrategy}\n >\n {items.map(item => (\n <DraggableItem\n key={itemDefinition.id(item)}\n item={item}\n itemDefinition={itemDefinition}\n showDirectionButtons={item === activeItem && isKeyboard.current}\n renderItem={renderItem}\n onKeyDown={handleKeyDown}\n dragHandleAriaLabel={i18nStrings?.dragHandleAriaLabel}\n />\n ))}\n </SortableContext>\n\n <Portal container={portalContainer}>\n {/* Make sure that the drag overlay is above the modal by assigning the z-index as inline style\n so that it prevails over dnd-kit's inline z-index of 999 */}\n <DragOverlay\n className={clsx(styles['drag-overlay'], styles[`drag-overlay-${getBorderRadiusVariant(itemDefinition)}`])}\n dropAnimation={null}\n style={{ zIndex: 5000 }}\n transition={isKeyboard.current ? 'transform 250ms' : ''}\n >\n {activeItem &&\n renderItem({\n item: activeItem,\n id: activeItemId!.toString(),\n style: {},\n className: styles.active,\n isDropPlaceholder: true,\n isSortingActive: false,\n isDragGhost: true,\n dragHandleProps: {\n ariaLabel: joinStrings(i18nStrings?.dragHandleAriaLabel, itemDefinition.label(activeItem)) ?? '',\n active: true,\n onKeyDown: handleKeyDown,\n },\n })}\n </DragOverlay>\n </Portal>\n </DndContext>\n );\n}\n\nfunction usePortalContainer() {\n const portalContainerRef = useRef(typeof document !== 'undefined' ? document.createElement('div') : null);\n useEffect(() => {\n const container = portalContainerRef.current;\n if (container && !container.isConnected) {\n document.body.appendChild(container);\n }\n return () => {\n if (container && container.isConnected) {\n document.body.removeChild(container);\n }\n };\n }, []);\n return portalContainerRef.current;\n}\n\nfunction DraggableItem<Item>({\n item,\n itemDefinition,\n dragHandleAriaLabel,\n showDirectionButtons,\n onKeyDown,\n renderItem,\n}: {\n item: Item;\n itemDefinition: SortableAreaProps.ItemDefinition<Item>;\n dragHandleAriaLabel?: string;\n showDirectionButtons: boolean;\n onKeyDown: (event: React.KeyboardEvent) => void;\n renderItem: (props: SortableAreaProps.RenderItemProps<Item>) => React.ReactNode;\n}) {\n const id = itemDefinition.id(item);\n const { isDragging, isSorting, listeners, setNodeRef, transform, attributes } = useSortable({\n id,\n });\n const style = { transform: CSS.Translate.toString(transform) };\n const dragHandleListeners = attributes['aria-disabled']\n ? {}\n : {\n ...listeners,\n onKeyDown: (event: React.KeyboardEvent) => {\n if (onKeyDown) {\n onKeyDown(event);\n }\n if (listeners?.onKeyDown) {\n listeners.onKeyDown(event);\n }\n },\n };\n const className = clsx(\n isDragging && clsx(styles.placeholder, styles[`placeholder-${getBorderRadiusVariant(itemDefinition)}`]),\n isSorting && styles.sorting\n );\n const dragHandleRef = useRef<HTMLElement>(null);\n return (\n <>\n {renderItem({\n item,\n id,\n ref: setNodeRef,\n style,\n className,\n isDropPlaceholder: isDragging,\n isSortingActive: isSorting,\n isDragGhost: false,\n dragHandleProps: {\n ...dragHandleListeners,\n active: isDragging,\n ariaLabel: joinStrings(dragHandleAriaLabel, itemDefinition.label(item)) ?? '',\n ariaDescribedby: attributes['aria-describedby'],\n disabled: attributes['aria-disabled'],\n triggerMode: 'controlled',\n controlledShowButtons: showDirectionButtons,\n ref: dragHandleRef,\n directions: showDirectionButtons\n ? {\n 'block-start': 'active',\n 'block-end': 'active',\n }\n : undefined,\n onDirectionClick: direction => {\n const event = new Event(direction === 'block-start' ? EventName.CustomUp : EventName.CustomDown, {\n bubbles: true,\n cancelable: true,\n });\n onKeyDown(event as any);\n dragHandleRef.current?.dispatchEvent(event);\n },\n },\n })}\n </>\n );\n}\n\nexport function getBorderRadiusVariant(\n itemDefinition: SortableAreaProps.ItemDefinition<any>\n): SortableAreaProps.BorderRadiusVariant {\n return itemDefinition.borderRadius ?? 'item';\n}\n"]}
@@ -3,4 +3,5 @@ export const PACKAGE_VERSION: string;
3
3
  export const GIT_SHA: string;
4
4
  export const THEME: string;
5
5
  export const SYSTEM: string;
6
- export const ALWAYS_VISUAL_REFRESH: string;
6
+ export const ALWAYS_VISUAL_REFRESH: string;
7
+ export const INCLUDE_ONE_THEME: string;
@@ -1,6 +1,7 @@
1
1
  export var PACKAGE_SOURCE = "components";
2
- export var PACKAGE_VERSION = "3.0.0 (d6bd1774)";
3
- export var GIT_SHA = "d6bd1774";
2
+ export var PACKAGE_VERSION = "3.0.0 (5325301e)";
3
+ export var GIT_SHA = "5325301e";
4
4
  export var THEME = "open-source-visual-refresh";
5
5
  export var SYSTEM = "core";
6
- export var ALWAYS_VISUAL_REFRESH = true;
6
+ export var ALWAYS_VISUAL_REFRESH = true;
7
+ export var INCLUDE_ONE_THEME = false;
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "PACKAGE_SOURCE": "components",
3
- "PACKAGE_VERSION": "3.0.0 (d6bd1774)",
4
- "GIT_SHA": "d6bd1774",
3
+ "PACKAGE_VERSION": "3.0.0 (5325301e)",
4
+ "GIT_SHA": "5325301e",
5
5
  "THEME": "open-source-visual-refresh",
6
6
  "SYSTEM": "core",
7
- "ALWAYS_VISUAL_REFRESH": true
7
+ "ALWAYS_VISUAL_REFRESH": true,
8
+ "INCLUDE_ONE_THEME": false
8
9
  }
@@ -289,6 +289,7 @@ export const colorBackgroundButtonNormalDefault: string;
289
289
  export const colorBackgroundButtonNormalDisabled: string;
290
290
  export const colorBackgroundButtonNormalHover: string;
291
291
  export const colorBackgroundToggleButtonNormalPressed: string;
292
+ export const colorBackgroundToggleButtonNormalDefault: string;
292
293
  export const colorBackgroundButtonPrimaryActive: string;
293
294
  export const colorBackgroundButtonPrimaryDefault: string;
294
295
  export const colorBackgroundButtonPrimaryDisabled: string;
@@ -491,6 +492,7 @@ export const colorTextButtonPrimaryActive: string;
491
492
  export const colorTextButtonPrimaryDefault: string;
492
493
  export const colorTextButtonPrimaryHover: string;
493
494
  export const colorTextCalendarDateHover: string;
495
+ export const colorTextCalendarDateSelected: string;
494
496
  export const colorTextCalendarMonth: string;
495
497
  export const colorTextCodeEditorGutterActiveLine: string;
496
498
  export const colorTextCodeEditorGutterDefault: string;
@@ -289,6 +289,7 @@ export var colorBackgroundButtonNormalDefault = "var(--color-background-button-n
289
289
  export var colorBackgroundButtonNormalDisabled = "var(--color-background-button-normal-disabled-hl039l, #ffffff)";
290
290
  export var colorBackgroundButtonNormalHover = "var(--color-background-button-normal-hover-53op9s, #f0fbff)";
291
291
  export var colorBackgroundToggleButtonNormalPressed = "var(--color-background-toggle-button-normal-pressed-4khex7, #d1f1ff)";
292
+ export var colorBackgroundToggleButtonNormalDefault = "var(--color-background-toggle-button-normal-default-ipnqr5, #ffffff)";
292
293
  export var colorBackgroundButtonPrimaryActive = "var(--color-background-button-primary-active-5cqoqt, #002b66)";
293
294
  export var colorBackgroundButtonPrimaryDefault = "var(--color-background-button-primary-default-vdt0fu, #006ce0)";
294
295
  export var colorBackgroundButtonPrimaryDisabled = "var(--color-background-button-primary-disabled-sgo4zo, #ebebf0)";
@@ -491,6 +492,7 @@ export var colorTextButtonPrimaryActive = "var(--color-text-button-primary-activ
491
492
  export var colorTextButtonPrimaryDefault = "var(--color-text-button-primary-default-mwl31m, #ffffff)";
492
493
  export var colorTextButtonPrimaryHover = "var(--color-text-button-primary-hover-pw12ep, #ffffff)";
493
494
  export var colorTextCalendarDateHover = "var(--color-text-calendar-date-hover-3fcriv, #0f141a)";
495
+ export var colorTextCalendarDateSelected = "var(--color-text-calendar-date-selected-m18pgv, #ffffff)";
494
496
  export var colorTextCalendarMonth = "var(--color-text-calendar-month-ea0e93, #656871)";
495
497
  export var colorTextCodeEditorGutterActiveLine = "var(--color-text-code-editor-gutter-active-line-2addhd, #ffffff)";
496
498
  export var colorTextCodeEditorGutterDefault = "var(--color-text-code-editor-gutter-default-nlshs8, #0f141a)";
@@ -1203,6 +1203,10 @@ module.exports.preset = {
1203
1203
  "light": "{colorPrimary100}",
1204
1204
  "dark": "{colorNeutral700}"
1205
1205
  },
1206
+ "colorBackgroundToggleButtonNormalDefault": {
1207
+ "light": "{colorBackgroundButtonNormalDefault}",
1208
+ "dark": "{colorBackgroundButtonNormalDefault}"
1209
+ },
1206
1210
  "colorBackgroundButtonPrimaryActive": {
1207
1211
  "light": "{colorPrimary900}",
1208
1212
  "dark": "{colorPrimary400}"
@@ -2011,6 +2015,10 @@ module.exports.preset = {
2011
2015
  "light": "{colorTextDropdownItemDefault}",
2012
2016
  "dark": "{colorTextDropdownItemDefault}"
2013
2017
  },
2018
+ "colorTextCalendarDateSelected": {
2019
+ "light": "{colorBackgroundControlDefault}",
2020
+ "dark": "{colorBackgroundControlDefault}"
2021
+ },
2014
2022
  "colorTextCalendarMonth": {
2015
2023
  "light": "{colorNeutral600}",
2016
2024
  "dark": "{colorNeutral450}"
@@ -3897,6 +3905,10 @@ module.exports.preset = {
3897
3905
  "light": "{colorNeutral700}",
3898
3906
  "dark": "{colorNeutral700}"
3899
3907
  },
3908
+ "colorBackgroundToggleButtonNormalDefault": {
3909
+ "light": "{colorBackgroundButtonNormalDefault}",
3910
+ "dark": "{colorBackgroundButtonNormalDefault}"
3911
+ },
3900
3912
  "colorBackgroundButtonPrimaryActive": {
3901
3913
  "light": "{colorPrimary400}",
3902
3914
  "dark": "{colorPrimary400}"
@@ -4705,6 +4717,10 @@ module.exports.preset = {
4705
4717
  "light": "{colorTextDropdownItemDefault}",
4706
4718
  "dark": "{colorTextDropdownItemDefault}"
4707
4719
  },
4720
+ "colorTextCalendarDateSelected": {
4721
+ "light": "{colorBackgroundControlDefault}",
4722
+ "dark": "{colorBackgroundControlDefault}"
4723
+ },
4708
4724
  "colorTextCalendarMonth": {
4709
4725
  "light": "{colorNeutral450}",
4710
4726
  "dark": "{colorNeutral450}"
@@ -5406,6 +5422,10 @@ module.exports.preset = {
5406
5422
  "light": "{colorNeutral700}",
5407
5423
  "dark": "{colorNeutral700}"
5408
5424
  },
5425
+ "colorBackgroundToggleButtonNormalDefault": {
5426
+ "light": "{colorBackgroundButtonNormalDefault}",
5427
+ "dark": "{colorBackgroundButtonNormalDefault}"
5428
+ },
5409
5429
  "colorBackgroundButtonPrimaryActive": {
5410
5430
  "light": "{colorPrimary400}",
5411
5431
  "dark": "{colorPrimary400}"
@@ -6214,6 +6234,10 @@ module.exports.preset = {
6214
6234
  "light": "{colorTextDropdownItemDefault}",
6215
6235
  "dark": "{colorTextDropdownItemDefault}"
6216
6236
  },
6237
+ "colorTextCalendarDateSelected": {
6238
+ "light": "{colorBackgroundControlDefault}",
6239
+ "dark": "{colorBackgroundControlDefault}"
6240
+ },
6217
6241
  "colorTextCalendarMonth": {
6218
6242
  "light": "{colorNeutral450}",
6219
6243
  "dark": "{colorNeutral450}"
@@ -6843,6 +6867,10 @@ module.exports.preset = {
6843
6867
  "light": "{colorPrimary100}",
6844
6868
  "dark": "{colorNeutral700}"
6845
6869
  },
6870
+ "colorBackgroundToggleButtonNormalDefault": {
6871
+ "light": "{colorBackgroundButtonNormalDefault}",
6872
+ "dark": "{colorBackgroundButtonNormalDefault}"
6873
+ },
6846
6874
  "colorBackgroundButtonPrimaryActive": {
6847
6875
  "light": "{colorPrimary900}",
6848
6876
  "dark": "{colorPrimary400}"
@@ -7651,6 +7679,10 @@ module.exports.preset = {
7651
7679
  "light": "{colorTextDropdownItemDefault}",
7652
7680
  "dark": "{colorTextDropdownItemDefault}"
7653
7681
  },
7682
+ "colorTextCalendarDateSelected": {
7683
+ "light": "{colorBackgroundControlDefault}",
7684
+ "dark": "{colorBackgroundControlDefault}"
7685
+ },
7654
7686
  "colorTextCalendarMonth": {
7655
7687
  "light": "{colorNeutral600}",
7656
7688
  "dark": "{colorNeutral450}"
@@ -8165,6 +8197,10 @@ module.exports.preset = {
8165
8197
  "light": "{colorPrimary100}",
8166
8198
  "dark": "{colorNeutral700}"
8167
8199
  },
8200
+ "colorBackgroundToggleButtonNormalDefault": {
8201
+ "light": "{colorBackgroundButtonNormalDefault}",
8202
+ "dark": "{colorBackgroundButtonNormalDefault}"
8203
+ },
8168
8204
  "colorBackgroundButtonPrimaryActive": {
8169
8205
  "light": "{colorPrimary900}",
8170
8206
  "dark": "{colorPrimary400}"
@@ -8973,6 +9009,10 @@ module.exports.preset = {
8973
9009
  "light": "{colorTextDropdownItemDefault}",
8974
9010
  "dark": "{colorTextDropdownItemDefault}"
8975
9011
  },
9012
+ "colorTextCalendarDateSelected": {
9013
+ "light": "{colorBackgroundControlDefault}",
9014
+ "dark": "{colorBackgroundControlDefault}"
9015
+ },
8976
9016
  "colorTextCalendarMonth": {
8977
9017
  "light": "{colorNeutral600}",
8978
9018
  "dark": "{colorNeutral450}"
@@ -9487,6 +9527,10 @@ module.exports.preset = {
9487
9527
  "light": "{colorPrimary100}",
9488
9528
  "dark": "{colorNeutral700}"
9489
9529
  },
9530
+ "colorBackgroundToggleButtonNormalDefault": {
9531
+ "light": "{colorBackgroundButtonNormalDefault}",
9532
+ "dark": "{colorBackgroundButtonNormalDefault}"
9533
+ },
9490
9534
  "colorBackgroundButtonPrimaryActive": {
9491
9535
  "light": "{colorPrimary900}",
9492
9536
  "dark": "{colorPrimary400}"
@@ -10295,6 +10339,10 @@ module.exports.preset = {
10295
10339
  "light": "{colorTextDropdownItemDefault}",
10296
10340
  "dark": "{colorTextDropdownItemDefault}"
10297
10341
  },
10342
+ "colorTextCalendarDateSelected": {
10343
+ "light": "{colorBackgroundControlDefault}",
10344
+ "dark": "{colorBackgroundControlDefault}"
10345
+ },
10298
10346
  "colorTextCalendarMonth": {
10299
10347
  "light": "{colorNeutral600}",
10300
10348
  "dark": "{colorNeutral450}"
@@ -10811,6 +10859,10 @@ module.exports.preset = {
10811
10859
  "light": "{colorNeutral700}",
10812
10860
  "dark": "{colorNeutral700}"
10813
10861
  },
10862
+ "colorBackgroundToggleButtonNormalDefault": {
10863
+ "light": "{colorBackgroundButtonNormalDefault}",
10864
+ "dark": "{colorBackgroundButtonNormalDefault}"
10865
+ },
10814
10866
  "colorBackgroundButtonPrimaryActive": {
10815
10867
  "light": "{colorPrimary400}",
10816
10868
  "dark": "{colorPrimary400}"
@@ -11619,6 +11671,10 @@ module.exports.preset = {
11619
11671
  "light": "{colorTextDropdownItemDefault}",
11620
11672
  "dark": "{colorTextDropdownItemDefault}"
11621
11673
  },
11674
+ "colorTextCalendarDateSelected": {
11675
+ "light": "{colorBackgroundControlDefault}",
11676
+ "dark": "{colorBackgroundControlDefault}"
11677
+ },
11622
11678
  "colorTextCalendarMonth": {
11623
11679
  "light": "{colorNeutral450}",
11624
11680
  "dark": "{colorNeutral450}"
@@ -12352,6 +12408,7 @@ module.exports.preset = {
12352
12408
  "colorBackgroundButtonNormalDisabled": "color",
12353
12409
  "colorBackgroundButtonNormalHover": "color",
12354
12410
  "colorBackgroundToggleButtonNormalPressed": "color",
12411
+ "colorBackgroundToggleButtonNormalDefault": "color",
12355
12412
  "colorBackgroundButtonPrimaryActive": "color",
12356
12413
  "colorBackgroundButtonPrimaryDefault": "color",
12357
12414
  "colorBackgroundButtonPrimaryDisabled": "color",
@@ -12554,6 +12611,7 @@ module.exports.preset = {
12554
12611
  "colorTextButtonPrimaryDefault": "color",
12555
12612
  "colorTextButtonPrimaryHover": "color",
12556
12613
  "colorTextCalendarDateHover": "color",
12614
+ "colorTextCalendarDateSelected": "color",
12557
12615
  "colorTextCalendarMonth": "color",
12558
12616
  "colorTextCodeEditorGutterActiveLine": "color",
12559
12617
  "colorTextCodeEditorGutterDefault": "color",
@@ -13149,6 +13207,7 @@ module.exports.preset = {
13149
13207
  "colorBackgroundButtonNormalDisabled",
13150
13208
  "colorBackgroundButtonNormalHover",
13151
13209
  "colorBackgroundToggleButtonNormalPressed",
13210
+ "colorBackgroundToggleButtonNormalDefault",
13152
13211
  "colorBackgroundButtonPrimaryActive",
13153
13212
  "colorBackgroundButtonPrimaryDefault",
13154
13213
  "colorBackgroundButtonPrimaryDisabled",
@@ -13200,6 +13259,7 @@ module.exports.preset = {
13200
13259
  "colorBackgroundStatusSuccess",
13201
13260
  "colorBackgroundStatusWarning",
13202
13261
  "colorBackgroundToggleCheckedDisabled",
13262
+ "colorBackgroundToggleDefault",
13203
13263
  "colorBackgroundStatusIndicatorError",
13204
13264
  "colorBackgroundStatusIndicatorWarning",
13205
13265
  "colorBackgroundStatusIndicatorSuccess",
@@ -13271,6 +13331,7 @@ module.exports.preset = {
13271
13331
  "colorTextButtonPrimaryActive",
13272
13332
  "colorTextButtonPrimaryDefault",
13273
13333
  "colorTextButtonPrimaryHover",
13334
+ "colorTextCalendarDateSelected",
13274
13335
  "colorTextCounter",
13275
13336
  "colorTextDropdownItemDefault",
13276
13337
  "colorTextDropdownItemDisabled",
@@ -13626,6 +13687,7 @@ module.exports.preset = {
13626
13687
  "colorBackgroundButtonNormalDisabled",
13627
13688
  "colorBackgroundButtonNormalHover",
13628
13689
  "colorBackgroundToggleButtonNormalPressed",
13690
+ "colorBackgroundToggleButtonNormalDefault",
13629
13691
  "colorBackgroundButtonPrimaryActive",
13630
13692
  "colorBackgroundButtonPrimaryDefault",
13631
13693
  "colorBackgroundButtonPrimaryDisabled",
@@ -13677,6 +13739,7 @@ module.exports.preset = {
13677
13739
  "colorBackgroundStatusSuccess",
13678
13740
  "colorBackgroundStatusWarning",
13679
13741
  "colorBackgroundToggleCheckedDisabled",
13742
+ "colorBackgroundToggleDefault",
13680
13743
  "colorBackgroundAvatarGenAi",
13681
13744
  "colorBackgroundAvatarDefault",
13682
13745
  "colorTextAvatar",
@@ -13743,6 +13806,7 @@ module.exports.preset = {
13743
13806
  "colorTextButtonPrimaryActive",
13744
13807
  "colorTextButtonPrimaryDefault",
13745
13808
  "colorTextButtonPrimaryHover",
13809
+ "colorTextCalendarDateSelected",
13746
13810
  "colorTextCounter",
13747
13811
  "colorTextDropdownItemDefault",
13748
13812
  "colorTextDropdownItemDisabled",
@@ -14242,6 +14306,7 @@ module.exports.preset = {
14242
14306
  "colorBackgroundButtonNormalDisabled": "color-background-button-normal-disabled",
14243
14307
  "colorBackgroundButtonNormalHover": "color-background-button-normal-hover",
14244
14308
  "colorBackgroundToggleButtonNormalPressed": "color-background-toggle-button-normal-pressed",
14309
+ "colorBackgroundToggleButtonNormalDefault": "color-background-toggle-button-normal-default",
14245
14310
  "colorBackgroundButtonPrimaryActive": "color-background-button-primary-active",
14246
14311
  "colorBackgroundButtonPrimaryDefault": "color-background-button-primary-default",
14247
14312
  "colorBackgroundButtonPrimaryDisabled": "color-background-button-primary-disabled",
@@ -14444,6 +14509,7 @@ module.exports.preset = {
14444
14509
  "colorTextButtonPrimaryDefault": "color-text-button-primary-default",
14445
14510
  "colorTextButtonPrimaryHover": "color-text-button-primary-hover",
14446
14511
  "colorTextCalendarDateHover": "color-text-calendar-date-hover",
14512
+ "colorTextCalendarDateSelected": "color-text-calendar-date-selected",
14447
14513
  "colorTextCalendarMonth": "color-text-calendar-month",
14448
14514
  "colorTextCodeEditorGutterActiveLine": "color-text-code-editor-gutter-active-line",
14449
14515
  "colorTextCodeEditorGutterDefault": "color-text-code-editor-gutter-default",
@@ -15169,6 +15235,7 @@ module.exports.preset = {
15169
15235
  "colorBackgroundButtonNormalDisabled": "--color-background-button-normal-disabled-hl039l",
15170
15236
  "colorBackgroundButtonNormalHover": "--color-background-button-normal-hover-53op9s",
15171
15237
  "colorBackgroundToggleButtonNormalPressed": "--color-background-toggle-button-normal-pressed-4khex7",
15238
+ "colorBackgroundToggleButtonNormalDefault": "--color-background-toggle-button-normal-default-ipnqr5",
15172
15239
  "colorBackgroundButtonPrimaryActive": "--color-background-button-primary-active-5cqoqt",
15173
15240
  "colorBackgroundButtonPrimaryDefault": "--color-background-button-primary-default-vdt0fu",
15174
15241
  "colorBackgroundButtonPrimaryDisabled": "--color-background-button-primary-disabled-sgo4zo",
@@ -15371,6 +15438,7 @@ module.exports.preset = {
15371
15438
  "colorTextButtonPrimaryDefault": "--color-text-button-primary-default-mwl31m",
15372
15439
  "colorTextButtonPrimaryHover": "--color-text-button-primary-hover-pw12ep",
15373
15440
  "colorTextCalendarDateHover": "--color-text-calendar-date-hover-3fcriv",
15441
+ "colorTextCalendarDateSelected": "--color-text-calendar-date-selected-m18pgv",
15374
15442
  "colorTextCalendarMonth": "--color-text-calendar-month-ea0e93",
15375
15443
  "colorTextCodeEditorGutterActiveLine": "--color-text-code-editor-gutter-active-line-2addhd",
15376
15444
  "colorTextCodeEditorGutterDefault": "--color-text-code-editor-gutter-default-nlshs8",