@pega/cosmos-react-core 10.0.0-build.10.0 → 10.0.0-build.10.2

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 (104) hide show
  1. package/lib/components/Checkbox/Checkbox.d.ts +1 -1
  2. package/lib/components/Checkbox/Checkbox.test-ids.d.ts +1 -1
  3. package/lib/components/Checkbox/Checkbox.test-ids.d.ts.map +1 -1
  4. package/lib/components/CheckboxGroup/CheckboxGroup.d.ts +1 -1
  5. package/lib/components/ColorPicker/ColorPicker.d.ts +1 -1
  6. package/lib/components/ColorPicker/ColorPicker.test-ids.d.ts +1 -1
  7. package/lib/components/ColorPicker/ColorPicker.test-ids.d.ts.map +1 -1
  8. package/lib/components/ComboBox/ComboBox.d.ts +1 -1
  9. package/lib/components/ComboBox/ComboxBox.test-ids.d.ts +1 -1
  10. package/lib/components/ComboBox/ComboxBox.test-ids.d.ts.map +1 -1
  11. package/lib/components/CompositeInput/CompositeInput.d.ts +1 -1
  12. package/lib/components/CompositeInput/CompositeInput.test-ids.d.ts +1 -1
  13. package/lib/components/CompositeInput/CompositeInput.test-ids.d.ts.map +1 -1
  14. package/lib/components/Currency/Currency.test-ids.d.ts +1 -1
  15. package/lib/components/Currency/Currency.test-ids.d.ts.map +1 -1
  16. package/lib/components/Currency/CurrencyInput.d.ts +1 -1
  17. package/lib/components/Currency/CurrencyInput.styles.d.ts +1 -1
  18. package/lib/components/DateTime/DateTime.test-ids.d.ts +10 -10
  19. package/lib/components/DateTime/DateTime.test-ids.d.ts.map +1 -1
  20. package/lib/components/DateTime/Input/DateInput.d.ts +1 -1
  21. package/lib/components/DateTime/Input/DateRangeInput.d.ts +1 -1
  22. package/lib/components/DateTime/Input/DateTimeInput.d.ts +1 -1
  23. package/lib/components/DateTime/Input/DayOfWeekInput.d.ts +1 -1
  24. package/lib/components/DateTime/Input/Duration/DurationInput.d.ts +1 -1
  25. package/lib/components/DateTime/Input/MonthInput.d.ts +1 -1
  26. package/lib/components/DateTime/Input/QuarterInput.d.ts +1 -1
  27. package/lib/components/DateTime/Input/TimeInput.d.ts +1 -1
  28. package/lib/components/DateTime/Input/TimeRangeInput.d.ts +1 -1
  29. package/lib/components/DateTime/Input/WeekInput.d.ts +1 -1
  30. package/lib/components/File/File.test-ids.d.ts +1 -1
  31. package/lib/components/File/File.test-ids.d.ts.map +1 -1
  32. package/lib/components/File/FileInput.d.ts +1 -1
  33. package/lib/components/File/FileInput.styles.d.ts +1 -1
  34. package/lib/components/FormField/FormField.d.ts +9 -2
  35. package/lib/components/FormField/FormField.d.ts.map +1 -1
  36. package/lib/components/FormField/FormField.js +73 -3
  37. package/lib/components/FormField/FormField.js.map +1 -1
  38. package/lib/components/FormField/FormField.test-ids.d.ts +2 -2
  39. package/lib/components/FormField/FormField.test-ids.d.ts.map +1 -1
  40. package/lib/components/FormField/FormField.test-ids.js +1 -0
  41. package/lib/components/FormField/FormField.test-ids.js.map +1 -1
  42. package/lib/components/FormField/index.d.ts +1 -1
  43. package/lib/components/FormField/index.d.ts.map +1 -1
  44. package/lib/components/FormField/index.js.map +1 -1
  45. package/lib/components/Input/Input.d.ts +5 -4
  46. package/lib/components/Input/Input.d.ts.map +1 -1
  47. package/lib/components/Input/Input.js +1 -0
  48. package/lib/components/Input/Input.js.map +1 -1
  49. package/lib/components/Input/Input.test-ids.d.ts +1 -1
  50. package/lib/components/Input/Input.test-ids.d.ts.map +1 -1
  51. package/lib/components/Location/Location.test-ids.d.ts +1 -1
  52. package/lib/components/Location/Location.test-ids.d.ts.map +1 -1
  53. package/lib/components/Location/LocationInput.d.ts +1 -1
  54. package/lib/components/MultiStepForm/FormProgress.styles.js +5 -5
  55. package/lib/components/MultiStepForm/FormProgress.styles.js.map +1 -1
  56. package/lib/components/Number/Number.test-ids.d.ts +2 -2
  57. package/lib/components/Number/Number.test-ids.d.ts.map +1 -1
  58. package/lib/components/Number/NumberInput.d.ts +1 -1
  59. package/lib/components/Number/NumberRangeInput.d.ts +1 -1
  60. package/lib/components/Phone/Phone.test-ids.d.ts +1 -1
  61. package/lib/components/Phone/Phone.test-ids.d.ts.map +1 -1
  62. package/lib/components/Phone/PhoneInput.d.ts +1 -1
  63. package/lib/components/RadioButton/RadioButton.d.ts +1 -1
  64. package/lib/components/RadioButton/RadioButton.test-ids.d.ts +1 -1
  65. package/lib/components/RadioButton/RadioButton.test-ids.d.ts.map +1 -1
  66. package/lib/components/RadioButtonGroup/RadioButtonGroup.d.ts +2 -2
  67. package/lib/components/RadioButtonGroup/RadioButtonGroup.d.ts.map +1 -1
  68. package/lib/components/RadioButtonGroup/RadioButtonGroup.js.map +1 -1
  69. package/lib/components/RadioCheck/RadioCheck.d.ts +1 -1
  70. package/lib/components/RadioCheck/RadioCheck.test-ids.d.ts +1 -1
  71. package/lib/components/RadioCheck/RadioCheck.test-ids.d.ts.map +1 -1
  72. package/lib/components/RadioCheckGroup/RadioCheckGroup.d.ts +7 -1
  73. package/lib/components/RadioCheckGroup/RadioCheckGroup.d.ts.map +1 -1
  74. package/lib/components/RadioCheckGroup/RadioCheckGroup.js +25 -14
  75. package/lib/components/RadioCheckGroup/RadioCheckGroup.js.map +1 -1
  76. package/lib/components/RadioCheckGroup/RadioCheckGroup.test-ids.d.ts +1 -1
  77. package/lib/components/RadioCheckGroup/RadioCheckGroup.test-ids.d.ts.map +1 -1
  78. package/lib/components/SearchInput/SearchInput.styles.d.ts +1 -1
  79. package/lib/components/Select/Select.d.ts +1 -1
  80. package/lib/components/Select/Select.test-ids.d.ts +1 -1
  81. package/lib/components/Select/Select.test-ids.d.ts.map +1 -1
  82. package/lib/components/Slider/Slider.d.ts +1 -1
  83. package/lib/components/Slider/Slider.test-ids.d.ts +1 -1
  84. package/lib/components/Slider/Slider.test-ids.d.ts.map +1 -1
  85. package/lib/components/TextArea/TextArea.d.ts +1 -1
  86. package/lib/components/TextArea/TextArea.test-ids.d.ts +1 -1
  87. package/lib/components/TextArea/TextArea.test-ids.d.ts.map +1 -1
  88. package/lib/hooks/useI18n.d.ts +2 -0
  89. package/lib/hooks/useI18n.d.ts.map +1 -1
  90. package/lib/i18n/default.d.ts +2 -0
  91. package/lib/i18n/default.d.ts.map +1 -1
  92. package/lib/i18n/default.js +2 -0
  93. package/lib/i18n/default.js.map +1 -1
  94. package/lib/i18n/i18n.d.ts +2 -0
  95. package/lib/i18n/i18n.d.ts.map +1 -1
  96. package/lib/styles/utils.d.ts +2 -0
  97. package/lib/styles/utils.d.ts.map +1 -1
  98. package/lib/styles/utils.js +7 -0
  99. package/lib/styles/utils.js.map +1 -1
  100. package/lib/theme/themes/aurigaDarkTheme.json +1 -1
  101. package/lib/theme/themes/aurigaTheme.json +3 -3
  102. package/lib/theme/themes/velaDarkTheme.json +1 -1
  103. package/lib/theme/themes/velaTheme.json +2 -2
  104. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"RadioButtonGroup.d.ts","sourceRoot":"","sources":["../../../src/components/RadioButtonGroup/RadioButtonGroup.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAK/D,MAAM,MAAM,qBAAqB,GAAG,IAAI,CAAC,oBAAoB,EAAE,iBAAiB,CAAC,CAAC;;;;AASlF,wBAAwE"}
