@sproutsocial/racine 20.12.0 → 20.13.5
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/CHANGELOG.md +36 -0
- package/README.md +1 -0
- package/__flow__/EnumLogoNames.flow.js +1 -1
- package/__flow__/LogoViewBoxes.js +2 -0
- package/__flow__/types/theme.colors.flow.js +2 -0
- package/commonjs/Avatar/Avatar.flow.js +2 -2
- package/commonjs/Avatar/Avatar.js +10 -12
- package/commonjs/Avatar/constants.flow.js +2 -3
- package/commonjs/Avatar/constants.js +2 -3
- package/commonjs/Avatar/index.js +1 -2
- package/commonjs/Badge/Badge.flow.js +2 -2
- package/commonjs/Badge/Badge.js +3 -4
- package/commonjs/Badge/constants.flow.js +2 -3
- package/commonjs/Badge/constants.js +3 -5
- package/commonjs/Badge/index.js +1 -2
- package/commonjs/Badge/styles.js +1 -2
- package/commonjs/Banner/Banner.flow.js +2 -2
- package/commonjs/Banner/Banner.js +3 -4
- package/commonjs/Banner/index.js +1 -2
- package/commonjs/Banner/styles.js +5 -7
- package/commonjs/Box/Box.flow.js +2 -2
- package/commonjs/Box/Box.js +3 -4
- package/commonjs/Box/index.js +1 -2
- package/commonjs/Box/styles.js +1 -2
- package/commonjs/Breadcrumb/Breadcrumb.flow.js +2 -2
- package/commonjs/Breadcrumb/Breadcrumb.js +5 -6
- package/commonjs/Breadcrumb/index.js +1 -2
- package/commonjs/Breadcrumb/styles.js +1 -2
- package/commonjs/Button/Button.flow.js +2 -2
- package/commonjs/Button/Button.js +1 -2
- package/commonjs/Button/index.js +1 -2
- package/commonjs/Button/styles.js +4 -8
- package/commonjs/Card/Card.flow.js +2 -2
- package/commonjs/Card/Card.js +3 -4
- package/commonjs/Card/CardTypes.flow.js +2 -2
- package/commonjs/Card/index.js +1 -2
- package/commonjs/Card/styles.js +9 -17
- package/commonjs/Card/subComponents.js +9 -15
- package/commonjs/Card/utils.js +4 -7
- package/commonjs/CharacterCounter/CharacterCounter.flow.js +2 -2
- package/commonjs/CharacterCounter/CharacterCounter.js +10 -12
- package/commonjs/CharacterCounter/index.js +1 -2
- package/commonjs/CharacterCounter/styles.js +3 -4
- package/commonjs/ChartLegend/ChartLegend.flow.js +2 -2
- package/commonjs/ChartLegend/ChartLegend.js +3 -4
- package/commonjs/ChartLegend/index.js +1 -2
- package/commonjs/ChartLegend/styles.js +5 -8
- package/commonjs/ChartLegend/useChartLabels.js +2 -3
- package/commonjs/Checkbox/Checkbox.flow.js +2 -2
- package/commonjs/Checkbox/Checkbox.js +11 -13
- package/commonjs/Checkbox/index.js +1 -2
- package/commonjs/Checkbox/styles.js +9 -16
- package/commonjs/Collapsible/Collapsible.flow.js +2 -2
- package/commonjs/Collapsible/Collapsible.js +13 -13
- package/commonjs/Collapsible/index.js +1 -2
- package/commonjs/Collapsible/styles.js +2 -3
- package/commonjs/DatePicker/DateRangePicker/DateRangePicker.flow.js +2 -2
- package/commonjs/DatePicker/DateRangePicker/DateRangePicker.js +3 -4
- package/commonjs/DatePicker/DateRangePicker/StatefulDateRangePicker.flow.js +2 -2
- package/commonjs/DatePicker/DateRangePicker/StatefulDateRangePicker.js +4 -5
- package/commonjs/DatePicker/DateRangePicker/index.js +1 -2
- package/commonjs/DatePicker/SingleDatePicker/SingleDatePicker.flow.js +2 -2
- package/commonjs/DatePicker/SingleDatePicker/SingleDatePicker.js +3 -4
- package/commonjs/DatePicker/SingleDatePicker/StatefulSingleDatePicker.flow.js +2 -2
- package/commonjs/DatePicker/SingleDatePicker/StatefulSingleDatePicker.js +4 -5
- package/commonjs/DatePicker/SingleDatePicker/index.js +1 -2
- package/commonjs/DatePicker/common.js +9 -15
- package/commonjs/DatePicker/index.flow.js +2 -2
- package/commonjs/DatePicker/styles.js +5 -7
- package/commonjs/Drawer/Drawer.flow.js +2 -2
- package/commonjs/Drawer/Drawer.js +11 -11
- package/commonjs/Drawer/SlideTransition.js +4 -5
- package/commonjs/Drawer/index.js +1 -2
- package/commonjs/Drawer/styles.js +4 -6
- package/commonjs/EmptyState/EmptyState.flow.js +2 -2
- package/commonjs/EmptyState/EmptyState.js +3 -4
- package/commonjs/EmptyState/index.js +1 -2
- package/commonjs/Fieldset/Fieldset.flow.js +2 -2
- package/commonjs/Fieldset/Fieldset.js +3 -4
- package/commonjs/Fieldset/index.js +1 -2
- package/commonjs/Fieldset/styles.js +4 -5
- package/commonjs/FormField/FormField.flow.js +2 -2
- package/commonjs/FormField/FormField.js +5 -6
- package/commonjs/FormField/index.js +1 -2
- package/commonjs/Icon/Icon.flow.js +2 -2
- package/commonjs/Icon/Icon.js +5 -6
- package/commonjs/Icon/index.flow.js +2 -2
- package/commonjs/Icon/index.js +1 -2
- package/commonjs/Icon/styles.js +3 -4
- package/commonjs/Image/Image.flow.js +2 -2
- package/commonjs/Image/Image.js +11 -13
- package/commonjs/Image/index.js +1 -2
- package/commonjs/Image/styles.js +3 -4
- package/commonjs/Indicator/Indicator.flow.js +2 -2
- package/commonjs/Indicator/Indicator.js +10 -12
- package/commonjs/Indicator/index.js +1 -2
- package/commonjs/Indicator/styles.js +1 -2
- package/commonjs/Input/Input.flow.js +2 -2
- package/commonjs/Input/Input.js +12 -13
- package/commonjs/Input/index.js +1 -2
- package/commonjs/Input/styles.js +4 -6
- package/commonjs/KeyboardKey/KeyboardKey.flow.js +2 -2
- package/commonjs/KeyboardKey/KeyboardKey.js +11 -13
- package/commonjs/KeyboardKey/index.js +1 -2
- package/commonjs/KeyboardKey/styles.js +1 -2
- package/commonjs/Label/Label.flow.js +2 -2
- package/commonjs/Label/Label.js +11 -13
- package/commonjs/Label/index.js +1 -2
- package/commonjs/Link/Link.flow.js +2 -2
- package/commonjs/Link/Link.js +3 -4
- package/commonjs/Link/constants.js +1 -2
- package/commonjs/Link/index.js +1 -2
- package/commonjs/Link/styles.js +3 -4
- package/commonjs/Listbox/Listbox.flow.js +2 -2
- package/commonjs/Listbox/Listbox.js +8 -12
- package/commonjs/Listbox/index.js +3 -4
- package/commonjs/Loader/Loader.flow.js +2 -2
- package/commonjs/Loader/Loader.js +10 -12
- package/commonjs/Loader/index.js +1 -2
- package/commonjs/Loader/styles.js +4 -6
- package/commonjs/LoaderButton/LoaderButton.flow.js +2 -2
- package/commonjs/LoaderButton/LoaderButton.js +4 -6
- package/commonjs/LoaderButton/index.js +1 -2
- package/commonjs/LogoViewBoxes.js +2 -0
- package/commonjs/Menu/Menu.flow.js +2 -2
- package/commonjs/Menu/Menu.js +42 -50
- package/commonjs/Menu/index.js +3 -4
- package/commonjs/Menu/styles.js +5 -7
- package/commonjs/Menu/utils/constants.flow.js +3 -5
- package/commonjs/Menu/utils/constants.js +3 -5
- package/commonjs/Menu/utils/descendants.js +17 -16
- package/commonjs/Menu/utils/hooks.js +3 -6
- package/commonjs/Message/Message.flow.js +3 -4
- package/commonjs/Message/Message.js +3 -4
- package/commonjs/Message/constants.js +2 -3
- package/commonjs/Message/index.js +1 -2
- package/commonjs/Message/styles.js +5 -10
- package/commonjs/Modal/Modal.flow.js +2 -2
- package/commonjs/Modal/Modal.js +7 -7
- package/commonjs/Modal/index.js +1 -2
- package/commonjs/Modal/styles.js +8 -14
- package/commonjs/Numeral/Numeral.flow.js +2 -2
- package/commonjs/Numeral/Numeral.js +3 -4
- package/commonjs/Numeral/constants.js +7 -13
- package/commonjs/Numeral/index.js +1 -2
- package/commonjs/Numeral/styles.js +3 -5
- package/commonjs/PartnerLogo/PartnerLogo.flow.js +2 -2
- package/commonjs/PartnerLogo/PartnerLogo.js +1 -2
- package/commonjs/PartnerLogo/PartnerLogoTypes.js +4 -6
- package/commonjs/PartnerLogo/index.js +1 -2
- package/commonjs/PartnerLogo/styles.js +3 -4
- package/commonjs/Popout/Popout.flow.js +2 -2
- package/commonjs/Popout/Popout.js +21 -22
- package/commonjs/Popout/index.js +1 -2
- package/commonjs/Popout/styles.js +2 -3
- package/commonjs/Portal/Portal.flow.js +2 -2
- package/commonjs/Portal/Portal.js +11 -13
- package/commonjs/Portal/index.js +1 -2
- package/commonjs/Radio/Radio.flow.js +2 -2
- package/commonjs/Radio/Radio.js +11 -13
- package/commonjs/Radio/index.js +1 -2
- package/commonjs/Radio/styles.js +6 -10
- package/commonjs/SegmentedControl/SegmentedControl.flow.js +2 -2
- package/commonjs/SegmentedControl/SegmentedControl.js +8 -8
- package/commonjs/SegmentedControl/index.js +1 -2
- package/commonjs/SegmentedControl/styles.js +6 -9
- package/commonjs/Select/Select.flow.js +2 -2
- package/commonjs/Select/Select.js +11 -13
- package/commonjs/Select/index.js +1 -2
- package/commonjs/Select/styles.js +4 -6
- package/commonjs/Skeleton/Skeleton.js +1 -2
- package/commonjs/Skeleton/index.js +1 -2
- package/commonjs/SpotIllustration/SpotIllustration.flow.js +2 -2
- package/commonjs/SpotIllustration/SpotIllustration.js +3 -4
- package/commonjs/SpotIllustration/illustrationNames.js +1 -2
- package/commonjs/SpotIllustration/index.js +1 -2
- package/commonjs/Stack/Stack.flow.js +2 -2
- package/commonjs/Stack/Stack.js +6 -6
- package/commonjs/Stack/index.js +1 -2
- package/commonjs/Switch/Switch.flow.js +2 -2
- package/commonjs/Switch/Switch.js +3 -4
- package/commonjs/Switch/index.js +1 -2
- package/commonjs/Switch/styles.js +4 -5
- package/commonjs/Table/Table.flow.js +2 -2
- package/commonjs/Table/Table.js +7 -12
- package/commonjs/Table/index.js +1 -2
- package/commonjs/Table/styles.js +1 -2
- package/commonjs/TableCell/TableCell.flow.js +2 -2
- package/commonjs/TableCell/TableCell.js +11 -14
- package/commonjs/TableCell/index.js +1 -2
- package/commonjs/TableCell/styles.js +1 -2
- package/commonjs/TableHeaderCell/TableHeaderCell.flow.js +4 -5
- package/commonjs/TableHeaderCell/TableHeaderCell.js +12 -15
- package/commonjs/TableHeaderCell/constants.js +2 -3
- package/commonjs/TableHeaderCell/index.js +1 -2
- package/commonjs/TableHeaderCell/styles.js +5 -8
- package/commonjs/TableRowAccordion/TableRowAccordion.flow.js +2 -2
- package/commonjs/TableRowAccordion/TableRowAccordion.js +12 -14
- package/commonjs/TableRowAccordion/index.js +1 -2
- package/commonjs/TableRowAccordion/styles.js +5 -8
- package/commonjs/Tabs/Tabs.flow.js +2 -2
- package/commonjs/Tabs/Tabs.js +12 -15
- package/commonjs/Tabs/index.js +1 -2
- package/commonjs/Tabs/styles.js +5 -8
- package/commonjs/Text/Text.flow.js +2 -2
- package/commonjs/Text/Text.js +3 -4
- package/commonjs/Text/index.js +1 -2
- package/commonjs/Text/styles.js +3 -4
- package/commonjs/Textarea/Textarea.flow.js +2 -2
- package/commonjs/Textarea/Textarea.js +11 -13
- package/commonjs/Textarea/index.js +1 -2
- package/commonjs/Textarea/styles.js +4 -6
- package/commonjs/ThemeProvider/index.flow.js +2 -2
- package/commonjs/ThemeProvider/index.js +3 -4
- package/commonjs/Toast/Toast.flow.js +2 -2
- package/commonjs/Toast/Toast.js +3 -4
- package/commonjs/Toast/index.js +3 -4
- package/commonjs/Toast/styles.js +6 -8
- package/commonjs/ToggleHint/ToggleHint.flow.js +2 -2
- package/commonjs/ToggleHint/ToggleHint.js +11 -13
- package/commonjs/ToggleHint/index.js +1 -2
- package/commonjs/ToggleHint/styles.js +4 -6
- package/commonjs/Token/Token.flow.js +2 -2
- package/commonjs/Token/Token.js +3 -4
- package/commonjs/Token/index.js +3 -4
- package/commonjs/Token/styles.js +3 -4
- package/commonjs/TokenInput/TokenInput.flow.js +2 -2
- package/commonjs/TokenInput/TokenInput.js +12 -14
- package/commonjs/TokenInput/TokenScreenReaderStatus.js +4 -5
- package/commonjs/TokenInput/index.js +1 -2
- package/commonjs/TokenInput/styles.js +3 -4
- package/commonjs/TokenInput/util.js +3 -5
- package/commonjs/Tooltip/Tooltip.flow.js +2 -2
- package/commonjs/Tooltip/Tooltip.js +11 -11
- package/commonjs/Tooltip/index.js +1 -2
- package/commonjs/Tooltip/styles.js +2 -3
- package/commonjs/VisuallyHidden/VisuallyHidden.flow.js +2 -2
- package/commonjs/VisuallyHidden/VisuallyHidden.js +2 -3
- package/commonjs/illustrationNames.js +1 -2
- package/commonjs/index.flow.js +2 -2
- package/commonjs/logoNames.js +1 -2
- package/commonjs/systemProps/background.flow.js +1 -2
- package/commonjs/systemProps/border.flow.js +1 -2
- package/commonjs/systemProps/color.flow.js +1 -2
- package/commonjs/systemProps/custom.flow.js +2 -3
- package/commonjs/systemProps/flexbox.flow.js +1 -2
- package/commonjs/systemProps/grid.flow.js +1 -2
- package/commonjs/systemProps/index.js +5 -7
- package/commonjs/systemProps/layout.flow.js +1 -2
- package/commonjs/systemProps/position.flow.js +1 -2
- package/commonjs/systemProps/shadow.flow.js +1 -2
- package/commonjs/systemProps/space.flow.js +1 -2
- package/commonjs/systemProps/systemProps.flow.js +1 -2
- package/commonjs/systemProps/typography.flow.js +1 -2
- package/commonjs/systemProps/variant.flow.js +2 -3
- package/commonjs/themes/dark/dataviz-palette.js +2 -3
- package/commonjs/themes/dark/decorative-palettes.js +12 -23
- package/commonjs/themes/dark/theme.js +5 -6
- package/commonjs/themes/extendedThemes/sproutTheme/dark/theme.flow.js +1 -2
- package/commonjs/themes/extendedThemes/sproutTheme/dark/theme.js +9 -16
- package/commonjs/themes/extendedThemes/sproutTheme/light/theme.js +9 -16
- package/commonjs/themes/light/dataviz-palette.js +2 -3
- package/commonjs/themes/light/decorative-palettes.js +12 -23
- package/commonjs/themes/light/literal-colors.js +1 -2
- package/commonjs/themes/light/theme.js +22 -34
- package/commonjs/types/shared.flow.js +2 -2
- package/commonjs/types/styled-components.flow.js +2 -2
- package/commonjs/utils/a11yTest.js +2 -3
- package/commonjs/utils/chartColors.js +5 -9
- package/commonjs/utils/constants.js +1 -2
- package/commonjs/utils/dataQaLabelQueries.js +2 -3
- package/commonjs/utils/hooks.flow.js +1 -0
- package/commonjs/utils/hooks.js +4 -6
- package/commonjs/utils/index.js +2 -4
- package/commonjs/utils/innerText.flow.js +2 -2
- package/commonjs/utils/innerText.js +1 -2
- package/commonjs/utils/mixins.js +5 -10
- package/commonjs/utils/react-testing-library.flow.js +2 -2
- package/commonjs/utils/react-testing-library.js +5 -8
- package/commonjs/utils/responsiveProps/index.js +2 -3
- package/commonjs/utils/system-props/gap.js +2 -3
- package/commonjs/utils/system-props/system-props.js +9 -16
- package/commonjs/utils/useInteractiveColor.js +2 -3
- package/dist/logo.svg +1 -1
- package/dist/logoList.js +1 -1
- package/dist/themes/dark/theme.scss +2 -1
- package/dist/themes/extendedThemes/sproutTheme/dark/theme.scss +2 -1
- package/dist/themes/extendedThemes/sproutTheme/light/theme.scss +4 -2
- package/dist/themes/light/theme.scss +4 -2
- package/dist/types/Button/styles.d.ts.map +1 -1
- package/dist/types/EnumLogoNames.d.ts +1 -1
- package/dist/types/EnumLogoNames.d.ts.map +1 -1
- package/dist/types/PartnerLogo/PartnerLogoTypes.d.ts +1 -1
- package/dist/types/PartnerLogo/PartnerLogoTypes.d.ts.map +1 -1
- package/dist/types/logoNames.d.ts +1 -1
- package/dist/types/logoNames.d.ts.map +1 -1
- package/dist/types/themes/dark/theme.d.ts +19 -18
- package/dist/types/themes/dark/theme.d.ts.map +1 -1
- package/dist/types/themes/light/theme.d.ts +29 -27
- package/dist/types/themes/light/theme.d.ts.map +1 -1
- package/dist/types/types/theme.colors.d.ts +2 -0
- package/dist/types/types/theme.colors.d.ts.map +1 -1
- package/lib/Breadcrumb/Breadcrumb.js +2 -2
- package/lib/Button/styles.js +1 -4
- package/lib/CharacterCounter/CharacterCounter.js +7 -8
- package/lib/Checkbox/Checkbox.js +8 -9
- package/lib/Collapsible/Collapsible.js +2 -2
- package/lib/Drawer/Drawer.js +2 -2
- package/lib/FormField/FormField.js +2 -2
- package/lib/Icon/Icon.js +2 -2
- package/lib/Image/Image.js +8 -9
- package/lib/Indicator/Indicator.js +7 -8
- package/lib/Input/Input.js +9 -9
- package/lib/KeyboardKey/KeyboardKey.js +7 -8
- package/lib/Label/Label.js +7 -8
- package/lib/Listbox/Listbox.js +2 -2
- package/lib/Loader/Loader.js +7 -8
- package/lib/LogoViewBoxes.js +2 -0
- package/lib/Menu/Menu.js +2 -2
- package/lib/Menu/utils/descendants.js +2 -2
- package/lib/Popout/Popout.js +2 -2
- package/lib/Portal/Portal.js +8 -9
- package/lib/Radio/Radio.js +8 -9
- package/lib/Select/Select.js +8 -9
- package/lib/TableCell/TableCell.js +7 -8
- package/lib/TableHeaderCell/TableHeaderCell.js +8 -9
- package/lib/TableRowAccordion/TableRowAccordion.js +8 -9
- package/lib/Tabs/Tabs.js +9 -11
- package/lib/Textarea/Textarea.js +8 -9
- package/lib/ToggleHint/ToggleHint.js +8 -9
- package/lib/TokenInput/TokenInput.js +8 -9
- package/lib/Tooltip/Tooltip.js +2 -2
- package/lib/logoNames.js +1 -1
- package/lib/systemProps/space.flow.js +14 -0
- package/lib/themes/dark/theme.js +2 -2
- package/lib/themes/extendedThemes/sproutTheme/dark/theme.js +2 -2
- package/lib/themes/extendedThemes/sproutTheme/light/theme.js +2 -2
- package/lib/themes/light/theme.js +7 -4
- package/lib/utils/hooks.flow.js +1 -0
- package/lib/utils/hooks.js +2 -2
- package/lib/utils/react-testing-library.js +2 -2
- package/package.json +16 -24
package/commonjs/Menu/index.js
CHANGED
|
@@ -58,7 +58,6 @@ Object.keys(_utils).forEach(function (key) {
|
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
});
|
|
61
|
-
function _getRequireWildcardCache(
|
|
62
|
-
function _interopRequireWildcard(
|
|
63
|
-
var _default = _Menu.default;
|
|
64
|
-
exports.default = _default;
|
|
61
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
62
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
63
|
+
var _default = exports.default = _Menu.default;
|
package/commonjs/Menu/styles.js
CHANGED
|
@@ -10,9 +10,9 @@ var _mixins = require("../utils/mixins");
|
|
|
10
10
|
var _Box = _interopRequireDefault(require("../Box"));
|
|
11
11
|
var _styles = require("../Switch/styles");
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
-
function _getRequireWildcardCache(
|
|
14
|
-
function _interopRequireWildcard(
|
|
15
|
-
var MenuItemContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
13
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
14
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
15
|
+
var MenuItemContainer = exports.MenuItemContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
16
16
|
displayName: "styles__MenuItemContainer",
|
|
17
17
|
componentId: "sc-168zlb1-0"
|
|
18
18
|
})(["", ";width:100%;border-radius:", ";background-color:", ";border:none;text-align:left;color:", ";font-family:", ";font-weight:", ";padding:", ";list-style-type:none;outline:0;", ";", " ", " ", "{", "}", " ", " ", ""], function (props) {
|
|
@@ -56,9 +56,7 @@ var MenuItemContainer = (0, _styledComponents.default)(_Box.default).withConfig(
|
|
|
56
56
|
}, function (props) {
|
|
57
57
|
return props.disabled && _mixins.disabled;
|
|
58
58
|
});
|
|
59
|
-
exports.
|
|
60
|
-
var MenuItemsContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
59
|
+
var MenuItemsContainer = exports.MenuItemsContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
61
60
|
displayName: "styles__MenuItemsContainer",
|
|
62
61
|
componentId: "sc-168zlb1-1"
|
|
63
|
-
})(["list-style-type:none;&:focus{", "}& > div[role='group']:first-of-type{border-top:none;}"], _mixins.focusRing);
|
|
64
|
-
exports.MenuItemsContainer = MenuItemsContainer;
|
|
62
|
+
})(["list-style-type:none;&:focus{", "}& > div[role='group']:first-of-type{border-top:none;}"], _mixins.focusRing);
|
|
@@ -4,17 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.MENU_ROLES = exports.MENU_ITEM_ROLES = void 0;
|
|
7
|
-
var MENU_ROLES = Object.freeze({
|
|
7
|
+
var MENU_ROLES = exports.MENU_ROLES = Object.freeze({
|
|
8
8
|
MENU: 'menu',
|
|
9
9
|
LIST: 'list',
|
|
10
10
|
LISTBOX: 'listbox'
|
|
11
11
|
});
|
|
12
|
-
exports.
|
|
13
|
-
var MENU_ITEM_ROLES = Object.freeze({
|
|
12
|
+
var MENU_ITEM_ROLES = exports.MENU_ITEM_ROLES = Object.freeze({
|
|
14
13
|
MENUITEM: 'menuitem',
|
|
15
14
|
LISTITEM: 'listitem',
|
|
16
15
|
OPTION: 'option',
|
|
17
16
|
RADIO: 'menuitemradio',
|
|
18
17
|
CHECKBOX: 'menuitemcheckbox'
|
|
19
|
-
});
|
|
20
|
-
exports.MENU_ITEM_ROLES = MENU_ITEM_ROLES;
|
|
18
|
+
});
|
|
@@ -4,17 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.MENU_ROLES = exports.MENU_ITEM_ROLES = void 0;
|
|
7
|
-
var MENU_ROLES = Object.freeze({
|
|
7
|
+
var MENU_ROLES = exports.MENU_ROLES = Object.freeze({
|
|
8
8
|
MENU: 'menu',
|
|
9
9
|
LIST: 'list',
|
|
10
10
|
LISTBOX: 'listbox'
|
|
11
11
|
});
|
|
12
|
-
exports.
|
|
13
|
-
var MENU_ITEM_ROLES = Object.freeze({
|
|
12
|
+
var MENU_ITEM_ROLES = exports.MENU_ITEM_ROLES = Object.freeze({
|
|
14
13
|
MENUITEM: 'menuitem',
|
|
15
14
|
LISTITEM: 'listitem',
|
|
16
15
|
OPTION: 'option',
|
|
17
16
|
RADIO: 'menuitemradio',
|
|
18
17
|
CHECKBOX: 'menuitemcheckbox'
|
|
19
|
-
});
|
|
20
|
-
exports.MENU_ITEM_ROLES = MENU_ITEM_ROLES;
|
|
18
|
+
});
|
|
@@ -12,11 +12,12 @@ exports.useDescendantKeyDown = useDescendantKeyDown;
|
|
|
12
12
|
exports.useDescendants = useDescendants;
|
|
13
13
|
exports.usePrevious = usePrevious;
|
|
14
14
|
exports.wrapEvent = wrapEvent;
|
|
15
|
-
var
|
|
15
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
16
|
+
var React = _react;
|
|
16
17
|
var _excluded = ["context", "element"],
|
|
17
18
|
_excluded2 = ["element"];
|
|
18
|
-
function _getRequireWildcardCache(
|
|
19
|
-
function _interopRequireWildcard(
|
|
19
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
20
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
20
21
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
21
22
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
22
23
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -33,8 +34,8 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
33
34
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
34
35
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
35
36
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
36
|
-
function _toPropertyKey(
|
|
37
|
-
function _toPrimitive(
|
|
37
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
38
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /* eslint-disable */
|
|
38
39
|
/**
|
|
39
40
|
* These hooks and utilities are largely copied from the @reach-ui/descendents package. They consider the package
|
|
40
41
|
* pre-release and unstable, so instead of importing it, we copied it here and changed the types from TypeScript to
|
|
@@ -49,8 +50,8 @@ var noop = function noop() {};
|
|
|
49
50
|
* @param value
|
|
50
51
|
*/
|
|
51
52
|
function usePrevious(value) {
|
|
52
|
-
var ref = (0,
|
|
53
|
-
(0,
|
|
53
|
+
var ref = (0, _react.useRef)(null);
|
|
54
|
+
(0, _react.useEffect)(function () {
|
|
54
55
|
ref.current = value;
|
|
55
56
|
}, [value]);
|
|
56
57
|
return ref.current;
|
|
@@ -75,9 +76,9 @@ function wrapEvent(theirHandler, ourHandler) {
|
|
|
75
76
|
function canUseDOM() {
|
|
76
77
|
return typeof window !== 'undefined' && typeof window.document !== 'undefined' && typeof window.document.createElement !== 'undefined';
|
|
77
78
|
}
|
|
78
|
-
var useIsomorphicLayoutEffect = canUseDOM() ?
|
|
79
|
+
var useIsomorphicLayoutEffect = canUseDOM() ? _react.useLayoutEffect : _react.useEffect;
|
|
79
80
|
function createNamedContext(name, defaultValue) {
|
|
80
|
-
var Ctx = /*#__PURE__*/(0,
|
|
81
|
+
var Ctx = /*#__PURE__*/(0, _react.createContext)(defaultValue);
|
|
81
82
|
Ctx.displayName = name;
|
|
82
83
|
return Ctx;
|
|
83
84
|
}
|
|
@@ -117,10 +118,10 @@ function useDescendant(_ref, indexProp) {
|
|
|
117
118
|
var context = _ref.context,
|
|
118
119
|
element = _ref.element,
|
|
119
120
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
120
|
-
var _useState = (0,
|
|
121
|
+
var _useState = (0, _react.useState)(),
|
|
121
122
|
_useState2 = _slicedToArray(_useState, 2),
|
|
122
123
|
forceUpdate = _useState2[1];
|
|
123
|
-
var _useContext = (0,
|
|
124
|
+
var _useContext = (0, _react.useContext)(context),
|
|
124
125
|
registerDescendant = _useContext.registerDescendant,
|
|
125
126
|
unregisterDescendant = _useContext.unregisterDescendant,
|
|
126
127
|
descendants = _useContext.descendants;
|
|
@@ -139,14 +140,14 @@ function useDescendant(_ref, indexProp) {
|
|
|
139
140
|
});
|
|
140
141
|
}
|
|
141
142
|
function useDescendants() {
|
|
142
|
-
return (0,
|
|
143
|
+
return (0, _react.useState)([]);
|
|
143
144
|
}
|
|
144
145
|
function DescendantProvider(_ref2) {
|
|
145
146
|
var Ctx = _ref2.context,
|
|
146
147
|
children = _ref2.children,
|
|
147
148
|
items = _ref2.items,
|
|
148
149
|
set = _ref2.set;
|
|
149
|
-
var registerDescendant = (0,
|
|
150
|
+
var registerDescendant = (0, _react.useCallback)(function (_ref3) {
|
|
150
151
|
var element = _ref3.element,
|
|
151
152
|
rest = _objectWithoutProperties(_ref3, _excluded2);
|
|
152
153
|
if (!element) {
|
|
@@ -216,7 +217,7 @@ function DescendantProvider(_ref2) {
|
|
|
216
217
|
// between renders.
|
|
217
218
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
218
219
|
[]);
|
|
219
|
-
var unregisterDescendant = (0,
|
|
220
|
+
var unregisterDescendant = (0, _react.useCallback)(function (element) {
|
|
220
221
|
if (!element) {
|
|
221
222
|
return;
|
|
222
223
|
}
|
|
@@ -235,7 +236,7 @@ function DescendantProvider(_ref2) {
|
|
|
235
236
|
// between renders.
|
|
236
237
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
237
238
|
[]);
|
|
238
|
-
var value = (0,
|
|
239
|
+
var value = (0, _react.useMemo)(function () {
|
|
239
240
|
return {
|
|
240
241
|
descendants: items,
|
|
241
242
|
registerDescendant: registerDescendant,
|
|
@@ -247,7 +248,7 @@ function DescendantProvider(_ref2) {
|
|
|
247
248
|
}, children);
|
|
248
249
|
}
|
|
249
250
|
function useDescendantKeyDown(context, options) {
|
|
250
|
-
var _useContext2 = (0,
|
|
251
|
+
var _useContext2 = (0, _react.useContext)(context),
|
|
251
252
|
descendants = _useContext2.descendants;
|
|
252
253
|
var callback = options.callback,
|
|
253
254
|
currentIndex = options.currentIndex,
|
|
@@ -12,7 +12,7 @@ var _descendants = require("./descendants");
|
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
13
|
// eslint-disable @typescript-eslint/no-explicit-any
|
|
14
14
|
|
|
15
|
-
var MenuContext = /*#__PURE__*/(0, _react.createContext)({
|
|
15
|
+
var MenuContext = exports.MenuContext = /*#__PURE__*/(0, _react.createContext)({
|
|
16
16
|
role: _constants.MENU_ROLES.MENU,
|
|
17
17
|
menuRef: {
|
|
18
18
|
current: null
|
|
@@ -33,20 +33,17 @@ var MenuContext = /*#__PURE__*/(0, _react.createContext)({
|
|
|
33
33
|
current: []
|
|
34
34
|
}
|
|
35
35
|
});
|
|
36
|
-
exports.
|
|
37
|
-
var MenuButtonContext = /*#__PURE__*/(0, _react.createContext)({
|
|
36
|
+
var MenuButtonContext = exports.MenuButtonContext = /*#__PURE__*/(0, _react.createContext)({
|
|
38
37
|
closeOnItemClick: undefined,
|
|
39
38
|
closePopout: undefined
|
|
40
39
|
});
|
|
41
|
-
exports.
|
|
42
|
-
var MenuDescendantContext = (0, _descendants.createDescendantContext)('MenuDescendantContext');
|
|
40
|
+
var MenuDescendantContext = exports.MenuDescendantContext = (0, _descendants.createDescendantContext)('MenuDescendantContext');
|
|
43
41
|
|
|
44
42
|
/**
|
|
45
43
|
* When a user's typed input matches the string displayed in a menu item, it is
|
|
46
44
|
* expected that the matching menu item is selected. This is our matching
|
|
47
45
|
* function.
|
|
48
46
|
*/
|
|
49
|
-
exports.MenuDescendantContext = MenuDescendantContext;
|
|
50
47
|
function filterItemsFromTypeahead(items) {
|
|
51
48
|
var string = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
52
49
|
if (!string) {
|
|
@@ -6,16 +6,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.MESSAGE_DENSITIES = void 0;
|
|
8
8
|
var React = _interopRequireWildcard(require("react"));
|
|
9
|
-
function _getRequireWildcardCache(
|
|
10
|
-
function _interopRequireWildcard(
|
|
11
|
-
var MESSAGE_DENSITIES = {
|
|
9
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
10
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
11
|
+
var MESSAGE_DENSITIES = exports.MESSAGE_DENSITIES = {
|
|
12
12
|
COMPACT: 'compact',
|
|
13
13
|
// Compact is deprecated. New applications should use condensed instead.
|
|
14
14
|
CONDENSED: 'condensed',
|
|
15
15
|
SMALL: 'small',
|
|
16
16
|
LARGE: 'large'
|
|
17
17
|
};
|
|
18
|
-
exports.MESSAGE_DENSITIES = MESSAGE_DENSITIES;
|
|
19
18
|
// Using `Object.freeze` on MESSAGE_DENSITIES causes breaking type changes, but this is needed for typing Message.DENSITIES
|
|
20
19
|
// This should be improved in the future during a major version bump and Message refactor
|
|
21
20
|
var MESSAGE_DENSITIES_FROZEN = Object.freeze(MESSAGE_DENSITIES);
|
|
@@ -13,8 +13,8 @@ var _styles = _interopRequireWildcard(require("./styles"));
|
|
|
13
13
|
var _constants = require("./constants");
|
|
14
14
|
var _excluded = ["children", "density", "borderColor", "bg", "indentContent", "innerRef", "qa"];
|
|
15
15
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
16
|
-
function _getRequireWildcardCache(
|
|
17
|
-
function _interopRequireWildcard(
|
|
16
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
17
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
18
18
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
19
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
20
20
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
@@ -151,5 +151,4 @@ MessageCheckbox.displayName = 'Message.Checkbox';
|
|
|
151
151
|
Message.Checkbox = MessageCheckbox;
|
|
152
152
|
Message.Context = MessageContext;
|
|
153
153
|
Message.DENSITIES = _constants.MESSAGE_DENSITIES;
|
|
154
|
-
var _default = Message;
|
|
155
|
-
exports.default = _default;
|
|
154
|
+
var _default = exports.default = Message;
|
|
@@ -4,11 +4,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.MESSAGE_DENSITIES = void 0;
|
|
7
|
-
var MESSAGE_DENSITIES = {
|
|
7
|
+
var MESSAGE_DENSITIES = exports.MESSAGE_DENSITIES = {
|
|
8
8
|
COMPACT: 'compact',
|
|
9
9
|
// Compact is deprecated. New applications should use condensed instead.
|
|
10
10
|
CONDENSED: 'condensed',
|
|
11
11
|
SMALL: 'small',
|
|
12
12
|
LARGE: 'large'
|
|
13
|
-
};
|
|
14
|
-
exports.MESSAGE_DENSITIES = MESSAGE_DENSITIES;
|
|
13
|
+
};
|
|
@@ -39,5 +39,4 @@ Object.keys(_constants).forEach(function (key) {
|
|
|
39
39
|
});
|
|
40
40
|
});
|
|
41
41
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
42
|
-
var _default = _Message.default;
|
|
43
|
-
exports.default = _default;
|
|
42
|
+
var _default = exports.default = _Message.default;
|
|
@@ -21,7 +21,7 @@ var Container = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
21
21
|
return props.theme.colors[props.bg];
|
|
22
22
|
}, _mixins.focusRing);
|
|
23
23
|
Container.displayName = 'Message.Container';
|
|
24
|
-
var MessageHeader = /*#__PURE__*/(0, _react.memo)((0, _styledComponents.default)(_Box.default).withConfig({
|
|
24
|
+
var MessageHeader = exports.MessageHeader = /*#__PURE__*/(0, _react.memo)((0, _styledComponents.default)(_Box.default).withConfig({
|
|
25
25
|
displayName: "styles__MessageHeader",
|
|
26
26
|
componentId: "sc-161ezbx-1"
|
|
27
27
|
})(["padding:", ";display:flex;justify-content:space-between;align-items:center;border-bottom-width:", ";border-bottom-style:solid;border-radius:", " ", " 0 0;", ";"], function (props) {
|
|
@@ -35,7 +35,6 @@ var MessageHeader = /*#__PURE__*/(0, _react.memo)((0, _styledComponents.default)
|
|
|
35
35
|
}, function (props) {
|
|
36
36
|
return props.theme.typography[200];
|
|
37
37
|
}));
|
|
38
|
-
exports.MessageHeader = MessageHeader;
|
|
39
38
|
var getContentPadding = function getContentPadding(props) {
|
|
40
39
|
if (!props.indentContent) {
|
|
41
40
|
return props.theme.space[400];
|
|
@@ -75,7 +74,7 @@ var messagePadding = function messagePadding(_ref) {
|
|
|
75
74
|
}
|
|
76
75
|
return theme.space[400];
|
|
77
76
|
};
|
|
78
|
-
var MessageBody = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
77
|
+
var MessageBody = exports.MessageBody = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
79
78
|
displayName: "styles__MessageBody",
|
|
80
79
|
componentId: "sc-161ezbx-2"
|
|
81
80
|
})(["padding:", " ", " ", " ", ";font-family:", ";", ";"], messagePadding, messagePadding, messagePadding, function (props) {
|
|
@@ -85,8 +84,7 @@ var MessageBody = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
85
84
|
}, function (props) {
|
|
86
85
|
return props.density === _constants.MESSAGE_DENSITIES.COMPACT || props.density === _constants.MESSAGE_DENSITIES.CONDENSED ? props.theme.typography[200] : props.theme.typography[300];
|
|
87
86
|
});
|
|
88
|
-
exports.
|
|
89
|
-
var MessageFooter = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
87
|
+
var MessageFooter = exports.MessageFooter = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
90
88
|
displayName: "styles__MessageFooter",
|
|
91
89
|
componentId: "sc-161ezbx-3"
|
|
92
90
|
})(["padding-bottom:", ";padding-left:", ";padding-right:", ";border-radius:0 0 ", " ", ";display:flex;justify-content:space-between;align-items:center;flex-wrap:", ";> :first-child{margin-left:-", ";}"], function (props) {
|
|
@@ -104,8 +102,7 @@ var MessageFooter = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
104
102
|
}, function (props) {
|
|
105
103
|
return props.theme.space[350];
|
|
106
104
|
});
|
|
107
|
-
exports.
|
|
108
|
-
var MessageMeta = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
105
|
+
var MessageMeta = exports.MessageMeta = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
109
106
|
displayName: "styles__MessageMeta",
|
|
110
107
|
componentId: "sc-161ezbx-4"
|
|
111
108
|
})(["background:none;border-width:0;border-style:none;border-top-width:1px;border-top-style:solid;display:block;width:100%;text-align:start;border-radius:0 0 ", " ", ";", ";margin:", " 0 ", ";padding:", " ", ";padding-left:", ";cursor:", ";color:", ";&:focus{", ";}"], function (props) {
|
|
@@ -129,6 +126,4 @@ var MessageMeta = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
129
126
|
}, function (props) {
|
|
130
127
|
return props.theme.colors.text.subtext;
|
|
131
128
|
}, _mixins.focusRing);
|
|
132
|
-
exports.
|
|
133
|
-
var _default = Container;
|
|
134
|
-
exports.default = _default;
|
|
129
|
+
var _default = exports.default = Container;
|
|
@@ -4,5 +4,5 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
4
4
|
var React = _interopRequireWildcard(require("react"));
|
|
5
5
|
var _index = _interopRequireDefault(require("../Box/index.flow"));
|
|
6
6
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
7
|
-
function _getRequireWildcardCache(
|
|
8
|
-
function _interopRequireWildcard(
|
|
7
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
8
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
package/commonjs/Modal/Modal.js
CHANGED
|
@@ -5,7 +5,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports.default = void 0;
|
|
8
|
-
var
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
var React = _react;
|
|
9
10
|
var _Box = _interopRequireDefault(require("../Box"));
|
|
10
11
|
var _Button = _interopRequireDefault(require("../Button"));
|
|
11
12
|
var _Icon = _interopRequireDefault(require("../Icon"));
|
|
@@ -15,8 +16,8 @@ var _excluded = ["title", "subtitle", "children", "bordered"],
|
|
|
15
16
|
_excluded2 = ["children"],
|
|
16
17
|
_excluded3 = ["appElementSelector", "children", "isOpen", "label", "onClose", "closeButtonLabel", "width", "zIndex"];
|
|
17
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
18
|
-
function _getRequireWildcardCache(
|
|
19
|
-
function _interopRequireWildcard(
|
|
19
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
20
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
20
21
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
21
22
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
22
23
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
@@ -45,7 +46,7 @@ var ModalHeader = function ModalHeader(props) {
|
|
|
45
46
|
}))));
|
|
46
47
|
};
|
|
47
48
|
var ModalCloseButton = function ModalCloseButton(props) {
|
|
48
|
-
var _useContext = (0,
|
|
49
|
+
var _useContext = (0, _react.useContext)(ModalContext),
|
|
49
50
|
onClose = _useContext.onClose,
|
|
50
51
|
closeButtonLabel = _useContext.closeButtonLabel;
|
|
51
52
|
if (!onClose) return null;
|
|
@@ -68,7 +69,7 @@ ModalFooter.defaultProps = {
|
|
|
68
69
|
var ModalContent = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
69
70
|
var children = _ref.children,
|
|
70
71
|
rest = _objectWithoutProperties(_ref, _excluded2);
|
|
71
|
-
var _useContext2 = (0,
|
|
72
|
+
var _useContext2 = (0, _react.useContext)(ModalContext),
|
|
72
73
|
label = _useContext2.label;
|
|
73
74
|
return /*#__PURE__*/React.createElement(_styles.Content, _extends({
|
|
74
75
|
"data-qa-modal": true,
|
|
@@ -132,5 +133,4 @@ Modal.Header = ModalHeader;
|
|
|
132
133
|
Modal.Footer = ModalFooter;
|
|
133
134
|
Modal.Content = ModalContent;
|
|
134
135
|
Modal.CloseButton = ModalCloseButton;
|
|
135
|
-
var _default = Modal;
|
|
136
|
-
exports.default = _default;
|
|
136
|
+
var _default = exports.default = Modal;
|
package/commonjs/Modal/index.js
CHANGED
|
@@ -27,5 +27,4 @@ Object.keys(_ModalTypes).forEach(function (key) {
|
|
|
27
27
|
});
|
|
28
28
|
});
|
|
29
29
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
30
|
-
var _default = _Modal.default;
|
|
31
|
-
exports.default = _default;
|
|
30
|
+
var _default = exports.default = _Modal.default;
|
package/commonjs/Modal/styles.js
CHANGED
|
@@ -12,8 +12,8 @@ var _reactModal = _interopRequireDefault(require("react-modal"));
|
|
|
12
12
|
var _systemProps = require("../utils/system-props");
|
|
13
13
|
var _Box = _interopRequireDefault(require("../Box"));
|
|
14
14
|
var _excluded = ["className"];
|
|
15
|
-
function _getRequireWildcardCache(
|
|
16
|
-
function _interopRequireWildcard(
|
|
15
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
16
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
17
17
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
18
18
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
19
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
@@ -39,9 +39,8 @@ var ReactModalAdapter = function ReactModalAdapter(_ref) {
|
|
|
39
39
|
overlayClassName: overlayClassName
|
|
40
40
|
}, props));
|
|
41
41
|
};
|
|
42
|
-
var Body = (0, _styledComponents.createGlobalStyle)([".ReactModal__Body--open{overflow:hidden;}"]);
|
|
43
|
-
exports.
|
|
44
|
-
var Container = (0, _styledComponents.default)(ReactModalAdapter).withConfig({
|
|
42
|
+
var Body = exports.Body = (0, _styledComponents.createGlobalStyle)([".ReactModal__Body--open{overflow:hidden;}"]);
|
|
43
|
+
var Container = exports.Container = (0, _styledComponents.default)(ReactModalAdapter).withConfig({
|
|
45
44
|
displayName: "styles__Container",
|
|
46
45
|
componentId: "sc-qfi2g8-0"
|
|
47
46
|
})(["&__Overlay{position:fixed;top:0px;left:0px;right:0px;bottom:0px;display:flex;align-items:center;justify-content:center;background-color:", ";opacity:0;will-change:opacity;transition:opacity ", " ", ";", " &.ReactModal__Overlay--after-open{opacity:1;}&.ReactModal__Overlay--before-close{opacity:0;}}&__Content{display:flex;flex-direction:column;background:", ";border-radius:", ";box-shadow:", ";filter:blur(0);color:", ";outline:none;max-width:calc(100vw - ", ");max-height:calc(100vh - ", ");@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){height:calc(100vh - ", ");}", " ", "}"], function (props) {
|
|
@@ -59,8 +58,7 @@ var Container = (0, _styledComponents.default)(ReactModalAdapter).withConfig({
|
|
|
59
58
|
}, function (props) {
|
|
60
59
|
return props.theme.colors.text.body;
|
|
61
60
|
}, BODY_PADDING, BODY_PADDING, BODY_PADDING, _styledSystem.width, _systemProps.COMMON);
|
|
62
|
-
exports.
|
|
63
|
-
var Content = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
61
|
+
var Content = exports.Content = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
64
62
|
displayName: "styles__Content",
|
|
65
63
|
componentId: "sc-qfi2g8-1"
|
|
66
64
|
})(["font-family:", ";min-height:80px;overflow-y:auto;flex:1 1 auto;padding:", " ", ";@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){flex-basis:100%;}"], function (props) {
|
|
@@ -70,8 +68,7 @@ var Content = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
70
68
|
}, function (props) {
|
|
71
69
|
return props.theme.space[450];
|
|
72
70
|
});
|
|
73
|
-
exports.
|
|
74
|
-
var HeaderContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
71
|
+
var HeaderContainer = exports.HeaderContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
75
72
|
displayName: "styles__HeaderContainer",
|
|
76
73
|
componentId: "sc-qfi2g8-2"
|
|
77
74
|
})(["font-family:", ";padding:", " ", ";"], function (props) {
|
|
@@ -81,8 +78,7 @@ var HeaderContainer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
81
78
|
}, function (props) {
|
|
82
79
|
return props.theme.space[450];
|
|
83
80
|
});
|
|
84
|
-
exports.
|
|
85
|
-
var Header = (0, _styledComponents.default)(HeaderContainer).withConfig({
|
|
81
|
+
var Header = exports.Header = (0, _styledComponents.default)(HeaderContainer).withConfig({
|
|
86
82
|
displayName: "styles__Header",
|
|
87
83
|
componentId: "sc-qfi2g8-3"
|
|
88
84
|
})(["display:flex;align-items:center;justify-content:space-between;flex:0 0 auto;border-bottom-width:", ";border-bottom-color:", ";border-bottom-style:solid;"], function (props) {
|
|
@@ -90,8 +86,7 @@ var Header = (0, _styledComponents.default)(HeaderContainer).withConfig({
|
|
|
90
86
|
}, function (props) {
|
|
91
87
|
return props.bordered ? props.theme.colors.container.border.base : 'transparent';
|
|
92
88
|
});
|
|
93
|
-
exports.
|
|
94
|
-
var Footer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
89
|
+
var Footer = exports.Footer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
95
90
|
displayName: "styles__Footer",
|
|
96
91
|
componentId: "sc-qfi2g8-4"
|
|
97
92
|
})(["flex:0 0 auto;font-family:", ";padding:", " ", ";border-bottom-right-radius:", ";border-bottom-left-radius:", ";"], function (props) {
|
|
@@ -105,7 +100,6 @@ var Footer = (0, _styledComponents.default)(_Box.default).withConfig({
|
|
|
105
100
|
}, function (props) {
|
|
106
101
|
return props.theme.radii[500];
|
|
107
102
|
});
|
|
108
|
-
exports.Footer = Footer;
|
|
109
103
|
Container.displayName = 'ModalContainer';
|
|
110
104
|
Content.displayName = 'Content';
|
|
111
105
|
Header.displayName = 'Modal.Header';
|
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
|
|
3
3
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
4
4
|
var React = _interopRequireWildcard(require("react"));
|
|
5
|
-
function _getRequireWildcardCache(
|
|
6
|
-
function _interopRequireWildcard(
|
|
5
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
6
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
@@ -14,8 +14,8 @@ var _constants2 = require("./constants");
|
|
|
14
14
|
var _styles = require("./styles");
|
|
15
15
|
var _excluded = ["number", "locale", "format", "currency", "abbreviate", "invalidNumberLabel", "precision", "qa"];
|
|
16
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
-
function _getRequireWildcardCache(
|
|
18
|
-
function _interopRequireWildcard(
|
|
17
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
18
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
19
19
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
20
20
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
21
21
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -147,5 +147,4 @@ var Numeral = function Numeral(props) {
|
|
|
147
147
|
}
|
|
148
148
|
return /*#__PURE__*/React.createElement(_styles.Container, _extends({}, qa, rest), fullText);
|
|
149
149
|
};
|
|
150
|
-
var _default = Numeral;
|
|
151
|
-
exports.default = _default;
|
|
150
|
+
var _default = exports.default = Numeral;
|
|
@@ -4,19 +4,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.MEMO_CACHE_SIZE = exports.MAX_PRECISION = exports.DefaultPrecisions = exports.DEFAULT_THRESHOLD = exports.COMPARE_OBJECTS = exports.ABBREV_PRECISION = void 0;
|
|
7
|
-
var DEFAULT_THRESHOLD = 10000;
|
|
8
|
-
exports.
|
|
9
|
-
var
|
|
10
|
-
exports.
|
|
11
|
-
var
|
|
12
|
-
exports.
|
|
13
|
-
var MAX_PRECISION = 20;
|
|
14
|
-
exports.MAX_PRECISION = MAX_PRECISION;
|
|
15
|
-
var ABBREV_PRECISION = 2;
|
|
16
|
-
exports.ABBREV_PRECISION = ABBREV_PRECISION;
|
|
17
|
-
var DefaultPrecisions = {
|
|
7
|
+
var DEFAULT_THRESHOLD = exports.DEFAULT_THRESHOLD = 10000;
|
|
8
|
+
var MEMO_CACHE_SIZE = exports.MEMO_CACHE_SIZE = 10;
|
|
9
|
+
var COMPARE_OBJECTS = exports.COMPARE_OBJECTS = true;
|
|
10
|
+
var MAX_PRECISION = exports.MAX_PRECISION = 20;
|
|
11
|
+
var ABBREV_PRECISION = exports.ABBREV_PRECISION = 2;
|
|
12
|
+
var DefaultPrecisions = exports.DefaultPrecisions = {
|
|
18
13
|
decimal: [0, 2],
|
|
19
14
|
percent: [0, 1],
|
|
20
15
|
currency: [2, 2]
|
|
21
|
-
};
|
|
22
|
-
exports.DefaultPrecisions = DefaultPrecisions;
|
|
16
|
+
};
|
|
@@ -27,5 +27,4 @@ Object.keys(_NumeralTypes).forEach(function (key) {
|
|
|
27
27
|
});
|
|
28
28
|
});
|
|
29
29
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
30
|
-
var _default = _Numeral.default;
|
|
31
|
-
exports.default = _default;
|
|
30
|
+
var _default = exports.default = _Numeral.default;
|