@oracle/oraclejet-preact 17.0.4 → 17.0.6

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 (87) hide show
  1. package/amd/CheckboxSet-9c883a32.js +2 -0
  2. package/{cjs/CheckboxSet-13a5c10c.js.map → amd/CheckboxSet-9c883a32.js.map} +1 -1
  3. package/amd/TextArea-2c7af40c.js +2 -0
  4. package/amd/TextArea-2c7af40c.js.map +1 -0
  5. package/amd/TextAreaAutosize-9dc5bffe.js +2 -0
  6. package/amd/{TextAreaAutosize-0a023972.js.map → TextAreaAutosize-9dc5bffe.js.map} +1 -1
  7. package/amd/Theme-redwood/theme.css +216 -216
  8. package/amd/Theme-stable/theme.css +352 -352
  9. package/amd/UNSAFE_CheckboxItem.js +1 -1
  10. package/amd/UNSAFE_CheckboxItem.js.map +1 -1
  11. package/amd/UNSAFE_CheckboxSet.js +1 -1
  12. package/amd/UNSAFE_CheckboxSet.js.map +1 -1
  13. package/amd/UNSAFE_TextArea.js +1 -1
  14. package/amd/UNSAFE_TextAreaAutosize.js +1 -1
  15. package/cjs/BaseNavigationListItem-175a3f35.js +49 -0
  16. package/cjs/BaseNavigationListItem-175a3f35.js.map +1 -0
  17. package/cjs/CheckboxSetContext-c62db26d.js +12 -0
  18. package/{es/CheckboxSetContext-1be56556.js.map → cjs/CheckboxSetContext-c62db26d.js.map} +1 -1
  19. package/cjs/{InputDatePicker-005c03d0.js → InputDatePicker-91be7790.js} +2 -2
  20. package/cjs/{InputDatePicker-005c03d0.js.map → InputDatePicker-91be7790.js.map} +1 -1
  21. package/cjs/{NavigationListItem-12a76e7d.js → NavigationList-5218562e.js} +3 -18
  22. package/cjs/NavigationList-5218562e.js.map +1 -0
  23. package/cjs/NavigationListItem-b80c41dc.js +12 -0
  24. package/cjs/NavigationListItem-b80c41dc.js.map +1 -0
  25. package/cjs/{OverflowTabBarItem-c0a592fd.js → OverflowTabBarItem-1de46588.js} +5 -4
  26. package/cjs/{OverflowTabBarItem-c0a592fd.js.map → OverflowTabBarItem-1de46588.js.map} +1 -1
  27. package/cjs/{RemovableNavigationListItem-6231df42.js → RemovableNavigationListItem-eb2c8156.js} +4 -3
  28. package/cjs/{RemovableNavigationListItem-6231df42.js.map → RemovableNavigationListItem-eb2c8156.js.map} +1 -1
  29. package/cjs/{ReorderableTabBar-5743c66a.js → ReorderableTabBar-025a0d71.js} +2 -2
  30. package/cjs/{ReorderableTabBar-5743c66a.js.map → ReorderableTabBar-025a0d71.js.map} +1 -1
  31. package/cjs/{TabBar-73bb6c97.js → TabBar-e77706d0.js} +6 -1
  32. package/cjs/{TabBar-73bb6c97.js.map → TabBar-e77706d0.js.map} +1 -1
  33. package/cjs/{TabBarMixed-426fcaf1.js → TabBarMixed-bc696a46.js} +6 -1
  34. package/cjs/{TabBarMixed-426fcaf1.js.map → TabBarMixed-bc696a46.js.map} +1 -1
  35. package/cjs/Theme-redwood/theme.css +89 -89
  36. package/cjs/Theme-stable/theme.css +217 -217
  37. package/cjs/UNSAFE_CheckboxItem.js +30 -80
  38. package/cjs/UNSAFE_CheckboxItem.js.map +1 -1
  39. package/cjs/UNSAFE_CheckboxSet.js +44 -15
  40. package/cjs/UNSAFE_CheckboxSet.js.map +1 -1
  41. package/cjs/UNSAFE_InputDatePicker.js +87 -87
  42. package/cjs/UNSAFE_NavigationList.js +16 -14
  43. package/cjs/UNSAFE_NavigationList.js.map +1 -1
  44. package/cjs/UNSAFE_NavigationListCommon.js +55 -54
  45. package/cjs/UNSAFE_NavigationListCommon.js.map +1 -1
  46. package/cjs/UNSAFE_OverflowTabBar.js +23 -21
  47. package/cjs/UNSAFE_OverflowTabBar.js.map +1 -1
  48. package/cjs/UNSAFE_ReorderableTabBar.js +21 -7
  49. package/cjs/UNSAFE_ReorderableTabBar.js.map +1 -1
  50. package/cjs/UNSAFE_TabBar.js +24 -22
  51. package/cjs/UNSAFE_TabBar.js.map +1 -1
  52. package/cjs/UNSAFE_TabBarCommon.js +20 -18
  53. package/cjs/UNSAFE_TabBarCommon.js.map +1 -1
  54. package/cjs/UNSAFE_TabBarMixed.js +24 -22
  55. package/cjs/UNSAFE_TabBarMixed.js.map +1 -1
  56. package/cjs/{BaseNavigationListItem-070d75bc.js → useNavigationListItem-74009187.js} +2 -40
  57. package/cjs/useNavigationListItem-74009187.js.map +1 -0
  58. package/es/CheckboxSet-836e3263.js +49 -0
  59. package/es/CheckboxSet-836e3263.js.map +1 -0
  60. package/es/{TextArea-d97aac1f.js → TextArea-979496a0.js} +25 -8
  61. package/es/TextArea-979496a0.js.map +1 -0
  62. package/es/{TextAreaAutosize-68a4786d.js → TextAreaAutosize-b73aaa2f.js} +2 -2
  63. package/es/{TextAreaAutosize-68a4786d.js.map → TextAreaAutosize-b73aaa2f.js.map} +1 -1
  64. package/es/Theme-redwood/theme.css +414 -414
  65. package/es/Theme-stable/theme.css +485 -485
  66. package/es/UNSAFE_CheckboxItem.js +80 -30
  67. package/es/UNSAFE_CheckboxItem.js.map +1 -1
  68. package/es/UNSAFE_CheckboxSet.js +10 -44
  69. package/es/UNSAFE_CheckboxSet.js.map +1 -1
  70. package/es/UNSAFE_TextArea.js +2 -3
  71. package/es/UNSAFE_TextArea.js.map +1 -1
  72. package/es/UNSAFE_TextAreaAutosize.js +2 -2
  73. package/package.json +2 -2
  74. package/amd/CheckboxSetContext-2e486ea8.js +0 -2
  75. package/amd/CheckboxSetContext-2e486ea8.js.map +0 -1
  76. package/amd/MaxLengthCounter-caafceef.js +0 -2
  77. package/amd/MaxLengthCounter-caafceef.js.map +0 -1
  78. package/amd/TextArea-44c90bc4.js +0 -2
  79. package/amd/TextArea-44c90bc4.js.map +0 -1
  80. package/amd/TextAreaAutosize-0a023972.js +0 -2
  81. package/cjs/BaseNavigationListItem-070d75bc.js.map +0 -1
  82. package/cjs/CheckboxSet-13a5c10c.js +0 -53
  83. package/cjs/NavigationListItem-12a76e7d.js.map +0 -1
  84. package/es/CheckboxSetContext-1be56556.js +0 -9
  85. package/es/MaxLengthCounter-cead2dac.js +0 -25
  86. package/es/MaxLengthCounter-cead2dac.js.map +0 -1
  87. package/es/TextArea-d97aac1f.js.map +0 -1
@@ -5,31 +5,25 @@ import './FormContext-4d71f9c7.js';
5
5
  import { u as useFormContext } from './useFormContext-875cacd7.js';
6
6
  import './FormFieldContext-68eb5946.js';
7
7
  import { u as useFormFieldContext } from './useFormFieldContext-626574fd.js';
8
+ import { u as useCheckboxSetContext } from './CheckboxSet-836e3263.js';
8
9
  import { C as CheckboxControl } from './CheckboxControl-7174e0b2.js';
9
- import { u as useCheckboxSetContext } from './CheckboxSetContext-1be56556.js';
10
10
  import 'preact';
11
11
  import 'preact/compat';
12
- import './CheckboxRadioContext-fe425383.js';
13
- import './HiddenAccessible-61197e7c.js';
14
- import './HiddenAccessibleStyles.styles.css';
15
- import './useComponentTheme-d2f9e47f.js';
16
- import './logger-c92f309c.js';
17
- import './useFocus-38c95977.js';
18
- import './useToggle-8b7fcefe.js';
19
- import './classNames-4e12b00d.js';
20
- import './TabbableModeContext-7d8ad946.js';
21
- import './useTabbableMode-a3a351d0.js';
12
+ import './useFormFieldContextProps-d07cd618.js';
13
+ import './CheckboxSetStyles.styles.css';
22
14
  import './useId-03dbfdf0.js';
15
+ import './CheckboxRadioField-c7c4643e.js';
16
+ import './useCollectionFocusRing-d0c80397.js';
17
+ import './collectionUtils-d72c7c40.js';
18
+ import './keys-df361af9.js';
19
+ import './clientHints-c76a913b.js';
23
20
  import './useTranslationBundle-cd815e10.js';
24
21
  import './LayerHost-45f545d7.js';
25
22
  import './Common/themes/redwood/theme.js';
26
23
  import './Common/themes/themeContract.css.js';
27
- import './UserAssistanceStyles.styles.css';
28
- import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceBaseTheme.styles.css';
29
- import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceVariants.css.js';
30
- import './vanilla-extract-recipes-createRuntimeFn.esm-2aaf8c98.js';
31
24
  import './Flex-24628925.js';
32
25
  import './useTestId-adde554c.js';
26
+ import './classNames-4e12b00d.js';
33
27
  import './boxalignment-486c5ac9.js';
34
28
  import './size-782ed57a.js';
35
29
  import './utils-6eab3a64.js';
@@ -49,6 +43,14 @@ import './_curry3-0b4222d7.js';
49
43
  import './_curry2-34316bcf.js';
50
44
  import './_isObject-1fab0f5b.js';
51
45
  import './FlexStyles.styles.css';
46
+ import './Label-6674b3f2.js';
47
+ import './useComponentTheme-d2f9e47f.js';
48
+ import './logger-c92f309c.js';
49
+ import './TabbableModeContext-7d8ad946.js';
50
+ import './UserAssistanceStyles.styles.css';
51
+ import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceBaseTheme.styles.css';
52
+ import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceVariants.css.js';
53
+ import './vanilla-extract-recipes-createRuntimeFn.esm-2aaf8c98.js';
52
54
  import './MessageBannerStyles.styles.css';
53
55
  import './UNSAFE_MessageBanner/themes/redwood/MessageBannerBaseTheme.styles.css';
54
56
  import './UNSAFE_MessageBanner/themes/redwood/MessageBannerVariants.css.js';
@@ -77,6 +79,8 @@ import './UNSAFE_Floating/themes/redwood/FloatingVariants.css.js';
77
79
  import './vanilla-extract-dynamic.esm-2955d60a.js';
78
80
  import './UNSAFE_Floating/themes/FloatingContract.css.js';
79
81
  import './useHover-d5088fcd.js';
82
+ import './useToggle-8b7fcefe.js';
83
+ import './useFocus-38c95977.js';
80
84
  import './useTouch-4828df25.js';
81
85
  import './mergeProps-88ea8306.js';
82
86
  import './useAnimation-fe9990dc.js';
@@ -94,7 +98,7 @@ import './IconButton-37310d21.js';
94
98
  import './BaseButton-5b2791b1.js';
95
99
  import './usePress-97fc1cf1.js';
96
100
  import './useActive-7d9737a5.js';
97
- import './clientHints-c76a913b.js';
101
+ import './useTabbableMode-a3a351d0.js';
98
102
  import './UNSAFE_BaseButton/themes/redwood/BaseButtonTheme.js';
99
103
  import './UNSAFE_BaseButton/themes/BaseButtonStyles.css.js';
100
104
  import './BaseButtonStyles.styles.css';
@@ -120,6 +124,7 @@ import './getLocale-1c41e86a.js';
120
124
  import './stringUtils-16f617bc.js';
121
125
  import './TransitionGroup-5fd80dc9.js';
122
126
  import './MessagesContext-76544845.js';
127
+ import './HiddenAccessibleStyles.styles.css';
123
128
  import './ComponentMessageStyles.styles.css';
124
129
  import './UNSAFE_ComponentMessage/themes/redwood/ComponentMessageBaseTheme.styles.css';
125
130
  import './UNSAFE_ComponentMessage/themes/redwood/ComponentMessageVariants.css.js';
