@moda/om 21.13.0 → 21.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +81 -61
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +81 -62
- package/dist/index.esm.js.map +1 -1
- package/dist/src/components/Constrain/Constrain.d.ts +4 -1
- package/dist/src/components/Drawer/Drawer.d.ts +6 -0
- package/dist/src/components/Drawer/Drawer.stories.d.ts +6 -0
- package/dist/src/components/Drawer/Drawer.test.d.ts +1 -0
- package/dist/src/components/Drawer/index.d.ts +1 -0
- package/dist/src/components/index.d.ts +1 -0
- package/dist/styles.css +1 -1
- package/package.json +1 -2
- package/src/components/Constrain/Constrain.scss +4 -0
- package/src/components/Constrain/Constrain.tsx +13 -3
- package/src/components/Drawer/Drawer.scss +22 -0
- package/src/components/Drawer/Drawer.stories.tsx +26 -0
- package/src/components/Drawer/Drawer.test.tsx +27 -0
- package/src/components/Drawer/Drawer.tsx +13 -0
- package/src/components/Drawer/index.ts +1 -0
- package/src/components/index.ts +1 -0
package/dist/index.cjs.js
CHANGED
|
@@ -1355,11 +1355,11 @@ var StateProps = function StateProps(_ref) {
|
|
|
1355
1355
|
}, stringifyProps(props)), ' ', !isRenderProps(children) && !isEmpty(childrenProps) && /*#__PURE__*/React.createElement("span", null, stringifyProps(childrenProps)), /*#__PURE__*/React.createElement("span", null, ' />'));
|
|
1356
1356
|
};
|
|
1357
1357
|
|
|
1358
|
-
var _excluded$
|
|
1358
|
+
var _excluded$I = ["props", "children"];
|
|
1359
1359
|
var State = function State(_ref) {
|
|
1360
1360
|
var props = _ref.props,
|
|
1361
1361
|
children = _ref.children,
|
|
1362
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
1362
|
+
rest = _objectWithoutProperties(_ref, _excluded$I);
|
|
1363
1363
|
var styles = useStyles();
|
|
1364
1364
|
var Specimen = isRenderProps(children) ? children(props) : /*#__PURE__*/React.cloneElement(children, props);
|
|
1365
1365
|
var innerChildren = isRenderProps(children) ? children(props) : children;
|
|
@@ -1370,12 +1370,12 @@ var State = function State(_ref) {
|
|
|
1370
1370
|
}, innerChildren));
|
|
1371
1371
|
};
|
|
1372
1372
|
|
|
1373
|
-
var _excluded$
|
|
1373
|
+
var _excluded$H = ["states", "children"];
|
|
1374
1374
|
var States = function States(_ref) {
|
|
1375
1375
|
var _ref$states = _ref.states,
|
|
1376
1376
|
states = _ref$states === void 0 ? [{}] : _ref$states,
|
|
1377
1377
|
children = _ref.children,
|
|
1378
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
1378
|
+
rest = _objectWithoutProperties(_ref, _excluded$H);
|
|
1379
1379
|
return /*#__PURE__*/React.createElement(React.Fragment, null, states.map(function (props, index) {
|
|
1380
1380
|
return /*#__PURE__*/React.createElement(State, _extends$1({
|
|
1381
1381
|
key: index,
|
|
@@ -5431,7 +5431,7 @@ function requireDist$3() {
|
|
|
5431
5431
|
|
|
5432
5432
|
var distExports$3 = requireDist$3();
|
|
5433
5433
|
|
|
5434
|
-
var _excluded$
|
|
5434
|
+
var _excluded$G = ["aspectWidth", "aspectHeight", "maxWidth", "maxHeight", "outlined", "children", "className"];
|
|
5435
5435
|
var DEFAULT_PRODUCT_ASPECT_WIDTH = 128;
|
|
5436
5436
|
var DEFAULT_PRODUCT_ASPECT_HEIGHT = 205;
|
|
5437
5437
|
var DEFAULT_PRODUCT_ASPECT_RATIO = DEFAULT_PRODUCT_ASPECT_HEIGHT / DEFAULT_PRODUCT_ASPECT_WIDTH;
|
|
@@ -5477,7 +5477,7 @@ var AspectRatioBox = /*#__PURE__*/React.forwardRef(function (_ref2, forwardedRef
|
|
|
5477
5477
|
outlined = _ref2$outlined === void 0 ? false : _ref2$outlined,
|
|
5478
5478
|
children = _ref2.children,
|
|
5479
5479
|
className = _ref2.className,
|
|
5480
|
-
rest = _objectWithoutProperties(_ref2, _excluded$
|
|
5480
|
+
rest = _objectWithoutProperties(_ref2, _excluded$G);
|
|
5481
5481
|
var _scaleDimensions = scaleDimensions({
|
|
5482
5482
|
width: aspectWidth,
|
|
5483
5483
|
height: aspectHeight,
|
|
@@ -5505,22 +5505,22 @@ var AspectRatioBox = /*#__PURE__*/React.forwardRef(function (_ref2, forwardedRef
|
|
|
5505
5505
|
});
|
|
5506
5506
|
AspectRatioBox.displayName = 'AspectRatioBox';
|
|
5507
5507
|
|
|
5508
|
-
var _excluded$
|
|
5508
|
+
var _excluded$F = ["className", "theme", "children"];
|
|
5509
5509
|
var Badge = function Badge(_ref) {
|
|
5510
5510
|
var className = _ref.className,
|
|
5511
5511
|
theme = _ref.theme,
|
|
5512
5512
|
children = _ref.children,
|
|
5513
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5513
|
+
rest = _objectWithoutProperties(_ref, _excluded$F);
|
|
5514
5514
|
return /*#__PURE__*/React.createElement("span", _extends$1({
|
|
5515
5515
|
className: classNames('Badge', theme && "Badge--".concat(theme), className)
|
|
5516
5516
|
}, rest), children);
|
|
5517
5517
|
};
|
|
5518
5518
|
|
|
5519
|
-
var _excluded$
|
|
5519
|
+
var _excluded$E = ["children", "className"];
|
|
5520
5520
|
var Breadcrumbs = function Breadcrumbs(_ref) {
|
|
5521
5521
|
var children = _ref.children,
|
|
5522
5522
|
className = _ref.className,
|
|
5523
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5523
|
+
rest = _objectWithoutProperties(_ref, _excluded$E);
|
|
5524
5524
|
var position = 0;
|
|
5525
5525
|
return /*#__PURE__*/React.createElement("ol", _extends$1({
|
|
5526
5526
|
itemScope: true,
|
|
@@ -5538,7 +5538,7 @@ var Breadcrumbs = function Breadcrumbs(_ref) {
|
|
|
5538
5538
|
}));
|
|
5539
5539
|
};
|
|
5540
5540
|
|
|
5541
|
-
var _excluded$
|
|
5541
|
+
var _excluded$D = ["className", "styleless", "disabled"];
|
|
5542
5542
|
|
|
5543
5543
|
// Define minimal LinkProps that work with both v5 and v7
|
|
5544
5544
|
// Using Omit to remove conflicting HTML attributes, then add router-specific props
|
|
@@ -5557,7 +5557,7 @@ var Clickable = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
5557
5557
|
_ref$styleless = _ref.styleless,
|
|
5558
5558
|
styleless = _ref$styleless === void 0 ? false : _ref$styleless,
|
|
5559
5559
|
disabled = _ref.disabled,
|
|
5560
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5560
|
+
rest = _objectWithoutProperties(_ref, _excluded$D);
|
|
5561
5561
|
var baseClassName = classNames({
|
|
5562
5562
|
Clickable: !styleless,
|
|
5563
5563
|
'Clickable--disabled': disabled
|
|
@@ -5585,14 +5585,14 @@ var Clickable = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
5585
5585
|
});
|
|
5586
5586
|
Clickable.displayName = 'Clickable';
|
|
5587
5587
|
|
|
5588
|
-
var _excluded$
|
|
5588
|
+
var _excluded$C = ["className", "disabled", "children", "underlined"];
|
|
5589
5589
|
var ControlLink = function ControlLink(_ref) {
|
|
5590
5590
|
var className = _ref.className,
|
|
5591
5591
|
disabled = _ref.disabled,
|
|
5592
5592
|
children = _ref.children,
|
|
5593
5593
|
_ref$underlined = _ref.underlined,
|
|
5594
5594
|
underlined = _ref$underlined === void 0 ? true : _ref$underlined,
|
|
5595
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5595
|
+
rest = _objectWithoutProperties(_ref, _excluded$C);
|
|
5596
5596
|
return /*#__PURE__*/React.createElement(Clickable, _extends$1({}, rest, {
|
|
5597
5597
|
className: classNames('ControlLink', {
|
|
5598
5598
|
'ControlLink--underlined': underlined
|
|
@@ -5603,12 +5603,12 @@ var ControlLink = function ControlLink(_ref) {
|
|
|
5603
5603
|
}), children);
|
|
5604
5604
|
};
|
|
5605
5605
|
|
|
5606
|
-
var _excluded$
|
|
5606
|
+
var _excluded$B = ["children", "position", "className"];
|
|
5607
5607
|
var Breadcrumb = function Breadcrumb(_ref) {
|
|
5608
5608
|
var children = _ref.children,
|
|
5609
5609
|
position = _ref.position,
|
|
5610
5610
|
className = _ref.className,
|
|
5611
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5611
|
+
rest = _objectWithoutProperties(_ref, _excluded$B);
|
|
5612
5612
|
return /*#__PURE__*/React.createElement("li", {
|
|
5613
5613
|
className: classNames('Breadcrumb', className),
|
|
5614
5614
|
itemProp: "itemListElement",
|
|
@@ -7352,11 +7352,11 @@ var useBreakpoint = function useBreakpoint(props) {
|
|
|
7352
7352
|
};
|
|
7353
7353
|
};
|
|
7354
7354
|
|
|
7355
|
-
var _excluded$
|
|
7355
|
+
var _excluded$A = ["children", "className"];
|
|
7356
7356
|
var Breakpoint = function Breakpoint(_ref) {
|
|
7357
7357
|
var children = _ref.children,
|
|
7358
7358
|
className = _ref.className,
|
|
7359
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7359
|
+
rest = _objectWithoutProperties(_ref, _excluded$A);
|
|
7360
7360
|
var _discriminate = discriminate(rest),
|
|
7361
7361
|
mode = _discriminate.mode,
|
|
7362
7362
|
breakpoint = _discriminate.breakpoint;
|
|
@@ -7367,7 +7367,7 @@ var Breakpoint = function Breakpoint(_ref) {
|
|
|
7367
7367
|
}, omit(['at', 'gt', 'lt'], rest)), children) : null;
|
|
7368
7368
|
};
|
|
7369
7369
|
|
|
7370
|
-
var _excluded$
|
|
7370
|
+
var _excluded$z = ["secondary", "tertiary", "elevated", "chip", "hover", "focus", "disabled", "className"];
|
|
7371
7371
|
var Button = function Button(_ref) {
|
|
7372
7372
|
var secondary = _ref.secondary,
|
|
7373
7373
|
tertiary = _ref.tertiary,
|
|
@@ -7377,7 +7377,7 @@ var Button = function Button(_ref) {
|
|
|
7377
7377
|
focus = _ref.focus,
|
|
7378
7378
|
disabled = _ref.disabled,
|
|
7379
7379
|
className = _ref.className,
|
|
7380
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7380
|
+
rest = _objectWithoutProperties(_ref, _excluded$z);
|
|
7381
7381
|
return /*#__PURE__*/React.createElement(Clickable, _extends$1({
|
|
7382
7382
|
className: classNames('Button', {
|
|
7383
7383
|
'Button--chip': chip,
|
|
@@ -7501,7 +7501,7 @@ var Circle12 = function Circle12(_a) {
|
|
|
7501
7501
|
};
|
|
7502
7502
|
Circle12.displayName = 'Circle12';
|
|
7503
7503
|
|
|
7504
|
-
var _excluded$
|
|
7504
|
+
var _excluded$y = ["className", "defaultChecked", "checked", "children", "value", "onChange", "disabled", "checkIcon", "dataTestId", "id"];
|
|
7505
7505
|
var CHECKED_ITEM_PROPS = {
|
|
7506
7506
|
className: 'Checkbox__check-mark',
|
|
7507
7507
|
height: '85%',
|
|
@@ -7520,7 +7520,7 @@ var Checkbox = function Checkbox(_ref) {
|
|
|
7520
7520
|
checkIcon = _ref$checkIcon === void 0 ? 'checkmark' : _ref$checkIcon,
|
|
7521
7521
|
dataTestId = _ref.dataTestId,
|
|
7522
7522
|
id = _ref.id,
|
|
7523
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7523
|
+
rest = _objectWithoutProperties(_ref, _excluded$y);
|
|
7524
7524
|
var _useState = React.useState((_ref2 = checked !== null && checked !== void 0 ? checked : defaultChecked) !== null && _ref2 !== void 0 ? _ref2 : false),
|
|
7525
7525
|
_useState2 = _slicedToArray(_useState, 2),
|
|
7526
7526
|
isChecked = _useState2[0],
|
|
@@ -7610,7 +7610,7 @@ var SKU_COLORS = {
|
|
|
7610
7610
|
yellow: '#ffca44'
|
|
7611
7611
|
};
|
|
7612
7612
|
|
|
7613
|
-
var _excluded$
|
|
7613
|
+
var _excluded$x = ["className", "size", "color", "backgroundUrl", "focus", "hover", "selected", "soldOut", "onSale", "onClick", "onMouseEnter", "disabled", "title"];
|
|
7614
7614
|
var ColorSwatch = function ColorSwatch(_ref) {
|
|
7615
7615
|
var _SKU_COLORS;
|
|
7616
7616
|
var className = _ref.className,
|
|
@@ -7626,7 +7626,7 @@ var ColorSwatch = function ColorSwatch(_ref) {
|
|
|
7626
7626
|
onMouseEnter = _ref.onMouseEnter,
|
|
7627
7627
|
disabled = _ref.disabled,
|
|
7628
7628
|
title = _ref.title,
|
|
7629
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7629
|
+
rest = _objectWithoutProperties(_ref, _excluded$x);
|
|
7630
7630
|
var handleClick = React.useCallback(function (_event) {
|
|
7631
7631
|
onClick === null || onClick === void 0 || onClick(color, title);
|
|
7632
7632
|
}, [color, title, onClick]);
|
|
@@ -7661,7 +7661,7 @@ var ColorSwatch = function ColorSwatch(_ref) {
|
|
|
7661
7661
|
}));
|
|
7662
7662
|
};
|
|
7663
7663
|
|
|
7664
|
-
var _excluded$
|
|
7664
|
+
var _excluded$w = ["className", "children", "onClose", "shards", "autoFocus"];
|
|
7665
7665
|
var Modal = function Modal(_ref) {
|
|
7666
7666
|
var className = _ref.className,
|
|
7667
7667
|
children = _ref.children,
|
|
@@ -7669,7 +7669,7 @@ var Modal = function Modal(_ref) {
|
|
|
7669
7669
|
shards = _ref.shards,
|
|
7670
7670
|
_ref$autoFocus = _ref.autoFocus,
|
|
7671
7671
|
autoFocus = _ref$autoFocus === void 0 ? true : _ref$autoFocus,
|
|
7672
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7672
|
+
rest = _objectWithoutProperties(_ref, _excluded$w);
|
|
7673
7673
|
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
7674
7674
|
className: classNames('Modal', className),
|
|
7675
7675
|
role: "dialog",
|
|
@@ -7682,14 +7682,14 @@ var Modal = function Modal(_ref) {
|
|
|
7682
7682
|
}, children));
|
|
7683
7683
|
};
|
|
7684
7684
|
|
|
7685
|
-
var _excluded$
|
|
7685
|
+
var _excluded$v = ["className", "children", "show"];
|
|
7686
7686
|
var UNMOUNT_DELAY_MS = 500;
|
|
7687
7687
|
var Overlay = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
7688
7688
|
var className = _ref.className,
|
|
7689
7689
|
children = _ref.children,
|
|
7690
7690
|
_ref$show = _ref.show,
|
|
7691
7691
|
show = _ref$show === void 0 ? true : _ref$show,
|
|
7692
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7692
|
+
rest = _objectWithoutProperties(_ref, _excluded$v);
|
|
7693
7693
|
var _useState = React.useState(show),
|
|
7694
7694
|
_useState2 = _slicedToArray(_useState, 2),
|
|
7695
7695
|
open = _useState2[0],
|
|
@@ -7716,7 +7716,7 @@ var Overlay = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
|
7716
7716
|
});
|
|
7717
7717
|
Overlay.displayName = 'Overlay';
|
|
7718
7718
|
|
|
7719
|
-
var _excluded$
|
|
7719
|
+
var _excluded$u = ["children", "className", "contentClassName", "onClose", "overlayClassName", "show", "shards", "autoFocus"];
|
|
7720
7720
|
var ModalOverlay = function ModalOverlay(_ref) {
|
|
7721
7721
|
var children = _ref.children,
|
|
7722
7722
|
className = _ref.className,
|
|
@@ -7727,7 +7727,7 @@ var ModalOverlay = function ModalOverlay(_ref) {
|
|
|
7727
7727
|
show = _ref$show === void 0 ? true : _ref$show,
|
|
7728
7728
|
shards = _ref.shards,
|
|
7729
7729
|
autoFocus = _ref.autoFocus,
|
|
7730
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7730
|
+
rest = _objectWithoutProperties(_ref, _excluded$u);
|
|
7731
7731
|
var element = React.useMemo(function () {
|
|
7732
7732
|
return typeof document !== 'undefined' ? document.createElement('div') : null;
|
|
7733
7733
|
}, []);
|
|
@@ -7753,7 +7753,7 @@ var ModalOverlay = function ModalOverlay(_ref) {
|
|
|
7753
7753
|
}, children))), element);
|
|
7754
7754
|
};
|
|
7755
7755
|
|
|
7756
|
-
var _excluded$
|
|
7756
|
+
var _excluded$t = ["className", "children", "space", "direction", "alignItems", "justifyContent", "style"];
|
|
7757
7757
|
var Stack = function Stack(_ref) {
|
|
7758
7758
|
var className = _ref.className,
|
|
7759
7759
|
children = _ref.children,
|
|
@@ -7763,7 +7763,7 @@ var Stack = function Stack(_ref) {
|
|
|
7763
7763
|
alignItems = _ref.alignItems,
|
|
7764
7764
|
justifyContent = _ref.justifyContent,
|
|
7765
7765
|
style = _ref.style,
|
|
7766
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7766
|
+
rest = _objectWithoutProperties(_ref, _excluded$t);
|
|
7767
7767
|
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
7768
7768
|
className: classNames("Stack Stack--".concat(direction, "-").concat(space), className),
|
|
7769
7769
|
style: _objectSpread2(_objectSpread2({}, style), {}, {
|
|
@@ -7773,7 +7773,7 @@ var Stack = function Stack(_ref) {
|
|
|
7773
7773
|
}, rest), children);
|
|
7774
7774
|
};
|
|
7775
7775
|
|
|
7776
|
-
var _excluded$
|
|
7776
|
+
var _excluded$s = ["as", "className", "treatment", "color", "family", "children", "style"];
|
|
7777
7777
|
var Text = function Text(_ref) {
|
|
7778
7778
|
var _ref$as = _ref.as,
|
|
7779
7779
|
Component = _ref$as === void 0 ? 'span' : _ref$as,
|
|
@@ -7785,7 +7785,7 @@ var Text = function Text(_ref) {
|
|
|
7785
7785
|
family = _ref.family,
|
|
7786
7786
|
children = _ref.children,
|
|
7787
7787
|
style = _ref.style,
|
|
7788
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7788
|
+
rest = _objectWithoutProperties(_ref, _excluded$s);
|
|
7789
7789
|
return /*#__PURE__*/React.createElement(Component, _extends$1({
|
|
7790
7790
|
className: classNames("Text Text--".concat(treatment, " ").concat(family ? "Text--".concat(family) : ''), className),
|
|
7791
7791
|
style: _objectSpread2({
|
|
@@ -7794,13 +7794,13 @@ var Text = function Text(_ref) {
|
|
|
7794
7794
|
}, rest), children);
|
|
7795
7795
|
};
|
|
7796
7796
|
|
|
7797
|
-
var _excluded$
|
|
7797
|
+
var _excluded$r = ["title", "message", "actions", "contentClassName"];
|
|
7798
7798
|
var Dialog = function Dialog(_ref) {
|
|
7799
7799
|
var title = _ref.title,
|
|
7800
7800
|
message = _ref.message,
|
|
7801
7801
|
actions = _ref.actions,
|
|
7802
7802
|
contentClassName = _ref.contentClassName,
|
|
7803
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7803
|
+
rest = _objectWithoutProperties(_ref, _excluded$r);
|
|
7804
7804
|
var titleId = React.useId();
|
|
7805
7805
|
return /*#__PURE__*/React.createElement(ModalOverlay, _extends$1({
|
|
7806
7806
|
contentClassName: classNames('Dialog', contentClassName),
|
|
@@ -7902,21 +7902,25 @@ var useConfirm = function useConfirm() {
|
|
|
7902
7902
|
return React.useContext(ConfirmContext);
|
|
7903
7903
|
};
|
|
7904
7904
|
|
|
7905
|
-
var _excluded$
|
|
7905
|
+
var _excluded$q = ["className", "children", "size"];
|
|
7906
7906
|
var Constrain = function Constrain(_ref) {
|
|
7907
7907
|
var className = _ref.className,
|
|
7908
7908
|
children = _ref.children,
|
|
7909
|
-
|
|
7909
|
+
_ref$size = _ref.size,
|
|
7910
|
+
size = _ref$size === void 0 ? 'medium' : _ref$size,
|
|
7911
|
+
rest = _objectWithoutProperties(_ref, _excluded$q);
|
|
7910
7912
|
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
7911
|
-
className: classNames('Constrain',
|
|
7913
|
+
className: classNames('Constrain', {
|
|
7914
|
+
'Constrain--wide': size === 'wide'
|
|
7915
|
+
}, className)
|
|
7912
7916
|
}, rest), children);
|
|
7913
7917
|
};
|
|
7914
7918
|
|
|
7915
|
-
var _excluded$
|
|
7919
|
+
var _excluded$p = ["className", "children"];
|
|
7916
7920
|
var ExceedConstrain = function ExceedConstrain(_ref) {
|
|
7917
7921
|
var className = _ref.className,
|
|
7918
7922
|
children = _ref.children,
|
|
7919
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
7923
|
+
rest = _objectWithoutProperties(_ref, _excluded$p);
|
|
7920
7924
|
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
7921
7925
|
className: classNames('ExceedConstrain', className)
|
|
7922
7926
|
}, rest), children);
|
|
@@ -9880,7 +9884,7 @@ var Warning16 = function Warning16(_a) {
|
|
|
9880
9884
|
};
|
|
9881
9885
|
Warning16.displayName = 'Warning16';
|
|
9882
9886
|
|
|
9883
|
-
var _excluded$
|
|
9887
|
+
var _excluded$o = ["className", "disabled", "error", "focus", "placeholder", "label", "onChange", "onChangeEvent"];
|
|
9884
9888
|
var TextInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
9885
9889
|
var className = _ref.className,
|
|
9886
9890
|
disabled = _ref.disabled,
|
|
@@ -9890,7 +9894,7 @@ var TextInput = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
9890
9894
|
label = _ref.label,
|
|
9891
9895
|
_onChange = _ref.onChange,
|
|
9892
9896
|
onChangeEvent = _ref.onChangeEvent,
|
|
9893
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
9897
|
+
rest = _objectWithoutProperties(_ref, _excluded$o);
|
|
9894
9898
|
return /*#__PURE__*/React.createElement("input", _extends$1({
|
|
9895
9899
|
className: classNames('TextInput', className, {
|
|
9896
9900
|
'TextInput--focus': focus,
|
|
@@ -10346,7 +10350,7 @@ var Search20 = function Search20(_a) {
|
|
|
10346
10350
|
};
|
|
10347
10351
|
Search20.displayName = 'Search20';
|
|
10348
10352
|
|
|
10349
|
-
var _excluded$
|
|
10353
|
+
var _excluded$n = ["className", "onChange", "onClear", "roundBorders", "noBorders", "value", "searchIconSize"];
|
|
10350
10354
|
var SEARCH_ICON_DEFAULT_SIZE = 20;
|
|
10351
10355
|
var DEFAULT_INPUT_VALUE = '';
|
|
10352
10356
|
var SearchInput = function SearchInput(_ref) {
|
|
@@ -10361,7 +10365,7 @@ var SearchInput = function SearchInput(_ref) {
|
|
|
10361
10365
|
value = _ref$value === void 0 ? DEFAULT_INPUT_VALUE : _ref$value,
|
|
10362
10366
|
_ref$searchIconSize = _ref.searchIconSize,
|
|
10363
10367
|
searchIconSize = _ref$searchIconSize === void 0 ? SEARCH_ICON_DEFAULT_SIZE : _ref$searchIconSize,
|
|
10364
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
10368
|
+
rest = _objectWithoutProperties(_ref, _excluded$n);
|
|
10365
10369
|
var ref = React.useRef(null);
|
|
10366
10370
|
var _useState = React.useState(value),
|
|
10367
10371
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -10626,7 +10630,7 @@ var SelectOption = function SelectOption(_ref) {
|
|
|
10626
10630
|
}), label);
|
|
10627
10631
|
};
|
|
10628
10632
|
|
|
10629
|
-
var _excluded$
|
|
10633
|
+
var _excluded$m = ["idRef", "searchable", "autoFocus", "options", "selectedOption", "onSelect", "onFocus", "className", "dataTestId", "extraOption", "onCloseDropdown"];
|
|
10630
10634
|
var SelectOptions = function SelectOptions(_ref) {
|
|
10631
10635
|
var idRef = _ref.idRef,
|
|
10632
10636
|
searchable = _ref.searchable,
|
|
@@ -10640,7 +10644,7 @@ var SelectOptions = function SelectOptions(_ref) {
|
|
|
10640
10644
|
dataTestId = _ref.dataTestId,
|
|
10641
10645
|
extraOption = _ref.extraOption,
|
|
10642
10646
|
onCloseDropdown = _ref.onCloseDropdown,
|
|
10643
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
10647
|
+
rest = _objectWithoutProperties(_ref, _excluded$m);
|
|
10644
10648
|
var _useState = React.useState(''),
|
|
10645
10649
|
_useState2 = _slicedToArray(_useState, 2),
|
|
10646
10650
|
searchPhrase = _useState2[0],
|
|
@@ -10825,7 +10829,7 @@ var useSelect = function useSelect(_ref) {
|
|
|
10825
10829
|
};
|
|
10826
10830
|
};
|
|
10827
10831
|
|
|
10828
|
-
var _excluded$
|
|
10832
|
+
var _excluded$l = ["allowAutoFill", "autoSelect", "className", "defaultValue", "disabled", "dropDirection", "error", "idRef", "label", "name", "onChange", "options", "placeholder", "searchable", "shiftIconLeftwards", "value", "dataTestId", "colorSwatch", "extraOption", "paddingRight", "smallMobileText"];
|
|
10829
10833
|
var Select = function Select(_ref) {
|
|
10830
10834
|
var _ref2, _ref3;
|
|
10831
10835
|
var _ref$allowAutoFill = _ref.allowAutoFill,
|
|
@@ -10855,7 +10859,7 @@ var Select = function Select(_ref) {
|
|
|
10855
10859
|
paddingRight = _ref.paddingRight,
|
|
10856
10860
|
_ref$smallMobileText = _ref.smallMobileText,
|
|
10857
10861
|
smallMobileText = _ref$smallMobileText === void 0 ? false : _ref$smallMobileText,
|
|
10858
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
10862
|
+
rest = _objectWithoutProperties(_ref, _excluded$l);
|
|
10859
10863
|
var _useFormControlContex = useFormControlContext(),
|
|
10860
10864
|
errorDisplayedByParent = _useFormControlContex.displaysError;
|
|
10861
10865
|
var _useSelect = useSelect({
|
|
@@ -11048,7 +11052,7 @@ var Exit16 = function Exit16(_a) {
|
|
|
11048
11052
|
};
|
|
11049
11053
|
Exit16.displayName = 'Exit16';
|
|
11050
11054
|
|
|
11051
|
-
var _excluded$
|
|
11055
|
+
var _excluded$k = ["className", "defaultValue", "disabled", "dropDirection", "error", "idRef", "onChange", "options", "searchable", "shiftIconLeftwards", "value"];
|
|
11052
11056
|
var MultiSelect = function MultiSelect(_ref) {
|
|
11053
11057
|
var className = _ref.className,
|
|
11054
11058
|
defaultValue = _ref.defaultValue,
|
|
@@ -11063,7 +11067,7 @@ var MultiSelect = function MultiSelect(_ref) {
|
|
|
11063
11067
|
searchable = _ref.searchable,
|
|
11064
11068
|
shiftIconLeftwards = _ref.shiftIconLeftwards,
|
|
11065
11069
|
value = _ref.value,
|
|
11066
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11070
|
+
rest = _objectWithoutProperties(_ref, _excluded$k);
|
|
11067
11071
|
var _useSelect = useSelect({
|
|
11068
11072
|
value: value,
|
|
11069
11073
|
defaultValue: defaultValue
|
|
@@ -11176,7 +11180,7 @@ var MultiSelect = function MultiSelect(_ref) {
|
|
|
11176
11180
|
}));
|
|
11177
11181
|
};
|
|
11178
11182
|
|
|
11179
|
-
var _excluded$
|
|
11183
|
+
var _excluded$j = ["className", "children", "error", "label", "placeholder", "showErrorIcon"];
|
|
11180
11184
|
var Field = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
11181
11185
|
var className = _ref.className,
|
|
11182
11186
|
children = _ref.children,
|
|
@@ -11185,7 +11189,7 @@ var Field = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
11185
11189
|
placeholder = _ref.placeholder,
|
|
11186
11190
|
_ref$showErrorIcon = _ref.showErrorIcon,
|
|
11187
11191
|
showErrorIcon = _ref$showErrorIcon === void 0 ? true : _ref$showErrorIcon,
|
|
11188
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11192
|
+
rest = _objectWithoutProperties(_ref, _excluded$j);
|
|
11189
11193
|
var id = React.useId();
|
|
11190
11194
|
var errorId = "".concat(id, "-error");
|
|
11191
11195
|
var fieldContextValue = React.useMemo(function () {
|
|
@@ -11229,16 +11233,16 @@ var Field = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
11229
11233
|
});
|
|
11230
11234
|
Field.displayName = 'Field';
|
|
11231
11235
|
|
|
11232
|
-
var _excluded$
|
|
11236
|
+
var _excluded$i = ["onChange"];
|
|
11233
11237
|
var CreditCardNumberInputField = function CreditCardNumberInputField(_ref) {
|
|
11234
11238
|
var onChange = _ref.onChange,
|
|
11235
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11239
|
+
rest = _objectWithoutProperties(_ref, _excluded$i);
|
|
11236
11240
|
return /*#__PURE__*/React.createElement(Field, _extends$1({}, rest, {
|
|
11237
11241
|
onChangeEvent: onChange
|
|
11238
11242
|
}));
|
|
11239
11243
|
};
|
|
11240
11244
|
|
|
11241
|
-
var _excluded$
|
|
11245
|
+
var _excluded$h = ["value", "disabled", "readOnly", "defaultValue", "maskChar", "alwaysShowMask", "onMouseDown", "onFocus", "onBlur", "onChange"];
|
|
11242
11246
|
var DEFAULT_MASK = '9999 9999 9999 9999';
|
|
11243
11247
|
var CreditCardNumberInput = function CreditCardNumberInput(_ref) {
|
|
11244
11248
|
var _ref2;
|
|
@@ -11252,7 +11256,7 @@ var CreditCardNumberInput = function CreditCardNumberInput(_ref) {
|
|
|
11252
11256
|
onFocus = _ref.onFocus,
|
|
11253
11257
|
onBlur = _ref.onBlur,
|
|
11254
11258
|
onChange = _ref.onChange,
|
|
11255
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11259
|
+
rest = _objectWithoutProperties(_ref, _excluded$h);
|
|
11256
11260
|
var _useState = React.useState((_ref2 = propsValue !== null && propsValue !== void 0 ? propsValue : defaultValue) !== null && _ref2 !== void 0 ? _ref2 : ''),
|
|
11257
11261
|
_useState2 = _slicedToArray(_useState, 2),
|
|
11258
11262
|
value = _useState2[0],
|
|
@@ -11290,18 +11294,18 @@ var CreditCardNumberInput = function CreditCardNumberInput(_ref) {
|
|
|
11290
11294
|
}, /*#__PURE__*/React.createElement(CreditCardNumberInputField, rest));
|
|
11291
11295
|
};
|
|
11292
11296
|
|
|
11293
|
-
var _excluded$
|
|
11297
|
+
var _excluded$g = ["term", "children", "className"];
|
|
11294
11298
|
var DefinitionList = function DefinitionList(_ref) {
|
|
11295
11299
|
var term = _ref.term,
|
|
11296
11300
|
children = _ref.children,
|
|
11297
11301
|
className = _ref.className,
|
|
11298
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11302
|
+
rest = _objectWithoutProperties(_ref, _excluded$g);
|
|
11299
11303
|
return /*#__PURE__*/React.createElement("dl", _extends$1({
|
|
11300
11304
|
className: classNames('DefinitionList', className)
|
|
11301
11305
|
}, rest), /*#__PURE__*/React.createElement("dt", null, term), /*#__PURE__*/React.createElement("dd", null, children));
|
|
11302
11306
|
};
|
|
11303
11307
|
|
|
11304
|
-
var _excluded$
|
|
11308
|
+
var _excluded$f = ["text", "treatment", "color", "family", "type", "className"];
|
|
11305
11309
|
var Divider = function Divider(_ref) {
|
|
11306
11310
|
var text = _ref.text,
|
|
11307
11311
|
treatment = _ref.treatment,
|
|
@@ -11309,7 +11313,7 @@ var Divider = function Divider(_ref) {
|
|
|
11309
11313
|
family = _ref.family,
|
|
11310
11314
|
type = _ref.type,
|
|
11311
11315
|
className = _ref.className,
|
|
11312
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
11316
|
+
rest = _objectWithoutProperties(_ref, _excluded$f);
|
|
11313
11317
|
var defaultTreatment = type === 'two-line' ? 'eyebrow' : 'h5';
|
|
11314
11318
|
var defaultFamily = type === 'two-line' ? undefined : 'serif';
|
|
11315
11319
|
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
@@ -11342,6 +11346,21 @@ var LineAboveDivider = function LineAboveDivider(props) {
|
|
|
11342
11346
|
}));
|
|
11343
11347
|
};
|
|
11344
11348
|
|
|
11349
|
+
var _excluded$e = ["className", "open", "children"];
|
|
11350
|
+
var Drawer = function Drawer(_ref) {
|
|
11351
|
+
var className = _ref.className,
|
|
11352
|
+
open = _ref.open,
|
|
11353
|
+
children = _ref.children,
|
|
11354
|
+
rest = _objectWithoutProperties(_ref, _excluded$e);
|
|
11355
|
+
return /*#__PURE__*/React.createElement("div", _extends$1({
|
|
11356
|
+
className: classNames('Drawer', {
|
|
11357
|
+
'Drawer--open': open
|
|
11358
|
+
}, className)
|
|
11359
|
+
}, rest), /*#__PURE__*/React.createElement("div", {
|
|
11360
|
+
className: "Drawer__content"
|
|
11361
|
+
}, children));
|
|
11362
|
+
};
|
|
11363
|
+
|
|
11345
11364
|
var _excluded$d = ["name", "children", "className", "virtual", "icon", "data-testid", "defaultExpanded", "expanded", "onToggle", "background", "border"];
|
|
11346
11365
|
var Expandable = function Expandable(_ref) {
|
|
11347
11366
|
var name = _ref.name,
|
|
@@ -13138,6 +13157,7 @@ exports.DefinitionList = DefinitionList;
|
|
|
13138
13157
|
exports.Dialog = Dialog;
|
|
13139
13158
|
exports.Diamond = Diamond;
|
|
13140
13159
|
exports.Divider = Divider;
|
|
13160
|
+
exports.Drawer = Drawer;
|
|
13141
13161
|
exports.ExceedConstrain = ExceedConstrain;
|
|
13142
13162
|
exports.Expandable = Expandable;
|
|
13143
13163
|
exports.Field = Field;
|