@procore/core-react 12.48.2 → 12.49.1
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 +23 -0
- package/dist/AnchorNavigation/AnchorNavigation.styles.js +4 -4
- package/dist/Avatar/Avatar.styles.js +5 -5
- package/dist/AvatarStack/AvatarStack.js +3 -3
- package/dist/AvatarStack/AvatarStack.js.map +1 -1
- package/dist/AvatarStack/AvatarStack.styles.d.ts +2 -0
- package/dist/AvatarStack/AvatarStack.styles.js +14 -9
- package/dist/AvatarStack/AvatarStack.styles.js.map +1 -1
- package/dist/Badge/Badge.styles.js +2 -2
- package/dist/BadgePill/BadgePill.styles.js +4 -4
- package/dist/Banner/Banner.styles.js +10 -10
- package/dist/Box/Box.styles.js +1 -1
- package/dist/Breadcrumbs/Breadcrumbs.styles.js +4 -4
- package/dist/Button/Button.styles.js +5 -5
- package/dist/Calendar/Calendar.styles.js +10 -10
- package/dist/Calendar/Calendar.styles.js.map +1 -1
- package/dist/Card/Card.styles.js +1 -1
- package/dist/Checkbox/Checkbox.js +9 -2
- package/dist/Checkbox/Checkbox.js.map +1 -1
- package/dist/Checkbox/Checkbox.styles.js +6 -6
- package/dist/ContactItem/ContactItem.styles.js +5 -5
- package/dist/Content/Content.styles.js +2 -2
- package/dist/DateInput/DateInput.styles.js +6 -6
- package/dist/DetailPage/DetailPage.js +1 -0
- package/dist/DetailPage/DetailPage.js.map +1 -1
- package/dist/DetailPage/DetailPage.styles.js +7 -7
- package/dist/Dropdown/Dropdown.styles.js +3 -3
- package/dist/DropdownFlyout/DropdownFlyout.styles.js +4 -4
- package/dist/Dropzone/Dropzone.js +1 -1
- package/dist/Dropzone/Dropzone.styles.js +9 -9
- package/dist/EmptyState/EmptyState.styles.js +6 -6
- package/dist/Field/Field.styles.js +3 -3
- package/dist/FileList/FileList.styles.js +3 -3
- package/dist/FileSelect/FileExplorer/FileExplorer.styles.js +9 -9
- package/dist/FileSelect/FileExplorer/FileExplorerSidebar.styles.js +3 -3
- package/dist/FileSelect/FileSelect.styles.js +2 -2
- package/dist/FileSelect/FileSelectDropzone/FileSelectDropzone.styles.js +3 -3
- package/dist/FileSelect/FileTokenList/FileTokenList.styles.js +2 -2
- package/dist/FileSelect/GridSource/GridSource.styles.js +6 -6
- package/dist/FileSelect/LocalSource/LocalSource.styles.js +4 -4
- package/dist/FileSelect/SourceItem/SourceItem.styles.js +3 -3
- package/dist/FileSelect/ThumbnailList/ThumbnailList.styles.js +6 -6
- package/dist/FileSelect/TreeSource/TreeSource.styles.js +1 -1
- package/dist/FileToken/FileToken.styles.js +6 -6
- package/dist/FilterToken/FilterToken.styles.js +5 -5
- package/dist/FlexList/FlexList.styles.js +1 -1
- package/dist/Form/Form.styles.js +13 -13
- package/dist/Form/StyledFormikForm.styles.js +2 -2
- package/dist/GhostPlaceholder/GhostPlaceholder.styles.js +2 -2
- package/dist/Grid/Grid.styles.js +2 -2
- package/dist/GroupSelect/GroupSelect.styles.js +1 -1
- package/dist/Input/Input.styles.js +1 -1
- package/dist/Link/Link.styles.js +1 -1
- package/dist/ListPage/ListPage.styles.js +8 -8
- package/dist/Loader/Loader.styles.js +2 -2
- package/dist/MenuImperative/MenuImperative.styles.js +11 -11
- package/dist/Modal/Modal.styles.js +13 -13
- package/dist/MultiSelect/MultiSelect.styles.js +8 -8
- package/dist/NextMenu/NextMenu.styles.js +3 -3
- package/dist/NextTile/NextTile.styles.js +5 -5
- package/dist/Notation/Notation.js +1 -1
- package/dist/NumberInput/NumberInput.js +48 -31
- package/dist/NumberInput/NumberInput.js.map +1 -1
- package/dist/NumberInput/NumberInput.styles.js +7 -7
- package/dist/NumberInput/NumberInput.types.d.ts +14 -0
- package/dist/NumberInput/NumberInput.types.js.map +1 -1
- package/dist/NumberInput/NumberInput.utils.d.ts +1 -0
- package/dist/NumberInput/NumberInput.utils.js +6 -0
- package/dist/NumberInput/NumberInput.utils.js.map +1 -1
- package/dist/Overlay/OverlayArrow.styles.js +1 -1
- package/dist/OverlayTrigger/OverlayTrigger.d.ts +1 -0
- package/dist/OverlayTrigger/OverlayTrigger.js +10 -6
- package/dist/OverlayTrigger/OverlayTrigger.js.map +1 -1
- package/dist/OverlayTrigger/index.d.ts +1 -1
- package/dist/OverlayTrigger/index.js +1 -1
- package/dist/OverlayTrigger/index.js.map +1 -1
- package/dist/PageLayout/PageLayout.d.ts +4 -3
- package/dist/PageLayout/PageLayout.js +26 -8
- package/dist/PageLayout/PageLayout.js.map +1 -1
- package/dist/PageLayout/PageLayout.styles.d.ts +6 -1
- package/dist/PageLayout/PageLayout.styles.js +30 -21
- package/dist/PageLayout/PageLayout.styles.js.map +1 -1
- package/dist/PageLayout/PageLayout.types.d.ts +19 -0
- package/dist/PageLayout/PageLayout.types.js.map +1 -1
- package/dist/PageLayout/index.d.ts +1 -1
- package/dist/PageLayout/index.js.map +1 -1
- package/dist/PageTemplate/PageFooterTemplate/PageFooterTemplate.styles.js +1 -1
- package/dist/PageTemplate/PageHeaderTemplate/PageHeaderTemplate.styles.js +3 -3
- package/dist/PageTemplate/PagePaneTemplate/PagePaneTemplate.styles.js +2 -2
- package/dist/PageTemplate/PageTemplate/PageTemplate.styles.d.ts +2 -2
- package/dist/PageTemplate/PageTemplate/PageTemplate.styles.js +3 -3
- package/dist/Pagination/Pagination.styles.js +5 -5
- package/dist/Panel/Panel.styles.js +11 -11
- package/dist/Pill/Pill.styles.js +3 -3
- package/dist/PillSelect/PillSelect.styles.js +4 -4
- package/dist/Popover/Popover.styles.js +2 -2
- package/dist/Portal/Portal.styles.js +1 -1
- package/dist/ProgressBar/ProgressBar.styles.js +2 -2
- package/dist/RadioButton/RadioButton.styles.js +3 -3
- package/dist/Required/Required.styles.js +3 -3
- package/dist/Search/Search.js +2 -5
- package/dist/Search/Search.js.map +1 -1
- package/dist/Search/Search.styles.js +5 -5
- package/dist/Section/Section.styles.js +7 -7
- package/dist/SegmentedController/SegmentedController.styles.js +4 -4
- package/dist/Select/Select.styles.js +8 -8
- package/dist/Semantic/Semantic.styles.js +9 -9
- package/dist/SettingsPage/SettingsPage.d.ts +1 -1
- package/dist/SettingsPage/SettingsPage.js +1 -0
- package/dist/SettingsPage/SettingsPage.js.map +1 -1
- package/dist/Slider/Slider.styles.js +5 -5
- package/dist/Spinner/Spinner.styles.js +7 -7
- package/dist/SplitViewCard/SplitViewCard.styles.js +8 -8
- package/dist/SuperSelect/SuperSelect.components.d.ts +3 -0
- package/dist/SuperSelect/SuperSelect.components.js +18 -1
- package/dist/SuperSelect/SuperSelect.components.js.map +1 -1
- package/dist/SuperSelect/SuperSelect.js +11 -2
- package/dist/SuperSelect/SuperSelect.js.map +1 -1
- package/dist/SuperSelect/SuperSelect.presets.styles.js +1 -1
- package/dist/SuperSelect/SuperSelect.styles.js +40 -40
- package/dist/SuperSelect/SuperSelect.types.d.ts +1 -0
- package/dist/SuperSelect/SuperSelect.types.js.map +1 -1
- package/dist/SuperSelect/useSuperSelect.js +15 -1
- package/dist/SuperSelect/useSuperSelect.js.map +1 -1
- package/dist/Switch/Switch.styles.js +4 -4
- package/dist/Table/Table.styles.js +29 -29
- package/dist/TableShelf/TableShelf.styles.js +5 -5
- package/dist/Tabs/Tabs.styles.js +16 -16
- package/dist/Tearsheet/Tearsheet.styles.js +5 -5
- package/dist/TextArea/TextArea.styles.js +1 -1
- package/dist/TextEditorOutput/TextEditorOutput.styles.js +1 -1
- package/dist/Thumbnail/Thumbnail.hooks.d.ts +1 -0
- package/dist/Thumbnail/Thumbnail.styles.js +21 -21
- package/dist/ThumbnailGrid/ThumbnailGrid.styles.js +7 -7
- package/dist/TieredSelect/TieredSelect.styles.js +9 -9
- package/dist/Tile/Tile.styles.js +8 -8
- package/dist/Title/Title.styles.js +7 -7
- package/dist/Toast/Toast.js +15 -6
- package/dist/Toast/Toast.js.map +1 -1
- package/dist/Toast/Toast.styles.js +5 -5
- package/dist/Toast/Toast.styles.js.map +1 -1
- package/dist/ToggleButton/ToggleButton.styles.js +1 -1
- package/dist/Token/Token.styles.js +5 -5
- package/dist/ToolHeader/ToolHeader.styles.js +6 -6
- package/dist/ToolLandingPage/ToolLandingPage.js +1 -0
- package/dist/ToolLandingPage/ToolLandingPage.js.map +1 -1
- package/dist/ToolLandingPage/ToolLandingPage.styles.js +3 -3
- package/dist/Tooltip/Tooltip.styles.js +3 -3
- package/dist/Tree/Tree.js +1 -1
- package/dist/Tree/Tree.styles.js +10 -10
- package/dist/Typeahead/Typeahead.js +8 -6
- package/dist/Typeahead/Typeahead.js.map +1 -1
- package/dist/Typeahead/Typeahead.styles.d.ts +4 -1
- package/dist/Typeahead/Typeahead.styles.js +15 -10
- package/dist/Typeahead/Typeahead.styles.js.map +1 -1
- package/dist/Typography/Typography.styles.js +1 -1
- package/dist/Typography/Typography.table.story.js +2 -2
- package/dist/_hooks/I18n.d.ts +4 -0
- package/dist/_locales/en.json +3 -1
- package/dist/_locales/pseudo.json +3 -1
- package/dist/_storyHelpers_/components/Deprecation.styles.js +1 -1
- package/dist/_storyHelpers_/components/StoryGrid.js +3 -3
- package/dist/_styles/colors.js +4 -1
- package/dist/_styles/colors.js.map +1 -1
- package/dist/_typedoc/AnchorNavigation/AnchorNavigation.types.json +4 -4
- package/dist/_typedoc/Avatar/Avatar.types.json +20 -20
- package/dist/_typedoc/AvatarStack/AvatarStack.types.json +25 -25
- package/dist/_typedoc/Badge/Badge.types.json +6 -6
- package/dist/_typedoc/Banner/Banner.types.json +15 -15
- package/dist/_typedoc/Box/Box.types.json +68 -68
- package/dist/_typedoc/Breadcrumbs/Breadcrumbs.types.json +10 -10
- package/dist/_typedoc/Button/Button.types.json +14 -14
- package/dist/_typedoc/Calendar/Calendar.types.json +80 -80
- package/dist/_typedoc/Card/Card.types.json +6 -6
- package/dist/_typedoc/Checkbox/Checkbox.types.json +8 -8
- package/dist/_typedoc/ContactItem/ContactItem.types.json +9 -9
- package/dist/_typedoc/DateInput/DateInput.types.json +35 -35
- package/dist/_typedoc/DateSelect/DateSelect.types.json +14 -14
- package/dist/_typedoc/DetailPage/DetailPage.types.json +5 -5
- package/dist/_typedoc/Dropdown/Dropdown.types.json +38 -38
- package/dist/_typedoc/DropdownFlyout/DropdownFlyout.types.json +31 -31
- package/dist/_typedoc/Dropzone/Dropzone.types.json +44 -44
- package/dist/_typedoc/EmptyState/EmptyState.types.json +18 -18
- package/dist/_typedoc/FileList/FileList.types.json +9 -9
- package/dist/_typedoc/FileSelect/FileSelect.types.json +27 -27
- package/dist/_typedoc/FileSelect/GridSource/GridSource.types.json +20 -20
- package/dist/_typedoc/FileSelect/LocalSource/LocalSource.types.json +14 -14
- package/dist/_typedoc/FileSelect/TreeSource/TreeSource.types.json +9 -9
- package/dist/_typedoc/Flex/Flex.types.json +27 -27
- package/dist/_typedoc/FlexList/FlexList.types.json +30 -30
- package/dist/_typedoc/Form/Form.types.json +842 -762
- package/dist/_typedoc/GhostPlaceholder/GhostPlaceholder.types.json +12 -12
- package/dist/_typedoc/Grid/Grid.types.json +8 -8
- package/dist/_typedoc/GroupSelect/GroupSelect.types.json +54 -54
- package/dist/_typedoc/Input/Input.types.json +2 -2
- package/dist/_typedoc/Link/Link.types.json +1 -1
- package/dist/_typedoc/ListPage/ListPage.types.json +13 -13
- package/dist/_typedoc/Menu/Menu.types.json +62 -62
- package/dist/_typedoc/MenuImperative/MenuImperative.types.json +84 -84
- package/dist/_typedoc/Modal/Modal.types.json +48 -48
- package/dist/_typedoc/MultiSelect/MultiSelect.types.json +33 -33
- package/dist/_typedoc/NextTile/NextTile.types.json +33 -33
- package/dist/_typedoc/Notation/Notation.types.json +4 -4
- package/dist/_typedoc/NumberInput/NumberInput.types.json +88 -48
- package/dist/_typedoc/OverlayTrigger/OverlayTrigger.types.json +33 -33
- package/dist/_typedoc/PageLayout/PageLayout.types.json +140 -28
- package/dist/_typedoc/Pagination/Pagination.types.json +7 -7
- package/dist/_typedoc/Panel/Panel.types.json +28 -28
- package/dist/_typedoc/Pill/Pill.types.json +2 -2
- package/dist/_typedoc/PillSelect/PillSelect.types.json +49 -49
- package/dist/_typedoc/Popover/Popover.types.json +15 -15
- package/dist/_typedoc/ProgressBar/ProgressBar.types.json +7 -7
- package/dist/_typedoc/RadioButton/RadioButton.types.json +6 -6
- package/dist/_typedoc/Required/Required.types.json +5 -5
- package/dist/_typedoc/Search/Search.types.json +18 -18
- package/dist/_typedoc/Section/Section.types.json +15 -15
- package/dist/_typedoc/SegmentedController/SegmentedController.types.json +21 -21
- package/dist/_typedoc/Select/Select.types.json +67 -67
- package/dist/_typedoc/SettingsPage/SettingsPage.types.json +10 -10
- package/dist/_typedoc/Slider/Slider.types.json +6 -6
- package/dist/_typedoc/Spinner/Spinner.types.json +9 -9
- package/dist/_typedoc/SplitViewCard/SplitViewCard.types.json +14 -14
- package/dist/_typedoc/Table/Table.types.json +105 -105
- package/dist/_typedoc/Tabs/Tabs.types.json +21 -21
- package/dist/_typedoc/Tearsheet/Tearsheet.types.json +17 -17
- package/dist/_typedoc/TextArea/TextArea.types.json +3 -3
- package/dist/_typedoc/TextEditor/TextEditor.types.json +11 -11
- package/dist/_typedoc/TextEditorOutput/TextEditorOutput.types.json +4 -4
- package/dist/_typedoc/Thumbnail/Thumbnail.types.json +19 -19
- package/dist/_typedoc/TieredDropdown/TieredDropdown.types.json +43 -43
- package/dist/_typedoc/TieredSelect/TieredSelect.types.json +29 -29
- package/dist/_typedoc/Tile/Tile.types.json +8 -8
- package/dist/_typedoc/Title/Title.types.json +1 -1
- package/dist/_typedoc/Toast/Toast.types.json +4 -4
- package/dist/_typedoc/ToggleButton/ToggleButton.types.json +4 -4
- package/dist/_typedoc/Token/Token.types.json +7 -7
- package/dist/_typedoc/ToolHeader/ToolHeader.types.json +10 -10
- package/dist/_typedoc/ToolLandingPage/ToolLandingPage.types.json +8 -8
- package/dist/_typedoc/Tooltip/Tooltip.types.json +15 -15
- package/dist/_typedoc/Tree/Tree.types.json +88 -88
- package/dist/_typedoc/Typeahead/Typeahead.types.json +2 -2
- package/dist/_typedoc/Typography/Typography.types.json +9 -9
- package/dist/_typedoc/_utils/types.json +3 -3
- package/dist/_typedoc/a11y-tips.json +1 -1
- package/package.json +2 -2
|
@@ -7,11 +7,11 @@ export var loaderTransitionDuration = 250;
|
|
|
7
7
|
var movingStripes = /*#__PURE__*/keyframes(["from{background-position:", "px 0;}100%{background-position:0 ", "px;}"], backgroundSize, backgroundSize);
|
|
8
8
|
export var StyledLoader = /*#__PURE__*/styled.div.withConfig({
|
|
9
9
|
displayName: "StyledLoader",
|
|
10
|
-
componentId: "core-
|
|
10
|
+
componentId: "core-12_49_1__sc-wgvjj9-0"
|
|
11
11
|
})(["display:block;height:100%;left:0;min-width:12px;position:absolute;transition:width ", "ms ease-out;top:0;"], loaderTransitionDuration);
|
|
12
12
|
export var StyledGradient = /*#__PURE__*/styled.div.withConfig({
|
|
13
13
|
displayName: "StyledGradient",
|
|
14
|
-
componentId: "core-
|
|
14
|
+
componentId: "core-12_49_1__sc-wgvjj9-1"
|
|
15
15
|
})(["height:100%;", ""], function (_ref) {
|
|
16
16
|
var $animated = _ref.$animated;
|
|
17
17
|
return $animated ? css(["@media (prefers-reduced-motion:no-preference){animation:", " 0.5s linear infinite;}background-image:linear-gradient( 45deg,", " 26%,", " 25%,", " 51%,", " 50%,", " 76%,", " 75%,", " );background-size:", "px ", "px;"], movingStripes, color1, color2, color2, color1, color1, color2, color2, backgroundSize, backgroundSize) : css(["background-color:", ";"], colors.blue50);
|
|
@@ -11,15 +11,15 @@ var optionMinHeight = 32;
|
|
|
11
11
|
// Do not merge with StyledMenu, needed for max-height working in IE
|
|
12
12
|
export var StyledWrapper = /*#__PURE__*/styled.div.withConfig({
|
|
13
13
|
displayName: "StyledWrapper",
|
|
14
|
-
componentId: "core-
|
|
14
|
+
componentId: "core-12_49_1__sc-z984sz-0"
|
|
15
15
|
})(["border-radius:inherit;display:flex;max-height:inherit;min-width:inherit;outline:none;width:inherit;"]);
|
|
16
16
|
export var StyledMenu = /*#__PURE__*/styled.div.withConfig({
|
|
17
17
|
displayName: "StyledMenu",
|
|
18
|
-
componentId: "core-
|
|
18
|
+
componentId: "core-12_49_1__sc-z984sz-1"
|
|
19
19
|
})(["border-radius:inherit;display:flex;flex-direction:column;outline:0;width:100%;"]);
|
|
20
20
|
export var StyledOptions = /*#__PURE__*/styled.div.withConfig({
|
|
21
21
|
displayName: "StyledOptions",
|
|
22
|
-
componentId: "core-
|
|
22
|
+
componentId: "core-12_49_1__sc-z984sz-2"
|
|
23
23
|
})(["flex-basis:auto;flex-grow:1;flex-shrink:1;min-height:", "px;", ";padding:", "px 0;position:relative;&:focus-visible{", " margin:-1px;}ol&{padding:", "px 0;list-style-type:none;margin:0;}"], optionMinHeight, function (_ref) {
|
|
24
24
|
var _ref$$scrollable = _ref.$scrollable,
|
|
25
25
|
$scrollable = _ref$$scrollable === void 0 ? true : _ref$$scrollable;
|
|
@@ -27,27 +27,27 @@ export var StyledOptions = /*#__PURE__*/styled.div.withConfig({
|
|
|
27
27
|
}, spacing.sm, getFocus(), spacing.sm);
|
|
28
28
|
export var StyledGrip = /*#__PURE__*/styled.div.withConfig({
|
|
29
29
|
displayName: "StyledGrip",
|
|
30
|
-
componentId: "core-
|
|
30
|
+
componentId: "core-12_49_1__sc-z984sz-3"
|
|
31
31
|
})(["padding:0 2px;height:24px;"]);
|
|
32
32
|
export var StyledHeader = /*#__PURE__*/styled.div.withConfig({
|
|
33
33
|
displayName: "StyledHeader",
|
|
34
|
-
componentId: "core-
|
|
34
|
+
componentId: "core-12_49_1__sc-z984sz-4"
|
|
35
35
|
})([""]);
|
|
36
36
|
export var StyledSearch = /*#__PURE__*/styled.div.withConfig({
|
|
37
37
|
displayName: "StyledSearch",
|
|
38
|
-
componentId: "core-
|
|
38
|
+
componentId: "core-12_49_1__sc-z984sz-5"
|
|
39
39
|
})(["padding:", "px ", "px ", "px;", " > *{pointer-events:none;}"], spacing.lg, spacing.lg, spacing.sm, StyledButton);
|
|
40
40
|
export var StyledGroup = /*#__PURE__*/styled.div.withConfig({
|
|
41
41
|
displayName: "StyledGroup",
|
|
42
|
-
componentId: "core-
|
|
42
|
+
componentId: "core-12_49_1__sc-z984sz-6"
|
|
43
43
|
})(["&:not(:first-child){margin-top:", "px;}"], spacing.md);
|
|
44
44
|
export var StyledGroupLabel = /*#__PURE__*/styled.span.withConfig({
|
|
45
45
|
displayName: "StyledGroupLabel",
|
|
46
|
-
componentId: "core-
|
|
46
|
+
componentId: "core-12_49_1__sc-z984sz-7"
|
|
47
47
|
})(["", " display:block;color:", ";font-weight:", ";padding:", "px ", "px;cursor:default;"], getTypographyIntent('body'), colors.gray15, typographyWeights.semibold, spacing.xs, spacing.lg);
|
|
48
48
|
export var StyledItem = /*#__PURE__*/styled.div.withConfig({
|
|
49
49
|
displayName: "StyledItem",
|
|
50
|
-
componentId: "core-
|
|
50
|
+
componentId: "core-12_49_1__sc-z984sz-8"
|
|
51
51
|
})(["", ";", " cursor:pointer;list-style-type:none;padding:", "px ", "px;a{color:", ";display:block;margin:-", "px -", "px;padding:", "px ", "px;text-decoration:none;&:hover{color:", ";text-decoration:none;}}&[data-highlighted='true']{background-color:", ";}", " ", "{color:inherit;cursor:pointer;}", " ", " ", ""], getTypographyIntent('body'), function (_ref2) {
|
|
52
52
|
var as = _ref2.as;
|
|
53
53
|
return as === 'a' && css(["display:block;text-decoration:none;"]);
|
|
@@ -76,10 +76,10 @@ export var StyledItem = /*#__PURE__*/styled.div.withConfig({
|
|
|
76
76
|
});
|
|
77
77
|
export var StyledDroppable = /*#__PURE__*/styled.div.withConfig({
|
|
78
78
|
displayName: "StyledDroppable",
|
|
79
|
-
componentId: "core-
|
|
79
|
+
componentId: "core-12_49_1__sc-z984sz-9"
|
|
80
80
|
})(["", ",", "{padding-left:28px;}"], StyledGroup, StyledItem);
|
|
81
81
|
export var StyledFooter = /*#__PURE__*/styled(Box).withConfig({
|
|
82
82
|
displayName: "StyledFooter",
|
|
83
|
-
componentId: "core-
|
|
83
|
+
componentId: "core-12_49_1__sc-z984sz-10"
|
|
84
84
|
})(["border-top:1px solid ", ";border-bottom-left-radius:inherit;border-bottom-right-radius:inherit;"], colors.gray85);
|
|
85
85
|
//# sourceMappingURL=MenuImperative.styles.js.map
|
|
@@ -32,15 +32,15 @@ var screenWidthPixelBreakpoints = {
|
|
|
32
32
|
};
|
|
33
33
|
export var StyledModal = /*#__PURE__*/styled.div.withConfig({
|
|
34
34
|
displayName: "StyledModal",
|
|
35
|
-
componentId: "core-
|
|
35
|
+
componentId: "core-12_49_1__sc-1ijdug2-0"
|
|
36
36
|
})(["display:flex;height:100vh;position:absolute;opacity:0;transition:0.3s opacity ease;width:100vw;z-index:0;pointer-events:none;&.", "{opacity:1;pointer-events:auto;}&.", "{opacity:0;pointer-events:none;}"], fadeInClassName, fadeOutClassName);
|
|
37
37
|
export var StyledModalButtons = /*#__PURE__*/styled.div.withConfig({
|
|
38
38
|
displayName: "StyledModalButtons",
|
|
39
|
-
componentId: "core-
|
|
39
|
+
componentId: "core-12_49_1__sc-1ijdug2-1"
|
|
40
40
|
})(["display:flex;flex:0 0 auto;margin-left:", "px;> * + *{margin-left:", "px;}"], spacing.lg, spacing.sm);
|
|
41
41
|
export var StyledModalContainer = /*#__PURE__*/styled(Card).withConfig({
|
|
42
42
|
displayName: "StyledModalContainer",
|
|
43
|
-
componentId: "core-
|
|
43
|
+
componentId: "core-12_49_1__sc-1ijdug2-2"
|
|
44
44
|
})(["display:flex;flex-direction:row;position:absolute;z-index:2;", " ", " ", ""], function (_ref) {
|
|
45
45
|
var $compact = _ref.$compact;
|
|
46
46
|
if (!$compact) {
|
|
@@ -64,11 +64,11 @@ export var StyledModalContainer = /*#__PURE__*/styled(Card).withConfig({
|
|
|
64
64
|
});
|
|
65
65
|
export var StyledModalFooter = /*#__PURE__*/styled.div.withConfig({
|
|
66
66
|
displayName: "StyledModalFooter",
|
|
67
|
-
componentId: "core-
|
|
67
|
+
componentId: "core-12_49_1__sc-1ijdug2-3"
|
|
68
68
|
})(["align-items:center;display:flex;flex:0 0 auto;flex-wrap:wrap;justify-content:flex-end;padding:", "px ", "px ", "px;"], spacing.xl, spacing.xxl, spacing.xxl);
|
|
69
69
|
export var StyledModalBody = /*#__PURE__*/styled.div.withConfig({
|
|
70
70
|
displayName: "StyledModalBody",
|
|
71
|
-
componentId: "core-
|
|
71
|
+
componentId: "core-12_49_1__sc-1ijdug2-4"
|
|
72
72
|
})(["", " &:focus-visible{", "}box-sizing:border-box;color:", ";display:flex;flex-direction:column;overflow:auto;", " ", " > ", "{padding-left:0;padding-right:0;&:first-child > ", "{padding-top:0;}}", ""], getTypographyIntent('body'), getFocusInset(), colors.gray15, function (_ref4) {
|
|
73
73
|
var $noSideSpacing = _ref4.$noSideSpacing;
|
|
74
74
|
return css(["padding:", "px ", "px;"], spacing.xl, $noSideSpacing ? 0 : spacing.xxl);
|
|
@@ -85,7 +85,7 @@ export var StyledModalBody = /*#__PURE__*/styled.div.withConfig({
|
|
|
85
85
|
});
|
|
86
86
|
export var StyledModalContent = /*#__PURE__*/styled.div.withConfig({
|
|
87
87
|
displayName: "StyledModalContent",
|
|
88
|
-
componentId: "core-
|
|
88
|
+
componentId: "core-12_49_1__sc-1ijdug2-5"
|
|
89
89
|
})(["display:flex;flex-direction:column;max-height:90vh;overflow:hidden;width:100%;", ""], function (_ref7) {
|
|
90
90
|
var _ref7$$compact = _ref7.$compact,
|
|
91
91
|
$compact = _ref7$$compact === void 0 ? false : _ref7$$compact;
|
|
@@ -96,11 +96,11 @@ export var StyledModalContent = /*#__PURE__*/styled.div.withConfig({
|
|
|
96
96
|
});
|
|
97
97
|
export var StyledModalFooterNotation = /*#__PURE__*/styled(Typography).withConfig({
|
|
98
98
|
displayName: "StyledModalFooterNotation",
|
|
99
|
-
componentId: "core-
|
|
99
|
+
componentId: "core-12_49_1__sc-1ijdug2-6"
|
|
100
100
|
})(["flex-grow:1;"]);
|
|
101
101
|
export var StyledModalHeader = /*#__PURE__*/styled.div.withConfig({
|
|
102
102
|
displayName: "StyledModalHeader",
|
|
103
|
-
componentId: "core-
|
|
103
|
+
componentId: "core-12_49_1__sc-1ijdug2-7"
|
|
104
104
|
})(["align-items:flex-start;color:", ";display:flex;flex:0 0 auto;position:relative;", " ", ""], colors.gray10, function (_ref8) {
|
|
105
105
|
var $compact = _ref8.$compact,
|
|
106
106
|
$isBodyScrolled = _ref8.$isBodyScrolled;
|
|
@@ -118,7 +118,7 @@ export var StyledModalHeader = /*#__PURE__*/styled.div.withConfig({
|
|
|
118
118
|
});
|
|
119
119
|
export var StyledModalHeading = /*#__PURE__*/styled.div.withConfig({
|
|
120
120
|
displayName: "StyledModalHeading",
|
|
121
|
-
componentId: "core-
|
|
121
|
+
componentId: "core-12_49_1__sc-1ijdug2-8"
|
|
122
122
|
})(["", " align-items:center;display:flex;flex:1 1 auto;min-height:36px;padding-right:", "px;", ""], function (_ref0) {
|
|
123
123
|
var $compact = _ref0.$compact;
|
|
124
124
|
return getTypographyIntent($compact ? 'h3' : 'h2');
|
|
@@ -134,18 +134,18 @@ export var StyledModalHeading = /*#__PURE__*/styled.div.withConfig({
|
|
|
134
134
|
});
|
|
135
135
|
export var StyledModalCancel = /*#__PURE__*/styled.div.withConfig({
|
|
136
136
|
displayName: "StyledModalCancel",
|
|
137
|
-
componentId: "core-
|
|
137
|
+
componentId: "core-12_49_1__sc-1ijdug2-9"
|
|
138
138
|
})(["flex:0 0 auto;"]);
|
|
139
139
|
export var StyledModalScrim = /*#__PURE__*/styled.div.withConfig({
|
|
140
140
|
displayName: "StyledModalScrim",
|
|
141
|
-
componentId: "core-
|
|
141
|
+
componentId: "core-12_49_1__sc-1ijdug2-10"
|
|
142
142
|
})(["background:hsla(200,8%,10%,0.6);height:100vh;left:0;position:absolute;top:0;width:100vw;z-index:1;"]);
|
|
143
143
|
export var StyledModalWarningIcon = /*#__PURE__*/styled(Warning).withConfig({
|
|
144
144
|
displayName: "StyledModalWarningIcon",
|
|
145
|
-
componentId: "core-
|
|
145
|
+
componentId: "core-12_49_1__sc-1ijdug2-11"
|
|
146
146
|
})(["color:", ";margin-right:", "px;"], colors.yellow40, spacing.sm);
|
|
147
147
|
export var StyledModalFooterSummary = /*#__PURE__*/styled.div.withConfig({
|
|
148
148
|
displayName: "StyledModalFooterSummary",
|
|
149
|
-
componentId: "core-
|
|
149
|
+
componentId: "core-12_49_1__sc-1ijdug2-12"
|
|
150
150
|
})(["", " border-top:1px solid ", ";border-bottom:1px solid ", ";padding:", "px ", "px;color:", ";font-style:italic;background-color:", ";margin:-", "px -", "px ", "px -", "px;flex:1 1 100%;"], getTypographyIntent('small'), colors.gray85, colors.gray85, spacing.md, spacing.xxl, colors.gray15, colors.gray98, spacing.xl, spacing.xxl, spacing.xl, spacing.xxl);
|
|
151
151
|
//# sourceMappingURL=Modal.styles.js.map
|
|
@@ -8,34 +8,34 @@ import { getFocus } from '../_styles/mixins';
|
|
|
8
8
|
import { spacing } from '../_styles/spacing';
|
|
9
9
|
export var StyledMultiSelectInner = /*#__PURE__*/styled.div.withConfig({
|
|
10
10
|
displayName: "StyledMultiSelectInner",
|
|
11
|
-
componentId: "core-
|
|
11
|
+
componentId: "core-12_49_1__sc-s9ym9q-0"
|
|
12
12
|
})(["display:flex;flex-wrap:wrap;margin-bottom:2px;margin-left:", "px;margin-right:", "px;margin-top:2px;min-width:0;width:100%;"], spacing.md, spacing.xs);
|
|
13
13
|
export var StyledMultiSelectValues = /*#__PURE__*/styled.div.withConfig({
|
|
14
14
|
displayName: "StyledMultiSelectValues",
|
|
15
|
-
componentId: "core-
|
|
15
|
+
componentId: "core-12_49_1__sc-s9ym9q-1"
|
|
16
16
|
})(["display:contents;"]);
|
|
17
17
|
export var StyledMultiSelectToken = /*#__PURE__*/styled.div.withConfig({
|
|
18
18
|
displayName: "StyledMultiSelectToken",
|
|
19
|
-
componentId: "core-
|
|
19
|
+
componentId: "core-12_49_1__sc-s9ym9q-2"
|
|
20
20
|
})(["margin-bottom:2px;margin-right:", "px;margin-top:2px;flex:0 1 auto;> div{max-width:178px;width:100%;}"], spacing.xs);
|
|
21
21
|
export var StyledMultiSelectSearchInput = /*#__PURE__*/styled.input.withConfig({
|
|
22
22
|
displayName: "StyledMultiSelectSearchInput",
|
|
23
|
-
componentId: "core-
|
|
23
|
+
componentId: "core-12_49_1__sc-s9ym9q-3"
|
|
24
24
|
})(["background-color:transparent;border-width:0;font-family:inherit;padding:0;height:24px;width:100%;", " ", " &::-ms-clear{display:none;}&:focus{box-shadow:none;outline:none;}&::placeholder{color:", ";}"], getTypographyIntent('body'), function (_ref) {
|
|
25
25
|
var $isNavigatingTokens = _ref.$isNavigatingTokens;
|
|
26
26
|
return $isNavigatingTokens && css(["color:transparent;"]);
|
|
27
27
|
}, colors.gray45);
|
|
28
28
|
export var StyledMultiSelectSearch = /*#__PURE__*/styled.div.withConfig({
|
|
29
29
|
displayName: "StyledMultiSelectSearch",
|
|
30
|
-
componentId: "core-
|
|
30
|
+
componentId: "core-12_49_1__sc-s9ym9q-4"
|
|
31
31
|
})(["margin-bottom:2px;margin-right:", "px;margin-top:2px;flex:1;max-width:100%;min-width:24px;"], spacing.xs);
|
|
32
32
|
export var StyledMultiSelectSearchIcon = /*#__PURE__*/styled.div.withConfig({
|
|
33
33
|
displayName: "StyledMultiSelectSearchIcon",
|
|
34
|
-
componentId: "core-
|
|
34
|
+
componentId: "core-12_49_1__sc-s9ym9q-5"
|
|
35
35
|
})(["align-items:center;align-self:flex-start;display:flex;height:34px;justify-content:flex-end;margin-left:", "px;margin-right:", "px;min-width:40px;width:40px;"], spacing.xs, spacing.md);
|
|
36
36
|
export var StyledMultiSelectClearIcon = /*#__PURE__*/styled(Button).withConfig({
|
|
37
37
|
displayName: "StyledMultiSelectClearIcon",
|
|
38
|
-
componentId: "core-
|
|
38
|
+
componentId: "core-12_49_1__sc-s9ym9q-6"
|
|
39
39
|
})(["", " ", "{pointer-events:none;}"], function (_ref2) {
|
|
40
40
|
var $show = _ref2.$show;
|
|
41
41
|
return css(["opacity:", ";"], $show ? 1 : 0);
|
|
@@ -45,7 +45,7 @@ export var StyledMultiSelectArrow = StyledSelectArrow;
|
|
|
45
45
|
export var StyledMultiSelectMenu = StyledSelectMenu;
|
|
46
46
|
export var StyledMultiSelectButton = /*#__PURE__*/styled(StyledSelectButton).withConfig({
|
|
47
47
|
displayName: "StyledMultiSelectButton",
|
|
48
|
-
componentId: "core-
|
|
48
|
+
componentId: "core-12_49_1__sc-s9ym9q-7"
|
|
49
49
|
})(["height:auto;padding:0;white-space:normal;&:focus-within{", "}", ""], getFocus(), function (_ref3) {
|
|
50
50
|
var $emptyValue = _ref3.$emptyValue;
|
|
51
51
|
return $emptyValue && css(["", "{cursor:pointer;}"], StyledMultiSelectSearchInput);
|
|
@@ -6,14 +6,14 @@ export var optionMinHeight = 32;
|
|
|
6
6
|
export var defaultMenuHeight = 64;
|
|
7
7
|
export var StyledOptions = /*#__PURE__*/styled.div.withConfig({
|
|
8
8
|
displayName: "StyledOptions",
|
|
9
|
-
componentId: "core-
|
|
9
|
+
componentId: "core-12_49_1__sc-3o6zya-0"
|
|
10
10
|
})([""]);
|
|
11
11
|
export var StyledItem = /*#__PURE__*/styled.div.withConfig({
|
|
12
12
|
displayName: "StyledItem",
|
|
13
|
-
componentId: "core-
|
|
13
|
+
componentId: "core-12_49_1__sc-3o6zya-1"
|
|
14
14
|
})(["", ";padding:", "px ", "px;cursor:pointer;list-style-type:none;"], getTypographyIntent('body'), spacing.xs, spacing.md);
|
|
15
15
|
export var StyledGroup = /*#__PURE__*/styled.div.withConfig({
|
|
16
16
|
displayName: "StyledGroup",
|
|
17
|
-
componentId: "core-
|
|
17
|
+
componentId: "core-12_49_1__sc-3o6zya-2"
|
|
18
18
|
})(["", ";padding:", "px ", "px ", "px;font-weight:", ";background:white;list-style-type:none;"], getTypographyIntent('body'), spacing.md, spacing.md, spacing.xs, typographyWeights.semibold);
|
|
19
19
|
//# sourceMappingURL=NextMenu.styles.js.map
|
|
@@ -75,26 +75,26 @@ function selectableTileFocusWithinOutlineCss() {
|
|
|
75
75
|
}
|
|
76
76
|
export var StyledNextTileInertContent = /*#__PURE__*/styled.div.withConfig({
|
|
77
77
|
displayName: "StyledNextTileInertContent",
|
|
78
|
-
componentId: "core-
|
|
78
|
+
componentId: "core-12_49_1__sc-17bbrfw-0"
|
|
79
79
|
})(["display:contents;color:", ";& *{color:inherit;}"], disabledText);
|
|
80
80
|
export var StyledNextTileFocusTarget = /*#__PURE__*/styled.div.withConfig({
|
|
81
81
|
displayName: "StyledNextTileFocusTarget",
|
|
82
|
-
componentId: "core-
|
|
82
|
+
componentId: "core-12_49_1__sc-17bbrfw-1"
|
|
83
83
|
})(["border-radius:inherit;min-height:0;outline:none;"]);
|
|
84
84
|
export var StyledNextInteractableTile = /*#__PURE__*/styled(StyledInteractableTile).withConfig({
|
|
85
85
|
displayName: "StyledNextInteractableTile",
|
|
86
|
-
componentId: "core-
|
|
86
|
+
componentId: "core-12_49_1__sc-17bbrfw-2"
|
|
87
87
|
})(["border:", ";position:relative;", ""], nextTileNeutralBorder, function (_ref5) {
|
|
88
88
|
var $disabled = _ref5.$disabled;
|
|
89
89
|
return $disabled && css(["&&{border-color:", ";cursor:not-allowed;pointer-events:none;}&&:focus{border:1px solid ", ";box-shadow:none;outline:none;}", ""], colors.gray85, colors.gray85, disabledInteractableStyles);
|
|
90
90
|
});
|
|
91
91
|
export var StyledNextLinkTile = /*#__PURE__*/styled(StyledLinkTile).withConfig({
|
|
92
92
|
displayName: "StyledNextLinkTile",
|
|
93
|
-
componentId: "core-
|
|
93
|
+
componentId: "core-12_49_1__sc-17bbrfw-3"
|
|
94
94
|
})(["border:", ";position:relative;", ""], nextTileNeutralBorder, nextTileLinkLikeFocusStyles);
|
|
95
95
|
export var StyledNextSelectableTile = /*#__PURE__*/styled(StyledSelectableTile).withConfig({
|
|
96
96
|
displayName: "StyledNextSelectableTile",
|
|
97
|
-
componentId: "core-
|
|
97
|
+
componentId: "core-12_49_1__sc-17bbrfw-4"
|
|
98
98
|
})(["position:relative;", " ", " ", " ", " ", " &:focus{", " outline:none;}", " ", ""], function (p) {
|
|
99
99
|
return nextTileSelectableBorderStyles(p);
|
|
100
100
|
}, function (_ref6) {
|
|
@@ -14,7 +14,7 @@ var variantColorMap = {
|
|
|
14
14
|
};
|
|
15
15
|
var StyledNotation = /*#__PURE__*/styled.i.withConfig({
|
|
16
16
|
displayName: "StyledNotation",
|
|
17
|
-
componentId: "core-
|
|
17
|
+
componentId: "core-12_49_1__sc-160q1m6-0"
|
|
18
18
|
})(["", " color:", ";font-style:italic;"], getTypographyIntent('small'), function (_ref) {
|
|
19
19
|
var $variant = _ref.$variant;
|
|
20
20
|
return $variant ? colors[variantColorMap[$variant]] : colors.gray15;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
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); }
|
|
2
|
-
var _excluded = ["aria-label", "aria-labelledby", "decimalScale", "defaultValue", "disabled", "error", "fillDecimalScale", "onChange", "onKeyDown", "onBlur", "prefix", "readOnly", "step", "style", "suffix", "value", "qa"],
|
|
2
|
+
var _excluded = ["aria-label", "aria-labelledby", "decimalScale", "defaultValue", "disabled", "error", "fillDecimalScale", "max", "min", "onChange", "onKeyDown", "onBlur", "prefix", "readOnly", "step", "style", "suffix", "value", "qa"],
|
|
3
3
|
_excluded2 = ["currencyDisplay", "currencyIsoCode", "decimalScale", "fillDecimalScale", "prefix", "suffix"];
|
|
4
4
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
5
5
|
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; }
|
|
@@ -24,7 +24,7 @@ import { mergeRefs } from '../_utils/mergeRefs';
|
|
|
24
24
|
import { defaultCurrencyFillDecimalScale, defaultCurrencyInputPrefix } from './NumberInput.constants';
|
|
25
25
|
import { useNumberFormat, useNumberInputLabel, usePrevious } from './NumberInput.hooks';
|
|
26
26
|
import { addonRootFontFamily, addonRootFontSize, addonRootPadding, inputDefaultXPadding, StyledIncrementerButton, StyledIncrementerWrapper, StyledInput, StyledPrefix, StyledSuffix, StyledWrapper } from './NumberInput.styles';
|
|
27
|
-
import { backspaceKey, commaKey, controlKey, copyKey, defaultLocale, deleteKey, emptyString, format, getNewCursorPosition, getSeparators, highlightAllKey, identicalLocales, identifyPressedKey, maxDigitLength, metaKeyIdentifier, minus, numericKeypadKey, periodKey, prepareValueToFormatting, toFixed, unformat } from './NumberInput.utils';
|
|
27
|
+
import { backspaceKey, clamp, commaKey, controlKey, copyKey, defaultLocale, deleteKey, emptyString, format, getNewCursorPosition, getSeparators, highlightAllKey, identicalLocales, identifyPressedKey, maxDigitLength, metaKeyIdentifier, minus, numericKeypadKey, periodKey, prepareValueToFormatting, toFixed, unformat } from './NumberInput.utils';
|
|
28
28
|
function noop() {}
|
|
29
29
|
var PlusIcon = function PlusIcon() {
|
|
30
30
|
return /*#__PURE__*/React.createElement("svg", {
|
|
@@ -73,6 +73,8 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
73
73
|
error = _ref$error === void 0 ? false : _ref$error,
|
|
74
74
|
_ref$fillDecimalScale = _ref.fillDecimalScale,
|
|
75
75
|
fillDecimalScale = _ref$fillDecimalScale === void 0 ? 'none' : _ref$fillDecimalScale,
|
|
76
|
+
max = _ref.max,
|
|
77
|
+
min = _ref.min,
|
|
76
78
|
_onChange = _ref.onChange,
|
|
77
79
|
_ref$onKeyDown = _ref.onKeyDown,
|
|
78
80
|
_onKeyDown = _ref$onKeyDown === void 0 ? noop : _ref$onKeyDown,
|
|
@@ -272,8 +274,11 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
272
274
|
var diff = toFixed(step, stepPrecision) * (down ? -1 : 1);
|
|
273
275
|
var precision = Math.max(stepPrecision, fixedDecimalScale ? verifiedDecimalScale : prevValuePrecision);
|
|
274
276
|
var significantPrecision = Math.max(prevValueSignificantPrecision, stepPrecision);
|
|
275
|
-
var
|
|
276
|
-
var
|
|
277
|
+
var calculatedNumber = inputValue ? (parsedNumber || 0) + diff : diff;
|
|
278
|
+
var clampedNumber = clamp(calculatedNumber, min, max);
|
|
279
|
+
var wasClamped = clampedNumber !== calculatedNumber;
|
|
280
|
+
var calculated = inputValue ? clampedNumber.toFixed(significantPrecision) : clampedNumber;
|
|
281
|
+
var _getValueLengthInfo = getValueLengthInfo(wasClamped ? clampedNumber : calculated, true),
|
|
277
282
|
isSafeLength = _getValueLengthInfo.isSafeLength,
|
|
278
283
|
isSafeIntegerLength = _getValueLengthInfo.isSafeIntegerLength;
|
|
279
284
|
var rejectStepByLengthLimit = !isSafeLength || !isSafeIntegerLength;
|
|
@@ -281,7 +286,7 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
281
286
|
console.warn("WARNING: Incrementer's step was not fulfilled since result oversteps input ".concat(maxDigitLength, "-digit limit and can't be presented without a loss of precision."));
|
|
282
287
|
return;
|
|
283
288
|
}
|
|
284
|
-
var formatted = format(locale, precision, 'always', calculated, true);
|
|
289
|
+
var formatted = wasClamped ? formatValue(clampedNumber) : format(locale, precision, 'always', calculated, true);
|
|
285
290
|
setInputValue(formatted);
|
|
286
291
|
externalOnChange(formatted);
|
|
287
292
|
};
|
|
@@ -369,33 +374,45 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
369
374
|
var isDecimalSeparatorRedundant = verifiedDecimalScale > 0 && inputValue[inputValue.length - 1] === decimal && !fillDecimalScaleOnBlur;
|
|
370
375
|
var isDecimalScaleNotFilled = verifiedDecimalScale - fraction.length > 0;
|
|
371
376
|
var shouldDecimalScaleBeFilled = fillDecimalScaleOnBlur && isDecimalScaleNotFilled;
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
377
|
+
var getBaseValue = function getBaseValue() {
|
|
378
|
+
if (shouldValueBeCleared) {
|
|
379
|
+
return emptyString;
|
|
380
|
+
}
|
|
381
|
+
if (shouldIntegerPartBeFilled) {
|
|
382
|
+
var numberOfZerosToPad = verifiedDecimalScale - fraction.length;
|
|
383
|
+
return "".concat(integer, "0").concat(decimal).concat(shouldDecimalScaleBeFilled ? fraction.concat(Array.from({
|
|
384
|
+
length: numberOfZerosToPad
|
|
385
|
+
}, function (_) {
|
|
386
|
+
return '0';
|
|
387
|
+
}).join(emptyString)) : fraction);
|
|
388
|
+
}
|
|
389
|
+
if (isDecimalSeparatorRedundant) {
|
|
390
|
+
return inputValue.replace(new RegExp("[".concat(decimal, "]"), 'g'), emptyString);
|
|
391
|
+
}
|
|
392
|
+
if (shouldDecimalScaleBeFilled) {
|
|
393
|
+
return format(locale, verifiedDecimalScale, 'always', inputValue);
|
|
394
|
+
}
|
|
395
|
+
return inputValue;
|
|
396
|
+
};
|
|
397
|
+
var baseValue = getBaseValue();
|
|
398
|
+
var hasBounds = typeof min === 'number' || typeof max === 'number';
|
|
399
|
+
var _unformat5 = unformat(locale, baseValue),
|
|
400
|
+
baseParsed = _unformat5.parsedNumber;
|
|
401
|
+
var clampedParsed = clamp(baseParsed, min, max);
|
|
402
|
+
var needsClamp = hasBounds && Number.isFinite(baseParsed) && clampedParsed !== baseParsed;
|
|
403
|
+
var clampFillScale = fixedDecimalScale || fillDecimalScaleOnBlur ? 'always' : 'none';
|
|
404
|
+
var finalValue = needsClamp ? format(locale, verifiedDecimalScale, clampFillScale, clampedParsed, true) : baseValue;
|
|
405
|
+
if (finalValue !== inputValue) {
|
|
406
|
+
setInputValue(finalValue);
|
|
407
|
+
externalOnChange(finalValue);
|
|
396
408
|
}
|
|
397
409
|
_onBlur(e);
|
|
398
410
|
};
|
|
411
|
+
var _unformat6 = unformat(locale, inputValue),
|
|
412
|
+
currentParsedNumber = _unformat6.parsedNumber;
|
|
413
|
+
var hasFiniteValue = Number.isFinite(currentParsedNumber);
|
|
414
|
+
var isAtMax = hasFiniteValue && Number.isFinite(max) && currentParsedNumber >= max;
|
|
415
|
+
var isAtMin = hasFiniteValue && Number.isFinite(min) && currentParsedNumber <= min;
|
|
399
416
|
return /*#__PURE__*/React.createElement(StyledWrapper, {
|
|
400
417
|
$hasIncrementer: hasIncrementer,
|
|
401
418
|
"data-qa": qa === null || qa === void 0 ? void 0 : qa.wrapper
|
|
@@ -427,7 +444,7 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
427
444
|
}, suffixProps), suffix), hasIncrementer && /*#__PURE__*/React.createElement(StyledIncrementerWrapper, null, /*#__PURE__*/React.createElement(StyledIncrementerButton, {
|
|
428
445
|
"aria-hidden": "true",
|
|
429
446
|
type: "button",
|
|
430
|
-
disabled: disabled,
|
|
447
|
+
disabled: disabled || isAtMax,
|
|
431
448
|
tabIndex: -1,
|
|
432
449
|
"data-qa": qa === null || qa === void 0 ? void 0 : qa.increment,
|
|
433
450
|
onClick: function onClick() {
|
|
@@ -436,7 +453,7 @@ export var NumberInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
436
453
|
}, /*#__PURE__*/React.createElement(PlusIcon, null)), /*#__PURE__*/React.createElement(StyledIncrementerButton, {
|
|
437
454
|
"aria-hidden": "true",
|
|
438
455
|
type: "button",
|
|
439
|
-
disabled: disabled,
|
|
456
|
+
disabled: disabled || isAtMin,
|
|
440
457
|
tabIndex: -1,
|
|
441
458
|
"data-qa": qa === null || qa === void 0 ? void 0 : qa.decrement,
|
|
442
459
|
onClick: function onClick() {
|