@@ -156,19 +161,73 @@ import './UNSAFE_Popup/themes/redwood/PopupVariants.css.js';
156
161
  import './PopupStyles.styles.css';
157
162
  import './UNSAFE_Separator/themes/SeparatorStyles.css.js';
158
163
  import './SeparatorStyles.styles.css';
164
+ import './CompactLabelAssistance-fc9478aa.js';
165
+ import './CompactHelpSource-548938ff.js';
166
+ import './Help-6b4bade1.js';
167
+ import './Icon-90c3a630.js';
168
+ import './UNSAFE_Icon/themes/IconStyle.css.js';
159
169
  import './useFocusWithin-30b1e2d8.js';
170
+ import './UNSAFE_UserAssistance/themes/UserAssistanceStyles.css.js';
171
+ import './UNSAFE_Label/themes/redwood/LabelTheme.js';
172
+ import './UNSAFE_Label/themes/LabelStyles.css.js';
160
173
  import './LabelStyles.styles.css';
174
+ import './UNSAFE_Label/themes/redwood/LabelBaseTheme.css.js';
161
175
  import './UNSAFE_Label/themes/redwood/LabelBaseTheme.styles.css';
162
176
  import './UNSAFE_Label/themes/redwood/LabelVariants.css.js';
163
- import './IconUserAssistance-c226cb4f.js';
164
- import './Help-6b4bade1.js';
165
- import './Icon-90c3a630.js';
166
- import './UNSAFE_Icon/themes/IconStyle.css.js';
177
+ import './UNSAFE_TextField/themes/redwood/TextFieldTheme.js';
178
+ import './UNSAFE_TextField/themes/TextFieldStyles.css.js';
179
+ import './SkeletonStyles.styles.css';
180
+ import './TextFieldLoadingStyles.styles.css';
181
+ import './TextFieldStyles.styles.css';
182
+ import './UNSAFE_TextField/themes/redwood/TextFieldBaseTheme.css.js';
183
+ import './UNSAFE_TextField/themes/redwood/TextFieldBaseTheme.styles.css';
184
+ import './UNSAFE_TextField/themes/redwood/TextFieldVariants.css.js';
185
+ import './TextFieldVariants.styles.css';
167
186
  import './InlineHelp-95ca55a5.js';
168
187
  import './InlineHelpSource-b43def76.js';
169
188
  import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceTheme.js';
170
- import './UNSAFE_UserAssistance/themes/UserAssistanceStyles.css.js';
171
189
  import './UNSAFE_UserAssistance/themes/redwood/UserAssistanceBaseTheme.css.js';
190
+ import './InlineUserAssistance-bb690d93.js';
191
+ import './ComponentMessageContainer-7d9228a3.js';
192
+ import './MessagesManager-0d60fea1.js';
193
+ import './SuccessS-b342103c.js';
194
+ import './ErrorS-e6e7e0e2.js';
195
+ import './InformationS-170eee52.js';
196
+ import './WarningS-67afbb93.js';
197
+ import './PRIVATE_Message/themes/MessageStyles.css.js';
198
+ import './soundUtils-88264cb5.js';
199
+ import './useMessagesContext-9e1dbe91.js';
200
+ import './Transition-f9501682.js';
201
+ import './HiddenAccessible-61197e7c.js';
202
+ import './UNSAFE_ComponentMessage/themes/redwood/ComponentMessageTheme.js';
203
+ import './UNSAFE_ComponentMessage/themes/ComponentMessageStyles.css.js';
204
+ import './UNSAFE_ComponentMessage/themes/redwood/ComponentMessageBaseTheme.css.js';
205
+ import './useInputGroupContext-1d19411e.js';
206
+ import './useMessageSeverity-65295e8f.js';
207
+ import './CheckboxRadioFieldStyles.styles.css';
208
+ import './LabelValueLayout-23b74176.js';
209
+ import './LabelValueLayoutStyles.styles.css';
210
+ import './UNSAFE_RadioItem/themes/redwood/RadioTheme.js';
211
+ import './UNSAFE_RadioItem/themes/RadioStyles.css.js';
212
+ import './RadioStyles.styles.css';
213
+ import './UNSAFE_RadioItem/themes/redwood/RadioBaseTheme.css.js';
214
+ import './UNSAFE_RadioItem/themes/redwood/RadioBaseTheme.styles.css';
215
+ import './UNSAFE_RadioItem/themes/redwood/RadioVariants.css.js';
216
+ import './UNSAFE_TextField/themes/redwood/FormLayoutTheme.js';
217
+ import './UNSAFE_TextField/themes/FormLayoutStyles.css.js';
218
+ import './UNSAFE_TextField/themes/redwood/FormLayoutBaseTheme.css.js';
219
+ import './UNSAFE_TextField/themes/redwood/FormLayoutBaseTheme.styles.css';
220
+ import './UNSAFE_Checkbox/themes/redwood/CheckboxTheme.js';
221
+ import './UNSAFE_Checkbox/themes/CheckboxStyles.css.js';
222
+ import './CheckboxStyles.styles.css';
223
+ import './UNSAFE_Checkbox/themes/redwood/CheckboxBaseTheme.css.js';
224
+ import './UNSAFE_Checkbox/themes/redwood/CheckboxBaseTheme.styles.css';
225
+ import './UNSAFE_Checkbox/themes/redwood/CheckboxVariants.css.js';
226
+ import './CheckboxVariants.styles.css';
227
+ import './CheckboxRadioContext-fe425383.js';
228
+ import './LayoutStyles.css-a679044e.js';
229
+ import './LayoutStyles.styles.css';
230
+ import './IconUserAssistance-c226cb4f.js';
172
231
  import './StyledCheckbox-7dc33a92.js';
173
232
  import './Check-c76fe451.js';
174
233
  import './CheckboxOff-d9693a93.js';
@@ -184,15 +243,6 @@ import './UNSAFE_Checkbox/themes/redwood/CheckboxIconVariants.css.js';
184
243
  import './CheckboxIconVariants.styles.css';
185
244
  import './StyledCheckbox.styles.css';
186
245
  import './useCollectionGestureContext-f18b492f.js';
187
- import './UNSAFE_Checkbox/themes/redwood/CheckboxTheme.js';
188
- import './UNSAFE_Checkbox/themes/CheckboxStyles.css.js';
189
- import './CheckboxStyles.styles.css';
190
- import './UNSAFE_Checkbox/themes/redwood/CheckboxBaseTheme.css.js';
191
- import './UNSAFE_Checkbox/themes/redwood/CheckboxBaseTheme.styles.css';
192
- import './UNSAFE_Checkbox/themes/redwood/CheckboxVariants.css.js';
193
- import './CheckboxVariants.styles.css';
194
- import './LayoutStyles.css-a679044e.js';
195
- import './LayoutStyles.styles.css';
196
246
 
