@carbon/react 1.82.1 → 1.83.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/.playwright/INTERNAL_AVT_REPORT_DO_NOT_USE.json +925 -880
  2. package/es/components/AccordionItem/index.d.ts +9 -0
  3. package/es/components/DatePicker/DatePicker.d.ts +1 -1
  4. package/es/components/DatePicker/DatePicker.js +6 -3
  5. package/es/components/FileUploader/FileUploaderButton.d.ts +1 -1
  6. package/es/components/FileUploader/FileUploaderButton.js +2 -1
  7. package/es/components/Grid/Column.d.ts +5 -5
  8. package/es/components/Grid/Column.js +10 -10
  9. package/es/components/LayoutDirection/index.d.ts +8 -0
  10. package/es/components/Menu/Menu.js +2 -1
  11. package/es/components/Menu/MenuItem.js +2 -1
  12. package/es/components/Modal/Modal.d.ts +1 -1
  13. package/es/components/Modal/Modal.js +5 -3
  14. package/es/components/Slider/Slider.d.ts +8 -0
  15. package/es/components/Slider/Slider.js +6 -0
  16. package/es/components/Tabs/Tabs.js +5 -2
  17. package/es/components/Tag/DismissibleTag.d.ts +4 -0
  18. package/es/components/Tag/DismissibleTag.js +8 -3
  19. package/es/components/Tag/SelectableTag.d.ts +4 -0
  20. package/es/components/Tag/SelectableTag.js +12 -3
  21. package/es/components/UIShell/Switcher.js +3 -3
  22. package/es/feature-flags.d.ts +7 -0
  23. package/es/index.js +2 -2
  24. package/es/internal/debounce.d.ts +8 -0
  25. package/es/internal/environment.d.ts +12 -0
  26. package/es/internal/useId.js +1 -1
  27. package/es/internal/usePreviousValue.d.ts +17 -0
  28. package/es/internal/usePreviousValue.js +28 -0
  29. package/es/prop-types/AriaPropTypes.d.ts +8 -0
  30. package/lib/components/AccordionItem/index.d.ts +9 -0
  31. package/lib/components/DatePicker/DatePicker.d.ts +1 -1
  32. package/lib/components/DatePicker/DatePicker.js +6 -3
  33. package/lib/components/FileUploader/FileUploaderButton.d.ts +1 -1
  34. package/lib/components/FileUploader/FileUploaderButton.js +3 -2
  35. package/lib/components/Grid/Column.d.ts +5 -5
  36. package/lib/components/Grid/Column.js +10 -10
  37. package/lib/components/LayoutDirection/index.d.ts +8 -0
  38. package/lib/components/Menu/Menu.js +2 -1
  39. package/lib/components/Menu/MenuItem.js +2 -1
  40. package/lib/components/Modal/Modal.d.ts +1 -1
  41. package/lib/components/Modal/Modal.js +5 -3
  42. package/lib/components/Slider/Slider.d.ts +8 -0
  43. package/lib/components/Slider/Slider.js +6 -0
  44. package/lib/components/Tabs/Tabs.js +5 -2
  45. package/lib/components/Tag/DismissibleTag.d.ts +4 -0
  46. package/lib/components/Tag/DismissibleTag.js +8 -3
  47. package/lib/components/Tag/SelectableTag.d.ts +4 -0
  48. package/lib/components/Tag/SelectableTag.js +12 -3
  49. package/lib/components/UIShell/Switcher.js +3 -3
  50. package/lib/feature-flags.d.ts +7 -0
  51. package/lib/index.js +4 -4
  52. package/lib/internal/debounce.d.ts +8 -0
  53. package/lib/internal/environment.d.ts +12 -0
  54. package/lib/internal/usePreviousValue.d.ts +17 -0
  55. package/lib/internal/usePreviousValue.js +32 -0
  56. package/lib/prop-types/AriaPropTypes.d.ts +8 -0
  57. package/package.json +4 -4
  58. package/telemetry.yml +1 -0
  59. package/es/prop-types/tools/getDisplayName.js +0 -34
  60. package/es/prop-types/types.js +0 -13
  61. package/lib/prop-types/tools/getDisplayName.js +0 -38
  62. package/lib/prop-types/types.js +0 -17
@@ -1,34 +0,0 @@
1
- /**
2
- * Copyright IBM Corp. 2016, 2023
3
- *
4
- * This source code is licensed under the Apache-2.0 license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
- const cachedDisplayNames = new WeakMap();
9
-
10
- /**
11
- * `getDisplayName` is a utility function for getting a name from a given
12
- * component type. It supports names from React elements, Stateless Functional
13
- * Components, and Class-based Components
14
- */
15
- const getDisplayName = type => {
16
- if (typeof type === 'string') {
17
- return type;
18
- }
19
- if (cachedDisplayNames.has(type)) {
20
- return cachedDisplayNames.get(type);
21
- }
22
- let displayName;
23
- if (typeof type.displayName === 'string') {
24
- displayName = type.displayName;
25
- }
26
- if (!displayName) {
27
- displayName = type.name || 'Unknown';
28
- }
29
- cachedDisplayNames.set(type, displayName);
30
- return displayName;
31
- };
32
- var getDisplayName$1 = getDisplayName;
33
-
34
- export { getDisplayName$1 as default };
@@ -1,13 +0,0 @@
1
- /**
2
- * Copyright IBM Corp. 2016, 2023
3
- *
4
- * This source code is licensed under the Apache-2.0 license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
- /**
9
- * @deprecated use ButtonKinds export from Button component instead
10
- */
11
- const ButtonKinds = ['primary', 'secondary', 'danger', 'ghost', 'danger--primary', 'danger--ghost', 'danger--tertiary', 'tertiary'];
12
-
13
- export { ButtonKinds };
@@ -1,38 +0,0 @@
1
- /**
2
- * Copyright IBM Corp. 2016, 2023
3
- *
4
- * This source code is licensed under the Apache-2.0 license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
- 'use strict';
9
-
10
- Object.defineProperty(exports, '__esModule', { value: true });
11
-
12
- const cachedDisplayNames = new WeakMap();
13
-
14
- /**
15
- * `getDisplayName` is a utility function for getting a name from a given
16
- * component type. It supports names from React elements, Stateless Functional
17
- * Components, and Class-based Components
18
- */
19
- const getDisplayName = type => {
20
- if (typeof type === 'string') {
21
- return type;
22
- }
23
- if (cachedDisplayNames.has(type)) {
24
- return cachedDisplayNames.get(type);
25
- }
26
- let displayName;
27
- if (typeof type.displayName === 'string') {
28
- displayName = type.displayName;
29
- }
30
- if (!displayName) {
31
- displayName = type.name || 'Unknown';
32
- }
33
- cachedDisplayNames.set(type, displayName);
34
- return displayName;
35
- };
36
- var getDisplayName$1 = getDisplayName;
37
-
38
- exports["default"] = getDisplayName$1;
@@ -1,17 +0,0 @@
1
- /**
2
- * Copyright IBM Corp. 2016, 2023
3
- *
4
- * This source code is licensed under the Apache-2.0 license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
- 'use strict';
9
-
10
- Object.defineProperty(exports, '__esModule', { value: true });
11
-
12
- /**
13
- * @deprecated use ButtonKinds export from Button component instead
14
- */
15
- const ButtonKinds = ['primary', 'secondary', 'danger', 'ghost', 'danger--primary', 'danger--ghost', 'danger--tertiary', 'tertiary'];
16
-
17
- exports.ButtonKinds = ButtonKinds;