impact-ui 5.0.0-alpha.2 → 5.0.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/CalendarDay.js +4 -0
- package/dist/_virtual/ModifiersShape.js +4 -0
- package/dist/_virtual/WithStylesContext.js +4 -0
- package/dist/_virtual/_commonjsHelpers.js +2 -0
- package/dist/_virtual/and.js +4 -0
- package/dist/_virtual/between.js +4 -0
- package/dist/_virtual/booleanSome.js +4 -0
- package/dist/_virtual/brcast.js +4 -0
- package/dist/_virtual/childrenHavePropXorChildren.js +4 -0
- package/dist/_virtual/childrenOf.js +4 -0
- package/dist/_virtual/childrenOfType.js +4 -0
- package/dist/_virtual/childrenSequenceOf.js +4 -0
- package/dist/_virtual/componentWithName.js +4 -0
- package/dist/_virtual/constants2.js +4 -0
- package/dist/_virtual/constants3.js +4 -0
- package/dist/_virtual/defaultPhrases.js +4 -0
- package/dist/_virtual/direction.js +4 -0
- package/dist/_virtual/disallowedIf.js +4 -0
- package/dist/_virtual/elementType.js +4 -0
- package/dist/_virtual/empty.js +4 -0
- package/dist/_virtual/emptyStylesFn.js +4 -0
- package/dist/_virtual/explicitNull.js +4 -0
- package/dist/_virtual/getCalendarDaySettings.js +4 -0
- package/dist/_virtual/getComponentName.js +4 -0
- package/dist/_virtual/getComponentName2.js +4 -0
- package/dist/_virtual/getPhrase.js +4 -0
- package/dist/_virtual/getPhrasePropTypes.js +4 -0
- package/dist/_virtual/hoist-non-react-statics.cjs.js +2 -0
- package/dist/_virtual/implementation.browser.js +4 -0
- package/dist/_virtual/index10.js +4 -0
- package/dist/_virtual/index11.js +4 -0
- package/dist/_virtual/index12.js +4 -0
- package/dist/_virtual/index2.js +5 -2
- package/dist/_virtual/index3.js +2 -2
- package/dist/_virtual/index5.js +2 -2
- package/dist/_virtual/index6.js +2 -2
- package/dist/_virtual/index7.js +2 -2
- package/dist/_virtual/index8.js +2 -2
- package/dist/_virtual/index9.js +4 -0
- package/dist/_virtual/integer.js +4 -0
- package/dist/_virtual/isInteger.js +4 -0
- package/dist/_virtual/isPlainObject.js +4 -0
- package/dist/_virtual/isPlainObject2.js +4 -0
- package/dist/_virtual/isPrimitive.js +4 -0
- package/dist/_virtual/keysOf.js +4 -0
- package/dist/_virtual/mutuallyExclusiveProps.js +4 -0
- package/dist/_virtual/mutuallyExclusiveTrueProps.js +4 -0
- package/dist/_virtual/nChildren.js +4 -0
- package/dist/_virtual/nonNegativeInteger.js +4 -0
- package/dist/_virtual/nonNegativeNumber.js +4 -0
- package/dist/_virtual/numericString.js +4 -0
- package/dist/_virtual/object.js +4 -0
- package/dist/_virtual/or.js +4 -0
- package/dist/_virtual/perf.js +4 -0
- package/dist/_virtual/performance-now.js +4 -0
- package/dist/_virtual/predicate.js +4 -0
- package/dist/_virtual/range.js +4 -0
- package/dist/_virtual/ref.js +4 -0
- package/dist/_virtual/ref2.js +4 -0
- package/dist/_virtual/renderableChildren.js +4 -0
- package/dist/_virtual/requiredBy.js +4 -0
- package/dist/_virtual/restrictedProp.js +4 -0
- package/dist/_virtual/sequenceOf.js +4 -0
- package/dist/_virtual/shape.js +4 -0
- package/dist/_virtual/stringEndsWith.js +4 -0
- package/dist/_virtual/stringStartsWith.js +4 -0
- package/dist/_virtual/typeOf.js +4 -0
- package/dist/_virtual/uniqueArray.js +4 -0
- package/dist/_virtual/uniqueArrayOf.js +4 -0
- package/dist/_virtual/valuesOf.js +4 -0
- package/dist/_virtual/withDirection.js +4 -0
- package/dist/_virtual/withShape.js +4 -0
- package/dist/_virtual/withStyles.js +4 -0
- package/dist/_virtual/withStylesPropTypes.js +4 -0
- package/dist/_virtual/wrapValidator.js +4 -0
- package/dist/_virtual/wrapValidator2.js +4 -0
- package/dist/components/Chatbot/Chatbot.types.d.ts +0 -2
- package/dist/components/Chatbot/Chatbot.types.d.ts.map +1 -1
- package/dist/components/Chatbot/historyPanel.d.ts +1 -1
- package/dist/components/Chatbot/historyPanel.d.ts.map +1 -1
- package/dist/components/Chatbot/historyPanel.js +90 -146
- package/dist/components/Chatbot/index.d.ts +1 -1
- package/dist/components/Chatbot/index.d.ts.map +1 -1
- package/dist/components/Chatbot/index.js +1 -3
- package/dist/components/DatePicker/index.js +1 -1
- package/dist/components/DateRangePicker/DateRangePicker.types.d.ts +1 -0
- package/dist/components/DateRangePicker/DateRangePicker.types.d.ts.map +1 -1
- package/dist/components/DateRangePicker/dateRangePickerDropdown.d.ts +1 -1
- package/dist/components/DateRangePicker/dateRangePickerDropdown.d.ts.map +1 -1
- package/dist/components/DateRangePicker/dateRangePickerDropdown.js +67 -49
- package/dist/components/DateRangePicker/index.d.ts.map +1 -1
- package/dist/components/DateRangePicker/index.js +3 -1
- package/dist/components/DateRangePicker/utils.d.ts +1 -0
- package/dist/components/DateRangePicker/utils.d.ts.map +1 -1
- package/dist/components/DateRangePicker/utils.js +11 -1
- package/dist/mcp-component-registry.json +7 -7
- package/dist/node_modules/@emotion/react/dist/emotion-react.browser.esm.js +1 -1
- package/dist/node_modules/@mui/base/TextareaAutosize/TextareaAutosize.js +1 -1
- package/dist/node_modules/@mui/material/Accordion/Accordion.js +1 -1
- package/dist/node_modules/@mui/material/AccordionDetails/AccordionDetails.js +1 -1
- package/dist/node_modules/@mui/material/AccordionSummary/AccordionSummary.js +1 -1
- package/dist/node_modules/@mui/material/Alert/Alert.js +1 -1
- package/dist/node_modules/@mui/material/AlertTitle/AlertTitle.js +1 -1
- package/dist/node_modules/@mui/material/Avatar/Avatar.js +1 -1
- package/dist/node_modules/@mui/material/Backdrop/Backdrop.js +1 -1
- package/dist/node_modules/@mui/material/Badge/Badge.js +1 -1
- package/dist/node_modules/@mui/material/Box/Box.js +1 -1
- package/dist/node_modules/@mui/material/Breadcrumbs/BreadcrumbCollapsed.js +1 -1
- package/dist/node_modules/@mui/material/Breadcrumbs/Breadcrumbs.js +1 -1
- package/dist/node_modules/@mui/material/Button/Button.js +1 -1
- package/dist/node_modules/@mui/material/ButtonBase/ButtonBase.js +1 -1
- package/dist/node_modules/@mui/material/ButtonBase/Ripple.js +1 -1
- package/dist/node_modules/@mui/material/ButtonBase/TouchRipple.js +1 -1
- package/dist/node_modules/@mui/material/Card/Card.js +1 -1
- package/dist/node_modules/@mui/material/Checkbox/Checkbox.js +1 -1
- package/dist/node_modules/@mui/material/Chip/Chip.js +1 -1
- package/dist/node_modules/@mui/material/CircularProgress/CircularProgress.js +1 -1
- package/dist/node_modules/@mui/material/Collapse/Collapse.js +1 -1
- package/dist/node_modules/@mui/material/Dialog/Dialog.js +1 -1
- package/dist/node_modules/@mui/material/DialogActions/DialogActions.js +1 -1
- package/dist/node_modules/@mui/material/DialogContent/DialogContent.js +1 -1
- package/dist/node_modules/@mui/material/DialogContentText/DialogContentText.js +1 -1
- package/dist/node_modules/@mui/material/DialogTitle/DialogTitle.js +1 -1
- package/dist/node_modules/@mui/material/Drawer/Drawer.js +1 -1
- package/dist/node_modules/@mui/material/Fade/Fade.js +1 -1
- package/dist/node_modules/@mui/material/FormControl/FormControl.js +1 -1
- package/dist/node_modules/@mui/material/FormControlLabel/FormControlLabel.js +1 -1
- package/dist/node_modules/@mui/material/FormGroup/FormGroup.js +1 -1
- package/dist/node_modules/@mui/material/FormHelperText/FormHelperText.js +1 -1
- package/dist/node_modules/@mui/material/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/node_modules/@mui/material/Grow/Grow.js +1 -1
- package/dist/node_modules/@mui/material/IconButton/IconButton.js +1 -1
- package/dist/node_modules/@mui/material/InputBase/InputBase.js +1 -1
- package/dist/node_modules/@mui/material/LinearProgress/LinearProgress.js +1 -1
- package/dist/node_modules/@mui/material/Link/Link.js +1 -1
- package/dist/node_modules/@mui/material/List/List.js +1 -1
- package/dist/node_modules/@mui/material/ListItemIcon/ListItemIcon.js +1 -1
- package/dist/node_modules/@mui/material/Menu/Menu.js +1 -1
- package/dist/node_modules/@mui/material/MenuItem/MenuItem.js +1 -1
- package/dist/node_modules/@mui/material/MenuList/MenuList.js +1 -1
- package/dist/node_modules/@mui/material/Modal/Modal.js +1 -1
- package/dist/node_modules/@mui/material/OutlinedInput/NotchedOutline.js +1 -1
- package/dist/node_modules/@mui/material/OutlinedInput/OutlinedInput.js +1 -1
- package/dist/node_modules/@mui/material/Paper/Paper.js +1 -1
- package/dist/node_modules/@mui/material/Popover/Popover.js +1 -1
- package/dist/node_modules/@mui/material/Popper/Popper.js +1 -1
- package/dist/node_modules/@mui/material/Radio/Radio.js +1 -1
- package/dist/node_modules/@mui/material/Radio/RadioButtonIcon.js +1 -1
- package/dist/node_modules/@mui/material/RadioGroup/RadioGroup.js +1 -1
- package/dist/node_modules/@mui/material/Skeleton/Skeleton.js +1 -1
- package/dist/node_modules/@mui/material/Slide/Slide.js +1 -1
- package/dist/node_modules/@mui/material/Slider/Slider.js +1 -1
- package/dist/node_modules/@mui/material/Slider/SliderValueLabel.js +1 -1
- package/dist/node_modules/@mui/material/Snackbar/Snackbar.js +1 -1
- package/dist/node_modules/@mui/material/SnackbarContent/SnackbarContent.js +1 -1
- package/dist/node_modules/@mui/material/Stack/Stack.js +1 -1
- package/dist/node_modules/@mui/material/Step/Step.js +1 -1
- package/dist/node_modules/@mui/material/StepConnector/StepConnector.js +1 -1
- package/dist/node_modules/@mui/material/StepIcon/StepIcon.js +1 -1
- package/dist/node_modules/@mui/material/StepLabel/StepLabel.js +1 -1
- package/dist/node_modules/@mui/material/Stepper/Stepper.js +1 -1
- package/dist/node_modules/@mui/material/SvgIcon/SvgIcon.js +1 -1
- package/dist/node_modules/@mui/material/Switch/Switch.js +1 -1
- package/dist/node_modules/@mui/material/Tab/Tab.js +1 -1
- package/dist/node_modules/@mui/material/TabScrollButton/TabScrollButton.js +1 -1
- package/dist/node_modules/@mui/material/Tabs/ScrollbarSize.js +1 -1
- package/dist/node_modules/@mui/material/Tabs/Tabs.js +1 -1
- package/dist/node_modules/@mui/material/ToggleButton/ToggleButton.js +1 -1
- package/dist/node_modules/@mui/material/ToggleButtonGroup/ToggleButtonGroup.js +1 -1
- package/dist/node_modules/@mui/material/Tooltip/Tooltip.js +1 -1
- package/dist/node_modules/@mui/material/Typography/Typography.js +1 -1
- package/dist/node_modules/@mui/material/internal/SwitchBase.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/ClickAwayListener/ClickAwayListener.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/FocusTrap/FocusTrap.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/Modal/Modal.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/Popper/Popper.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/Portal/Portal.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/@mui/base/TextareaAutosize/TextareaAutosize.js +1 -1
- package/dist/node_modules/@mui/material/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/@mui/styled-engine/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/node_modules/@mui/system/esm/Stack/createStack.js +1 -1
- package/dist/node_modules/@mui/system/esm/breakpoints.js +1 -0
- package/dist/node_modules/@mui/system/esm/responsivePropType.js +1 -1
- package/dist/node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js +1 -1
- package/dist/node_modules/@mui/utils/elementTypeAcceptingRef/elementTypeAcceptingRef.js +1 -1
- package/dist/node_modules/@mui/utils/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/@mui/utils/refType/refType.js +1 -1
- package/dist/node_modules/array.prototype.find/implementation.js +37 -0
- package/dist/node_modules/array.prototype.find/index.js +35 -0
- package/dist/node_modules/array.prototype.find/polyfill.js +17 -0
- package/dist/node_modules/array.prototype.find/shim.js +30 -0
- package/dist/node_modules/call-bind/callBound.js +22 -0
- package/dist/node_modules/call-bind/index.js +1 -1
- package/dist/node_modules/enzyme-shallow-equal/build/index.js +53 -0
- package/dist/node_modules/es-abstract/2023/CreateMethodProperty.js +46 -0
- package/dist/node_modules/es-abstract/2023/FromPropertyDescriptor.js +22 -0
- package/dist/node_modules/es-abstract/2023/IsDataDescriptor.js +28 -0
- package/dist/node_modules/es-abstract/2023/SameValue.js +21 -0
- package/dist/node_modules/es-abstract/helpers/OwnPropertyKeys.js +12 -0
- package/dist/node_modules/es-set-tostringtag/index.js +39 -0
- package/dist/node_modules/function.prototype.name/implementation.js +59 -0
- package/dist/node_modules/function.prototype.name/index.js +23 -0
- package/dist/node_modules/function.prototype.name/polyfill.js +15 -0
- package/dist/node_modules/function.prototype.name/shim.js +47 -0
- package/dist/node_modules/functions-have-names/index.js +36 -0
- package/dist/node_modules/globalthis/implementation.browser.js +17 -0
- package/dist/node_modules/globalthis/index.js +28 -0
- package/dist/node_modules/globalthis/polyfill.js +18 -0
- package/dist/node_modules/globalthis/shim.js +33 -0
- package/dist/node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js +90 -18
- package/dist/node_modules/is-document.all/index.js +40 -0
- package/dist/node_modules/is-symbol/index.js +1 -1
- package/dist/node_modules/object-is/implementation.js +25 -0
- package/dist/node_modules/object-is/index.js +27 -0
- package/dist/node_modules/object-is/polyfill.js +15 -0
- package/dist/node_modules/object-is/shim.js +23 -0
- package/dist/node_modules/object.assign/implementation.js +52 -0
- package/dist/node_modules/object.assign/index.js +30 -0
- package/dist/node_modules/object.assign/polyfill.js +53 -0
- package/dist/node_modules/object.assign/shim.js +25 -0
- package/dist/node_modules/object.entries/implementation.js +26 -0
- package/dist/node_modules/object.entries/index.js +27 -0
- package/dist/node_modules/object.entries/polyfill.js +15 -0
- package/dist/node_modules/object.entries/shim.js +23 -0
- package/dist/node_modules/object.values/implementation.js +25 -0
- package/dist/node_modules/object.values/index.js +27 -0
- package/dist/node_modules/object.values/polyfill.js +15 -0
- package/dist/node_modules/object.values/shim.js +23 -0
- package/dist/node_modules/own-keys/index.js +26 -0
- package/dist/node_modules/performance-now/lib/performance-now.js +42 -0
- package/dist/node_modules/prop-types/index.js +14 -11
- package/dist/node_modules/prop-types-exact/build/helpers/isPlainObject.js +15 -0
- package/dist/node_modules/prop-types-exact/node_modules/isarray/index.js +14 -0
- package/dist/node_modules/prop-types-exact/src/index.js +52 -0
- package/dist/node_modules/raf/index.js +66 -0
- package/dist/node_modules/react-dates/lib/components/CalendarDay.js +355 -0
- package/dist/node_modules/react-dates/lib/constants.js +68 -0
- package/dist/node_modules/react-dates/lib/defaultPhrases.js +250 -0
- package/dist/node_modules/react-dates/lib/shapes/ModifiersShape.js +41 -0
- package/dist/node_modules/react-dates/lib/utils/getCalendarDaySettings.js +64 -0
- package/dist/node_modules/react-dates/lib/utils/getPhrase.js +23 -0
- package/dist/node_modules/react-dates/lib/utils/getPhrasePropTypes.js +55 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/and.js +53 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/between.js +276 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/booleanSome.js +64 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/childrenHavePropXorChildren.js +65 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/childrenOf.js +105 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/childrenOfType.js +63 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/childrenSequenceOf.js +100 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/componentWithName.js +109 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/disallowedIf.js +64 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/elementType.js +77 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/empty.js +46 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/explicitNull.js +50 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/getComponentName.js +41 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/isInteger.js +23 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/isPlainObject.js +23 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/isPrimitive.js +32 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/renderableChildren.js +26 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/typeOf.js +49 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/helpers/wrapValidator.js +33 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/index.js +123 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/integer.js +45 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/keysOf.js +63 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/mocks/index.js +55 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/mutuallyExclusiveProps.js +100 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/mutuallyExclusiveTrueProps.js +64 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/nChildren.js +47 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/nonNegativeInteger.js +27 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/nonNegativeNumber.js +45 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/numericString.js +55 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/object.js +56 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/or.js +96 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/predicate.js +48 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/range.js +49 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/ref.js +58 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/requiredBy.js +49 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/restrictedProp.js +42 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/sequenceOf.js +211 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/shape.js +58 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/stringEndsWith.js +53 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/stringStartsWith.js +53 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/uniqueArray.js +69 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/uniqueArrayOf.js +116 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/valuesOf.js +54 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/build/withShape.js +30 -0
- package/dist/node_modules/react-dates/node_modules/airbnb-prop-types/index.js +13 -0
- package/dist/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-moment-proptypes/src/core.js +96 -0
- package/dist/node_modules/react-moment-proptypes/src/index.js +48 -0
- package/dist/node_modules/react-moment-proptypes/src/moment-validation-wrapper.js +24 -0
- package/dist/node_modules/react-transition-group/esm/Transition.js +1 -1
- package/dist/node_modules/react-transition-group/esm/TransitionGroup.js +1 -1
- package/dist/node_modules/react-transition-group/esm/utils/PropTypes.js +1 -1
- package/dist/node_modules/react-with-styles/lib/WithStylesContext.js +57 -0
- package/dist/node_modules/react-with-styles/lib/utils/emptyStylesFn.js +22 -0
- package/dist/node_modules/react-with-styles/lib/utils/perf.js +49 -0
- package/dist/node_modules/react-with-styles/lib/withStyles.js +252 -0
- package/dist/node_modules/react-with-styles/lib/withStylesPropTypes.js +28 -0
- package/dist/node_modules/react-with-styles/node_modules/airbnb-prop-types/build/helpers/getComponentName.js +41 -0
- package/dist/node_modules/react-with-styles/node_modules/airbnb-prop-types/build/helpers/isPlainObject.js +23 -0
- package/dist/node_modules/react-with-styles/node_modules/airbnb-prop-types/build/helpers/wrapValidator.js +33 -0
- package/dist/node_modules/react-with-styles/node_modules/airbnb-prop-types/build/ref.js +58 -0
- package/dist/node_modules/react-with-styles/node_modules/deepmerge/dist/cjs.js +85 -0
- package/dist/node_modules/react-with-styles/node_modules/react-with-direction/dist/constants.js +18 -0
- package/dist/node_modules/react-with-styles/node_modules/react-with-direction/dist/proptypes/brcast.js +26 -0
- package/dist/node_modules/react-with-styles/node_modules/react-with-direction/dist/proptypes/direction.js +27 -0
- package/dist/node_modules/react-with-styles/node_modules/react-with-direction/dist/withDirection.js +160 -0
- package/dist/node_modules/react-with-styles-interface-css/dist/index.js +1 -1
- package/dist/node_modules/react-with-styles-interface-css/dist/utils/constants.js +1 -1
- package/dist/node_modules/reflect.ownkeys/implementation.js +15 -0
- package/dist/node_modules/reflect.ownkeys/index.js +27 -0
- package/dist/node_modules/reflect.ownkeys/polyfill.js +18 -0
- package/dist/node_modules/reflect.ownkeys/shim.js +30 -0
- package/dist/node_modules/safe-push-apply/index.js +22 -0
- package/dist/node_modules/safe-push-apply/node_modules/isarray/index.js +14 -0
- package/package.json +1 -1
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { __exports as ModifiersShape } from "../../../../_virtual/ModifiersShape.js";
|
|
2
|
+
import require$$0 from "@babel/runtime/helpers/interopRequireDefault";
|
|
3
|
+
import require$$1 from "@babel/runtime/helpers/defineProperty";
|
|
4
|
+
import require$$2 from "@babel/runtime/helpers/toConsumableArray";
|
|
5
|
+
import { __require as requirePropTypes } from "../../../prop-types/index.js";
|
|
6
|
+
import { __require as requireAirbnbPropTypes } from "../../node_modules/airbnb-prop-types/index.js";
|
|
7
|
+
var hasRequiredModifiersShape;
|
|
8
|
+
function requireModifiersShape() {
|
|
9
|
+
if (hasRequiredModifiersShape) return ModifiersShape;
|
|
10
|
+
hasRequiredModifiersShape = 1;
|
|
11
|
+
(function(exports) {
|
|
12
|
+
var _interopRequireDefault = require$$0;
|
|
13
|
+
Object.defineProperty(exports, "__esModule", {
|
|
14
|
+
value: true
|
|
15
|
+
});
|
|
16
|
+
exports["default"] = void 0;
|
|
17
|
+
var _defineProperty2 = _interopRequireDefault(require$$1);
|
|
18
|
+
var _toConsumableArray2 = _interopRequireDefault(require$$2);
|
|
19
|
+
var _propTypes = _interopRequireDefault(requirePropTypes());
|
|
20
|
+
var _airbnbPropTypes = requireAirbnbPropTypes();
|
|
21
|
+
var _default = (0, _airbnbPropTypes.and)([_propTypes["default"].instanceOf(Set), function modifiers(props, propName) {
|
|
22
|
+
for (var _len = arguments.length, rest = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
|
|
23
|
+
rest[_key - 2] = arguments[_key];
|
|
24
|
+
}
|
|
25
|
+
var propValue = props[propName];
|
|
26
|
+
var firstError;
|
|
27
|
+
(0, _toConsumableArray2["default"])(propValue).some(function(v, i) {
|
|
28
|
+
var _PropTypes$string;
|
|
29
|
+
var fakePropName = "".concat(propName, ": index ").concat(i);
|
|
30
|
+
firstError = (_PropTypes$string = _propTypes["default"].string).isRequired.apply(_PropTypes$string, [(0, _defineProperty2["default"])({}, fakePropName, v), fakePropName].concat(rest));
|
|
31
|
+
return firstError != null;
|
|
32
|
+
});
|
|
33
|
+
return firstError == null ? null : firstError;
|
|
34
|
+
}], "Modifiers (Set of Strings)");
|
|
35
|
+
exports["default"] = _default;
|
|
36
|
+
})(ModifiersShape);
|
|
37
|
+
return ModifiersShape;
|
|
38
|
+
}
|
|
39
|
+
export {
|
|
40
|
+
requireModifiersShape as __require
|
|
41
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { __exports as getCalendarDaySettings } from "../../../../_virtual/getCalendarDaySettings.js";
|
|
2
|
+
import require$$0 from "@babel/runtime/helpers/interopRequireDefault";
|
|
3
|
+
import { __require as requireGetPhrase } from "./getPhrase.js";
|
|
4
|
+
import { __require as requireConstants } from "../constants.js";
|
|
5
|
+
var hasRequiredGetCalendarDaySettings;
|
|
6
|
+
function requireGetCalendarDaySettings() {
|
|
7
|
+
if (hasRequiredGetCalendarDaySettings) return getCalendarDaySettings;
|
|
8
|
+
hasRequiredGetCalendarDaySettings = 1;
|
|
9
|
+
(function(exports) {
|
|
10
|
+
var _interopRequireDefault = require$$0;
|
|
11
|
+
Object.defineProperty(exports, "__esModule", {
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
exports["default"] = getCalendarDaySettings2;
|
|
15
|
+
var _getPhrase = _interopRequireDefault(requireGetPhrase());
|
|
16
|
+
var _constants = requireConstants();
|
|
17
|
+
function isSelected(modifiers) {
|
|
18
|
+
return modifiers.has("selected") || modifiers.has("selected-span") || modifiers.has("selected-start") || modifiers.has("selected-end");
|
|
19
|
+
}
|
|
20
|
+
function shouldUseDefaultCursor(modifiers) {
|
|
21
|
+
return modifiers.has("blocked-minimum-nights") || modifiers.has("blocked-calendar") || modifiers.has("blocked-out-of-range");
|
|
22
|
+
}
|
|
23
|
+
function isHoveredSpan(modifiers) {
|
|
24
|
+
if (isSelected(modifiers)) return false;
|
|
25
|
+
return modifiers.has("hovered-span") || modifiers.has("after-hovered-start") || modifiers.has("before-hovered-end");
|
|
26
|
+
}
|
|
27
|
+
function getAriaLabel(phrases, modifiers, day, ariaLabelFormat) {
|
|
28
|
+
var chooseAvailableDate = phrases.chooseAvailableDate, dateIsUnavailable = phrases.dateIsUnavailable, dateIsSelected = phrases.dateIsSelected, dateIsSelectedAsStartDate = phrases.dateIsSelectedAsStartDate, dateIsSelectedAsEndDate = phrases.dateIsSelectedAsEndDate;
|
|
29
|
+
var formattedDate = {
|
|
30
|
+
date: day.format(ariaLabelFormat)
|
|
31
|
+
};
|
|
32
|
+
if (modifiers.has("selected-start") && dateIsSelectedAsStartDate) {
|
|
33
|
+
return (0, _getPhrase["default"])(dateIsSelectedAsStartDate, formattedDate);
|
|
34
|
+
}
|
|
35
|
+
if (modifiers.has("selected-end") && dateIsSelectedAsEndDate) {
|
|
36
|
+
return (0, _getPhrase["default"])(dateIsSelectedAsEndDate, formattedDate);
|
|
37
|
+
}
|
|
38
|
+
if (isSelected(modifiers) && dateIsSelected) {
|
|
39
|
+
return (0, _getPhrase["default"])(dateIsSelected, formattedDate);
|
|
40
|
+
}
|
|
41
|
+
if (modifiers.has(_constants.BLOCKED_MODIFIER)) {
|
|
42
|
+
return (0, _getPhrase["default"])(dateIsUnavailable, formattedDate);
|
|
43
|
+
}
|
|
44
|
+
return (0, _getPhrase["default"])(chooseAvailableDate, formattedDate);
|
|
45
|
+
}
|
|
46
|
+
function getCalendarDaySettings2(day, ariaLabelFormat, daySize, modifiers, phrases) {
|
|
47
|
+
return {
|
|
48
|
+
ariaLabel: getAriaLabel(phrases, modifiers, day, ariaLabelFormat),
|
|
49
|
+
hoveredSpan: isHoveredSpan(modifiers),
|
|
50
|
+
isOutsideRange: modifiers.has("blocked-out-of-range"),
|
|
51
|
+
selected: isSelected(modifiers),
|
|
52
|
+
useDefaultCursor: shouldUseDefaultCursor(modifiers),
|
|
53
|
+
daySizeStyles: {
|
|
54
|
+
width: daySize,
|
|
55
|
+
height: daySize - 1
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
})(getCalendarDaySettings);
|
|
60
|
+
return getCalendarDaySettings;
|
|
61
|
+
}
|
|
62
|
+
export {
|
|
63
|
+
requireGetCalendarDaySettings as __require
|
|
64
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { __exports as getPhrase } from "../../../../_virtual/getPhrase.js";
|
|
2
|
+
var hasRequiredGetPhrase;
|
|
3
|
+
function requireGetPhrase() {
|
|
4
|
+
if (hasRequiredGetPhrase) return getPhrase;
|
|
5
|
+
hasRequiredGetPhrase = 1;
|
|
6
|
+
(function(exports) {
|
|
7
|
+
Object.defineProperty(exports, "__esModule", {
|
|
8
|
+
value: true
|
|
9
|
+
});
|
|
10
|
+
exports["default"] = getPhrase2;
|
|
11
|
+
function getPhrase2(phrase, args) {
|
|
12
|
+
if (typeof phrase === "string") return phrase;
|
|
13
|
+
if (typeof phrase === "function") {
|
|
14
|
+
return phrase(args);
|
|
15
|
+
}
|
|
16
|
+
return "";
|
|
17
|
+
}
|
|
18
|
+
})(getPhrase);
|
|
19
|
+
return getPhrase;
|
|
20
|
+
}
|
|
21
|
+
export {
|
|
22
|
+
requireGetPhrase as __require
|
|
23
|
+
};
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { __exports as getPhrasePropTypes } from "../../../../_virtual/getPhrasePropTypes.js";
|
|
2
|
+
import require$$0 from "@babel/runtime/helpers/interopRequireDefault";
|
|
3
|
+
import require$$1 from "@babel/runtime/helpers/defineProperty";
|
|
4
|
+
import { __require as requirePropTypes } from "../../../prop-types/index.js";
|
|
5
|
+
var hasRequiredGetPhrasePropTypes;
|
|
6
|
+
function requireGetPhrasePropTypes() {
|
|
7
|
+
if (hasRequiredGetPhrasePropTypes) return getPhrasePropTypes;
|
|
8
|
+
hasRequiredGetPhrasePropTypes = 1;
|
|
9
|
+
(function(exports) {
|
|
10
|
+
var _interopRequireDefault = require$$0;
|
|
11
|
+
Object.defineProperty(exports, "__esModule", {
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
exports["default"] = getPhrasePropTypes2;
|
|
15
|
+
var _defineProperty2 = _interopRequireDefault(require$$1);
|
|
16
|
+
var _propTypes = _interopRequireDefault(requirePropTypes());
|
|
17
|
+
function ownKeys(object, enumerableOnly) {
|
|
18
|
+
var keys = Object.keys(object);
|
|
19
|
+
if (Object.getOwnPropertySymbols) {
|
|
20
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
21
|
+
if (enumerableOnly) symbols = symbols.filter(function(sym) {
|
|
22
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
23
|
+
});
|
|
24
|
+
keys.push.apply(keys, symbols);
|
|
25
|
+
}
|
|
26
|
+
return keys;
|
|
27
|
+
}
|
|
28
|
+
function _objectSpread(target) {
|
|
29
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
30
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
31
|
+
if (i % 2) {
|
|
32
|
+
ownKeys(Object(source), true).forEach(function(key) {
|
|
33
|
+
(0, _defineProperty2["default"])(target, key, source[key]);
|
|
34
|
+
});
|
|
35
|
+
} else if (Object.getOwnPropertyDescriptors) {
|
|
36
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
37
|
+
} else {
|
|
38
|
+
ownKeys(Object(source)).forEach(function(key) {
|
|
39
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return target;
|
|
44
|
+
}
|
|
45
|
+
function getPhrasePropTypes2(defaultPhrases) {
|
|
46
|
+
return Object.keys(defaultPhrases).reduce(function(phrases, key) {
|
|
47
|
+
return _objectSpread({}, phrases, (0, _defineProperty2["default"])({}, key, _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].func, _propTypes["default"].node])));
|
|
48
|
+
}, {});
|
|
49
|
+
}
|
|
50
|
+
})(getPhrasePropTypes);
|
|
51
|
+
return getPhrasePropTypes;
|
|
52
|
+
}
|
|
53
|
+
export {
|
|
54
|
+
requireGetPhrasePropTypes as __require
|
|
55
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { __exports as and } from "../../../../../_virtual/and.js";
|
|
2
|
+
import { __require as requireWrapValidator } from "./helpers/wrapValidator.js";
|
|
3
|
+
var hasRequiredAnd;
|
|
4
|
+
function requireAnd() {
|
|
5
|
+
if (hasRequiredAnd) return and;
|
|
6
|
+
hasRequiredAnd = 1;
|
|
7
|
+
(function(exports) {
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports["default"] = andValidator;
|
|
12
|
+
var _wrapValidator = _interopRequireDefault(requireWrapValidator());
|
|
13
|
+
function _interopRequireDefault(obj) {
|
|
14
|
+
return obj && obj.__esModule ? obj : { "default": obj };
|
|
15
|
+
}
|
|
16
|
+
function andValidator(validators) {
|
|
17
|
+
var name = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "and";
|
|
18
|
+
if (!Array.isArray(validators)) {
|
|
19
|
+
throw new TypeError("and: 2 or more validators are required");
|
|
20
|
+
}
|
|
21
|
+
if (validators.length <= 1) {
|
|
22
|
+
throw new RangeError("and: 2 or more validators are required");
|
|
23
|
+
}
|
|
24
|
+
var validator = function and2() {
|
|
25
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
26
|
+
args[_key] = arguments[_key];
|
|
27
|
+
}
|
|
28
|
+
var firstError = null;
|
|
29
|
+
validators.some(function(validatorFn) {
|
|
30
|
+
firstError = validatorFn.apply(void 0, args);
|
|
31
|
+
return firstError != null;
|
|
32
|
+
});
|
|
33
|
+
return firstError == null ? null : firstError;
|
|
34
|
+
};
|
|
35
|
+
validator.isRequired = function andIsRequired() {
|
|
36
|
+
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
37
|
+
args[_key2] = arguments[_key2];
|
|
38
|
+
}
|
|
39
|
+
var firstError = null;
|
|
40
|
+
validators.some(function(validatorFn) {
|
|
41
|
+
firstError = validatorFn.isRequired.apply(validatorFn, args);
|
|
42
|
+
return firstError != null;
|
|
43
|
+
});
|
|
44
|
+
return firstError == null ? null : firstError;
|
|
45
|
+
};
|
|
46
|
+
return (0, _wrapValidator["default"])(validator, name, validators);
|
|
47
|
+
}
|
|
48
|
+
})(and);
|
|
49
|
+
return and;
|
|
50
|
+
}
|
|
51
|
+
export {
|
|
52
|
+
requireAnd as __require
|
|
53
|
+
};
|
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
import { __exports as between } from "../../../../../_virtual/between.js";
|
|
2
|
+
import { __require as requireObject_entries } from "../../../../object.entries/index.js";
|
|
3
|
+
import { __require as requireShape } from "./shape.js";
|
|
4
|
+
import { __require as requireValuesOf } from "./valuesOf.js";
|
|
5
|
+
import { __require as requireWrapValidator } from "./helpers/wrapValidator.js";
|
|
6
|
+
var hasRequiredBetween;
|
|
7
|
+
function requireBetween() {
|
|
8
|
+
if (hasRequiredBetween) return between;
|
|
9
|
+
hasRequiredBetween = 1;
|
|
10
|
+
(function(exports) {
|
|
11
|
+
Object.defineProperty(exports, "__esModule", {
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
exports["default"] = betweenValidator;
|
|
15
|
+
var _object = _interopRequireDefault(requireObject_entries());
|
|
16
|
+
var _shape = _interopRequireDefault(requireShape());
|
|
17
|
+
var _valuesOf = _interopRequireDefault(requireValuesOf());
|
|
18
|
+
var _wrapValidator = _interopRequireDefault(requireWrapValidator());
|
|
19
|
+
function _interopRequireDefault(obj) {
|
|
20
|
+
return obj && obj.__esModule ? obj : { "default": obj };
|
|
21
|
+
}
|
|
22
|
+
function _typeof(obj) {
|
|
23
|
+
"@babel/helpers - typeof";
|
|
24
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
25
|
+
_typeof = function _typeof2(obj2) {
|
|
26
|
+
return typeof obj2;
|
|
27
|
+
};
|
|
28
|
+
} else {
|
|
29
|
+
_typeof = function _typeof2(obj2) {
|
|
30
|
+
return obj2 && typeof Symbol === "function" && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2;
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
return _typeof(obj);
|
|
34
|
+
}
|
|
35
|
+
function ownKeys(object, enumerableOnly) {
|
|
36
|
+
var keys = Object.keys(object);
|
|
37
|
+
if (Object.getOwnPropertySymbols) {
|
|
38
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
39
|
+
if (enumerableOnly) symbols = symbols.filter(function(sym) {
|
|
40
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
41
|
+
});
|
|
42
|
+
keys.push.apply(keys, symbols);
|
|
43
|
+
}
|
|
44
|
+
return keys;
|
|
45
|
+
}
|
|
46
|
+
function _objectSpread(target) {
|
|
47
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
48
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
49
|
+
if (i % 2) {
|
|
50
|
+
ownKeys(Object(source), true).forEach(function(key) {
|
|
51
|
+
_defineProperty(target, key, source[key]);
|
|
52
|
+
});
|
|
53
|
+
} else if (Object.getOwnPropertyDescriptors) {
|
|
54
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
55
|
+
} else {
|
|
56
|
+
ownKeys(Object(source)).forEach(function(key) {
|
|
57
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return target;
|
|
62
|
+
}
|
|
63
|
+
function _defineProperty(obj, key, value) {
|
|
64
|
+
if (key in obj) {
|
|
65
|
+
Object.defineProperty(obj, key, { value, enumerable: true, configurable: true, writable: true });
|
|
66
|
+
} else {
|
|
67
|
+
obj[key] = value;
|
|
68
|
+
}
|
|
69
|
+
return obj;
|
|
70
|
+
}
|
|
71
|
+
function _slicedToArray(arr, i) {
|
|
72
|
+
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
73
|
+
}
|
|
74
|
+
function _nonIterableRest() {
|
|
75
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
76
|
+
}
|
|
77
|
+
function _unsupportedIterableToArray(o, minLen) {
|
|
78
|
+
if (!o) return;
|
|
79
|
+
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
80
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
81
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
82
|
+
if (n === "Map" || n === "Set") return Array.from(o);
|
|
83
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
84
|
+
}
|
|
85
|
+
function _arrayLikeToArray(arr, len) {
|
|
86
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
87
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++) {
|
|
88
|
+
arr2[i] = arr[i];
|
|
89
|
+
}
|
|
90
|
+
return arr2;
|
|
91
|
+
}
|
|
92
|
+
function _iterableToArrayLimit(arr, i) {
|
|
93
|
+
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
|
|
94
|
+
var _arr = [];
|
|
95
|
+
var _n = true;
|
|
96
|
+
var _d = false;
|
|
97
|
+
var _e = void 0;
|
|
98
|
+
try {
|
|
99
|
+
for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
|
|
100
|
+
_arr.push(_s.value);
|
|
101
|
+
if (i && _arr.length === i) break;
|
|
102
|
+
}
|
|
103
|
+
} catch (err) {
|
|
104
|
+
_d = true;
|
|
105
|
+
_e = err;
|
|
106
|
+
} finally {
|
|
107
|
+
try {
|
|
108
|
+
if (!_n && _i["return"] != null) _i["return"]();
|
|
109
|
+
} finally {
|
|
110
|
+
if (_d) throw _e;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
return _arr;
|
|
114
|
+
}
|
|
115
|
+
function _arrayWithHoles(arr) {
|
|
116
|
+
if (Array.isArray(arr)) return arr;
|
|
117
|
+
}
|
|
118
|
+
function number(props, propName, componentName) {
|
|
119
|
+
var value = props[propName];
|
|
120
|
+
if (typeof value === "number" && !isNaN(value)) {
|
|
121
|
+
return null;
|
|
122
|
+
}
|
|
123
|
+
return new TypeError("".concat(componentName, ": ").concat(propName, " must be a non-NaN number."));
|
|
124
|
+
}
|
|
125
|
+
function numberOrPropsFunc(props, propName) {
|
|
126
|
+
var value = props[propName];
|
|
127
|
+
if (typeof value === "function") {
|
|
128
|
+
return null;
|
|
129
|
+
}
|
|
130
|
+
if (typeof value === "number" && !isNaN(value)) {
|
|
131
|
+
return null;
|
|
132
|
+
}
|
|
133
|
+
return new TypeError("".concat(propName, ": a function, or a non-NaN number is required"));
|
|
134
|
+
}
|
|
135
|
+
function lowerCompare(value, _ref) {
|
|
136
|
+
var gt = _ref.gt, gte = _ref.gte;
|
|
137
|
+
if (typeof gt === "number") {
|
|
138
|
+
return value > gt;
|
|
139
|
+
}
|
|
140
|
+
if (typeof gte === "number") {
|
|
141
|
+
return value >= gte;
|
|
142
|
+
}
|
|
143
|
+
return true;
|
|
144
|
+
}
|
|
145
|
+
function upperCompare(value, _ref2) {
|
|
146
|
+
var lt = _ref2.lt, lte = _ref2.lte;
|
|
147
|
+
if (typeof lt === "number") {
|
|
148
|
+
return value < lt;
|
|
149
|
+
}
|
|
150
|
+
if (typeof lte === "number") {
|
|
151
|
+
return value <= lte;
|
|
152
|
+
}
|
|
153
|
+
return true;
|
|
154
|
+
}
|
|
155
|
+
function greaterThanError(_ref3) {
|
|
156
|
+
var gt = _ref3.gt, gte = _ref3.gte;
|
|
157
|
+
if (typeof gt === "number") {
|
|
158
|
+
return "greater than ".concat(gt);
|
|
159
|
+
}
|
|
160
|
+
if (typeof gte === "number") {
|
|
161
|
+
return "greater than or equal to ".concat(gte);
|
|
162
|
+
}
|
|
163
|
+
return "";
|
|
164
|
+
}
|
|
165
|
+
function lessThanError(_ref4) {
|
|
166
|
+
var lt = _ref4.lt, lte = _ref4.lte;
|
|
167
|
+
if (typeof lt === "number") {
|
|
168
|
+
return "less than ".concat(lt);
|
|
169
|
+
}
|
|
170
|
+
if (typeof lte === "number") {
|
|
171
|
+
return "less than or equal to ".concat(lte);
|
|
172
|
+
}
|
|
173
|
+
return "";
|
|
174
|
+
}
|
|
175
|
+
function errorMessage(componentName, propName, opts) {
|
|
176
|
+
var errors = [greaterThanError(opts), lessThanError(opts)].filter(Boolean).join(" and ");
|
|
177
|
+
return "".concat(componentName, ": ").concat(propName, " must be ").concat(errors);
|
|
178
|
+
}
|
|
179
|
+
function propsThunkify(opts) {
|
|
180
|
+
return (0, _object["default"])(opts).reduce(function(acc, _ref5) {
|
|
181
|
+
var _ref6 = _slicedToArray(_ref5, 2), key = _ref6[0], value = _ref6[1];
|
|
182
|
+
var numberThunk = typeof value === "number" ? function() {
|
|
183
|
+
return value;
|
|
184
|
+
} : value;
|
|
185
|
+
return _objectSpread(_objectSpread({}, acc), {}, _defineProperty({}, key, numberThunk));
|
|
186
|
+
}, {});
|
|
187
|
+
}
|
|
188
|
+
function invokeWithProps(optsThunks, props) {
|
|
189
|
+
return (0, _object["default"])(optsThunks).reduce(function(acc, _ref7) {
|
|
190
|
+
var _ref8 = _slicedToArray(_ref7, 2), key = _ref8[0], thunk = _ref8[1];
|
|
191
|
+
var value = thunk(props);
|
|
192
|
+
return _objectSpread(_objectSpread({}, acc), {}, _defineProperty({}, key, value));
|
|
193
|
+
}, {});
|
|
194
|
+
}
|
|
195
|
+
var argValidators = [(0, _shape["default"])({
|
|
196
|
+
lt: numberOrPropsFunc,
|
|
197
|
+
gt: numberOrPropsFunc
|
|
198
|
+
}).isRequired, (0, _shape["default"])({
|
|
199
|
+
lte: numberOrPropsFunc,
|
|
200
|
+
gt: numberOrPropsFunc
|
|
201
|
+
}).isRequired, (0, _shape["default"])({
|
|
202
|
+
lt: numberOrPropsFunc,
|
|
203
|
+
gte: numberOrPropsFunc
|
|
204
|
+
}).isRequired, (0, _shape["default"])({
|
|
205
|
+
lte: numberOrPropsFunc,
|
|
206
|
+
gte: numberOrPropsFunc
|
|
207
|
+
}).isRequired, (0, _shape["default"])({
|
|
208
|
+
lt: numberOrPropsFunc
|
|
209
|
+
}).isRequired, (0, _shape["default"])({
|
|
210
|
+
lte: numberOrPropsFunc
|
|
211
|
+
}).isRequired, (0, _shape["default"])({
|
|
212
|
+
gt: numberOrPropsFunc
|
|
213
|
+
}).isRequired, (0, _shape["default"])({
|
|
214
|
+
gte: numberOrPropsFunc
|
|
215
|
+
}).isRequired];
|
|
216
|
+
function argValidator(props, propName) {
|
|
217
|
+
return argValidators.every(function(validator) {
|
|
218
|
+
return !!validator(props, propName);
|
|
219
|
+
});
|
|
220
|
+
}
|
|
221
|
+
var thunkValueValidator = (0, _valuesOf["default"])(number).isRequired;
|
|
222
|
+
function betweenValidator(options) {
|
|
223
|
+
var argError = argValidator({
|
|
224
|
+
options
|
|
225
|
+
}, "options");
|
|
226
|
+
if (argError) {
|
|
227
|
+
throw new TypeError("between: only one of the pairs of `lt`/`lte`, and `gt`/`gte`, may be supplied, and at least one pair must be provided.");
|
|
228
|
+
}
|
|
229
|
+
var optsThunks = propsThunkify(options);
|
|
230
|
+
var validator = function between2(props, propName, componentName) {
|
|
231
|
+
var propValue = props[propName];
|
|
232
|
+
if (propValue == null) {
|
|
233
|
+
return null;
|
|
234
|
+
}
|
|
235
|
+
if (typeof propValue !== "number") {
|
|
236
|
+
return new RangeError("".concat(componentName, ": ").concat(propName, ' must be a number, got "').concat(_typeof(propValue), '"'));
|
|
237
|
+
}
|
|
238
|
+
var opts = invokeWithProps(optsThunks, props);
|
|
239
|
+
for (var _len = arguments.length, rest = new Array(_len > 3 ? _len - 3 : 0), _key = 3; _key < _len; _key++) {
|
|
240
|
+
rest[_key - 3] = arguments[_key];
|
|
241
|
+
}
|
|
242
|
+
var thunkValuesError = thunkValueValidator.apply(void 0, [_defineProperty({}, propName, opts), propName, componentName].concat(rest));
|
|
243
|
+
if (thunkValuesError) {
|
|
244
|
+
return thunkValuesError;
|
|
245
|
+
}
|
|
246
|
+
if (!lowerCompare(propValue, opts) || !upperCompare(propValue, opts)) {
|
|
247
|
+
return new RangeError(errorMessage(componentName, propName, opts));
|
|
248
|
+
}
|
|
249
|
+
return null;
|
|
250
|
+
};
|
|
251
|
+
validator.isRequired = function betweenRequired(props, propName, componentName) {
|
|
252
|
+
var propValue = props[propName];
|
|
253
|
+
if (typeof propValue !== "number") {
|
|
254
|
+
return new RangeError("".concat(componentName, ": ").concat(propName, ' must be a number, got "').concat(_typeof(propValue), '"'));
|
|
255
|
+
}
|
|
256
|
+
var opts = invokeWithProps(optsThunks, props);
|
|
257
|
+
for (var _len2 = arguments.length, rest = new Array(_len2 > 3 ? _len2 - 3 : 0), _key2 = 3; _key2 < _len2; _key2++) {
|
|
258
|
+
rest[_key2 - 3] = arguments[_key2];
|
|
259
|
+
}
|
|
260
|
+
var thunkValuesError = thunkValueValidator.apply(void 0, [_defineProperty({}, propName, opts), propName, componentName].concat(rest));
|
|
261
|
+
if (thunkValuesError) {
|
|
262
|
+
return thunkValuesError;
|
|
263
|
+
}
|
|
264
|
+
if (!lowerCompare(propValue, opts) || !upperCompare(propValue, opts)) {
|
|
265
|
+
return new RangeError(errorMessage(componentName, propName, opts));
|
|
266
|
+
}
|
|
267
|
+
return null;
|
|
268
|
+
};
|
|
269
|
+
return (0, _wrapValidator["default"])(validator, "between", options);
|
|
270
|
+
}
|
|
271
|
+
})(between);
|
|
272
|
+
return between;
|
|
273
|
+
}
|
|
274
|
+
export {
|
|
275
|
+
requireBetween as __require
|
|
276
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { __exports as booleanSome } from "../../../../../_virtual/booleanSome.js";
|
|
2
|
+
import { __require as requirePropTypes } from "../../../../prop-types/index.js";
|
|
3
|
+
import { __require as requireWrapValidator } from "./helpers/wrapValidator.js";
|
|
4
|
+
var hasRequiredBooleanSome;
|
|
5
|
+
function requireBooleanSome() {
|
|
6
|
+
if (hasRequiredBooleanSome) return booleanSome;
|
|
7
|
+
hasRequiredBooleanSome = 1;
|
|
8
|
+
(function(exports) {
|
|
9
|
+
Object.defineProperty(exports, "__esModule", {
|
|
10
|
+
value: true
|
|
11
|
+
});
|
|
12
|
+
exports["default"] = booleanSomeValidator;
|
|
13
|
+
var _propTypes = requirePropTypes();
|
|
14
|
+
var _wrapValidator = _interopRequireDefault(requireWrapValidator());
|
|
15
|
+
function _interopRequireDefault(obj) {
|
|
16
|
+
return obj && obj.__esModule ? obj : { "default": obj };
|
|
17
|
+
}
|
|
18
|
+
function booleanSomeValidator() {
|
|
19
|
+
for (var _len = arguments.length, notAllPropsFalse = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
20
|
+
notAllPropsFalse[_key] = arguments[_key];
|
|
21
|
+
}
|
|
22
|
+
if (notAllPropsFalse.length < 1) {
|
|
23
|
+
throw new TypeError("at least one prop (one of which must be `true`) is required");
|
|
24
|
+
}
|
|
25
|
+
if (!notAllPropsFalse.every(function(x) {
|
|
26
|
+
return typeof x === "string";
|
|
27
|
+
})) {
|
|
28
|
+
throw new TypeError("all booleanSome props must be strings");
|
|
29
|
+
}
|
|
30
|
+
var propsList = notAllPropsFalse.join(", or ");
|
|
31
|
+
var validator = function booleanSome2(props, propName, componentName) {
|
|
32
|
+
var countFalse = function countFalse2(count, prop) {
|
|
33
|
+
return count + (props[prop] === false ? 1 : 0);
|
|
34
|
+
};
|
|
35
|
+
var falsePropCount = notAllPropsFalse.reduce(countFalse, 0);
|
|
36
|
+
if (falsePropCount === notAllPropsFalse.length) {
|
|
37
|
+
return new Error("A ".concat(componentName, " must have at least one of these boolean props be `true`: ").concat(propsList));
|
|
38
|
+
}
|
|
39
|
+
for (var _len2 = arguments.length, rest = new Array(_len2 > 3 ? _len2 - 3 : 0), _key2 = 3; _key2 < _len2; _key2++) {
|
|
40
|
+
rest[_key2 - 3] = arguments[_key2];
|
|
41
|
+
}
|
|
42
|
+
return _propTypes.bool.apply(void 0, [props, propName, componentName].concat(rest));
|
|
43
|
+
};
|
|
44
|
+
validator.isRequired = function booleanSomeRequired(props, propName, componentName) {
|
|
45
|
+
var countFalse = function countFalse2(count, prop) {
|
|
46
|
+
return count + (props[prop] === false ? 1 : 0);
|
|
47
|
+
};
|
|
48
|
+
var falsePropCount = notAllPropsFalse.reduce(countFalse, 0);
|
|
49
|
+
if (falsePropCount === notAllPropsFalse.length) {
|
|
50
|
+
return new Error("A ".concat(componentName, " must have at least one of these boolean props be `true`: ").concat(propsList));
|
|
51
|
+
}
|
|
52
|
+
for (var _len3 = arguments.length, rest = new Array(_len3 > 3 ? _len3 - 3 : 0), _key3 = 3; _key3 < _len3; _key3++) {
|
|
53
|
+
rest[_key3 - 3] = arguments[_key3];
|
|
54
|
+
}
|
|
55
|
+
return _propTypes.bool.isRequired.apply(_propTypes.bool, [props, propName, componentName].concat(rest));
|
|
56
|
+
};
|
|
57
|
+
return (0, _wrapValidator["default"])(validator, "booleanSome: ".concat(propsList), notAllPropsFalse);
|
|
58
|
+
}
|
|
59
|
+
})(booleanSome);
|
|
60
|
+
return booleanSome;
|
|
61
|
+
}
|
|
62
|
+
export {
|
|
63
|
+
requireBooleanSome as __require
|
|
64
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { __exports as childrenHavePropXorChildren } from "../../../../../_virtual/childrenHavePropXorChildren.js";
|
|
2
|
+
import React__default from "react";
|
|
3
|
+
import { __require as requireWrapValidator } from "./helpers/wrapValidator.js";
|
|
4
|
+
var hasRequiredChildrenHavePropXorChildren;
|
|
5
|
+
function requireChildrenHavePropXorChildren() {
|
|
6
|
+
if (hasRequiredChildrenHavePropXorChildren) return childrenHavePropXorChildren;
|
|
7
|
+
hasRequiredChildrenHavePropXorChildren = 1;
|
|
8
|
+
(function(exports) {
|
|
9
|
+
Object.defineProperty(exports, "__esModule", {
|
|
10
|
+
value: true
|
|
11
|
+
});
|
|
12
|
+
exports["default"] = childrenHavePropXorChildren2;
|
|
13
|
+
var _react = _interopRequireDefault(React__default);
|
|
14
|
+
var _wrapValidator = _interopRequireDefault(requireWrapValidator());
|
|
15
|
+
function _interopRequireDefault(obj) {
|
|
16
|
+
return obj && obj.__esModule ? obj : { "default": obj };
|
|
17
|
+
}
|
|
18
|
+
function _typeof(obj) {
|
|
19
|
+
"@babel/helpers - typeof";
|
|
20
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
21
|
+
_typeof = function _typeof2(obj2) {
|
|
22
|
+
return typeof obj2;
|
|
23
|
+
};
|
|
24
|
+
} else {
|
|
25
|
+
_typeof = function _typeof2(obj2) {
|
|
26
|
+
return obj2 && typeof Symbol === "function" && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2;
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
return _typeof(obj);
|
|
30
|
+
}
|
|
31
|
+
function childrenHavePropXorChildren2(prop) {
|
|
32
|
+
if (typeof prop !== "string" && _typeof(prop) !== "symbol") {
|
|
33
|
+
throw new TypeError("invalid prop: must be string or symbol");
|
|
34
|
+
}
|
|
35
|
+
var validator = function childrenHavePropXorChildrenWithProp(_ref, _, componentName) {
|
|
36
|
+
var children = _ref.children;
|
|
37
|
+
var truthyChildrenCount = 0;
|
|
38
|
+
var propCount = 0;
|
|
39
|
+
var grandchildrenCount = 0;
|
|
40
|
+
_react["default"].Children.forEach(children, function(child) {
|
|
41
|
+
if (!child) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
truthyChildrenCount += 1;
|
|
45
|
+
if (child.props[prop]) {
|
|
46
|
+
propCount += 1;
|
|
47
|
+
}
|
|
48
|
+
if (_react["default"].Children.count(child.props.children)) {
|
|
49
|
+
grandchildrenCount += 1;
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
if (propCount === truthyChildrenCount && grandchildrenCount === 0 || propCount === 0 && grandchildrenCount === truthyChildrenCount || propCount === 0 && grandchildrenCount === 0) {
|
|
53
|
+
return null;
|
|
54
|
+
}
|
|
55
|
+
return new TypeError("`".concat(componentName, "` requires children to all have prop “").concat(prop, "”, all have children, or all have neither."));
|
|
56
|
+
};
|
|
57
|
+
validator.isRequired = validator;
|
|
58
|
+
return (0, _wrapValidator["default"])(validator, "childrenHavePropXorChildrenWithProp:".concat(prop), prop);
|
|
59
|
+
}
|
|
60
|
+
})(childrenHavePropXorChildren);
|
|
61
|
+
return childrenHavePropXorChildren;
|
|
62
|
+
}
|
|
63
|
+
export {
|
|
64
|
+
requireChildrenHavePropXorChildren as __require
|
|
65
|
+
};
|