197
247
  /**
198
248
  * CheckboxItem is a child component of CheckboxSet. It contains the checkbox, label, and assistive text.
@@ -1 +1 @@
1
- {"version":3,"file":"UNSAFE_CheckboxItem.js","sources":["../../src/UNSAFE_CheckboxItem/CheckboxItem.tsx"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentProps } from 'preact';\nimport { useCallback } from 'preact/hooks';\n\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { useCheckboxSetContext } from '../UNSAFE_CheckboxSet';\n\nimport { CheckboxControl } from '../PRIVATE_CheckboxControl/CheckboxControl';\nimport { InlineUserAssistance } from '#UNSAFE_UserAssistance';\n\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * Text that describes the checkbox item value.\n */\n children: string;\n /**\n * Text to provide guidance to help the user understand what data to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the `helpSourceLink`.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Value of the checkbox item.\n */\n value: string | number;\n};\n\n/**\n * CheckboxItem is a child component of CheckboxSet. It contains the checkbox, label, and assistive text.\n */\nconst CheckboxItem = ({\n children,\n value,\n assistiveText,\n helpSourceLink,\n helpSourceText\n}: Props) => {\n const { isReadonly: isFormReadonly, isDisabled: isFormDisabled } = useFormContext();\n const { isDisabled: isFieldDisabled, isReadonly: isFieldReadonly } = useFormFieldContext();\n const { name, onCommit, value: groupValue } = useCheckboxSetContext();\n\n const isChecked = groupValue?.has(value);\n const isDisabled = isFieldDisabled ?? isFormDisabled;\n const isReadonly = isFieldReadonly ?? isFormReadonly;\n\n const onChangeHandler = useCallback(\n (e: Event) => {\n // return early on keyup if key isn't spacebar\n const { key } = e as KeyboardEvent;\n if (key !== undefined && key !== ' ') {\n return;\n }\n\n // create a new set from the previous and add or remove the changed value\n const newGroupValue = new Set(groupValue);\n newGroupValue.has(value) ? newGroupValue.delete(value) : newGroupValue.add(value);\n\n onCommit?.({\n previousValue: groupValue,\n value: newGroupValue.size > 0 ? newGroupValue : undefined\n });\n },\n [groupValue, onCommit, value]\n );\n\n return (\n <CheckboxControl\n name={name}\n value={value}\n {...(!isReadonly && !isDisabled\n ? { onChange: onChangeHandler, onKeyUp: onChangeHandler }\n : {})}\n assistiveText={assistiveText}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n isChecked={isChecked}\n isDisabled={isDisabled}\n isReadonly={isReadonly}>\n {children}\n </CheckboxControl>\n );\n};\n\nexport { CheckboxItem };\n"],"names":["_jsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CA;;AAEG;AACH,MAAM,YAAY,GAAG,CAAC,EACpB,QAAQ,EACR,KAAK,EACL,aAAa,EACb,cAAc,EACd,cAAc,EACR,KAAI;AACV,IAAA,MAAM,EAAE,UAAU,EAAE,cAAc,EAAE,UAAU,EAAE,cAAc,EAAE,GAAG,cAAc,EAAE,CAAC;AACpF,IAAA,MAAM,EAAE,UAAU,EAAE,eAAe,EAAE,UAAU,EAAE,eAAe,EAAE,GAAG,mBAAmB,EAAE,CAAC;AAC3F,IAAA,MAAM,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,GAAG,qBAAqB,EAAE,CAAC;IAEtE,MAAM,SAAS,GAAG,UAAU,EAAE,GAAG,CAAC,KAAK,CAAC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"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentProps } from 'preact';\nimport { useCallback } from 'preact/hooks';\n\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { useCheckboxSetContext } from '../UNSAFE_CheckboxSet';\n\nimport { CheckboxControl } from '../PRIVATE_CheckboxControl/CheckboxControl';\nimport { InlineUserAssistance } from '#UNSAFE_UserAssistance';\n\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * Text that describes the checkbox item value.\n */\n children: string;\n /**\n * Text to provide guidance to help the user understand what data to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the `helpSourceLink`.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Value of the checkbox item.\n */\n value: string | number;\n};\n\n/**\n * CheckboxItem is a child component of CheckboxSet. It contains the checkbox, label, and assistive text.\n */\nconst CheckboxItem = ({\n children,\n value,\n assistiveText,\n helpSourceLink,\n helpSourceText\n}: Props) => {\n const { isReadonly: isFormReadonly, isDisabled: isFormDisabled } = useFormContext();\n const { isDisabled: isFieldDisabled, isReadonly: isFieldReadonly } = useFormFieldContext();\n const { name, onCommit, value: groupValue } = useCheckboxSetContext();\n\n const isChecked = groupValue?.has(value);\n const isDisabled = isFieldDisabled ?? isFormDisabled;\n const isReadonly = isFieldReadonly ?? isFormReadonly;\n\n const onChangeHandler = useCallback(\n (e: Event) => {\n // return early on keyup if key isn't spacebar\n const { key } = e as KeyboardEvent;\n if (key !== undefined && key !== ' ') {\n return;\n }\n\n // create a new set from the previous and add or remove the changed value\n const newGroupValue = new Set(groupValue);\n newGroupValue.has(value) ? newGroupValue.delete(value) : newGroupValue.add(value);\n\n onCommit?.({\n previousValue: groupValue,\n value: newGroupValue.size > 0 ? newGroupValue : undefined\n });\n },\n [groupValue, onCommit, value]\n );\n\n return (\n <CheckboxControl\n name={name}\n value={value}\n {...(!isReadonly && !isDisabled\n ? { onChange: onChangeHandler, onKeyUp: onChangeHandler }\n : {})}\n assistiveText={assistiveText}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n isChecked={isChecked}\n isDisabled={isDisabled}\n isReadonly={isReadonly}>\n {children}\n </CheckboxControl>\n );\n};\n\nexport { CheckboxItem };\n"],"names":["_jsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CA;;AAEG;AACH,MAAM,YAAY,GAAG,CAAC,EACpB,QAAQ,EACR,KAAK,EACL,aAAa,EACb,cAAc,EACd,cAAc,EACR,KAAI;AACV,IAAA,MAAM,EAAE,UAAU,EAAE,cAAc,EAAE,UAAU,EAAE,cAAc,EAAE,GAAG,cAAc,EAAE,CAAC;AACpF,IAAA,MAAM,EAAE,UAAU,EAAE,eAAe,EAAE,UAAU,EAAE,eAAe,EAAE,GAAG,mBAAmB,EAAE,CAAC;AAC3F,IAAA,MAAM,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,GAAG,qBAAqB,EAAE,CAAC;IAEtE,MAAM,SAAS,GAAG,UAAU,EAAE,GAAG,CAAC,KAAK,CAAC,CAAC;AACzC,IAAA,MA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
4
- import { useMemo } from 'preact/hooks';
5
- import { forwardRef } from 'preact/compat';
6
- import { C as CheckboxSetContext } from './CheckboxSetContext-1be56556.js';
7
- export { C as CheckboxSetContext, u as useCheckboxSetContext } from './CheckboxSetContext-1be56556.js';
2
+ export { C as CheckboxSet, a as CheckboxSetContext, u as useCheckboxSetContext } from './CheckboxSet-836e3263.js';
3
+ import 'preact/jsx-runtime';
4
+ import 'preact';
5
+ import 'preact/hooks';
6
+ import 'preact/compat';
8
7
  import './FormContext-4d71f9c7.js';
9
- import { u as useFormContext } from './useFormContext-875cacd7.js';
10
- import { F as FormFieldContext } from './FormFieldContext-68eb5946.js';
11
- import { u as useFormFieldContextProps } from './useFormFieldContextProps-d07cd618.js';
8
+ import './useFormContext-875cacd7.js';
9
+ import './FormFieldContext-68eb5946.js';
10
+ import './useFormFieldContextProps-d07cd618.js';
12
11
  import './CheckboxSetStyles.styles.css';
13
- import { u as useId } from './useId-03dbfdf0.js';
14
- import { C as CheckboxRadioField } from './CheckboxRadioField-c7c4643e.js';
12
+ import './useId-03dbfdf0.js';
13
+ import './CheckboxRadioField-c7c4643e.js';
15
14
  import './useCollectionFocusRing-d0c80397.js';
16
15
  import './collectionUtils-d72c7c40.js';
17
16
  import './keys-df361af9.js';
@@ -227,37 +226,4 @@ import './CheckboxVariants.styles.css';
227
226
  import './CheckboxRadioContext-fe425383.js';
228
227
  import './LayoutStyles.css-a679044e.js';
229
228
  import './LayoutStyles.styles.css';
230
-
231
- var styles = {ul:'CheckboxSetStyles_styles_ul__68p6630'};
232
-
233
- /**
234
- * A CheckboxSet set allows the user to select one or more options from a set.
235
- */
236
- const CheckboxSet = forwardRef(({ 'aria-describedby': ariaDescribedBy, assistiveText, columnSpan, direction = 'column', helpSourceLink, helpSourceText, isDisabled: propIsDisabled, isReadonly: propIsReadonly, isRequired = false, label, labelEdge: propLabelEdge, labelStartWidth: propLabelStartWidth, messages, onCommit, userAssistanceDensity: propUserAssistanceDensity, value, children, testId }, ref) => {
237
- const hasValue = value !== undefined ? value.size > 0 : false;
238
- const baseId = useId();
239
- const { isDisabled: isFormDisabled, isReadonly: isFormReadonly, labelEdge: formLabelEdge, labelStartWidth: formLabelStartWidth, userAssistanceDensity: formUserAssistanceDensity } = useFormContext();
240
- // default to FormContext values if component properties are not specified
241
- const isDisabled = propIsDisabled ?? isFormDisabled;
242
- const isReadonly = propIsReadonly ?? isFormReadonly;
243
- const labelEdge = propLabelEdge ?? formLabelEdge;
244
- const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;
245
- const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;
246
- const formFieldContext = useFormFieldContextProps({
247
- hasValue,
248
- isDisabled,
249
- isReadonly
250
- });
251
- const checkboxSetContext = useMemo(() => ({
252
- name: baseId,
253
- value,
254
- onCommit
255
- }), [baseId, onCommit, value]);
256
- // wrap each CheckboxItem in an <li> tag and the entire set with <ul>
257
- const childrenArray = toChildArray(children).filter(Boolean);
258
- const wrappedChildren = childrenArray.map((item) => jsx("li", { children: item }));
259
- return (jsx(FormFieldContext.Provider, { value: formFieldContext, children: jsx(CheckboxRadioField, { "aria-describedby": ariaDescribedBy, assistiveText: assistiveText, baseId: baseId, columnSpan: columnSpan, direction: direction, helpSourceLink: helpSourceLink, helpSourceText: helpSourceText, isDisabled: isDisabled, isReadonly: isReadonly, isRequired: isRequired, label: label, labelEdge: labelEdge, labelStartWidth: labelStartWidth, parentComponentVariant: "checkboxSet", messages: messages, userAssistanceDensity: userAssistanceDensity, hasValue: hasValue, role: "group", testId: testId, ref: ref, children: jsx(CheckboxSetContext.Provider, { value: checkboxSetContext, children: jsx("ul", { className: styles.ul, children: wrappedChildren }) }) }) }));
260
- });
261
-
262
- export { CheckboxSet };
263
229
  //# sourceMappingURL=UNSAFE_CheckboxSet.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"UNSAFE_CheckboxSet.js","sources":["../../src/UNSAFE_CheckboxSet/CheckboxSet.tsx"],"sourcesContent":["import { ComponentChildren, ComponentProps, Ref, toChildArray } from 'preact';\nimport { useMemo } from 'preact/hooks';\nimport { forwardRef } from 'preact/compat';\n\nimport { CheckboxSetContext } from './CheckboxSetContext';\nimport { CheckboxRadioField } from '#PRIVATE_CheckboxRadioField';\nimport { InlineUserAssistance, UserAssistanceDensityType } from '#UNSAFE_UserAssistance';\nimport { useFormContext } from '#hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '#hooks/UNSAFE_useFormFieldContext';\nimport { useFormFieldContextProps } from '#hooks/UNSAFE_useFormFieldContextProps';\nimport { FlexboxProps } from '#utils/UNSAFE_interpolations/flexbox';\nimport { Size } from '#utils/UNSAFE_size';\nimport { ValueUpdateDetail } from '#utils/UNSAFE_valueUpdateDetail';\nimport { FocusableHandle } from '#hooks/UNSAFE_useFocusableTextField';\nimport { styles } from './CheckboxSetStyles.css';\nimport { AriaAttributesSignalExcluded } from '#utils/UNSAFE_attributeUtils';\nimport { useId } from '#hooks/UNSAFE_useId';\nimport { LayoutColumnSpan } from '#utils/UNSAFE_styles/Layout';\nimport { TestIdProps } from '#hooks/UNSAFE_useTestId';\n\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n 'aria-describedby'?: AriaAttributesSignalExcluded['aria-describedby'];\n /**\n * Text to provide guidance to help the user understand what data to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * set of CheckboxItems\n */\n children: ComponentChildren;\n /**\n * Specifies how many columns to span in a FormLayout with direction === 'row'\n */\n columnSpan?: LayoutColumnSpan;\n /**\n * layout direction of the children elements\n */\n direction?: FlexboxProps['direction'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the checkbox set requires a selection to be made.\n */\n isRequired?: boolean;\n /**\n * Specifies if the checkbox set is read-only.\n */\n isReadonly?: boolean;\n /**\n * Specifies if the checkbox set is disabled.\n */\n isDisabled?: boolean;\n /**\n * Label text for the group of checkbox items.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'none' | 'top' | 'start' | 'inside';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>.\n */\n labelStartWidth?: Size;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * Callback invoked each time the user changes selected option.\n */\n onCommit: (detail: ValueUpdateDetail<Set<string | number>>) => void;\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'compact'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * </ul>\n */\n userAssistanceDensity?: UserAssistanceDensityType;\n /**\n * Value of the selected checkbox option.\n */\n value?: Set<string | number>;\n} & TestIdProps;\n/**\n * A CheckboxSet set allows the user to select one or more options from a set.\n */\nexport const CheckboxSet = forwardRef(\n (\n {\n 'aria-describedby': ariaDescribedBy,\n assistiveText,\n columnSpan,\n direction = 'column',\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n messages,\n onCommit,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n children,\n testId\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const hasValue = value !== undefined ? value.size > 0 : false;\n const baseId = useId();\n\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n\n const formFieldContext = useFormFieldContextProps({\n hasValue,\n isDisabled,\n isReadonly\n });\n\n const checkboxSetContext = useMemo(\n () => ({\n name: baseId,\n value,\n onCommit\n }),\n [baseId, onCommit, value]\n );\n\n // wrap each CheckboxItem in an <li> tag and the entire set with <ul>\n const childrenArray = toChildArray(children).filter(Boolean);\n const wrappedChildren = childrenArray.map((item) => <li>{item}</li>);\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <CheckboxRadioField\n aria-describedby={ariaDescribedBy}\n assistiveText={assistiveText}\n baseId={baseId}\n columnSpan={columnSpan}\n direction={direction}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n isDisabled={isDisabled}\n isReadonly={isReadonly}\n isRequired={isRequired}\n label={label}\n labelEdge={labelEdge}\n labelStartWidth={labelStartWidth}\n parentComponentVariant=\"checkboxSet\"\n messages={messages}\n userAssistanceDensity={userAssistanceDensity}\n hasValue={hasValue}\n role=\"group\"\n testId={testId}\n ref={ref}>\n <CheckboxSetContext.Provider value={checkboxSetContext}>\n <ul className={styles.ul}>{wrappedChildren}</ul>\n </CheckboxSetContext.Provider>\n </CheckboxRadioField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["_jsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,5 @@
1
1
  /* @oracle/oraclejet-preact: undefined */
2
- export { T as TextArea } from './TextArea-d97aac1f.js';
3
- export { M as MaxLengthCounter } from './MaxLengthCounter-cead2dac.js';
2
+ export { M as MaxLengthCounter, T as TextArea } from './TextArea-979496a0.js';
4
3
  import 'preact/jsx-runtime';
5
4
  import 'preact/compat';
6
5
  import './FormContext-4d71f9c7.js';
@@ -259,6 +258,6 @@ import './CompactUserAssistance-41c32c6f.js';
259
258
  import './Separator-93c70737.js';
260
259
  import './useLengthFilter-f72f45ac.js';
261
260
  import './lengthFilter-d249a7ab.js';
262
- import './useCurrentValueReducer-bdf796fa.js';
263
261
  import './MaxLengthCounterStyles.styles.css';
262
+ import './useCurrentValueReducer-bdf796fa.js';
264
263
  //# sourceMappingURL=UNSAFE_TextArea.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"UNSAFE_TextArea.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"UNSAFE_TextArea.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  /* @oracle/oraclejet-preact: undefined */
2
- export { T as TextAreaAutosize } from './TextAreaAutosize-68a4786d.js';
2
+ export { T as TextAreaAutosize } from './TextAreaAutosize-b73aaa2f.js';
3
3
  import 'preact/jsx-runtime';
4
4
  import 'preact/compat';
5
5
  import './FormContext-4d71f9c7.js';
@@ -259,6 +259,6 @@ import './Separator-93c70737.js';
259
259
  import './useLengthFilter-f72f45ac.js';
260
260
  import './lengthFilter-d249a7ab.js';
261
261
  import './useCurrentValueReducer-bdf796fa.js';
262
- import './MaxLengthCounter-cead2dac.js';
262
+ import './TextArea-979496a0.js';
263
263
  import './MaxLengthCounterStyles.styles.css';
264
264
  //# sourceMappingURL=UNSAFE_TextAreaAutosize.js.map
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "scripts": {},
6
6
  "devDependencies": {},
7
7
  "dependencies": {
8
- "@oracle/oraclejet-testing": "17.0.4",
8
+ "@oracle/oraclejet-testing": "17.0.6",
9
9
  "csstype": "3.1.1"
10
10
  },
11
11
  "peerDependencies": {
@@ -33,5 +33,5 @@
33
33
  ]
34
34
  }
35
35
  },
36
- "version": "17.0.4"
36
+ "version": "17.0.6"
37
37
  }