1
+ {"version":3,"file":"RadioButtonGroup.d.ts","sourceRoot":"","sources":["../../../src/components/RadioButtonGroup/RadioButtonGroup.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAK/D,MAAM,MAAM,qBAAqB,GAAG,IAAI,CAAC,oBAAoB,EAAE,iBAAiB,GAAG,WAAW,CAAC,CAAC;;;;AAShG,wBAAwE"}
@@ -1 +1 @@
1
- {"version":3,"file":"RadioButtonGroup.js","sourceRoot":"","sources":["../../../src/components/RadioButtonGroup/RadioButtonGroup.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAInC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,eAAe,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,yBAAyB,EAAE,MAAM,6CAA6C,CAAC;AAMxF,MAAM,gBAAgB,GAAG,UAAU,CAGjC,SAAS,gBAAgB,CAAC,KAAK,EAAE,GAAG;IACpC,OAAO,KAAC,eAAe,OAAK,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,eAAe,SAAG,CAAC;AAClE,CAAC,CAAC,CAAC;AAEH,eAAe,WAAW,CAAC,gBAAgB,EAAE,yBAAyB,CAAC,CAAC","sourcesContent":["import { forwardRef } from 'react';\nimport type { PropsWithoutRef } from 'react';\n\nimport type { RefElement } from '../../types';\nimport { withTestIds } from '../../utils';\nimport RadioCheckGroup from '../RadioCheckGroup';\nimport type { RadioCheckGroupProps } from '../RadioCheckGroup';\nimport { getRadioCheckGroupTestIds } from '../RadioCheckGroup/RadioCheckGroup.test-ids';\n\n// Using Omit instead of OmitStrict as workaround for downstream consumers without inert type augmentation.\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport type RadioButtonGroupProps = Omit<RadioCheckGroupProps, 'arrowNavigation'>;\n\nconst RadioButtonGroup = forwardRef<\n RefElement<RadioButtonGroupProps>,\n PropsWithoutRef<RadioButtonGroupProps>\n>(function RadioButtonGroup(props, ref) {\n return <RadioCheckGroup {...props} ref={ref} arrowNavigation />;\n});\n\nexport default withTestIds(RadioButtonGroup, getRadioCheckGroupTestIds);\n"]}
1
+ {"version":3,"file":"RadioButtonGroup.js","sourceRoot":"","sources":["../../../src/components/RadioButtonGroup/RadioButtonGroup.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAInC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,eAAe,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,yBAAyB,EAAE,MAAM,6CAA6C,CAAC;AAMxF,MAAM,gBAAgB,GAAG,UAAU,CAGjC,SAAS,gBAAgB,CAAC,KAAK,EAAE,GAAG;IACpC,OAAO,KAAC,eAAe,OAAK,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,eAAe,SAAG,CAAC;AAClE,CAAC,CAAC,CAAC;AAEH,eAAe,WAAW,CAAC,gBAAgB,EAAE,yBAAyB,CAAC,CAAC","sourcesContent":["import { forwardRef } from 'react';\nimport type { PropsWithoutRef } from 'react';\n\nimport type { RefElement } from '../../types';\nimport { withTestIds } from '../../utils';\nimport RadioCheckGroup from '../RadioCheckGroup';\nimport type { RadioCheckGroupProps } from '../RadioCheckGroup';\nimport { getRadioCheckGroupTestIds } from '../RadioCheckGroup/RadioCheckGroup.test-ids';\n\n// Using Omit instead of OmitStrict as workaround for downstream consumers without inert type augmentation.\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport type RadioButtonGroupProps = Omit<RadioCheckGroupProps, 'arrowNavigation' | 'selectAll'>;\n\nconst RadioButtonGroup = forwardRef<\n RefElement<RadioButtonGroupProps>,\n PropsWithoutRef<RadioButtonGroupProps>\n>(function RadioButtonGroup(props, ref) {\n return <RadioCheckGroup {...props} ref={ref} arrowNavigation />;\n});\n\nexport default withTestIds(RadioButtonGroup, getRadioCheckGroupTestIds);\n"]}
@@ -44,7 +44,7 @@ export declare const StyledRadioCheck: import("styled-components/dist/types").IS
44
44
  }>> & string;
45
45
  export declare const StyledRadioCheckCard: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, Pick<RadioCheckProps, "disabled" | "readOnly" | "status">>> & string;
46
46
  declare const _default: import("react").ForwardRefExoticComponent<Omit<RadioCheckProps, "ref"> & import("react").RefAttributes<HTMLInputElement>> & {
47
- getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
47
+ getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
48
48
  };
49
49
  export default _default;
50
50
  //# sourceMappingURL=RadioCheck.d.ts.map
@@ -1,2 +1,2 @@
1
- export declare const getRadioCheckTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
1
+ export declare const getRadioCheckTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=RadioCheck.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RadioCheck.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/RadioCheck/RadioCheck.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,oBAAoB,0LAAkE,CAAC"}
1
+ {"version":3,"file":"RadioCheck.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/RadioCheck/RadioCheck.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,oBAAoB,qMAAkE,CAAC"}
@@ -47,6 +47,12 @@ export type RadioCheckGroupProps = WithAttributes<'fieldset', TestIdProp<typeof
47
47
  variant?: RadioCheckProps['variant'] | 'card-grid';
48
48
  /** Pass a heading and content to show additional information on the field. */
49
49
  additionalInfo?: FormControlProps['additionalInfo'];
50
+ /** Renders a single link-style action, "Select all" or "Unselect all", directly above the options. */
51
+ selectAll?: {
52
+ /** Shows "Unselect all" when true and "Select all" when false. */
53
+ hasSelection: boolean;
54
+ onClick: () => void;
55
+ };
50
56
  /**
51
57
  * Enables arrow key navigation between options in the group.
52
58
  * Disable for checkbox groups where each option is independently selectable.
@@ -58,7 +64,7 @@ export type RadioCheckGroupProps = WithAttributes<'fieldset', TestIdProp<typeof
58
64
  }>;
59
65
  export declare const StyledRadioCheckGroup: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").FieldsetHTMLAttributes<HTMLFieldSetElement>, HTMLFieldSetElement>, never>> & string;
60
66
  declare const _default: import("react").ForwardRefExoticComponent<Omit<RadioCheckGroupProps, "ref"> & import("react").RefAttributes<HTMLElement>> & {
61
- getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
67
+ getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
62
68
  };
63
69
  export default _default;
64
70
  //# sourceMappingURL=RadioCheckGroup.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RadioCheckGroup.d.ts","sourceRoot":"","sources":["../../../src/components/RadioCheckGroup/RadioCheckGroup.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,GAAG,EAEH,YAAY,EACZ,WAAW,EAEZ,MAAM,OAAO,CAAC;AAGf,OAAO,KAAK,EAAc,UAAU,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAEnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAUrD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAMhE,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAC/C,UAAU,EACV,UAAU,CAAC,OAAO,QAAQ,CAAC,GACzB,IAAI,CAAC,gBAAgB,EAAE,YAAY,CAAC,GAAG;IACrC,sDAAsD;IACtD,QAAQ,CAAC,EAAE,YAAY,GAAG,YAAY,EAAE,CAAC;IACzC;;;;OAIG;IACH,QAAQ,CA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,UAAU,CAAC,CAAC;IACxC,qFAAqF;IACrF,QAAQ,CAAC,EAAE,gBAAgB,CAAC,UAAU,CAAC,CAAC;IACxC;;;OAGG;IACH,MAAM,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC;IAClC;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,+FAA+F;IAC/F,IAAI,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAChC;;;OAGG;IACH,OAAO,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,GAAG,WAAW,CAAC;IACnD,8EAA8E;IAC9E,cAAc,CAAC,EAAE,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IACpD,sGAAsG;IACtG,SAAS,CAAC,EAAE;QACV,kEAAkE;QAClE,YAAY,EAAE,OAAO,CAAC;QACtB,OAAO,EAAE,MAAM,IAAI,CAAC;KACrB,CAAC;IACF;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,6CAA6C;IAC7C,GAAG,CAAC,EAAE,GAAG,CAAC,WAAW,CAAC,CAAC;CACxB,CACJ,CAAC;AAEF,eAAO,MAAM,qBAAqB,+OA8BhC,CAAC;;;;AAkPH,wBAAuE"}
@@ -1,15 +1,16 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { forwardRef, Children, cloneElement, useState, useEffect, useRef, useMemo } from 'react';
3
3
  import styled, { css } from 'styled-components';
4
4
  import FormField from '../FormField';
5
5
  import { StyledFormField, StyledFormFieldInfo } from '../FormField/FormField';
6
6
  import Flex from '../Flex';
7
7
  import { defaultThemeProp } from '../../theme';
8
- import { useArrows, useConsolidatedRef, useElement, useTestIds, useUID } from '../../hooks';
8
+ import { useArrows, useConsolidatedRef, useElement, useI18n, useTestIds, useUID } from '../../hooks';
9
9
  import { StyledImageContainer, StyledSelectionCard, StyledSelectionCardInline } from '../SelectionCard/SelectionCard.styles';
10
10
  import { getActiveElement, withTestIds } from '../../utils';
11
11
  import { StyledRadioCheck } from '../RadioCheck/RadioCheck';
12
12
  import EmptyState, { StyledEmptyState } from '../EmptyState';
13
+ import Button from '../Button';
13
14
  import { getRadioCheckGroupTestIds } from './RadioCheckGroup.test-ids';
14
15
  export const StyledRadioCheckGroup = styled.fieldset(({ theme }) => {
15
16
  return css `
@@ -43,6 +44,14 @@ export const StyledRadioCheckGroup = styled.fieldset(({ theme }) => {
43
44
  `;
44
45
  });
45
46
  StyledRadioCheckGroup.defaultProps = defaultThemeProp;
47
+ const StyledSelectAllButton = styled(Button)(({ theme }) => {
48
+ const { base: { spacing } } = theme;
49
+ return css `
50
+ align-self: start;
51
+ margin-block-end: calc(0.5 * ${spacing});
52
+ `;
53
+ });
54
+ StyledSelectAllButton.defaultProps = defaultThemeProp;
46
55
  const getCardGridColumns = (cardWidth) => css `
47
56
  @container (min-width: calc(2 * ${cardWidth})) {
48
57
  grid-template-columns: repeat(2, 1fr);
@@ -93,7 +102,8 @@ const StyledCardGrid = styled.div(({ theme, renderInline, autoStack, childCount
93
102
  StyledCardGrid.defaultProps = defaultThemeProp;
94
103
  const RadioCheckGroup = forwardRef(function RadioCheckGroup(props, ref) {
95
104
  const uid = useUID();
96
- const { testId, children, name = uid, disabled = false, required = false, onChange, readOnly, inline = false, autoStack = true, variant = 'simple', arrowNavigation = true, onClear, suggestion, ...restProps } = props;
105
+ const { testId, children, name = uid, disabled = false, required = false, onChange, readOnly, inline = false, autoStack = true, variant = 'simple', arrowNavigation = true, onClear, suggestion, selectAll, ...restProps } = props;
106
+ const t = useI18n();
97
107
  const testIds = useTestIds(testId, getRadioCheckGroupTestIds);
98
108
  const [optionsEl, setOptionsEl] = useElement();
99
109
  const [renderInline, setRenderInline] = useState(inline);
@@ -155,6 +165,17 @@ const RadioCheckGroup = forwardRef(function RadioCheckGroup(props, ref) {
155
165
  });
156
166
  });
157
167
  }, [children, name, disabled, readOnly, variant, onChange]);
168
+ const optionsContent = (() => {
169
+ if (!mapChildren) {
170
+ return _jsx(EmptyState, { variant: 'bordered' });
171
+ }
172
+ return variant === 'card-grid' ? (_jsx(StyledCardGrid, { ref: setOptionsEl, renderInline: renderInline, autoStack: autoStack, childCount: Children.count(children), children: mapChildren })) : (_jsx(Flex, { ref: setOptionsEl, container: {
173
+ direction: renderInline ? 'row' : 'column',
174
+ colGap: renderInline ? 1.5 : 2,
175
+ rowGap: variant === 'card' ? 1 : 0,
176
+ wrap: 'wrap'
177
+ }, children: mapChildren }));
178
+ })();
158
179
  return (_jsx(FormField, { testId: testIds, as: StyledRadioCheckGroup, ref: containerRef, name: name, disabled: disabled, required: required, ...restProps, inline: false, suggestion: suggestion, isRadioCheck: true, labelVariant: variant === 'card-grid' ? 'h3' : undefined, onClear: onClear,
159
180
  // Prevents blur when any input within the group is actively focused.
160
181
  onMouseDown: (e) => {
@@ -166,17 +187,7 @@ const RadioCheckGroup = forwardRef(function RadioCheckGroup(props, ref) {
166
187
  if (!(e.target instanceof Element) || !e.target.closest('label'))
167
188
  return;
168
189
  e.preventDefault();
169
- }, children: (() => {
170
- if (!mapChildren) {
171
- return _jsx(EmptyState, { variant: 'bordered' });
172
- }
173
- return variant === 'card-grid' ? (_jsx(StyledCardGrid, { ref: setOptionsEl, renderInline: renderInline, autoStack: autoStack, childCount: Children.count(children), children: mapChildren })) : (_jsx(Flex, { ref: setOptionsEl, container: {
174
- direction: renderInline ? 'row' : 'column',
175
- colGap: renderInline ? 1.5 : 2,
176
- rowGap: variant === 'card' ? 1 : 0,
177
- wrap: 'wrap'
178
- }, children: mapChildren }));
179
- })() }));
190
+ }, children: selectAll ? (_jsxs(_Fragment, { children: [_jsx(StyledSelectAllButton, { variant: 'link', onClick: selectAll.onClick, children: t(selectAll.hasSelection ? 'unselect_all' : 'select_all') }), optionsContent] })) : (optionsContent) }));
180
191
  });
181
192
  export default withTestIds(RadioCheckGroup, getRadioCheckGroupTestIds);
182
193
  //#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CAAC;AAEH,eAAe,WAAW,CAAC,eAAe,EAAE,yBAAyB,CAAC,CAAC","sourcesContent":["import { forwardRef, Children, cloneElement, useState, useEffect, useRef, useMemo } from 'react';\nimport type {\n Ref,\n PropsWithoutRef,\n ReactElement,\n ChangeEvent,\n MouseEvent as ReactMouseEvent\n} from 'react';\nimport styled, { css, type DefaultTheme } from 'styled-components';\n\nimport type { RefElement, TestIdProp, WithAttributes } from '../../types';\nimport FormField from '../FormField';\nimport type { FormFieldProps } from '../FormField';\nimport { StyledFormField, StyledFormFieldInfo } from '../FormField/FormField';\nimport type { FormControlProps } from '../FormControl';\nimport type { RadioCheckProps } from '../RadioCheck';\nimport Flex from '../Flex';\nimport { defaultThemeProp } from '../../theme';\nimport { useArrows, useConsolidatedRef, useElement, useTestIds, useUID } from '../../hooks';\nimport {\n StyledImageContainer,\n StyledSelectionCard,\n StyledSelectionCardInline\n} from '../SelectionCard/SelectionCard.styles';\nimport { getActiveElement, withTestIds } from '../../utils';\nimport type { elements } from '../FormField/FormField.test-ids';\nimport { StyledRadioCheck } from '../RadioCheck/RadioCheck';\nimport EmptyState, { StyledEmptyState } from '../EmptyState';\n\nimport { getRadioCheckGroupTestIds } from './RadioCheckGroup.test-ids';\n\nexport type RadioCheckGroupProps = WithAttributes<\n 'fieldset',\n TestIdProp<typeof elements> &\n Pick<FormControlProps, 'suggestion'> & {\n /** Accepts Checkboxes or RadioButtons as children. */\n children?: ReactElement | ReactElement[];\n /**\n * Conveniently pass an onChange handler to the group to be notified when any of the inputs change.\n * Additionally, onChange can be passed to individual children.\n * Both handlers will be called, child followed by group.\n */\n onChange?: (e: ChangeEvent<HTMLInputElement>) => void;\n /** Callback invoked when the clear button is clicked. If provided will render the clear button. */\n onClear?: FormFieldProps['onClear'];\n /** Set visual state based on a validation state. */\n status?: FormControlProps['status'];\n /** Pass a string or a fragment with an Icon and string. */\n label?: FormControlProps['label'];\n /** Visually hides the label region. */\n labelHidden?: FormControlProps['labelHidden'];\n /** It is recommended to pass a simple string to offer guidance. Text will be styled based on status prop. */\n info?: FormControlProps['info'];\n /** Indicate if the field is required. The browser defaults to false. */\n required?: FormControlProps['required'];\n /** Disable the control. The browser defaults to false. */\n disabled?: FormControlProps['disabled'];\n /** Makes the input non editable and non clickable. The browser defaults to false. */\n readOnly?: FormControlProps['readOnly'];\n /**\n * Layout field elements inline in a row.\n * @default false\n */\n inline?: FormFieldProps['inline'];\n /** Used to toggle the auto stacking feature of an inlined group.\n * @default true\n */\n autoStack?: boolean;\n /** Sets html name attribute for the underlying control. Useful for mapping to a data field. */\n name?: FormControlProps['name'];\n /**\n * Controls the styling of the child RadioChecks.\n * @default 'simple'\n */\n variant?: RadioCheckProps['variant'] | 'card-grid';\n /** Pass a heading and content to show additional information on the field. */\n additionalInfo?: FormControlProps['additionalInfo'];\n /**\n * Enables arrow key navigation between options in the group.\n * Disable for checkbox groups where each option is independently selectable.\n * @default true\n */\n arrowNavigation?: boolean;\n /** Ref forwarded to the wrapping element. */\n ref?: Ref<HTMLElement>;\n }\n>;\n\nexport const StyledRadioCheckGroup = styled.fieldset(({ theme }) => {\n return css`\n container-type: inline-size;\n flex-wrap: nowrap;\n\n &[disabled] {\n > ${StyledFormField} {\n opacity: unset;\n }\n }\n\n ${StyledSelectionCard} {\n max-width: 100%;\n }\n\n ${StyledSelectionCardInline} ${StyledImageContainer} {\n /* To enlarge the image containers to the size of the biggest one */\n min-height: 100%;\n }\n\n ${StyledRadioCheck} > ${StyledFormFieldInfo} {\n display: none;\n }\n\n ${StyledEmptyState} {\n border: 0.0625rem solid ${theme.base.palette['border-line']};\n border-radius: ${theme.components.card['border-radius']};\n padding: calc(2 * ${theme.base.spacing});\n }\n `;\n});\n\nStyledRadioCheckGroup.defaultProps = defaultThemeProp;\n\nconst getCardGridColumns = (cardWidth: string) => css`\n @container (min-width: calc(2 * ${cardWidth})) {\n grid-template-columns: repeat(2, 1fr);\n }\n\n @container (min-width: calc(3 * ${cardWidth})) {\n grid-template-columns: repeat(3, 1fr);\n }\n\n @container (min-width: calc(4 * ${cardWidth})) {\n grid-template-columns: repeat(4, 1fr);\n }\n`;\n\nconst getCardGridContainerStyles = (theme: DefaultTheme) => {\n const defaultCardWidth = theme.base['content-width'].sm;\n const inlineImageCardWidth = theme.base['content-width'].md;\n return css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: 1fr;\n grid-auto-rows: 1fr;\n\n ${getCardGridColumns(defaultCardWidth)}\n\n &:has(${StyledSelectionCardInline}) {\n ${getCardGridColumns(inlineImageCardWidth)}\n }\n `;\n};\n\nconst StyledCardGrid = styled.div<{\n renderInline: boolean;\n autoStack: boolean;\n childCount: number;\n}>(({ theme, renderInline, autoStack, childCount }) => {\n if (!renderInline) {\n return css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: minmax(min-content, max-content);\n grid-auto-rows: 1fr;\n `;\n }\n\n return autoStack\n ? getCardGridContainerStyles(theme)\n : css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: repeat(${childCount}, 1fr);\n grid-auto-rows: 1fr;\n `;\n});\n\nStyledCardGrid.defaultProps = defaultThemeProp;\n\nconst RadioCheckGroup = forwardRef<\n RefElement<RadioCheckGroupProps>,\n PropsWithoutRef<RadioCheckGroupProps>\n>(function RadioCheckGroup(props, ref) {\n const uid = useUID();\n const {\n testId,\n children,\n name = uid,\n disabled = false,\n required = false,\n onChange,\n readOnly,\n inline = false,\n autoStack = true,\n variant = 'simple',\n arrowNavigation = true,\n onClear,\n suggestion,\n ...restProps\n } = props;\n\n const testIds = useTestIds(testId, getRadioCheckGroupTestIds);\n const [optionsEl, setOptionsEl] = useElement<HTMLDivElement>();\n\n const [renderInline, setRenderInline] = useState(inline);\n const renderInlineRef = useRef(inline);\n const minInlineWidth = useRef(0);\n const containerRef = useConsolidatedRef(ref);\n const skipRef = useRef<HTMLElement>(null);\n\n useArrows(\n arrowNavigation ? containerRef : skipRef,\n {\n selector: '[data-main-focus]',\n cycle: false,\n dir: 'both'\n },\n [children]\n );\n\n useEffect(() => {\n setRenderInline(inline);\n if (inline && optionsEl && optionsEl.lastChild && autoStack) {\n const intersectionObserver = new IntersectionObserver(\n entries => {\n if (entries[0].intersectionRatio < 1) {\n if (entries[0].rootBounds) minInlineWidth.current = entries[0].rootBounds.width + 1;\n renderInlineRef.current = false;\n setRenderInline(false);\n }\n },\n { root: optionsEl, threshold: 1 }\n );\n\n const resizeObserver = new ResizeObserver(entries => {\n if (!renderInlineRef.current && entries[0].contentRect.width > minInlineWidth.current) {\n renderInlineRef.current = true;\n setRenderInline(true);\n }\n });\n\n intersectionObserver.observe(optionsEl.lastChild as Element);\n resizeObserver.observe(optionsEl);\n\n return () => {\n intersectionObserver.disconnect();\n resizeObserver.disconnect();\n };\n }\n }, [optionsEl, inline, autoStack]);\n\n const mapChildren = useMemo(() => {\n if (!children || Children.toArray(children).filter(Boolean).length === 0) return;\n\n return Children.map(children, child => {\n if (!child) return null;\n return cloneElement(child, {\n name,\n status: restProps.status,\n disabled: disabled || child.props.disabled,\n readOnly: readOnly || child.props.readOnly,\n variant: variant === 'card-grid' ? 'card' : variant,\n suppressAnnouncements: true,\n onChange: onChange\n ? (e: ChangeEvent<HTMLInputElement>) => {\n if (!(readOnly || child.props.readOnly)) {\n child.props.onChange?.(e);\n onChange(e);\n }\n }\n : child.props.onChange\n });\n });\n }, [children, name, disabled, readOnly, variant, onChange]);\n\n return (\n <FormField\n testId={testIds}\n as={StyledRadioCheckGroup}\n ref={containerRef}\n name={name}\n disabled={disabled}\n required={required}\n {...restProps}\n inline={false}\n suggestion={suggestion}\n isRadioCheck\n labelVariant={variant === 'card-grid' ? 'h3' : undefined}\n onClear={onClear}\n // Prevents blur when any input within the group is actively focused.\n onMouseDown={(e: ReactMouseEvent<HTMLFieldSetElement>) => {\n restProps.onMouseDown?.(e);\n\n if (!containerRef.current) return;\n\n if (!containerRef.current.contains(getActiveElement())) return;\n\n if (!(e.target instanceof Element) || !e.target.closest('label')) return;\n\n e.preventDefault();\n }}\n >\n {(() => {\n if (!mapChildren) {\n return <EmptyState variant='bordered' />;\n }\n\n return variant === 'card-grid' ? (\n <StyledCardGrid\n ref={setOptionsEl}\n renderInline={renderInline}\n autoStack={autoStack}\n childCount={Children.count(children)}\n >\n {mapChildren}\n </StyledCardGrid>\n ) : (\n <Flex\n ref={setOptionsEl}\n container={{\n direction: renderInline ? 'row' : 'column',\n colGap: renderInline ? 1.5 : 2,\n rowGap: variant === 'card' ? 1 : 0,\n wrap: 'wrap'\n }}\n >\n {mapChildren}\n </Flex>\n );\n })()}\n </FormField>\n );\n});\n\nexport default withTestIds(RadioCheckGroup, getRadioCheckGroupTestIds);\n"]}
1
+ {"version":3,"file":"RadioCheckGroup.js","sourceRoot":"","sources":["../../../src/components/RadioCheckGroup/RadioCheckGroup.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAQjG,OAAO,MAAM,EAAE,EAAE,GAAG,EAAqB,MAAM,mBAAmB,CAAC;AAGnE,OAAO,SAAS,MAAM,cAAc,CAAC;AAErC,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAG9E,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EACL,SAAS,EACT,kBAAkB,EAClB,UAAU,EACV,OAAO,EACP,UAAU,EACV,MAAM,EACP,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,oBAAoB,EACpB,mBAAmB,EACnB,yBAAyB,EAC1B,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,UAAU,EAAE,EAAE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M,EAAE,OAAO,EACf,EAAE,EAAE,qBAAqB,EACzB,GAAG,EAAE,YAAY,EACjB,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,QAAQ,KACd,SAAS,EACb,MAAM,EAAE,KAAK,EACb,UAAU,EAAE,UAAU,EACtB,YAAY,QACZ,YAAY,EAAE,OAAO,KAAK,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,EACxD,OAAO,EAAE,OAAO;QAChB,qEAAqE;QACrE,WAAW,EAAE,CAAC,CAAuC,EAAE,EAAE;YACvD,SAAS,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC;YAE3B,IAAI,CAAC,YAAY,CAAC,OAAO;gBAAE,OAAO;YAElC,IAAI,CAAC,YAAY,CAAC,OAAO,CAAC,QAAQ,CAAC,gBAAgB,EAAE,CAAC;gBAAE,OAAO;YAE/D,IAAI,CAAC,CAAC,CAAC,CAAC,MAAM,YAAY,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC;gBAAE,OAAO;YAEzE,CAAC,CAAC,cAAc,EAAE,CAAC;QACrB,CAAC,YAEA,SAAS,CAAC,CAAC,CAAC,CACX,8BACE,KAAC,qBAAqB,IAAC,OAAO,EAAC,MAAM,EAAC,OAAO,EAAE,SAAS,CAAC,OAAO,YAC7D,CAAC,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,YAAY,CAAC,GACpC,EACvB,cAAc,IACd,CACJ,CAAC,CAAC,CAAC,CACF,cAAc,CACf,GACS,CACb,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,eAAe,WAAW,CAAC,eAAe,EAAE,yBAAyB,CAAC,CAAC","sourcesContent":["import { forwardRef, Children, cloneElement, useState, useEffect, useRef, useMemo } from 'react';\nimport type {\n Ref,\n PropsWithoutRef,\n ReactElement,\n ChangeEvent,\n MouseEvent as ReactMouseEvent\n} from 'react';\nimport styled, { css, type DefaultTheme } from 'styled-components';\n\nimport type { RefElement, TestIdProp, WithAttributes } from '../../types';\nimport FormField from '../FormField';\nimport type { FormFieldProps } from '../FormField';\nimport { StyledFormField, StyledFormFieldInfo } from '../FormField/FormField';\nimport type { FormControlProps } from '../FormControl';\nimport type { RadioCheckProps } from '../RadioCheck';\nimport Flex from '../Flex';\nimport { defaultThemeProp } from '../../theme';\nimport {\n useArrows,\n useConsolidatedRef,\n useElement,\n useI18n,\n useTestIds,\n useUID\n} from '../../hooks';\nimport {\n StyledImageContainer,\n StyledSelectionCard,\n StyledSelectionCardInline\n} from '../SelectionCard/SelectionCard.styles';\nimport { getActiveElement, withTestIds } from '../../utils';\nimport type { elements } from '../FormField/FormField.test-ids';\nimport { StyledRadioCheck } from '../RadioCheck/RadioCheck';\nimport EmptyState, { StyledEmptyState } from '../EmptyState';\nimport Button from '../Button';\n\nimport { getRadioCheckGroupTestIds } from './RadioCheckGroup.test-ids';\n\nexport type RadioCheckGroupProps = WithAttributes<\n 'fieldset',\n TestIdProp<typeof elements> &\n Pick<FormControlProps, 'suggestion'> & {\n /** Accepts Checkboxes or RadioButtons as children. */\n children?: ReactElement | ReactElement[];\n /**\n * Conveniently pass an onChange handler to the group to be notified when any of the inputs change.\n * Additionally, onChange can be passed to individual children.\n * Both handlers will be called, child followed by group.\n */\n onChange?: (e: ChangeEvent<HTMLInputElement>) => void;\n /** Callback invoked when the clear button is clicked. If provided will render the clear button. */\n onClear?: FormFieldProps['onClear'];\n /** Set visual state based on a validation state. */\n status?: FormControlProps['status'];\n /** Pass a string or a fragment with an Icon and string. */\n label?: FormControlProps['label'];\n /** Visually hides the label region. */\n labelHidden?: FormControlProps['labelHidden'];\n /** It is recommended to pass a simple string to offer guidance. Text will be styled based on status prop. */\n info?: FormControlProps['info'];\n /** Indicate if the field is required. The browser defaults to false. */\n required?: FormControlProps['required'];\n /** Disable the control. The browser defaults to false. */\n disabled?: FormControlProps['disabled'];\n /** Makes the input non editable and non clickable. The browser defaults to false. */\n readOnly?: FormControlProps['readOnly'];\n /**\n * Layout field elements inline in a row.\n * @default false\n */\n inline?: FormFieldProps['inline'];\n /** Used to toggle the auto stacking feature of an inlined group.\n * @default true\n */\n autoStack?: boolean;\n /** Sets html name attribute for the underlying control. Useful for mapping to a data field. */\n name?: FormControlProps['name'];\n /**\n * Controls the styling of the child RadioChecks.\n * @default 'simple'\n */\n variant?: RadioCheckProps['variant'] | 'card-grid';\n /** Pass a heading and content to show additional information on the field. */\n additionalInfo?: FormControlProps['additionalInfo'];\n /** Renders a single link-style action, \"Select all\" or \"Unselect all\", directly above the options. */\n selectAll?: {\n /** Shows \"Unselect all\" when true and \"Select all\" when false. */\n hasSelection: boolean;\n onClick: () => void;\n };\n /**\n * Enables arrow key navigation between options in the group.\n * Disable for checkbox groups where each option is independently selectable.\n * @default true\n */\n arrowNavigation?: boolean;\n /** Ref forwarded to the wrapping element. */\n ref?: Ref<HTMLElement>;\n }\n>;\n\nexport const StyledRadioCheckGroup = styled.fieldset(({ theme }) => {\n return css`\n container-type: inline-size;\n flex-wrap: nowrap;\n\n &[disabled] {\n > ${StyledFormField} {\n opacity: unset;\n }\n }\n\n ${StyledSelectionCard} {\n max-width: 100%;\n }\n\n ${StyledSelectionCardInline} ${StyledImageContainer} {\n /* To enlarge the image containers to the size of the biggest one */\n min-height: 100%;\n }\n\n ${StyledRadioCheck} > ${StyledFormFieldInfo} {\n display: none;\n }\n\n ${StyledEmptyState} {\n border: 0.0625rem solid ${theme.base.palette['border-line']};\n border-radius: ${theme.components.card['border-radius']};\n padding: calc(2 * ${theme.base.spacing});\n }\n `;\n});\n\nStyledRadioCheckGroup.defaultProps = defaultThemeProp;\n\nconst StyledSelectAllButton = styled(Button)(({ theme }) => {\n const {\n base: { spacing }\n } = theme;\n\n return css`\n align-self: start;\n margin-block-end: calc(0.5 * ${spacing});\n `;\n});\n\nStyledSelectAllButton.defaultProps = defaultThemeProp;\n\nconst getCardGridColumns = (cardWidth: string) => css`\n @container (min-width: calc(2 * ${cardWidth})) {\n grid-template-columns: repeat(2, 1fr);\n }\n\n @container (min-width: calc(3 * ${cardWidth})) {\n grid-template-columns: repeat(3, 1fr);\n }\n\n @container (min-width: calc(4 * ${cardWidth})) {\n grid-template-columns: repeat(4, 1fr);\n }\n`;\n\nconst getCardGridContainerStyles = (theme: DefaultTheme) => {\n const defaultCardWidth = theme.base['content-width'].sm;\n const inlineImageCardWidth = theme.base['content-width'].md;\n return css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: 1fr;\n grid-auto-rows: 1fr;\n\n ${getCardGridColumns(defaultCardWidth)}\n\n &:has(${StyledSelectionCardInline}) {\n ${getCardGridColumns(inlineImageCardWidth)}\n }\n `;\n};\n\nconst StyledCardGrid = styled.div<{\n renderInline: boolean;\n autoStack: boolean;\n childCount: number;\n}>(({ theme, renderInline, autoStack, childCount }) => {\n if (!renderInline) {\n return css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: minmax(min-content, max-content);\n grid-auto-rows: 1fr;\n `;\n }\n\n return autoStack\n ? getCardGridContainerStyles(theme)\n : css`\n display: grid;\n gap: ${theme.base.spacing};\n grid-template-columns: repeat(${childCount}, 1fr);\n grid-auto-rows: 1fr;\n `;\n});\n\nStyledCardGrid.defaultProps = defaultThemeProp;\n\nconst RadioCheckGroup = forwardRef<\n RefElement<RadioCheckGroupProps>,\n PropsWithoutRef<RadioCheckGroupProps>\n>(function RadioCheckGroup(props, ref) {\n const uid = useUID();\n const {\n testId,\n children,\n name = uid,\n disabled = false,\n required = false,\n onChange,\n readOnly,\n inline = false,\n autoStack = true,\n variant = 'simple',\n arrowNavigation = true,\n onClear,\n suggestion,\n selectAll,\n ...restProps\n } = props;\n\n const t = useI18n();\n const testIds = useTestIds(testId, getRadioCheckGroupTestIds);\n const [optionsEl, setOptionsEl] = useElement<HTMLDivElement>();\n\n const [renderInline, setRenderInline] = useState(inline);\n const renderInlineRef = useRef(inline);\n const minInlineWidth = useRef(0);\n const containerRef = useConsolidatedRef(ref);\n const skipRef = useRef<HTMLElement>(null);\n\n useArrows(\n arrowNavigation ? containerRef : skipRef,\n {\n selector: '[data-main-focus]',\n cycle: false,\n dir: 'both'\n },\n [children]\n );\n\n useEffect(() => {\n setRenderInline(inline);\n if (inline && optionsEl && optionsEl.lastChild && autoStack) {\n const intersectionObserver = new IntersectionObserver(\n entries => {\n if (entries[0].intersectionRatio < 1) {\n if (entries[0].rootBounds) minInlineWidth.current = entries[0].rootBounds.width + 1;\n renderInlineRef.current = false;\n setRenderInline(false);\n }\n },\n { root: optionsEl, threshold: 1 }\n );\n\n const resizeObserver = new ResizeObserver(entries => {\n if (!renderInlineRef.current && entries[0].contentRect.width > minInlineWidth.current) {\n renderInlineRef.current = true;\n setRenderInline(true);\n }\n });\n\n intersectionObserver.observe(optionsEl.lastChild as Element);\n resizeObserver.observe(optionsEl);\n\n return () => {\n intersectionObserver.disconnect();\n resizeObserver.disconnect();\n };\n }\n }, [optionsEl, inline, autoStack]);\n\n const mapChildren = useMemo(() => {\n if (!children || Children.toArray(children).filter(Boolean).length === 0) return;\n\n return Children.map(children, child => {\n if (!child) return null;\n return cloneElement(child, {\n name,\n status: restProps.status,\n disabled: disabled || child.props.disabled,\n readOnly: readOnly || child.props.readOnly,\n variant: variant === 'card-grid' ? 'card' : variant,\n suppressAnnouncements: true,\n onChange: onChange\n ? (e: ChangeEvent<HTMLInputElement>) => {\n if (!(readOnly || child.props.readOnly)) {\n child.props.onChange?.(e);\n onChange(e);\n }\n }\n : child.props.onChange\n });\n });\n }, [children, name, disabled, readOnly, variant, onChange]);\n\n const optionsContent = (() => {\n if (!mapChildren) {\n return <EmptyState variant='bordered' />;\n }\n\n return variant === 'card-grid' ? (\n <StyledCardGrid\n ref={setOptionsEl}\n renderInline={renderInline}\n autoStack={autoStack}\n childCount={Children.count(children)}\n >\n {mapChildren}\n </StyledCardGrid>\n ) : (\n <Flex\n ref={setOptionsEl}\n container={{\n direction: renderInline ? 'row' : 'column',\n colGap: renderInline ? 1.5 : 2,\n rowGap: variant === 'card' ? 1 : 0,\n wrap: 'wrap'\n }}\n >\n {mapChildren}\n </Flex>\n );\n })();\n\n return (\n <FormField\n testId={testIds}\n as={StyledRadioCheckGroup}\n ref={containerRef}\n name={name}\n disabled={disabled}\n required={required}\n {...restProps}\n inline={false}\n suggestion={suggestion}\n isRadioCheck\n labelVariant={variant === 'card-grid' ? 'h3' : undefined}\n onClear={onClear}\n // Prevents blur when any input within the group is actively focused.\n onMouseDown={(e: ReactMouseEvent<HTMLFieldSetElement>) => {\n restProps.onMouseDown?.(e);\n\n if (!containerRef.current) return;\n\n if (!containerRef.current.contains(getActiveElement())) return;\n\n if (!(e.target instanceof Element) || !e.target.closest('label')) return;\n\n e.preventDefault();\n }}\n >\n {selectAll ? (\n <>\n <StyledSelectAllButton variant='link' onClick={selectAll.onClick}>\n {t(selectAll.hasSelection ? 'unselect_all' : 'select_all')}\n </StyledSelectAllButton>\n {optionsContent}\n </>\n ) : (\n optionsContent\n )}\n </FormField>\n );\n});\n\nexport default withTestIds(RadioCheckGroup, getRadioCheckGroupTestIds);\n"]}
@@ -1,2 +1,2 @@
1
- export declare const getRadioCheckGroupTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
1
+ export declare const getRadioCheckGroupTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=RadioCheckGroup.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RadioCheckGroup.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/RadioCheckGroup/RadioCheckGroup.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,yBAAyB,+KAA6D,CAAC"}
1
+ {"version":3,"file":"RadioCheckGroup.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/RadioCheckGroup/RadioCheckGroup.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,yBAAyB,0LAA6D,CAAC"}
@@ -13,7 +13,7 @@ export declare const StyledSearchIcon: import("styled-components/dist/types").IS
13
13
  export declare const StyledSearchTextInput: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<Omit<import("../Input").InputProps, "ref"> & import("react").RefAttributes<HTMLInputElement>, "ref"> & {
14
14
  ref?: ((instance: HTMLInputElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLInputElement> | null | undefined;
15
15
  }, never>> & string & Omit<import("react").ForwardRefExoticComponent<Omit<import("../Input").InputProps, "ref"> & import("react").RefAttributes<HTMLInputElement>> & {
16
- getTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
16
+ getTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
17
17
  }, keyof import("react").Component<any, {}, any>>;
18
18
  export declare const StyledSearchInput: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
19
19
  hasFilters: boolean;
@@ -45,7 +45,7 @@ export declare const StyledSelect: import("styled-components/dist/types").IStyle
45
45
  hasSuggestion?: boolean;
46
46
  }>> & string;
47
47
  declare const _default: ForwardRefForwardPropsComponent<SelectProps> & {
48
- getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
48
+ getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
49
49
  };
50
50
  export default _default;
51
51
  //# sourceMappingURL=Select.d.ts.map
@@ -1,2 +1,2 @@
1
- export declare const getSelectTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
1
+ export declare const getSelectTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=Select.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Select.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/Select/Select.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,0LAA6D,CAAC"}
1
+ {"version":3,"file":"Select.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/Select/Select.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,qMAA6D,CAAC"}
@@ -2,7 +2,7 @@ import type { FunctionComponent } from 'react';
2
2
  import type { ForwardProps } from '../../types';
3
3
  import type SliderProps from './Slider.types';
4
4
  declare const _default: FunctionComponent<SliderProps & ForwardProps> & {
5
- getTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
5
+ getTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
6
6
  };
7
7
  export default _default;
8
8
  //# sourceMappingURL=Slider.d.ts.map
@@ -1,2 +1,2 @@
1
- export declare const getSliderTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
1
+ export declare const getSliderTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=Slider.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Slider.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/Slider/Slider.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,0LAA6D,CAAC"}
1
+ {"version":3,"file":"Slider.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/Slider/Slider.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,qMAA6D,CAAC"}
@@ -31,7 +31,7 @@ export interface TextAreaProps extends FormControlProps, BaseProps, NoChildrenPr
31
31
  onBlur?: FocusEventHandler<HTMLTextAreaElement>;
32
32
  }
33
33
  declare const _default: FC<TextAreaProps & ForwardProps> & {
34
- getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
34
+ getTestIds: (testIdProp?: TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
35
35
  };
36
36
  export default _default;
37
37
  //# sourceMappingURL=TextArea.d.ts.map
@@ -1,2 +1,2 @@
1
- export declare const getTextAreaTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
1
+ export declare const getTextAreaTestIds: (testIdProp?: import("../..").TestIdProp["testId"]) => import("../..").TestIdsRecord<readonly ["control", "label", "info", "additional-info", "actions", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=TextArea.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextArea.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/TextArea/TextArea.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB,0LAAgE,CAAC"}
1
+ {"version":3,"file":"TextArea.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/TextArea/TextArea.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB,qMAAgE,CAAC"}
@@ -149,6 +149,8 @@ declare const useI18n: () => import("..").TranslationFunction<Readonly<{
149
149
  show_all: string;
150
150
  clear_all: string;
151
151
  clear_selection: string;
152
+ select_all: string;
153
+ unselect_all: string;
152
154
  link_open_in_tab_text: string;
153
155
  link_open_text: string;
154
156
  edit_details: string;
@@ -1 +1 @@
1
- {"version":3,"file":"useI18n.d.ts","sourceRoot":"","sources":["../../src/hooks/useI18n.ts"],"names":[],"mappings":"AAMA;;;GAGG;AACH,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAGZ,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -145,6 +145,8 @@ declare const _default: {
145
145
  show_all: string;
146
146
  clear_all: string;
147
147
  clear_selection: string;
148
+ select_all: string;
149
+ unselect_all: string;
148
150
  link_open_in_tab_text: string;
149
151
  link_open_text: string;
150
152
  edit_details: string;
@@ -1 +1 @@
1
- {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../src/i18n/default.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;IA2C/B,wCAAwC;;IAGxC,oCAAoC;;;;;;;;;;IAYpC,uCAAuC;;;;;;;;;;;IAavC,6CAA6C;;;;;;;IAQ7C,uCAAuC;;;;;;;;IAUvC,yCAAyC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAvzE3C,wBAo3EE"}
@@ -151,6 +151,8 @@ export default {
151
151
  show_all: 'Show all',
152
152
  clear_all: 'Clear all',
153
153
  clear_selection: 'Clear selection',
154
+ select_all: 'Select all',
155
+ unselect_all: 'Unselect all',
154
156
  link_open_in_tab_text: 'Open in tab',
155
157
  link_open_text: 'Open',
156
158
  edit_details: 'Edit details',