@deephaven/components 0.69.2-beta.0 → 0.69.2-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -1
- package/dist/index.js.map +1 -1
- package/dist/spectrum/buttons.d.ts +2 -0
- package/dist/spectrum/buttons.d.ts.map +1 -0
- package/dist/spectrum/buttons.js +2 -0
- package/dist/spectrum/buttons.js.map +1 -0
- package/dist/spectrum/collections.d.ts +2 -0
- package/dist/spectrum/collections.d.ts.map +1 -0
- package/dist/spectrum/collections.js +2 -0
- package/dist/spectrum/collections.js.map +1 -0
- package/dist/spectrum/content.d.ts +2 -0
- package/dist/spectrum/content.d.ts.map +1 -0
- package/dist/spectrum/content.js +2 -0
- package/dist/spectrum/content.js.map +1 -0
- package/dist/spectrum/dateAndTime.d.ts +2 -0
- package/dist/spectrum/dateAndTime.d.ts.map +1 -0
- package/dist/spectrum/dateAndTime.js +2 -0
- package/dist/spectrum/dateAndTime.js.map +1 -0
- package/dist/spectrum/forms.d.ts +3 -0
- package/dist/spectrum/forms.d.ts.map +1 -0
- package/dist/spectrum/forms.js +2 -0
- package/dist/spectrum/forms.js.map +1 -0
- package/dist/spectrum/index.d.ts +17 -3
- package/dist/spectrum/index.d.ts.map +1 -1
- package/dist/spectrum/index.js +17 -3
- package/dist/spectrum/index.js.map +1 -1
- package/dist/spectrum/layout.d.ts +2 -0
- package/dist/spectrum/layout.d.ts.map +1 -0
- package/dist/spectrum/layout.js +2 -0
- package/dist/spectrum/layout.js.map +1 -0
- package/dist/spectrum/navigation.d.ts +2 -0
- package/dist/spectrum/navigation.d.ts.map +1 -0
- package/dist/spectrum/navigation.js +2 -0
- package/dist/spectrum/navigation.js.map +1 -0
- package/dist/spectrum/overlays.d.ts +2 -0
- package/dist/spectrum/overlays.d.ts.map +1 -0
- package/dist/spectrum/overlays.js +2 -0
- package/dist/spectrum/overlays.js.map +1 -0
- package/dist/spectrum/picker/Picker.d.ts.map +1 -1
- package/dist/spectrum/picker/Picker.js +1 -2
- package/dist/spectrum/picker/Picker.js.map +1 -1
- package/dist/spectrum/picker/PickerUtils.d.ts +1 -2
- package/dist/spectrum/picker/PickerUtils.d.ts.map +1 -1
- package/dist/spectrum/picker/PickerUtils.js +1 -2
- package/dist/spectrum/picker/PickerUtils.js.map +1 -1
- package/dist/spectrum/pickers.d.ts +2 -0
- package/dist/spectrum/pickers.d.ts.map +1 -0
- package/dist/spectrum/pickers.js +2 -0
- package/dist/spectrum/pickers.js.map +1 -0
- package/dist/spectrum/shared.d.ts +12 -0
- package/dist/spectrum/shared.d.ts.map +1 -0
- package/dist/spectrum/shared.js +11 -0
- package/dist/spectrum/shared.js.map +1 -0
- package/dist/spectrum/status.d.ts +2 -0
- package/dist/spectrum/status.d.ts.map +1 -0
- package/dist/spectrum/status.js +2 -0
- package/dist/spectrum/status.js.map +1 -0
- package/package.json +8 -7
- package/dist/ValidateLabelInput.css +0 -10
- package/dist/ValidateLabelInput.css.map +0 -1
- package/dist/ValidateLabelInput.d.ts +0 -28
- package/dist/ValidateLabelInput.d.ts.map +0 -1
- package/dist/ValidateLabelInput.js +0 -59
- package/dist/ValidateLabelInput.js.map +0 -1
- package/dist/spectrum/Flex.d.ts +0 -5
- package/dist/spectrum/Flex.d.ts.map +0 -1
- package/dist/spectrum/Flex.js +0 -4
- package/dist/spectrum/Flex.js.map +0 -1
- package/dist/spectrum/Item.d.ts +0 -11
- package/dist/spectrum/Item.d.ts.map +0 -1
- package/dist/spectrum/Item.js +0 -10
- package/dist/spectrum/Item.js.map +0 -1
- package/dist/spectrum/Section.d.ts +0 -11
- package/dist/spectrum/Section.d.ts.map +0 -1
- package/dist/spectrum/Section.js +0 -10
- package/dist/spectrum/Section.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -58,5 +58,4 @@ export { default as TimeInput } from './TimeInput';
|
|
|
58
58
|
export { default as TimeSlider } from './TimeSlider';
|
|
59
59
|
export { default as ToastNotification } from './ToastNotification';
|
|
60
60
|
export { default as UISwitch } from './UISwitch';
|
|
61
|
-
export { default as ValidateLabelInput } from './ValidateLabelInput';
|
|
62
61
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC9C,cAAc,WAAW,CAAC;AAC1B,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,aAAa,CAAC;AACnD,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC;AACjD,cAAc,mBAAmB,CAAC;AAClC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,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OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -57,5 +57,4 @@ export { default as TimeInput } from "./TimeInput.js";
|
|
|
57
57
|
export { default as TimeSlider } from "./TimeSlider.js";
|
|
58
58
|
export { default as ToastNotification } from "./ToastNotification.js";
|
|
59
59
|
export { default as UISwitch } from "./UISwitch.js";
|
|
60
|
-
export { default as ValidateLabelInput } from "./ValidateLabelInput.js";
|
|
61
60
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["default","AutoCompleteInput","AutoResizeTextarea","BasicModal","Button","ButtonGroup","ButtonOld","CardFlip","Collapse","Checkbox","ComboBox","CopyButton","CustomTimeSelect","DateTimeInput","DateInput","DebouncedSearchInput","DraggableItemList","DragUtils","EditableItemList","HierarchicalCheckboxMenu","ItemListItem","LoadingOverlay","LoadingSpinner","DropdownMenu","MaskedInput","Option","RadioGroup","RadioItem","RandomAreaPlotAnimation","Select","SearchInput","SelectValueList","SocketedButton","ThemeExport","TimeInput","TimeSlider","ToastNotification","UISwitch"
|
|
1
|
+
{"version":3,"file":"index.js","names":["default","AutoCompleteInput","AutoResizeTextarea","BasicModal","Button","ButtonGroup","ButtonOld","CardFlip","Collapse","Checkbox","ComboBox","CopyButton","CustomTimeSelect","DateTimeInput","DateInput","DebouncedSearchInput","DraggableItemList","DragUtils","EditableItemList","HierarchicalCheckboxMenu","ItemListItem","LoadingOverlay","LoadingSpinner","DropdownMenu","MaskedInput","Option","RadioGroup","RadioItem","RandomAreaPlotAnimation","Select","SearchInput","SelectValueList","SocketedButton","ThemeExport","TimeInput","TimeSlider","ToastNotification","UISwitch"],"sources":["../src/index.ts"],"sourcesContent":["export type { Range } from '@deephaven/utils';\nexport * from './actions';\nexport { default as AutoCompleteInput } from './AutoCompleteInput';\nexport { default as AutoResizeTextarea } from './AutoResizeTextarea';\nexport { default as BasicModal } from './BasicModal';\nexport { default as Button } from './Button';\nexport { default as ButtonGroup } from './ButtonGroup';\nexport { default as ButtonOld } from './ButtonOld';\nexport * from './BulkActionBar';\nexport { default as CardFlip } from './CardFlip';\nexport * from './context-actions';\nexport { default as Collapse } from './Collapse';\nexport { default as Checkbox } from './Checkbox';\nexport { default as ComboBox } from './ComboBox';\nexport { default as CopyButton } from './CopyButton';\nexport { default as CustomTimeSelect } from './CustomTimeSelect';\nexport { default as DateTimeInput } from './DateTimeInput';\nexport { default as DateInput } from './DateInput';\nexport { default as DebouncedSearchInput } from './DebouncedSearchInput';\nexport * from './dialogs';\nexport { default as DraggableItemList } from './DraggableItemList';\nexport * from './DraggableItemList';\nexport { default as DragUtils } from './DragUtils';\nexport { default as EditableItemList } from './EditableItemList';\nexport * from './ErrorBoundary';\nexport { default as HierarchicalCheckboxMenu } from './HierarchicalCheckboxMenu';\nexport * from './HierarchicalCheckboxMenu';\nexport * from './ItemList';\nexport { default as ItemListItem } from './ItemListItem';\nexport { default as LoadingOverlay } from './LoadingOverlay';\nexport { default as LoadingSpinner } from './LoadingSpinner';\nexport { default as DropdownMenu } from './menu-actions';\nexport * from './menu-actions';\nexport { default as MaskedInput } from './MaskedInput';\nexport * from './MaskedInput';\nexport * from './MaskedInputUtils';\nexport * from './navigation';\nexport { default as Option } from './Option';\nexport * from './popper';\nexport * from './modal';\nexport { default as RadioGroup } from './RadioGroup';\nexport { default as RadioItem } from './RadioItem';\nexport { default as RandomAreaPlotAnimation } from './RandomAreaPlotAnimation';\nexport * from './SearchableCombobox';\nexport { default as Select } from './Select';\nexport { default as SearchInput } from './SearchInput';\nexport { default as SelectValueList } from './SelectValueList';\nexport * from './SelectValueList';\nexport * from './shortcuts';\nexport { default as SocketedButton } from './SocketedButton';\nexport * from './spectrum';\nexport * from './SpectrumUtils';\nexport * from './TableViewEmptyState';\nexport * from './TextWithTooltip';\nexport * from './theme';\nexport { default as ThemeExport } from './ThemeExport';\nexport { default as TimeInput } from './TimeInput';\nexport { default as TimeSlider } from './TimeSlider';\nexport { default as ToastNotification } from './ToastNotification';\nexport { default as UISwitch } from './UISwitch';\n"],"mappings":";SAESA,OAAO,IAAIC,iBAAiB;AAAA,SAC5BD,OAAO,IAAIE,kBAAkB;AAAA,SAC7BF,OAAO,IAAIG,UAAU;AAAA,SACrBH,OAAO,IAAII,MAAM;AAAA,SACjBJ,OAAO,IAAIK,WAAW;AAAA,SACtBL,OAAO,IAAIM,SAAS;AAAA;AAAA,SAEpBN,OAAO,IAAIO,QAAQ;AAAA;AAAA,SAEnBP,OAAO,IAAIQ,QAAQ;AAAA,SACnBR,OAAO,IAAIS,QAAQ;AAAA,SACnBT,OAAO,IAAIU,QAAQ;AAAA,SACnBV,OAAO,IAAIW,UAAU;AAAA,SACrBX,OAAO,IAAIY,gBAAgB;AAAA,SAC3BZ,OAAO,IAAIa,aAAa;AAAA,SACxBb,OAAO,IAAIc,SAAS;AAAA,SACpBd,OAAO,IAAIe,oBAAoB;AAAA;AAAA,SAE/Bf,OAAO,IAAIgB,iBAAiB;AAAA;AAAA,SAE5BhB,OAAO,IAAIiB,SAAS;AAAA,SACpBjB,OAAO,IAAIkB,gBAAgB;AAAA;AAAA,SAE3BlB,OAAO,IAAImB,wBAAwB;AAAA;AAAA;AAAA,SAGnCnB,OAAO,IAAIoB,YAAY;AAAA,SACvBpB,OAAO,IAAIqB,cAAc;AAAA,SACzBrB,OAAO,IAAIsB,cAAc;AAAA,SACzBtB,OAAO,IAAIuB,YAAY;AAAA;AAAA,SAEvBvB,OAAO,IAAIwB,WAAW;AAAA;AAAA;AAAA;AAAA,SAItBxB,OAAO,IAAIyB,MAAM;AAAA;AAAA;AAAA,SAGjBzB,OAAO,IAAI0B,UAAU;AAAA,SACrB1B,OAAO,IAAI2B,SAAS;AAAA,SACpB3B,OAAO,IAAI4B,uBAAuB;AAAA;AAAA,SAElC5B,OAAO,IAAI6B,MAAM;AAAA,SACjB7B,OAAO,IAAI8B,WAAW;AAAA,SACtB9B,OAAO,IAAI+B,eAAe;AAAA;AAAA;AAAA,SAG1B/B,OAAO,IAAIgC,cAAc;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SAMzBhC,OAAO,IAAIiC,WAAW;AAAA,SACtBjC,OAAO,IAAIkC,SAAS;AAAA,SACpBlC,OAAO,IAAImC,UAAU;AAAA,SACrBnC,OAAO,IAAIoC,iBAAiB;AAAA,SAC5BpC,OAAO,IAAIqC,QAAQ"}
|
|
@@ -0,0 +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';
|
|
2
|
+
//# sourceMappingURL=buttons.d.ts.map
|
|
@@ -0,0 +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"}
|
|
@@ -0,0 +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"}
|
|
@@ -0,0 +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';
|
|
2
|
+
//# sourceMappingURL=collections.d.ts.map
|
|
@@ -0,0 +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"}
|
|
@@ -0,0 +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"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { Avatar, type SpectrumAvatarProps as AvatarProps, Content, type ContentProps, Divider, type SpectrumDividerProps as DividerProps, Footer, type FooterProps, Heading, type HeadingProps, IllustratedMessage, type SpectrumIllustratedMessageProps as IllustratedMessageProps, Image, type SpectrumImageProps as ImageProps, Keyboard, type KeyboardProps, Text, type TextProps, View, type ViewProps, Well, type SpectrumWellProps as WellProps, } from '@adobe/react-spectrum';
|
|
2
|
+
//# sourceMappingURL=content.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content.d.ts","sourceRoot":"","sources":["../../src/spectrum/content.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,OAAO,EACP,KAAK,YAAY,EACjB,OAAO,EACP,KAAK,oBAAoB,IAAI,YAAY,EACzC,MAAM,EACN,KAAK,WAAW,EAChB,OAAO,EACP,KAAK,YAAY,EACjB,kBAAkB,EAClB,KAAK,+BAA+B,IAAI,uBAAuB,EAC/D,KAAK,EACL,KAAK,kBAAkB,IAAI,UAAU,EACrC,QAAQ,EACR,KAAK,aAAa,EAClB,IAAI,EACJ,KAAK,SAAS,EACd,IAAI,EACJ,KAAK,SAAS,EACd,IAAI,EACJ,KAAK,iBAAiB,IAAI,SAAS,GACpC,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content.js","names":["Avatar","Content","Divider","Footer","Heading","IllustratedMessage","Image","Keyboard","Text","View","Well"],"sources":["../../src/spectrum/content.ts"],"sourcesContent":["export {\n Avatar,\n type SpectrumAvatarProps as AvatarProps,\n Content,\n type ContentProps,\n Divider,\n type SpectrumDividerProps as DividerProps,\n Footer,\n type FooterProps,\n Heading,\n type HeadingProps,\n IllustratedMessage,\n type SpectrumIllustratedMessageProps as IllustratedMessageProps,\n Image,\n type SpectrumImageProps as ImageProps,\n Keyboard,\n type KeyboardProps,\n Text,\n type TextProps,\n View,\n type ViewProps,\n Well,\n type SpectrumWellProps as WellProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,MAAM,EAENC,OAAO,EAEPC,OAAO,EAEPC,MAAM,EAENC,OAAO,EAEPC,kBAAkB,EAElBC,KAAK,EAELC,QAAQ,EAERC,IAAI,EAEJC,IAAI,EAEJC,IAAI,QAEC,uBAAuB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { Calendar, type SpectrumCalendarProps as CalendarProps, DateField, type SpectrumDateFieldProps as DateFieldProps, DatePicker, type SpectrumDatePickerProps as DatePickerProps, DateRangePicker, type SpectrumDateRangePickerProps as DateRangePickerProps, RangeCalendar, type SpectrumRangeCalendarProps as RangeCalendarProps, TimeField, type SpectrumTimeFieldProps as TimeFieldProps, } from '@adobe/react-spectrum';
|
|
2
|
+
//# sourceMappingURL=dateAndTime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dateAndTime.d.ts","sourceRoot":"","sources":["../../src/spectrum/dateAndTime.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,KAAK,qBAAqB,IAAI,aAAa,EAC3C,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,EAC7C,UAAU,EACV,KAAK,uBAAuB,IAAI,eAAe,EAC/C,eAAe,EACf,KAAK,4BAA4B,IAAI,oBAAoB,EACzD,aAAa,EACb,KAAK,0BAA0B,IAAI,kBAAkB,EACrD,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,GAC9C,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dateAndTime.js","names":["Calendar","DateField","DatePicker","DateRangePicker","RangeCalendar","TimeField"],"sources":["../../src/spectrum/dateAndTime.ts"],"sourcesContent":["export {\n Calendar,\n type SpectrumCalendarProps as CalendarProps,\n DateField,\n type SpectrumDateFieldProps as DateFieldProps,\n DatePicker,\n type SpectrumDatePickerProps as DatePickerProps,\n DateRangePicker,\n type SpectrumDateRangePickerProps as DateRangePickerProps,\n RangeCalendar,\n type SpectrumRangeCalendarProps as RangeCalendarProps,\n TimeField,\n type SpectrumTimeFieldProps as TimeFieldProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,QAAQ,EAERC,SAAS,EAETC,UAAU,EAEVC,eAAe,EAEfC,aAAa,EAEbC,SAAS,QAEJ,uBAAuB"}
|
|
@@ -0,0 +1,3 @@
|
|
|
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';
|
|
2
|
+
export { type SpectrumTextAreaProps as TextAreaProps } from '@react-types/textfield';
|
|
3
|
+
//# sourceMappingURL=forms.d.ts.map
|
|
@@ -0,0 +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;AAE/B,OAAO,EAAE,KAAK,qBAAqB,IAAI,aAAa,EAAE,MAAM,wBAAwB,CAAC"}
|
|
@@ -0,0 +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\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"}
|
package/dist/spectrum/index.d.ts
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Re-exporting React Spectrum components + props.
|
|
3
|
+
*/
|
|
4
|
+
export * from './buttons';
|
|
5
|
+
export * from './collections';
|
|
6
|
+
export * from './content';
|
|
7
|
+
export * from './dateAndTime';
|
|
8
|
+
export * from './forms';
|
|
9
|
+
export * from './layout';
|
|
10
|
+
export * from './navigation';
|
|
11
|
+
export * from './overlays';
|
|
12
|
+
export * from './pickers';
|
|
13
|
+
export * from './shared';
|
|
14
|
+
export * from './status';
|
|
15
|
+
/**
|
|
16
|
+
* Custom DH components wrapping React Spectrum components.
|
|
17
|
+
*/
|
|
3
18
|
export * from './picker';
|
|
4
|
-
export * from './Section';
|
|
5
19
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/spectrum/index.ts"],"names":[],"mappings":"AAAA,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,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"}
|
package/dist/spectrum/index.js
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Re-exporting React Spectrum components + props.
|
|
3
|
+
*/
|
|
4
|
+
export * from "./buttons.js";
|
|
5
|
+
export * from "./collections.js";
|
|
6
|
+
export * from "./content.js";
|
|
7
|
+
export * from "./dateAndTime.js";
|
|
8
|
+
export * from "./forms.js";
|
|
9
|
+
export * from "./layout.js";
|
|
10
|
+
export * from "./navigation.js";
|
|
11
|
+
export * from "./overlays.js";
|
|
12
|
+
export * from "./pickers.js";
|
|
13
|
+
export * from "./shared.js";
|
|
14
|
+
export * from "./status.js";
|
|
15
|
+
/**
|
|
16
|
+
* Custom DH components wrapping React Spectrum components.
|
|
17
|
+
*/
|
|
3
18
|
export * from "./picker/index.js";
|
|
4
|
-
export * from "./Section.js";
|
|
5
19
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../src/spectrum/index.ts"],"sourcesContent":["
|
|
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';\n"],"mappings":"AAAA;AACA;AACA;AAFA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAeA;AACA;AACA;AAFA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../src/spectrum/layout.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EACJ,KAAK,SAAS,EACd,IAAI,EACJ,KAAK,SAAS,GACf,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layout.js","names":["Flex","Grid"],"sources":["../../src/spectrum/layout.ts"],"sourcesContent":["export {\n Flex,\n type FlexProps,\n Grid,\n type GridProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,IAAI,EAEJC,IAAI,QAEC,uBAAuB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { Breadcrumbs, type SpectrumBreadcrumbsProps as BreadcrumbsProps, Link, type SpectrumLinkProps as LinkProps, TabList, type SpectrumTabListProps as TabListProps, TabPanels, type SpectrumTabPanelsProps as TabPanelsProps, Tabs, type SpectrumTabsProps as TabsProps, } from '@adobe/react-spectrum';
|
|
2
|
+
//# sourceMappingURL=navigation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../src/spectrum/navigation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,IAAI,EACJ,KAAK,iBAAiB,IAAI,SAAS,EACnC,OAAO,EACP,KAAK,oBAAoB,IAAI,YAAY,EACzC,SAAS,EACT,KAAK,sBAAsB,IAAI,cAAc,EAC7C,IAAI,EACJ,KAAK,iBAAiB,IAAI,SAAS,GACpC,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigation.js","names":["Breadcrumbs","Link","TabList","TabPanels","Tabs"],"sources":["../../src/spectrum/navigation.ts"],"sourcesContent":["export {\n Breadcrumbs,\n type SpectrumBreadcrumbsProps as BreadcrumbsProps,\n Link,\n type SpectrumLinkProps as LinkProps,\n TabList,\n type SpectrumTabListProps as TabListProps,\n TabPanels,\n type SpectrumTabPanelsProps as TabPanelsProps,\n Tabs,\n type SpectrumTabsProps as TabsProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,WAAW,EAEXC,IAAI,EAEJC,OAAO,EAEPC,SAAS,EAETC,IAAI,QAEC,uBAAuB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { AlertDialog, type SpectrumAlertDialogProps as AlertDialogProps, ContextualHelp, type SpectrumContextualHelpProps as ContextualHelpProps, Dialog, type SpectrumDialogProps as DialogProps, DialogContainer, type SpectrumDialogContainerProps as DialogContainerProps, DialogTrigger, type SpectrumDialogTriggerProps as DialogTriggerProps, } from '@adobe/react-spectrum';
|
|
2
|
+
//# sourceMappingURL=overlays.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overlays.d.ts","sourceRoot":"","sources":["../../src/spectrum/overlays.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,cAAc,EACd,KAAK,2BAA2B,IAAI,mBAAmB,EACvD,MAAM,EACN,KAAK,mBAAmB,IAAI,WAAW,EACvC,eAAe,EACf,KAAK,4BAA4B,IAAI,oBAAoB,EACzD,aAAa,EACb,KAAK,0BAA0B,IAAI,kBAAkB,GACtD,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overlays.js","names":["AlertDialog","ContextualHelp","Dialog","DialogContainer","DialogTrigger"],"sources":["../../src/spectrum/overlays.ts"],"sourcesContent":["export {\n AlertDialog,\n type SpectrumAlertDialogProps as AlertDialogProps,\n ContextualHelp,\n type SpectrumContextualHelpProps as ContextualHelpProps,\n Dialog,\n type SpectrumDialogProps as DialogProps,\n DialogContainer,\n type SpectrumDialogContainerProps as DialogContainerProps,\n DialogTrigger,\n type SpectrumDialogTriggerProps as DialogTriggerProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,WAAW,EAEXC,cAAc,EAEdC,MAAM,EAENC,eAAe,EAEfC,aAAa,QAER,uBAAuB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Picker.d.ts","sourceRoot":"","sources":["../../../src/spectrum/picker/Picker.tsx"],"names":[],"mappings":";AAKA,OAAO,EACL,6BAA6B,EAG7B,mBAAmB,EACnB,aAAa,EACb,cAAc,EAGf,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"Picker.d.ts","sourceRoot":"","sources":["../../../src/spectrum/picker/Picker.tsx"],"names":[],"mappings":";AAKA,OAAO,EACL,6BAA6B,EAG7B,mBAAmB,EACnB,aAAa,EACb,cAAc,EAGf,MAAM,eAAe,CAAC;AAIvB,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,EAAE,mBAAmB,GAAG,mBAAmB,EAAE,CAAC;IACtD,qEAAqE;IACrE,OAAO,CAAC,EAAE,OAAO,GAAG,cAAc,CAAC;IACnC,iEAAiE;IACjE,WAAW,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;IACnC,iEAAiE;IACjE,kBAAkB,CAAC,EAAE,aAAa,CAAC;IACnC;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,aAAa,KAAK,IAAI,CAAC;IACxC;;;OAGG;IACH,iBAAiB,CAAC,EAAE,CAAC,GAAG,EAAE,aAAa,KAAK,IAAI,CAAC;CAClD,GAKK,IAAI,CACR,6BAA6B,EAC3B,UAAU,GACV,OAAO,GACP,mBAAmB,GACnB,aAAa,GACb,oBAAoB,CACvB,CAAC;AAsBF;;;;;;GAMG;AACH,wBAAgB,MAAM,CAAC,EACrB,QAAQ,EACR,OAAc,EACd,kBAAkB,EAClB,WAAW,EACX,QAAQ,EACR,iBAAiB,EAEjB,gBAAgB,EAChB,GAAG,mBAAmB,EACvB,EAAE,WAAW,GAAG,GAAG,CAAC,OAAO,CAoE3B;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -13,8 +13,7 @@ import cl from 'classnames';
|
|
|
13
13
|
import { Tooltip } from "../../popper/index.js";
|
|
14
14
|
import { normalizePickerItemList, normalizeTooltipOptions, isNormalizedPickerSection } from "./PickerUtils.js";
|
|
15
15
|
import { PickerItemContent } from "./PickerItemContent.js";
|
|
16
|
-
import { Item } from "../
|
|
17
|
-
import { Section } from "../Section.js";
|
|
16
|
+
import { Item, Section } from "../shared.js";
|
|
18
17
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
19
18
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
20
19
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Picker.js","names":["useCallback","useMemo","Flex","Picker","SpectrumPicker","Text","isElementOfType","cl","Tooltip","normalizePickerItemList","normalizeTooltipOptions","isNormalizedPickerSection","PickerItemContent","Item","Section","jsx","_jsx","jsxs","_jsxs","createTooltipContent","content","String","Array","isArray","direction","alignItems","children","filter","node","_ref","tooltip","defaultSelectedKey","selectedKey","onChange","onSelectionChange","UNSAFE_className","spectrumPickerProps","_objectWithoutProperties","_excluded","normalizedItems","tooltipOptions","renderItem","_ref2","key","textValue","options","_objectSpread","items","itemOrSection","title"],"sources":["../../../src/spectrum/picker/Picker.tsx"],"sourcesContent":["import { Key, ReactNode, useCallback, useMemo } from 'react';\nimport { Flex, Picker as SpectrumPicker, Text } from '@adobe/react-spectrum';\nimport { isElementOfType } from '@deephaven/react-hooks';\nimport cl from 'classnames';\nimport { Tooltip } from '../../popper';\nimport {\n NormalizedSpectrumPickerProps,\n normalizePickerItemList,\n normalizeTooltipOptions,\n PickerItemOrSection,\n PickerItemKey,\n TooltipOptions,\n NormalizedPickerItem,\n isNormalizedPickerSection,\n} from './PickerUtils';\nimport { PickerItemContent } from './PickerItemContent';\nimport { Item
|
|
1
|
+
{"version":3,"file":"Picker.js","names":["useCallback","useMemo","Flex","Picker","SpectrumPicker","Text","isElementOfType","cl","Tooltip","normalizePickerItemList","normalizeTooltipOptions","isNormalizedPickerSection","PickerItemContent","Item","Section","jsx","_jsx","jsxs","_jsxs","createTooltipContent","content","String","Array","isArray","direction","alignItems","children","filter","node","_ref","tooltip","defaultSelectedKey","selectedKey","onChange","onSelectionChange","UNSAFE_className","spectrumPickerProps","_objectWithoutProperties","_excluded","normalizedItems","tooltipOptions","renderItem","_ref2","key","textValue","options","_objectSpread","items","itemOrSection","title"],"sources":["../../../src/spectrum/picker/Picker.tsx"],"sourcesContent":["import { Key, ReactNode, useCallback, useMemo } from 'react';\nimport { Flex, Picker as SpectrumPicker, Text } from '@adobe/react-spectrum';\nimport { isElementOfType } from '@deephaven/react-hooks';\nimport cl from 'classnames';\nimport { Tooltip } from '../../popper';\nimport {\n NormalizedSpectrumPickerProps,\n normalizePickerItemList,\n normalizeTooltipOptions,\n PickerItemOrSection,\n PickerItemKey,\n TooltipOptions,\n NormalizedPickerItem,\n isNormalizedPickerSection,\n} from './PickerUtils';\nimport { PickerItemContent } from './PickerItemContent';\nimport { Item, Section } from '../shared';\n\nexport type PickerProps = {\n children: PickerItemOrSection | PickerItemOrSection[];\n /** Can be set to true or a TooltipOptions to enable item tooltips */\n tooltip?: boolean | TooltipOptions;\n /** The currently selected key in the collection (controlled). */\n selectedKey?: PickerItemKey | null;\n /** The initial selected key in the collection (uncontrolled). */\n defaultSelectedKey?: PickerItemKey;\n /**\n * Handler that is called when the selection change.\n * Note that under the hood, this is just an alias for Spectrum's\n * `onSelectionChange`. We are renaming for better consistency with other\n * components.\n */\n onChange?: (key: PickerItemKey) => void;\n /**\n * Handler that is called when the selection changes.\n * @deprecated Use `onChange` instead\n */\n onSelectionChange?: (key: PickerItemKey) => void;\n} /*\n * Support remaining SpectrumPickerProps.\n * Note that `selectedKey`, `defaultSelectedKey`, and `onSelectionChange` are\n * re-defined above to account for boolean types which aren't included in the\n * React `Key` type, but are actually supported by the Spectrum Picker component.\n */ & Omit<\n NormalizedSpectrumPickerProps,\n | 'children'\n | 'items'\n | 'onSelectionChange'\n | 'selectedKey'\n | 'defaultSelectedKey'\n>;\n\n/**\n * Create tooltip content optionally wrapping with a Flex column for array\n * content. This is needed for Items containing description `Text` elements.\n */\nfunction createTooltipContent(content: ReactNode) {\n if (typeof content === 'boolean') {\n return String(content);\n }\n\n if (Array.isArray(content)) {\n return (\n <Flex direction=\"column\" alignItems=\"start\">\n {content.filter(node => isElementOfType(node, Text))}\n </Flex>\n );\n }\n\n return content;\n}\n\n/**\n * Picker component for selecting items from a list of items. Items can be\n * provided via the `items` prop or as children. Each item can be a string,\n * number, boolean, or a Spectrum <Item> element. The remaining props are just\n * pass through props for the Spectrum Picker component.\n * See https://react-spectrum.adobe.com/react-spectrum/Picker.html\n */\nexport function Picker({\n children,\n tooltip = true,\n defaultSelectedKey,\n selectedKey,\n onChange,\n onSelectionChange,\n // eslint-disable-next-line camelcase\n UNSAFE_className,\n ...spectrumPickerProps\n}: PickerProps): JSX.Element {\n const normalizedItems = useMemo(\n () => normalizePickerItemList(children),\n [children]\n );\n\n const tooltipOptions = useMemo(\n () => normalizeTooltipOptions(tooltip),\n [tooltip]\n );\n\n const renderItem = useCallback(\n ({ key, content, textValue }: NormalizedPickerItem) => (\n // The `textValue` prop gets used to provide the content of `<option>`\n // elements that back the Spectrum Picker. These are not visible in the UI,\n // but are used for accessibility purposes, so we set to an arbitrary\n // 'Empty' value so that they are not empty strings.\n <Item\n key={key as Key}\n textValue={textValue === '' || textValue == null ? 'Empty' : textValue}\n >\n <PickerItemContent>{content}</PickerItemContent>\n {tooltipOptions == null || content === '' ? null : (\n <Tooltip options={tooltipOptions}>\n {createTooltipContent(content)}\n </Tooltip>\n )}\n </Item>\n ),\n [tooltipOptions]\n );\n\n return (\n <SpectrumPicker\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...spectrumPickerProps}\n UNSAFE_className={cl('dh-picker', UNSAFE_className)}\n items={normalizedItems}\n // Type assertions are necessary for `selectedKey`, `defaultSelectedKey`,\n // and `onSelectionChange` due to Spectrum types not accounting for\n // `boolean` keys\n selectedKey={selectedKey as NormalizedSpectrumPickerProps['selectedKey']}\n defaultSelectedKey={\n defaultSelectedKey as NormalizedSpectrumPickerProps['defaultSelectedKey']\n }\n // `onChange` is just an alias for `onSelectionChange`\n onSelectionChange={\n (onChange ??\n onSelectionChange) as NormalizedSpectrumPickerProps['onSelectionChange']\n }\n >\n {itemOrSection => {\n if (isNormalizedPickerSection(itemOrSection)) {\n return (\n <Section\n key={itemOrSection.key}\n title={itemOrSection.title}\n items={itemOrSection.items}\n >\n {renderItem}\n </Section>\n );\n }\n\n return renderItem(itemOrSection);\n }}\n </SpectrumPicker>\n );\n}\n\nexport default Picker;\n"],"mappings":";;;;;;;;AAAA,SAAyBA,WAAW,EAAEC,OAAO,QAAQ,OAAO;AAC5D,SAASC,IAAI,EAAEC,MAAM,IAAIC,cAAc,EAAEC,IAAI,QAAQ,uBAAuB;AAC5E,SAASC,eAAe,QAAQ,wBAAwB;AACxD,OAAOC,EAAE,MAAM,YAAY;AAAC,SACnBC,OAAO;AAAA,SAGdC,uBAAuB,EACvBC,uBAAuB,EAKvBC,yBAAyB;AAAA,SAElBC,iBAAiB;AAAA,SACjBC,IAAI,EAAEC,OAAO;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAoCtB;AACA;AACA;AACA;AACA,SAASC,oBAAoBA,CAACC,OAAkB,EAAE;EAChD,IAAI,OAAOA,OAAO,KAAK,SAAS,EAAE;IAChC,OAAOC,MAAM,CAACD,OAAO,CAAC;EACxB;EAEA,IAAIE,KAAK,CAACC,OAAO,CAACH,OAAO,CAA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oBAAoB,CAACC,OAAO;QAAC,CACvB,CACV;MAAA,GARIuB,GASD;IAAC;EAAA,CACR,EACD,CAACH,cAAc,CACjB,CAAC;EAED,oBACExB,IAAA,CAACZ;EACC;EAAA,EAAA0C,aAAA,CAAAA,aAAA,KACIV,mBAAmB;IACvBD,gBAAgB,EAAE5B,EAAE,CAAC,WAAW,EAAE4B,gBAAgB,CAAE;IACpDY,KAAK,EAAER;IACP;IACA;IACA;IAAA;IACAP,WAAW,EAAEA,WAA4D;IACzED,kBAAkB,EAChBA;IAEF;IAAA;IACAG,iBAAiB,EACdD,QAAQ,aAARA,QAAQ,cAARA,QAAQ,GACPC,iBACH;IAAAR,QAAA,EAEAsB,aAAa,IAAI;MAChB,IAAIrC,yBAAyB,CAACqC,aAAa,CAAC,EAAE;QAC5C,oBACEhC,IAAA,CAACF,OAAO;UAENmC,KAAK,EAAED,aAAa,CAACC,KAAM;UAC3BF,KAAK,EAAEC,aAAa,CAACD,KAAM;UAAArB,QAAA,EAE1Be;QAAU,GAJNO,aAAa,CAACL,GAKZ,CAAC;MAEd;MAEA,OAAOF,UAAU,CAACO,aAAa,CAAC;IAClC;EAAC,EACa,CAAC;AAErB;AAEA,eAAe7C,MAAM"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Key, ReactElement, ReactNode } from 'react';
|
|
2
2
|
import { SpectrumPickerProps } from '@adobe/react-spectrum';
|
|
3
3
|
import type { ItemRenderer } from '@react-types/shared';
|
|
4
|
-
import { ItemProps } from '../
|
|
5
|
-
import { SectionProps } from '../Section';
|
|
4
|
+
import { ItemProps, SectionProps } from '../shared';
|
|
6
5
|
import { PopperOptions } from '../../popper';
|
|
7
6
|
export declare const INVALID_PICKER_ITEM_ERROR_MESSAGE = "Picker items must be strings, numbers, booleans, <Item> or <Section> elements:";
|
|
8
7
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PickerUtils.d.ts","sourceRoot":"","sources":["../../../src/spectrum/picker/Pick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,CAKpD;AAED;;;;GAIG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,CAAC,EAAE,OAAO,GAAG,cAAc,GAAG,IAAI,GACxC,cAAc,GAAG,IAAI,CAUvB"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { isValidElement } from 'react';
|
|
2
2
|
import Log from '@deephaven/log';
|
|
3
|
-
import { Item } from "../
|
|
4
|
-
import { Section } from "../Section.js";
|
|
3
|
+
import { Item, Section } from "../shared.js";
|
|
5
4
|
var log = Log.module('PickerUtils');
|
|
6
5
|
export var INVALID_PICKER_ITEM_ERROR_MESSAGE = 'Picker items must be strings, numbers, booleans, <Item> or <Section> elements:';
|
|
7
6
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PickerUtils.js","names":["isValidElement","Log","Item","Section","log","module","INVALID_PICKER_ITEM_ERROR_MESSAGE","isSectionElement","node","type","isItemElement","isPickerItemOrSection","isNormalizedPickerSection","maybeNormalizedPickerSection","normalizeItemKey","itemOrSection","_itemOrSection$props$","key","props","title","undefined","textValue","children","normalizeTextValue","item","String","normalizePickerItem","debug","Error","items","normalizePickerItemList","filter","childItem","content","itemsOrSections","itemsArray","Array","isArray","map","normalizeTooltipOptions","options","placement"],"sources":["../../../src/spectrum/picker/PickerUtils.ts"],"sourcesContent":["import { isValidElement, Key, ReactElement, ReactNode } from 'react';\nimport { SpectrumPickerProps } from '@adobe/react-spectrum';\nimport type { ItemRenderer } from '@react-types/shared';\nimport Log from '@deephaven/log';\nimport { Item, ItemProps } from '../Item';\nimport { Section, SectionProps } from '../Section';\nimport { PopperOptions } from '../../popper';\n\nconst log = Log.module('PickerUtils');\n\nexport const INVALID_PICKER_ITEM_ERROR_MESSAGE =\n 'Picker items must be strings, numbers, booleans, <Item> or <Section> elements:';\n\n/**\n * React Spectrum <Section> supports an `ItemRenderer` function as a child. The\n * DH picker makes use of this internally, but we don't want to support it as\n * an incoming prop.\n */\ntype SectionPropsNoItemRenderer<T> = Omit<SectionProps<T>, 'children'> & {\n children: Exclude<SectionProps<T>['children'], ItemRenderer<T>>;\n};\n\ntype ItemElement = ReactElement<ItemProps<unknown>>;\ntype SectionElement = ReactElement<SectionPropsNoItemRenderer<unknown>>;\n\nexport type PickerItem = number | string | boolean | ItemElement;\nexport type PickerSection = SectionElement;\nexport type PickerItemOrSection = PickerItem | PickerSection;\n\n/**\n * Augment the Spectrum selection key type to include boolean values.\n * The Spectrum Picker already supports this, but the built in types don't\n * reflect it.\n */\nexport type PickerItemKey = Key | boolean;\n\n/**\n * Augment the Spectrum selection change handler type to include boolean keys.\n * The Spectrum Picker already supports this, but the built in types don't\n * reflect it.\n */\nexport type PickerSelectionChangeHandler = (key: PickerItemKey) => void;\n\n/**\n * The Picker supports a variety of item types, including strings, numbers,\n * booleans, and more complex React elements. This type represents a normalized\n * form to make rendering items simpler and keep the logic of transformation\n * in separate util methods.\n */\nexport interface NormalizedPickerItem {\n key?: PickerItemKey;\n content: ReactNode;\n textValue?: string;\n}\n\nexport interface NormalizedPickerSection {\n key?: Key;\n title?: ReactNode;\n items: NormalizedPickerItem[];\n}\n\nexport type NormalizedSpectrumPickerProps =\n SpectrumPickerProps<NormalizedPickerItem>;\n\nexport type TooltipOptions = { placement: PopperOptions['placement'] };\n\n/**\n * Determine if a node is a Section element.\n * @param node The node to check\n * @returns True if the node is a Section element\n */\nexport function isSectionElement<T>(\n node: ReactNode\n): node is ReactElement<SectionProps<T>> {\n return isValidElement<SectionProps<T>>(node) && node.type === Section;\n}\n\n/**\n * Determine if a node is an Item element.\n * @param node The node to check\n * @returns True if the node is an Item element\n */\nexport function isItemElement<T>(\n node: ReactNode\n): node is ReactElement<ItemProps<T>> {\n return isValidElement<ItemProps<T>>(node) && node.type === Item;\n}\n\n/**\n * Determine if a node is a Picker item or section. Valid types include strings,\n * numbers, booleans, Item elements, and Section elements.\n * @param node The node to check\n * @returns True if the node is a Picker item or section\n */\nexport function isPickerItemOrSection(\n node: ReactNode\n): node is PickerItemOrSection {\n return (\n typeof node === 'string' ||\n typeof node === 'number' ||\n typeof node === 'boolean' ||\n isItemElement(node) ||\n isSectionElement(node)\n );\n}\n\n/**\n * Determine if an object is a normalized Picker section.\n * @param maybeNormalizedPickerSection The object to check\n * @returns True if the object is a normalized Picker section\n */\nexport function isNormalizedPickerSection(\n maybeNormalizedPickerSection: NormalizedPickerItem | NormalizedPickerSection\n): maybeNormalizedPickerSection is NormalizedPickerSection {\n return 'items' in maybeNormalizedPickerSection;\n}\n\n/**\n * Determine the `key` of a picker item or section.\n * @param itemOrSection The picker item or section\n * @returns A `PickerItemKey` for the picker item or undefined if a key can't be determined\n */\nfunction normalizeItemKey(item: PickerItem): PickerItemKey | undefined;\nfunction normalizeItemKey(section: PickerSection): Key | undefined;\nfunction normalizeItemKey(\n itemOrSection: PickerItem | PickerSection\n): Key | PickerItemKey | undefined {\n // string, number, or boolean\n if (typeof itemOrSection !== 'object') {\n return itemOrSection;\n }\n\n // If `key` prop is explicitly set\n if (itemOrSection.key != null) {\n return itemOrSection.key;\n }\n\n // Section element\n if (isSectionElement(itemOrSection)) {\n return typeof itemOrSection.props.title === 'string'\n ? itemOrSection.props.title\n : undefined;\n }\n\n // Item element\n return (\n itemOrSection.props.textValue ??\n (typeof itemOrSection.props.children === 'string'\n ? itemOrSection.props.children\n : undefined)\n );\n}\n\n/**\n * Get a normalized `textValue` for a picker item ensuring it is a string.\n * @param item The picker item\n * @returns A string `textValue` for the picker item\n */\nfunction normalizeTextValue(item: PickerItem): string | undefined {\n if (typeof item !== 'object') {\n return String(item);\n }\n\n if (item.props.textValue != null) {\n return item.props.textValue;\n }\n\n if (typeof item.props.children === 'string') {\n return item.props.children;\n }\n\n return undefined;\n}\n\n/**\n * Normalize a picker item to an object form.\n * @param itemOrSection item to normalize\n * @returns NormalizedPickerItem object\n */\nfunction normalizePickerItem(\n itemOrSection: PickerItemOrSection\n): NormalizedPickerItem | NormalizedPickerSection {\n if (!isPickerItemOrSection(itemOrSection)) {\n log.debug(INVALID_PICKER_ITEM_ERROR_MESSAGE, itemOrSection);\n throw new Error(INVALID_PICKER_ITEM_ERROR_MESSAGE);\n }\n\n if (isSectionElement(itemOrSection)) {\n const key = normalizeItemKey(itemOrSection);\n const { title } = itemOrSection.props;\n\n const items = normalizePickerItemList(itemOrSection.props.children).filter(\n // We don't support nested section elements\n childItem => !isSectionElement(childItem)\n ) as NormalizedPickerItem[];\n\n return {\n key,\n title,\n items,\n };\n }\n\n const key = normalizeItemKey(itemOrSection);\n const content = isItemElement(itemOrSection)\n ? itemOrSection.props.children\n : itemOrSection;\n const textValue = normalizeTextValue(itemOrSection);\n\n return {\n key,\n content,\n textValue,\n };\n}\n\n/**\n * Get normalized picker items from a picker item or array of picker items.\n * @param itemsOrSections A picker item or array of picker items\n * @returns An array of normalized picker items\n */\nexport function normalizePickerItemList(\n itemsOrSections: PickerItemOrSection | PickerItemOrSection[]\n): (NormalizedPickerItem | NormalizedPickerSection)[] {\n const itemsArray = Array.isArray(itemsOrSections)\n ? itemsOrSections\n : [itemsOrSections];\n return itemsArray.map(normalizePickerItem);\n}\n\n/**\n * Returns a TooltipOptions object or null if options is false or null.\n * @param options\n * @returns TooltipOptions or null\n */\nexport function normalizeTooltipOptions(\n options?: boolean | TooltipOptions | null\n): TooltipOptions | null {\n if (options == null || options === false) {\n return null;\n }\n\n if (options === true) {\n return { placement: 'right' };\n }\n\n return options;\n}\n"],"mappings":"AAAA,SAASA,cAAc,QAAsC,OAAO;AAGpE,OAAOC,GAAG,MAAM,gBAAgB;AAAC,SACxBC,IAAI;AAAA,SACJC,OAAO;AAGhB,IAAMC,GAAG,GAAGH,GAAG,CAACI,MAAM,CAAC,aAAa,CAAC;AAErC,OAAO,IAAMC,iCAAiC,GAC5C,gFAAgF;;AAElF;AACA;AACA;AACA;AACA;;AAYA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;;AAkBA;AACA;AACA;AACA;AACA;AAC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AACG,KAAK,CAACI,QAAQ,GAC5BP,aAAa;EACjB,IAAMM,SAAS,GAAGE,kBAAkB,CAACR,aAAa,CAAC;EAEnD,OAAO;IACLE,GAAG;IACHgB,OAAO;IACPZ;EACF,CAAC;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASS,uBAAuBA,CACrCI,eAA4D,EACR;EACpD,IAAMC,UAAU,GAAGC,KAAK,CAACC,OAAO,CAACH,eAAe,CAAC,GAC7CA,eAAe,GACf,CAACA,eAAe,CAAC;EACrB,OAAOC,UAAU,CAACG,GAAG,CAACZ,mBAAmB,CAAC;AAC5C;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASa,uBAAuBA,CACrCC,OAAyC,EAClB;EACvB,IAAIA,OAAO,IAAI,IAAI,IAAIA,OAAO,KAAK,KAAK,EAAE;IACxC,OAAO,IAAI;EACb;EAEA,IAAIA,OAAO,KAAK,IAAI,EAAE;IACpB,OAAO;MAAEC,SAAS,EAAE;IAAQ,CAAC;EAC/B;EAEA,OAAOD,OAAO;AAChB"}
|
|
1
|
+
{"version":3,"file":"PickerUtils.js","names":["isValidElement","Log","Item","Section","log","module","INVALID_PICKER_ITEM_ERROR_MESSAGE","isSectionElement","node","type","isItemElement","isPickerItemOrSection","isNormalizedPickerSection","maybeNormalizedPickerSection","normalizeItemKey","itemOrSection","_itemOrSection$props$","key","props","title","undefined","textValue","children","normalizeTextValue","item","String","normalizePickerItem","debug","Error","items","normalizePickerItemList","filter","childItem","content","itemsOrSections","itemsArray","Array","isArray","map","normalizeTooltipOptions","options","placement"],"sources":["../../../src/spectrum/picker/PickerUtils.ts"],"sourcesContent":["import { isValidElement, Key, ReactElement, ReactNode } from 'react';\nimport { SpectrumPickerProps } from '@adobe/react-spectrum';\nimport type { ItemRenderer } from '@react-types/shared';\nimport Log from '@deephaven/log';\nimport { Item, ItemProps, Section, SectionProps } from '../shared';\nimport { PopperOptions } from '../../popper';\n\nconst log = Log.module('PickerUtils');\n\nexport const INVALID_PICKER_ITEM_ERROR_MESSAGE =\n 'Picker items must be strings, numbers, booleans, <Item> or <Section> elements:';\n\n/**\n * React Spectrum <Section> supports an `ItemRenderer` function as a child. The\n * DH picker makes use of this internally, but we don't want to support it as\n * an incoming prop.\n */\ntype SectionPropsNoItemRenderer<T> = Omit<SectionProps<T>, 'children'> & {\n children: Exclude<SectionProps<T>['children'], ItemRenderer<T>>;\n};\n\ntype ItemElement = ReactElement<ItemProps<unknown>>;\ntype SectionElement = ReactElement<SectionPropsNoItemRenderer<unknown>>;\n\nexport type PickerItem = number | string | boolean | ItemElement;\nexport type PickerSection = SectionElement;\nexport type PickerItemOrSection = PickerItem | PickerSection;\n\n/**\n * Augment the Spectrum selection key type to include boolean values.\n * The Spectrum Picker already supports this, but the built in types don't\n * reflect it.\n */\nexport type PickerItemKey = Key | boolean;\n\n/**\n * Augment the Spectrum selection change handler type to include boolean keys.\n * The Spectrum Picker already supports this, but the built in types don't\n * reflect it.\n */\nexport type PickerSelectionChangeHandler = (key: PickerItemKey) => void;\n\n/**\n * The Picker supports a variety of item types, including strings, numbers,\n * booleans, and more complex React elements. This type represents a normalized\n * form to make rendering items simpler and keep the logic of transformation\n * in separate util methods.\n */\nexport interface NormalizedPickerItem {\n key?: PickerItemKey;\n content: ReactNode;\n textValue?: string;\n}\n\nexport interface NormalizedPickerSection {\n key?: Key;\n title?: ReactNode;\n items: NormalizedPickerItem[];\n}\n\nexport type NormalizedSpectrumPickerProps =\n SpectrumPickerProps<NormalizedPickerItem>;\n\nexport type TooltipOptions = { placement: PopperOptions['placement'] };\n\n/**\n * Determine if a node is a Section element.\n * @param node The node to check\n * @returns True if the node is a Section element\n */\nexport function isSectionElement<T>(\n node: ReactNode\n): node is ReactElement<SectionProps<T>> {\n return isValidElement<SectionProps<T>>(node) && node.type === Section;\n}\n\n/**\n * Determine if a node is an Item element.\n * @param node The node to check\n * @returns True if the node is an Item element\n */\nexport function isItemElement<T>(\n node: ReactNode\n): node is ReactElement<ItemProps<T>> {\n return isValidElement<ItemProps<T>>(node) && node.type === Item;\n}\n\n/**\n * Determine if a node is a Picker item or section. Valid types include strings,\n * numbers, booleans, Item elements, and Section elements.\n * @param node The node to check\n * @returns True if the node is a Picker item or section\n */\nexport function isPickerItemOrSection(\n node: ReactNode\n): node is PickerItemOrSection {\n return (\n typeof node === 'string' ||\n typeof node === 'number' ||\n typeof node === 'boolean' ||\n isItemElement(node) ||\n isSectionElement(node)\n );\n}\n\n/**\n * Determine if an object is a normalized Picker section.\n * @param maybeNormalizedPickerSection The object to check\n * @returns True if the object is a normalized Picker section\n */\nexport function isNormalizedPickerSection(\n maybeNormalizedPickerSection: NormalizedPickerItem | NormalizedPickerSection\n): maybeNormalizedPickerSection is NormalizedPickerSection {\n return 'items' in maybeNormalizedPickerSection;\n}\n\n/**\n * Determine the `key` of a picker item or section.\n * @param itemOrSection The picker item or section\n * @returns A `PickerItemKey` for the picker item or undefined if a key can't be determined\n */\nfunction normalizeItemKey(item: PickerItem): PickerItemKey | undefined;\nfunction normalizeItemKey(section: PickerSection): Key | undefined;\nfunction normalizeItemKey(\n itemOrSection: PickerItem | PickerSection\n): Key | PickerItemKey | undefined {\n // string, number, or boolean\n if (typeof itemOrSection !== 'object') {\n return itemOrSection;\n }\n\n // If `key` prop is explicitly set\n if (itemOrSection.key != null) {\n return itemOrSection.key;\n }\n\n // Section element\n if (isSectionElement(itemOrSection)) {\n return typeof itemOrSection.props.title === 'string'\n ? itemOrSection.props.title\n : undefined;\n }\n\n // Item element\n return (\n itemOrSection.props.textValue ??\n (typeof itemOrSection.props.children === 'string'\n ? itemOrSection.props.children\n : undefined)\n );\n}\n\n/**\n * Get a normalized `textValue` for a picker item ensuring it is a string.\n * @param item The picker item\n * @returns A string `textValue` for the picker item\n */\nfunction normalizeTextValue(item: PickerItem): string | undefined {\n if (typeof item !== 'object') {\n return String(item);\n }\n\n if (item.props.textValue != null) {\n return item.props.textValue;\n }\n\n if (typeof item.props.children === 'string') {\n return item.props.children;\n }\n\n return undefined;\n}\n\n/**\n * Normalize a picker item to an object form.\n * @param itemOrSection item to normalize\n * @returns NormalizedPickerItem object\n */\nfunction normalizePickerItem(\n itemOrSection: PickerItemOrSection\n): NormalizedPickerItem | NormalizedPickerSection {\n if (!isPickerItemOrSection(itemOrSection)) {\n log.debug(INVALID_PICKER_ITEM_ERROR_MESSAGE, itemOrSection);\n throw new Error(INVALID_PICKER_ITEM_ERROR_MESSAGE);\n }\n\n if (isSectionElement(itemOrSection)) {\n const key = normalizeItemKey(itemOrSection);\n const { title } = itemOrSection.props;\n\n const items = normalizePickerItemList(itemOrSection.props.children).filter(\n // We don't support nested section elements\n childItem => !isSectionElement(childItem)\n ) as NormalizedPickerItem[];\n\n return {\n key,\n title,\n items,\n };\n }\n\n const key = normalizeItemKey(itemOrSection);\n const content = isItemElement(itemOrSection)\n ? itemOrSection.props.children\n : itemOrSection;\n const textValue = normalizeTextValue(itemOrSection);\n\n return {\n key,\n content,\n textValue,\n };\n}\n\n/**\n * Get normalized picker items from a picker item or array of picker items.\n * @param itemsOrSections A picker item or array of picker items\n * @returns An array of normalized picker items\n */\nexport function normalizePickerItemList(\n itemsOrSections: PickerItemOrSection | PickerItemOrSection[]\n): (NormalizedPickerItem | NormalizedPickerSection)[] {\n const itemsArray = Array.isArray(itemsOrSections)\n ? itemsOrSections\n : [itemsOrSections];\n return itemsArray.map(normalizePickerItem);\n}\n\n/**\n * Returns a TooltipOptions object or null if options is false or null.\n * @param options\n * @returns TooltipOptions or null\n */\nexport function normalizeTooltipOptions(\n options?: boolean | TooltipOptions | null\n): TooltipOptions | null {\n if (options == null || options === false) {\n return null;\n }\n\n if (options === true) {\n return { placement: 'right' };\n }\n\n return options;\n}\n"],"mappings":"AAAA,SAASA,cAAc,QAAsC,OAAO;AAGpE,OAAOC,GAAG,MAAM,gBAAgB;AAAC,SACxBC,IAAI,EAAaC,OAAO;AAGjC,IAAMC,GAAG,GAAGH,GAAG,CAACI,MAAM,CAAC,aAAa,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B,OAAO;MACLf,GAAG,EAAHA,IAAG;MACHE,KAAK;MACLU;IACF,CAAC;EACH;EAEA,IAAMZ,GAAG,GAAGH,gBAAgB,CAACC,aAAa,CAAC;EAC3C,IAAMkB,OAAO,GAAGvB,aAAa,CAACK,aAAa,CAAC,GACxCA,aAAa,CAACG,KAAK,CAACI,QAAQ,GAC5BP,aAAa;EACjB,IAAMM,SAAS,GAAGE,kBAAkB,CAACR,aAAa,CAAC;EAEnD,OAAO;IACLE,GAAG;IACHgB,OAAO;IACPZ;EACF,CAAC;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASS,uBAAuBA,CACrCI,eAA4D,EACR;EACpD,IAAMC,UAAU,GAAGC,KAAK,CAACC,OAAO,CAACH,eAAe,CAAC,GAC7CA,eAAe,GACf,CAACA,eAAe,CAAC;EACrB,OAAOC,UAAU,CAACG,GAAG,CAACZ,mBAAmB,CAAC;AAC5C;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASa,uBAAuBA,CACrCC,OAAyC,EAClB;EACvB,IAAIA,OAAO,IAAI,IAAI,IAAIA,OAAO,KAAK,KAAK,EAAE;IACxC,OAAO,IAAI;EACb;EAEA,IAAIA,OAAO,KAAK,IAAI,EAAE;IACpB,OAAO;MAAEC,SAAS,EAAE;IAAQ,CAAC;EAC/B;EAEA,OAAOD,OAAO;AAChB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pickers.d.ts","sourceRoot":"","sources":["../../src/spectrum/pickers.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,KAAK,qBAAqB,IAAI,aAAa,GAC5C,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pickers.js","names":["ComboBox"],"sources":["../../src/spectrum/pickers.ts"],"sourcesContent":["export {\n ComboBox,\n type SpectrumComboBoxProps as ComboBoxProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,QAAQ,QAEH,uBAAuB"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wrapping Spectrum `Item` and `Section` components will break functionality
|
|
3
|
+
* due to the way they are consumed by collection components. They are only used
|
|
4
|
+
* to pass data and don't render anything on their own, so they don't need to be
|
|
5
|
+
* wrapped. If we do ever need to wrap them for whatever reason, the static
|
|
6
|
+
* `getCollectionNode` method will need to be implemented.
|
|
7
|
+
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17
|
|
8
|
+
* https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18
|
|
9
|
+
*/
|
|
10
|
+
export { Item, Section } from '@adobe/react-spectrum';
|
|
11
|
+
export type { ItemProps, SectionProps } from '@react-types/shared';
|
|
12
|
+
//# sourceMappingURL=shared.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/spectrum/shared.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AACtD,YAAY,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wrapping Spectrum `Item` and `Section` components will break functionality
|
|
3
|
+
* due to the way they are consumed by collection components. They are only used
|
|
4
|
+
* to pass data and don't render anything on their own, so they don't need to be
|
|
5
|
+
* wrapped. If we do ever need to wrap them for whatever reason, the static
|
|
6
|
+
* `getCollectionNode` method will need to be implemented.
|
|
7
|
+
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17
|
|
8
|
+
* https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18
|
|
9
|
+
*/
|
|
10
|
+
export { Item, Section } from '@adobe/react-spectrum';
|
|
11
|
+
//# sourceMappingURL=shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.js","names":["Item","Section"],"sources":["../../src/spectrum/shared.ts"],"sourcesContent":["/**\n * Wrapping Spectrum `Item` and `Section` components will break functionality\n * due to the way they are consumed by collection components. They are only used\n * to pass data and don't render anything on their own, so they don't need to be\n * wrapped. If we do ever need to wrap them for whatever reason, the static\n * `getCollectionNode` method will need to be implemented.\n * See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17\n * https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18\n */\nexport { Item, Section } from '@adobe/react-spectrum';\nexport type { ItemProps, SectionProps } from '@react-types/shared';\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,IAAI,EAAEC,OAAO,QAAQ,uBAAuB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { Badge, type SpectrumBadgeProps as BadgeProps, InlineAlert, type SpectrumInlineAlertProps as InlineAlertProps, LabeledValue, type SpectrumLabeledValueProps as LabeledValueProps, Meter, type SpectrumMeterProps as MeterProps, ProgressBar, type SpectrumProgressBarProps as ProgressBarProps, ProgressCircle, type SpectrumProgressCircleProps as ProgressCircleProps, StatusLight, type SpectrumStatusLightProps as StatusLightProps, } from '@adobe/react-spectrum';
|
|
2
|
+
//# sourceMappingURL=status.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../../src/spectrum/status.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,EACL,KAAK,kBAAkB,IAAI,UAAU,EACrC,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,YAAY,EACZ,KAAK,yBAAyB,IAAI,iBAAiB,EACnD,KAAK,EACL,KAAK,kBAAkB,IAAI,UAAU,EACrC,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,EACjD,cAAc,EACd,KAAK,2BAA2B,IAAI,mBAAmB,EACvD,WAAW,EACX,KAAK,wBAAwB,IAAI,gBAAgB,GAClD,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.js","names":["Badge","InlineAlert","LabeledValue","Meter","ProgressBar","ProgressCircle","StatusLight"],"sources":["../../src/spectrum/status.ts"],"sourcesContent":["export {\n Badge,\n type SpectrumBadgeProps as BadgeProps,\n InlineAlert,\n type SpectrumInlineAlertProps as InlineAlertProps,\n LabeledValue,\n type SpectrumLabeledValueProps as LabeledValueProps,\n Meter,\n type SpectrumMeterProps as MeterProps,\n ProgressBar,\n type SpectrumProgressBarProps as ProgressBarProps,\n ProgressCircle,\n type SpectrumProgressCircleProps as ProgressCircleProps,\n StatusLight,\n type SpectrumStatusLightProps as StatusLightProps,\n} from '@adobe/react-spectrum';\n"],"mappings":"AAAA,SACEA,KAAK,EAELC,WAAW,EAEXC,YAAY,EAEZC,KAAK,EAELC,WAAW,EAEXC,cAAc,EAEdC,WAAW,QAEN,uBAAuB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deephaven/components",
|
|
3
|
-
"version": "0.69.2-beta.
|
|
3
|
+
"version": "0.69.2-beta.2+5d6ebe92",
|
|
4
4
|
"description": "Deephaven React component library",
|
|
5
5
|
"author": "Deephaven Data Labs LLC",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -25,14 +25,15 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@adobe/react-spectrum": "^3.34.1",
|
|
28
|
-
"@deephaven/icons": "^0.69.2-beta.
|
|
29
|
-
"@deephaven/log": "^0.69.2-beta.
|
|
30
|
-
"@deephaven/react-hooks": "^0.69.2-beta.
|
|
31
|
-
"@deephaven/utils": "^0.69.2-beta.
|
|
28
|
+
"@deephaven/icons": "^0.69.2-beta.2+5d6ebe92",
|
|
29
|
+
"@deephaven/log": "^0.69.2-beta.2+5d6ebe92",
|
|
30
|
+
"@deephaven/react-hooks": "^0.69.2-beta.2+5d6ebe92",
|
|
31
|
+
"@deephaven/utils": "^0.69.2-beta.2+5d6ebe92",
|
|
32
32
|
"@fortawesome/fontawesome-svg-core": "^6.2.1",
|
|
33
33
|
"@fortawesome/react-fontawesome": "^0.2.0",
|
|
34
34
|
"@react-spectrum/theme-default": "^3.5.1",
|
|
35
35
|
"@react-types/shared": "^3.22.1",
|
|
36
|
+
"@react-types/textfield": "^3.9.1",
|
|
36
37
|
"bootstrap": "4.6.2",
|
|
37
38
|
"classnames": "^2.3.1",
|
|
38
39
|
"event-target-shim": "^6.0.2",
|
|
@@ -53,7 +54,7 @@
|
|
|
53
54
|
"react-dom": ">=16.8.0"
|
|
54
55
|
},
|
|
55
56
|
"devDependencies": {
|
|
56
|
-
"@deephaven/mocks": "^0.69.2-beta.
|
|
57
|
+
"@deephaven/mocks": "^0.69.2-beta.2+5d6ebe92"
|
|
57
58
|
},
|
|
58
59
|
"files": [
|
|
59
60
|
"dist",
|
|
@@ -67,5 +68,5 @@
|
|
|
67
68
|
"publishConfig": {
|
|
68
69
|
"access": "public"
|
|
69
70
|
},
|
|
70
|
-
"gitHead": "
|
|
71
|
+
"gitHead": "5d6ebe92d91f39c1a2343721f5a4f53a6e02f3a5"
|
|
71
72
|
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/* stylelint-disable scss/at-import-no-partial-leading-underscore */
|
|
2
|
-
/* stylelint-disable-next-line number-max-precision */
|
|
3
|
-
.validate-label {
|
|
4
|
-
padding-right: 0.5rem;
|
|
5
|
-
}
|
|
6
|
-
.validate-label.modified {
|
|
7
|
-
color: var(--dh-color-modified);
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
/*# sourceMappingURL=ValidateLabelInput.css.map */
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":["../scss/custom.scss","../scss/bootstrap_overrides.scss","../src/ValidateLabelInput.scss"],"names":[],"mappings":"AAAA;AC6LA;ACzLA;EACE;;AACA;EACE,OALO","file":"ValidateLabelInput.css","sourcesContent":["/* stylelint-disable scss/at-import-no-partial-leading-underscore */\n// Consumers should be able to resolve bootstrap/ to node_modules/bootstrap\n\n//Make bootstrap functions available for use in overrides\n@import 'bootstrap/scss/_functions.scss';\n@import './bootstrap_overrides.scss';\n\n//_variable imports come after bootstrap default overrides,\n// makes all other variables and mixins from bootstrap available\n/// with just importing customer.scss\n@import 'bootstrap/scss/_variables.scss';\n@import 'bootstrap/scss/_mixins.scss';\n\n//New variables come after imports\n@import './new_variables.scss';\n@import './util.scss';\n","// Styling overrides for bootstrap\n@use 'sass:map';\n\n// Override / set color variables\n$red: var(--dh-color-visual-red);\n$orange: var(--dh-color-visual-orange);\n$yellow: var(--dh-color-visual-yellow);\n$green: var(--dh-color-visual-green);\n$blue: var(--dh-color-visual-blue);\n$purple: var(--dh-color-visual-purple);\n\n// Fallback colors are used if theme isn't loaded\n// this is required for error messages if the API doesn't load\n\n//Define our Gray scale\n$gray-100: var(--dh-color-gray-900, #fcfcfa);\n$gray-200: var(--dh-color-gray-800);\n$gray-300: var(--dh-color-gray-700);\n$gray-400: var(--dh-color-gray-600);\n$gray-500: var(--dh-color-gray-500);\n// intentional duplicate, scale doesn't line up otherwise\n// as we have gray-850 and spectrum doesn't and it is needed\n$gray-600: var(--dh-color-gray-500);\n$gray-700: var(--dh-color-gray-400);\n$gray-800: var(--dh-color-gray-300);\n$gray-850: var(--dh-color-gray-200);\n$gray-900: var(--dh-color-gray-75);\n$black: var(--dh-color-black, #1a171a);\n$white: var(--dh-color-white, #f0f0ee);\n\n//Define some UI colors\n$interfacegray: var(--dh-color-content-bg, #2d2a2e);\n$interfaceblue: var(--dh-color-accent-bg);\n$interfacewhite: $white;\n$interfaceblack: $black;\n$content-bg: var(--dh-color-content-bg, #2d2a2e);\n$background: var(--dh-color-bg, #1a171a);\n$foreground: var(--dh-color-fg, #f0f0ee);\n\n// Extend default Bootstrap $grays map\n$grays-custom: (\n '850': $gray-850,\n);\n$grays: () !default;\n$grays: map-merge($grays, $grays-custom);\n\n// Extend default Bootstrap $colors map\n$colors-custom: (\n 'black': $black,\n);\n$colors: () !default;\n$colors: map-merge($colors, $colors-custom);\n\n// Override default Bootstrap $theme-colors map by mapping each key to itself.\n// These will then be re-mapped inside of `button-outline-variant` and\n// `button-outline-variant` mixins in `bootstrap_override_mixins_buttons.scss`\n$theme-colors-self-map: ();\n@each $key\n in (\n 'primary',\n 'secondary',\n 'success',\n 'info',\n 'warning',\n 'danger',\n 'light',\n 'dark'\n )\n{\n $theme-colors-self-map: map.set($theme-colors-self-map, $key, $key);\n}\n$theme-colors: () !default;\n$theme-colors: map-merge($theme-colors, $theme-colors-self-map);\n\n// Used by bootstrap_override_mixins_buttons.scss to map Bootstrap colors to\n// DH semantic colors\n$bootstrap-dh-semantic-map: (\n 'primary': 'accent',\n 'secondary': 'neutral',\n 'success': 'positive',\n 'info': 'info',\n 'warning': 'notice',\n 'danger': 'negative',\n // We shouldn't be using these, but mapping so they work with our custom\n // `color-yiq` mixin. If we find a way to remove $light + $dark that are\n // defined in Bootstrap _variables.scss, we should remove these\n 'light': 'neutral',\n 'dark': 'neutral',\n);\n\n//Set default colors\n$body-bg: $black;\n$body-color: $interfacewhite;\n\n// Set brand colors\n$primary: var(--dh-color-accent-bg);\n$primary-hover: var(--dh-color-accent-hover-bg);\n$primary-dark: var(--dh-color-accent-down-bg);\n$secondary: var(--dh-color-neutral-bg);\n$secondary-hover: var(--dh-color-neutral-hover-bg);\n$success: $green;\n$info: $yellow;\n$warning: $orange;\n$danger: var(--dh-color-negative-bg);\n$danger-hover: var(--dh-color-negative-hover-bg);\n// We really don't want to use $light or $dark variables, but Bootstrap defines\n// them in _variables.scss. Explicitly setting them to ensure we are in control\n// of their values. If we can find a way to remove them, we should\n$light: var(--dh-color-gray-light);\n$dark: var(--dh-color-gray-dark);\n// Bootstrap doesn't define $mid, and we want to move away from this particular\n// semantic. Should be deleted by #1635\n$mid: var(--dh-color-gray-mid);\n\n$semantic-colors: (\n 'primary-hover': $primary-hover,\n 'primary-dark': $primary-dark,\n 'mid': $mid,\n 'content-bg': $interfacegray,\n 'background': $interfaceblack,\n 'foreground': $interfacewhite,\n 'secondary-hover': $secondary-hover,\n 'danger-hover': $danger-hover,\n);\n\n$component-active-bg: $primary;\n$theme-color-interval: 9%;\n$yiq-contrasted-threshold: 180;\n\n// Override fonts\n$font-family-sans-serif:\n 'Fira Sans',\n -apple-system,\n blinkmacsystemfont,\n 'Segoe UI',\n 'Roboto',\n 'Helvetica Neue',\n arial,\n sans-serif; //fira sans then native system ui fallbacks\n$font-family-monospace: 'Fira Mono', menlo, monaco, consolas, 'Liberation Mono',\n 'Courier New', monospace;\n$font-family-base: $font-family-sans-serif;\n\n$headings-font-weight: 400;\n\n//Text overides\n$text-muted: $gray-400;\n\n//Style Selection highlight color\n$text-select-color: var(--dh-color-text-highlight);\n\n//Grid variables, same value as default just making easily accessible\n$grid-gutter-width: 30px;\n\n//Visual Overrides\n$border-radius: 4px;\n$box-shadow: 0 0.1rem 1rem var(--dh-color-dropshadow);\n\n//Override Btn\n$btn-border-radius: 4rem;\n$btn-padding-x: 1.5rem;\n$btn-transition:\n color 0.12s ease-in-out,\n background-color 0.12s ease-in-out,\n border-color 0.12s ease-in-out,\n box-shadow 0.12s ease-in-out; //default 0.15 is too long\n$btn-border-width: 2px;\n$btn-font-weight: var(--spectrum-global-font-weight-bold);\n$btn-line-height: 1.3;\n\n//Override Inputs\n$input-bg: var(--dh-color-input-bg);\n$input-disabled-bg: var(--dh-color-input-disabled-bg);\n$input-color: var(--dh-color-input-fg);\n$input-border-color: var(--dh-color-input-border);\n$input-placeholder-color: var(--dh-color-input-placeholder);\n$input-focus-border-color: var(--dh-color-input-focus-border);\n\n$input-btn-focus-width: 0.2rem;\n$input-btn-focus-color: color-mix(\n in srgb,\n var(--dh-color-accent) 35%,\n transparent\n);\n$input-btn-focus-box-shadow: 0 0 0 $input-btn-focus-width $input-btn-focus-color;\n$input-btn-line-height: 1.3;\n// Bootstrap uses a calc expression to determine the input height (calc(line-height + 2*padding-y + border)).\n// The padding-y value has to be in rem to match units as it is a SASS calc.\n// Using 0.42145rem with 1.3 line height gets us to spectrum's 32px.\n/* stylelint-disable-next-line number-max-precision */\n$input-btn-padding-y: 0.42145rem;\n\n//checkbox\n$custom-control-indicator-bg: var(--dh-color-input-bg);\n$custom-control-indicator-border-color: var(--dh-color-input-border);\n$custom-checkbox-indicator-border-radius: 2px;\n$custom-control-indicator-border-width: 2px;\n$custom-control-indicator-active-bg: var(--dh-color-input-bg);\n$custom-control-indicator-active-border-color: var(--dh-color-input-fg);\n$custom-control-indicator-checked-bg: var(--dh-color-input-fg);\n$custom-control-indicator-checked-color: black; // used as mask fill color\n$custom-checkbox-indicator-indeterminate-bg: var(--dh-color-input-fg);\n$custom-control-indicator-bg-size: 75% 75%;\n$custom-control-indicator-disabled-bg: var(--dh-color-input-disabled-bg);\n$custom-control-indicator-checked-disabled-bg: var(\n --dh-color-input-disabled-bg\n);\n$custom-control-label-disabled-color: var(--dh-color-input-disabled-fg);\n\n// The $custom-select-indicator variable is used by Bootstrap to provide the\n// icon for the select dropdown. Inline svgs can't use CSS variables, so we hard\n// code the color to #929192 (the default value of --dh-color-gray-600). PR #1651\n// overrides this icon altogether for known dropdowns, so technically we may not\n// need this, but it's here in case there are any remaining instances.\n$custom-select-indicator-color: #929192;\n$custom-select-bg: var(--dh-color-selector-bg);\n$custom-select-bg-size: 16px 16px;\n//dhSort icon encoded\n$custom-select-indicator: str-replace(\n url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='#{$custom-select-indicator-color}' d='M4 7l-.4-.8 4-3.7h.8l4 3.7-.4.8H4zm0 2l-.4.8 4 3.7h.8l4-3.7L12 9H4z'/%3E%3C/svg%3E\"),\n '#',\n '%23'\n);\n$custom-select-focus-box-shadow: $input-btn-focus-box-shadow;\n$custom-select-disabled-color: $gray-500;\n$custom-select-disabled-bg: $gray-800;\n\n//modal\n$modal-content-bg: $content-bg;\n$modal-content-border-width: 0;\n$modal-md: 550px;\n$close-color: var(--dh-color-text);\n$close-text-shadow: none;\n\n// Toast notification\n$toast-bg: var(--dh-color-accent-100);\n$toast-color: var(--dh-color-text);\n$toast-error-bg: var(--dh-color-negative-bg);\n$toast-error-color: var(--dh-color-text);\n\n//tooltips\n$tooltip-bg: var(--dh-color-tooltip-bg);\n$tooltip-color: var(--dh-color-tooltip-fg);\n$tooltip-box-shadow: 0 0.1rem 1.5rem 0.1rem var(--dh-color-tooltip-box-shadow);\n\n//drowdowns\n$dropdown-bg: $gray-600;\n$dropdown-link-color: $foreground;\n$dropdown-link-hover-color: $foreground;\n$dropdown-link-hover-bg: var(--dh-color-item-list-hover-bg);\n$dropdown-divider-bg: $gray-700;\n\n//context menus\n$contextmenu-bg: var(--dh-color-popover-bg);\n$contextmenu-color: var(--dh-color-text);\n$contextmenu-disabled-color: var(--dh-color-input-disabled-fg);\n$contextmenu-keyboard-selected-bg: var(--dh-color-keyboard-selected-bg);\n$contextmenu-selected-bg: var(--dh-color-item-list-hover-bg);\n$contextmenu-selected-color: var(--dh-color-item-list-selected-fg);\n\n//hr\n$hr-border-color: var(--dh-color-hr);\n\n//links\n$link-color: $gray-400;\n$link-hover-color: $foreground;\n\n//progress-bar\n$progress-bg: $gray-600;\n$progress-border-radius: 1rem;\n\n// Set global options\n$enable-shadows: false;\n$enable-gradients: false;\n$enable-print-styles: false; //I don't think anyone should expect to \"print\" this app.\n\n// Transition times\n$transition: 0.15s;\n$transition-mid: 0.2s;\n$transition-long: 0.3s;\n$transition-slow: 0.6s;\n\n//form-validation icon, uses vsWarning icon encoded here as svg\n$form-feedback-icon-invalid-color: $danger;\n$form-feedback-icon-invalid: str-replace(\n url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cg fill='none'%3E%3Cg fill='#{$form-feedback-icon-invalid-color}'%3E%3Cpath d='M7.56 1h.88l6.54 12.26-.44.74H1.44L1 13.26 7.56 1zM8 2.28 2.28 13H13.7L8 2.28zM8.625 12v-1h-1.25v1h1.25zm-1.25-2V6h1.25v4h-1.25z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E \"),\n '#',\n '%23'\n);\n\n// This section of variables is not consumed directly by DH, but they need to be\n// defined for sass to compile _variables\n$table-dark-bg: $gray-800;\n$table-dark-accent-bg: var(--dh-color-highlight-hover);\n$table-dark-hover-bg: var(--dh-color-highlight-active);\n$table-dark-border-color: $gray-700;\n$popover-bg: var(--dh-color-tooltip-bg);\n$popover-border-color: var(--dh-color-overlay-modal-bg);\n$popover-header-bg: #000;\n$popover-arrow-outer-color: var(--dh-color-dropshadow);\n$custom-range-thumb-active-bg: var(--dh-color-accent-1100);\n","@import '../scss/custom.scss';\n\n$modified: var(--dh-color-modified);\n\n.validate-label {\n padding-right: $spacer-2;\n &.modified {\n color: $modified;\n }\n}\n"]}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import './ValidateLabelInput.scss';
|
|
3
|
-
export type ValidateLabelInputProps = {
|
|
4
|
-
/** Element to add label to */
|
|
5
|
-
children: React.ReactNode;
|
|
6
|
-
/** Any classnames to add */
|
|
7
|
-
className?: string | string[];
|
|
8
|
-
/** Text for this validation label */
|
|
9
|
-
labelText?: string;
|
|
10
|
-
/** Small hint text next to the main label */
|
|
11
|
-
hintText?: string;
|
|
12
|
-
/** Show a modified state. Defaults to false. */
|
|
13
|
-
isModified?: boolean;
|
|
14
|
-
/** Validation error that has occurred */
|
|
15
|
-
validationError?: string;
|
|
16
|
-
/** Show the validation error if it exists. Default to true. */
|
|
17
|
-
showValidationError?: boolean;
|
|
18
|
-
/** ID to use. Auto-generates if not provided */
|
|
19
|
-
id?: string;
|
|
20
|
-
/** data-testid to apply to the label */
|
|
21
|
-
'data-testid'?: string;
|
|
22
|
-
};
|
|
23
|
-
/**
|
|
24
|
-
* Takes a child and add a label and validaton error
|
|
25
|
-
*/
|
|
26
|
-
export declare function ValidateLabelInput(props: ValidateLabelInputProps): React.ReactElement;
|
|
27
|
-
export default ValidateLabelInput;
|
|
28
|
-
//# sourceMappingURL=ValidateLabelInput.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ValidateLabelInput.d.ts","sourceRoot":"","sources":["../src/ValidateLabelInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAiB,MAAM,OAAO,CAAC;AAGtC,OAAO,2BAA2B,CAAC;AAEnC,MAAM,MAAM,uBAAuB,GAAG;IACpC,8BAA8B;IAC9B,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAE1B,4BAA4B;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE9B,qCAAqC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,6CAA6C;IAC7C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,gDAAgD;IAChD,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB,yCAAyC;IACzC,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB,+DAA+D;IAC/D,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAE9B,gDAAgD;IAChD,EAAE,CAAC,EAAE,MAAM,CAAC;IAEZ,wCAAwC;IACxC,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF;;GAEG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,uBAAuB,GAC7B,KAAK,CAAC,YAAY,CA+CpB;AAED,eAAe,kBAAkB,CAAC"}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import React, { useRef } from 'react';
|
|
2
|
-
import classNames from 'classnames';
|
|
3
|
-
import shortid from 'shortid';
|
|
4
|
-
import "./ValidateLabelInput.css";
|
|
5
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
7
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
|
-
/**
|
|
9
|
-
* Takes a child and add a label and validaton error
|
|
10
|
-
*/
|
|
11
|
-
export function ValidateLabelInput(props) {
|
|
12
|
-
var {
|
|
13
|
-
children,
|
|
14
|
-
className,
|
|
15
|
-
labelText,
|
|
16
|
-
hintText,
|
|
17
|
-
isModified,
|
|
18
|
-
validationError,
|
|
19
|
-
showValidationError = true,
|
|
20
|
-
'data-testid': dataTestId,
|
|
21
|
-
id: idProp
|
|
22
|
-
} = props;
|
|
23
|
-
var {
|
|
24
|
-
current: id
|
|
25
|
-
} = useRef(idProp !== null && idProp !== void 0 ? idProp : shortid());
|
|
26
|
-
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
27
|
-
children: [/*#__PURE__*/_jsx("label", {
|
|
28
|
-
className: classNames('validate-label', className, {
|
|
29
|
-
modified: isModified
|
|
30
|
-
}),
|
|
31
|
-
htmlFor: id,
|
|
32
|
-
"data-testid": dataTestId,
|
|
33
|
-
children: labelText
|
|
34
|
-
}), React.Children.toArray(children).map(child => {
|
|
35
|
-
if (! /*#__PURE__*/React.isValidElement(child)) {
|
|
36
|
-
// eslint-disable-next-line react/jsx-key
|
|
37
|
-
return /*#__PURE__*/_jsx("div", {
|
|
38
|
-
className: classNames(className),
|
|
39
|
-
children: child
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// toArray strips null children
|
|
44
|
-
return /*#__PURE__*/React.cloneElement(child, {
|
|
45
|
-
className: classNames(child.props.className, {
|
|
46
|
-
'is-invalid': validationError
|
|
47
|
-
})
|
|
48
|
-
});
|
|
49
|
-
}), hintText !== undefined && /*#__PURE__*/_jsx("small", {
|
|
50
|
-
className: "form-text text-muted",
|
|
51
|
-
children: hintText
|
|
52
|
-
}), validationError !== undefined && showValidationError && /*#__PURE__*/_jsx("p", {
|
|
53
|
-
className: "validate-label-error text-danger",
|
|
54
|
-
children: validationError
|
|
55
|
-
})]
|
|
56
|
-
});
|
|
57
|
-
}
|
|
58
|
-
export default ValidateLabelInput;
|
|
59
|
-
//# sourceMappingURL=ValidateLabelInput.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ValidateLabelInput.js","names":["React","useRef","classNames","shortid","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","ValidateLabelInput","props","children","className","labelText","hintText","isModified","validationError","showValidationError","dataTestId","id","idProp","current","modified","htmlFor","Children","toArray","map","child","isValidElement","cloneElement","undefined"],"sources":["../src/ValidateLabelInput.tsx"],"sourcesContent":["import React, { useRef } from 'react';\nimport classNames from 'classnames';\nimport shortid from 'shortid';\nimport './ValidateLabelInput.scss';\n\nexport type ValidateLabelInputProps = {\n /** Element to add label to */\n children: React.ReactNode;\n\n /** Any classnames to add */\n className?: string | string[];\n\n /** Text for this validation label */\n labelText?: string;\n\n /** Small hint text next to the main label */\n hintText?: string;\n\n /** Show a modified state. Defaults to false. */\n isModified?: boolean;\n\n /** Validation error that has occurred */\n validationError?: string;\n\n /** Show the validation error if it exists. Default to true. */\n showValidationError?: boolean;\n\n /** ID to use. Auto-generates if not provided */\n id?: string;\n\n /** data-testid to apply to the label */\n 'data-testid'?: string;\n};\n\n/**\n * Takes a child and add a label and validaton error\n */\nexport function ValidateLabelInput(\n props: ValidateLabelInputProps\n): React.ReactElement {\n const {\n children,\n className,\n labelText,\n hintText,\n isModified,\n validationError,\n showValidationError = true,\n 'data-testid': dataTestId,\n id: idProp,\n } = props;\n\n const { current: id } = useRef(idProp ?? shortid());\n\n return (\n <>\n <label\n className={classNames('validate-label', className, {\n modified: isModified,\n })}\n htmlFor={id}\n data-testid={dataTestId}\n >\n {labelText}\n </label>\n {React.Children.toArray(children).map(child => {\n if (!React.isValidElement<React.HTMLAttributes<HTMLElement>>(child)) {\n // eslint-disable-next-line react/jsx-key\n return <div className={classNames(className)}>{child}</div>;\n }\n\n // toArray strips null children\n return React.cloneElement(child, {\n className: classNames(child.props.className, {\n 'is-invalid': validationError,\n }),\n });\n })}\n {hintText !== undefined && (\n <small className=\"form-text text-muted\">{hintText}</small>\n )}\n {validationError !== undefined && showValidationError && (\n <p className=\"validate-label-error text-danger\">{validationError}</p>\n )}\n </>\n );\n}\n\nexport default ValidateLabelInput;\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,MAAM,QAAQ,OAAO;AACrC,OAAOC,UAAU,MAAM,YAAY;AACnC,OAAOC,OAAO,MAAM,SAAS;AAAC;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,QAAA,IAAAC,SAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAgC9B;AACA;AACA;AACA,OAAO,SAASC,kBAAkBA,CAChCC,KAA8B,EACV;EACpB,IAAM;IACJC,QAAQ;IACRC,SAAS;IACTC,SAAS;IACTC,QAAQ;IACRC,UAAU;IACVC,eAAe;IACfC,mBAAmB,GAAG,IAAI;IAC1B,aAAa,EAAEC,UAAU;IACzBC,EAAE,EAAEC;EACN,CAAC,GAAGV,KAAK;EAET,IAAM;IAAEW,OAAO,EAAEF;EAAG,CAAC,GAAGnB,MAAM,CAACoB,MAAM,aAANA,MAAM,cAANA,MAAM,GAAIlB,OAAO,CAAC,CAAC,CAAC;EAEnD,oBACEM,KAAA,CAAAF,SAAA;IAAAK,QAAA,gBACEP,IAAA;MACEQ,SAAS,EAAEX,UAAU,CAAC,gBAAgB,EAAEW,SAAS,EAAE;QACjDU,QAAQ,EAAEP;MACZ,CAAC,CAAE;MACHQ,OAAO,EAAEJ,EAAG;MACZ,eAAaD,UAAW;MAAAP,QAAA,EAEvBE;IAAS,CACL,CAAC,EACPd,KAAK,CAACyB,QAAQ,CAACC,OAAO,CAACd,QAAQ,CAAC,CAACe,GAAG,CAACC,KAAK,IAAI;MAC7C,IAAI,eAAC5B,KAAK,CAAC6B,cAAc,CAAoCD,KAAK,CAAC,EAAE;QACnE;QACA,oBAAOvB,IAAA;UAAKQ,SAAS,EAAEX,UAAU,CAACW,SAAS,CAAE;UAAAD,QAAA,EAAEgB;QAAK,CAAM,CAAC;MAC7D;;MAEA;MACA,oBAAO5B,KAAK,CAAC8B,YAAY,CAACF,KAAK,EAAE;QAC/Bf,SAAS,EAAEX,UAAU,CAAC0B,KAAK,CAACjB,KAAK,CAACE,SAAS,EAAE;UAC3C,YAAY,EAAEI;QAChB,CAAC;MACH,CAAC,CAAC;IACJ,CAAC,CAAC,EACDF,QAAQ,KAAKgB,SAAS,iBACrB1B,IAAA;MAAOQ,SAAS,EAAC,sBAAsB;MAAAD,QAAA,EAAEG;IAAQ,CAAQ,CAC1D,EACAE,eAAe,KAAKc,SAAS,IAAIb,mBAAmB,iBACnDb,IAAA;MAAGQ,SAAS,EAAC,kCAAkC;MAAAD,QAAA,EAAEK;IAAe,CAAI,CACrE;EAAA,CACD,CAAC;AAEP;AAEA,eAAeP,kBAAkB"}
|
package/dist/spectrum/Flex.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.d.ts","sourceRoot":"","sources":["../../src/spectrum/Flex.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C,YAAY,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,eAAe,IAAI,CAAC"}
|
package/dist/spectrum/Flex.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.js","names":["Flex"],"sources":["../../src/spectrum/Flex.tsx"],"sourcesContent":["import { Flex } from '@adobe/react-spectrum';\n\nexport type { FlexProps } from '@adobe/react-spectrum';\nexport { Flex };\nexport default Flex;\n"],"mappings":"AAAA,SAASA,IAAI,QAAQ,uBAAuB;AAG5C,SAASA,IAAI;AACb,eAAeA,IAAI"}
|
package/dist/spectrum/Item.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Wrapping Spectrum `Item` components will break functionality due to the way
|
|
3
|
-
* they are consumed by collection components. They are only used to pass data
|
|
4
|
-
* and don't render anything on their own, so they don't need to be wrapped.
|
|
5
|
-
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17
|
|
6
|
-
*/
|
|
7
|
-
import { Item } from '@adobe/react-spectrum';
|
|
8
|
-
export type { ItemProps } from '@react-types/shared';
|
|
9
|
-
export { Item };
|
|
10
|
-
export default Item;
|
|
11
|
-
//# sourceMappingURL=Item.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Item.d.ts","sourceRoot":"","sources":["../../src/spectrum/Item.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C,YAAY,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAErD,OAAO,EAAE,IAAI,EAAE,CAAC;AAEhB,eAAe,IAAI,CAAC"}
|
package/dist/spectrum/Item.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Wrapping Spectrum `Item` components will break functionality due to the way
|
|
3
|
-
* they are consumed by collection components. They are only used to pass data
|
|
4
|
-
* and don't render anything on their own, so they don't need to be wrapped.
|
|
5
|
-
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17
|
|
6
|
-
*/
|
|
7
|
-
import { Item } from '@adobe/react-spectrum';
|
|
8
|
-
export { Item };
|
|
9
|
-
export default Item;
|
|
10
|
-
//# sourceMappingURL=Item.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Item.js","names":["Item"],"sources":["../../src/spectrum/Item.tsx"],"sourcesContent":["/**\n * Wrapping Spectrum `Item` components will break functionality due to the way\n * they are consumed by collection components. They are only used to pass data\n * and don't render anything on their own, so they don't need to be wrapped.\n * See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Item.ts#L17\n */\nimport { Item } from '@adobe/react-spectrum';\n\nexport type { ItemProps } from '@react-types/shared';\n\nexport { Item };\n\nexport default Item;\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,IAAI,QAAQ,uBAAuB;AAI5C,SAASA,IAAI;AAEb,eAAeA,IAAI"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Wrapping Spectrum `Section` components will break functionality due to the way
|
|
3
|
-
* they are consumed by collection components. They are only used to pass data
|
|
4
|
-
* and don't render anything on their own, so they don't need to be wrapped.
|
|
5
|
-
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18
|
|
6
|
-
*/
|
|
7
|
-
import { Section } from '@adobe/react-spectrum';
|
|
8
|
-
export type { SectionProps } from '@react-types/shared';
|
|
9
|
-
export { Section };
|
|
10
|
-
export default Section;
|
|
11
|
-
//# sourceMappingURL=Section.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Section.d.ts","sourceRoot":"","sources":["../../src/spectrum/Section.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAEhD,YAAY,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAExD,OAAO,EAAE,OAAO,EAAE,CAAC;AAEnB,eAAe,OAAO,CAAC"}
|
package/dist/spectrum/Section.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Wrapping Spectrum `Section` components will break functionality due to the way
|
|
3
|
-
* they are consumed by collection components. They are only used to pass data
|
|
4
|
-
* and don't render anything on their own, so they don't need to be wrapped.
|
|
5
|
-
* See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18
|
|
6
|
-
*/
|
|
7
|
-
import { Section } from '@adobe/react-spectrum';
|
|
8
|
-
export { Section };
|
|
9
|
-
export default Section;
|
|
10
|
-
//# sourceMappingURL=Section.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Section.js","names":["Section"],"sources":["../../src/spectrum/Section.tsx"],"sourcesContent":["/**\n * Wrapping Spectrum `Section` components will break functionality due to the way\n * they are consumed by collection components. They are only used to pass data\n * and don't render anything on their own, so they don't need to be wrapped.\n * See https://github.com/adobe/react-spectrum/blob/main/packages/%40react-stately/collections/src/Section.ts#L18\n */\nimport { Section } from '@adobe/react-spectrum';\n\nexport type { SectionProps } from '@react-types/shared';\n\nexport { Section };\n\nexport default Section;\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,OAAO,QAAQ,uBAAuB;AAI/C,SAASA,OAAO;AAEhB,eAAeA,OAAO"}
|