@@ -1,2 +0,0 @@
1
- define(['exports', 'preact', 'preact/hooks'], (function(e,t,o){"use strict";const c=t.createContext({});e.CheckboxSetContext=c,e.useCheckboxSetContext=()=>o.useContext(c)}));
2
- //# sourceMappingURL=CheckboxSetContext-2e486ea8.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CheckboxSetContext-2e486ea8.js","sources":["../../src/UNSAFE_CheckboxSet/CheckboxSetContext.ts"],"sourcesContent":["import { createContext } from 'preact';\nimport { useContext } from 'preact/hooks';\n\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\n\ntype CheckboxSetContextValue = {\n name: string;\n value?: Set<string | number>;\n onCommit?: (detail: ValueUpdateDetail<Set<string | number>>) => void;\n};\n\nconst CheckboxSetContext = createContext<CheckboxSetContextValue>({} as CheckboxSetContextValue);\nconst useCheckboxSetContext = () => useContext(CheckboxSetContext);\n\nexport { CheckboxSetContext, useCheckboxSetContext };\n"],"names":["CheckboxSetContext","createContext","useContext"],"mappings":"yEAWA,MAAMA,EAAqBC,EAAaA,cAA0B,mDACpC,IAAMC,EAAAA,WAAWF"}
@@ -1,2 +0,0 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/hooks', './classNames-08d99695', './usePress-a9ed1488', './FormFieldContext-3c44aaaa', './useFormFieldContext-8196183c', 'css!./MaxLengthCounterStyles.styles.css'], (function(s,e,n,t,a,r,l,c){"use strict";var o="MaxLengthCounterStyles_spanStyles__7dy9j72";const u=()=>{};s.MaxLengthCounter=function({maxLength:s,valueLength:r=0,onClick:c}){const{isFocused:d}=l.useFormFieldContext(),i=n.useCallback((s=>s.preventDefault()),[]),x=t.classNames([!d&&"MaxLengthCounterStyles_hide__7dy9j71"]),{pressProps:h}=a.usePress(c??u);return e.jsx("div",{class:"MaxLengthCounterStyles_maxLengthCounterBase__7dy9j70",onMouseDown:i,...h,children:e.jsxs("span",{class:x,children:[e.jsx("span",{class:o,children:r}),e.jsx("span",{class:o,children:"/"}),e.jsx("span",{class:o,children:s})]})})}}));
2
- //# sourceMappingURL=MaxLengthCounter-caafceef.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"MaxLengthCounter-caafceef.js","sources":["../../src/UNSAFE_TextArea/MaxLengthCounter.tsx"],"sourcesContent":["import { useCallback } from 'preact/hooks';\n\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { usePress } from '../hooks/UNSAFE_usePress';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { hide, maxLengthCounterBase, spanStyles } from './MaxLengthCounterStyles.css';\n\ntype Props = {\n maxLength: number;\n valueLength?: number;\n onClick?: () => void; // the calling component should focus on the appropriate element when clicked.\n};\n\nconst noop = () => {};\n\nexport function MaxLengthCounter({ maxLength, valueLength = 0, onClick }: Props) {\n const { isFocused } = useFormFieldContext();\n // We don't want mousedown on this component to do anything, so prevent the default behavior.\n const killEvent = useCallback((event: Event) => event.preventDefault(), []);\n const textClasses = classNames([!isFocused && hide]);\n const { pressProps } = usePress(onClick ?? noop);\n return (\n <div class={maxLengthCounterBase} onMouseDown={killEvent} {...pressProps}>\n <span class={textClasses}>\n <span class={spanStyles}>{valueLength}</span>\n <span class={spanStyles}>/</span>\n <span class={spanStyles}>{maxLength}</span>\n </span>\n </div>\n );\n}\n"],"names":["noop","maxLength","valueLength","onClick","isFocused","useFormFieldContext","killEvent","useCallback","event","preventDefault","textClasses","classNames","pressProps","usePress","_jsx","jsx","class","onMouseDown","_jsxs","jsxs","children","spanStyles"],"mappings":"qSAaA,MAAMA,EAAO,0BAEP,UAA2BC,UAAEA,EAASC,YAAEA,EAAc,EAACC,QAAEA,IAC7D,MAAMC,UAAEA,GAAcC,EAAAA,sBAEhBC,EAAYC,EAAAA,aAAaC,GAAiBA,EAAMC,kBAAkB,IAClEC,EAAcC,EAAAA,WAAW,EAAEP,6CAC3BQ,WAAEA,GAAeC,EAAQA,SAACV,GAAWH,GAC3C,OACEc,EAAKC,IAAA,MAAA,CAAAC,6DAA6BC,YAAaX,KAAeM,WAC5DM,EAAMC,KAAA,OAAA,CAAAH,MAAON,EAAWU,SAAA,CACtBN,cAAME,MAAOK,EAAUD,SAAGlB,IAC1BY,EAAAA,YAAME,MAAOK,EAAoBD,SAAA,MACjCN,cAAME,MAAOK,EAAaD,SAAAnB,QAIlC"}
@@ -1,2 +0,0 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/compat', './FormContext-5130e198', './useFormContext-30acdd33', './FormFieldContext-3c44aaaa', 'preact/hooks', './useFocusableTextField-c2f98a8b', './Label-3f8fc274', './TextFieldInput-dfd9529f', 'css!./ObfuscatedTextFieldInputStyles.styles.css', './ReadonlyTextFieldInput-a5e85e5d', './StyledTextField-8ac3bbb4', './TextField-0fc70892', './MaxLengthLiveRegion-23d7e335', './useTextField-e6877c79', './logger-0f873e29', './TabbableModeContext-a9c97640', './useId-c9578d26', './useTranslationBundle-6ef0dab6', 'css!./UserAssistanceStyles.styles.css', 'module', './UNSAFE_UserAssistance/themes/redwood/UserAssistanceVariants.css', './InlineUserAssistance-f4d1fa1b', './CompactUserAssistance-b2cbdbad', './useTooltipControlled-abf886f2', 'preact', 'css!./IconStyle.styles.css', './Popup-249d77c3', 'css!./LabelStyles.styles.css', 'module', './UNSAFE_Label/themes/redwood/LabelVariants.css', './InputGroupContext-372087af', './LayerHost-eab40731', './HiddenAccessible-037ef42d', 'module', './UNSAFE_Popup/themes/redwood/PopupVariants.css', './useLengthFilter-ed8959a4', './MaxLengthCounter-caafceef', './useCurrentValueReducer-faded381'], (function(e,s,t,a,n,i,l,o,r,d,c,u,x,m,p,b,h,f,F,g,y,L,v,A,C,R,T,S,I,U,j,E,w,P,_,D,V,k,M,B){"use strict";const N=t.forwardRef((({"aria-describedby":e,assistiveText:a,autoComplete:l="off",autoFocus:c=!1,columnSpan:h,helpSourceLink:f,helpSourceText:y,isDisabled:L,isReadonly:v,isRequired:R=!1,isRequiredShown:T,label:S,labelEdge:I,labelStartWidth:U,maxLength:j,maxLengthCounter:E="remaining",maxLengthUnit:w,messages:P,placeholder:D,resize:V,role:N,rows:H,textAlign:q,userAssistanceDensity:z,value:W,variant:$="default",onInput:G,onCommit:O,testId:X},J)=>{const K=g.useTranslationBundle("@oracle/oraclejet-preact"),Q=j?K.formControl_limitReached({CHARACTER_LIMIT:j}):"",{currentCommitValue:Y,dispatch:Z}=B.useCurrentValueReducer({value:W}),ee=t.useCallback((e=>{Z({type:"input",payload:e.value}),G?.(e)}),[G,Z]),se=t.useCallback((e=>{Z({type:"commit",payload:e.value}),O?.(e)}),[O,Z]),{isDisabled:te,isReadonly:ae,labelEdge:ne,labelStartWidth:ie,textAlign:le,userAssistanceDensity:oe}=n.useFormContext(),re=L??te,de=v??ae,ce=I??ne,ue=U??ie,xe=q??le,me=z??oe,pe=t.useRef(F.useId()),be=e?`${e} ${pe.current}`:pe.current,{enabledElementRef:he,readonlyElementRef:fe,focusProps:Fe,isFocused:ge}=o.useFocusableTextField({isDisabled:re,isReadonly:de,ref:J}),{isMaxLengthReached:ye,valueLength:Le,onFilteredInput:ve}=k.useLengthFilter({maxLength:j,maxLengthUnit:w,value:W,onInput:ee,onCommit:se}),Ae=[...P??[],...ye?[{detail:Q,severity:"info"}]:[]],{formFieldContext:Ce,inputProps:Re,labelProps:Te,textFieldProps:Se,userAssistanceProps:Ie}=b.useTextField({ariaDescribedBy:de||re?e:be,contentVariant:"textarea",helpSourceLink:f,helpSourceText:y,isDisabled:re,isFocused:ge,isReadonly:de,isRequiredShown:T,labelEdge:ce,messages:Ae,styleVariant:$,userAssistanceDensity:me,value:W}),Ue=t.useCallback((()=>{const e=he.current,s=e?e.value.length:null;he.current?.setSelectionRange(s,s),he.current?.focus()}),[he]),je="none"!==ce?s.jsx(r.Label,{...Te,children:S}):void 0,Ee={label:"none"!==ce?je:void 0,labelEdge:"none"!==ce?ce:void 0,labelStartWidth:"none"!==ce?ue:void 0},we="none"===ce?S:void 0,Pe="efficient"===me||"reflow"===me?re||de?"efficient"!==me?void 0:s.jsx(A.InlineUserAssistance,{userAssistanceDensity:me,...Ie}):s.jsx(A.InlineUserAssistance,{assistiveText:a,fieldLabel:S,helpSourceLink:f,helpSourceText:y,messages:Ae,isRequiredShown:T,userAssistanceDensity:me,...Ie}):void 0,_e=t.useRef(null),De="compact"===me?s.jsx(C.CompactUserAssistance,{anchorRef:_e,messages:Ae,assistiveText:a,...Ie}):void 0;if(de){const e=s.jsx(u.ReadonlyTextFieldInput,{"aria-describedby":Re["aria-describedby"],"aria-label":we,"aria-labelledby":Te.id,as:"textarea",elementRef:fe,rows:H,autoFocus:c,textAlign:xe,value:W,variant:"textarea",hasEmptyLabel:""===S&&"none"===ce,hasInsideLabel:void 0!==S&&"inside"===ce});return s.jsx(i.FormFieldContext.Provider,{value:Ce,children:s.jsx(x.ReadonlyTextField,{role:"presentation",columnSpan:h,compactUserAssistance:De,inlineUserAssistance:Pe,ref:_e,testId:X,variant:"textarea",mainContent:e,resize:V,...Ee})})}const Ve=void 0!==j,ke=s.jsxs(s.Fragment,{children:[s.jsx(d.TextFieldInput,{as:"textarea","aria-label":we,autoComplete:l,autoFocus:c,currentCommitValue:Y,hasEmptyLabel:""===S&&"none"===ce,hasInsideLabel:void 0!==je&&"inside"===ce,isRequired:R,inputRef:he,onCommit:se,onInput:ve,placeholder:D,role:N,rows:H,textAlign:xe,value:W,...Re}),"remaining"===E&&Ve&&s.jsx(M.MaxLengthCounter,{maxLength:j,valueLength:Le,onClick:Ue}),Ve&&s.jsx(_.HiddenAccessible,{id:pe.current,isHidden:!0,children:K.formControl_maxLength({MAX_LENGTH:`${j}`})}),Ve&&ge&&s.jsx(p.MaxLengthLiveRegion,{maxLength:j,valueLength:Le,testId:X+"_remainingChars"})]});return s.jsx(i.FormFieldContext.Provider,{value:Ce,children:s.jsx(m.TextField,{mainContent:ke,columnSpan:h,compactUserAssistance:De,inlineUserAssistance:Pe,onBlur:Fe?.onFocusOut,onFocus:Fe?.onFocusIn,mainFieldRef:_e,resize:V,testId:X,...Se,...Ee})})}));e.TextArea=N}));
2
- //# sourceMappingURL=TextArea-44c90bc4.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TextArea-44c90bc4.js","sources":["../../src/UNSAFE_TextArea/TextArea.tsx"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\n\nimport { ComponentProps, Ref } from 'preact';\nimport { forwardRef, useCallback, useRef } from 'preact/compat';\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { FocusableHandle, useFocusableTextField } from '../hooks/UNSAFE_useFocusableTextField';\nimport { Label } from '../UNSAFE_Label';\nimport {\n ReadonlyTextField,\n ReadonlyTextFieldInput,\n TextField,\n TextFieldInput\n} from '../UNSAFE_TextField';\nimport { useTextField } from '../hooks/UNSAFE_useTextField';\nimport {\n CompactUserAssistance,\n InlineUserAssistance,\n UserAssistanceDensityType\n} from '../UNSAFE_UserAssistance';\nimport { CountUnit, useLengthFilter } from '../hooks/UNSAFE_useLengthFilter';\nimport { MaxLengthLiveRegion } from '../UNSAFE_TextField';\nimport { MaxLengthCounter } from './MaxLengthCounter';\nimport { Size } from '../utils/UNSAFE_size';\nimport { useCurrentValueReducer } from '../hooks/UNSAFE_useCurrentValueReducer';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\nimport { ComponentMessageItem } from '../UNSAFE_ComponentMessage';\nimport { useTranslationBundle } from '../hooks/UNSAFE_useTranslationBundle';\nimport { BundleType } from '../resources/nls/bundle';\nimport { LayoutColumnSpan } from '../utils/UNSAFE_styles/Layout';\nimport type { TestIdProps } from '#hooks/UNSAFE_useTestId';\nimport { HiddenAccessible } from '../UNSAFE_HiddenAccessible';\nimport { useId } from '../hooks/UNSAFE_useId';\n\ntype TextFieldProps = ComponentProps<typeof TextField>;\ntype TextFieldInputProps = ComponentProps<typeof TextFieldInput>;\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = TestIdProps & {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n 'aria-describedby'?: TextFieldInputProps['aria-describedby'];\n\n /**\n * Text to provide guidance to help the user understand what to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Dictates component's autocomplete state.\n * This attribute indicates whether the value of the control can be automatically completed by the browser.\n * The common values are \"on\" and \"off\".\n */\n autoComplete?: TextFieldInputProps['autoComplete'];\n /**\n * Autofocus specifies whether the component will get focus when the page is loaded.\n * If it is set to true then the associated component will get input focus when the page is loaded.\n * Setting this property doesn't set the focus to the component; it tells the browser to focus\n * to it when the element is inserted in the document.\n */\n autoFocus?: TextFieldInputProps['autoFocus'];\n /**\n * Specifies how many columns to span in a FormLayout with direction === 'row'\n */\n columnSpan?: LayoutColumnSpan;\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the component is disabled.\n */\n isDisabled?: boolean;\n /**\n * Specifies whether the component is readonly.\n */\n isReadonly?: boolean;\n /**\n * Specifies for accessibility purposes whether a value is required.\n *\n * Setting this property to <code>false</code> means that a value is not required to be\n * committed by the user. Setting this property to <code>true</code> means that a value\n * is required to be committed by the user.\n */\n isRequired?: TextFieldInputProps['isRequired'];\n /**\n * Specifies whether to show an indicator on screen that a value is required, for example\n * before the user has committed a value.\n */\n isRequiredShown?: InlineUserAssistanceProps['isRequiredShown'];\n /**\n * Specifies the label associated with the field.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'inside' | 'start' | 'top' | 'none';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>\n */\n labelStartWidth?: Size;\n /**\n * Specifies the maximum number of characters that can be entered in the input field.\n */\n maxLength?: number;\n /**\n * Determines whether the remaining number of characters that can be entered is shown or not.\n */\n maxLengthCounter?: 'none' | 'remaining';\n /**\n * Specifies how the input text characters are to be counted when maxLength is specified.\n */\n maxLengthUnit?: CountUnit;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * A short hint to display before the user enters a value.\n */\n placeholder?: TextFieldInputProps['placeholder'];\n /**\n * Specifies how the user is allowed to manually resize the TextArea component.\n */\n resize?: TextFieldProps['resize'];\n /**\n * Specifies the ARIA role type.\n */\n role?: TextFieldInputProps['role'];\n /**\n * Specifies the number of rows to display\n */\n rows?: TextFieldInputProps['rows'];\n /**\n * Specifies how to align text within the field.\n */\n textAlign?: TextFieldInputProps['textAlign'];\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * <li><code>'compact'</code>: Messages, help, hints, and required will not be shown inline; they will show in a mode that keeps the screen more compact, like a popup for the messages, and a required icon to indicate Required. </li>\n * </ul>\n */\n userAssistanceDensity?: UserAssistanceDensityType;\n /**\n * The current display value of the component.\n */\n value?: TextFieldInputProps['value'];\n /**\n * The style variant of the component.\n */\n variant?: TextFieldInputProps['variant'];\n /**\n * Callback invoked when the user commits the entered value by blurring out of the field.\n */\n onCommit?: TextFieldInputProps['onCommit'];\n /**\n * Callback invoked each time the user changes the value of the field. For example, if the user\n * types 'abcd', this callback will be called four times with the value as 'a', 'ab', 'abc' and 'abcd'\n * respectively.\n */\n onInput: TextFieldInputProps['onInput'];\n};\n/**\n * A text area displays a field that allows a user to enter a multi-line text value.\n */\nexport const TextArea = forwardRef(\n (\n {\n 'aria-describedby': ariaDescribedBy,\n assistiveText,\n autoComplete = 'off',\n autoFocus = false,\n columnSpan,\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n isRequiredShown,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n maxLength,\n maxLengthCounter = 'remaining',\n maxLengthUnit,\n messages,\n placeholder,\n resize,\n role,\n rows,\n textAlign: propTextAlign,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n variant = 'default',\n onInput,\n onCommit,\n testId\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const translations = useTranslationBundle<BundleType>('@oracle/oraclejet-preact');\n const formControl_limitReached = maxLength\n ? translations.formControl_limitReached({\n CHARACTER_LIMIT: maxLength\n })\n : '';\n\n const { currentCommitValue, dispatch } = useCurrentValueReducer({ value });\n const onInputAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'input', payload: detail.value });\n onInput?.(detail);\n },\n [onInput, dispatch]\n );\n const onCommitAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'commit', payload: detail.value });\n onCommit?.(detail);\n },\n [onCommit, dispatch]\n );\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n textAlign: formTextAlign,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const textAlign = propTextAlign ?? formTextAlign;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n const maxLengthDescribedByIdRef = useRef<string>(useId());\n // The enabledAriaDescribedBy includes the maxLengthDescribedById in addition to what was passed in to aria-describedby.\n // We don't need to announce the max length message for readonly, as it only applies when editing the value.\n const enabledAriaDescribedBy = ariaDescribedBy\n ? `${ariaDescribedBy} ${maxLengthDescribedByIdRef.current}`\n : maxLengthDescribedByIdRef.current;\n\n const { enabledElementRef, readonlyElementRef, focusProps, isFocused } = useFocusableTextField<\n HTMLTextAreaElement,\n HTMLTextAreaElement\n >({ isDisabled, isReadonly, ref });\n\n // Handle length filter for user-typed inputs and controlled inputs\n const { isMaxLengthReached, valueLength, onFilteredInput } = useLengthFilter({\n maxLength,\n maxLengthUnit,\n value,\n onInput: onInputAndDispatch,\n onCommit: onCommitAndDispatch\n });\n\n const limitMessage = [{ detail: formControl_limitReached, severity: 'info' }];\n const allMessages = [\n ...(messages ?? []),\n ...(isMaxLengthReached ? limitMessage : [])\n ] as ComponentMessageItem[];\n\n const { formFieldContext, inputProps, labelProps, textFieldProps, userAssistanceProps } =\n useTextField({\n ariaDescribedBy: isReadonly || isDisabled ? ariaDescribedBy : enabledAriaDescribedBy,\n contentVariant: 'textarea',\n helpSourceLink,\n helpSourceText,\n isDisabled,\n isFocused,\n isReadonly,\n isRequiredShown,\n labelEdge,\n messages: allMessages,\n styleVariant: variant,\n userAssistanceDensity,\n value\n });\n\n const onClickCounter = useCallback(() => {\n const elm = enabledElementRef.current;\n // for setSelectionRange(), len needs to be a number or null.\n const len = elm ? elm.value.length : null;\n // Since the counter element is after the text, clicking in this\n // should put the selection at the end of the text\n enabledElementRef.current?.setSelectionRange(len, len);\n // Clicking the counter should put the focus on the input field\n enabledElementRef.current?.focus();\n }, [enabledElementRef]);\n\n const labelComp = labelEdge !== 'none' ? <Label {...labelProps}>{label}</Label> : undefined;\n\n const fieldLabelProps = {\n label: labelEdge !== 'none' ? labelComp : undefined,\n labelEdge: labelEdge !== 'none' ? labelEdge : undefined,\n labelStartWidth: labelEdge !== 'none' ? labelStartWidth : undefined\n };\n\n const ariaLabel = labelEdge === 'none' ? label : undefined;\n const isInlineDensity =\n userAssistanceDensity === 'efficient' || userAssistanceDensity === 'reflow';\n\n const inlineUserAssistance = isInlineDensity ? (\n isDisabled || isReadonly ? (\n // save space for user assistance if density is 'efficient', even though we don't\n // render user assistance for disabled or readonly fields\n userAssistanceDensity !== 'efficient' ? undefined : (\n <InlineUserAssistance\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : (\n <InlineUserAssistance\n assistiveText={assistiveText}\n fieldLabel={label}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n messages={allMessages}\n isRequiredShown={isRequiredShown}\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : undefined;\n\n const anchorRef = useRef<HTMLDivElement>(null);\n\n const compactUserAssistance =\n userAssistanceDensity === 'compact' ? (\n <CompactUserAssistance\n anchorRef={anchorRef}\n messages={allMessages}\n assistiveText={assistiveText}\n {...userAssistanceProps}\n />\n ) : undefined;\n\n if (isReadonly) {\n const mainContent = (\n <ReadonlyTextFieldInput\n aria-describedby={inputProps['aria-describedby']}\n aria-label={ariaLabel}\n aria-labelledby={labelProps.id}\n as=\"textarea\"\n elementRef={readonlyElementRef}\n rows={rows}\n autoFocus={autoFocus}\n textAlign={textAlign}\n value={value}\n variant=\"textarea\"\n hasEmptyLabel={label === '' && labelEdge === 'none'}\n hasInsideLabel={label !== undefined && labelEdge === 'inside'}\n />\n );\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <ReadonlyTextField\n role=\"presentation\"\n columnSpan={columnSpan}\n compactUserAssistance={compactUserAssistance}\n inlineUserAssistance={inlineUserAssistance}\n ref={anchorRef}\n testId={testId}\n variant=\"textarea\"\n mainContent={mainContent}\n resize={resize}\n {...fieldLabelProps}\n />\n </FormFieldContext.Provider>\n );\n }\n const hasMaxLength = maxLength !== undefined;\n const mainContent = (\n <>\n <TextFieldInput\n as=\"textarea\"\n aria-label={ariaLabel}\n autoComplete={autoComplete}\n autoFocus={autoFocus}\n currentCommitValue={currentCommitValue}\n hasEmptyLabel={label === '' && labelEdge === 'none'}\n hasInsideLabel={labelComp !== undefined && labelEdge === 'inside'}\n isRequired={isRequired}\n inputRef={enabledElementRef}\n onCommit={onCommitAndDispatch}\n onInput={onFilteredInput}\n placeholder={placeholder}\n role={role}\n rows={rows}\n textAlign={textAlign}\n value={value}\n {...inputProps}\n />\n {maxLengthCounter === 'remaining' && hasMaxLength && (\n <MaxLengthCounter\n maxLength={maxLength}\n valueLength={valueLength}\n onClick={onClickCounter}\n />\n )}\n {hasMaxLength && (\n <HiddenAccessible id={maxLengthDescribedByIdRef.current} isHidden={true}>\n {translations.formControl_maxLength({\n MAX_LENGTH: `${maxLength}`\n })}\n </HiddenAccessible>\n )}\n {hasMaxLength && isFocused && (\n <MaxLengthLiveRegion\n maxLength={maxLength}\n valueLength={valueLength}\n testId={testId + '_remainingChars'}\n />\n )}\n </>\n );\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <TextField\n mainContent={mainContent}\n columnSpan={columnSpan}\n compactUserAssistance={compactUserAssistance}\n inlineUserAssistance={inlineUserAssistance}\n onBlur={focusProps?.onFocusOut}\n onFocus={focusProps?.onFocusIn}\n mainFieldRef={anchorRef}\n resize={resize}\n testId={testId}\n {...textFieldProps}\n {...fieldLabelProps}></TextField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["TextArea","forwardRef","ariaDescribedBy","assistiveText","autoComplete","autoFocus","columnSpan","helpSourceLink","helpSourceText","isDisabled","propIsDisabled","isReadonly","propIsReadonly","isRequired","isRequiredShown","label","labelEdge","propLabelEdge","labelStartWidth","propLabelStartWidth","maxLength","maxLengthCounter","maxLengthUnit","messages","placeholder","resize","role","rows","textAlign","propTextAlign","userAssistanceDensity","propUserAssistanceDensity","value","variant","onInput","onCommit","testId","ref","translations","useTranslationBundle","formControl_limitReached","CHARACTER_LIMIT","currentCommitValue","dispatch","useCurrentValueReducer","onInputAndDispatch","useCallback","detail","type","payload","onCommitAndDispatch","isFormDisabled","isFormReadonly","formLabelEdge","formLabelStartWidth","formTextAlign","formUserAssistanceDensity","useFormContext","maxLengthDescribedByIdRef","useRef","useId","enabledAriaDescribedBy","current","enabledElementRef","readonlyElementRef","focusProps","isFocused","useFocusableTextField","isMaxLengthReached","valueLength","onFilteredInput","useLengthFilter","allMessages","severity","formFieldContext","inputProps","labelProps","textFieldProps","userAssistanceProps","useTextField","contentVariant","styleVariant","onClickCounter","elm","len","length","setSelectionRange","focus","labelComp","_jsx","jsx","Label","undefined","fieldLabelProps","ariaLabel","inlineUserAssistance","InlineUserAssistance","fieldLabel","anchorRef","compactUserAssistance","CompactUserAssistance","mainContent","ReadonlyTextFieldInput","id","as","elementRef","hasEmptyLabel","hasInsideLabel","FormFieldContext","Provider","children","ReadonlyTextField","hasMaxLength","_jsxs","_Fragment","Fragment","TextFieldInput","inputRef","MaxLengthCounter","onClick","HiddenAccessible","isHidden","formControl_maxLength","MAX_LENGTH","MaxLengthLiveRegion","TextField","onBlur","onFocusOut","onFocus","onFocusIn","mainFieldRef"],"mappings":"23CAqLaA,EAAWC,EAAAA,YACtB,EAEI,mBAAoBC,EACpBC,gBACAC,eAAe,MACfC,aAAY,EACZC,aACAC,iBACAC,iBACAC,WAAYC,EACZC,WAAYC,EACZC,cAAa,EACbC,kBACAC,QACAC,UAAWC,EACXC,gBAAiBC,EACjBC,YACAC,mBAAmB,YACnBC,gBACAC,WACAC,cACAC,SACAC,OACAC,OACAC,UAAWC,EACXC,sBAAuBC,EACvBC,QACAC,UAAU,UACVC,UACAC,WACAC,UAEFC,KAEA,MAAMC,EAAeC,uBAAiC,4BAChDC,EAA2BpB,EAC7BkB,EAAaE,yBAAyB,CACpCC,gBAAiBrB,IAEnB,IAEEsB,mBAAEA,EAAkBC,SAAEA,GAAaC,EAAAA,uBAAuB,CAAEZ,UAC5Da,GAAqBC,eACxBC,IAECJ,EAAS,CAAEK,KAAM,QAASC,QAASF,EAAOf,QAC1CE,IAAUa,EAAO,GAEnB,CAACb,EAASS,IAENO,GAAsBJ,eACzBC,IAECJ,EAAS,CAAEK,KAAM,SAAUC,QAASF,EAAOf,QAC3CG,IAAWY,EAAO,GAEpB,CAACZ,EAAUQ,KAGXlC,WAAY0C,GACZxC,WAAY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IAAA0B,iBACC,CAAAZ,GAAG,WACS,aAAAV,GACZ1F,aAAcA,EACdC,UAAWA,EACXqC,mBAAoBA,EACpBgE,cAAyB,KAAV3F,GAA8B,SAAdC,GAC/B2F,oBAA8Bf,IAAdJ,IAAyC,WAAdxE,GAC3CH,WAAYA,EACZwG,SAAUtD,GACV5B,SAAUe,GACVhB,QAASoC,GACT9C,YAAaA,EACbE,KAAMA,EACNC,KAAMA,EACNC,UAAWA,GACXI,MAAOA,KACH2C,KAEgB,cAArBtD,GAAoC2F,IACnCvB,EAAAA,IAAC6B,EAAAA,kBACClG,UAAWA,EACXiD,YAAaA,GACbkD,QAASrC,KAGZ8B,IACCvB,MAAC+B,EAAAA,iBAAgB,CAACjB,GAAI7C,GAA0BI,QAAS2D,UAAU,EAAIX,SACpExE,EAAaoF,sBAAsB,CAClCC,WAAY,GAAGvG,QAIpB4F,IAAgB9C,IACfuB,MAACmC,EAAAA,oBACC,CAAAxG,UAAWA,EACXiD,YAAaA,GACbjC,OAAQA,EAAS,uBAMzB,OACEqD,EAAAA,IAACmB,EAAAA,iBAAiBC,SAAS,CAAA7E,MAAO0C,GAChCoC,SAAArB,EAAAC,IAACmC,EAASA,UAAA,CACRxB,YAAaA,GACb/F,WAAYA,EACZ6F,sBAAuBA,GACvBJ,qBAAsBA,GACtB+B,OAAQ7D,IAAY8D,WACpBC,QAAS/D,IAAYgE,UACrBC,aAAchC,GACdzE,OAAQA,EACRW,OAAQA,KACJyC,MACAgB,MAER"}
@@ -1,2 +0,0 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/compat', './FormContext-5130e198', './useFormContext-30acdd33', './FormFieldContext-3c44aaaa', 'preact/hooks', './useFocusableTextField-c2f98a8b', './Label-3f8fc274', './TextFieldInput-dfd9529f', 'css!./ObfuscatedTextFieldInputStyles.styles.css', './ReadonlyTextFieldInput-a5e85e5d', './StyledTextField-8ac3bbb4', './TextField-0fc70892', './MaxLengthLiveRegion-23d7e335', './useTextField-e6877c79', './logger-0f873e29', './TabbableModeContext-a9c97640', './useId-c9578d26', './useTranslationBundle-6ef0dab6', 'css!./UserAssistanceStyles.styles.css', 'module', './UNSAFE_UserAssistance/themes/redwood/UserAssistanceVariants.css', './InlineUserAssistance-f4d1fa1b', './CompactUserAssistance-b2cbdbad', './useTooltipControlled-abf886f2', 'preact', 'css!./IconStyle.styles.css', './Popup-249d77c3', 'css!./LabelStyles.styles.css', 'module', './UNSAFE_Label/themes/redwood/LabelVariants.css', './InputGroupContext-372087af', './LayerHost-eab40731', './HiddenAccessible-037ef42d', 'module', './UNSAFE_Popup/themes/redwood/PopupVariants.css', './useLengthFilter-ed8959a4', './useCurrentValueReducer-faded381', './MaxLengthCounter-caafceef'], (function(e,t,s,a,n,i,o,l,r,d,c,u,m,p,x,h,b,f,g,F,y,R,v,L,A,C,T,S,I,w,E,U,j,H,P,D,_,B,M,V){"use strict";const k=({isReadonly:e,enabledElementRef:t,readonlyElementRef:s,minRows:a=2,maxRows:n,value:i})=>{o.useLayoutEffect((()=>{const i=e?s:t;if(null===i.current)return;if(i.current instanceof HTMLDivElement)return;const o=i.current,l=(e=>{const t=window.getComputedStyle(e),s=t.lineHeight;if("normal"===s)return 1.2*parseFloat(t.fontSize);return parseFloat(s)})(o);o.style.height="0";const{paddingHeight:r,borderHeight:d}=(e=>{const t=window.getComputedStyle(e);return{paddingHeight:parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),borderHeight:parseFloat(t.borderTop)+parseFloat(t.borderBottom)}})(o),c=l*a+r+d,u=o.scrollHeight+d;let m=0;if(void 0===n)m=u<c?c:u;else if(n>a){const e=l*n+r+d;m=u>e?e:u<c?c:u}else m=c;o.style.height=m+.5+"px"}),[i,a,n,e,t,s])},N=s.forwardRef((({"aria-describedby":e,assistiveText:a,autoComplete:o="off",autoFocus:c=!1,columnSpan:b,helpSourceLink:f,helpSourceText:y,isDisabled:R,isReadonly:v,isRequired:C=!1,isRequiredShown:T,label:S,labelEdge:I,labelStartWidth:w,maxLength:E,maxLengthCounter:U="remaining",maxLengthUnit:j,maxRows:H,messages:D,minRows:_=2,placeholder:N,role:q,textAlign:W,userAssistanceDensity:$,value:z,variant:G="default",onInput:O,onCommit:X,testId:J},K)=>{const Q=F.useTranslationBundle("@oracle/oraclejet-preact"),Y=E?Q.formControl_limitReached({CHARACTER_LIMIT:E}):"",{currentCommitValue:Z,dispatch:ee}=M.useCurrentValueReducer({value:z}),te=s.useCallback((e=>{ee({type:"input",payload:e.value}),O?.(e)}),[O,ee]),se=s.useCallback((e=>{ee({type:"commit",payload:e.value}),X?.(e)}),[X,ee]),{isDisabled:ae,isReadonly:ne,labelEdge:ie,labelStartWidth:oe,textAlign:le,userAssistanceDensity:re}=n.useFormContext(),de=R??ae,ce=v??ne,ue=I??ie,me=w??oe,pe=W??le,xe=$??re,he=s.useRef(g.useId()),be=e?`${e} ${he.current}`:he.current,{enabledElementRef:fe,readonlyElementRef:ge,focusProps:Fe,isFocused:ye}=l.useFocusableTextField({isDisabled:de,isReadonly:ce,ref:K}),{isMaxLengthReached:Re,valueLength:ve,onFilteredInput:Le}=B.useLengthFilter({maxLength:E,maxLengthUnit:j,value:z,onInput:te,onCommit:se}),Ae=[...D??[],...Re?[{detail:Y,severity:"info"}]:[]],{formFieldContext:Ce,inputProps:Te,labelProps:Se,textFieldProps:Ie,userAssistanceProps:we}=h.useTextField({ariaDescribedBy:ce||de?e:be,contentVariant:"textarea",helpSourceLink:f,helpSourceText:y,isDisabled:de,isFocused:ye,isReadonly:ce,isRequiredShown:T,labelEdge:ue,messages:Ae,styleVariant:G,userAssistanceDensity:xe,value:z}),Ee=s.useCallback((()=>{const e=fe.current,t=e?e.value.length:null;fe.current?.setSelectionRange(t,t),fe.current?.focus()}),[fe]),Ue="none"!==ue?t.jsx(r.Label,{...Se,children:S}):void 0,je={label:"none"!==ue?Ue:void 0,labelEdge:"none"!==ue?ue:void 0,labelStartWidth:"none"!==ue?me:void 0},He="none"===ue?S:void 0,Pe="efficient"===xe||"reflow"===xe?de||ce?"efficient"!==xe?void 0:t.jsx(L.InlineUserAssistance,{userAssistanceDensity:xe,...we}):t.jsx(L.InlineUserAssistance,{assistiveText:a,fieldLabel:S,helpSourceLink:f,helpSourceText:y,messages:Ae,isRequiredShown:T,userAssistanceDensity:xe,...we}):void 0,De=s.useRef(null),_e="compact"===xe?t.jsx(A.CompactUserAssistance,{anchorRef:De,messages:Ae,assistiveText:a,...we}):void 0;if(k({isReadonly:ce,enabledElementRef:fe,readonlyElementRef:ge,minRows:_,maxRows:H,value:z}),ce){const e=t.jsx(u.ReadonlyTextFieldInput,{"aria-describedby":Te["aria-describedby"],"aria-label":He,"aria-labelledby":Se.id,elementRef:ge,...H?{as:"textarea",rows:_}:{as:"div"},autoFocus:c,textAlign:pe,value:z,variant:"textarea",hasEmptyLabel:""===S&&"none"===ue,hasInsideLabel:void 0!==S&&"inside"===ue});return t.jsx(i.FormFieldContext.Provider,{value:Ce,children:t.jsx(m.ReadonlyTextField,{role:"presentation",colSpan:b,compactUserAssistance:_e,inlineUserAssistance:Pe,variant:"textarea",mainContent:e,ref:De,testId:J,...je})})}const Be=void 0!==E,Me=t.jsxs(t.Fragment,{children:[t.jsx(d.TextFieldInput,{as:"textarea","aria-label":He,autoComplete:o,autoFocus:c,currentCommitValue:Z,hasEmptyLabel:""===S&&"none"===ue,hasInsideLabel:void 0!==Ue&&"inside"===ue,isRequired:C,inputRef:fe,onCommit:se,onInput:Le,placeholder:N,role:q,rows:_,textAlign:pe,value:z,...Te}),"remaining"===U&&Be&&t.jsx(V.MaxLengthCounter,{maxLength:E,valueLength:ve,onClick:Ee}),Be&&t.jsx(P.HiddenAccessible,{id:he.current,children:Q.formControl_maxLength({MAX_LENGTH:`${E}`})}),Be&&ye&&t.jsx(x.MaxLengthLiveRegion,{maxLength:E,valueLength:ve,testId:J+"_remainingChars"})]});return t.jsx(i.FormFieldContext.Provider,{value:Ce,children:t.jsx(p.TextField,{mainContent:Me,columnSpan:b,compactUserAssistance:_e,inlineUserAssistance:Pe,onBlur:Fe?.onFocusOut,onFocus:Fe?.onFocusIn,mainFieldRef:De,testId:J,...Ie,...je})})}));e.TextAreaAutosize=N}));
2
- //# sourceMappingURL=TextAreaAutosize-0a023972.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BaseNavigationListItem-070d75bc.js","sources":["../../src/UNSAFE_NavigationListCommon/NavigationListContext.ts","../../src/UNSAFE_NavigationListCommon/useNavigationListContext.ts","../../src/UNSAFE_NavigationListCommon/useNavigationListItem.ts","../../src/UNSAFE_NavigationListCommon/BaseNavigationListItem.tsx"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\n\nimport { createContext } from 'preact';\nimport { NavigationListProps } from './NavigationListProps';\n\ntype CurrentKeyDetail<K> = {\n value: K;\n};\n\nexport type NavigationListContextProps<K extends string | number> = Pick<\n NavigationListProps<K>,\n 'selection' | 'onSelectionChange' | 'onRemove'\n> & {\n currentKey?: K;\n showFocusRing: boolean;\n onCurrentKeyChange:\n | (<K extends string | number>(detail: CurrentKeyDetail<K>) => void)\n | undefined;\n navigationListItemPrefix: string;\n};\n\n/**\n * Context used to pass navlist information without having to pass it to navlist children props.\n * We want to communicate information down to any interested navlist item children.\n */\n\nconst NavigationListContext = createContext<NavigationListContextProps<string | number>>(null!);\n\nexport { NavigationListContext };\n","/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\n\nimport { useContext } from 'preact/hooks';\nimport { NavigationListContext } from './NavigationListContext';\n\n/**\n * Utility hook for consuming the NavigationListContext\n *\n * @returns The value of NavigationListContext provider\n */\nfunction useNavigationListContext() {\n return useContext(NavigationListContext);\n}\n\nexport { useNavigationListContext };\n","import { useCallback } from 'preact/hooks';\n\nimport { usePress } from '../hooks/UNSAFE_usePress';\nimport { mergeProps } from '../utils/UNSAFE_mergeProps';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { useInteractionStyle } from '../hooks/UNSAFE_useInteractionStyle';\nimport { useComponentTheme } from '../hooks/UNSAFE_useComponentTheme';\nimport { useNavigationListContext } from './useNavigationListContext';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\nimport { FlexitemProps } from '../utils/UNSAFE_interpolations/flexitem';\nimport { flexitemInterpolations } from '../utils/UNSAFE_interpolations/flexitem';\nimport {\n NavigationListItemStyles,\n NavigationListItemVariantOptions\n} from '../UNSAFE_NavigationList/themes/NavigationListItemStyles.css';\nimport { NavigationListItemRedwoodTheme } from './themes/redwood/NavigationListItemTheme';\n\nconst flexItemStyleInterpolations = mergeInterpolations<FlexitemProps>([\n ...Object.values(flexitemInterpolations)\n]);\nconst { class: labelContainerFlexItemClasses, ...labelContainerFlexItemStyle } =\n flexItemStyleInterpolations({\n alignSelf: 'center'\n });\n\nexport function useNavigationListItem<K extends string | number>({ itemKey }: { itemKey: K }) {\n const { onSelectionChange, selection, currentKey, showFocusRing, navigationListItemPrefix } =\n useNavigationListContext();\n\n //Selection and focus state\n const isCurrent = currentKey === itemKey;\n\n const isSelected = selection === itemKey;\n\n //Styling\n const { interactionProps, applyPseudoHoverStyle, applyHoverStyle, applyActiveStyle } =\n useInteractionStyle();\n\n const {\n classes: listItemClasses,\n styles: { labelContainerClasses }\n } = useComponentTheme<NavigationListItemVariantOptions, NavigationListItemStyles>(\n NavigationListItemRedwoodTheme,\n {\n focusRing: showFocusRing ? 'isFocusRing' : 'notFocusRing',\n current: isCurrent ? 'isCurrent' : 'notCurrtent',\n selected: isSelected ? 'isSelected' : 'notSelected',\n hybridHover: applyHoverStyle ? 'isHybridHover' : 'notHybridHover',\n pseudoHover: applyPseudoHoverStyle ? 'isPseudoHover' : 'notPseudoHover',\n active: applyActiveStyle ? 'isActive' : 'notActive'\n }\n );\n\n //Item handlers\n const handlePress = useCallback(() => {\n onSelectionChange?.({ value: itemKey as K, reason: 'pointer' });\n }, [itemKey, onSelectionChange]);\n\n //Legacy navlist makes selection on keyDown, but since preact tabbar made selection after keyUp, will do the same\n //for preact navlist\n const { pressProps } = usePress(handlePress);\n\n return {\n itemId: navigationListItemPrefix + itemKey,\n itemHandlers: mergeProps(interactionProps, pressProps /*,onFocusProps*/),\n itemClasses: classNames([listItemClasses]),\n isSelected,\n labelContainerClasses: classNames([labelContainerClasses, labelContainerFlexItemClasses]),\n labelContainerStyle: labelContainerFlexItemStyle\n };\n}\n","import { useRef } from 'preact/hooks';\n\nimport { Text } from '../UNSAFE_Text';\n\nimport { useNavigationListItem } from './useNavigationListItem';\nimport { Flex } from '../UNSAFE_Flex';\nimport { Badge } from '../UNSAFE_Badge';\nimport { useComponentTheme } from '../hooks/UNSAFE_useComponentTheme';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { WarningS } from '../UNSAFE_RedwoodIcons/WarningS';\nimport { ErrorS } from '../UNSAFE_RedwoodIcons/ErrorS';\nimport { InformationS } from '../UNSAFE_RedwoodIcons/InformationS';\nimport { SuccessS } from '../UNSAFE_RedwoodIcons/SuccessS';\nimport {\n NavigationListItemStyles,\n NavigationListItemVariantOptions\n} from '../UNSAFE_NavigationList/themes/NavigationListItemStyles.css';\nimport { NavigationListItemRedwoodTheme } from './themes/redwood/NavigationListItemTheme';\nimport { ComponentChildren } from 'preact';\n\ntype Severity = 'warning' | 'info' | 'none' | 'error' | 'confirmation';\n\nexport type BaseNavigationListItemProps<K extends string | number> = {\n /**\n * Key of the NavigationListItem.\n */\n itemKey: K;\n /**\n * Label of the NavigationListItem.\n */\n label?: string;\n /**\n * The content to be rendered inside the Badge component.\n */\n badge?: string;\n /**\n * The content to be rendered inside the Text component as a metadata.\n */\n metadata?: string;\n /**\n * The status icon to be rendered after the label.\n */\n severity?: Severity;\n /**\n * The content to be rendered for remove icon\n */\n removeIcon?: ComponentChildren;\n};\n\n/*TODO: JET-58535. Add ripple effect when touching navigationListItem. */\nexport function BaseNavigationListItem<K extends string | number>({\n itemKey,\n label,\n badge,\n metadata,\n severity = 'none',\n removeIcon\n}: BaseNavigationListItemProps<K>) {\n const itemRef = useRef<HTMLLIElement | null>(null);\n\n //Logic of the component handled here\n const {\n itemId,\n itemHandlers,\n itemClasses,\n isSelected,\n labelContainerClasses,\n labelContainerStyle\n } = useNavigationListItem({\n itemKey\n });\n\n const severityRequirement = !(severity === 'none' || severity === undefined);\n\n const IconComponent = (severityValue: Severity) => {\n switch (severityValue) {\n case 'error':\n return <ErrorS color=\"danger\" />;\n case 'warning':\n return <WarningS color=\"warning\" />;\n case 'info':\n return <InformationS color=\"info\" />;\n case 'confirmation':\n return <SuccessS color=\"success\" />;\n default:\n return null;\n }\n };\n\n const {\n styles: { iconLabelContainer, iconContainer, navigationItemMetadata }\n } = useComponentTheme<NavigationListItemVariantOptions, NavigationListItemStyles>(\n NavigationListItemRedwoodTheme\n );\n\n const navigationItemMatadata = classNames([navigationItemMetadata]);\n\n const endIconContainerClasses = classNames([iconLabelContainer, iconContainer]);\n const {\n styles: { navigationlistRemoveIcon }\n } = useComponentTheme<NavigationListItemVariantOptions, NavigationListItemStyles>(\n NavigationListItemRedwoodTheme\n );\n\n const removeClass = classNames([navigationlistRemoveIcon]);\n\n return (\n <li\n role=\"tab\"\n {...itemHandlers}\n data-oj-key={itemKey}\n id={itemId}\n class={itemClasses}\n aria-selected={isSelected}\n ref={itemRef}>\n {label && (\n <span class={labelContainerClasses} style={labelContainerStyle}>\n <Text size=\"inherit\" weight=\"inherit\" variant=\"inherit\">\n {label}\n </Text>\n </span>\n )}\n {(metadata || severityRequirement || badge || removeIcon) && (\n <Flex gap=\"2x\" align=\"center\" justify=\"end\" flex=\"1 1 auto\">\n {' '}\n {badge && (\n <span class={endIconContainerClasses}>\n <Badge size=\"md\" variant=\"neutralSubtle\">\n {badge}\n </Badge>\n </span>\n )}\n {metadata && (\n <span class={navigationItemMatadata}>\n <Text>{'( ' + metadata + ' )'}</Text>\n </span>\n )}\n {severityRequirement && (\n <span class={endIconContainerClasses}>{IconComponent(severity)}</span>\n )}\n {removeIcon && <span class={removeClass}>{removeIcon}</span>}\n </Flex>\n )}\n </li>\n );\n}\n"],"names":["createContext","useContext","mergeInterpolations","flexitemInterpolations","useInteractionStyle","useComponentTheme","NavigationListItemRedwoodTheme","useCallback","usePress","mergeProps","classNames","useRef","_jsx","ErrorS","WarningS","InformationS","SuccessS","_jsxs","Text","Flex","Badge"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;;AAMG;AAqBH;;;AAGG;AAEH,MAAM,qBAAqB,GAAGA,oBAAa,CAA8C,IAAK;;AChC9F;;;;;;AAMG;AAKH;;;;AAIG;AACH,SAAS,wBAAwB,GAAA;AAC/B,IAAA,OAAOC,gBAAU,CAAC,qBAAqB,CAAC,CAAC;AAC3C;;ACDA,MAAM,2BAA2B,GAAGC,uCAAmB,CAAgB;AACrE,IAAA,GAAG,MAAM,CAAC,MAAM,CAACC,+BAAsB,CAAC;AACzC,CAAA,CAAC,CAAC;AACH,MAAM,EAAE,KAAK,EAAE,6BAA6B,EAAE,GAAG,2BAA2B,EAAE,GAC5E,2BAA2B,CAAC;AAC1B,IAAA,SAAS,EAAE,QAAQ;AACpB,CAAA,CAAC,CAAC;AAEW,SAAA,qBAAqB,CAA4B,EAAE,OAAO,EAAkB,EAAA;AAC1F,IAAA,MAAM,EAAE,iBAAiB,EAAE,SAAS,EAAE,UAAU,EAAE,aAAa,EAAE,wBAAwB,EAAE,GACzF,wBAAwB,EAAE,CAAC;;AAG7B,IAAA,MAAM,SAAS,GAAG,UAAU,KAAK,OAAO,CAAC;AAEzC,IAAA,MAAM,UAAU,GAAG,SAAS,KAAK,OAAO,CAAC;;AAGzC,IAAA,MAAM,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,eAAe,EAAE,gBAA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AAQ,CAAA,CACvE,EACA,UAAU,IAAIA,cAAM,CAAA,MAAA,EAAA,EAAA,KAAK,EAAE,WAAW,YAAG,UAAU,EAAA,CAAQ,IACvD,CACR,CAAA,EAAA,CACE,EACL;AACJ;;;;;;"}
@@ -1,53 +0,0 @@
1
- /* @oracle/oraclejet-preact: undefined */
2
- 'use strict';
3
-
4
- var jsxRuntime = require('preact/jsx-runtime');
5
- var preact = require('preact');
6
- var hooks = require('preact/hooks');
7
- var compat = require('preact/compat');
8
- require('./FormContext-9452bd30.js');
9
- var useFormContext = require('./useFormContext-4c3091dc.js');
10
- var FormFieldContext = require('./FormFieldContext-8418dc68.js');
11
- var useFormFieldContextProps = require('./useFormFieldContextProps-8c04ed0f.js');
12
-
13
- var useId = require('./useId-6c0eeb27.js');
14
- var CheckboxRadioField = require('./CheckboxRadioField-0d4b2c66.js');
15
-
16
- const CheckboxSetContext = preact.createContext({});
17
- const useCheckboxSetContext = () => hooks.useContext(CheckboxSetContext);
18
-
19
- var styles = {ul:'CheckboxSetStyles_styles_ul__68p6630'};
20
-
21
- /**
22
- * A CheckboxSet set allows the user to select one or more options from a set.
23
- */
24
- const CheckboxSet = compat.forwardRef(({ 'aria-describedby': ariaDescribedBy, assistiveText, columnSpan, direction = 'column', helpSourceLink, helpSourceText, isDisabled: propIsDisabled, isReadonly: propIsReadonly, isRequired = false, label, labelEdge: propLabelEdge, labelStartWidth: propLabelStartWidth, messages, onCommit, userAssistanceDensity: propUserAssistanceDensity, value, children, testId }, ref) => {
25
- const hasValue = value !== undefined ? value.size > 0 : false;
26
- const baseId = useId.useId();
27
- const { isDisabled: isFormDisabled, isReadonly: isFormReadonly, labelEdge: formLabelEdge, labelStartWidth: formLabelStartWidth, userAssistanceDensity: formUserAssistanceDensity } = useFormContext.useFormContext();
28
- // default to FormContext values if component properties are not specified
29
- const isDisabled = propIsDisabled ?? isFormDisabled;
30
- const isReadonly = propIsReadonly ?? isFormReadonly;
31
- const labelEdge = propLabelEdge ?? formLabelEdge;
32
- const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;
33
- const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;
34
- const formFieldContext = useFormFieldContextProps.useFormFieldContextProps({
35
- hasValue,
36
- isDisabled,
37
- isReadonly
38
- });
39
- const checkboxSetContext = hooks.useMemo(() => ({
40
- name: baseId,
41
- value,
42
- onCommit
43
- }), [baseId, onCommit, value]);
44
- // wrap each CheckboxItem in an <li> tag and the entire set with <ul>
45
- const childrenArray = preact.toChildArray(children).filter(Boolean);
46
- const wrappedChildren = childrenArray.map((item) => jsxRuntime.jsx("li", { children: item }));
47
- return (jsxRuntime.jsx(FormFieldContext.FormFieldContext.Provider, { value: formFieldContext, children: jsxRuntime.jsx(CheckboxRadioField.CheckboxRadioField, { "aria-describedby": ariaDescribedBy, assistiveText: assistiveText, baseId: baseId, columnSpan: columnSpan, direction: direction, helpSourceLink: helpSourceLink, helpSourceText: helpSourceText, isDisabled: isDisabled, isReadonly: isReadonly, isRequired: isRequired, label: label, labelEdge: labelEdge, labelStartWidth: labelStartWidth, parentComponentVariant: "checkboxSet", messages: messages, userAssistanceDensity: userAssistanceDensity, hasValue: hasValue, role: "group", testId: testId, ref: ref, children: jsxRuntime.jsx(CheckboxSetContext.Provider, { value: checkboxSetContext, children: jsxRuntime.jsx("ul", { className: styles.ul, children: wrappedChildren }) }) }) }));
48
- });
49
-
50
- exports.CheckboxSet = CheckboxSet;
51
- exports.CheckboxSetContext = CheckboxSetContext;
52
- exports.useCheckboxSetContext = useCheckboxSetContext;
53
- //# sourceMappingURL=CheckboxSet-13a5c10c.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"NavigationListItem-12a76e7d.js","sources":["../../src/UNSAFE_NavigationList/useNavigationList.ts","../../src/UNSAFE_NavigationList/NavigationList.tsx","../../src/UNSAFE_NavigationList/NavigationListItem.tsx"],"sourcesContent":["import { useState, useCallback, MutableRef, useRef, useEffect } from 'preact/hooks';\nimport {\n keyExtractor,\n getFirstVisibleKey,\n getKey,\n getPrevNextKeyUsingRef,\n findElementByKey\n} from '../utils/PRIVATE_collectionUtils';\nimport { mergeProps } from '../utils/UNSAFE_mergeProps';\nimport { useCollectionFocusRing } from '../hooks/PRIVATE_useCollectionFocusRing';\nimport { useCurrentKey } from '../hooks/PRIVATE_useCurrentKey';\nimport { NavigationListContextProps } from '../UNSAFE_NavigationListCommon';\n\nimport { ComponentChildren } from 'preact';\n\n/**\n * type for payload of current key change event handler\n */\ntype CurrentKeyDetail<K> = {\n value: K;\n};\n/**\n * type for payload of selection change event handler\n */\ntype SelectionDetail<K> = {\n value: K;\n reason: 'pointer' | 'keyboard';\n};\n/**\n * type for payload of remove event handler\n */\ntype RemoveDetail<K> = {\n value: K;\n};\n\n/*TODO: JET-58534. Create a hook to share some logic between navlist and tabbar. Hook will be used inside this one. */\nexport function useNavigationList<K extends string | number>({\n containerRef,\n selection,\n onRemove,\n onSelectionChange,\n children\n}: {\n containerRef: MutableRef<HTMLUListElement>;\n selection?: K;\n onRemove?: <K extends string | number>(detail: RemoveDetail<K>) => void;\n onSelectionChange?: <K extends string | number>(detail: SelectionDetail<K>) => void;\n children: ComponentChildren;\n}) {\n const ITEM_SELECTOR = '[role=\"tab\"]';\n const REMOVAL_ICON_SELECTOR = '[data-oj-navigationlist-item-remove-icon]';\n const [currentKey, setCurrentKey] = useState<K | undefined>(selection);\n\n const onCurrentKeyChange = useCallback((detail: CurrentKeyDetail<K | undefined>) => {\n setCurrentKey(detail.value);\n }, []) as NavigationListContextProps<K>['onCurrentKeyChange'];\n\n const { currentKeyProps } = useCurrentKey(\n (element) =>\n onRemove\n ? (extractOnlyItemKey(element, ITEM_SELECTOR, REMOVAL_ICON_SELECTOR) as K)\n : keyExtractor(element, ITEM_SELECTOR),\n false,\n getPrevNextKeyUsingRef(containerRef, currentKey, true, ITEM_SELECTOR),\n getPrevNextKeyUsingRef(containerRef, currentKey, false, ITEM_SELECTOR),\n undefined,\n undefined,\n currentKey,\n onCurrentKeyChange\n );\n\n const [showFocusRing, focusRingProps] = useCollectionFocusRing(containerRef, [\n 'Home',\n 'End',\n 'ArrowUp',\n 'ArrowDown'\n ]);\n\n const onFocus = useCallback(() => {\n if (containerRef.current && currentKey === undefined) {\n const key = getFirstVisibleKey(containerRef.current, ITEM_SELECTOR);\n if (key) {\n setCurrentKey(key as K);\n }\n }\n }, [currentKey, containerRef]);\n\n const onFocusProps = { onFocus };\n const prevNavItems = useRef<K[]>();\n\n useEffect(() => {\n if (containerRef.current) {\n const navListItemKeys = Array.from(\n containerRef.current.querySelectorAll(ITEM_SELECTOR),\n (elem) => getKey(elem as HTMLElement) as K\n );\n if (currentKey != null && navListItemKeys.indexOf(currentKey) !== -1) {\n const navListItem = findElementByKey(\n containerRef.current,\n currentKey,\n ITEM_SELECTOR\n ) as any;\n if (navListItem.scrollIntoViewIfNeeded) {\n // for some browsers, we'll need the non-standard scrollIntoViewIfNeeded\n navListItem.scrollIntoViewIfNeeded();\n } else {\n navListItem.scrollIntoView({ block: 'nearest' });\n }\n } else {\n if (currentKey && navListItemKeys.indexOf(currentKey) === -1) {\n prevNavItems.current\n ? setCurrentKey(findNextCurrentKey(currentKey, navListItemKeys, prevNavItems.current))\n : setCurrentKey(navListItemKeys[0] as K);\n }\n prevNavItems.current = navListItemKeys;\n }\n }\n }, [children, currentKey, containerRef]);\n\n const onKeyDown = useCallback(\n (event: KeyboardEvent) => {\n if ((event.key === 'Home' || event.key === 'End') && containerRef.current && currentKey) {\n const navListItemKey = Array.from(\n containerRef.current.querySelectorAll(ITEM_SELECTOR),\n (elem) => getKey(elem as HTMLElement) as K\n );\n onCurrentKeyChange?.({\n value: navListItemKey[event.key === 'Home' ? 0 : navListItemKey.length - 1] as K\n });\n }\n if (currentKey && event.key === 'Enter') {\n onSelectionChange?.({\n value: currentKey as K,\n reason: 'keyboard'\n });\n }\n if (currentKey && event.key === 'Delete') {\n onRemove?.({ value: currentKey as K });\n }\n },\n [currentKey, onSelectionChange, onRemove, onCurrentKeyChange, containerRef]\n );\n\n return {\n showFocusRing,\n currentKey,\n onCurrentKeyChange,\n onKeyDown,\n containerHandlers: mergeProps(focusRingProps, currentKeyProps, onFocusProps)\n };\n}\n\nconst extractOnlyItemKey = (element: HTMLElement, itemSelector: string, itemEliminator: string) => {\n const navigationListItem = element.closest(itemSelector);\n const removeButton = element.closest(itemEliminator);\n return navigationListItem?.contains(removeButton) ? null : keyExtractor(element, itemSelector);\n};\n\nconst findNextCurrentKey = <K>(currentKey: K, currNavs: K[], prevNavs: K[]) => {\n const index = prevNavs.indexOf(currentKey);\n if (index > 0) {\n const nextIndex = index === prevNavs.length - 1 ? index - 1 : index + 1;\n const nextKey = prevNavs[nextIndex];\n if (currNavs.indexOf(nextKey) !== -1) {\n return nextKey;\n }\n }\n // update current key to be the first one if we can't find a suitable next key\n return currNavs[0];\n};\n","import { Ref } from 'preact';\nimport { MutableRef, useRef } from 'preact/hooks';\nimport { mergeProps } from '../utils/UNSAFE_mergeProps';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { useId } from '../hooks/UNSAFE_useId';\nimport { navigationListStyles } from './themes/NavigationListStyles.css';\nimport { useNavigationList } from './useNavigationList';\nimport { forwardRef, useImperativeHandle } from 'preact/compat';\nimport { useTestId, TestIdProps } from '../hooks/UNSAFE_useTestId';\nimport { NavigationListProps, NavigationListContext } from '../UNSAFE_NavigationListCommon';\nexport { RemovableNavigationListItem } from '../UNSAFE_NavigationListCommon';\n\nexport type FocusableHandle = {\n focus: () => void;\n blur: () => void;\n};\n\nexport const NavigationList = forwardRef(\n <K extends string | number>(\n {\n children,\n selection,\n onSelectionChange,\n onRemove,\n 'aria-label': ariaLabel,\n 'aria-labelledby': ariaLabelLedBy,\n testId\n }: NavigationListProps<K> & TestIdProps,\n ref?: Ref<FocusableHandle>\n ) => {\n const containerRef = useRef<HTMLUListElement>(null);\n\n const { showFocusRing, currentKey, onCurrentKeyChange, containerHandlers, onKeyDown } =\n useNavigationList({\n containerRef: containerRef as MutableRef<HTMLUListElement>,\n selection,\n onRemove,\n onSelectionChange,\n children\n });\n\n const eventProps = { onKeyDown };\n const navigationListClass = classNames([navigationListStyles.uListStyle]);\n const navigationListItemPrefix = useId() + '_';\n const testIdProps = useTestId(testId);\n\n //Allows to call focus on rootRef without having to expose it\n useImperativeHandle(ref!, () => ({\n focus: () => {\n if (containerRef.current) {\n containerRef.current.focus();\n }\n },\n blur: () => {\n if (containerRef.current) {\n containerRef.current.focus();\n }\n }\n }));\n\n return (\n <ul\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelLedBy}\n role=\"tablist\"\n ref={containerRef}\n aria-orientation={'vertical'}\n tabIndex={0}\n aria-activedescendant={currentKey ? navigationListItemPrefix + currentKey : ''}\n {...mergeProps(eventProps, containerHandlers)}\n {...testIdProps}\n class={navigationListClass}>\n <NavigationListContext.Provider\n value={{\n selection,\n onSelectionChange,\n onCurrentKeyChange,\n currentKey,\n showFocusRing,\n navigationListItemPrefix,\n onRemove\n }}>\n {children}\n </NavigationListContext.Provider>\n </ul>\n );\n }\n);\n","import {\n BaseNavigationListItem,\n BaseNavigationListItemProps\n} from '../UNSAFE_NavigationListCommon/BaseNavigationListItem';\n\nexport type NavigationListItemProps<K extends string | number> = Omit<\n BaseNavigationListItemProps<K>,\n 'removeIcon'\n>;\n\nexport function NavigationListItem<K extends string | number>({\n itemKey,\n label,\n badge,\n metadata,\n severity\n}: NavigationListItemProps<K>) {\n return (\n <BaseNavigationListItem\n itemKey={itemKey}\n label={label}\n badge={badge}\n metadata={metadata}\n severity={severity}\n />\n );\n}\n"],"names":["useState","useCallback","useCurrentKey","keyExtractor","getPrevNextKeyUsingRef","useCollectionFocusRing","getFirstVisibleKey","useRef","useEffect","getKey","findElementByKey","mergeProps","forwardRef","classNames","navigationListStyles","useId","useTestId","useImperativeHandle","_jsx","NavigationListContext","BaseNavigationListItem"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAmCA;AACgB,SAAA,iBAAiB,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