@splunk/react-ui 5.1.0 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Accordion.js +60 -39
- package/Anchor.js +9 -9
- package/Animation.js +2 -2
- package/Avatar.js +63 -58
- package/Box.js +4 -3
- package/Breadcrumbs.js +13 -13
- package/Button.js +12 -12
- package/ButtonGroup.js +9 -9
- package/ButtonSimple.js +2 -2
- package/CHANGELOG.md +54 -0
- package/Calendar.js +69 -65
- package/Card.js +286 -255
- package/CardLayout.js +10 -10
- package/Checkbox.d.ts +2 -0
- package/Checkbox.js +350 -0
- package/Chip.js +31 -31
- package/Clickable.js +29 -29
- package/Code.js +161 -142
- package/CollapsiblePanel.js +200 -224
- package/Color.js +14 -12
- package/ColumnLayout.js +16 -16
- package/ComboBox.js +110 -110
- package/ControlGroup.js +101 -100
- package/Date.js +144 -140
- package/DefinitionList.js +137 -94
- package/Divider.js +2 -2
- package/Dropdown.js +2 -2
- package/DualListbox.js +446 -385
- package/File.js +121 -118
- package/FormRows.js +15 -15
- package/Heading.js +15 -15
- package/Image.js +31 -31
- package/JSONTree.js +543 -513
- package/Layer.js +4 -1
- package/Layout.js +10 -10
- package/Link.js +13 -13
- package/List.js +24 -24
- package/MIGRATION.md +27 -0
- package/Markdown.js +237 -226
- package/Menu.js +63 -60
- package/Message.js +20 -20
- package/MessageBar.js +13 -13
- package/Modal.js +36 -36
- package/Monogram.js +94 -68
- package/Multiselect.js +1032 -910
- package/Number.js +18 -18
- package/Paginator.js +41 -40
- package/Paragraph.js +10 -10
- package/Popover.js +243 -208
- package/Progress.js +6 -6
- package/Prose.js +16 -16
- package/RadioBar.js +118 -118
- package/RadioList.js +137 -113
- package/Resize.js +20 -20
- package/ResultsMenu.js +50 -49
- package/ScreenReaderContent.js +13 -13
- package/Scroll.js +25 -24
- package/Search.js +143 -139
- package/Select.js +942 -838
- package/SidePanel.js +29 -29
- package/Slider.js +30 -30
- package/SlidingPanels.js +28 -28
- package/SplitButton.js +100 -72
- package/StaticContent.js +6 -6
- package/StepBar.js +8 -8
- package/Switch.js +197 -229
- package/TabBar.js +293 -270
- package/TabLayout.js +68 -68
- package/Table.js +825 -800
- package/Text.js +182 -208
- package/TextArea.js +235 -226
- package/Tooltip.js +149 -144
- package/TransitionOpen.js +11 -11
- package/Tree.js +194 -189
- package/Typography.js +15 -15
- package/WaitSpinner.js +6 -6
- package/package.json +19 -23
- package/tsconfig.check-docs.json +8 -0
- package/types/src/Accordion/docs/examples/Controlled.d.ts +3 -0
- package/types/src/Accordion/docs/examples/Inset.d.ts +4 -0
- package/types/src/Accordion/docs/examples/Uncontrolled.d.ts +3 -0
- package/types/src/Anchor/docs/examples/Basic.d.ts +4 -0
- package/types/src/AnimationToggle/docs/examples/Provider.d.ts +4 -0
- package/types/src/AnimationToggle/docs/examples/ReducedMotionComponent.d.ts +4 -0
- package/types/src/AnimationToggle/docs/examples/ReducedMotionHook.d.ts +4 -0
- package/types/src/AnimationToggle/docs/examples/ToggleComponent.d.ts +4 -0
- package/types/src/Avatar/docs/examples/BackgroundColor.d.ts +4 -0
- package/types/src/Avatar/docs/examples/Basic.d.ts +4 -0
- package/types/src/Avatar/docs/examples/Image.d.ts +4 -0
- package/types/src/Avatar/docs/examples/Interactive.d.ts +4 -0
- package/types/src/Avatar/docs/examples/Size.d.ts +4 -0
- package/types/src/Breadcrumbs/docs/examples/Adornments.d.ts +4 -0
- package/types/src/Breadcrumbs/docs/examples/Basic.d.ts +3 -0
- package/types/src/Breadcrumbs/docs/examples/CustomizedClick.d.ts +4 -0
- package/types/src/Button/docs/examples/Basic.d.ts +3 -0
- package/types/src/Button/docs/examples/Block.d.ts +4 -0
- package/types/src/Button/docs/examples/Disabled.d.ts +4 -0
- package/types/src/Button/docs/examples/Icons.d.ts +4 -0
- package/types/src/Button/docs/examples/Menus.d.ts +4 -0
- package/types/src/Button/docs/examples/To.d.ts +4 -0
- package/types/src/ButtonGroup/docs/examples/Basic.d.ts +3 -0
- package/types/src/Card/docs/examples/Basic.d.ts +4 -0
- package/types/src/Card/docs/examples/Clickable.d.ts +4 -0
- package/types/src/Card/docs/examples/Full.d.ts +4 -0
- package/types/src/Card/docs/examples/HeadingTitle.d.ts +4 -0
- package/types/src/Card/docs/examples/Images.d.ts +4 -0
- package/types/src/Card/docs/examples/Selectable.d.ts +4 -0
- package/types/src/CardLayout/docs/examples/Basic.d.ts +3 -0
- package/types/src/CardLayout/docs/examples/Interactive.d.ts +4 -0
- package/types/src/Checkbox/Checkbox.d.ts +90 -0
- package/types/src/Checkbox/docs/examples/Basic.d.ts +7 -0
- package/types/src/Checkbox/docs/examples/Disabled.d.ts +6 -0
- package/types/src/Checkbox/docs/examples/Error.d.ts +6 -0
- package/types/src/Checkbox/docs/examples/Uncontrolled.d.ts +7 -0
- package/types/src/Checkbox/index.d.ts +2 -0
- package/types/src/Chip/docs/examples/Appearance.d.ts +3 -0
- package/types/src/Chip/docs/examples/CustomColors.d.ts +4 -0
- package/types/src/Chip/docs/examples/Disabled.d.ts +3 -0
- package/types/src/Chip/docs/examples/Icon.d.ts +3 -0
- package/types/src/Chip/docs/examples/Removable.d.ts +3 -0
- package/types/src/Chip/docs/examples/RemovableWithNonStringChildren.d.ts +4 -0
- package/types/src/Clickable/docs/examples/Disabled.d.ts +4 -0
- package/types/src/Code/Code.d.ts +4 -1
- package/types/src/Code/LineHighlights.d.ts +1 -0
- package/types/src/Code/LineNumbers.d.ts +2 -1
- package/types/src/Code/docs/examples/CustomizeContainer.d.ts +7 -0
- package/types/src/Code/docs/examples/Default.d.ts +3 -0
- package/types/src/Code/docs/examples/HideIndent.d.ts +4 -0
- package/types/src/Code/docs/examples/Language.d.ts +4 -0
- package/types/src/Code/docs/examples/LineHighlights.d.ts +4 -0
- package/types/src/Code/docs/examples/LineNumbers.d.ts +4 -0
- package/types/src/Code/docs/examples/LineNumbersCustomStart.d.ts +4 -0
- package/types/src/CollapsiblePanel/docs/examples/Actions.d.ts +4 -0
- package/types/src/CollapsiblePanel/docs/examples/BasicControlled.d.ts +3 -0
- package/types/src/CollapsiblePanel/docs/examples/BasicUncontrolled.d.ts +3 -0
- package/types/src/CollapsiblePanel/docs/examples/Disabled.d.ts +7 -0
- package/types/src/CollapsiblePanel/docs/examples/MultiControlled.d.ts +3 -0
- package/types/src/CollapsiblePanel/docs/examples/MultiUncontrolled.d.ts +3 -0
- package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupControlled.d.ts +4 -0
- package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupInset.d.ts +4 -0
- package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupUncontrolled.d.ts +4 -0
- package/types/src/CollapsiblePanel/docs/examples/Subtle.d.ts +4 -0
- package/types/src/Color/docs/examples/Controlled.d.ts +3 -0
- package/types/src/Color/docs/examples/CustomizedPalette.d.ts +4 -0
- package/types/src/Color/docs/examples/HideInput.d.ts +4 -0
- package/types/src/Color/docs/examples/Null.d.ts +4 -0
- package/types/src/Color/docs/examples/ThemeVariables.d.ts +4 -0
- package/types/src/Color/docs/examples/Transparent.d.ts +4 -0
- package/types/src/Color/docs/examples/Uncontrolled.d.ts +3 -0
- package/types/src/ColumnLayout/docs/examples/AlignItems.d.ts +4 -0
- package/types/src/ColumnLayout/docs/examples/Basic.d.ts +4 -0
- package/types/src/ColumnLayout/docs/examples/Dividers.d.ts +4 -0
- package/types/src/ColumnLayout/docs/examples/Gutters.d.ts +4 -0
- package/types/src/ComboBox/docs/examples/Controlled.d.ts +4 -0
- package/types/src/ComboBox/docs/examples/Fetching.d.ts +4 -0
- package/types/src/ComboBox/docs/examples/Headings.d.ts +3 -0
- package/types/src/ComboBox/docs/examples/Label.d.ts +4 -0
- package/types/src/ComboBox/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/Basic.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/CustomizedLabelTarget.d.ts +7 -3
- package/types/src/ControlGroup/docs/examples/Error.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/HelpWithErrorText.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/HelpWithLinks.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/LabelLeft.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/LayoutFill.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/LayoutFillJoin.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/LayoutNone.d.ts +4 -0
- package/types/src/ControlGroup/docs/examples/Required.d.ts +4 -0
- package/types/src/Date/Date.d.ts +7 -1
- package/types/src/Date/docs/examples/Basic.d.ts +3 -0
- package/types/src/Date/docs/examples/Controlled.d.ts +3 -0
- package/types/src/Date/docs/examples/CustomDate.d.ts +4 -0
- package/types/src/Date/docs/examples/Disabled.d.ts +3 -0
- package/types/src/Date/docs/examples/Error.d.ts +3 -0
- package/types/src/Date/docs/examples/HighlightToday.d.ts +4 -0
- package/types/src/Date/docs/examples/WithoutCalendar.d.ts +4 -0
- package/types/src/DefinitionList/DefinitionList.d.ts +27 -4
- package/types/src/DefinitionList/DefinitionListContext.d.ts +2 -0
- package/types/src/DefinitionList/docs/examples/Basic.d.ts +3 -0
- package/types/src/DefinitionList/docs/examples/CustomizedWidths.d.ts +7 -0
- package/types/src/DefinitionList/docs/examples/EmptyDescription.d.ts +4 -0
- package/types/src/DefinitionList/docs/examples/StackedLayout.d.ts +6 -0
- package/types/src/DefinitionList/docs/examples/WithSeparator.d.ts +4 -0
- package/types/src/Divider/docs/examples/Appearance.d.ts +4 -0
- package/types/src/Divider/docs/examples/Basic.d.ts +3 -0
- package/types/src/Divider/docs/examples/CustomStyle.d.ts +4 -0
- package/types/src/Divider/docs/examples/Decorative.d.ts +4 -0
- package/types/src/Divider/docs/examples/Vertical.d.ts +3 -0
- package/types/src/Dropdown/docs/examples/Basic.d.ts +4 -0
- package/types/src/Dropdown/docs/examples/BasicMenu.d.ts +3 -0
- package/types/src/Dropdown/docs/examples/ControlledDropdown.d.ts +4 -0
- package/types/src/Dropdown/docs/examples/Dialog.d.ts +4 -0
- package/types/src/Dropdown/docs/examples/ScrollContainer.d.ts +4 -0
- package/types/src/Dropdown/docs/examples/ScrollingMenu.d.ts +4 -0
- package/types/src/Dropdown/docs/examples/Submenu.d.ts +3 -0
- package/types/src/Dropdown/docs/examples/TooltipButtonToggle.d.ts +4 -0
- package/types/src/DualListbox/DualListbox.d.ts +1 -1
- package/types/src/DualListbox/Label.d.ts +7 -7
- package/types/src/DualListbox/Listbox.d.ts +2 -2
- package/types/src/DualListbox/ListboxContext.d.ts +1 -1
- package/types/src/DualListbox/Option.d.ts +1 -1
- package/types/src/DualListbox/docs/examples/Basic.d.ts +3 -0
- package/types/src/DualListbox/docs/examples/Controlled.d.ts +3 -0
- package/types/src/DualListbox/docs/examples/Fill.d.ts +4 -0
- package/types/src/File/File.d.ts +7 -1
- package/types/src/File/docs/examples/CustomizedMessages.d.ts +4 -0
- package/types/src/File/docs/examples/Disabled.d.ts +3 -0
- package/types/src/File/docs/examples/DropAnywhere.d.ts +4 -0
- package/types/src/File/docs/examples/Error.d.ts +4 -0
- package/types/src/File/docs/examples/FullScreen.d.ts +4 -0
- package/types/src/File/docs/examples/Multi.d.ts +4 -0
- package/types/src/File/docs/examples/Progress.d.ts +4 -0
- package/types/src/File/docs/examples/Single.d.ts +4 -0
- package/types/src/FormRows/docs/examples/Basic.d.ts +3 -0
- package/types/src/FormRows/docs/examples/Header.d.ts +4 -0
- package/types/src/FormRows/docs/examples/Menu.d.ts +4 -0
- package/types/src/FormRows/docs/examples/ReorderOnly.d.ts +4 -0
- package/types/src/Heading/docs/examples/Basic.d.ts +3 -0
- package/types/src/Heading/docs/examples/Variant.d.ts +4 -0
- package/types/src/Image/docs/examples/Basic.d.ts +3 -0
- package/types/src/JSONTree/JSONTreeItem.d.ts +4 -2
- package/types/src/JSONTree/docs/examples/Basic.d.ts +3 -0
- package/types/src/JSONTree/docs/examples/Events.d.ts +4 -0
- package/types/src/JSONTree/docs/examples/ExpandChildrenOnShiftKey.d.ts +4 -0
- package/types/src/JSONTree/renderTreeItems.d.ts +2 -1
- package/types/src/Layer/docs/examples/Basic.d.ts +4 -0
- package/types/src/Layout/docs/examples/Basic.d.ts +3 -0
- package/types/src/Link/docs/examples/Basic.d.ts +4 -0
- package/types/src/Link/docs/examples/Disabled.d.ts +4 -0
- package/types/src/Link/docs/examples/NewWindow.d.ts +4 -0
- package/types/src/Link/docs/examples/Standalone.d.ts +4 -0
- package/types/src/List/docs/examples/CustomizedList.d.ts +4 -0
- package/types/src/List/docs/examples/OrderedList.d.ts +4 -0
- package/types/src/List/docs/examples/UnorderedList.d.ts +3 -0
- package/types/src/Markdown/docs/examples/Basic.d.ts +4 -0
- package/types/src/Markdown/docs/examples/I18n.d.ts +4 -0
- package/types/src/Markdown/renderers/MarkdownCodeBlock.d.ts +2 -1
- package/types/src/Menu/Item.d.ts +27 -10
- package/types/src/Menu/docs/examples/Adornments.d.ts +4 -0
- package/types/src/Menu/docs/examples/Basic.d.ts +3 -0
- package/types/src/Menu/docs/examples/Complex.d.ts +4 -0
- package/types/src/Menu/docs/examples/Descriptions.d.ts +4 -0
- package/types/src/Menu/docs/examples/Dimmed.d.ts +4 -0
- package/types/src/Menu/docs/examples/Disabled.d.ts +4 -0
- package/types/src/Menu/docs/examples/Dividers.d.ts +3 -0
- package/types/src/Menu/docs/examples/Headings.d.ts +4 -0
- package/types/src/Menu/docs/examples/Links.d.ts +4 -0
- package/types/src/Menu/docs/examples/MatchRanges.d.ts +4 -0
- package/types/src/Menu/docs/examples/Selectable.d.ts +4 -0
- package/types/src/Menu/docs/examples/SelectableWithAdornments.d.ts +4 -0
- package/types/src/Menu/docs/examples/Truncate.d.ts +4 -0
- package/types/src/Message/docs/examples/Basic.d.ts +3 -0
- package/types/src/Message/docs/examples/Content.d.ts +4 -0
- package/types/src/Message/docs/examples/Fill.d.ts +3 -0
- package/types/src/Message/docs/examples/Removable.d.ts +3 -0
- package/types/src/MessageBar/docs/examples/Basic.d.ts +4 -0
- package/types/src/MessageBar/docs/examples/Types.d.ts +4 -0
- package/types/src/MessageBar/docs/examples/WithActions.d.ts +3 -0
- package/types/src/Modal/Modal.d.ts +10 -3
- package/types/src/Modal/docs/examples/Basic.d.ts +3 -0
- package/types/src/Modal/docs/examples/InitialFocus.d.ts +4 -0
- package/types/src/Modal/docs/examples/TypicalUsage.d.ts +4 -0
- package/types/src/Modal/docs/examples/Undismissable.d.ts +4 -0
- package/types/src/Monogram/Monogram.d.ts +4 -0
- package/types/src/Monogram/docs/examples/BackgroundAuto.d.ts +4 -0
- package/types/src/Monogram/docs/examples/BackgroundCustom.d.ts +3 -0
- package/types/src/Monogram/docs/examples/Basic.d.ts +4 -0
- package/types/src/Monogram/docs/examples/Interactive.d.ts +4 -0
- package/types/src/Monogram/docs/examples/Size.d.ts +4 -0
- package/types/src/Multiselect/Compact.d.ts +8 -2
- package/types/src/Multiselect/Multiselect.d.ts +8 -2
- package/types/src/Multiselect/Normal.d.ts +7 -1
- package/types/src/Multiselect/docs/examples/Children.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/Compact.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/Controlled.d.ts +3 -0
- package/types/src/Multiselect/docs/examples/CustomizeSelected.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/Disabled.d.ts +3 -0
- package/types/src/Multiselect/docs/examples/Error.d.ts +3 -0
- package/types/src/Multiselect/docs/examples/Fetching.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/Headings.d.ts +3 -0
- package/types/src/Multiselect/docs/examples/Icons.d.ts +3 -0
- package/types/src/Multiselect/docs/examples/LoadMoreOnScrollBottom.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/NewValues.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/TabInput.d.ts +4 -0
- package/types/src/Multiselect/docs/examples/Uncontrolled.d.ts +3 -0
- package/types/src/Number/docs/examples/Basic.d.ts +4 -0
- package/types/src/Number/docs/examples/Disabled.d.ts +3 -0
- package/types/src/Number/docs/examples/Error.d.ts +3 -0
- package/types/src/Number/docs/examples/Limits.d.ts +4 -0
- package/types/src/Number/docs/examples/Locale.d.ts +4 -0
- package/types/src/Number/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/Paginator/docs/examples/Basic.d.ts +3 -0
- package/types/src/Paginator/docs/examples/Compact.d.ts +4 -0
- package/types/src/Paginator/docs/examples/CompactCustomLabel.d.ts +3 -0
- package/types/src/Paginator/docs/examples/CompactWithLabel.d.ts +3 -0
- package/types/src/Paginator/docs/examples/CustomPages.d.ts +4 -0
- package/types/src/Paginator/docs/examples/Labelled.d.ts +4 -0
- package/types/src/Paginator/docs/examples/PageControl.d.ts +4 -0
- package/types/src/Paragraph/docs/examples/Basic.d.ts +4 -0
- package/types/src/Popover/PopoverProvider.d.ts +9 -1
- package/types/src/Popover/docs/examples/Basic.d.ts +4 -0
- package/types/src/Progress/docs/examples/Basic.d.ts +3 -0
- package/types/src/Progress/docs/examples/Type.d.ts +3 -0
- package/types/src/Prose/docs/examples/Basic.d.ts +3 -0
- package/types/src/Prose/docs/examples/Customize.d.ts +4 -0
- package/types/src/RadioBar/docs/examples/AdornmentAriaExamples.d.ts +5 -0
- package/types/src/RadioBar/docs/examples/Basic.d.ts +3 -0
- package/types/src/RadioBar/docs/examples/Disabled.d.ts +4 -0
- package/types/src/RadioBar/docs/examples/Error.d.ts +3 -0
- package/types/src/RadioBar/docs/examples/MenuBar.d.ts +4 -0
- package/types/src/RadioBar/docs/examples/Uncontrolled.d.ts +3 -0
- package/types/src/RadioList/docs/examples/Basic.d.ts +4 -0
- package/types/src/RadioList/docs/examples/Disabled.d.ts +3 -0
- package/types/src/RadioList/docs/examples/Error.d.ts +3 -0
- package/types/src/RadioList/docs/examples/Row.d.ts +3 -0
- package/types/src/RadioList/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/Resize/docs/examples/Appearance.d.ts +4 -0
- package/types/src/Resize/docs/examples/Basic.d.ts +4 -0
- package/types/src/Resize/docs/examples/Percentage.d.ts +4 -0
- package/types/src/Resize/docs/examples/SizingInner.d.ts +4 -0
- package/types/src/Resize/docs/examples/SizingOuter.d.ts +4 -0
- package/types/src/ScreenReaderContent/docs/examples/Basic.d.ts +4 -0
- package/types/src/ScreenReaderContent/docs/examples/SkipLink.d.ts +4 -0
- package/types/src/Scroll/docs/examples/Controlled.d.ts +4 -0
- package/types/src/Scroll/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/ScrollContainerContext/docs/examples/Provider.d.ts +4 -0
- package/types/src/Search/Search.d.ts +5 -1
- package/types/src/Search/docs/examples/Controlled.d.ts +4 -0
- package/types/src/Search/docs/examples/Loading.d.ts +4 -0
- package/types/src/Search/docs/examples/Options.d.ts +4 -0
- package/types/src/Search/docs/examples/OptionsLinks.d.ts +4 -0
- package/types/src/Select/SelectAllOption.d.ts +5 -10
- package/types/src/Select/SelectBase.d.ts +1 -1
- package/types/src/Select/docs/examples/Appearance.d.ts +4 -0
- package/types/src/Select/docs/examples/Basic.d.ts +4 -0
- package/types/src/Select/docs/examples/Children.d.ts +4 -0
- package/types/src/Select/docs/examples/Descriptions.d.ts +4 -0
- package/types/src/Select/docs/examples/Error.d.ts +3 -0
- package/types/src/Select/docs/examples/Fetching.d.ts +4 -0
- package/types/src/Select/docs/examples/Filter.d.ts +4 -0
- package/types/src/Select/docs/examples/Headings.d.ts +3 -0
- package/types/src/Select/docs/examples/Icons.d.ts +3 -0
- package/types/src/Select/docs/examples/LoadMoreOnScrollBottom.d.ts +4 -0
- package/types/src/Select/docs/examples/Prefix.d.ts +4 -0
- package/types/src/Select/docs/examples/Truncate.d.ts +4 -0
- package/types/src/Select/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/SidePanel/docs/examples/Basic.d.ts +4 -0
- package/types/src/SidePanel/docs/examples/ChangeSize.d.ts +3 -0
- package/types/src/SidePanel/docs/examples/Composition.d.ts +4 -0
- package/types/src/Slider/docs/examples/Basic.d.ts +3 -0
- package/types/src/Slider/docs/examples/Controlled.d.ts +4 -0
- package/types/src/Slider/docs/examples/CustomLabels.d.ts +4 -0
- package/types/src/Slider/docs/examples/Disabled.d.ts +3 -0
- package/types/src/Slider/docs/examples/Error.d.ts +3 -0
- package/types/src/Slider/docs/examples/StepMarks.d.ts +4 -0
- package/types/src/SlidingPanels/docs/examples/Basic.d.ts +3 -0
- package/types/src/SlidingPanels/docs/examples/Dropdown.d.ts +3 -0
- package/types/src/SlidingPanels/docs/examples/Modal.d.ts +3 -0
- package/types/src/SplitButton/SplitButton.d.ts +6 -1
- package/types/src/SplitButton/docs/examples/Basic.d.ts +3 -0
- package/types/src/SplitButton/docs/examples/Block.d.ts +4 -0
- package/types/src/SplitButton/docs/examples/ChangeLabel.d.ts +4 -0
- package/types/src/SplitButton/docs/examples/Disabled.d.ts +3 -0
- package/types/src/StaticContent/docs/examples/Basic.d.ts +4 -0
- package/types/src/StaticContent/docs/examples/FieldValue.d.ts +4 -0
- package/types/src/StepBar/docs/examples/Basic.d.ts +3 -0
- package/types/src/StepBar/docs/examples/Error.d.ts +3 -0
- package/types/src/Switch/Switch.d.ts +7 -1
- package/types/src/Switch/docs/examples/Basic.d.ts +5 -9
- package/types/src/Switch/docs/examples/Disabled.d.ts +5 -9
- package/types/src/TabBar/docs/examples/Basic.d.ts +3 -0
- package/types/src/TabBar/docs/examples/Disabled.d.ts +3 -0
- package/types/src/TabBar/docs/examples/Icons.d.ts +3 -0
- package/types/src/TabBar/docs/examples/Tooltips.d.ts +3 -0
- package/types/src/TabBar/docs/examples/Vertical.d.ts +3 -0
- package/types/src/TabBar/docs/examples/VerticalIcons.d.ts +3 -0
- package/types/src/TabBar/docs/examples/WithCount.d.ts +3 -0
- package/types/src/TabBar/tabBarUtils.d.ts +4 -0
- package/types/src/TabBar/types.d.ts +5 -0
- package/types/src/TabLayout/docs/examples/AutoActivate.d.ts +4 -0
- package/types/src/TabLayout/docs/examples/Controlled.d.ts +4 -0
- package/types/src/TabLayout/docs/examples/Icons.d.ts +3 -0
- package/types/src/TabLayout/docs/examples/Uncontrolled.d.ts +3 -0
- package/types/src/TabLayout/docs/examples/Vertical.d.ts +3 -0
- package/types/src/TabLayout/docs/examples/VerticalIcons.d.ts +3 -0
- package/types/src/Table/ExpandButton.d.ts +1 -1
- package/types/src/Table/docs/examples/Basic.d.ts +3 -0
- package/types/src/Table/docs/examples/Click.d.ts +4 -0
- package/types/src/Table/docs/examples/ClickRows.d.ts +4 -0
- package/types/src/Table/docs/examples/Complex.d.ts +4 -0
- package/types/src/Table/docs/examples/DockedHeaderScrollbar.d.ts +4 -0
- package/types/src/Table/docs/examples/FilterColumnValues.d.ts +4 -0
- package/types/src/Table/docs/examples/FixedHeader.d.ts +4 -0
- package/types/src/Table/docs/examples/HeadDropdownCell.d.ts +4 -0
- package/types/src/Table/docs/examples/ReorderColumns.d.ts +4 -0
- package/types/src/Table/docs/examples/ReorderRows.d.ts +4 -0
- package/types/src/Table/docs/examples/Resizable.d.ts +4 -0
- package/types/src/Table/docs/examples/ResizableFill.d.ts +4 -0
- package/types/src/Table/docs/examples/RowActions.d.ts +4 -0
- package/types/src/Table/docs/examples/Selectable.d.ts +4 -0
- package/types/src/Table/docs/examples/SortableColumns.d.ts +4 -0
- package/types/src/Table/docs/examples/StripeRows.d.ts +3 -0
- package/types/src/Text/docs/examples/Basic.d.ts +4 -0
- package/types/src/Text/docs/examples/CustomizedIcon.d.ts +4 -0
- package/types/src/Text/docs/examples/Dimmed.d.ts +4 -0
- package/types/src/Text/docs/examples/Disabled.d.ts +4 -0
- package/types/src/Text/docs/examples/Error.d.ts +4 -0
- package/types/src/Text/docs/examples/Inline.d.ts +4 -0
- package/types/src/Text/docs/examples/Password.d.ts +4 -0
- package/types/src/Text/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/TextArea/docs/examples/Basic.d.ts +4 -0
- package/types/src/TextArea/docs/examples/Disabled.d.ts +3 -0
- package/types/src/TextArea/docs/examples/Error.d.ts +4 -0
- package/types/src/TextArea/docs/examples/Inline.d.ts +4 -0
- package/types/src/TextArea/docs/examples/Uncontrolled.d.ts +4 -0
- package/types/src/Tooltip/Tooltip.d.ts +14 -1
- package/types/src/Tooltip/docs/examples/Basic.d.ts +4 -0
- package/types/src/Tooltip/docs/examples/ContentRelationship.d.ts +4 -0
- package/types/src/Tooltip/docs/examples/Controlled.d.ts +4 -0
- package/types/src/Tooltip/docs/examples/CustomDelay.d.ts +4 -0
- package/types/src/Tooltip/docs/examples/CustomProps.d.ts +4 -0
- package/types/src/Tooltip/docs/examples/Toggletip.d.ts +4 -0
- package/types/src/TransitionOpen/docs/examples/ExpandHeight.d.ts +3 -0
- package/types/src/TransitionOpen/docs/examples/ExpandWidth.d.ts +3 -0
- package/types/src/TransitionOpen/docs/examples/None.d.ts +4 -0
- package/types/src/TransitionOpen/docs/examples/SlideFromBottom.d.ts +4 -0
- package/types/src/TransitionOpen/docs/examples/SlideFromLeft.d.ts +4 -0
- package/types/src/TransitionOpen/docs/examples/SlideFromRight.d.ts +4 -0
- package/types/src/TransitionOpen/docs/examples/SlideFromTop.d.ts +4 -0
- package/types/src/Tree/Item.d.ts +4 -4
- package/types/src/Tree/docs/examples/Basic.d.ts +5 -0
- package/types/src/Tree/docs/examples/ClickableExpansion.d.ts +2 -0
- package/types/src/Tree/docs/examples/ClickableExpansionWithSelection.d.ts +2 -0
- package/types/src/Typography/docs/examples/Basic.d.ts +4 -0
- package/types/src/WaitSpinner/docs/examples/Basic.d.ts +3 -0
- package/useResizeObserver.js +2 -2
- package/NonInteractiveCheckbox.js +0 -101
- package/types/src/CollapsiblePanel/icons/ExpandPanel.d.ts +0 -12
- package/types/src/DefinitionList/docs/examples/Customize.d.ts +0 -3
- package/types/src/NonInteractiveCheckbox/NonInteractiveCheckbox.d.ts +0 -22
- package/types/src/NonInteractiveCheckbox/index.d.ts +0 -1
- package/types/src/Switch/docs/examples/Error.d.ts +0 -3
- package/types/src/Text/IconOutlinedHide.d.ts +0 -3
- package/types/src/Text/IconOutlinedView.d.ts +0 -3
- /package/cypress/{tsconfig.cypress.json → tsconfig.check-cypress.json} +0 -0
package/CardLayout.js
CHANGED
|
@@ -94,8 +94,8 @@
|
|
|
94
94
|
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
95
95
|
}, f(e);
|
|
96
96
|
}
|
|
97
|
-
function
|
|
98
|
-
return
|
|
97
|
+
function d() {
|
|
98
|
+
return d = Object.assign ? Object.assign.bind() : function(e) {
|
|
99
99
|
for (var r = 1; r < arguments.length; r++) {
|
|
100
100
|
var t = arguments[r];
|
|
101
101
|
for (var n in t) {
|
|
@@ -103,9 +103,9 @@
|
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
return e;
|
|
106
|
-
},
|
|
106
|
+
}, d.apply(null, arguments);
|
|
107
107
|
}
|
|
108
|
-
function
|
|
108
|
+
function s(e, r) {
|
|
109
109
|
var t = Object.keys(e);
|
|
110
110
|
if (Object.getOwnPropertySymbols) {
|
|
111
111
|
var n = Object.getOwnPropertySymbols(e);
|
|
@@ -118,9 +118,9 @@
|
|
|
118
118
|
function p(e) {
|
|
119
119
|
for (var r = 1; r < arguments.length; r++) {
|
|
120
120
|
var t = null != arguments[r] ? arguments[r] : {};
|
|
121
|
-
r % 2 ?
|
|
121
|
+
r % 2 ? s(Object(t), !0).forEach((function(r) {
|
|
122
122
|
y(e, r, t[r]);
|
|
123
|
-
})) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) :
|
|
123
|
+
})) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : s(Object(t)).forEach((function(r) {
|
|
124
124
|
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
125
125
|
}));
|
|
126
126
|
}
|
|
@@ -154,7 +154,7 @@
|
|
|
154
154
|
if (Object.getOwnPropertySymbols) {
|
|
155
155
|
var o = Object.getOwnPropertySymbols(e);
|
|
156
156
|
for (n = 0; n < o.length; n++) {
|
|
157
|
-
t = o[n], r.
|
|
157
|
+
t = o[n], -1 === r.indexOf(t) && {}.propertyIsEnumerable.call(e, t) && (i[t] = e[t]);
|
|
158
158
|
}
|
|
159
159
|
}
|
|
160
160
|
return i;
|
|
@@ -164,7 +164,7 @@
|
|
|
164
164
|
var t = {};
|
|
165
165
|
for (var n in e) {
|
|
166
166
|
if ({}.hasOwnProperty.call(e, n)) {
|
|
167
|
-
if (r.
|
|
167
|
+
if (-1 !== r.indexOf(n)) continue;
|
|
168
168
|
t[n] = e[n];
|
|
169
169
|
}
|
|
170
170
|
}
|
|
@@ -181,7 +181,7 @@
|
|
|
181
181
|
wrapCards: o().bool
|
|
182
182
|
};
|
|
183
183
|
function h(e) {
|
|
184
|
-
var r = e.alignCards, i = r === void 0 ? "left" : r, o = e.cardMaxWidth, a = e.cardMinWidth, c = e.cardWidth, l = e.children, f = e.elementRef,
|
|
184
|
+
var r = e.alignCards, i = r === void 0 ? "left" : r, o = e.cardMaxWidth, a = e.cardMinWidth, c = e.cardWidth, l = e.children, f = e.elementRef, s = e.gutterSize, y = s === void 0 ? 10 : s, b = e.style, m = e.wrapCards, v = m === void 0 ? true : m, O = g(e, [ "alignCards", "cardMaxWidth", "cardMinWidth", "cardWidth", "children", "elementRef", "gutterSize", "style", "wrapCards" ]);
|
|
185
185
|
// @docs-props-type CardLayoutPropsBase
|
|
186
186
|
var h = t.Children.toArray(l).filter(t.isValidElement).map((function(e) {
|
|
187
187
|
|
|
@@ -192,7 +192,7 @@
|
|
|
192
192
|
});
|
|
193
193
|
}));
|
|
194
194
|
|
|
195
|
-
return n().createElement(u,
|
|
195
|
+
return n().createElement(u, d({
|
|
196
196
|
"data-test": "card-layout",
|
|
197
197
|
$alignCards: i,
|
|
198
198
|
$wrapCards: v,
|
package/Checkbox.d.ts
ADDED
package/Checkbox.js
ADDED
|
@@ -0,0 +1,350 @@
|
|
|
1
|
+
/******/ (() => {
|
|
2
|
+
// webpackBootstrap
|
|
3
|
+
/******/ "use strict";
|
|
4
|
+
/******/ // The require scope
|
|
5
|
+
/******/ var e = {};
|
|
6
|
+
/******/
|
|
7
|
+
/************************************************************************/
|
|
8
|
+
/******/ /* webpack/runtime/compat get default export */
|
|
9
|
+
/******/ (() => {
|
|
10
|
+
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
|
11
|
+
/******/ e.n = r => {
|
|
12
|
+
/******/ var o = r && r.__esModule ?
|
|
13
|
+
/******/ () => r["default"]
|
|
14
|
+
/******/ : () => r
|
|
15
|
+
/******/;
|
|
16
|
+
e.d(o, {
|
|
17
|
+
a: o
|
|
18
|
+
});
|
|
19
|
+
/******/ return o;
|
|
20
|
+
/******/ };
|
|
21
|
+
/******/ })();
|
|
22
|
+
/******/
|
|
23
|
+
/******/ /* webpack/runtime/define property getters */
|
|
24
|
+
/******/ (() => {
|
|
25
|
+
/******/ // define getter functions for harmony exports
|
|
26
|
+
/******/ e.d = (r, o) => {
|
|
27
|
+
/******/ for (var t in o) {
|
|
28
|
+
/******/ if (e.o(o, t) && !e.o(r, t)) {
|
|
29
|
+
/******/ Object.defineProperty(r, t, {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
get: o[t]
|
|
32
|
+
});
|
|
33
|
+
/******/ }
|
|
34
|
+
/******/ }
|
|
35
|
+
/******/ };
|
|
36
|
+
/******/ })();
|
|
37
|
+
/******/
|
|
38
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
|
39
|
+
/******/ (() => {
|
|
40
|
+
/******/ e.o = (e, r) => Object.prototype.hasOwnProperty.call(e, r)
|
|
41
|
+
/******/;
|
|
42
|
+
})();
|
|
43
|
+
/******/
|
|
44
|
+
/******/ /* webpack/runtime/make namespace object */
|
|
45
|
+
/******/ (() => {
|
|
46
|
+
/******/ // define __esModule on exports
|
|
47
|
+
/******/ e.r = e => {
|
|
48
|
+
/******/ if (typeof Symbol !== "undefined" && Symbol.toStringTag) {
|
|
49
|
+
/******/ Object.defineProperty(e, Symbol.toStringTag, {
|
|
50
|
+
value: "Module"
|
|
51
|
+
});
|
|
52
|
+
/******/ }
|
|
53
|
+
/******/ Object.defineProperty(e, "__esModule", {
|
|
54
|
+
value: true
|
|
55
|
+
});
|
|
56
|
+
/******/ };
|
|
57
|
+
/******/ })();
|
|
58
|
+
/******/
|
|
59
|
+
/************************************************************************/ var r = {};
|
|
60
|
+
// ESM COMPAT FLAG
|
|
61
|
+
e.r(r);
|
|
62
|
+
// EXPORTS
|
|
63
|
+
e.d(r, {
|
|
64
|
+
default: () => /* reexport */ T
|
|
65
|
+
});
|
|
66
|
+
// CONCATENATED MODULE: external "react"
|
|
67
|
+
const o = require("react");
|
|
68
|
+
var t = e.n(o);
|
|
69
|
+
// CONCATENATED MODULE: external "lodash/pickBy"
|
|
70
|
+
const n = require("lodash/pickBy");
|
|
71
|
+
var a = e.n(n);
|
|
72
|
+
// CONCATENATED MODULE: external "prop-types"
|
|
73
|
+
const i = require("prop-types");
|
|
74
|
+
var l = e.n(i);
|
|
75
|
+
// CONCATENATED MODULE: external "@splunk/ui-utils/id"
|
|
76
|
+
const c = require("@splunk/ui-utils/id");
|
|
77
|
+
// CONCATENATED MODULE: external "styled-components"
|
|
78
|
+
const s = require("styled-components");
|
|
79
|
+
var d = e.n(s);
|
|
80
|
+
// CONCATENATED MODULE: external "@splunk/react-icons/CheckBoxCompleted"
|
|
81
|
+
const u = require("@splunk/react-icons/CheckBoxCompleted");
|
|
82
|
+
var b = e.n(u);
|
|
83
|
+
// CONCATENATED MODULE: external "@splunk/react-icons/CheckBoxIndeterminate"
|
|
84
|
+
const v = require("@splunk/react-icons/CheckBoxIndeterminate");
|
|
85
|
+
var f = e.n(v);
|
|
86
|
+
// CONCATENATED MODULE: external "@splunk/themes"
|
|
87
|
+
const p = require("@splunk/themes");
|
|
88
|
+
// CONCATENATED MODULE: ./src/Checkbox/CheckboxStyles.ts
|
|
89
|
+
var y = "5 5 16 16";
|
|
90
|
+
var h = "20px";
|
|
91
|
+
var m = d().input.attrs({
|
|
92
|
+
type: "checkbox"
|
|
93
|
+
}).withConfig({
|
|
94
|
+
displayName: "CheckboxStyles__StyledCheckbox",
|
|
95
|
+
componentId: "sc-1yo50j-0"
|
|
96
|
+
})([ "height:100%;margin:0;opacity:0;position:absolute;width:100%;cursor:pointer;&:disabled{cursor:not-allowed;}" ]);
|
|
97
|
+
var g = (0, s.css)([ "display:none;height:", ";width:", ";" ], h, h);
|
|
98
|
+
var k = d()(b()).attrs({
|
|
99
|
+
viewBox: y
|
|
100
|
+
}).withConfig({
|
|
101
|
+
displayName: "CheckboxStyles__StyledCheckIcon",
|
|
102
|
+
componentId: "sc-1yo50j-1"
|
|
103
|
+
})([ "", "" ], g);
|
|
104
|
+
var C = d()(f()).attrs({
|
|
105
|
+
viewBox: y
|
|
106
|
+
}).withConfig({
|
|
107
|
+
displayName: "CheckboxStyles__StyledIndeterminateIcon",
|
|
108
|
+
componentId: "sc-1yo50j-2"
|
|
109
|
+
})([ "", "" ], g);
|
|
110
|
+
var O = d().div.withConfig({
|
|
111
|
+
displayName: "CheckboxStyles__StyledCheckboxWrapper",
|
|
112
|
+
componentId: "sc-1yo50j-3"
|
|
113
|
+
})([ "display:inline-block;box-sizing:border-box;position:relative;width:", ";height:", ";line-height:", ";border-radius:", ";border:", " solid ", ";background-color:", ";cursor:pointer;flex:0 0 auto;&:has(", ":checked){", "{display:block;}}&:has(", ":indeterminate){", "{display:block;}}&:has(", ":focus){box-shadow:", ";}color:", ";", " &:has(", ":disabled){border-color:", ";background-color:", ";color:", ";cursor:not-allowed;&:has(", ":where(:checked,:indeterminate)){background-color:", ";border-color:", ";}}" ], h, h, h, p.variables.borderRadius, p.variables.inputBorderWidth, p.variables.interactiveColorBorder, p.variables.interactiveColorBackground, m, k, m, C, m, p.variables.focusShadow, (0,
|
|
114
|
+
p.pick)({
|
|
115
|
+
light: p.variables.white,
|
|
116
|
+
dark: p.variables.black
|
|
117
|
+
}), (function(e) {
|
|
118
|
+
var r = e.$error;
|
|
119
|
+
if (r) {
|
|
120
|
+
return (0, s.css)([ "border-color:", ";&:has(", ":where(:checked,:indeterminate)){background-color:", ";}" ], p.variables.interactiveColorAccentError, m, p.variables.interactiveColorAccentError);
|
|
121
|
+
}
|
|
122
|
+
return (0, s.css)([ "&:has(", ":where(:checked,:indeterminate)){background-color:", ";border-color:", ";}" ], m, p.variables.interactiveColorAccent, p.variables.interactiveColorAccent);
|
|
123
|
+
}), m, p.variables.interactiveColorBorderDisabled, p.variables.interactiveColorBackgroundDisabled, p.variables.contentColorDisabled, m, p.variables.neutral100, p.variables.interactiveColorBackgroundDisabled);
|
|
124
|
+
var w = d().label.withConfig({
|
|
125
|
+
displayName: "CheckboxStyles__StyledLabel",
|
|
126
|
+
componentId: "sc-1yo50j-4"
|
|
127
|
+
})([ "cursor:inherit;" ]);
|
|
128
|
+
var x = d().div.withConfig({
|
|
129
|
+
displayName: "CheckboxStyles__StyledWrapper",
|
|
130
|
+
componentId: "sc-1yo50j-5"
|
|
131
|
+
})([ "", ";position:relative;flex-shrink:0;gap:", ";min-height:", ";align-items:center;color:", ";cursor:pointer;:has(", ":disabled){color:", ";cursor:not-allowed;}&:not(:has(", ":disabled)){&:hover ", "{", "}}" ], p.mixins.reset("flex"), p.variables.spacingSmall, p.variables.inputHeight, p.variables.contentColorActive, m, p.variables.contentColorDisabled, m, O, (function(e) {
|
|
132
|
+
var r = e.$error;
|
|
133
|
+
if (r) {
|
|
134
|
+
return (0, s.css)([ ":has(", ":where(:checked,:indeterminate)){background-color:", ";border-color:", ";}border-color:", ";background-color:", ";" ], m, p.variables.interactiveColorAccentError, p.variables.interactiveColorAccentError, p.mixins.overlayColors(p.variables.interactiveColorAccentError, p.variables.interactiveColorBorderHover), p.mixins.overlayColors(p.variables.interactiveColorBackground, p.variables.interactiveColorOverlayHover));
|
|
135
|
+
}
|
|
136
|
+
return (0, s.css)([ ":has(", ":where(:checked,:indeterminate)){background-color:", ";border-color:", ";}border-color:", ";background-color:", ";" ], m, p.mixins.overlayColors(p.variables.interactiveColorAccent, p.variables.interactiveColorOverlayHover), p.variables.interactiveColorAccent, p.variables.interactiveColorBorderHover, p.mixins.overlayColors(p.variables.interactiveColorBackground, p.variables.interactiveColorOverlayHover));
|
|
137
|
+
}));
|
|
138
|
+
// CONCATENATED MODULE: ./src/utils/updateReactRef.ts
|
|
139
|
+
/**
|
|
140
|
+
* Updates a React ref. Callback refs and object refs (from `createRef` and `useRef`) are supported.
|
|
141
|
+
*
|
|
142
|
+
* @param ref - The React callback or object ref. Can be `null` or `undefined`.
|
|
143
|
+
* @param current - The new value of the ref.
|
|
144
|
+
*/
|
|
145
|
+
function j(e, r) {
|
|
146
|
+
if (e) {
|
|
147
|
+
if (typeof e === "function") {
|
|
148
|
+
e(r);
|
|
149
|
+
} else {
|
|
150
|
+
// the public signature of this util uses React.Ref<T> to mirror the way React types refs.
|
|
151
|
+
// the intention here is to signal "we will take care of setting 'current', not you".
|
|
152
|
+
e.current = r;
|
|
153
|
+
// eslint-disable-line no-param-reassign
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
// CONCATENATED MODULE: ./src/Checkbox/Checkbox.tsx
|
|
158
|
+
function S(e) {
|
|
159
|
+
"@babel/helpers - typeof";
|
|
160
|
+
return S = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
|
|
161
|
+
return typeof e;
|
|
162
|
+
} : function(e) {
|
|
163
|
+
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
164
|
+
}, S(e);
|
|
165
|
+
}
|
|
166
|
+
function B() {
|
|
167
|
+
return B = Object.assign ? Object.assign.bind() : function(e) {
|
|
168
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
169
|
+
var o = arguments[r];
|
|
170
|
+
for (var t in o) {
|
|
171
|
+
({}).hasOwnProperty.call(o, t) && (e[t] = o[t]);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
return e;
|
|
175
|
+
}, B.apply(null, arguments);
|
|
176
|
+
}
|
|
177
|
+
function P(e, r) {
|
|
178
|
+
var o = Object.keys(e);
|
|
179
|
+
if (Object.getOwnPropertySymbols) {
|
|
180
|
+
var t = Object.getOwnPropertySymbols(e);
|
|
181
|
+
r && (t = t.filter((function(r) {
|
|
182
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
183
|
+
}))), o.push.apply(o, t);
|
|
184
|
+
}
|
|
185
|
+
return o;
|
|
186
|
+
}
|
|
187
|
+
function E(e) {
|
|
188
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
189
|
+
var o = null != arguments[r] ? arguments[r] : {};
|
|
190
|
+
r % 2 ? P(Object(o), !0).forEach((function(r) {
|
|
191
|
+
I(e, r, o[r]);
|
|
192
|
+
})) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(o)) : P(Object(o)).forEach((function(r) {
|
|
193
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(o, r));
|
|
194
|
+
}));
|
|
195
|
+
}
|
|
196
|
+
return e;
|
|
197
|
+
}
|
|
198
|
+
function I(e, r, o) {
|
|
199
|
+
return (r = _(r)) in e ? Object.defineProperty(e, r, {
|
|
200
|
+
value: o,
|
|
201
|
+
enumerable: !0,
|
|
202
|
+
configurable: !0,
|
|
203
|
+
writable: !0
|
|
204
|
+
}) : e[r] = o, e;
|
|
205
|
+
}
|
|
206
|
+
function _(e) {
|
|
207
|
+
var r = D(e, "string");
|
|
208
|
+
return "symbol" == S(r) ? r : r + "";
|
|
209
|
+
}
|
|
210
|
+
function D(e, r) {
|
|
211
|
+
if ("object" != S(e) || !e) return e;
|
|
212
|
+
var o = e[Symbol.toPrimitive];
|
|
213
|
+
if (void 0 !== o) {
|
|
214
|
+
var t = o.call(e, r || "default");
|
|
215
|
+
if ("object" != S(t)) return t;
|
|
216
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
217
|
+
}
|
|
218
|
+
return ("string" === r ? String : Number)(e);
|
|
219
|
+
}
|
|
220
|
+
function q(e, r) {
|
|
221
|
+
if (null == e) return {};
|
|
222
|
+
var o, t, n = A(e, r);
|
|
223
|
+
if (Object.getOwnPropertySymbols) {
|
|
224
|
+
var a = Object.getOwnPropertySymbols(e);
|
|
225
|
+
for (t = 0; t < a.length; t++) {
|
|
226
|
+
o = a[t], -1 === r.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (n[o] = e[o]);
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
return n;
|
|
230
|
+
}
|
|
231
|
+
function A(e, r) {
|
|
232
|
+
if (null == e) return {};
|
|
233
|
+
var o = {};
|
|
234
|
+
for (var t in e) {
|
|
235
|
+
if ({}.hasOwnProperty.call(e, t)) {
|
|
236
|
+
if (-1 !== r.indexOf(t)) continue;
|
|
237
|
+
o[t] = e[t];
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
return o;
|
|
241
|
+
}
|
|
242
|
+
/** @public */ var M = {
|
|
243
|
+
checked: l().oneOf([ true, false, "indeterminate" ]),
|
|
244
|
+
children: l().node,
|
|
245
|
+
defaultChecked: l().bool,
|
|
246
|
+
describedBy: l().string,
|
|
247
|
+
disabled: l().bool,
|
|
248
|
+
elementRef: l().oneOfType([ l().func, l().object ]),
|
|
249
|
+
error: l().bool,
|
|
250
|
+
inert: l().bool,
|
|
251
|
+
inputRef: l().oneOfType([ l().func, l().object ]),
|
|
252
|
+
labelledBy: l().string,
|
|
253
|
+
name: l().string,
|
|
254
|
+
onChange: l().func,
|
|
255
|
+
/** @private. */
|
|
256
|
+
required: l().bool
|
|
257
|
+
};
|
|
258
|
+
var R = function e(r) {
|
|
259
|
+
var n = r.checked, i = r.children, l = r.defaultChecked, s = r.describedBy, d = r.disabled, u = r.elementRef, b = r.error, v = r.id, f = r.inert, p = r.inputRef, y = r.labelledBy, h = r.name, g = r.onChange, S = r.required, P = r.role, I = r.tabIndex, _ = r.value, D = q(r, [ "checked", "children", "defaultChecked", "describedBy", "disabled", "elementRef", "error", "id", "inert", "inputRef", "labelledBy", "name", "onChange", "required", "role", "tabIndex", "value" ]);
|
|
260
|
+
// @docs-props-type CheckboxPropsBase
|
|
261
|
+
// this component intentionally does not use useControlled because it uses React's checked/defaultChecked built-in instead
|
|
262
|
+
// https://react.dev/reference/react-dom/components/input#providing-an-initial-value-for-an-input
|
|
263
|
+
var A = (0, o.useCallback)((function(e) {
|
|
264
|
+
g === null || g === void 0 ? void 0 : g(e, {
|
|
265
|
+
checked: e.currentTarget.checked,
|
|
266
|
+
name: h,
|
|
267
|
+
value: e.currentTarget.value
|
|
268
|
+
});
|
|
269
|
+
}), [ h, g ]);
|
|
270
|
+
// If has internal label defined with children, must have an id and must use generated labelId.
|
|
271
|
+
// Otherwise, use customer defined id and external label.
|
|
272
|
+
var M = (0, o.useMemo)((function() {
|
|
273
|
+
return i && v == null ? (0, c.createDOMID)("checkbox-input") : v;
|
|
274
|
+
}), [ i, v ]);
|
|
275
|
+
var R = (0, o.useMemo)((function() {
|
|
276
|
+
return i ? (0, c.createDOMID)("checkbox-label") : y;
|
|
277
|
+
}), [ i, y ]);
|
|
278
|
+
var T = (0, o.useRef)(null);
|
|
279
|
+
var N = (0, o.useCallback)((function(e) {
|
|
280
|
+
j(T, e);
|
|
281
|
+
j(p, e);
|
|
282
|
+
}), [ p, T ]);
|
|
283
|
+
// useLayoutEffect is necessary to ensure that the checkbox is set to indeterminate before the browser paints
|
|
284
|
+
(0, o.useLayoutEffect)((function() {
|
|
285
|
+
if (T.current) {
|
|
286
|
+
// input type="checkbox" does not support indeterminate directly on the value prop - it needs to be set via JS
|
|
287
|
+
T.current.indeterminate = n === "indeterminate";
|
|
288
|
+
}
|
|
289
|
+
}), [ n ]);
|
|
290
|
+
var H = (0, o.useMemo)((function() {
|
|
291
|
+
return E(E({}, a()(D, (function(e, r) {
|
|
292
|
+
return r === "role" || r.indexOf("aria-") === 0;
|
|
293
|
+
}))), {}, {
|
|
294
|
+
"aria-describedby": s,
|
|
295
|
+
"aria-labelledby": R,
|
|
296
|
+
"aria-invalid": b || undefined
|
|
297
|
+
});
|
|
298
|
+
}), [ s, b, R, D ]);
|
|
299
|
+
var $ = {};
|
|
300
|
+
// a checkbox's value defaults to "on" if no value is passed
|
|
301
|
+
// so we cannot pass a value attribute if it is not specified
|
|
302
|
+
// to avoid overwriting the default when value is not set
|
|
303
|
+
if (_ != null) {
|
|
304
|
+
$.value = _;
|
|
305
|
+
}
|
|
306
|
+
// using React's checked/defaultChecked built-in, we cannot pass both props at once
|
|
307
|
+
if (n != null) {
|
|
308
|
+
// checked="indeterminate" is not a value Checkbox supports so handle it here
|
|
309
|
+
// specifically avoiding !!checked because Firefox will match :checked against an indeterminate checkbox with checked={true}
|
|
310
|
+
// this appears incorrect according to the spec: https://html.spec.whatwg.org/multipage/input.html#checkbox-state-(type=checkbox)
|
|
311
|
+
// which says: "If the element's indeterminate IDL attribute is set to true,
|
|
312
|
+
// then the control's selection should be obscured as if the control was in a third, indeterminate, state."
|
|
313
|
+
$.checked = n === true;
|
|
314
|
+
} else if (l != null) {
|
|
315
|
+
$.defaultChecked = l;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
return t().createElement(x, B({
|
|
319
|
+
"data-test": "checkbox",
|
|
320
|
+
"data-test-checked": n,
|
|
321
|
+
"data-test-disabled": d ? "disabled" : undefined,
|
|
322
|
+
"data-test-error": b ? true : undefined,
|
|
323
|
+
"data-test-value": _,
|
|
324
|
+
$error: b,
|
|
325
|
+
ref: u
|
|
326
|
+
}, D), t().createElement(O, {
|
|
327
|
+
$error: b
|
|
328
|
+
}, t().createElement(m, B({
|
|
329
|
+
disabled: d,
|
|
330
|
+
"data-test": f ? "presentation-toggle" : "toggle",
|
|
331
|
+
id: M,
|
|
332
|
+
inert: f ? "true" : undefined,
|
|
333
|
+
name: h,
|
|
334
|
+
onChange: A,
|
|
335
|
+
ref: N,
|
|
336
|
+
required: S,
|
|
337
|
+
role: f ? "presentation" : P,
|
|
338
|
+
tabIndex: I,
|
|
339
|
+
type: "checkbox"
|
|
340
|
+
}, H, $)), t().createElement(k, null), t().createElement(C, null)), i && t().createElement(w, {
|
|
341
|
+
"data-test": "label",
|
|
342
|
+
htmlFor: M,
|
|
343
|
+
id: R
|
|
344
|
+
}, i));
|
|
345
|
+
};
|
|
346
|
+
R.propTypes = M;
|
|
347
|
+
/* harmony default export */ const T = R;
|
|
348
|
+
// CONCATENATED MODULE: ./src/Checkbox/index.ts
|
|
349
|
+
module.exports = r;
|
|
350
|
+
/******/})();
|
package/Chip.js
CHANGED
|
@@ -82,8 +82,8 @@
|
|
|
82
82
|
// CONCATENATED MODULE: external "@splunk/ui-utils/i18n"
|
|
83
83
|
const v = require("@splunk/ui-utils/i18n");
|
|
84
84
|
// CONCATENATED MODULE: external "styled-components"
|
|
85
|
-
const
|
|
86
|
-
var
|
|
85
|
+
const f = require("styled-components");
|
|
86
|
+
var p = e.n(f);
|
|
87
87
|
// CONCATENATED MODULE: external "@splunk/react-icons/Cross"
|
|
88
88
|
const b = require("@splunk/react-icons/Cross");
|
|
89
89
|
var m = e.n(b);
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
// CONCATENATED MODULE: external "@splunk/themes"
|
|
94
94
|
const C = require("@splunk/themes");
|
|
95
95
|
// CONCATENATED MODULE: ./src/Chip/ChipStyles.ts
|
|
96
|
-
var h = (0,
|
|
96
|
+
var h = (0, f.css)([ "", ";", ";align-content:center;align-items:center;height:", ";max-width:100%;padding:", " ", ";column-gap:", ";background-color:", ";color:", ";border-radius:", ";", ";", ";" ], C.mixins.reset("grid"), C.mixins.typography("body"), C.variables.inputHeight, C.variables.spacingXSmall, C.variables.spacingSmall, C.variables.spacingXSmall, (0,
|
|
97
97
|
C.pickVariant)("$appearance", {
|
|
98
98
|
default: C.variables.neutral200,
|
|
99
99
|
outline: C.variables.transparent,
|
|
@@ -110,40 +110,40 @@
|
|
|
110
110
|
return n || (r === "default" || r === "outline" ? C.variables.contentColorActive : C.variables.contentColorInverted);
|
|
111
111
|
}), C.variables.borderRadius, (function(e) {
|
|
112
112
|
var r = e.$appearance;
|
|
113
|
-
return r === "outline" && (0,
|
|
113
|
+
return r === "outline" && (0, f.css)([ "border:1px solid ", ";" ], C.variables.borderColorStrong);
|
|
114
114
|
}), (function(e) {
|
|
115
115
|
var r = e.$appearance, n = e.$disabled;
|
|
116
|
-
return n && (0,
|
|
117
|
-
|
|
116
|
+
return n && (0, f.css)([ "background-color:", ";color:", ";", "" ], C.variables.neutral100, C.variables.contentColorDisabled, r === "outline" && (0,
|
|
117
|
+
f.css)([ "background-color:", ";border-color:", ";" ], C.variables.transparent, C.variables.borderColorWeak));
|
|
118
118
|
}));
|
|
119
|
-
var S =
|
|
119
|
+
var S = p().div.withConfig({
|
|
120
120
|
displayName: "ChipStyles__StyledNonInteractive",
|
|
121
121
|
componentId: "sc-1sd3tsh-0"
|
|
122
122
|
})([ "", " ", ";" ], h, (0, C.pickVariant)("$icon", {
|
|
123
|
-
true: (0,
|
|
124
|
-
false: (0,
|
|
123
|
+
true: (0, f.css)([ "grid-template-columns:[icon] min-content [label] auto;" ]),
|
|
124
|
+
false: (0, f.css)([ "grid-template-columns:[label] auto;" ])
|
|
125
125
|
}));
|
|
126
|
-
var $ =
|
|
126
|
+
var $ = p().div.withConfig({
|
|
127
127
|
displayName: "ChipStyles__StyledIcon",
|
|
128
128
|
componentId: "sc-1sd3tsh-1"
|
|
129
129
|
})([ "display:grid;grid-column:icon;" ]);
|
|
130
|
-
var k =
|
|
130
|
+
var k = p()(m()).withConfig({
|
|
131
131
|
displayName: "ChipStyles__StyledRemoveIcon",
|
|
132
132
|
componentId: "sc-1sd3tsh-2"
|
|
133
133
|
})([ "grid-column:remove;" ]);
|
|
134
|
-
var O =
|
|
134
|
+
var O = p().div.withConfig({
|
|
135
135
|
displayName: "ChipStyles__StyledLabel",
|
|
136
136
|
componentId: "sc-1sd3tsh-3"
|
|
137
137
|
})([ "", " grid-column:label;" ], C.mixins.ellipsis());
|
|
138
|
-
var R =
|
|
138
|
+
var R = p()(g()).withConfig({
|
|
139
139
|
displayName: "ChipStyles__StyledClickable",
|
|
140
140
|
componentId: "sc-1sd3tsh-4"
|
|
141
141
|
})([ "", " cursor:pointer;", ";", "" ], h, (0, C.pickVariant)("$icon", {
|
|
142
|
-
true: (0,
|
|
143
|
-
false: (0,
|
|
142
|
+
true: (0, f.css)([ "grid-template-columns:[icon] min-content [label] auto [remove] min-content;" ]),
|
|
143
|
+
false: (0, f.css)([ "grid-template-columns:[label] auto [remove] min-content;" ])
|
|
144
144
|
}), (function(e) {
|
|
145
145
|
var r = e.$disabled;
|
|
146
|
-
return !r && (0,
|
|
146
|
+
return !r && (0, f.css)([ "&:focus{box-shadow:", ";}&:hover{background-color:", ";}" ], C.variables.focusShadow, (0,
|
|
147
147
|
C.pickVariant)("$appearance", {
|
|
148
148
|
outline: C.variables.neutral100,
|
|
149
149
|
default: C.variables.neutral300,
|
|
@@ -170,26 +170,26 @@
|
|
|
170
170
|
}, w.apply(null, arguments);
|
|
171
171
|
}
|
|
172
172
|
function q(e, r) {
|
|
173
|
-
return E(e) ||
|
|
173
|
+
return E(e) || I(e, r) || j(e, r) || _();
|
|
174
174
|
}
|
|
175
175
|
function _() {
|
|
176
176
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
177
177
|
}
|
|
178
178
|
function j(e, r) {
|
|
179
179
|
if (e) {
|
|
180
|
-
if ("string" == typeof e) return
|
|
180
|
+
if ("string" == typeof e) return x(e, r);
|
|
181
181
|
var n = {}.toString.call(e).slice(8, -1);
|
|
182
|
-
return "Object" === n && e.constructor && (n = e.constructor.name), "Map" === n || "Set" === n ? Array.from(e) : "Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ?
|
|
182
|
+
return "Object" === n && e.constructor && (n = e.constructor.name), "Map" === n || "Set" === n ? Array.from(e) : "Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? x(e, r) : void 0;
|
|
183
183
|
}
|
|
184
184
|
}
|
|
185
|
-
function
|
|
185
|
+
function x(e, r) {
|
|
186
186
|
(null == r || r > e.length) && (r = e.length);
|
|
187
187
|
for (var n = 0, o = Array(r); n < r; n++) {
|
|
188
188
|
o[n] = e[n];
|
|
189
189
|
}
|
|
190
190
|
return o;
|
|
191
191
|
}
|
|
192
|
-
function
|
|
192
|
+
function I(e, r) {
|
|
193
193
|
var n = null == e ? null : "undefined" != typeof Symbol && e[Symbol.iterator] || e["@@iterator"];
|
|
194
194
|
if (null != n) {
|
|
195
195
|
var o, a, t, l, i = [], s = !0, c = !1;
|
|
@@ -220,7 +220,7 @@
|
|
|
220
220
|
if (Object.getOwnPropertySymbols) {
|
|
221
221
|
var t = Object.getOwnPropertySymbols(e);
|
|
222
222
|
for (o = 0; o < t.length; o++) {
|
|
223
|
-
n = t[o], r.
|
|
223
|
+
n = t[o], -1 === r.indexOf(n) && {}.propertyIsEnumerable.call(e, n) && (a[n] = e[n]);
|
|
224
224
|
}
|
|
225
225
|
}
|
|
226
226
|
return a;
|
|
@@ -230,7 +230,7 @@
|
|
|
230
230
|
var n = {};
|
|
231
231
|
for (var o in e) {
|
|
232
232
|
if ({}.hasOwnProperty.call(e, o)) {
|
|
233
|
-
if (r.
|
|
233
|
+
if (-1 !== r.indexOf(o)) continue;
|
|
234
234
|
n[o] = e[o];
|
|
235
235
|
}
|
|
236
236
|
}
|
|
@@ -268,13 +268,13 @@
|
|
|
268
268
|
}
|
|
269
269
|
function M(e) {
|
|
270
270
|
var r = T(e), a = q(r, 2), l = a[0], i = a[1];
|
|
271
|
-
var s = l.$appearance, u = l.$foregroundColor,
|
|
271
|
+
var s = l.$appearance, u = l.$foregroundColor, f = l.disabled, p = f === void 0 ? false : f, b = l.icon, m = N(l, [ "$appearance", "$foregroundColor", "disabled", "icon" ]);
|
|
272
272
|
var y = i.children, g = i.elementRef, C = i.onRequestRemove, h = i.value, S = N(i, [ "children", "elementRef", "onRequestRemove", "value" ]);
|
|
273
273
|
var _ = typeof y === "string";
|
|
274
274
|
var j = _ ? (0, d.sprintf)((0, v._)("Remove %(children)s"), {
|
|
275
275
|
children: y
|
|
276
276
|
}) : (0, v._)("Remove");
|
|
277
|
-
var
|
|
277
|
+
var x = (0, n.useCallback)((function(e) {
|
|
278
278
|
C(e, {
|
|
279
279
|
value: h
|
|
280
280
|
});
|
|
@@ -283,12 +283,12 @@
|
|
|
283
283
|
return o().createElement(R, w({
|
|
284
284
|
$appearance: s,
|
|
285
285
|
$icon: !!b,
|
|
286
|
-
$disabled:
|
|
286
|
+
$disabled: p,
|
|
287
287
|
$foregroundColor: u,
|
|
288
288
|
"data-test-value": h,
|
|
289
|
-
disabled:
|
|
289
|
+
disabled: p ? "disabled" : undefined,
|
|
290
290
|
elementRef: g,
|
|
291
|
-
onClick:
|
|
291
|
+
onClick: x
|
|
292
292
|
}, m, t()(S, Object.keys(P))), o().createElement(c(), null, j), b && o().createElement($, null, b), o().createElement(O, {
|
|
293
293
|
"data-test": "label",
|
|
294
294
|
"aria-hidden": _ ? true : undefined
|
|
@@ -299,7 +299,7 @@
|
|
|
299
299
|
function V(e) {
|
|
300
300
|
var r = T(e), n = q(r, 2), a = n[0], l = n[1];
|
|
301
301
|
var i = a.$appearance, s = a.$foregroundColor, c = a.disabled, u = a.icon, d = N(a, [ "$appearance", "$foregroundColor", "disabled", "icon" ]);
|
|
302
|
-
var v = l.children,
|
|
302
|
+
var v = l.children, f = l.elementRef, p = N(l, [ "children", "elementRef" ]);
|
|
303
303
|
|
|
304
304
|
return o().createElement(S, w({
|
|
305
305
|
$appearance: i,
|
|
@@ -307,8 +307,8 @@
|
|
|
307
307
|
$disabled: c !== null && c !== void 0 ? c : false,
|
|
308
308
|
$foregroundColor: s,
|
|
309
309
|
"data-test-disabled": c ? "disabled" : undefined,
|
|
310
|
-
ref:
|
|
311
|
-
}, d, t()(
|
|
310
|
+
ref: f
|
|
311
|
+
}, d, t()(p, Object.keys(P))), u && o().createElement($, null, u), o().createElement(O, {
|
|
312
312
|
"data-test": "label"
|
|
313
313
|
}, v));
|
|
314
314
|
}
|