@deephaven/components 0.72.1-beta.5 → 0.72.1-core-plugins.9

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 (263) hide show
  1. package/css/BaseStyleSheet.css.map +1 -1
  2. package/dist/BasicModal.js +2 -2
  3. package/dist/BasicModal.js.map +1 -1
  4. package/dist/Button.d.ts +1 -1
  5. package/dist/Button.d.ts.map +1 -1
  6. package/dist/Button.js +12 -2
  7. package/dist/Button.js.map +1 -1
  8. package/dist/Checkbox.js +2 -2
  9. package/dist/Checkbox.js.map +1 -1
  10. package/dist/ComboBox.css.map +1 -1
  11. package/dist/ComponentUtils.d.ts +34 -0
  12. package/dist/ComponentUtils.d.ts.map +1 -0
  13. package/dist/ComponentUtils.js +49 -0
  14. package/dist/ComponentUtils.js.map +1 -0
  15. package/dist/CustomTimeSelect.css.map +1 -1
  16. package/dist/DateTimeInput.d.ts +3 -3
  17. package/dist/DateTimeInput.d.ts.map +1 -1
  18. package/dist/DateTimeInput.js +1 -1
  19. package/dist/DateTimeInput.js.map +1 -1
  20. package/dist/DraggableItemList.css.map +1 -1
  21. package/dist/ErrorView.css +77 -0
  22. package/dist/ErrorView.css.map +1 -0
  23. package/dist/ErrorView.d.ts +16 -0
  24. package/dist/ErrorView.d.ts.map +1 -0
  25. package/dist/ErrorView.js +73 -0
  26. package/dist/ErrorView.js.map +1 -0
  27. package/dist/HierarchicalCheckboxMenu.css.map +1 -1
  28. package/dist/HierarchicalCheckboxMenu.js +1 -1
  29. package/dist/HierarchicalCheckboxMenu.js.map +1 -1
  30. package/dist/LoadingOverlay.css +2 -1
  31. package/dist/LoadingOverlay.css.map +1 -1
  32. package/dist/RadioGroup.js +2 -2
  33. package/dist/RadioGroup.js.map +1 -1
  34. package/dist/RadioItem.js +2 -2
  35. package/dist/RadioItem.js.map +1 -1
  36. package/dist/SearchInput.css.map +1 -1
  37. package/dist/SearchableCombobox.d.ts +2 -2
  38. package/dist/SearchableCombobox.d.ts.map +1 -1
  39. package/dist/SearchableCombobox.js.map +1 -1
  40. package/dist/Select.d.ts +1 -1
  41. package/dist/SocketedButton.d.ts.map +1 -1
  42. package/dist/SocketedButton.js +12 -2
  43. package/dist/SocketedButton.js.map +1 -1
  44. package/dist/{ButtonGroup.d.ts → SplitButtonGroup.d.ts} +5 -5
  45. package/dist/SplitButtonGroup.d.ts.map +1 -0
  46. package/dist/{ButtonGroup.js → SplitButtonGroup.js} +6 -6
  47. package/dist/SplitButtonGroup.js.map +1 -0
  48. package/dist/TimeSlider.css.map +1 -1
  49. package/dist/TimeSlider.module.css.map +1 -1
  50. package/dist/XComponent.d.ts +38 -0
  51. package/dist/XComponent.d.ts.map +1 -0
  52. package/dist/XComponent.js +70 -0
  53. package/dist/XComponent.js.map +1 -0
  54. package/dist/XComponentMap.d.ts +15 -0
  55. package/dist/XComponentMap.d.ts.map +1 -0
  56. package/dist/XComponentMap.js +20 -0
  57. package/dist/XComponentMap.js.map +1 -0
  58. package/dist/index.d.ts +7 -7
  59. package/dist/index.d.ts.map +1 -1
  60. package/dist/index.js +7 -7
  61. package/dist/index.js.map +1 -1
  62. package/dist/navigation/MenuItem.css.map +1 -1
  63. package/dist/navigation/NavTab.d.ts.map +1 -1
  64. package/dist/navigation/NavTab.js +28 -7
  65. package/dist/navigation/NavTab.js.map +1 -1
  66. package/dist/navigation/NavTabList.css.map +1 -1
  67. package/dist/navigation/NavTabList.d.ts +5 -0
  68. package/dist/navigation/NavTabList.d.ts.map +1 -1
  69. package/dist/navigation/NavTabList.js.map +1 -1
  70. package/dist/spectrum/ActionGroup.d.ts +14 -0
  71. package/dist/spectrum/ActionGroup.d.ts.map +1 -0
  72. package/dist/spectrum/ActionGroup.js +42 -0
  73. package/dist/spectrum/ActionGroup.js.map +1 -0
  74. package/dist/spectrum/ActionMenu.d.ts +15 -0
  75. package/dist/spectrum/ActionMenu.d.ts.map +1 -0
  76. package/dist/spectrum/ActionMenu.js +35 -0
  77. package/dist/spectrum/ActionMenu.js.map +1 -0
  78. package/dist/spectrum/Heading.d.ts +4 -1
  79. package/dist/spectrum/Heading.d.ts.map +1 -1
  80. package/dist/spectrum/Heading.js +5 -3
  81. package/dist/spectrum/Heading.js.map +1 -1
  82. package/dist/spectrum/ItemContent.d.ts +15 -0
  83. package/dist/spectrum/ItemContent.d.ts.map +1 -0
  84. package/dist/spectrum/{picker/PickerItemContent.js → ItemContent.js} +44 -19
  85. package/dist/spectrum/ItemContent.js.map +1 -0
  86. package/dist/spectrum/ItemTooltip.d.ts +12 -0
  87. package/dist/spectrum/ItemTooltip.d.ts.map +1 -0
  88. package/dist/spectrum/ItemTooltip.js +30 -0
  89. package/dist/spectrum/ItemTooltip.js.map +1 -0
  90. package/dist/spectrum/ListActionGroup.d.ts +19 -0
  91. package/dist/spectrum/ListActionGroup.d.ts.map +1 -0
  92. package/dist/spectrum/ListActionGroup.js +9 -0
  93. package/dist/spectrum/ListActionGroup.js.map +1 -0
  94. package/dist/spectrum/ListActionMenu.d.ts +19 -0
  95. package/dist/spectrum/ListActionMenu.d.ts.map +1 -0
  96. package/dist/spectrum/ListActionMenu.js +9 -0
  97. package/dist/spectrum/ListActionMenu.js.map +1 -0
  98. package/dist/spectrum/Text.d.ts +4 -1
  99. package/dist/spectrum/Text.d.ts.map +1 -1
  100. package/dist/spectrum/Text.js +5 -4
  101. package/dist/spectrum/Text.js.map +1 -1
  102. package/dist/spectrum/View.d.ts +20 -3
  103. package/dist/spectrum/View.d.ts.map +1 -1
  104. package/dist/spectrum/View.js +47 -10
  105. package/dist/spectrum/View.js.map +1 -1
  106. package/dist/spectrum/buttons.d.ts +1 -1
  107. package/dist/spectrum/buttons.d.ts.map +1 -1
  108. package/dist/spectrum/buttons.js +3 -1
  109. package/dist/spectrum/buttons.js.map +1 -1
  110. package/dist/spectrum/collections.d.ts +1 -1
  111. package/dist/spectrum/collections.d.ts.map +1 -1
  112. package/dist/spectrum/collections.js +12 -1
  113. package/dist/spectrum/collections.js.map +1 -1
  114. package/dist/spectrum/comboBox/ComboBox.d.ts +17 -0
  115. package/dist/spectrum/comboBox/ComboBox.d.ts.map +1 -0
  116. package/dist/spectrum/comboBox/ComboBox.js +44 -0
  117. package/dist/spectrum/comboBox/ComboBox.js.map +1 -0
  118. package/dist/spectrum/comboBox/ComboBoxNormalized.d.ts +15 -0
  119. package/dist/spectrum/comboBox/ComboBoxNormalized.d.ts.map +1 -0
  120. package/dist/spectrum/comboBox/ComboBoxNormalized.js +42 -0
  121. package/dist/spectrum/comboBox/ComboBoxNormalized.js.map +1 -0
  122. package/dist/spectrum/comboBox/index.d.ts +3 -0
  123. package/dist/spectrum/comboBox/index.d.ts.map +1 -0
  124. package/dist/spectrum/comboBox/index.js +3 -0
  125. package/dist/spectrum/comboBox/index.js.map +1 -0
  126. package/dist/spectrum/forms.d.ts +2 -1
  127. package/dist/spectrum/forms.d.ts.map +1 -1
  128. package/dist/spectrum/forms.js +1 -1
  129. package/dist/spectrum/forms.js.map +1 -1
  130. package/dist/spectrum/icons.d.ts +2 -0
  131. package/dist/spectrum/icons.d.ts.map +1 -0
  132. package/dist/spectrum/icons.js +3 -0
  133. package/dist/spectrum/icons.js.map +1 -0
  134. package/dist/spectrum/index.d.ts +9 -1
  135. package/dist/spectrum/index.d.ts.map +1 -1
  136. package/dist/spectrum/index.js +9 -1
  137. package/dist/spectrum/index.js.map +1 -1
  138. package/dist/spectrum/listView/ListView.d.ts +14 -0
  139. package/dist/spectrum/listView/ListView.d.ts.map +1 -0
  140. package/dist/spectrum/listView/ListView.js +43 -0
  141. package/dist/spectrum/listView/ListView.js.map +1 -0
  142. package/dist/spectrum/listView/ListViewNormalized.d.ts +23 -0
  143. package/dist/spectrum/listView/ListViewNormalized.d.ts.map +1 -0
  144. package/dist/spectrum/listView/ListViewNormalized.js +82 -0
  145. package/dist/spectrum/listView/ListViewNormalized.js.map +1 -0
  146. package/dist/spectrum/listView/ListViewWrapper.css +48 -0
  147. package/dist/spectrum/listView/ListViewWrapper.css.map +1 -0
  148. package/dist/spectrum/listView/ListViewWrapper.d.ts +21 -0
  149. package/dist/spectrum/listView/ListViewWrapper.d.ts.map +1 -0
  150. package/dist/spectrum/listView/ListViewWrapper.js +71 -0
  151. package/dist/spectrum/listView/ListViewWrapper.js.map +1 -0
  152. package/dist/spectrum/listView/index.d.ts +4 -0
  153. package/dist/spectrum/listView/index.d.ts.map +1 -0
  154. package/dist/spectrum/listView/index.js +4 -0
  155. package/dist/spectrum/listView/index.js.map +1 -0
  156. package/dist/spectrum/picker/Picker.d.ts +17 -31
  157. package/dist/spectrum/picker/Picker.d.ts.map +1 -1
  158. package/dist/spectrum/picker/Picker.js +31 -130
  159. package/dist/spectrum/picker/Picker.js.map +1 -1
  160. package/dist/spectrum/picker/PickerNormalized.d.ts +10 -0
  161. package/dist/spectrum/picker/PickerNormalized.d.ts.map +1 -0
  162. package/dist/spectrum/picker/PickerNormalized.js +37 -0
  163. package/dist/spectrum/picker/PickerNormalized.js.map +1 -0
  164. package/dist/spectrum/picker/PickerProps.d.ts +64 -0
  165. package/dist/spectrum/picker/PickerProps.d.ts.map +1 -0
  166. package/dist/spectrum/picker/PickerProps.js +2 -0
  167. package/dist/spectrum/picker/PickerProps.js.map +1 -0
  168. package/dist/spectrum/picker/index.d.ts +6 -1
  169. package/dist/spectrum/picker/index.d.ts.map +1 -1
  170. package/dist/spectrum/picker/index.js +6 -1
  171. package/dist/spectrum/picker/index.js.map +1 -1
  172. package/dist/spectrum/picker/useMultiRef.d.ts +9 -0
  173. package/dist/spectrum/picker/useMultiRef.d.ts.map +1 -0
  174. package/dist/spectrum/picker/useMultiRef.js +25 -0
  175. package/dist/spectrum/picker/useMultiRef.js.map +1 -0
  176. package/dist/spectrum/picker/usePickerItemScale.d.ts +9 -0
  177. package/dist/spectrum/picker/usePickerItemScale.d.ts.map +1 -0
  178. package/dist/spectrum/picker/usePickerItemScale.js +17 -0
  179. package/dist/spectrum/picker/usePickerItemScale.js.map +1 -0
  180. package/dist/spectrum/picker/usePickerNormalizedProps.d.ts +27 -0
  181. package/dist/spectrum/picker/usePickerNormalizedProps.d.ts.map +1 -0
  182. package/dist/spectrum/picker/usePickerNormalizedProps.js +101 -0
  183. package/dist/spectrum/picker/usePickerNormalizedProps.js.map +1 -0
  184. package/dist/spectrum/picker/usePickerProps.d.ts +28 -0
  185. package/dist/spectrum/picker/usePickerProps.d.ts.map +1 -0
  186. package/dist/spectrum/picker/usePickerProps.js +75 -0
  187. package/dist/spectrum/picker/usePickerProps.js.map +1 -0
  188. package/dist/spectrum/picker/usePickerScrollOnOpen.d.ts +22 -0
  189. package/dist/spectrum/picker/usePickerScrollOnOpen.d.ts.map +1 -0
  190. package/dist/spectrum/picker/usePickerScrollOnOpen.js +33 -0
  191. package/dist/spectrum/picker/usePickerScrollOnOpen.js.map +1 -0
  192. package/dist/spectrum/shared.d.ts +15 -9
  193. package/dist/spectrum/shared.d.ts.map +1 -1
  194. package/dist/spectrum/shared.js +16 -1
  195. package/dist/spectrum/shared.js.map +1 -1
  196. package/dist/spectrum/utils/index.d.ts +7 -0
  197. package/dist/spectrum/utils/index.d.ts.map +1 -1
  198. package/dist/spectrum/utils/index.js +7 -0
  199. package/dist/spectrum/utils/index.js.map +1 -1
  200. package/dist/spectrum/utils/itemUtils.d.ts +80 -27
  201. package/dist/spectrum/utils/itemUtils.d.ts.map +1 -1
  202. package/dist/spectrum/utils/itemUtils.js +106 -111
  203. package/dist/spectrum/utils/itemUtils.js.map +1 -1
  204. package/dist/spectrum/utils/itemWrapperUtils.d.ts +28 -0
  205. package/dist/spectrum/utils/itemWrapperUtils.d.ts.map +1 -0
  206. package/dist/spectrum/utils/itemWrapperUtils.js +111 -0
  207. package/dist/spectrum/utils/itemWrapperUtils.js.map +1 -0
  208. package/dist/spectrum/utils/propsUtils.d.ts +14 -0
  209. package/dist/spectrum/utils/propsUtils.d.ts.map +1 -0
  210. package/dist/spectrum/utils/propsUtils.js +93 -0
  211. package/dist/spectrum/utils/propsUtils.js.map +1 -0
  212. package/dist/spectrum/utils/useOnChangeTrackUncontrolled.d.ts +19 -0
  213. package/dist/spectrum/utils/useOnChangeTrackUncontrolled.d.ts.map +1 -0
  214. package/dist/spectrum/utils/useOnChangeTrackUncontrolled.js +31 -0
  215. package/dist/spectrum/utils/useOnChangeTrackUncontrolled.js.map +1 -0
  216. package/dist/spectrum/utils/useRenderNormalizedItem.d.ts +25 -0
  217. package/dist/spectrum/utils/useRenderNormalizedItem.d.ts.map +1 -0
  218. package/dist/spectrum/utils/useRenderNormalizedItem.js +87 -0
  219. package/dist/spectrum/utils/useRenderNormalizedItem.js.map +1 -0
  220. package/dist/spectrum/utils/useStaticItemInitialScrollPosition.d.ts +10 -0
  221. package/dist/spectrum/utils/useStaticItemInitialScrollPosition.d.ts.map +1 -0
  222. package/dist/spectrum/utils/useStaticItemInitialScrollPosition.js +27 -0
  223. package/dist/spectrum/utils/useStaticItemInitialScrollPosition.js.map +1 -0
  224. package/dist/spectrum/utils/useStringifiedMultiSelection.d.ts +43 -0
  225. package/dist/spectrum/utils/useStringifiedMultiSelection.d.ts.map +1 -0
  226. package/dist/spectrum/utils/useStringifiedMultiSelection.js +53 -0
  227. package/dist/spectrum/utils/useStringifiedMultiSelection.js.map +1 -0
  228. package/dist/spectrum/utils/useStringifiedSelection.d.ts +33 -0
  229. package/dist/spectrum/utils/useStringifiedSelection.d.ts.map +1 -0
  230. package/dist/spectrum/utils/useStringifiedSelection.js +50 -0
  231. package/dist/spectrum/utils/useStringifiedSelection.js.map +1 -0
  232. package/dist/theme/SpectrumThemeProvider.js +2 -2
  233. package/dist/theme/SpectrumThemeProvider.js.map +1 -1
  234. package/dist/theme/index.d.ts +1 -0
  235. package/dist/theme/index.d.ts.map +1 -1
  236. package/dist/theme/index.js +1 -0
  237. package/dist/theme/index.js.map +1 -1
  238. package/dist/theme/theme-spectrum/theme-spectrum-overrides.css +1 -1
  239. package/dist/theme/theme-spectrum/theme-spectrum-overrides.css.map +1 -1
  240. package/dist/theme/useSpectrumThemeProvider.d.ts +4 -0
  241. package/dist/theme/useSpectrumThemeProvider.d.ts.map +1 -0
  242. package/dist/theme/useSpectrumThemeProvider.js +4 -0
  243. package/dist/theme/useSpectrumThemeProvider.js.map +1 -0
  244. package/package.json +11 -10
  245. package/scss/new_variables.scss +1 -1
  246. package/scss/util.scss +4 -0
  247. package/dist/ButtonGroup.d.ts.map +0 -1
  248. package/dist/ButtonGroup.js.map +0 -1
  249. package/dist/ButtonOld.d.ts +0 -12
  250. package/dist/ButtonOld.d.ts.map +0 -1
  251. package/dist/ButtonOld.js +0 -43
  252. package/dist/ButtonOld.js.map +0 -1
  253. package/dist/ComboBox.d.ts +0 -120
  254. package/dist/ComboBox.d.ts.map +0 -1
  255. package/dist/ComboBox.js +0 -497
  256. package/dist/ComboBox.js.map +0 -1
  257. package/dist/spectrum/picker/PickerItemContent.d.ts +0 -11
  258. package/dist/spectrum/picker/PickerItemContent.d.ts.map +0 -1
  259. package/dist/spectrum/picker/PickerItemContent.js.map +0 -1
  260. package/dist/spectrum/pickers.d.ts +0 -2
  261. package/dist/spectrum/pickers.d.ts.map +0 -1
  262. package/dist/spectrum/pickers.js +0 -2
  263. package/dist/spectrum/pickers.js.map +0 -1
