@salutejs/plasma-core 1.227.0-next-sbcom.0 → 1.227.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/__helpers/IconPlaceholder.js +6 -9
- package/__helpers/index.js +1 -1
- package/collectPackageInfo.js +4 -4
- package/components/Badge/Badge.js +30 -103
- package/components/Badge/index.js +1 -1
- package/components/Basebox/Basebox.js +33 -42
- package/components/Basebox/index.js +1 -1
- package/components/Button/Button.js +28 -67
- package/components/Button/Button.mixins.js +22 -76
- package/components/Button/Button.props.js +5 -5
- package/components/Button/createButton.js +14 -145
- package/components/Button/index.js +4 -4
- package/components/Card/Card.js +34 -162
- package/components/Card/CardBody.js +4 -4
- package/components/Card/CardContent.js +14 -23
- package/components/Card/CardMedia.js +20 -91
- package/components/Card/CardPrice.js +18 -60
- package/components/Card/CardTypography.js +43 -52
- package/components/Card/index.js +5 -5
- package/components/Carousel/Carousel.js +46 -64
- package/components/Carousel/CarouselItem.js +21 -93
- package/components/Carousel/hooks.js +62 -121
- package/components/Carousel/index.js +3 -3
- package/components/Carousel/utils.js +59 -73
- package/components/Fade/Fade.js +6 -9
- package/components/Fade/index.js +1 -1
- package/components/Field/Field.js +48 -63
- package/components/Field/Field.statuses.js +3 -3
- package/components/Field/index.js +2 -2
- package/components/Image/Image.js +34 -115
- package/components/Image/index.js +1 -1
- package/components/Input/Input.js +7 -7
- package/components/Input/Input.mixins.js +9 -12
- package/components/Input/index.js +1 -1
- package/components/ModalBase/ModalBase.js +22 -100
- package/components/ModalBase/ModalBaseContext.js +6 -9
- package/components/ModalBase/ModalOverlay.js +28 -111
- package/components/ModalBase/hooks.js +15 -43
- package/components/ModalBase/index.js +2 -2
- package/components/PaginationDots/PaginationDot.js +11 -17
- package/components/PaginationDots/PaginationDots.js +4 -7
- package/components/PaginationDots/index.js +3 -3
- package/components/PaginationDots/usePaginationDots.js +10 -11
- package/components/Popup/Popup.js +52 -205
- package/components/Popup/index.js +1 -1
- package/components/PopupBase/PopupBase.js +35 -169
- package/components/PopupBase/PopupBaseContext.js +26 -86
- package/components/PopupBase/PopupBaseRoot.js +31 -169
- package/components/PopupBase/hooks.js +23 -97
- package/components/PopupBase/index.js +3 -3
- package/components/PopupBase/utils.js +32 -78
- package/components/Price/Price.js +15 -90
- package/components/Price/index.js +1 -1
- package/components/RadioGroup/RadioGroup.js +6 -127
- package/components/RadioGroup/index.js +1 -1
- package/components/SSRProvider/SSRProvider.js +4 -5
- package/components/SSRProvider/index.js +1 -1
- package/components/Skeleton/LineSkeleton.js +23 -95
- package/components/Skeleton/RectSkeleton.js +20 -93
- package/components/Skeleton/Skeleton.js +2 -2
- package/components/Skeleton/TextSkeleton.js +11 -55
- package/components/Skeleton/index.js +3 -3
- package/components/Slider/Double.js +52 -203
- package/components/Slider/Handle.js +28 -158
- package/components/Slider/Single.js +29 -177
- package/components/Slider/Slider.js +5 -7
- package/components/Slider/SliderBase.js +39 -48
- package/components/Slider/ThumbBase.js +19 -95
- package/components/Slider/index.js +3 -3
- package/components/Slider/utils.js +2 -2
- package/components/Spinner/Spinner.js +28 -100
- package/components/Spinner/SpinnerSvg.js +9 -78
- package/components/Spinner/index.js +1 -1
- package/components/Switch/Switch.js +49 -220
- package/components/Switch/index.js +1 -1
- package/components/Tabs/TabItem.js +33 -168
- package/components/Tabs/Tabs.js +32 -170
- package/components/Tabs/TabsContext.js +12 -42
- package/components/Tabs/createTabsController.js +33 -168
- package/components/Tabs/index.js +4 -4
- package/components/TextArea/TextArea.js +20 -30
- package/components/TextArea/index.js +1 -1
- package/components/TextField/index.js +3 -3
- package/components/Toast/Toast.js +15 -16
- package/components/Toast/ToastContext.js +4 -8
- package/components/Toast/ToastController.js +44 -101
- package/components/Toast/ToastProvider.js +37 -142
- package/components/Toast/index.js +3 -3
- package/components/Toast/useToast.js +6 -6
- package/components/Typography/Body.js +18 -18
- package/components/Typography/Button.js +13 -13
- package/components/Typography/Caption.js +8 -8
- package/components/Typography/Display.js +18 -18
- package/components/Typography/Footnote.js +13 -13
- package/components/Typography/Headline.js +43 -43
- package/components/Typography/Paragraph.js +24 -24
- package/components/Typography/Underline.js +8 -8
- package/es/__helpers/IconPlaceholder.js +5 -8
- package/es/collectPackageInfo.js +3 -3
- package/es/components/Badge/Badge.js +27 -100
- package/es/components/Basebox/Basebox.js +28 -37
- package/es/components/Button/Button.js +24 -63
- package/es/components/Button/Button.mixins.js +19 -73
- package/es/components/Button/Button.props.js +3 -3
- package/es/components/Button/createButton.js +12 -143
- package/es/components/Card/Card.js +29 -157
- package/es/components/Card/CardBody.js +2 -2
- package/es/components/Card/CardContent.js +12 -21
- package/es/components/Card/CardMedia.js +17 -88
- package/es/components/Card/CardPrice.js +13 -55
- package/es/components/Card/CardTypography.js +43 -52
- package/es/components/Carousel/Carousel.js +45 -63
- package/es/components/Carousel/CarouselItem.js +18 -90
- package/es/components/Carousel/hooks.js +58 -117
- package/es/components/Carousel/utils.js +58 -72
- package/es/components/Fade/Fade.js +5 -8
- package/es/components/Field/Field.js +44 -59
- package/es/components/Field/Field.statuses.js +4 -4
- package/es/components/Image/Image.js +31 -112
- package/es/components/Input/Input.js +4 -4
- package/es/components/Input/Input.mixins.js +6 -9
- package/es/components/ModalBase/ModalBase.js +16 -94
- package/es/components/ModalBase/ModalBaseContext.js +6 -9
- package/es/components/ModalBase/ModalOverlay.js +23 -106
- package/es/components/ModalBase/hooks.js +12 -40
- package/es/components/PaginationDots/PaginationDot.js +9 -15
- package/es/components/PaginationDots/PaginationDots.js +3 -6
- package/es/components/PaginationDots/usePaginationDots.js +9 -10
- package/es/components/Popup/Popup.js +48 -201
- package/es/components/PopupBase/PopupBase.js +27 -161
- package/es/components/PopupBase/PopupBaseContext.js +25 -85
- package/es/components/PopupBase/PopupBaseRoot.js +26 -164
- package/es/components/PopupBase/hooks.js +21 -95
- package/es/components/PopupBase/utils.js +31 -77
- package/es/components/Price/Price.js +12 -87
- package/es/components/RadioGroup/RadioGroup.js +5 -126
- package/es/components/SSRProvider/SSRProvider.js +3 -4
- package/es/components/Skeleton/LineSkeleton.js +18 -90
- package/es/components/Skeleton/RectSkeleton.js +16 -89
- package/es/components/Skeleton/Skeleton.js +2 -2
- package/es/components/Skeleton/TextSkeleton.js +7 -51
- package/es/components/Slider/Double.js +49 -200
- package/es/components/Slider/Handle.js +23 -153
- package/es/components/Slider/Single.js +26 -174
- package/es/components/Slider/Slider.js +2 -4
- package/es/components/Slider/SliderBase.js +36 -45
- package/es/components/Slider/ThumbBase.js +16 -92
- package/es/components/Slider/index.js +1 -1
- package/es/components/Slider/utils.js +2 -2
- package/es/components/Spinner/Spinner.js +23 -95
- package/es/components/Spinner/SpinnerSvg.js +8 -77
- package/es/components/Switch/Switch.js +45 -216
- package/es/components/Tabs/TabItem.js +28 -163
- package/es/components/Tabs/Tabs.js +28 -166
- package/es/components/Tabs/TabsContext.js +11 -41
- package/es/components/Tabs/createTabsController.js +28 -163
- package/es/components/TextArea/TextArea.js +18 -28
- package/es/components/Toast/Toast.js +10 -11
- package/es/components/Toast/ToastContext.js +3 -7
- package/es/components/Toast/ToastController.js +38 -95
- package/es/components/Toast/ToastProvider.js +34 -139
- package/es/components/Toast/useToast.js +4 -4
- package/es/components/Typography/Body.js +15 -15
- package/es/components/Typography/Button.js +10 -10
- package/es/components/Typography/Caption.js +5 -5
- package/es/components/Typography/Display.js +15 -15
- package/es/components/Typography/Footnote.js +10 -10
- package/es/components/Typography/Headline.js +40 -40
- package/es/components/Typography/Paragraph.js +21 -21
- package/es/components/Typography/Underline.js +5 -5
- package/es/hocs/withAutoFocus.js +8 -78
- package/es/hocs/withSkeleton.js +5 -10
- package/es/hooks/useDebouncedFunction.js +4 -36
- package/es/hooks/useFocusTrap.js +18 -21
- package/es/hooks/useForkRef.js +3 -3
- package/es/hooks/useIsomorphicLayoutEffect.js +1 -1
- package/es/hooks/useResizeObserver.js +8 -8
- package/es/hooks/useUniqId.js +6 -52
- package/es/mixins/addFocus.js +17 -22
- package/es/mixins/applyDisabled.js +6 -9
- package/es/mixins/applyEllipsis.js +2 -4
- package/es/mixins/applyMaxLines.js +3 -6
- package/es/mixins/applyNoSelect.js +2 -4
- package/es/mixins/applyOutline.js +2 -4
- package/es/mixins/applyRoundness.js +4 -7
- package/es/mixins/applyScrollSnap.js +4 -7
- package/es/mixins/applySkeletonGradient.js +6 -9
- package/es/mixins/applyView.js +2 -5
- package/es/mixins/blur.js +2 -5
- package/es/mixins/shadows.js +1 -1
- package/es/tokens/colors.js +48 -48
- package/es/tokens/typography.js +18 -18
- package/es/utils/__tests__/formatters.test.js +2 -2
- package/es/utils/animatedScrollTo.js +24 -34
- package/es/utils/canUseDOM.js +1 -1
- package/es/utils/extractTextFrom.js +3 -7
- package/es/utils/focusManager.js +40 -47
- package/es/utils/formatCurrency.js +4 -4
- package/es/utils/formatters.js +6 -14
- package/es/utils/react.js +4 -4
- package/es/utils/roundness.js +2 -4
- package/es/utils/scopeTab.js +5 -5
- package/es/utils/setRef.js +1 -1
- package/es/utils/tabbable.js +16 -25
- package/es/utils/toCssSize.js +1 -3
- package/es/utils/transformStyles.js +5 -60
- package/hocs/index.js +2 -2
- package/hocs/withAutoFocus.js +9 -79
- package/hocs/withSkeleton.js +8 -13
- package/hooks/index.js +6 -6
- package/hooks/useDebouncedFunction.js +5 -37
- package/hooks/useFocusTrap.js +22 -25
- package/hooks/useForkRef.js +5 -5
- package/hooks/useIsomorphicLayoutEffect.js +3 -3
- package/hooks/useResizeObserver.js +9 -9
- package/hooks/useUniqId.js +8 -54
- package/mixins/addFocus.js +19 -24
- package/mixins/applyDisabled.js +7 -10
- package/mixins/applyEllipsis.js +3 -5
- package/mixins/applyMaxLines.js +4 -7
- package/mixins/applyNoSelect.js +3 -5
- package/mixins/applyOutline.js +3 -5
- package/mixins/applyRoundness.js +5 -8
- package/mixins/applyScrollSnap.js +5 -8
- package/mixins/applySkeletonGradient.js +8 -11
- package/mixins/applyView.js +3 -6
- package/mixins/blur.js +2 -5
- package/mixins/index.js +11 -11
- package/mixins/shadows.js +1 -1
- package/package.json +13 -18
- package/tokens/colors.js +48 -48
- package/tokens/typography.js +18 -18
- package/utils/__tests__/formatters.test.js +3 -3
- package/utils/animatedScrollTo.js +24 -34
- package/utils/canUseDOM.js +1 -1
- package/utils/extractTextFrom.js +4 -8
- package/utils/focusManager.js +41 -48
- package/utils/formatCurrency.js +4 -4
- package/utils/formatters.js +6 -14
- package/utils/index.js +10 -10
- package/utils/react.js +7 -7
- package/utils/roundness.js +2 -4
- package/utils/scopeTab.js +6 -6
- package/utils/setRef.js +1 -1
- package/utils/tabbable.js +16 -25
- package/utils/toCssSize.js +1 -3
- package/utils/transformStyles.js +5 -60
|
@@ -8,22 +8,9 @@ Object.defineProperty(exports, "Price", {
|
|
|
8
8
|
return Price;
|
|
9
9
|
}
|
|
10
10
|
});
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
function _define_property(obj, key, value) {
|
|
15
|
-
if (key in obj) {
|
|
16
|
-
Object.defineProperty(obj, key, {
|
|
17
|
-
value: value,
|
|
18
|
-
enumerable: true,
|
|
19
|
-
configurable: true,
|
|
20
|
-
writable: true
|
|
21
|
-
});
|
|
22
|
-
} else {
|
|
23
|
-
obj[key] = value;
|
|
24
|
-
}
|
|
25
|
-
return obj;
|
|
26
|
-
}
|
|
11
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
12
|
+
const _styledcomponents = /*#__PURE__*/ _interop_require_wildcard(require("styled-components"));
|
|
13
|
+
const _utils = require("../../utils");
|
|
27
14
|
function _interop_require_default(obj) {
|
|
28
15
|
return obj && obj.__esModule ? obj : {
|
|
29
16
|
default: obj
|
|
@@ -70,84 +57,22 @@ function _interop_require_wildcard(obj, nodeInterop) {
|
|
|
70
57
|
}
|
|
71
58
|
return newObj;
|
|
72
59
|
}
|
|
73
|
-
|
|
74
|
-
for(var i = 1; i < arguments.length; i++){
|
|
75
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
76
|
-
var ownKeys = Object.keys(source);
|
|
77
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
78
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
79
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
80
|
-
}));
|
|
81
|
-
}
|
|
82
|
-
ownKeys.forEach(function(key) {
|
|
83
|
-
_define_property(target, key, source[key]);
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
return target;
|
|
87
|
-
}
|
|
88
|
-
function _object_without_properties(source, excluded) {
|
|
89
|
-
if (source == null) return {};
|
|
90
|
-
var target = {}, sourceKeys, key, i;
|
|
91
|
-
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
92
|
-
sourceKeys = Reflect.ownKeys(source);
|
|
93
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
94
|
-
key = sourceKeys[i];
|
|
95
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
96
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
97
|
-
target[key] = source[key];
|
|
98
|
-
}
|
|
99
|
-
return target;
|
|
100
|
-
}
|
|
101
|
-
target = _object_without_properties_loose(source, excluded);
|
|
102
|
-
if (Object.getOwnPropertySymbols) {
|
|
103
|
-
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
104
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
105
|
-
key = sourceKeys[i];
|
|
106
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
107
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
108
|
-
target[key] = source[key];
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
return target;
|
|
112
|
-
}
|
|
113
|
-
function _object_without_properties_loose(source, excluded) {
|
|
114
|
-
if (source == null) return {};
|
|
115
|
-
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
116
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
117
|
-
key = sourceKeys[i];
|
|
118
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
119
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
120
|
-
target[key] = source[key];
|
|
121
|
-
}
|
|
122
|
-
return target;
|
|
123
|
-
}
|
|
124
|
-
var StyledPrice = _styledcomponents.default.span.withConfig({
|
|
60
|
+
const StyledPrice = _styledcomponents.default.span.withConfig({
|
|
125
61
|
displayName: "Price__StyledPrice",
|
|
126
62
|
componentId: "sc-cf7d3366-0"
|
|
127
63
|
})([
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
],
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
]);
|
|
135
|
-
});
|
|
136
|
-
var StyledPeriodicity = _styledcomponents.default.span.withConfig({
|
|
64
|
+
``,
|
|
65
|
+
`;`
|
|
66
|
+
], ({ $stroke })=>$stroke && (0, _styledcomponents.css)([
|
|
67
|
+
`text-decoration:line-through;`
|
|
68
|
+
]));
|
|
69
|
+
const StyledPeriodicity = _styledcomponents.default.span.withConfig({
|
|
137
70
|
displayName: "Price__StyledPeriodicity",
|
|
138
71
|
componentId: "sc-cf7d3366-1"
|
|
139
72
|
})([
|
|
140
|
-
|
|
73
|
+
`padding-left:0.25rem;`
|
|
141
74
|
]);
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
"minimumFractionDigits",
|
|
147
|
-
"stroke",
|
|
148
|
-
"periodicity"
|
|
149
|
-
]);
|
|
150
|
-
return /*#__PURE__*/ _react.default.createElement(StyledPrice, _object_spread({
|
|
151
|
-
$stroke: stroke
|
|
152
|
-
}, rest), (0, _utils.formatCurrency)(children, currency, minimumFractionDigits), periodicity && /*#__PURE__*/ _react.default.createElement(StyledPeriodicity, null, periodicity));
|
|
153
|
-
};
|
|
75
|
+
const Price = ({ children, currency = 'rub', minimumFractionDigits = 0, stroke = false, periodicity, ...rest })=>/*#__PURE__*/ _react.default.createElement(StyledPrice, {
|
|
76
|
+
$stroke: stroke,
|
|
77
|
+
...rest
|
|
78
|
+
}, (0, _utils.formatCurrency)(children, currency, minimumFractionDigits), periodicity && /*#__PURE__*/ _react.default.createElement(StyledPeriodicity, null, periodicity));
|
|
@@ -8,137 +8,16 @@ Object.defineProperty(exports, "RadioGroup", {
|
|
|
8
8
|
return RadioGroup;
|
|
9
9
|
}
|
|
10
10
|
});
|
|
11
|
-
|
|
12
|
-
function _array_like_to_array(arr, len) {
|
|
13
|
-
if (len == null || len > arr.length) len = arr.length;
|
|
14
|
-
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
15
|
-
return arr2;
|
|
16
|
-
}
|
|
17
|
-
function _array_with_holes(arr) {
|
|
18
|
-
if (Array.isArray(arr)) return arr;
|
|
19
|
-
}
|
|
20
|
-
function _define_property(obj, key, value) {
|
|
21
|
-
if (key in obj) {
|
|
22
|
-
Object.defineProperty(obj, key, {
|
|
23
|
-
value: value,
|
|
24
|
-
enumerable: true,
|
|
25
|
-
configurable: true,
|
|
26
|
-
writable: true
|
|
27
|
-
});
|
|
28
|
-
} else {
|
|
29
|
-
obj[key] = value;
|
|
30
|
-
}
|
|
31
|
-
return obj;
|
|
32
|
-
}
|
|
11
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
33
12
|
function _interop_require_default(obj) {
|
|
34
13
|
return obj && obj.__esModule ? obj : {
|
|
35
14
|
default: obj
|
|
36
15
|
};
|
|
37
16
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
function _iterable_to_array_limit(arr, i) {
|
|
42
|
-
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
43
|
-
if (_i == null) return;
|
|
44
|
-
var _arr = [];
|
|
45
|
-
var _n = true;
|
|
46
|
-
var _d = false;
|
|
47
|
-
var _s, _e;
|
|
48
|
-
try {
|
|
49
|
-
for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
|
|
50
|
-
_arr.push(_s.value);
|
|
51
|
-
if (i && _arr.length === i) break;
|
|
52
|
-
}
|
|
53
|
-
} catch (err) {
|
|
54
|
-
_d = true;
|
|
55
|
-
_e = err;
|
|
56
|
-
} finally{
|
|
57
|
-
try {
|
|
58
|
-
if (!_n && _i["return"] != null) _i["return"]();
|
|
59
|
-
} finally{
|
|
60
|
-
if (_d) throw _e;
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
return _arr;
|
|
64
|
-
}
|
|
65
|
-
function _non_iterable_rest() {
|
|
66
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
67
|
-
}
|
|
68
|
-
function _object_spread(target) {
|
|
69
|
-
for(var i = 1; i < arguments.length; i++){
|
|
70
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
71
|
-
var ownKeys = Object.keys(source);
|
|
72
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
73
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
74
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
75
|
-
}));
|
|
76
|
-
}
|
|
77
|
-
ownKeys.forEach(function(key) {
|
|
78
|
-
_define_property(target, key, source[key]);
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
return target;
|
|
82
|
-
}
|
|
83
|
-
function _object_without_properties(source, excluded) {
|
|
84
|
-
if (source == null) return {};
|
|
85
|
-
var target = {}, sourceKeys, key, i;
|
|
86
|
-
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
87
|
-
sourceKeys = Reflect.ownKeys(source);
|
|
88
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
89
|
-
key = sourceKeys[i];
|
|
90
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
91
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
92
|
-
target[key] = source[key];
|
|
93
|
-
}
|
|
94
|
-
return target;
|
|
95
|
-
}
|
|
96
|
-
target = _object_without_properties_loose(source, excluded);
|
|
97
|
-
if (Object.getOwnPropertySymbols) {
|
|
98
|
-
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
99
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
100
|
-
key = sourceKeys[i];
|
|
101
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
102
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
103
|
-
target[key] = source[key];
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
return target;
|
|
107
|
-
}
|
|
108
|
-
function _object_without_properties_loose(source, excluded) {
|
|
109
|
-
if (source == null) return {};
|
|
110
|
-
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
111
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
112
|
-
key = sourceKeys[i];
|
|
113
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
114
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
115
|
-
target[key] = source[key];
|
|
116
|
-
}
|
|
117
|
-
return target;
|
|
118
|
-
}
|
|
119
|
-
function _sliced_to_array(arr, i) {
|
|
120
|
-
return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
|
|
121
|
-
}
|
|
122
|
-
function _to_array(arr) {
|
|
123
|
-
return _array_with_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_rest();
|
|
124
|
-
}
|
|
125
|
-
function _unsupported_iterable_to_array(o, minLen) {
|
|
126
|
-
if (!o) return;
|
|
127
|
-
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
128
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
129
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
130
|
-
if (n === "Map" || n === "Set") return Array.from(n);
|
|
131
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
132
|
-
}
|
|
133
|
-
var RadioGroup = /*#__PURE__*/ _react.default.forwardRef(function(_0, _1) {
|
|
134
|
-
var _ref = [
|
|
135
|
-
_0,
|
|
136
|
-
_1
|
|
137
|
-
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), children = _ref2.children, rest = _object_without_properties(_ref2, [
|
|
138
|
-
"children"
|
|
139
|
-
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
140
|
-
return /*#__PURE__*/ _react.default.createElement("div", _object_spread({
|
|
17
|
+
const RadioGroup = /*#__PURE__*/ _react.default.forwardRef(({ children, ...rest }, ref)=>{
|
|
18
|
+
return /*#__PURE__*/ _react.default.createElement("div", {
|
|
141
19
|
role: "radiogroup",
|
|
142
|
-
ref: ref
|
|
143
|
-
|
|
20
|
+
ref: ref,
|
|
21
|
+
...rest
|
|
22
|
+
}, children);
|
|
144
23
|
});
|
|
@@ -16,7 +16,7 @@ _export(exports, {
|
|
|
16
16
|
return SSRProvider;
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
|
-
|
|
19
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
20
20
|
function _getRequireWildcardCache(nodeInterop) {
|
|
21
21
|
if (typeof WeakMap !== "function") return null;
|
|
22
22
|
var cacheBabelInterop = new WeakMap();
|
|
@@ -58,12 +58,11 @@ function _interop_require_wildcard(obj, nodeInterop) {
|
|
|
58
58
|
}
|
|
59
59
|
return newObj;
|
|
60
60
|
}
|
|
61
|
-
|
|
61
|
+
const SSRContext = /*#__PURE__*/ (0, _react.createContext)({
|
|
62
62
|
uniqId: null
|
|
63
63
|
});
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
var value = {
|
|
64
|
+
const SSRProvider = ({ children })=>{
|
|
65
|
+
const value = {
|
|
67
66
|
uniqId: 0
|
|
68
67
|
};
|
|
69
68
|
return /*#__PURE__*/ _react.default.createElement(SSRContext.Provider, {
|
|
@@ -8,24 +8,11 @@ Object.defineProperty(exports, "LineSkeleton", {
|
|
|
8
8
|
return LineSkeleton;
|
|
9
9
|
}
|
|
10
10
|
});
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
function _define_property(obj, key, value) {
|
|
17
|
-
if (key in obj) {
|
|
18
|
-
Object.defineProperty(obj, key, {
|
|
19
|
-
value: value,
|
|
20
|
-
enumerable: true,
|
|
21
|
-
configurable: true,
|
|
22
|
-
writable: true
|
|
23
|
-
});
|
|
24
|
-
} else {
|
|
25
|
-
obj[key] = value;
|
|
26
|
-
}
|
|
27
|
-
return obj;
|
|
28
|
-
}
|
|
11
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
12
|
+
const _styledcomponents = /*#__PURE__*/ _interop_require_wildcard(require("styled-components"));
|
|
13
|
+
const _mixins = require("../../mixins");
|
|
14
|
+
const _typography = /*#__PURE__*/ _interop_require_wildcard(require("../../tokens/typography"));
|
|
15
|
+
const _Skeleton = require("./Skeleton");
|
|
29
16
|
function _interop_require_default(obj) {
|
|
30
17
|
return obj && obj.__esModule ? obj : {
|
|
31
18
|
default: obj
|
|
@@ -72,88 +59,29 @@ function _interop_require_wildcard(obj, nodeInterop) {
|
|
|
72
59
|
}
|
|
73
60
|
return newObj;
|
|
74
61
|
}
|
|
75
|
-
|
|
76
|
-
for(var i = 1; i < arguments.length; i++){
|
|
77
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
78
|
-
var ownKeys = Object.keys(source);
|
|
79
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
80
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
81
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
82
|
-
}));
|
|
83
|
-
}
|
|
84
|
-
ownKeys.forEach(function(key) {
|
|
85
|
-
_define_property(target, key, source[key]);
|
|
86
|
-
});
|
|
87
|
-
}
|
|
88
|
-
return target;
|
|
89
|
-
}
|
|
90
|
-
function _object_without_properties(source, excluded) {
|
|
91
|
-
if (source == null) return {};
|
|
92
|
-
var target = {}, sourceKeys, key, i;
|
|
93
|
-
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
94
|
-
sourceKeys = Reflect.ownKeys(source);
|
|
95
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
96
|
-
key = sourceKeys[i];
|
|
97
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
98
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
99
|
-
target[key] = source[key];
|
|
100
|
-
}
|
|
101
|
-
return target;
|
|
102
|
-
}
|
|
103
|
-
target = _object_without_properties_loose(source, excluded);
|
|
104
|
-
if (Object.getOwnPropertySymbols) {
|
|
105
|
-
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
106
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
107
|
-
key = sourceKeys[i];
|
|
108
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
109
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
110
|
-
target[key] = source[key];
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
return target;
|
|
114
|
-
}
|
|
115
|
-
function _object_without_properties_loose(source, excluded) {
|
|
116
|
-
if (source == null) return {};
|
|
117
|
-
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
118
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
119
|
-
key = sourceKeys[i];
|
|
120
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
121
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
122
|
-
target[key] = source[key];
|
|
123
|
-
}
|
|
124
|
-
return target;
|
|
125
|
-
}
|
|
126
|
-
var StyledVisibleLine = _styledcomponents.default.div.withConfig({
|
|
62
|
+
const StyledVisibleLine = _styledcomponents.default.div.withConfig({
|
|
127
63
|
displayName: "LineSkeleton__StyledVisibleLine",
|
|
128
64
|
componentId: "sc-fa3b5b49-0"
|
|
129
65
|
})([
|
|
130
|
-
|
|
66
|
+
`position:relative;overflow:hidden;width:100%;`
|
|
131
67
|
]);
|
|
132
|
-
|
|
68
|
+
const StyledLine = _styledcomponents.default.div.withConfig({
|
|
133
69
|
displayName: "LineSkeleton__StyledLine",
|
|
134
70
|
componentId: "sc-fa3b5b49-1"
|
|
135
71
|
})([
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
],
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
], _typography[$size].lineHeight, StyledVisibleLine, _typography[$size].fontSize);
|
|
149
|
-
}, StyledVisibleLine, _mixins.applyRoundness, _mixins.applySkeletonGradient);
|
|
150
|
-
var LineSkeleton = function LineSkeleton(_0) {
|
|
151
|
-
var _0_size = _0.size, size = _0_size === void 0 ? _Skeleton.DEFAULT_TEXT_SIZE : _0_size, _0_roundness = _0.roundness, roundness = _0_roundness === void 0 ? _Skeleton.DEFAULT_ROUNDNESS : _0_roundness, rest = _object_without_properties(_0, [
|
|
152
|
-
"size",
|
|
153
|
-
"roundness"
|
|
154
|
-
]);
|
|
155
|
-
return /*#__PURE__*/ _react.default.createElement(StyledLine, _object_spread({
|
|
72
|
+
`display:flex;align-items:center;width:100%;`,
|
|
73
|
+
` & `,
|
|
74
|
+
`{`,
|
|
75
|
+
` `,
|
|
76
|
+
`}`
|
|
77
|
+
], ({ $size })=>(0, _styledcomponents.css)([
|
|
78
|
+
`height:`,
|
|
79
|
+
`;& `,
|
|
80
|
+
`{height:`,
|
|
81
|
+
`;}`
|
|
82
|
+
], _typography[$size].lineHeight, StyledVisibleLine, _typography[$size].fontSize), StyledVisibleLine, _mixins.applyRoundness, _mixins.applySkeletonGradient);
|
|
83
|
+
const LineSkeleton = ({ size = _Skeleton.DEFAULT_TEXT_SIZE, roundness = _Skeleton.DEFAULT_ROUNDNESS, ...rest })=>/*#__PURE__*/ _react.default.createElement(StyledLine, {
|
|
156
84
|
$size: size,
|
|
157
|
-
roundness: roundness
|
|
158
|
-
|
|
159
|
-
};
|
|
85
|
+
roundness: roundness,
|
|
86
|
+
...rest
|
|
87
|
+
}, /*#__PURE__*/ _react.default.createElement(StyledVisibleLine, null));
|
|
@@ -8,23 +8,10 @@ Object.defineProperty(exports, "RectSkeleton", {
|
|
|
8
8
|
return RectSkeleton;
|
|
9
9
|
}
|
|
10
10
|
});
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
function _define_property(obj, key, value) {
|
|
16
|
-
if (key in obj) {
|
|
17
|
-
Object.defineProperty(obj, key, {
|
|
18
|
-
value: value,
|
|
19
|
-
enumerable: true,
|
|
20
|
-
configurable: true,
|
|
21
|
-
writable: true
|
|
22
|
-
});
|
|
23
|
-
} else {
|
|
24
|
-
obj[key] = value;
|
|
25
|
-
}
|
|
26
|
-
return obj;
|
|
27
|
-
}
|
|
11
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
12
|
+
const _styledcomponents = /*#__PURE__*/ _interop_require_wildcard(require("styled-components"));
|
|
13
|
+
const _mixins = require("../../mixins");
|
|
14
|
+
const _Skeleton = require("./Skeleton");
|
|
28
15
|
function _interop_require_default(obj) {
|
|
29
16
|
return obj && obj.__esModule ? obj : {
|
|
30
17
|
default: obj
|
|
@@ -71,82 +58,22 @@ function _interop_require_wildcard(obj, nodeInterop) {
|
|
|
71
58
|
}
|
|
72
59
|
return newObj;
|
|
73
60
|
}
|
|
74
|
-
|
|
75
|
-
for(var i = 1; i < arguments.length; i++){
|
|
76
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
77
|
-
var ownKeys = Object.keys(source);
|
|
78
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
79
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
80
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
81
|
-
}));
|
|
82
|
-
}
|
|
83
|
-
ownKeys.forEach(function(key) {
|
|
84
|
-
_define_property(target, key, source[key]);
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
return target;
|
|
88
|
-
}
|
|
89
|
-
function _object_without_properties(source, excluded) {
|
|
90
|
-
if (source == null) return {};
|
|
91
|
-
var target = {}, sourceKeys, key, i;
|
|
92
|
-
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
93
|
-
sourceKeys = Reflect.ownKeys(source);
|
|
94
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
95
|
-
key = sourceKeys[i];
|
|
96
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
97
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
98
|
-
target[key] = source[key];
|
|
99
|
-
}
|
|
100
|
-
return target;
|
|
101
|
-
}
|
|
102
|
-
target = _object_without_properties_loose(source, excluded);
|
|
103
|
-
if (Object.getOwnPropertySymbols) {
|
|
104
|
-
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
105
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
106
|
-
key = sourceKeys[i];
|
|
107
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
108
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
109
|
-
target[key] = source[key];
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
return target;
|
|
113
|
-
}
|
|
114
|
-
function _object_without_properties_loose(source, excluded) {
|
|
115
|
-
if (source == null) return {};
|
|
116
|
-
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
117
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
118
|
-
key = sourceKeys[i];
|
|
119
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
120
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
121
|
-
target[key] = source[key];
|
|
122
|
-
}
|
|
123
|
-
return target;
|
|
124
|
-
}
|
|
125
|
-
var StyledRectSkeleton = _styledcomponents.default.div.withConfig({
|
|
61
|
+
const StyledRectSkeleton = _styledcomponents.default.div.withConfig({
|
|
126
62
|
displayName: "RectSkeleton__StyledRectSkeleton",
|
|
127
63
|
componentId: "sc-b64b4dbc-0"
|
|
128
64
|
})([
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
], _mixins.applyRoundness, _mixins.applySkeletonGradient,
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
"height",
|
|
145
|
-
"roundness"
|
|
146
|
-
]);
|
|
147
|
-
return /*#__PURE__*/ _react.default.createElement(StyledRectSkeleton, _object_spread({
|
|
148
|
-
$width: typeof width === 'string' ? width : "".concat(width, "px"),
|
|
149
|
-
$height: typeof height === 'string' ? height : "".concat(height, "px"),
|
|
150
|
-
roundness: roundness
|
|
151
|
-
}, rest));
|
|
152
|
-
};
|
|
65
|
+
``,
|
|
66
|
+
`;`,
|
|
67
|
+
`;position:relative;overflow:hidden;`,
|
|
68
|
+
``
|
|
69
|
+
], _mixins.applyRoundness, _mixins.applySkeletonGradient, ({ $width, $height })=>(0, _styledcomponents.css)([
|
|
70
|
+
`width:`,
|
|
71
|
+
`;height:`,
|
|
72
|
+
`;`
|
|
73
|
+
], $width, $height));
|
|
74
|
+
const RectSkeleton = ({ width, height, roundness = _Skeleton.DEFAULT_ROUNDNESS, ...rest })=>/*#__PURE__*/ _react.default.createElement(StyledRectSkeleton, {
|
|
75
|
+
$width: typeof width === 'string' ? width : `${width}px`,
|
|
76
|
+
$height: typeof height === 'string' ? height : `${height}px`,
|
|
77
|
+
roundness: roundness,
|
|
78
|
+
...rest
|
|
79
|
+
});
|