@basic-ui/material 1.0.0-alpha.10 → 1.0.0-alpha.13
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/build/cjs/index.js +1165 -1290
- package/build/cjs/index.js.map +1 -1
- package/build/esm/Alert/Alert.d.ts +1 -1
- package/build/esm/Alert/Alert.js +2 -1
- package/build/esm/Alert/Alert.js.map +1 -1
- package/build/esm/Alert/index.d.ts +0 -0
- package/build/esm/Alert/index.js +0 -0
- package/build/esm/Alert/index.js.map +1 -1
- package/build/esm/AppBar/AppBar.d.ts +1 -1
- package/build/esm/AppBar/AppBar.js +4 -3
- package/build/esm/AppBar/AppBar.js.map +1 -1
- package/build/esm/AppBar/AppBarButton.d.ts +1 -1
- package/build/esm/AppBar/AppBarButton.js +2 -1
- package/build/esm/AppBar/AppBarButton.js.map +1 -1
- package/build/esm/AppBar/context.d.ts +0 -0
- package/build/esm/AppBar/context.js +0 -0
- package/build/esm/AppBar/context.js.map +1 -1
- package/build/esm/AppBar/index.d.ts +0 -0
- package/build/esm/AppBar/index.js +0 -0
- package/build/esm/AppBar/index.js.map +1 -1
- package/build/esm/Badge/Badge.d.ts +1 -1
- package/build/esm/Badge/Badge.js +0 -0
- package/build/esm/Badge/Badge.js.map +1 -1
- package/build/esm/Badge/index.d.ts +0 -0
- package/build/esm/Badge/index.js +0 -0
- package/build/esm/Badge/index.js.map +1 -1
- package/build/esm/BaseLine/BaseLine.d.ts +0 -1
- package/build/esm/BaseLine/BaseLine.js +0 -0
- package/build/esm/BaseLine/BaseLine.js.map +1 -1
- package/build/esm/BaseLine/index.d.ts +0 -0
- package/build/esm/BaseLine/index.js +0 -0
- package/build/esm/BaseLine/index.js.map +1 -1
- package/build/esm/BottomSheet/BottomSheet.d.ts +1 -1
- package/build/esm/BottomSheet/BottomSheet.js +2 -1
- package/build/esm/BottomSheet/BottomSheet.js.map +1 -1
- package/build/esm/BottomSheet/BottomSheetSurface.d.ts +1 -1
- package/build/esm/BottomSheet/BottomSheetSurface.js +2 -1
- package/build/esm/BottomSheet/BottomSheetSurface.js.map +1 -1
- package/build/esm/BottomSheet/index.d.ts +0 -0
- package/build/esm/BottomSheet/index.js +0 -0
- package/build/esm/BottomSheet/index.js.map +1 -1
- package/build/esm/Box/Box.d.ts +0 -0
- package/build/esm/Box/Box.js +0 -0
- package/build/esm/Box/Box.js.map +1 -1
- package/build/esm/Box/index.d.ts +0 -0
- package/build/esm/Box/index.js +0 -0
- package/build/esm/Box/index.js.map +1 -1
- package/build/esm/Button/BaseButton.d.ts +1 -1
- package/build/esm/Button/BaseButton.js +5 -4
- package/build/esm/Button/BaseButton.js.map +1 -1
- package/build/esm/Button/Button.d.ts +1 -1
- package/build/esm/Button/Button.js +6 -5
- package/build/esm/Button/Button.js.map +1 -1
- package/build/esm/Button/ButtonGroup.d.ts +1 -1
- package/build/esm/Button/ButtonGroup.js +2 -1
- package/build/esm/Button/ButtonGroup.js.map +1 -1
- package/build/esm/Button/FilledButton.d.ts +1 -1
- package/build/esm/Button/FilledButton.js +0 -0
- package/build/esm/Button/FilledButton.js.map +1 -1
- package/build/esm/Button/FloatingActionButton.d.ts +0 -0
- package/build/esm/Button/FloatingActionButton.js +1 -1
- package/build/esm/Button/FloatingActionButton.js.map +1 -1
- package/build/esm/Button/IconButton.d.ts +0 -0
- package/build/esm/Button/IconButton.js +1 -1
- package/build/esm/Button/IconButton.js.map +1 -1
- package/build/esm/Button/OutlinedButton.d.ts +1 -1
- package/build/esm/Button/OutlinedButton.js +0 -0
- package/build/esm/Button/OutlinedButton.js.map +1 -1
- package/build/esm/Button/TransparentButton.d.ts +1 -1
- package/build/esm/Button/TransparentButton.js +0 -0
- package/build/esm/Button/TransparentButton.js.map +1 -1
- package/build/esm/Button/context.d.ts +0 -0
- package/build/esm/Button/context.js +0 -0
- package/build/esm/Button/context.js.map +1 -1
- package/build/esm/Button/index.d.ts +0 -0
- package/build/esm/Button/index.js +0 -0
- package/build/esm/Button/index.js.map +1 -1
- package/build/esm/CheckBox/CheckBox.d.ts +1 -1
- package/build/esm/CheckBox/CheckBox.js +6 -4
- package/build/esm/CheckBox/CheckBox.js.map +1 -1
- package/build/esm/CheckBox/CheckBoxIcon.d.ts +1 -1
- package/build/esm/CheckBox/CheckBoxIcon.js +4 -3
- package/build/esm/CheckBox/CheckBoxIcon.js.map +1 -1
- package/build/esm/CheckBox/CheckPath.d.ts +0 -1
- package/build/esm/CheckBox/CheckPath.js +0 -0
- package/build/esm/CheckBox/CheckPath.js.map +1 -1
- package/build/esm/CheckBox/IndeterminatePath.d.ts +0 -1
- package/build/esm/CheckBox/IndeterminatePath.js +0 -0
- package/build/esm/CheckBox/IndeterminatePath.js.map +1 -1
- package/build/esm/CheckBox/index.d.ts +0 -0
- package/build/esm/CheckBox/index.js +0 -0
- package/build/esm/CheckBox/index.js.map +1 -1
- package/build/esm/Chip/ButtonChip.d.ts +1 -1
- package/build/esm/Chip/ButtonChip.js +4 -3
- package/build/esm/Chip/ButtonChip.js.map +1 -1
- package/build/esm/Chip/Chip.d.ts +0 -0
- package/build/esm/Chip/Chip.js +0 -0
- package/build/esm/Chip/Chip.js.map +1 -1
- package/build/esm/Chip/ChipBase.d.ts +1 -1
- package/build/esm/Chip/ChipBase.js +10 -9
- package/build/esm/Chip/ChipBase.js.map +1 -1
- package/build/esm/Chip/ChoiceChip.d.ts +1 -1
- package/build/esm/Chip/ChoiceChip.js +6 -4
- package/build/esm/Chip/ChoiceChip.js.map +1 -1
- package/build/esm/Chip/index.d.ts +0 -0
- package/build/esm/Chip/index.js +0 -0
- package/build/esm/Chip/index.js.map +1 -1
- package/build/esm/Combobox/Combobox.d.ts +7 -7
- package/build/esm/Combobox/Combobox.js +18 -10
- package/build/esm/Combobox/Combobox.js.map +1 -1
- package/build/esm/Combobox/index.d.ts +0 -0
- package/build/esm/Combobox/index.js +0 -0
- package/build/esm/Combobox/index.js.map +1 -1
- package/build/esm/Dialog/Dialog.d.ts +1 -1
- package/build/esm/Dialog/Dialog.js +6 -5
- package/build/esm/Dialog/Dialog.js.map +1 -1
- package/build/esm/Dialog/DialogBackdrop.d.ts +1 -1
- package/build/esm/Dialog/DialogBackdrop.js +2 -1
- package/build/esm/Dialog/DialogBackdrop.js.map +1 -1
- package/build/esm/Dialog/DialogContainer.d.ts +1 -1
- package/build/esm/Dialog/DialogContainer.js +2 -1
- package/build/esm/Dialog/DialogContainer.js.map +1 -1
- package/build/esm/Dialog/DialogSurface.d.ts +1 -1
- package/build/esm/Dialog/DialogSurface.js +4 -3
- package/build/esm/Dialog/DialogSurface.js.map +1 -1
- package/build/esm/Dialog/Scrim.d.ts +1 -1
- package/build/esm/Dialog/Scrim.js +2 -1
- package/build/esm/Dialog/Scrim.js.map +1 -1
- package/build/esm/Dialog/index.d.ts +0 -0
- package/build/esm/Dialog/index.js +1 -0
- package/build/esm/Dialog/index.js.map +1 -1
- package/build/esm/Dialog/useDialogAnimation.d.ts +0 -0
- package/build/esm/Dialog/useDialogAnimation.js +3 -2
- package/build/esm/Dialog/useDialogAnimation.js.map +1 -1
- package/build/esm/Divider/Divider.d.ts +1 -1
- package/build/esm/Divider/Divider.js +7 -6
- package/build/esm/Divider/Divider.js.map +1 -1
- package/build/esm/Divider/index.d.ts +0 -0
- package/build/esm/Divider/index.js +0 -0
- package/build/esm/Divider/index.js.map +1 -1
- package/build/esm/FloatingLabel/FloatingLabel.d.ts +0 -0
- package/build/esm/FloatingLabel/FloatingLabel.js +4 -3
- package/build/esm/FloatingLabel/FloatingLabel.js.map +1 -1
- package/build/esm/FloatingLabel/index.d.ts +0 -0
- package/build/esm/FloatingLabel/index.js +0 -0
- package/build/esm/FloatingLabel/index.js.map +1 -1
- package/build/esm/LineRipple/LineRipple.d.ts +1 -1
- package/build/esm/LineRipple/LineRipple.js +3 -2
- package/build/esm/LineRipple/LineRipple.js.map +1 -1
- package/build/esm/LineRipple/index.d.ts +0 -0
- package/build/esm/LineRipple/index.js +0 -0
- package/build/esm/LineRipple/index.js.map +1 -1
- package/build/esm/Link/Link.d.ts +1 -1
- package/build/esm/Link/Link.js +2 -1
- package/build/esm/Link/Link.js.map +1 -1
- package/build/esm/Link/index.d.ts +0 -0
- package/build/esm/Link/index.js +0 -0
- package/build/esm/Link/index.js.map +1 -1
- package/build/esm/List/List.d.ts +1 -1
- package/build/esm/List/List.js +2 -1
- package/build/esm/List/List.js.map +1 -1
- package/build/esm/List/index.d.ts +0 -0
- package/build/esm/List/index.js +0 -0
- package/build/esm/List/index.js.map +1 -1
- package/build/esm/ListItem/ListItem.d.ts +1 -1
- package/build/esm/ListItem/ListItem.js +4 -3
- package/build/esm/ListItem/ListItem.js.map +1 -1
- package/build/esm/ListItem/ListItemText.d.ts +0 -0
- package/build/esm/ListItem/ListItemText.js +4 -3
- package/build/esm/ListItem/ListItemText.js.map +1 -1
- package/build/esm/ListItem/index.d.ts +0 -0
- package/build/esm/ListItem/index.js +0 -0
- package/build/esm/ListItem/index.js.map +1 -1
- package/build/esm/Menu/Menu.d.ts +4 -4
- package/build/esm/Menu/Menu.js +8 -4
- package/build/esm/Menu/Menu.js.map +1 -1
- package/build/esm/Menu/animation.d.ts +0 -0
- package/build/esm/Menu/animation.js +0 -0
- package/build/esm/Menu/animation.js.map +1 -1
- package/build/esm/Menu/index.d.ts +0 -0
- package/build/esm/Menu/index.js +0 -0
- package/build/esm/Menu/index.js.map +1 -1
- package/build/esm/NavRail/NavRailItem.d.ts +3 -3
- package/build/esm/NavRail/NavRailItem.js +15 -12
- package/build/esm/NavRail/NavRailItem.js.map +1 -1
- package/build/esm/NavRail/index.d.ts +0 -0
- package/build/esm/NavRail/index.js +0 -0
- package/build/esm/NavRail/index.js.map +1 -1
- package/build/esm/NotchedOutline/NotchedOutline.d.ts +0 -0
- package/build/esm/NotchedOutline/NotchedOutline.js +4 -3
- package/build/esm/NotchedOutline/NotchedOutline.js.map +1 -1
- package/build/esm/NotchedOutline/context.d.ts +0 -0
- package/build/esm/NotchedOutline/context.js +0 -0
- package/build/esm/NotchedOutline/context.js.map +1 -1
- package/build/esm/NotchedOutline/index.d.ts +0 -0
- package/build/esm/NotchedOutline/index.js +0 -0
- package/build/esm/NotchedOutline/index.js.map +1 -1
- package/build/esm/NotchedOutline/styledComponents.d.ts +0 -27
- package/build/esm/NotchedOutline/styledComponents.js +0 -0
- package/build/esm/NotchedOutline/styledComponents.js.map +1 -1
- package/build/esm/Paper/Paper.d.ts +1 -1
- package/build/esm/Paper/Paper.js +6 -5
- package/build/esm/Paper/Paper.js.map +1 -1
- package/build/esm/Paper/index.d.ts +0 -0
- package/build/esm/Paper/index.js +0 -0
- package/build/esm/Paper/index.js.map +1 -1
- package/build/esm/ProgressSpinner/ProgressSpinner.d.ts +1 -1
- package/build/esm/ProgressSpinner/ProgressSpinner.js +12 -13
- package/build/esm/ProgressSpinner/ProgressSpinner.js.map +1 -1
- package/build/esm/ProgressSpinner/index.d.ts +0 -0
- package/build/esm/ProgressSpinner/index.js +0 -0
- package/build/esm/ProgressSpinner/index.js.map +1 -1
- package/build/esm/RadioButton/RadioButton.d.ts +0 -0
- package/build/esm/RadioButton/RadioButton.js +4 -2
- package/build/esm/RadioButton/RadioButton.js.map +1 -1
- package/build/esm/RadioButton/RadioButtonIcon.d.ts +0 -0
- package/build/esm/RadioButton/RadioButtonIcon.js +4 -3
- package/build/esm/RadioButton/RadioButtonIcon.js.map +1 -1
- package/build/esm/RadioButton/RadioGroup.d.ts +1 -1
- package/build/esm/RadioButton/RadioGroup.js +2 -1
- package/build/esm/RadioButton/RadioGroup.js.map +1 -1
- package/build/esm/RadioButton/index.d.ts +0 -0
- package/build/esm/RadioButton/index.js +0 -0
- package/build/esm/RadioButton/index.js.map +1 -1
- package/build/esm/Ripple/Ripple.d.ts +0 -0
- package/build/esm/Ripple/Ripple.js +0 -0
- package/build/esm/Ripple/Ripple.js.map +1 -1
- package/build/esm/Ripple/RippleBox.d.ts +0 -0
- package/build/esm/Ripple/RippleBox.js +7 -5
- package/build/esm/Ripple/RippleBox.js.map +1 -1
- package/build/esm/Ripple/constants.d.ts +0 -0
- package/build/esm/Ripple/constants.js +0 -0
- package/build/esm/Ripple/constants.js.map +1 -1
- package/build/esm/Ripple/index.d.ts +0 -0
- package/build/esm/Ripple/index.js +0 -0
- package/build/esm/Ripple/index.js.map +1 -1
- package/build/esm/Ripple/keyframes.d.ts +0 -0
- package/build/esm/Ripple/keyframes.js +0 -0
- package/build/esm/Ripple/keyframes.js.map +1 -1
- package/build/esm/Ripple/useRipple.d.ts +0 -0
- package/build/esm/Ripple/useRipple.js +2 -2
- package/build/esm/Ripple/useRipple.js.map +1 -1
- package/build/esm/Ripple/useRippleHandlers.d.ts +0 -0
- package/build/esm/Ripple/useRippleHandlers.js +2 -1
- package/build/esm/Ripple/useRippleHandlers.js.map +1 -1
- package/build/esm/Ripple/useRippleSurface.d.ts +0 -0
- package/build/esm/Ripple/useRippleSurface.js +6 -5
- package/build/esm/Ripple/useRippleSurface.js.map +1 -1
- package/build/esm/Select/Select.d.ts +1 -1
- package/build/esm/Select/Select.js +5 -4
- package/build/esm/Select/Select.js.map +1 -1
- package/build/esm/Select/SelectIcon.d.ts +1 -1
- package/build/esm/Select/SelectIcon.js +4 -3
- package/build/esm/Select/SelectIcon.js.map +1 -1
- package/build/esm/Select/context.d.ts +0 -0
- package/build/esm/Select/context.js +0 -0
- package/build/esm/Select/context.js.map +1 -1
- package/build/esm/Select/defaultRender.d.ts +1 -1
- package/build/esm/Select/defaultRender.js +0 -0
- package/build/esm/Select/defaultRender.js.map +1 -1
- package/build/esm/Select/index.d.ts +0 -0
- package/build/esm/Select/index.js +0 -0
- package/build/esm/Select/index.js.map +1 -1
- package/build/esm/Select/styledComponents.d.ts +0 -0
- package/build/esm/Select/styledComponents.js +8 -5
- package/build/esm/Select/styledComponents.js.map +1 -1
- package/build/esm/SelectItem/SelectItem.d.ts +1 -1
- package/build/esm/SelectItem/SelectItem.js +6 -5
- package/build/esm/SelectItem/SelectItem.js.map +1 -1
- package/build/esm/SelectItem/index.d.ts +0 -0
- package/build/esm/SelectItem/index.js +0 -0
- package/build/esm/SelectItem/index.js.map +1 -1
- package/build/esm/SelectionControl/SelectionControlLabel.d.ts +1 -1
- package/build/esm/SelectionControl/SelectionControlLabel.js +2 -1
- package/build/esm/SelectionControl/SelectionControlLabel.js.map +1 -1
- package/build/esm/SelectionControl/SelectionControlText.d.ts +1 -1
- package/build/esm/SelectionControl/SelectionControlText.js +4 -3
- package/build/esm/SelectionControl/SelectionControlText.js.map +1 -1
- package/build/esm/SelectionControl/index.d.ts +0 -0
- package/build/esm/SelectionControl/index.js +0 -0
- package/build/esm/SelectionControl/index.js.map +1 -1
- package/build/esm/Skeleton/DelayAppearance.d.ts +1 -1
- package/build/esm/Skeleton/DelayAppearance.js +2 -1
- package/build/esm/Skeleton/DelayAppearance.js.map +1 -1
- package/build/esm/Skeleton/Skeleton.d.ts +1 -1
- package/build/esm/Skeleton/Skeleton.js +4 -3
- package/build/esm/Skeleton/Skeleton.js.map +1 -1
- package/build/esm/Skeleton/animation.d.ts +0 -0
- package/build/esm/Skeleton/animation.js +0 -0
- package/build/esm/Skeleton/animation.js.map +1 -1
- package/build/esm/Skeleton/index.d.ts +0 -0
- package/build/esm/Skeleton/index.js +0 -0
- package/build/esm/Skeleton/index.js.map +1 -1
- package/build/esm/Snackbar/Snackbar.d.ts +1 -1
- package/build/esm/Snackbar/Snackbar.js +8 -7
- package/build/esm/Snackbar/Snackbar.js.map +1 -1
- package/build/esm/Snackbar/Stack.d.ts +0 -0
- package/build/esm/Snackbar/Stack.js +4 -2
- package/build/esm/Snackbar/Stack.js.map +1 -1
- package/build/esm/Snackbar/index.d.ts +0 -0
- package/build/esm/Snackbar/index.js +0 -0
- package/build/esm/Snackbar/index.js.map +1 -1
- package/build/esm/Snackbar/useSnackbarAnimation.d.ts +0 -0
- package/build/esm/Snackbar/useSnackbarAnimation.js +6 -6
- package/build/esm/Snackbar/useSnackbarAnimation.js.map +1 -1
- package/build/esm/Switch/Switch.d.ts +1 -1
- package/build/esm/Switch/Switch.js +6 -4
- package/build/esm/Switch/Switch.js.map +1 -1
- package/build/esm/Switch/index.d.ts +0 -0
- package/build/esm/Switch/index.js +0 -0
- package/build/esm/Switch/index.js.map +1 -1
- package/build/esm/Switch/styledComponents.d.ts +0 -1
- package/build/esm/Switch/styledComponents.js +6 -3
- package/build/esm/Switch/styledComponents.js.map +1 -1
- package/build/esm/Tab/Tab.d.ts +1 -1
- package/build/esm/Tab/Tab.js +6 -4
- package/build/esm/Tab/Tab.js.map +1 -1
- package/build/esm/Tab/TabList.d.ts +1 -1
- package/build/esm/Tab/TabList.js +4 -2
- package/build/esm/Tab/TabList.js.map +1 -1
- package/build/esm/Tab/TabPanel.d.ts +1 -1
- package/build/esm/Tab/TabPanel.js +4 -2
- package/build/esm/Tab/TabPanel.js.map +1 -1
- package/build/esm/Tab/TabPanels.d.ts +0 -0
- package/build/esm/Tab/TabPanels.js +0 -0
- package/build/esm/Tab/TabPanels.js.map +1 -1
- package/build/esm/Tab/Tabs.d.ts +0 -0
- package/build/esm/Tab/Tabs.js +0 -0
- package/build/esm/Tab/Tabs.js.map +1 -1
- package/build/esm/Tab/context.d.ts +0 -0
- package/build/esm/Tab/context.js +0 -0
- package/build/esm/Tab/context.js.map +1 -1
- package/build/esm/Tab/index.d.ts +0 -0
- package/build/esm/Tab/index.js +0 -0
- package/build/esm/Tab/index.js.map +1 -1
- package/build/esm/TabIndicator/TabIndicator.d.ts +1 -1
- package/build/esm/TabIndicator/TabIndicator.js +2 -1
- package/build/esm/TabIndicator/TabIndicator.js.map +1 -1
- package/build/esm/TabIndicator/context.d.ts +0 -0
- package/build/esm/TabIndicator/context.js +0 -0
- package/build/esm/TabIndicator/context.js.map +1 -1
- package/build/esm/TabIndicator/index.d.ts +0 -0
- package/build/esm/TabIndicator/index.js +0 -0
- package/build/esm/TabIndicator/index.js.map +1 -1
- package/build/esm/Table/Table.d.ts +1 -1
- package/build/esm/Table/Table.js +4 -3
- package/build/esm/Table/Table.js.map +1 -1
- package/build/esm/Table/TableBody.d.ts +1 -1
- package/build/esm/Table/TableBody.js +4 -3
- package/build/esm/Table/TableBody.js.map +1 -1
- package/build/esm/Table/TableCell.d.ts +1 -1
- package/build/esm/Table/TableCell.js +4 -3
- package/build/esm/Table/TableCell.js.map +1 -1
- package/build/esm/Table/TableHead.d.ts +1 -1
- package/build/esm/Table/TableHead.js +4 -3
- package/build/esm/Table/TableHead.js.map +1 -1
- package/build/esm/Table/TableRow.d.ts +1 -1
- package/build/esm/Table/TableRow.js +4 -3
- package/build/esm/Table/TableRow.js.map +1 -1
- package/build/esm/Table/context.d.ts +0 -0
- package/build/esm/Table/context.js +0 -0
- package/build/esm/Table/context.js.map +1 -1
- package/build/esm/Table/index.d.ts +0 -0
- package/build/esm/Table/index.js +0 -0
- package/build/esm/Table/index.js.map +1 -1
- package/build/esm/Text/LoremIpsum.d.ts +0 -0
- package/build/esm/Text/LoremIpsum.js +0 -0
- package/build/esm/Text/LoremIpsum.js.map +1 -1
- package/build/esm/Text/Text.d.ts +1 -1
- package/build/esm/Text/Text.js +2 -1
- package/build/esm/Text/Text.js.map +1 -1
- package/build/esm/Text/index.d.ts +0 -0
- package/build/esm/Text/index.js +0 -0
- package/build/esm/Text/index.js.map +1 -1
- package/build/esm/TextField/FilledContainer.d.ts +1 -1
- package/build/esm/TextField/FilledContainer.js +6 -5
- package/build/esm/TextField/FilledContainer.js.map +1 -1
- package/build/esm/TextField/HelperText.d.ts +1 -1
- package/build/esm/TextField/HelperText.js +4 -3
- package/build/esm/TextField/HelperText.js.map +1 -1
- package/build/esm/TextField/IconContainer.d.ts +0 -0
- package/build/esm/TextField/IconContainer.js +0 -0
- package/build/esm/TextField/IconContainer.js.map +1 -1
- package/build/esm/TextField/Input.d.ts +1 -1
- package/build/esm/TextField/Input.js +9 -8
- package/build/esm/TextField/Input.js.map +1 -1
- package/build/esm/TextField/OutlinedContainer.d.ts +1 -1
- package/build/esm/TextField/OutlinedContainer.js +5 -4
- package/build/esm/TextField/OutlinedContainer.js.map +1 -1
- package/build/esm/TextField/TextField.d.ts +1 -1
- package/build/esm/TextField/TextField.js +4 -3
- package/build/esm/TextField/TextField.js.map +1 -1
- package/build/esm/TextField/consts.d.ts +0 -0
- package/build/esm/TextField/consts.js +0 -0
- package/build/esm/TextField/consts.js.map +1 -1
- package/build/esm/TextField/index.d.ts +0 -0
- package/build/esm/TextField/index.js +0 -0
- package/build/esm/TextField/index.js.map +1 -1
- package/build/esm/ThemeExplorer/ColorPicker.d.ts +0 -0
- package/build/esm/ThemeExplorer/ColorPicker.js +4 -3
- package/build/esm/ThemeExplorer/ColorPicker.js.map +1 -1
- package/build/esm/ThemeExplorer/TextFieldColorPicker.d.ts +0 -0
- package/build/esm/ThemeExplorer/TextFieldColorPicker.js +4 -3
- package/build/esm/ThemeExplorer/TextFieldColorPicker.js.map +1 -1
- package/build/esm/ThemeExplorer/ThemeBuilder.d.ts +9 -0
- package/build/esm/ThemeExplorer/ThemeBuilder.js +244 -0
- package/build/esm/ThemeExplorer/ThemeBuilder.js.map +1 -0
- package/build/esm/ThemeExplorer/ThemeColors.d.ts +0 -0
- package/build/esm/ThemeExplorer/ThemeColors.js +0 -0
- package/build/esm/ThemeExplorer/ThemeColors.js.map +1 -1
- package/build/esm/ThemeExplorer/components.d.ts +1 -1
- package/build/esm/ThemeExplorer/components.js +24 -21
- package/build/esm/ThemeExplorer/components.js.map +1 -1
- package/build/esm/ThemeExplorer/index.d.ts +1 -0
- package/build/esm/ThemeExplorer/index.js +2 -0
- package/build/esm/ThemeExplorer/index.js.map +1 -0
- package/build/esm/ThemeExplorer/makeColorScheme.d.ts +0 -0
- package/build/esm/ThemeExplorer/makeColorScheme.js +1 -2
- package/build/esm/ThemeExplorer/makeColorScheme.js.map +1 -1
- package/build/esm/ThemeExplorer/useDeferredColor.d.ts +0 -0
- package/build/esm/ThemeExplorer/useDeferredColor.js +5 -7
- package/build/esm/ThemeExplorer/useDeferredColor.js.map +1 -1
- package/build/esm/ThemeExplorer/useLocalStorageCachedState.d.ts +1 -1
- package/build/esm/ThemeExplorer/useLocalStorageCachedState.js +1 -1
- package/build/esm/ThemeExplorer/useLocalStorageCachedState.js.map +1 -1
- package/build/esm/Tooltip/Tooltip.d.ts +1 -1
- package/build/esm/Tooltip/Tooltip.js +2 -1
- package/build/esm/Tooltip/Tooltip.js.map +1 -1
- package/build/esm/Tooltip/index.d.ts +0 -0
- package/build/esm/Tooltip/index.js +0 -0
- package/build/esm/Tooltip/index.js.map +1 -1
- package/build/esm/color.d.ts +0 -0
- package/build/esm/color.js +1 -1
- package/build/esm/color.js.map +1 -1
- package/build/esm/css.d.ts +0 -0
- package/build/esm/css.js +0 -0
- package/build/esm/css.js.map +1 -1
- package/build/esm/hooks/useAnimation.d.ts +0 -0
- package/build/esm/hooks/useAnimation.js +3 -3
- package/build/esm/hooks/useAnimation.js.map +1 -1
- package/build/esm/index.d.ts +0 -1
- package/build/esm/index.js +0 -1
- package/build/esm/index.js.map +1 -1
- package/build/esm/motion.d.ts +0 -0
- package/build/esm/motion.js +0 -0
- package/build/esm/motion.js.map +1 -1
- package/build/esm/theme/index.d.ts +0 -0
- package/build/esm/theme/index.js +0 -0
- package/build/esm/theme/index.js.map +1 -1
- package/build/esm/theme/theme.d.ts +0 -27
- package/build/esm/theme/theme.js +4 -31
- package/build/esm/theme/theme.js.map +1 -1
- package/build/esm/theme/typography-raleway.d.ts +0 -0
- package/build/esm/theme/typography-raleway.js +0 -0
- package/build/esm/theme/typography-raleway.js.map +1 -1
- package/build/esm/theme/typography-roboto.d.ts +0 -0
- package/build/esm/theme/typography-roboto.js +0 -0
- package/build/esm/theme/typography-roboto.js.map +1 -1
- package/build/esm/theme/useTheme.d.ts +557 -1
- package/build/esm/theme/useTheme.js +0 -0
- package/build/esm/theme/useTheme.js.map +1 -1
- package/build/tsconfig-build.tsbuildinfo +1 -1
- package/package.json +5 -5
- package/src/CheckBox/CheckBox.story.tsx +5 -4
- package/src/ProgressSpinner/ProgressSpinner.tsx +7 -7
- package/src/Snackbar/Snackbar.tsx +3 -3
- package/src/ThemeExplorer/ThemeBuilder.story.tsx +1 -163
- package/src/ThemeExplorer/ThemeBuilder.tsx +198 -0
- package/src/ThemeExplorer/components.tsx +24 -21
- package/src/ThemeExplorer/index.ts +1 -0
- package/src/ThemeExplorer/makeColorScheme.tsx +1 -1
- package/src/ThemeExplorer/useDeferredColor.tsx +3 -4
- package/src/ThemeExplorer/useLocalStorageCachedState.ts +2 -2
- package/src/Tooltip/Tooltip.story.tsx +1 -1
- package/src/color.ts +1 -1
- package/src/index.ts +0 -1
- package/src/theme/theme.ts +4 -31
- package/build/esm/ColorMode/ColorModeProvider.d.ts +0 -7
- package/build/esm/ColorMode/ColorModeProvider.js +0 -91
- package/build/esm/ColorMode/ColorModeProvider.js.map +0 -1
- package/build/esm/ColorMode/color-mode.d.ts +0 -8
- package/build/esm/ColorMode/color-mode.js +0 -11
- package/build/esm/ColorMode/color-mode.js.map +0 -1
- package/build/esm/ColorMode/color-vars.d.ts +0 -4
- package/build/esm/ColorMode/color-vars.js +0 -58
- package/build/esm/ColorMode/color-vars.js.map +0 -1
- package/build/esm/ColorMode/constants.d.ts +0 -3
- package/build/esm/ColorMode/constants.js +0 -5
- package/build/esm/ColorMode/constants.js.map +0 -1
- package/build/esm/ColorMode/index.d.ts +0 -4
- package/build/esm/ColorMode/index.js +0 -5
- package/build/esm/ColorMode/index.js.map +0 -1
- package/build/esm/ListItem/context.d.ts +0 -7
- package/build/esm/ListItem/context.js +0 -10
- package/build/esm/ListItem/context.js.map +0 -1
- package/build/tsconfig.tsbuildinfo +0 -1
- package/src/ColorMode/ColorModeProvider.tsx +0 -97
- package/src/ColorMode/color-mode.ts +0 -20
- package/src/ColorMode/color-vars.ts +0 -56
- package/src/ColorMode/constants.ts +0 -5
- package/src/ColorMode/index.ts +0 -4
- package/src/ColorMode/tests/color-vars.test.ts +0 -9
|
@@ -14,4 +14,4 @@ export interface OutlinedContainerProps extends BoxProps {
|
|
|
14
14
|
forceActive?: boolean;
|
|
15
15
|
leadingIcon?: boolean;
|
|
16
16
|
}
|
|
17
|
-
export declare const OutlinedContainer: import("react").ForwardRefExoticComponent<Pick<OutlinedContainerProps, "
|
|
17
|
+
export declare const OutlinedContainer: import("react").ForwardRefExoticComponent<Pick<OutlinedContainerProps, "boxShadow" | "fontWeight" | "zIndex" | "alignContent" | "alignItems" | "alignSelf" | "backgroundColor" | "backgroundImage" | "backgroundPosition" | "backgroundRepeat" | "backgroundSize" | "borderBottomColor" | "borderBottomLeftRadius" | "borderBottomRightRadius" | "borderBottomStyle" | "borderBottomWidth" | "borderLeftColor" | "borderLeftStyle" | "borderLeftWidth" | "borderRightColor" | "borderRightStyle" | "borderRightWidth" | "borderTopColor" | "borderTopLeftRadius" | "borderTopRightRadius" | "borderTopStyle" | "borderTopWidth" | "bottom" | "color" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBottom" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "order" | "overflowX" | "overflowY" | "paddingBottom" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "textAlign" | "textShadow" | "top" | "translate" | "verticalAlign" | "width" | "background" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderStyle" | "borderTop" | "borderWidth" | "flex" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "overflow" | "padding" | "bg" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "p" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "variant" | "size" | "hidden" | "as" | "sx" | "__css" | "tx" | "theme" | "borderX" | "borderY" | "gridGap" | "gridColumnGap" | "gridRowGap" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "label" | "error" | "disabled" | "leadingIcon" | "hasFocus" | "labelIsFloating" | "inputId" | "forceActive"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
+
var _excluded = ["label", "labelIsFloating", "inputId", "forceActive", "children", "error", "color", "leadingIcon"];
|
|
4
5
|
import { forwardRef, useEffect, useLayoutEffect, useState, useRef } from 'react';
|
|
5
6
|
import { NotchedOutline } from '../NotchedOutline';
|
|
6
7
|
import { Box } from '../Box';
|
|
@@ -19,7 +20,7 @@ export var OutlinedContainer = /*#__PURE__*/forwardRef(function OutlinedContaine
|
|
|
19
20
|
_props$color = props.color,
|
|
20
21
|
colorProp = _props$color === void 0 ? 'primary' : _props$color,
|
|
21
22
|
leadingIcon = props.leadingIcon,
|
|
22
|
-
otherProps = _objectWithoutProperties(props,
|
|
23
|
+
otherProps = _objectWithoutProperties(props, _excluded);
|
|
23
24
|
|
|
24
25
|
var _useState = useState(0),
|
|
25
26
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -34,7 +35,7 @@ export var OutlinedContainer = /*#__PURE__*/forwardRef(function OutlinedContaine
|
|
|
34
35
|
var _document, _document$fonts, _document$fonts$ready;
|
|
35
36
|
|
|
36
37
|
setLabelWidth(element.offsetWidth);
|
|
37
|
-
(_document = document)
|
|
38
|
+
(_document = document) === null || _document === void 0 ? void 0 : (_document$fonts = _document.fonts) === null || _document$fonts === void 0 ? void 0 : (_document$fonts$ready = _document$fonts.ready) === null || _document$fonts$ready === void 0 ? void 0 : _document$fonts$ready.then(function () {
|
|
38
39
|
// set the label width again once the fonts have been loaded
|
|
39
40
|
requestAnimationFrame(function () {
|
|
40
41
|
setLabelWidth(element.offsetWidth);
|
|
@@ -44,10 +45,10 @@ export var OutlinedContainer = /*#__PURE__*/forwardRef(function OutlinedContaine
|
|
|
44
45
|
}, [label]);
|
|
45
46
|
var color = error ? 'error' : colorProp;
|
|
46
47
|
var inputHeight = 56;
|
|
47
|
-
return /*#__PURE__*/_jsx(Box, _extends({
|
|
48
|
+
return /*#__PURE__*/_jsx(Box, _extends(_extends({
|
|
48
49
|
position: "relative",
|
|
49
50
|
lineHeight: 0
|
|
50
|
-
}, otherProps, {
|
|
51
|
+
}, otherProps), {}, {
|
|
51
52
|
children: /*#__PURE__*/_jsx(NotchedOutline, {
|
|
52
53
|
ref: forwardedRef,
|
|
53
54
|
borderRadius: 4,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"OutlinedContainer.js","names":["forwardRef","useEffect","useLayoutEffect","useState","useRef","NotchedOutline","Box","FloatingLabel","ICON_WIDTH","PADDING_LEFT_WITHOUT_ICON","PADDING_LEFT_WITH_ICON","useEnhancedEffect","window","OutlinedContainer","props","forwardedRef","label","labelIsFloating","inputId","forceActive","children","error","color","colorProp","leadingIcon","otherProps","labelWidth","setLabelWidth","labelRef","element","current","offsetWidth","document","fonts","ready","then","requestAnimationFrame","inputHeight"],"sources":["../../../src/TextField/OutlinedContainer.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport {\n forwardRef,\n useEffect,\n useLayoutEffect,\n useState,\n useRef,\n} from 'react';\n\nimport { NotchedOutline } from '../NotchedOutline';\nimport type { BoxProps } from '../Box';\nimport { Box } from '../Box';\nimport { FloatingLabel } from '../FloatingLabel';\nimport type { Theme } from '../theme';\nimport {\n ICON_WIDTH,\n PADDING_LEFT_WITHOUT_ICON,\n PADDING_LEFT_WITH_ICON,\n} from './consts';\n\nconst useEnhancedEffect =\n typeof window !== 'undefined' ? useLayoutEffect : useEffect;\n\nexport interface OutlinedContainerProps extends BoxProps {\n children?: ReactNode;\n label?: ReactNode;\n color?: string;\n error?: boolean;\n theme: Theme;\n labelIsFloating: boolean;\n hasFocus: boolean;\n inputId: string;\n disabled?: boolean;\n forceActive?: boolean;\n leadingIcon?: boolean;\n}\n\nexport const OutlinedContainer = forwardRef<\n HTMLDivElement,\n OutlinedContainerProps\n>(function OutlinedContainer(props, forwardedRef) {\n const {\n label,\n labelIsFloating,\n inputId,\n forceActive = false,\n children,\n error,\n color: colorProp = 'primary',\n leadingIcon,\n ...otherProps\n } = props;\n const [labelWidth, setLabelWidth] = useState(0);\n const labelRef = useRef<HTMLLabelElement>(null);\n\n useEnhancedEffect(() => {\n const element = labelRef.current;\n\n if (element) {\n setLabelWidth(element.offsetWidth);\n (document as any)?.fonts?.ready?.then(() => {\n // set the label width again once the fonts have been loaded\n requestAnimationFrame(() => {\n setLabelWidth(element.offsetWidth);\n });\n });\n }\n }, [label]);\n\n const color = error ? 'error' : colorProp;\n const inputHeight = 56;\n\n return (\n <Box position=\"relative\" lineHeight={0} {...otherProps}>\n <NotchedOutline\n ref={forwardedRef}\n borderRadius={4}\n borderColor={color}\n borderWidth={1}\n notchActive={forceActive || labelIsFloating}\n notchWidth={labelWidth * 0.75}\n notchStart={16}\n forceActive={forceActive || error}\n label={\n label && (\n <FloatingLabel\n height={inputHeight}\n offsetX={\n leadingIcon\n ? PADDING_LEFT_WITH_ICON +\n ICON_WIDTH +\n PADDING_LEFT_WITHOUT_ICON\n : PADDING_LEFT_WITHOUT_ICON\n }\n translateX={\n leadingIcon ? -(PADDING_LEFT_WITH_ICON + ICON_WIDTH) : 0\n }\n active={forceActive || labelIsFloating}\n ref={labelRef}\n htmlFor={inputId}\n >\n {label}\n </FloatingLabel>\n )\n }\n >\n {children}\n </NotchedOutline>\n </Box>\n );\n});\n"],"mappings":";;;;AACA,SACEA,UADF,EAEEC,SAFF,EAGEC,eAHF,EAIEC,QAJF,EAKEC,MALF,QAMO,OANP;AAQA,SAASC,cAAT,QAA+B,mBAA/B;AAEA,SAASC,GAAT,QAAoB,QAApB;AACA,SAASC,aAAT,QAA8B,kBAA9B;AAEA,SACEC,UADF,EAEEC,yBAFF,EAGEC,sBAHF,QAIO,UAJP;;AAMA,IAAMC,iBAAiB,GACrB,OAAOC,MAAP,KAAkB,WAAlB,GAAgCV,eAAhC,GAAkDD,SADpD;AAiBA,OAAO,IAAMY,iBAAiB,gBAAGb,UAAU,CAGzC,SAASa,iBAAT,CAA2BC,KAA3B,EAAkCC,YAAlC,EAAgD;EAChD,IACEC,KADF,GAUIF,KAVJ,CACEE,KADF;EAAA,IAEEC,eAFF,GAUIH,KAVJ,CAEEG,eAFF;EAAA,IAGEC,OAHF,GAUIJ,KAVJ,CAGEI,OAHF;EAAA,yBAUIJ,KAVJ,CAIEK,WAJF;EAAA,IAIEA,WAJF,mCAIgB,KAJhB;EAAA,IAKEC,QALF,GAUIN,KAVJ,CAKEM,QALF;EAAA,IAMEC,KANF,GAUIP,KAVJ,CAMEO,KANF;EAAA,mBAUIP,KAVJ,CAOEQ,KAPF;EAAA,IAOSC,SAPT,6BAOqB,SAPrB;EAAA,IAQEC,WARF,GAUIV,KAVJ,CAQEU,WARF;EAAA,IASKC,UATL,4BAUIX,KAVJ;;EAWA,gBAAoCX,QAAQ,CAAC,CAAD,CAA5C;EAAA;EAAA,IAAOuB,UAAP;EAAA,IAAmBC,aAAnB;;EACA,I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GI;IAhCH;EADF,GADF;AAsCD,CAzE0C,CAApC"}
|
|
@@ -16,4 +16,4 @@ export declare type TextFieldProps = Omit<InputProps, 'value' | 'defaultValue'>
|
|
|
16
16
|
leadingIcon?: ReactNode;
|
|
17
17
|
trailingIcon?: ReactNode;
|
|
18
18
|
};
|
|
19
|
-
export declare const TextField: import("react").ForwardRefExoticComponent<Pick<TextFieldProps, "
|
|
19
|
+
export declare const TextField: import("react").ForwardRefExoticComponent<Pick<TextFieldProps, "boxShadow" | "fontWeight" | "zIndex" | "alignContent" | "alignItems" | "alignSelf" | "backgroundColor" | "backgroundImage" | "backgroundPosition" | "backgroundRepeat" | "backgroundSize" | "borderBottomColor" | "borderBottomLeftRadius" | "borderBottomRightRadius" | "borderBottomStyle" | "borderBottomWidth" | "borderLeftColor" | "borderLeftStyle" | "borderLeftWidth" | "borderRightColor" | "borderRightStyle" | "borderRightWidth" | "borderTopColor" | "borderTopLeftRadius" | "borderTopRightRadius" | "borderTopStyle" | "borderTopWidth" | "bottom" | "color" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBottom" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "order" | "overflowX" | "overflowY" | "paddingBottom" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "textAlign" | "textShadow" | "top" | "translate" | "verticalAlign" | "width" | "background" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderStyle" | "borderTop" | "borderWidth" | "flex" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "overflow" | "padding" | "bg" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "p" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "variant" | "size" | "hidden" | "as" | "sx" | "__css" | "tx" | "theme" | "borderX" | "borderY" | "gridGap" | "gridColumnGap" | "gridRowGap" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "value" | "form" | "label" | "pattern" | "list" | "error" | "step" | "autoFocus" | "disabled" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "name" | "type" | "multiple" | "alt" | "autoComplete" | "accept" | "capture" | "checked" | "maxLength" | "minLength" | "src" | "crossOrigin" | "enterKeyHint" | "max" | "min" | "readOnly" | "required" | "multiline" | "hasLabel" | "leadingIcon" | "trailingIcon" | "containerProps" | "helperText" | "hideCharacterCounter"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
+
var _excluded = ["type", "id", "variant", "color", "value", "defaultValue", "error", "disabled", "maxLength", "hideCharacterCounter", "label", "placeholder", "helperText", "multiline", "onChange", "onFocus", "onBlur", "leadingIcon", "trailingIcon", "containerProps"];
|
|
4
5
|
import { forwardRef, useState, useId } from 'react';
|
|
5
6
|
import { wrapEvent, useControlledState } from '@basic-ui/core';
|
|
6
7
|
import { Input } from './Input';
|
|
@@ -54,7 +55,7 @@ export var TextField = /*#__PURE__*/forwardRef(function TextField(props, forward
|
|
|
54
55
|
_props$trailingIcon = props.trailingIcon,
|
|
55
56
|
trailingIcon = _props$trailingIcon === void 0 ? null : _props$trailingIcon,
|
|
56
57
|
containerProps = props.containerProps,
|
|
57
|
-
otherProps = _objectWithoutProperties(props,
|
|
58
|
+
otherProps = _objectWithoutProperties(props, _excluded);
|
|
58
59
|
|
|
59
60
|
var _useControlledState = useControlledState(valueProp, onChangeProp, defaultValue, function (setState) {
|
|
60
61
|
return function (e) {
|
|
@@ -92,7 +93,7 @@ export var TextField = /*#__PURE__*/forwardRef(function TextField(props, forward
|
|
|
92
93
|
display: "inline-flex",
|
|
93
94
|
flexDirection: "column",
|
|
94
95
|
width: "100%",
|
|
95
|
-
children: [/*#__PURE__*/_jsxs(Container, _extends({
|
|
96
|
+
children: [/*#__PURE__*/_jsxs(Container, _extends(_extends({
|
|
96
97
|
theme: theme,
|
|
97
98
|
label: label,
|
|
98
99
|
color: color,
|
|
@@ -102,7 +103,7 @@ export var TextField = /*#__PURE__*/forwardRef(function TextField(props, forward
|
|
|
102
103
|
hasFocus: hasFocus,
|
|
103
104
|
disabled: disabled,
|
|
104
105
|
leadingIcon: Boolean(leadingIcon)
|
|
105
|
-
}, containerProps, {
|
|
106
|
+
}, containerProps), {}, {
|
|
106
107
|
children: [leadingIcon && /*#__PURE__*/_jsx(IconContainer, {
|
|
107
108
|
position: "start",
|
|
108
109
|
children: leadingIcon
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"TextField.js","names":["forwardRef","useState","useId","wrapEvent","useControlledState","Input","useTheme","FilledContainer","OutlinedContainer","HelperText","Box","IconContainer","componentMap","outlined","filled","characterCounter","value","maxLength","undefined","length","TextField","props","forwardedRef","type","idProp","id","variant","color","valueProp","defaultValue","error","disabled","hideCharacterCounter","label","placeholder","helperTextProp","helperText","multiline","onChangeProp","onChange","onFocus","onBlur","leadingIcon","trailingIcon","containerProps","otherProps","setState","e","target","hasFocus","setHasFocus","Container","fallbackId","theme","handleFocus","handleBlur","hasError","Boolean","inputId","helperTextId","labelIsFloating"],"sources":["../../../src/TextField/TextField.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport { forwardRef, useState, useId } from 'react';\nimport { wrapEvent, useControlledState } from '@basic-ui/core';\n\nimport type { InputProps } from './Input';\nimport { Input } from './Input';\nimport { useTheme } from '../theme';\nimport { FilledContainer } from './FilledContainer';\nimport { OutlinedContainer } from './OutlinedContainer';\nimport { HelperText } from './HelperText';\nimport type { BoxProps } from '../Box';\nimport { Box } from '../Box';\nimport { IconContainer } from './IconContainer';\n\nconst componentMap = {\n outlined: OutlinedContainer,\n filled: FilledContainer,\n};\n\nfunction characterCounter(\n value: string | number | string[],\n maxLength?: number\n) {\n if (maxLength === undefined) {\n return null;\n }\n\n return `${typeof value === 'string' ? value.length : 0} / ${maxLength}`;\n}\n\nexport type TextFieldProps = Omit<InputProps, 'value' | 'defaultValue'> & {\n variant?: 'outlined' | 'filled';\n containerProps?: Omit<BoxProps, 'color'>;\n color?: 'primary' | 'secondary';\n label?: ReactNode;\n helperText?: string;\n maxLength?: number;\n hideCharacterCounter?: boolean;\n defaultValue?: string;\n value?: string;\n multiline?: boolean;\n error?: boolean | string;\n leadingIcon?: ReactNode;\n trailingIcon?: ReactNode;\n};\n\nexport const TextField = forwardRef<HTMLInputElement, TextFieldProps>(\n function TextField(props, forwardedRef) {\n const {\n type = 'text',\n id: idProp,\n variant = 'outlined',\n color = 'primary',\n value: valueProp,\n defaultValue = '',\n error,\n disabled,\n maxLength,\n hideCharacterCounter = false,\n label = null,\n placeholder,\n helperText: helperTextProp,\n multiline,\n onChange: onChangeProp,\n onFocus,\n onBlur,\n leadingIcon = null,\n trailingIcon = null,\n containerProps,\n ...otherProps\n } = props;\n const [value, onChange] = useControlledState(\n valueProp,\n onChangeProp,\n defaultValue,\n (setState) => (e) => {\n setState(e.target.value);\n }\n );\n const [hasFocus, setHasFocus] = useState(false);\n\n const Container = componentMap[variant] || OutlinedContainer;\n\n const fallbackId = useId();\n\n const theme = useTheme();\n\n const handleFocus = () => {\n setHasFocus(true);\n };\n\n const handleBlur = () => {\n setHasFocus(false);\n };\n\n const hasError = Boolean(error);\n const helperText = typeof error === 'string' ? error : helperTextProp;\n\n const id = idProp || fallbackId;\n const inputId = `${id}-text-field`;\n const helperTextId = helperText ? `${id}-helper-text` : undefined;\n\n const labelIsFloating =\n hasFocus || (typeof value === 'string' && value.length > 0);\n\n return (\n <Box display=\"inline-flex\" flexDirection=\"column\" width=\"100%\">\n <Container\n theme={theme}\n label={label}\n color={color}\n error={hasError}\n labelIsFloating={labelIsFloating}\n inputId={inputId}\n hasFocus={hasFocus}\n disabled={disabled}\n leadingIcon={Boolean(leadingIcon)}\n {...containerProps}\n >\n {leadingIcon && (\n <IconContainer position=\"start\">{leadingIcon}</IconContainer>\n )}\n <Input\n ref={forwardedRef}\n as={multiline ? 'textarea' : 'input'}\n variant={variant}\n type={type}\n id={inputId}\n onFocus={wrapEvent(onFocus, handleFocus)}\n onBlur={wrapEvent(onBlur, handleBlur)}\n onChange={onChange}\n value={value}\n theme={theme}\n placeholder={placeholder}\n disabled={disabled}\n aria-disabled={disabled ? 'true' : undefined}\n maxLength={maxLength}\n multiline={multiline}\n aria-describedby={helperTextId}\n hasLabel={!!label}\n leadingIcon={Boolean(leadingIcon)}\n trailingIcon={Boolean(trailingIcon)}\n {...otherProps}\n />\n {trailingIcon && (\n <IconContainer position=\"end\">{trailingIcon}</IconContainer>\n )}\n </Container>\n\n <HelperText\n error={hasError}\n disabled={disabled}\n leftSide={helperText && <span id={helperTextId}>{helperText}</span>}\n rightSide={\n !hideCharacterCounter &&\n characterCounter(value as string, maxLength)\n }\n />\n </Box>\n );\n }\n);\n"],"mappings":";;;;AACA,SAASA,UAAT,EAAqBC,QAArB,EAA+BC,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AD,EAAUc,WAAV,CANpB;QAOE,MAAM,EAAEnD,SAAS,CAACsC,MAAD,EAASc,UAAT,CAPnB;QAQE,QAAQ,EAAEhB,QARZ;QASE,KAAK,EAAEvB,KATT;QAUE,KAAK,EAAEqC,KAVT;QAWE,WAAW,EAAEnB,WAXf;QAYE,QAAQ,EAAEH,QAZZ;QAaE,iBAAeA,QAAQ,GAAG,MAAH,GAAYb,SAbrC;QAcE,SAAS,EAAED,SAdb;QAeE,SAAS,EAAEoB,SAfb;QAgBE,oBAAkBsB,YAhBpB;QAiBE,QAAQ,EAAE,CAAC,CAAC1B,KAjBd;QAkBE,WAAW,EAAEwB,OAAO,CAACf,WAAD,CAlBtB;QAmBE,YAAY,EAAEe,OAAO,CAACd,YAAD;MAnBvB,GAoBME,UApBN,EAfF,EAqCGF,YAAY,iBACX,KAAC,aAAD;QAAe,QAAQ,EAAC,KAAxB;QAAA,UAA+BA;MAA/B,EAtCJ;IAAA,GADF,eA2CE,KAAC,UAAD;MACE,KAAK,EAAEa,QADT;MAEE,QAAQ,EAAEzB,QAFZ;MAGE,QAAQ,EAAEK,UAAU,iBAAI;QAAM,EAAE,EAAEuB,YAAV;QAAA,UAAyBvB;MAAzB,EAH1B;MAIE,SAAS,EACP,CAACJ,oBAAD,IACAjB,gBAAgB,CAACC,KAAD,EAAkBC,SAAlB;IANpB,EA3CF;EAAA,EADF;AAuDD,CAlHgC,CAA5B"}
|
|
File without changes
|
|
File without changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"consts.js","names":["PADDING_LEFT_WITH_ICON","PADDING_LEFT_WITHOUT_ICON","ICON_WIDTH","PADDING_RIGHT_WITH_ICON","PADDING_RIGHT_WITHOUT_ICON"],"sources":["../../../src/TextField/consts.ts"],"sourcesContent":["export const PADDING_LEFT_WITH_ICON = 14;\nexport const PADDING_LEFT_WITHOUT_ICON = 16;\n\nexport const ICON_WIDTH = 24;\n\nexport const PADDING_RIGHT_WITH_ICON = 12;\nexport const PADDING_RIGHT_WITHOUT_ICON = 16;\n"],"mappings":"AAAA,OAAO,IAAMA,sBAAsB,GAAG,EAA/B;AACP,OAAO,IAAMC,yBAAyB,GAAG,EAAlC;AAEP,OAAO,IAAMC,UAAU,GAAG,EAAnB;AAEP,OAAO,IAAMC,uBAAuB,GAAG,EAAhC;AACP,OAAO,IAAMC,0BAA0B,GAAG,EAAnC"}
|
|
File without changes
|
|
File without changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../src/TextField/index.ts"],"sourcesContent":["export * from './TextField';\nexport * from './FilledContainer';\nexport * from './OutlinedContainer';\nexport * from './HelperText';\n"],"mappings":"AAAA,cAAc,aAAd;AACA,cAAc,mBAAd;AACA,cAAc,qBAAd;AACA,cAAc,cAAd"}
|
|
File without changes
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["color", "onChange", "width", "height"];
|
|
3
4
|
import { ColorPicker as _BaseColorPicker, Hue as _Hue, HueCursor as _HueCursor, Saturation as _Saturation, SaturationCursor as _SaturationCursor } from '@basic-ui/color-picker';
|
|
4
5
|
import { Box } from '../Box';
|
|
5
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -16,15 +17,15 @@ export var ColorPicker = function ColorPicker(_ref) {
|
|
|
16
17
|
width = _ref$width === void 0 ? 450 : _ref$width,
|
|
17
18
|
_ref$height = _ref.height,
|
|
18
19
|
height = _ref$height === void 0 ? 225 : _ref$height,
|
|
19
|
-
otherProps = _objectWithoutProperties(_ref,
|
|
20
|
+
otherProps = _objectWithoutProperties(_ref, _excluded);
|
|
20
21
|
|
|
21
|
-
return /*#__PURE__*/_jsxs(BaseColorPicker, _extends({
|
|
22
|
+
return /*#__PURE__*/_jsxs(BaseColorPicker, _extends(_extends({
|
|
22
23
|
as: Box,
|
|
23
24
|
width: width,
|
|
24
25
|
height: height,
|
|
25
26
|
onChange: onChange,
|
|
26
27
|
color: color
|
|
27
|
-
}, otherProps, {
|
|
28
|
+
}, otherProps), {}, {
|
|
28
29
|
children: [/*#__PURE__*/_jsx(Saturation, {
|
|
29
30
|
as: Box,
|
|
30
31
|
sx: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"ColorPicker.js","names":["ColorPicker","_BaseColorPicker","Hue","_Hue","HueCursor","_HueCursor","Saturation","_Saturation","SaturationCursor","_SaturationCursor","Box","BaseColorPicker","color","onChange","width","height","otherProps","position","touchAction","userSelect","backgroundImage","border","borderRadius","boxShadow","boxSizing","transform"],"sources":["../../../src/ThemeExplorer/ColorPicker.tsx"],"sourcesContent":["import type {\n Color,\n ColorPickerProps as BaseColorPickerProps,\n HueProps,\n HueCursorProps,\n SaturationProps,\n SaturationCursorProps,\n} from '@basic-ui/color-picker';\nimport {\n ColorPicker as _BaseColorPicker,\n Hue as _Hue,\n HueCursor as _HueCursor,\n Saturation as _Saturation,\n SaturationCursor as _SaturationCursor,\n} from '@basic-ui/color-picker';\nimport type { FC } from 'react';\n\nimport type { BoxProps } from '../Box';\nimport { Box } from '../Box';\n\nexport type ColorPickerProps = (Omit<BoxProps, 'color' | 'onChange'> &\n BaseColorPickerProps) & {\n color: Color;\n onChange: (color: Color) => void;\n};\n\nconst BaseColorPicker: FC<\n Omit<BoxProps, 'color' | 'onChange'> & BaseColorPickerProps\n> = _BaseColorPicker as any;\nconst Hue: FC<BoxProps & HueProps> = _Hue as any;\nconst HueCursor: FC<BoxProps & HueCursorProps> = _HueCursor as any;\nconst Saturation: FC<BoxProps & SaturationProps> = _Saturation as any;\nconst SaturationCursor: FC<BoxProps & SaturationCursorProps> =\n _SaturationCursor as any;\n\nexport const ColorPicker: FC<ColorPickerProps> = ({\n color,\n onChange,\n width = 450,\n height = 225,\n ...otherProps\n}) => {\n return (\n <BaseColorPicker\n as={Box}\n width={width}\n height={height}\n onChange={onChange}\n color={color}\n {...otherProps}\n >\n <Saturation\n as={Box}\n sx={{\n position: 'relative',\n touchAction: 'none',\n userSelect: 'none',\n width: '100%',\n backgroundImage:\n 'linear-gradient(transparent, black), linear-gradient(to right, white, transparent)',\n }}\n >\n <SaturationCursor\n as={Box}\n sx={{\n position: 'absolute',\n width: '20px',\n height: '20px',\n border: '2px solid #ffffff',\n borderRadius: 'full',\n boxShadow: '0 0 15px 0 rgba(0, 0, 0, 0.15)',\n boxSizing: 'border-box',\n transform: 'translate(-10px, -10px)',\n }}\n />\n </Saturation>\n <Hue\n as={Box}\n sx={{\n position: 'relative',\n touchAction: 'none',\n userSelect: 'none',\n width: '100%',\n height: '12px',\n backgroundImage: `linear-gradient(to right, rgb(255, 0, 0), rgb(255, 255, 0), rgb(0, 255, 0), rgb(0, 255, 255), rgb(0, 0, 255), rgb(255, 0, 255), rgb(255, 0, 0))`,\n }}\n >\n <HueCursor\n as={Box}\n sx={{\n position: 'absolute',\n width: '20px',\n height: '20px',\n border: '2px solid #ffffff',\n borderRadius: 'full',\n boxShadow: 'rgba(0, 0, 0, 0.2) 0px 0px 0px 0.5px',\n boxSizing: 'border-box',\n transform: 'translate(-10px, -4px)',\n }}\n />\n </Hue>\n </BaseColorPicker>\n );\n};\n"],"mappings":";;;AAQA,SACEA,WAAW,IAAIC,gBADjB,EAEEC,GAAG,IAAIC,IAFT,EAGEC,SAAS,IAAIC,UAHf,EAIEC,UAAU,IAAIC,WAJhB,EAKEC,gBAAgB,IAAIC,iBALtB,QAMO,wBANP;AAUA,SAASC,GAAT,QAAoB,QAApB;;;AAQA,IAAMC,eAEL,GAAGV,gBAFJ;AAGA,IAAMC,GAA4B,GAAGC,IAArC;AACA,IAAMC,SAAwC,GAAGC,UAAjD;AACA,IAAMC,UAA0C,GAAGC,WAAnD;AACA,IAAMC,gBAAsD,GAC1DC,iBADF;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M,MAAM,EAAE,mBAJN;UAKFC,YAAY,EAAE,MALZ;UAMFC,SAAS,EAAE,sCANT;UAOFC,SAAS,EAAE,YAPT;UAQFC,SAAS,EAAE;QART;MAFN;IAXF,EAjCF;EAAA,GADF;AA6DD,CApEM"}
|
|
File without changes
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
+
var _excluded = ["value", "defaultValue", "onChange", "disabled"];
|
|
4
5
|
import { toColor } from '@basic-ui/color-picker';
|
|
5
6
|
import { Popper, useControlledState, useOnClickOutside } from '@basic-ui/core';
|
|
6
7
|
import { useRef, useState, memo, useCallback } from 'react';
|
|
@@ -15,14 +16,14 @@ export var TextFieldColorPicker = /*#__PURE__*/memo(function (props) {
|
|
|
15
16
|
defaultValue = _props$defaultValue === void 0 ? toColor('hex', '#33ff33') : _props$defaultValue,
|
|
16
17
|
onChangeProp = props.onChange,
|
|
17
18
|
disabled = props.disabled,
|
|
18
|
-
otherProps = _objectWithoutProperties(props,
|
|
19
|
+
otherProps = _objectWithoutProperties(props, _excluded);
|
|
19
20
|
|
|
20
21
|
var _useState = useState(false),
|
|
21
22
|
_useState2 = _slicedToArray(_useState, 2),
|
|
22
23
|
popoverOpen = _useState2[0],
|
|
23
24
|
setPopoverOpen = _useState2[1];
|
|
24
25
|
|
|
25
|
-
var _useState3 = useState((valueProp
|
|
26
|
+
var _useState3 = useState((valueProp === null || valueProp === void 0 ? void 0 : valueProp.hex) || defaultValue.hex),
|
|
26
27
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
27
28
|
text = _useState4[0],
|
|
28
29
|
setText = _useState4[1];
|
|
@@ -47,7 +48,7 @@ export var TextFieldColorPicker = /*#__PURE__*/memo(function (props) {
|
|
|
47
48
|
var popoverRef = useRef(null);
|
|
48
49
|
var buttonRef = useRef(null);
|
|
49
50
|
useOnClickOutside(popoverRef, function (e) {
|
|
50
|
-
if (e.target === (buttonRef
|
|
51
|
+
if (e.target === (buttonRef === null || buttonRef === void 0 ? void 0 : buttonRef.current)) {
|
|
51
52
|
return;
|
|
52
53
|
}
|
|
53
54
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"TextFieldColorPicker.js","names":["toColor","Popper","useControlledState","useOnClickOutside","useRef","useState","memo","useCallback","alpha","Box","TextField","Button","ColorPicker","TextFieldColorPicker","props","valueProp","value","defaultValue","onChangeProp","onChange","disabled","otherProps","popoverOpen","setPopoverOpen","hex","text","setText","setState","v","_onChange","color","replace","popoverRef","buttonRef","e","target","current","backgroundColor","open","pointerEvents","cursor","width","height","borderRadius","borderWidth","borderColor","borderStyle","outlineColor","match","zIndex"],"sources":["../../../src/ThemeExplorer/TextFieldColorPicker.tsx"],"sourcesContent":["import type { Color } from '@basic-ui/color-picker';\nimport { toColor } from '@basic-ui/color-picker';\nimport { Popper, useControlledState, useOnClickOutside } from '@basic-ui/core';\nimport { useRef, useState, memo, useCallback } from 'react';\n\nimport type { TextFieldProps } from '../';\nimport { alpha, Box, TextField, Button } from '../';\nimport { ColorPicker } from './ColorPicker';\n\nexport interface TextFieldColorPickerProps\n extends Omit<TextFieldProps, 'value' | 'defaultValue' | 'onChange'> {\n value?: Color;\n defaultValue?: Color;\n onChange?: (color: Color) => void;\n}\n\nexport const TextFieldColorPicker = memo<TextFieldColorPickerProps>((props) => {\n const {\n value: valueProp,\n defaultValue = toColor('hex', '#33ff33'),\n onChange: onChangeProp,\n disabled,\n ...otherProps\n } = props;\n\n const [popoverOpen, setPopoverOpen] = useState(false);\n const [text, setText] = useState(valueProp?.hex || defaultValue.hex);\n const [value, _onChange] = useControlledState<Color, any, []>(\n valueProp,\n onChangeProp as any,\n defaultValue,\n (setState) => (v: any) => {\n setState(v);\n setText(v.hex);\n }\n );\n\n const onChange = useCallback(\n (color: Color) => {\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n _onChange!(color);\n setText(color.hex.replace('#', ''));\n },\n [_onChange]\n );\n\n const popoverRef = useRef<HTMLDivElement>(null);\n const buttonRef = useRef<HTMLButtonElement>(null);\n useOnClickOutside(popoverRef, (e) => {\n if (e.target === buttonRef?.current) {\n return;\n }\n setPopoverOpen(false);\n });\n\n return (\n <>\n <TextField\n disabled={disabled}\n value={text.replace('#', '')}\n leadingIcon={'#'}\n trailingIcon={\n <Button\n style={{ backgroundColor: value.hex }}\n color=\"on.surface\"\n ref={buttonRef}\n onClick={() => setPopoverOpen((open) => !open)}\n disabled={disabled}\n sx={{\n pointerEvents: 'all',\n cursor: 'pointer',\n width: 32,\n height: 32,\n borderRadius: 'extra-small',\n borderWidth: '1px',\n borderColor: alpha('on.surface', 0.38),\n borderStyle: 'solid',\n outlineColor: 'transparent',\n }}\n />\n }\n maxLength={6}\n hideCharacterCounter\n onChange={(e) => {\n if (e.target.value.match(/^[a-fA-F0-9]{6}$/)) {\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n onChange!(toColor('hex', '#' + e.target.value));\n return;\n }\n setText(e.target.value);\n }}\n {...otherProps}\n />\n {popoverOpen && (\n <Popper\n anchorEl={buttonRef}\n placement=\"bottom-end\"\n style={{ zIndex: 2 }}\n >\n <Box ref={popoverRef} py={2}>\n <Box boxShadow={4}>\n <ColorPicker\n color={value}\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n onChange={onChange!}\n width={220}\n height={220}\n />\n </Box>\n </Box>\n </Popper>\n )}\n </>\n );\n});\n"],"mappings":";;;;AACA,SAASA,OAAT,QAAwB,wBAAxB;AACA,SAASC,MAAT,EAAiBC,kBAAjB,EAAqCC,iBAArC,QAA8D,gBAA9D;AACA,SAASC,MAAT,EAAiBC,QAAjB,EAA2BC,IAA3B,EAAiCC,WAAjC,QAAoD,OAApD;AAGA,SAASC,KAAT,EAAgBC,GAAhB,EAAqB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,CAAC,CAACC,MAAF,CAASnB,KAAvB,CAAT,CAAR;;UACA;QACD;;QACDU,OAAO,CAACQ,CAAC,CAACC,MAAF,CAASnB,KAAV,CAAP;MACD;IAjCH,GAkCMK,UAlCN,EADF,EAqCGC,WAAW,iBACV,KAAC,MAAD;MACE,QAAQ,EAAEW,SADZ;MAEE,SAAS,EAAC,YAFZ;MAGE,KAAK,EAAE;QAAEgB,MAAM,EAAE;MAAV,CAHT;MAAA,uBAKE,KAAC,GAAD;QAAK,GAAG,EAAEjB,UAAV;QAAsB,EAAE,EAAE,CAA1B;QAAA,uBACE,KAAC,GAAD;UAAK,SAAS,EAAE,CAAhB;UAAA,uBACE,KAAC,WAAD;YACE,KAAK,EAAEhB,KADT,CAEE;YAFF;YAGE,QAAQ,EAAEG,UAHZ;YAIE,KAAK,EAAE,GAJT;YAKE,MAAM,EAAE;UALV;QADF;MADF;IALF,EAtCJ;EAAA,EADF;AA2DD,CAlGuC,CAAjC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ComponentType } from 'react';
|
|
2
|
+
export interface ThemeBuilderProps {
|
|
3
|
+
CodeHighlightingComponent?: ComponentType<{
|
|
4
|
+
children: string;
|
|
5
|
+
className: string;
|
|
6
|
+
showButtons?: boolean;
|
|
7
|
+
}>;
|
|
8
|
+
}
|
|
9
|
+
export declare const ThemeBuilder: (props: ThemeBuilderProps) => JSX.Element | null;
|