@@ -1,4 +1,4 @@
1
- var _excluded = ["backgroundColor", "UNSAFE_style"];
1
+ var _excluded = ["backgroundColor", "borderColor", "borderStartColor", "borderEndColor", "borderTopColor", "borderBottomColor", "borderXColor", "borderYColor", "UNSAFE_style"];
2
2
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
3
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
4
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
@@ -7,32 +7,69 @@ function _toPrimitive(input, hint) { if (typeof input !== "object" || input ===
7
7
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
8
8
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
9
9
  /* eslint-disable react/jsx-props-no-spreading */
10
- import { useMemo } from 'react';
11
- import { View as SpectrumView } from '@adobe/react-spectrum';
10
+ import { forwardRef, useMemo } from 'react';
11
+ import { useLocale, View as SpectrumView } from '@adobe/react-spectrum';
12
12
  import { colorValueStyle } from "../theme/colorUtils.js";
13
13
  import { jsx as _jsx } from "react/jsx-runtime";
14
14
  /**
15
15
  * A View component that re-exports the Spectrum View component.
16
16
  * However, it overrides ColorValues to accept CSS color strings and
17
- * our custom variable names from our color paletee and semantic colors.
17
+ * our custom variable names from our color palette and semantic colors.
18
18
  *
19
19
  * @param props The props for the View component
20
20
  * @returns The View component
21
21
  *
22
22
  */
23
-
24
- export function View(props) {
23
+ export var View = /*#__PURE__*/forwardRef((props, forwardedRef) => {
25
24
  var {
26
25
  backgroundColor,
26
+ borderColor,
27
+ borderStartColor,
28
+ borderEndColor,
29
+ borderTopColor,
30
+ borderBottomColor,
31
+ borderXColor,
32
+ borderYColor,
27
33
  UNSAFE_style
28
34
  } = props,
29
35
  rest = _objectWithoutProperties(props, _excluded);
30
- var style = useMemo(() => _objectSpread(_objectSpread({}, UNSAFE_style), {}, {
31
- backgroundColor: colorValueStyle(backgroundColor)
32
- }), [backgroundColor, UNSAFE_style]);
36
+ var {
37
+ direction
38
+ } = useLocale();
39
+ var style = useMemo(() => {
40
+ var borderStyle = {};
41
+ if (borderColor !== undefined) {
42
+ borderStyle.borderColor = colorValueStyle(borderColor);
43
+ }
44
+ if (borderXColor !== undefined) {
45
+ borderStyle.borderLeftColor = colorValueStyle(borderXColor);
46
+ borderStyle.borderRightColor = colorValueStyle(borderXColor);
47
+ }
48
+ if (borderYColor !== undefined) {
49
+ borderStyle.borderTopColor = colorValueStyle(borderYColor);
50
+ borderStyle.borderBottomColor = colorValueStyle(borderYColor);
51
+ }
52
+ if (borderStartColor !== undefined) {
53
+ borderStyle[direction === 'rtl' ? 'borderRightColor' : 'borderLeftColor'] = colorValueStyle(borderStartColor);
54
+ }
55
+ if (borderEndColor !== undefined) {
56
+ borderStyle[direction === 'rtl' ? 'borderLeftColor' : 'borderRightColor'] = colorValueStyle(borderEndColor);
57
+ }
58
+ if (borderTopColor !== undefined) {
59
+ borderStyle.borderTopColor = colorValueStyle(borderTopColor);
60
+ }
61
+ if (borderBottomColor !== undefined) {
62
+ borderStyle.borderBottomColor = colorValueStyle(borderBottomColor);
63
+ }
64
+ return _objectSpread(_objectSpread({}, UNSAFE_style), {}, {
65
+ backgroundColor: colorValueStyle(backgroundColor)
66
+ }, borderStyle);
67
+ }, [backgroundColor, UNSAFE_style, borderColor, borderStartColor, borderEndColor, borderTopColor, borderBottomColor, borderXColor, borderYColor, direction]);
33
68
  return /*#__PURE__*/_jsx(SpectrumView, _objectSpread(_objectSpread({}, rest), {}, {
69
+ ref: forwardedRef,
34
70
  UNSAFE_style: style
35
71
  }));
36
- }
72
+ });
73
+ View.displayName = 'View';
37
74
  export default View;
38
75
  //# sourceMappingURL=View.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"View.js","names":["useMemo","View","SpectrumView","colorValueStyle","jsx","_jsx","props","backgroundColor","UNSAFE_style","rest","_objectWithoutProperties","_excluded","style","_objectSpread"],"sources":["../../src/spectrum/View.tsx"],"sourcesContent":["/* eslint-disable react/jsx-props-no-spreading */\nimport { useMemo } from 'react';\nimport {\n View as SpectrumView,\n type ViewProps as SpectrumViewProps,\n} from '@adobe/react-spectrum';\nimport { type ColorValue, colorValueStyle } from '../theme/colorUtils';\n\nexport type ViewProps = Omit<SpectrumViewProps<6>, 'backgroundColor'> & {\n backgroundColor?: ColorValue;\n};\n\n/**\n * A View component that re-exports the Spectrum View component.\n * However, it overrides ColorValues to accept CSS color strings and\n * our custom variable names from our color paletee and semantic colors.\n *\n * @param props The props for the View component\n * @returns The View component\n *\n */\n\nexport function View(props: ViewProps): JSX.Element {\n const { backgroundColor, UNSAFE_style, ...rest } = props;\n const style = useMemo(\n () => ({\n ...UNSAFE_style,\n backgroundColor: colorValueStyle(backgroundColor),\n }),\n [backgroundColor, UNSAFE_style]\n );\n\n return <SpectrumView {...rest} UNSAFE_style={style} />;\n}\n\nexport default View;\n"],"mappings":";;;;;;;;AAAA;AACA,SAASA,OAAO,QAAQ,OAAO;AAC/B,SACEC,IAAI,IAAIC,YAAY,QAEf,uBAAuB;AAAC,SACLC,eAAe;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAMzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,SAASJ,IAAIA,CAACK,KAAgB,EAAe;EAClD,IAAM;MAAEC,eAAe;MAAEC;IAAsB,CAAC,GAAGF,KAAK;IAAdG,IAAI,GAAAC,wBAAA,CAAKJ,KAAK,EAAAK,SAAA;EACxD,IAAMC,KAAK,GAAGZ,OAAO,CACnB,MAAAa,aAAA,CAAAA,aAAA,KACKL,YAAY;IACfD,eAAe,EAAEJ,eAAe,CAACI,eAAe;EAAC,EACjD,EACF,CAACA,eAAe,EAAEC,YAAY,CAChC,CAAC;EAED,oBAAOH,IAAA,CAACH,YAAY,EAAAW,aAAA,CAAAA,aAAA,KAAKJ,IAAI;IAAED,YAAY,EAAEI;EAAM,EAAE,CAAC;AACxD;AAEA,eAAeX,IAAI"}
1
+ {"version":3,"file":"View.js","names":["forwardRef","useMemo","useLocale","View","SpectrumView","colorValueStyle","jsx","_jsx","props","forwardedRef","backgroundColor","borderColor","borderStartColor","borderEndColor","borderTopColor","borderBottomColor","borderXColor","borderYColor","UNSAFE_style","rest","_objectWithoutProperties","_excluded","direction","style","borderStyle","undefined","borderLeftColor","borderRightColor","_objectSpread","ref","displayName"],"sources":["../../src/spectrum/View.tsx"],"sourcesContent":["/* eslint-disable react/jsx-props-no-spreading */\nimport { CSSProperties, forwardRef, useMemo } from 'react';\nimport {\n useLocale,\n View as SpectrumView,\n type ViewProps as SpectrumViewProps,\n} from '@adobe/react-spectrum';\nimport type { DOMRefValue } from '@react-types/shared';\nimport { type ColorValue, colorValueStyle } from '../theme/colorUtils';\n\nexport type ViewProps = Omit<\n SpectrumViewProps<6>,\n | 'backgroundColor'\n | 'borderColor'\n | 'borderStartColor'\n | 'borderEndColor'\n | 'borderTopColor'\n | 'borderBottomColor'\n | 'borderXColor'\n | 'borderYColor'\n> & {\n backgroundColor?: ColorValue;\n borderColor?: ColorValue;\n borderStartColor?: ColorValue;\n borderEndColor?: ColorValue;\n borderTopColor?: ColorValue;\n borderBottomColor?: ColorValue;\n borderXColor?: ColorValue;\n borderYColor?: ColorValue;\n};\n\n/**\n * A View component that re-exports the Spectrum View component.\n * However, it overrides ColorValues to accept CSS color strings and\n * our custom variable names from our color palette and semantic colors.\n *\n * @param props The props for the View component\n * @returns The View component\n *\n */\nexport const View = forwardRef<DOMRefValue<HTMLElement>, ViewProps>(\n (props, forwardedRef): JSX.Element => {\n const {\n backgroundColor,\n borderColor,\n borderStartColor,\n borderEndColor,\n borderTopColor,\n borderBottomColor,\n borderXColor,\n borderYColor,\n UNSAFE_style,\n ...rest\n } = props;\n\n const { direction } = useLocale();\n const style = useMemo(() => {\n const borderStyle: CSSProperties = {};\n if (borderColor !== undefined) {\n borderStyle.borderColor = colorValueStyle(borderColor);\n }\n if (borderXColor !== undefined) {\n borderStyle.borderLeftColor = colorValueStyle(borderXColor);\n borderStyle.borderRightColor = colorValueStyle(borderXColor);\n }\n if (borderYColor !== undefined) {\n borderStyle.borderTopColor = colorValueStyle(borderYColor);\n borderStyle.borderBottomColor = colorValueStyle(borderYColor);\n }\n if (borderStartColor !== undefined) {\n borderStyle[\n direction === 'rtl' ? 'borderRightColor' : 'borderLeftColor'\n ] = colorValueStyle(borderStartColor);\n }\n if (borderEndColor !== undefined) {\n borderStyle[\n direction === 'rtl' ? 'borderLeftColor' : 'borderRightColor'\n ] = colorValueStyle(borderEndColor);\n }\n if (borderTopColor !== undefined) {\n borderStyle.borderTopColor = colorValueStyle(borderTopColor);\n }\n if (borderBottomColor !== undefined) {\n borderStyle.borderBottomColor = colorValueStyle(borderBottomColor);\n }\n\n return {\n ...UNSAFE_style,\n backgroundColor: colorValueStyle(backgroundColor),\n ...borderStyle,\n };\n }, [\n backgroundColor,\n UNSAFE_style,\n borderColor,\n borderStartColor,\n borderEndColor,\n borderTopColor,\n borderBottomColor,\n borderXColor,\n borderYColor,\n direction,\n ]);\n\n return <SpectrumView {...rest} ref={forwardedRef} UNSAFE_style={style} />;\n }\n);\n\nView.displayName = 'View';\n\nexport default View;\n"],"mappings":";;;;;;;;AAAA;AACA,SAAwBA,UAAU,EAAEC,OAAO,QAAQ,OAAO;AAC1D,SACEC,SAAS,EACTC,IAAI,IAAIC,YAAY,QAEf,uBAAuB;AAAC,SAELC,eAAe;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAuBzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMJ,IAAI,gBAAGH,UAAU,CAC5B,CAACQ,KAAK,EAAEC,YAAY,KAAkB;EACpC,IAAM;MACJC,eAAe;MACfC,WAAW;MACXC,gBAAgB;MAChBC,cAAc;MACdC,cAAc;MACdC,iBAAiB;MACjBC,YAAY;MACZC,YAAY;MACZC;IAEF,CAAC,GAAGV,KAAK;IADJW,IAAI,GAAAC,wBAAA,CACLZ,KAAK,EAAAa,SAAA;EAET,IAAM;IAAEC;EAAU,CAAC,GAAGpB,SAAS,CAAC,CAAC;EACjC,IAAMqB,KAAK,GAAGtB,OAAO,CAAC,MAAM;IAC1B,IAAMuB,WAA0B,GAAG,CAAC,CAAC;IACrC,IAAIb,WAAW,KAAKc,SAAS,EAAE;MAC7BD,WAAW,CAACb,WAAW,GAAGN,eAAe,CAACM,WAAW,CAAC;IACxD;IACA,IAAIK,YAAY,KAAKS,SAAS,EAAE;MAC9BD,WAAW,CAACE,eAAe,GAAGrB,eAAe,CAACW,YAAY,CAAC;MAC3DQ,WAAW,CAACG,gBAAgB,GAAGtB,eAAe,CAACW,YAAY,CAAC;IAC9D;IACA,IAAIC,YAAY,KAAKQ,SAAS,EAAE;MAC9BD,WAAW,CAACV,cAAc,GAAGT,eAAe,CAACY,YAAY,CAAC;MAC1DO,WAAW,CAACT,iBAAiB,GAAGV,eAAe,CAACY,YAAY,CAAC;IAC/D;IACA,IAAIL,gBAAgB,KAAKa,SAAS,EAAE;MAClCD,WAAW,CACTF,SAAS,KAAK,KAAK,GAAG,kBAAkB,GAAG,iBAAiB,CAC7D,GAAGjB,eAAe,CAACO,gBAAgB,CAAC;IACvC;IACA,IAAIC,cAAc,KAAKY,SAAS,EAAE;MAChCD,WAAW,CACTF,SAAS,KAAK,KAAK,GAAG,iBAAiB,GAAG,kBAAkB,CAC7D,GAAGjB,eAAe,CAACQ,cAAc,CAAC;IACrC;IACA,IAAIC,cAAc,KAAKW,SAAS,EAAE;MAChCD,WAAW,CAACV,cAAc,GAAGT,eAAe,CAACS,cAAc,CAAC;IAC9D;IACA,IAAIC,iBAAiB,KAAKU,SAAS,EAAE;MACnCD,WAAW,CAACT,iBAAiB,GAAGV,eAAe,CAACU,iBAAiB,CAAC;IACpE;IAEA,OAAAa,aAAA,CAAAA,aAAA,KACKV,YAAY;MACfR,eAAe,EAAEL,eAAe,CAACK,eAAe;IAAC,GAC9Cc,WAAW;EAElB,CAAC,EAAE,CACDd,eAAe,EACfQ,YAAY,EACZP,WAAW,EACXC,gBAAgB,EAChBC,cAAc,EACdC,cAAc,EACdC,iBAAiB,EACjBC,YAAY,EACZC,YAAY,EACZK,SAAS,CACV,CAAC;EAEF,oBAAOf,IAAA,CAACH,YAAY,EAAAwB,aAAA,CAAAA,aAAA,KAAKT,IAAI;IAAEU,GAAG,EAAEpB,YAAa;IAACS,YAAY,EAAEK;EAAM,EAAE,CAAC;AAC3E,CACF,CAAC;AAEDpB,IAAI,CAAC2B,WAAW,GAAG,MAAM;AAEzB,eAAe3B,IAAI"}
@@ -1,2 +1,2 @@
1
- export { ActionButton, type SpectrumActionButtonProps as ActionButtonProps, ActionGroup, type SpectrumActionGroupProps as ActionGroupProps, LogicButton, type SpectrumLogicButtonProps as LogicButtonProps, ToggleButton, type SpectrumToggleButtonProps as ToggleButtonProps, } from '@adobe/react-spectrum';
1
+ export { ActionButton, type SpectrumActionButtonProps as ActionButtonProps, Button as SpectrumButton, type SpectrumButtonProps, ButtonGroup, type SpectrumButtonGroupProps as ButtonGroupProps, LogicButton, type SpectrumLogicButtonProps as LogicButtonProps, ToggleButton, type SpectrumToggleButtonProps as ToggleButtonProps, } from '@adobe/react-spectrum';
2
2
  //# sourceMappingURL=buttons.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"buttons.d.ts","sourceRoot":"","sources":["../../src/spectrum/buttons.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EACZ,KAAK,yBAAyB,IAAI,iBAAiB,EACnD,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,YAAY,EACZ,KAAK,yBAAyB,IAAI,iBAAiB,GACpD,MAAM,uBAAuB,CAAC"}
1
+ {"version":3,"file":"buttons.d.ts","sourceRoot":"","sources":["../../src/spectrum/buttons.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EACZ,KAAK,yBAAyB,IAAI,iBAAiB,EACnD,MAAM,IAAI,cAAc,EACxB,KAAK,mBAAmB,EACxB,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EAEjD,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,YAAY,EACZ,KAAK,yBAAyB,IAAI,iBAAiB,GACpD,MAAM,uBAAuB,CAAC"}
@@ -1,2 +1,4 @@
1
- export { ActionButton, ActionGroup, LogicButton, ToggleButton } from '@adobe/react-spectrum';
1
+ export { ActionButton, Button as SpectrumButton, ButtonGroup,
2
+ // FileTrigger - we aren't planning to support this component
3
+ LogicButton, ToggleButton } from '@adobe/react-spectrum';
2
4
  //# sourceMappingURL=buttons.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"buttons.js","names":["ActionButton","ActionGroup","LogicButton","ToggleButton"],"sources":["../../src/spectrum/buttons.ts"],"sourcesContent":["export {\n ActionButton,\n type SpectrumActionButtonProps as ActionButtonProps,\n ActionGroup,\n type SpectrumActionGroupProps as ActionGroupProps,\n LogicButton,\n type SpectrumLogicButtonProps as LogicButtonProps,\n ToggleButton,\n type SpectrumToggleButtonProps as ToggleButtonProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,YAAY,EAEZC,WAAW,EAEXC,WAAW,EAEXC,YAAY,QAEP,uBAAuB"}
1
+ {"version":3,"file":"buttons.js","names":["ActionButton","Button","SpectrumButton","ButtonGroup","LogicButton","ToggleButton"],"sources":["../../src/spectrum/buttons.ts"],"sourcesContent":["export {\n ActionButton,\n type SpectrumActionButtonProps as ActionButtonProps,\n Button as SpectrumButton,\n type SpectrumButtonProps,\n ButtonGroup,\n type SpectrumButtonGroupProps as ButtonGroupProps,\n // FileTrigger - we aren't planning to support this component\n LogicButton,\n type SpectrumLogicButtonProps as LogicButtonProps,\n ToggleButton,\n type SpectrumToggleButtonProps as ToggleButtonProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,YAAY,EAEZC,MAAM,IAAIC,cAAc,EAExBC,WAAW;AAEX;AACAC,WAAW,EAEXC,YAAY,QAEP,uBAAuB"}
@@ -1,2 +1,2 @@
1
- export { ActionBar, type SpectrumActionBarProps as ActionBarProps, ActionMenu, type SpectrumActionMenuProps as ActionMenuProps, ListView, type SpectrumListViewProps as ListViewProps, MenuTrigger, type SpectrumMenuTriggerProps as MenuTriggerProps, TagGroup, type SpectrumTagGroupProps as TagGroupProps, } from '@adobe/react-spectrum';
1
+ export { ActionBar, type SpectrumActionBarProps as ActionBarProps, type SpectrumComboBoxProps, MenuTrigger, type SpectrumMenuTriggerProps as MenuTriggerProps, type SpectrumPickerProps, TagGroup, type SpectrumTagGroupProps as TagGroupProps, } from '@adobe/react-spectrum';
2
2
  //# sourceMappingURL=collections.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"collections.d.ts","sourceRoot":"","sources":["../../src/spectrum/collections.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,EAC7C,UAAU,EACV,KAAK,uBAAuB,IAAI,eAAe,EAC/C,QAAQ,EACR,KAAK,qBAAqB,IAAI,aAAa,EAC3C,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,QAAQ,EACR,KAAK,qBAAqB,IAAI,aAAa,GAC5C,MAAM,uBAAuB,CAAC"}
1
+ {"version":3,"file":"collections.d.ts","sourceRoot":"","sources":["../../src/spectrum/collections.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,EAG7C,KAAK,qBAAqB,EAE1B,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EAIjD,KAAK,mBAAmB,EACxB,QAAQ,EACR,KAAK,qBAAqB,IAAI,aAAa,GAC5C,MAAM,uBAAuB,CAAC"}
@@ -1,2 +1,13 @@
1
- export { ActionBar, ActionMenu, ListView, MenuTrigger, TagGroup } from '@adobe/react-spectrum';
1
+ export { ActionBar
2
+
3
+ // ComboBox is exported from ComboBox.tsx as a custom DH component. Re-exporting
4
+ // the Spectrum props type for upstream consumers that need to compose prop types.
5
+ ,
6
+ // ListBox - we aren't planning to support this component
7
+ MenuTrigger
8
+
9
+ // TableView - we aren't planning to support this component
10
+ // Picker is exported from Picker.tsx as a custom DH component. Re-exporting
11
+ // the Spectrum props type for upstream consumers that need to compose prop types.
12
+ , TagGroup } from '@adobe/react-spectrum';
2
13
  //# sourceMappingURL=collections.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"collections.js","names":["ActionBar","ActionMenu","ListView","MenuTrigger","TagGroup"],"sources":["../../src/spectrum/collections.ts"],"sourcesContent":["export {\n ActionBar,\n type SpectrumActionBarProps as ActionBarProps,\n ActionMenu,\n type SpectrumActionMenuProps as ActionMenuProps,\n ListView,\n type SpectrumListViewProps as ListViewProps,\n MenuTrigger,\n type SpectrumMenuTriggerProps as MenuTriggerProps,\n TagGroup,\n type SpectrumTagGroupProps as TagGroupProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,SAAS,EAETC,UAAU,EAEVC,QAAQ,EAERC,WAAW,EAEXC,QAAQ,QAEH,uBAAuB"}
1
+ {"version":3,"file":"collections.js","names":["ActionBar","MenuTrigger","TagGroup"],"sources":["../../src/spectrum/collections.ts"],"sourcesContent":["export {\n ActionBar,\n type SpectrumActionBarProps as ActionBarProps,\n // ComboBox is exported from ComboBox.tsx as a custom DH component. Re-exporting\n // the Spectrum props type for upstream consumers that need to compose prop types.\n type SpectrumComboBoxProps,\n // ListBox - we aren't planning to support this component\n MenuTrigger,\n type SpectrumMenuTriggerProps as MenuTriggerProps,\n // TableView - we aren't planning to support this component\n // Picker is exported from Picker.tsx as a custom DH component. Re-exporting\n // the Spectrum props type for upstream consumers that need to compose prop types.\n type SpectrumPickerProps,\n TagGroup,\n type SpectrumTagGroupProps as TagGroupProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA;;AAEA;AACA;AAAA;AAEA;AACAC;;AAEA;AACA;AACA;AAAA,EAEAC,QAAQ,QAEH,uBAAuB"}
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import { SpectrumComboBoxProps } from '@adobe/react-spectrum';
3
+ import type { NormalizedItem } from '../utils';
4
+ import { PickerPropsT } from '../picker';
5
+ export type ComboBoxProps = PickerPropsT<SpectrumComboBoxProps<NormalizedItem>>;
6
+ export declare const ComboBox: React.ForwardRefExoticComponent<Omit<SpectrumComboBoxProps<NormalizedItem>, "children" | "items" | "selectedKey" | "defaultSelectedKey" | "disabledKeys" | "onSelectionChange" | "defaultItems"> & {
7
+ children: import("../utils").ItemOrSection<unknown> | import("../utils").ItemOrSection<unknown>[];
8
+ tooltip?: boolean | import("../utils").TooltipOptions | undefined;
9
+ selectedKey?: import("../utils").ItemKey | null | undefined;
10
+ defaultSelectedKey?: import("../utils").ItemKey | undefined;
11
+ disabledKeys?: Iterable<import("../utils").ItemKey> | undefined;
12
+ onChange?: ((key: import("../utils").ItemKey | null) => void) | undefined;
13
+ onOpenChange?: ((isOpen: boolean) => void) | undefined;
14
+ onScroll?: ((event: Event) => void) | undefined;
15
+ onSelectionChange?: ((key: import("../utils").ItemKey | null) => void) | undefined;
16
+ } & React.RefAttributes<import("@react-types/shared").DOMRefValue<HTMLDivElement>>>;
17
+ //# sourceMappingURL=ComboBox.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ComboBox.d.ts","sourceRoot":"","sources":["../../../src/spectrum/comboBox/ComboBox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAEL,qBAAqB,EACtB,MAAM,uBAAuB,CAAC;AAG/B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAkB,MAAM,WAAW,CAAC;AAGzD,MAAM,MAAM,aAAa,GAAG,YAAY,CAAC,qBAAqB,CAAC,cAAc,CAAC,CAAC,CAAC;AAEhF,eAAO,MAAM,QAAQ;;;;;;;;;;mFAgCnB,CAAC"}
@@ -0,0 +1,44 @@
1
+ var _excluded = ["UNSAFE_className"],
2
+ _excluded2 = ["defaultSelectedKey", "disabledKeys", "selectedKey", "ref"];
3
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
4
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
7
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
8
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
9
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
10
+ import React from 'react';
11
+ import { ComboBox as SpectrumComboBox } from '@adobe/react-spectrum';
12
+ import cl from 'classnames';
13
+ import { usePickerProps } from "../picker/index.js";
14
+ import useMultiRef from "../picker/useMultiRef.js";
15
+ import { jsx as _jsx } from "react/jsx-runtime";
16
+ export var ComboBox = /*#__PURE__*/React.forwardRef(function ComboBox(_ref, ref) {
17
+ var {
18
+ UNSAFE_className
19
+ } = _ref,
20
+ props = _objectWithoutProperties(_ref, _excluded);
21
+ var _usePickerProps = usePickerProps(props),
22
+ {
23
+ defaultSelectedKey,
24
+ disabledKeys,
25
+ selectedKey,
26
+ ref: scrollRef
27
+ } = _usePickerProps,
28
+ comboBoxProps = _objectWithoutProperties(_usePickerProps, _excluded2);
29
+ var pickerRef = useMultiRef(ref, scrollRef);
30
+ return /*#__PURE__*/_jsx(SpectrumComboBox
31
+ // eslint-disable-next-line react/jsx-props-no-spreading
32
+ , _objectSpread(_objectSpread({}, comboBoxProps), {}, {
33
+ UNSAFE_className: cl('dh-combobox', UNSAFE_className),
34
+ ref: pickerRef
35
+ // Type assertions are necessary here since Spectrum types don't account
36
+ // for number and boolean key values even though they are valid runtime
37
+ // values.
38
+ ,
39
+ defaultSelectedKey: defaultSelectedKey,
40
+ disabledKeys: disabledKeys,
41
+ selectedKey: selectedKey
42
+ }));
43
+ });
44
+ //# sourceMappingURL=ComboBox.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ComboBox.js","names":["React","ComboBox","SpectrumComboBox","cl","usePickerProps","useMultiRef","jsx","_jsx","forwardRef","_ref","ref","UNSAFE_className","props","_objectWithoutProperties","_excluded","_usePickerProps","defaultSelectedKey","disabledKeys","selectedKey","scrollRef","comboBoxProps","_excluded2","pickerRef","_objectSpread"],"sources":["../../../src/spectrum/comboBox/ComboBox.tsx"],"sourcesContent":["import React from 'react';\nimport {\n ComboBox as SpectrumComboBox,\n SpectrumComboBoxProps,\n} from '@adobe/react-spectrum';\nimport type { DOMRef } from '@react-types/shared';\nimport cl from 'classnames';\nimport type { NormalizedItem } from '../utils';\nimport { PickerPropsT, usePickerProps } from '../picker';\nimport useMultiRef from '../picker/useMultiRef';\n\nexport type ComboBoxProps = PickerPropsT<SpectrumComboBoxProps<NormalizedItem>>;\n\nexport const ComboBox = React.forwardRef(function ComboBox(\n { UNSAFE_className, ...props }: ComboBoxProps,\n ref: DOMRef<HTMLDivElement>\n): JSX.Element {\n const {\n defaultSelectedKey,\n disabledKeys,\n selectedKey,\n ref: scrollRef,\n ...comboBoxProps\n } = usePickerProps(props);\n const pickerRef = useMultiRef(ref, scrollRef);\n return (\n <SpectrumComboBox\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...comboBoxProps}\n UNSAFE_className={cl('dh-combobox', UNSAFE_className)}\n ref={pickerRef}\n // Type assertions are necessary here since Spectrum types don't account\n // for number and boolean key values even though they are valid runtime\n // values.\n defaultSelectedKey={\n defaultSelectedKey as SpectrumComboBoxProps<NormalizedItem>['defaultSelectedKey']\n }\n disabledKeys={\n disabledKeys as SpectrumComboBoxProps<NormalizedItem>['disabledKeys']\n }\n selectedKey={\n selectedKey as SpectrumComboBoxProps<NormalizedItem>['selectedKey']\n }\n />\n );\n});\n"],"mappings":";;;;;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,QAAQ,IAAIC,gBAAgB,QAEvB,uBAAuB;AAE9B,OAAOC,EAAE,MAAM,YAAY;AAAC,SAELC,cAAc;AAAA,OAC9BC,WAAW;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAIlB,OAAO,IAAMN,QAAQ,gBAAGD,KAAK,CAACQ,UAAU,CAAC,SAASP,QAAQA,CAAAQ,IAAA,EAExDC,GAA2B,EACd;EAAA,IAFb;MAAEC;IAA0C,CAAC,GAAAF,IAAA;IAAtBG,KAAK,GAAAC,wBAAA,CAAAJ,IAAA,EAAAK,SAAA;EAG5B,IAAAC,eAAA,GAMIX,cAAc,CAACQ,KAAK,CAAC;IANnB;MACJI,kBAAkB;MAClBC,YAAY;MACZC,WAAW;MACXR,GAAG,EAAES;IAEP,CAAC,GAAAJ,eAAA;IADIK,aAAa,GAAAP,wBAAA,CAAAE,eAAA,EAAAM,UAAA;EAElB,IAAMC,SAAS,GAAGjB,WAAW,CAACK,GAAG,EAAES,SAAS,CAAC;EAC7C,oBACEZ,IAAA,CAACL;EACC;EAAA,EAAAqB,aAAA,CAAAA,aAAA,KACIH,aAAa;IACjBT,gBAAgB,EAAER,EAAE,CAAC,aAAa,EAAEQ,gBAAgB,CAAE;IACtDD,GAAG,EAAEY;IACL;IACA;IACA;IAAA;IACAN,kBAAkB,EAChBA,kBACD;IACDC,YAAY,EACVA,YACD;IACDC,WAAW,EACTA;EACD,EACF,CAAC;AAEN,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ /// <reference types="react" />
2
+ import { PickerNormalizedPropsT } from '../picker';
3
+ import { ComboBoxProps } from './ComboBox';
4
+ export type ComboBoxNormalizedProps = PickerNormalizedPropsT<ComboBoxProps>;
5
+ /**
6
+ * ComboBox that takes an array of `NormalizedItem` or `NormalizedSection` items
7
+ * as children and uses a render item function to render the items. `NormalizedItem`
8
+ * and `NormalizedSection` datums always provide a `key` property but have an
9
+ * optional `item` property that can be lazy loaded. This is necessary to support
10
+ * windowed data since we need a representative key for every item in the
11
+ * collection.
12
+ */
13
+ export declare function ComboBoxNormalized({ UNSAFE_className, ...props }: ComboBoxNormalizedProps): JSX.Element;
14
+ export default ComboBoxNormalized;
15
+ //# sourceMappingURL=ComboBoxNormalized.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ComboBoxNormalized.d.ts","sourceRoot":"","sources":["../../../src/spectrum/comboBox/ComboBoxNormalized.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAE,sBAAsB,EAA4B,MAAM,WAAW,CAAC;AAC7E,OAAO,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE3C,MAAM,MAAM,uBAAuB,GAAG,sBAAsB,CAAC,aAAa,CAAC,CAAC;AAE5E;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,gBAAgB,EAChB,GAAG,KAAK,EACT,EAAE,uBAAuB,GAAG,GAAG,CAAC,OAAO,CAiBvC;AAED,eAAe,kBAAkB,CAAC"}
@@ -0,0 +1,42 @@
1
+ var _excluded = ["UNSAFE_className"],
2
+ _excluded2 = ["forceRerenderKey", "ref"];
3
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
4
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
7
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
8
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
9
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
10
+ import { ComboBox as SpectrumComboBox } from '@adobe/react-spectrum';
11
+ import cl from 'classnames';
12
+ import { usePickerNormalizedProps } from "../picker/index.js";
13
+ import { createElement as _createElement } from "react";
14
+ /**
15
+ * ComboBox that takes an array of `NormalizedItem` or `NormalizedSection` items
16
+ * as children and uses a render item function to render the items. `NormalizedItem`
17
+ * and `NormalizedSection` datums always provide a `key` property but have an
18
+ * optional `item` property that can be lazy loaded. This is necessary to support
19
+ * windowed data since we need a representative key for every item in the
20
+ * collection.
21
+ */
22
+ export function ComboBoxNormalized(_ref) {
23
+ var {
24
+ UNSAFE_className
25
+ } = _ref,
26
+ props = _objectWithoutProperties(_ref, _excluded);
27
+ var _usePickerNormalizedP = usePickerNormalizedProps(props),
28
+ {
29
+ forceRerenderKey,
30
+ ref
31
+ } = _usePickerNormalizedP,
32
+ pickerProps = _objectWithoutProperties(_usePickerNormalizedP, _excluded2);
33
+ return /*#__PURE__*/_createElement(SpectrumComboBox
34
+ // eslint-disable-next-line react/jsx-props-no-spreading
35
+ , _objectSpread(_objectSpread({}, pickerProps), {}, {
36
+ key: forceRerenderKey,
37
+ ref: ref,
38
+ UNSAFE_className: cl('dh-combobox', 'dh-combobox-normalized', UNSAFE_className)
39
+ }));
40
+ }
41
+ export default ComboBoxNormalized;
42
+ //# sourceMappingURL=ComboBoxNormalized.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ComboBoxNormalized.js","names":["ComboBox","SpectrumComboBox","cl","usePickerNormalizedProps","createElement","_createElement","ComboBoxNormalized","_ref","UNSAFE_className","props","_objectWithoutProperties","_excluded","_usePickerNormalizedP","forceRerenderKey","ref","pickerProps","_excluded2","_objectSpread","key"],"sources":["../../../src/spectrum/comboBox/ComboBoxNormalized.tsx"],"sourcesContent":["import { ComboBox as SpectrumComboBox } from '@adobe/react-spectrum';\nimport { FocusableRef } from '@react-types/shared';\nimport cl from 'classnames';\nimport { PickerNormalizedPropsT, usePickerNormalizedProps } from '../picker';\nimport { ComboBoxProps } from './ComboBox';\n\nexport type ComboBoxNormalizedProps = PickerNormalizedPropsT<ComboBoxProps>;\n\n/**\n * ComboBox that takes an array of `NormalizedItem` or `NormalizedSection` items\n * as children and uses a render item function to render the items. `NormalizedItem`\n * and `NormalizedSection` datums always provide a `key` property but have an\n * optional `item` property that can be lazy loaded. This is necessary to support\n * windowed data since we need a representative key for every item in the\n * collection.\n */\nexport function ComboBoxNormalized({\n UNSAFE_className,\n ...props\n}: ComboBoxNormalizedProps): JSX.Element {\n const { forceRerenderKey, ref, ...pickerProps } =\n usePickerNormalizedProps<ComboBoxNormalizedProps>(props);\n\n return (\n <SpectrumComboBox\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...pickerProps}\n key={forceRerenderKey}\n ref={ref as FocusableRef<HTMLElement>}\n UNSAFE_className={cl(\n 'dh-combobox',\n 'dh-combobox-normalized',\n UNSAFE_className\n )}\n />\n );\n}\n\nexport default ComboBoxNormalized;\n"],"mappings":";;;;;;;;;AAAA,SAASA,QAAQ,IAAIC,gBAAgB,QAAQ,uBAAuB;AAEpE,OAAOC,EAAE,MAAM,YAAY;AAAC,SACKC,wBAAwB;AAAA,SAAAC,aAAA,IAAAC,cAAA;AAKzD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,kBAAkBA,CAAAC,IAAA,EAGO;EAAA,IAHN;MACjCC;IAEuB,CAAC,GAAAD,IAAA;IADrBE,KAAK,GAAAC,wBAAA,CAAAH,IAAA,EAAAI,SAAA;EAER,IAAAC,qBAAA,GACET,wBAAwB,CAA0BM,KAAK,CAAC;IADpD;MAAEI,gBAAgB;MAAEC;IAAoB,CAAC,GAAAF,qBAAA;IAAbG,WAAW,GAAAL,wBAAA,CAAAE,qBAAA,EAAAI,UAAA;EAG7C,oBACEX,cAAA,CAACJ;EACC;EAAA,EAAAgB,aAAA,CAAAA,aAAA,KACIF,WAAW;IACfG,GAAG,EAAEL,gBAAiB;IACtBC,GAAG,EAAEA,GAAiC;IACtCN,gBAAgB,EAAEN,EAAE,CAClB,aAAa,EACb,wBAAwB,EACxBM,gBACF;EAAE,EACH,CAAC;AAEN;AAEA,eAAeF,kBAAkB"}
@@ -0,0 +1,3 @@
1
+ export * from './ComboBox';
2
+ export * from './ComboBoxNormalized';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/spectrum/comboBox/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,sBAAsB,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from "./ComboBox.js";
2
+ export * from "./ComboBoxNormalized.js";
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../../src/spectrum/comboBox/index.ts"],"sourcesContent":["export * from './ComboBox';\nexport * from './ComboBoxNormalized';\n"],"mappings":""}
@@ -1,3 +1,4 @@
1
- export { CheckboxGroup, type SpectrumCheckboxGroupProps as CheckboxGroupProps, Form, type SpectrumFormProps as FormProps, NumberField, type SpectrumNumberFieldProps as NumberFieldProps, RangeSlider, type SpectrumRangeSliderProps as RangeSliderProps, Slider, type SpectrumSliderProps as SliderProps, Switch, type SpectrumSwitchProps as SwitchProps, TextArea, TextField, type SpectrumTextFieldProps as TextFieldProps, } from '@adobe/react-spectrum';
1
+ export { Checkbox as SpectrumCheckbox, type SpectrumCheckboxProps, CheckboxGroup, type SpectrumCheckboxGroupProps as CheckboxGroupProps, Form, type SpectrumFormProps as FormProps, NumberField, type SpectrumNumberFieldProps as NumberFieldProps, Radio, RadioGroup, RangeSlider, type SpectrumRangeSliderProps as RangeSliderProps, Slider, type SpectrumSliderProps as SliderProps, Switch, type SpectrumSwitchProps as SwitchProps, TextArea, TextField, type SpectrumTextFieldProps as TextFieldProps, } from '@adobe/react-spectrum';
2
+ export type { SpectrumRadioGroupProps as RadioGroupProps, SpectrumRadioProps as RadioProps, } from '@react-types/radio';
2
3
  export type { SpectrumTextAreaProps as TextAreaProps } from '@react-types/textfield';
3
4
  //# sourceMappingURL=forms.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"forms.d.ts","sourceRoot":"","sources":["../../src/spectrum/forms.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,aAAa,EACb,KAAK,0BAA0B,IAAI,kBAAkB,EACrD,IAAI,EACJ,KAAK,iBAAiB,IAAI,SAAS,EACnC,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,QAAQ,EACR,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,GAC9C,MAAM,uBAAuB,CAAC;AAG/B,YAAY,EAAE,qBAAqB,IAAI,aAAa,EAAE,MAAM,wBAAwB,CAAC"}
1
+ {"version":3,"file":"forms.d.ts","sourceRoot":"","sources":["../../src/spectrum/forms.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,IAAI,gBAAgB,EAC5B,KAAK,qBAAqB,EAC1B,aAAa,EACb,KAAK,0BAA0B,IAAI,kBAAkB,EACrD,IAAI,EACJ,KAAK,iBAAiB,IAAI,SAAS,EACnC,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,KAAK,EACL,UAAU,EACV,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,QAAQ,EACR,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,GAC9C,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EACV,uBAAuB,IAAI,eAAe,EAC1C,kBAAkB,IAAI,UAAU,GACjC,MAAM,oBAAoB,CAAC;AAG5B,YAAY,EAAE,qBAAqB,IAAI,aAAa,EAAE,MAAM,wBAAwB,CAAC"}
@@ -1,4 +1,4 @@
1
- export { CheckboxGroup, Form, NumberField, RangeSlider, Slider, Switch, TextArea, TextField } from '@adobe/react-spectrum';
1
+ export { Checkbox as SpectrumCheckbox, CheckboxGroup, Form, NumberField, Radio, RadioGroup, RangeSlider, Slider, Switch, TextArea, TextField } from '@adobe/react-spectrum';
2
2
 
3
3
  // @react-types/textfield is unecessary if https://github.com/adobe/react-spectrum/pull/6090 merge
4
4
  //# sourceMappingURL=forms.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"forms.js","names":["CheckboxGroup","Form","NumberField","RangeSlider","Slider","Switch","TextArea","TextField"],"sources":["../../src/spectrum/forms.ts"],"sourcesContent":["export {\n CheckboxGroup,\n type SpectrumCheckboxGroupProps as CheckboxGroupProps,\n Form,\n type SpectrumFormProps as FormProps,\n NumberField,\n type SpectrumNumberFieldProps as NumberFieldProps,\n RangeSlider,\n type SpectrumRangeSliderProps as RangeSliderProps,\n Slider,\n type SpectrumSliderProps as SliderProps,\n Switch,\n type SpectrumSwitchProps as SwitchProps,\n TextArea,\n TextField,\n type SpectrumTextFieldProps as TextFieldProps,\n} from '@adobe/react-spectrum';\n\n// @react-types/textfield is unecessary if https://github.com/adobe/react-spectrum/pull/6090 merge\nexport type { SpectrumTextAreaProps as TextAreaProps } from '@react-types/textfield';\n"],"mappings":"AAAA,SACEA,aAAa,EAEbC,IAAI,EAEJC,WAAW,EAEXC,WAAW,EAEXC,MAAM,EAENC,MAAM,EAENC,QAAQ,EACRC,SAAS,QAEJ,uBAAuB;;AAE9B"}
1
+ {"version":3,"file":"forms.js","names":["Checkbox","SpectrumCheckbox","CheckboxGroup","Form","NumberField","Radio","RadioGroup","RangeSlider","Slider","Switch","TextArea","TextField"],"sources":["../../src/spectrum/forms.ts"],"sourcesContent":["export {\n Checkbox as SpectrumCheckbox,\n type SpectrumCheckboxProps,\n CheckboxGroup,\n type SpectrumCheckboxGroupProps as CheckboxGroupProps,\n Form,\n type SpectrumFormProps as FormProps,\n NumberField,\n type SpectrumNumberFieldProps as NumberFieldProps,\n Radio,\n RadioGroup,\n RangeSlider,\n type SpectrumRangeSliderProps as RangeSliderProps,\n Slider,\n type SpectrumSliderProps as SliderProps,\n Switch,\n type SpectrumSwitchProps as SwitchProps,\n TextArea,\n TextField,\n type SpectrumTextFieldProps as TextFieldProps,\n} from '@adobe/react-spectrum';\n\nexport type {\n SpectrumRadioGroupProps as RadioGroupProps,\n SpectrumRadioProps as RadioProps,\n} from '@react-types/radio';\n\n// @react-types/textfield is unecessary if https://github.com/adobe/react-spectrum/pull/6090 merge\nexport type { SpectrumTextAreaProps as TextAreaProps } from '@react-types/textfield';\n"],"mappings":"AAAA,SACEA,QAAQ,IAAIC,gBAAgB,EAE5BC,aAAa,EAEbC,IAAI,EAEJC,WAAW,EAEXC,KAAK,EACLC,UAAU,EACVC,WAAW,EAEXC,MAAM,EAENC,MAAM,EAENC,QAAQ,EACRC,SAAS,QAEJ,uBAAuB;;AAO9B"}
@@ -0,0 +1,2 @@
1
+ export { Icon } from '@adobe/react-spectrum';
2
+ //# sourceMappingURL=icons.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"icons.d.ts","sourceRoot":"","sources":["../../src/spectrum/icons.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC"}
@@ -0,0 +1,3 @@
1
+ // eslint-disable-next-line import/prefer-default-export
2
+ export { Icon } from '@adobe/react-spectrum';
3
+ //# sourceMappingURL=icons.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"icons.js","names":["Icon"],"sources":["../../src/spectrum/icons.ts"],"sourcesContent":["// eslint-disable-next-line import/prefer-default-export\nexport { Icon } from '@adobe/react-spectrum';\n"],"mappings":"AAAA;AACA,SAASA,IAAI,QAAQ,uBAAuB"}
@@ -6,15 +6,21 @@ export * from './collections';
6
6
  export * from './content';
7
7
  export * from './dateAndTime';
8
8
  export * from './forms';
9
+ export * from './icons';
9
10
  export * from './layout';
10
11
  export * from './navigation';
11
12
  export * from './overlays';
12
- export * from './pickers';
13
13
  export * from './shared';
14
14
  export * from './status';
15
15
  /**
16
16
  * Custom DH components wrapping React Spectrum components.
17
17
  */
18
+ export * from './ActionMenu';
19
+ export * from './ActionGroup';
20
+ export * from './comboBox';
21
+ export * from './ListActionGroup';
22
+ export * from './ListActionMenu';
23
+ export * from './listView';
18
24
  export * from './picker';
19
25
  export * from './Heading';
20
26
  export * from './Text';
@@ -22,5 +28,7 @@ export * from './View';
22
28
  /**
23
29
  * Custom DH spectrum utils
24
30
  */
31
+ export * from './ItemContent';
32
+ export * from './ItemTooltip';
25
33
  export * from './utils';
26
34
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/spectrum/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AAEzB;;GAEG;AACH,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AACvB,cAAc,QAAQ,CAAC;AAEvB;;GAEG;AACH,cAAc,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/spectrum/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AAEzB;;GAEG;AACH,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AACvB,cAAc,QAAQ,CAAC;AAEvB;;GAEG;AACH,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC"}
@@ -6,15 +6,21 @@ export * from "./collections.js";
6
6
  export * from "./content.js";
7
7
  export * from "./dateAndTime.js";
8
8
  export * from "./forms.js";
9
+ export * from "./icons.js";
9
10
  export * from "./layout.js";
10
11
  export * from "./navigation.js";
11
12
  export * from "./overlays.js";
12
- export * from "./pickers.js";
13
13
  export * from "./shared.js";
14
14
  export * from "./status.js";
15
15
  /**
16
16
  * Custom DH components wrapping React Spectrum components.
17
17
  */
18
+ export * from "./ActionMenu.js";
19
+ export * from "./ActionGroup.js";
20
+ export * from "./comboBox/index.js";
21
+ export * from "./ListActionGroup.js";
22
+ export * from "./ListActionMenu.js";
23
+ export * from "./listView/index.js";
18
24
  export * from "./picker/index.js";
19
25
  export * from "./Heading.js";
20
26
  export * from "./Text.js";
@@ -22,5 +28,7 @@ export * from "./View.js";
22
28
  /**
23
29
  * Custom DH spectrum utils
24
30
  */
31
+ export * from "./ItemContent.js";
32
+ export * from "./ItemTooltip.js";
25
33
  export * from "./utils/index.js";
26
34
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/spectrum/index.ts"],"sourcesContent":["/**\n * Re-exporting React Spectrum components + props.\n */\nexport * from './buttons';\nexport * from './collections';\nexport * from './content';\nexport * from './dateAndTime';\nexport * from './forms';\nexport * from './layout';\nexport * from './navigation';\nexport * from './overlays';\nexport * from './pickers';\nexport * from './shared';\nexport * from './status';\n\n/**\n * Custom DH components wrapping React Spectrum components.\n */\nexport * from './picker';\nexport * from './Heading';\nexport * from './Text';\nexport * from './View';\n\n/**\n * Custom DH spectrum utils\n */\nexport * from './utils';\n"],"mappings":"AAAA;AACA;AACA;AAFA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAeA;AACA;AACA;AAFA;AAAA;AAAA;AAAA;AAQA;AACA;AACA;AAFA"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/spectrum/index.ts"],"sourcesContent":["/**\n * Re-exporting React Spectrum components + props.\n */\nexport * from './buttons';\nexport * from './collections';\nexport * from './content';\nexport * from './dateAndTime';\nexport * from './forms';\nexport * from './icons';\nexport * from './layout';\nexport * from './navigation';\nexport * from './overlays';\nexport * from './shared';\nexport * from './status';\n\n/**\n * Custom DH components wrapping React Spectrum components.\n */\nexport * from './ActionMenu';\nexport * from './ActionGroup';\nexport * from './comboBox';\nexport * from './ListActionGroup';\nexport * from './ListActionMenu';\nexport * from './listView';\nexport * from './picker';\nexport * from './Heading';\nexport * from './Text';\nexport * from './View';\n\n/**\n * Custom DH spectrum utils\n */\nexport * from './ItemContent';\nexport * from './ItemTooltip';\nexport * from './utils';\n"],"mappings":"AAAA;AACA;AACA;AAFA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAeA;AACA;AACA;AAFA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAcA;AACA;AACA;AAFA;AAAA;AAAA"}
@@ -0,0 +1,14 @@
1
+ /// <reference types="react" />
2
+ import { SpectrumListViewProps } from '@adobe/react-spectrum';
3
+ import { MultipleItemSelectionProps, NormalizedItem, TooltipOptions } from '../utils';
4
+ import { ItemElementOrPrimitive } from '../shared';
5
+ export type ListViewProps = MultipleItemSelectionProps & {
6
+ children: ItemElementOrPrimitive | ItemElementOrPrimitive[];
7
+ /** Can be set to true or a TooltipOptions to enable item tooltips */
8
+ tooltip?: boolean | TooltipOptions;
9
+ /** Handler that is called when the picker is scrolled. */
10
+ onScroll?: (event: Event) => void;
11
+ } & Omit<SpectrumListViewProps<NormalizedItem>, 'children' | 'items' | 'selectedKeys' | 'defaultSelectedKeys' | 'disabledKeys' | 'onSelectionChange'>;
12
+ export declare function ListView({ children, tooltip, selectedKeys, defaultSelectedKeys, disabledKeys, UNSAFE_className, onChange, onScroll, onSelectionChange, ...spectrumListViewProps }: ListViewProps): JSX.Element | null;
13
+ export default ListView;
14
+ //# sourceMappingURL=ListView.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ListView.d.ts","sourceRoot":"","sources":["../../../src/spectrum/listView/ListView.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAG9D,OAAO,EACL,0BAA0B,EAC1B,cAAc,EAEd,cAAc,EAEf,MAAM,UAAU,CAAC;AAElB,OAAO,EAAE,sBAAsB,EAAE,MAAM,WAAW,CAAC;AAEnD,MAAM,MAAM,aAAa,GAAG,0BAA0B,GAAG;IACvD,QAAQ,EAAE,sBAAsB,GAAG,sBAAsB,EAAE,CAAC;IAC5D,qEAAqE;IACrE,OAAO,CAAC,EAAE,OAAO,GAAG,cAAc,CAAC;IAEnC,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;CACnC,GAAG,IAAI,CACJ,qBAAqB,CAAC,cAAc,CAAC,EACnC,UAAU,GACV,OAAO,GACP,cAAc,GACd,qBAAqB,GACrB,cAAc,GACd,mBAAmB,CACtB,CAAC;AAEJ,wBAAgB,QAAQ,CAAC,EACvB,QAAQ,EACR,OAAc,EACd,YAAY,EACZ,mBAAmB,EACnB,YAAY,EACZ,gBAAgB,EAChB,QAAQ,EACR,QAAyB,EACzB,iBAAiB,EACjB,GAAG,qBAAqB,EACzB,EAAE,aAAa,GAAG,GAAG,CAAC,OAAO,GAAG,IAAI,CA+BpC;AAED,eAAe,QAAQ,CAAC"}
@@ -0,0 +1,43 @@
1
+ var _excluded = ["children", "tooltip", "selectedKeys", "defaultSelectedKeys", "disabledKeys", "UNSAFE_className", "onChange", "onScroll", "onSelectionChange"];
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
5
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
6
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
7
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
8
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
9
+ import { useMemo } from 'react';
10
+ import cl from 'classnames';
11
+ import { EMPTY_FUNCTION } from '@deephaven/utils';
12
+ import { normalizeTooltipOptions, wrapItemChildren } from "../utils/index.js";
13
+ import { ListViewWrapper } from "./ListViewWrapper.js";
14
+ import { jsx as _jsx } from "react/jsx-runtime";
15
+ export function ListView(_ref) {
16
+ var {
17
+ children,
18
+ tooltip = true,
19
+ selectedKeys,
20
+ defaultSelectedKeys,
21
+ disabledKeys,
22
+ UNSAFE_className,
23
+ onChange,
24
+ onScroll = EMPTY_FUNCTION,
25
+ onSelectionChange
26
+ } = _ref,
27
+ spectrumListViewProps = _objectWithoutProperties(_ref, _excluded);
28
+ var tooltipOptions = useMemo(() => normalizeTooltipOptions(tooltip, 'bottom'), [tooltip]);
29
+ var wrappedItems = useMemo(() => wrapItemChildren(children, tooltipOptions), [children, tooltipOptions]);
30
+ return /*#__PURE__*/_jsx(ListViewWrapper
31
+ // eslint-disable-next-line react/jsx-props-no-spreading
32
+ , _objectSpread(_objectSpread({}, spectrumListViewProps), {}, {
33
+ UNSAFE_className: cl('dh-list-view', UNSAFE_className),
34
+ selectedKeys: selectedKeys,
35
+ defaultSelectedKeys: defaultSelectedKeys,
36
+ disabledKeys: disabledKeys,
37
+ onScroll: onScroll,
38
+ onSelectionChange: onChange !== null && onChange !== void 0 ? onChange : onSelectionChange,
39
+ children: wrappedItems
40
+ }));
41
+ }
42
+ export default ListView;
43
+ //# sourceMappingURL=ListView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ListView.js","names":["useMemo","cl","EMPTY_FUNCTION","normalizeTooltipOptions","wrapItemChildren","ListViewWrapper","jsx","_jsx","ListView","_ref","children","tooltip","selectedKeys","defaultSelectedKeys","disabledKeys","UNSAFE_className","onChange","onScroll","onSelectionChange","spectrumListViewProps","_objectWithoutProperties","_excluded","tooltipOptions","wrappedItems","_objectSpread"],"sources":["../../../src/spectrum/listView/ListView.tsx"],"sourcesContent":["import { useMemo } from 'react';\nimport { SpectrumListViewProps } from '@adobe/react-spectrum';\nimport cl from 'classnames';\nimport { EMPTY_FUNCTION } from '@deephaven/utils';\nimport {\n MultipleItemSelectionProps,\n NormalizedItem,\n normalizeTooltipOptions,\n TooltipOptions,\n wrapItemChildren,\n} from '../utils';\nimport { ListViewWrapper, ListViewWrapperProps } from './ListViewWrapper';\nimport { ItemElementOrPrimitive } from '../shared';\n\nexport type ListViewProps = MultipleItemSelectionProps & {\n children: ItemElementOrPrimitive | ItemElementOrPrimitive[];\n /** Can be set to true or a TooltipOptions to enable item tooltips */\n tooltip?: boolean | TooltipOptions;\n\n /** Handler that is called when the picker is scrolled. */\n onScroll?: (event: Event) => void;\n} & Omit<\n SpectrumListViewProps<NormalizedItem>,\n | 'children'\n | 'items'\n | 'selectedKeys'\n | 'defaultSelectedKeys'\n | 'disabledKeys'\n | 'onSelectionChange'\n >;\n\nexport function ListView({\n children,\n tooltip = true,\n selectedKeys,\n defaultSelectedKeys,\n disabledKeys,\n UNSAFE_className,\n onChange,\n onScroll = EMPTY_FUNCTION,\n onSelectionChange,\n ...spectrumListViewProps\n}: ListViewProps): JSX.Element | null {\n const tooltipOptions = useMemo(\n () => normalizeTooltipOptions(tooltip, 'bottom'),\n [tooltip]\n );\n\n const wrappedItems = useMemo(\n () => wrapItemChildren(children, tooltipOptions),\n [children, tooltipOptions]\n );\n\n return (\n <ListViewWrapper\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...spectrumListViewProps}\n UNSAFE_className={cl('dh-list-view', UNSAFE_className)}\n selectedKeys={\n selectedKeys as ListViewWrapperProps<unknown>['selectedKeys']\n }\n defaultSelectedKeys={\n defaultSelectedKeys as ListViewWrapperProps<unknown>['defaultSelectedKeys']\n }\n disabledKeys={\n disabledKeys as ListViewWrapperProps<unknown>['disabledKeys']\n }\n onScroll={onScroll}\n onSelectionChange={onChange ?? onSelectionChange}\n >\n {wrappedItems}\n </ListViewWrapper>\n );\n}\n\nexport default ListView;\n"],"mappings":";;;;;;;;AAAA,SAASA,OAAO,QAAQ,OAAO;AAE/B,OAAOC,EAAE,MAAM,YAAY;AAC3B,SAASC,cAAc,QAAQ,kBAAkB;AAAC,SAIhDC,uBAAuB,EAEvBC,gBAAgB;AAAA,SAETC,eAAe;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAoBxB,OAAO,SAASC,QAAQA,CAAAC,IAAA,EAWc;EAAA,IAXb;MACvBC,QAAQ;MACRC,OAAO,GAAG,IAAI;MACdC,YAAY;MACZC,mBAAmB;MACnBC,YAAY;MACZC,gBAAgB;MAChBC,QAAQ;MACRC,QAAQ,GAAGf,cAAc;MACzBgB;IAEa,CAAC,GAAAT,IAAA;IADXU,qBAAqB,GAAAC,wBAAA,CAAAX,IAAA,EAAAY,SAAA;EAExB,IAAMC,cAAc,GAAGtB,OAAO,CAC5B,MAAMG,uBAAuB,CAACQ,OAAO,EAAE,QAAQ,CAAC,EAChD,CAACA,OAAO,CACV,CAAC;EAED,IAAMY,YAAY,GAAGvB,OAAO,CAC1B,MAAMI,gBAAgB,CAACM,QAAQ,EAAEY,cAAc,CAAC,EAChD,CAACZ,QAAQ,EAAEY,cAAc,CAC3B,CAAC;EAED,oBACEf,IAAA,CAACF;EACC;EAAA,EAAAmB,aAAA,CAAAA,aAAA,KACIL,qBAAqB;IACzBJ,gBAAgB,EAAEd,EAAE,CAAC,cAAc,EAAEc,gBAAgB,CAAE;IACvDH,YAAY,EACVA,YACD;IACDC,mBAAmB,EACjBA,mBACD;IACDC,YAAY,EACVA,YACD;IACDG,QAAQ,EAAEA,QAAS;IACnBC,iBAAiB,EAAEF,QAAQ,aAARA,QAAQ,cAARA,QAAQ,GAAIE,iBAAkB;IAAAR,QAAA,EAEhDa;EAAY,EACE,CAAC;AAEtB;AAEA,eAAef,QAAQ"}
@@ -0,0 +1,23 @@
1
+ /// <reference types="react" />
2
+ import { ListActions, NormalizedItem } from '../utils';
3
+ import type { ListViewProps } from './ListView';
4
+ export interface ListViewNormalizedProps extends Omit<ListViewProps, 'children'> {
5
+ normalizedItems: NormalizedItem[];
6
+ showItemIcons: boolean;
7
+ actions?: ListActions<unknown>;
8
+ }
9
+ /**
10
+ * ListView supporting normalized item data. This component mostly exists to
11
+ * decouple some of the logic needed to support table data. Specifically it
12
+ * handles item rendering configurations as well as converting selection keys
13
+ * to / from strings. This makes it easier to test logic in isolation without
14
+ * a dependency on JS apis (e.g. in the Styleguide).
15
+ *
16
+ * Note that This component will usually not be used directly. Instead, it is
17
+ * recommended to use
18
+ * - `@deephaven/components`'s `ListView` for non-table data sources
19
+ * - `@deephaven/jsapi-components`'s `ListView` for table data sources
20
+ */
21
+ export declare function ListViewNormalized({ normalizedItems, tooltip, selectedKeys, defaultSelectedKeys, disabledKeys, showItemIcons, actions, UNSAFE_className, onChange, onSelectionChange, ...props }: ListViewNormalizedProps): JSX.Element;
22
+ export default ListViewNormalized;
23
+ //# sourceMappingURL=ListViewNormalized.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ListViewNormalized.d.ts","sourceRoot":"","sources":["../../../src/spectrum/listView/ListViewNormalized.tsx"],"names":[],"mappings":";AAEA,OAAO,EACL,WAAW,EACX,cAAc,EAIf,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAGhD,MAAM,WAAW,uBACf,SAAQ,IAAI,CAAC,aAAa,EAAE,UAAU,CAAC;IACvC,eAAe,EAAE,cAAc,EAAE,CAAC;IAClC,aAAa,EAAE,OAAO,CAAC;IACvB,OAAO,CAAC,EAAE,WAAW,CAAC,OAAO,CAAC,CAAC;CAChC;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,eAAe,EACf,OAAc,EACd,YAAY,EACZ,mBAAmB,EACnB,YAAY,EACZ,aAAa,EACb,OAAO,EACP,gBAAgB,EAChB,QAAQ,EACR,iBAAiB,EACjB,GAAG,KAAK,EACT,EAAE,uBAAuB,GAAG,GAAG,CAAC,OAAO,CAmDvC;AAED,eAAe,kBAAkB,CAAC"}