@itcase/ui 1.8.58 → 1.8.60
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/{Avatar_cjs_CxyEa4gB.js → Avatar_cjs_-cKfA1OW.js} +28 -3
- package/dist/{Avatar_es_DQTyqtKx.js → Avatar_es_CSKFNChm.js} +28 -3
- package/dist/{DropdownItem_cjs_BtL83PeZ.js → DropdownItem_cjs_DdjN_gRH.js} +3 -3
- package/dist/{DropdownItem_es_BK2bacxA.js → DropdownItem_es_DfEoMbef.js} +3 -3
- package/dist/cjs/components/Avatar.js +1 -1
- package/dist/cjs/components/AvatarStack.js +1 -1
- package/dist/cjs/components/Dropdown.js +1 -1
- package/dist/cjs/components/Logo.js +3 -3
- package/dist/cjs/components/MenuItem.js +1 -0
- package/dist/cjs/components/Pagination.js +1 -1
- package/dist/cjs/components/Response.js +8 -16
- package/dist/components/Avatar.js +1 -1
- package/dist/components/AvatarStack.js +1 -1
- package/dist/components/Dropdown.js +1 -1
- package/dist/components/Logo.js +3 -3
- package/dist/components/MenuItem.js +1 -0
- package/dist/components/Pagination.js +1 -1
- package/dist/components/Response.js +8 -16
- package/dist/css/components/Avatar/Avatar.css +0 -22
- package/dist/css/components/Swiper/Swiper.css +3 -1
- package/dist/css/styles/align/align_horizontal-reverse.css +20 -5
- package/dist/css/styles/align/align_horizontal.css +24 -8
- package/dist/css/styles/align/align_vertical-reverse.css +19 -7
- package/dist/css/styles/align/align_vertical.css +22 -7
- package/dist/stories/Overview.mdx +1 -1
- package/dist/stories/Playground.mdx +1 -1
- package/dist/types/components/Avatar/appearance/avatarShape.d.ts +25 -0
- package/dist/types/components/MenuItem/appearance/menuItemSurface.d.ts +1 -0
- package/package.json +4 -4
|
@@ -30,6 +30,31 @@ var avatarAppearanceDefault = {
|
|
|
30
30
|
},
|
|
31
31
|
};
|
|
32
32
|
|
|
33
|
+
var avatarAppearanceShape = {
|
|
34
|
+
circular: {
|
|
35
|
+
shape: 'circular',
|
|
36
|
+
},
|
|
37
|
+
rounded: {
|
|
38
|
+
shape: 'rounded',
|
|
39
|
+
},
|
|
40
|
+
roundedL: {
|
|
41
|
+
shape: 'rounded',
|
|
42
|
+
shapeStrength: '1_5m',
|
|
43
|
+
},
|
|
44
|
+
roundedM: {
|
|
45
|
+
shape: 'rounded',
|
|
46
|
+
shapeStrength: '1m',
|
|
47
|
+
},
|
|
48
|
+
roundedS: {
|
|
49
|
+
shape: 'rounded',
|
|
50
|
+
shapeStrength: '0_5m',
|
|
51
|
+
},
|
|
52
|
+
roundedXL: {
|
|
53
|
+
shape: 'rounded',
|
|
54
|
+
shapeStrength: '2m',
|
|
55
|
+
},
|
|
56
|
+
};
|
|
57
|
+
|
|
33
58
|
var avatarAppearanceSize = {
|
|
34
59
|
size16: {
|
|
35
60
|
size: '16',
|
|
@@ -130,7 +155,7 @@ var avatarAppearanceStyle = {
|
|
|
130
155
|
},
|
|
131
156
|
};
|
|
132
157
|
|
|
133
|
-
var avatarAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({}, avatarAppearanceSize), avatarAppearanceStyle), avatarAppearanceDefault);
|
|
158
|
+
var avatarAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({}, avatarAppearanceSize), avatarAppearanceStyle), avatarAppearanceShape), avatarAppearanceDefault);
|
|
134
159
|
|
|
135
160
|
var avatarConfig = {
|
|
136
161
|
appearance: avatarAppearance,
|
|
@@ -147,8 +172,8 @@ function Avatar(props) {
|
|
|
147
172
|
}, [firstName, secondName]);
|
|
148
173
|
var appearanceConfig = useAppearanceConfig.useAppearanceConfig(appearance, avatarConfig);
|
|
149
174
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
150
|
-
var size = propsGenerator.size, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, textColor = propsGenerator.textColor, textSize = propsGenerator.textSize, textWeight = propsGenerator.textWeight, badge = propsGenerator.badge, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillHover = propsGenerator.iconFillHover, iconFillSize = propsGenerator.iconFillSize, iconItemFill = propsGenerator.iconItemFill, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, placeholderUrl = propsGenerator.placeholderUrl, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass;
|
|
151
|
-
return (jsxRuntime.jsx("div", { className: clsx(className, 'avatar',
|
|
175
|
+
var size = propsGenerator.size, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, textColor = propsGenerator.textColor, textSize = propsGenerator.textSize, textWeight = propsGenerator.textWeight, badge = propsGenerator.badge, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillHover = propsGenerator.iconFillHover, iconFillSize = propsGenerator.iconFillSize, iconItemFill = propsGenerator.iconItemFill, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, placeholderUrl = propsGenerator.placeholderUrl, shapeClass = propsGenerator.shapeClass, shapeStrengthClass = propsGenerator.shapeStrengthClass, sizeClass = propsGenerator.sizeClass;
|
|
176
|
+
return (jsxRuntime.jsx("div", { className: clsx(className, 'avatar', size && "avatar_size_".concat(sizeClass), type && "avatar_type_".concat(type), (badgeValue || badgeAppearance || badgeSize) && 'avatar_status', isSkeleton && "avatar_skeleton", onClick && 'cursor_type_pointer'), onClick: onClick, children: jsxRuntime.jsxs("div", { className: clsx('avatar__wrapper', shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)), children: [before, src ? (jsxRuntime.jsx(Image.Image, { className: clsx('avatar__image', shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass)), src: src, placeholderUrl: placeholderUrl })) : (jsxRuntime.jsx(Text.Text, { className: "avatar__text", size: textSize, textColor: textColor, textWeight: textWeight, children: avatarChars || count })), (icon || iconSrc) && (jsxRuntime.jsx(Icon.Icon, { className: "avatar__icon", fill: iconFill, fillHover: iconFillHover, fillSize: iconFillSize, iconFill: iconItemFill, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon })), (badge || badgeValue) && (jsxRuntime.jsx(Icon.Badge, { className: "avatar__badge", appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), after] }) }));
|
|
152
177
|
}
|
|
153
178
|
|
|
154
179
|
exports.Avatar = Avatar;
|
|
@@ -28,6 +28,31 @@ var avatarAppearanceDefault = {
|
|
|
28
28
|
},
|
|
29
29
|
};
|
|
30
30
|
|
|
31
|
+
var avatarAppearanceShape = {
|
|
32
|
+
circular: {
|
|
33
|
+
shape: 'circular',
|
|
34
|
+
},
|
|
35
|
+
rounded: {
|
|
36
|
+
shape: 'rounded',
|
|
37
|
+
},
|
|
38
|
+
roundedL: {
|
|
39
|
+
shape: 'rounded',
|
|
40
|
+
shapeStrength: '1_5m',
|
|
41
|
+
},
|
|
42
|
+
roundedM: {
|
|
43
|
+
shape: 'rounded',
|
|
44
|
+
shapeStrength: '1m',
|
|
45
|
+
},
|
|
46
|
+
roundedS: {
|
|
47
|
+
shape: 'rounded',
|
|
48
|
+
shapeStrength: '0_5m',
|
|
49
|
+
},
|
|
50
|
+
roundedXL: {
|
|
51
|
+
shape: 'rounded',
|
|
52
|
+
shapeStrength: '2m',
|
|
53
|
+
},
|
|
54
|
+
};
|
|
55
|
+
|
|
31
56
|
var avatarAppearanceSize = {
|
|
32
57
|
size16: {
|
|
33
58
|
size: '16',
|
|
@@ -128,7 +153,7 @@ var avatarAppearanceStyle = {
|
|
|
128
153
|
},
|
|
129
154
|
};
|
|
130
155
|
|
|
131
|
-
var avatarAppearance = __assign(__assign(__assign({}, avatarAppearanceSize), avatarAppearanceStyle), avatarAppearanceDefault);
|
|
156
|
+
var avatarAppearance = __assign(__assign(__assign(__assign({}, avatarAppearanceSize), avatarAppearanceStyle), avatarAppearanceShape), avatarAppearanceDefault);
|
|
132
157
|
|
|
133
158
|
var avatarConfig = {
|
|
134
159
|
appearance: avatarAppearance,
|
|
@@ -145,8 +170,8 @@ function Avatar(props) {
|
|
|
145
170
|
}, [firstName, secondName]);
|
|
146
171
|
var appearanceConfig = useAppearanceConfig(appearance, avatarConfig);
|
|
147
172
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
148
|
-
var size = propsGenerator.size, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, textColor = propsGenerator.textColor, textSize = propsGenerator.textSize, textWeight = propsGenerator.textWeight, badge = propsGenerator.badge, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillHover = propsGenerator.iconFillHover, iconFillSize = propsGenerator.iconFillSize, iconItemFill = propsGenerator.iconItemFill, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, placeholderUrl = propsGenerator.placeholderUrl, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass;
|
|
149
|
-
return (jsx("div", { className: clsx(className, 'avatar',
|
|
173
|
+
var size = propsGenerator.size, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, textColor = propsGenerator.textColor, textSize = propsGenerator.textSize, textWeight = propsGenerator.textWeight, badge = propsGenerator.badge, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillHover = propsGenerator.iconFillHover, iconFillSize = propsGenerator.iconFillSize, iconItemFill = propsGenerator.iconItemFill, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, placeholderUrl = propsGenerator.placeholderUrl, shapeClass = propsGenerator.shapeClass, shapeStrengthClass = propsGenerator.shapeStrengthClass, sizeClass = propsGenerator.sizeClass;
|
|
174
|
+
return (jsx("div", { className: clsx(className, 'avatar', size && "avatar_size_".concat(sizeClass), type && "avatar_type_".concat(type), (badgeValue || badgeAppearance || badgeSize) && 'avatar_status', isSkeleton && "avatar_skeleton", onClick && 'cursor_type_pointer'), onClick: onClick, children: jsxs("div", { className: clsx('avatar__wrapper', shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)), children: [before, src ? (jsx(Image, { className: clsx('avatar__image', shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass)), src: src, placeholderUrl: placeholderUrl })) : (jsx(Text, { className: "avatar__text", size: textSize, textColor: textColor, textWeight: textWeight, children: avatarChars || count })), (icon || iconSrc) && (jsx(Icon, { className: "avatar__icon", fill: iconFill, fillHover: iconFillHover, fillSize: iconFillSize, iconFill: iconItemFill, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon })), (badge || badgeValue) && (jsx(Badge, { className: "avatar__badge", appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), after] }) }));
|
|
150
175
|
}
|
|
151
176
|
|
|
152
177
|
export { Avatar as A, avatarConfig as a, avatarAppearance as b };
|
|
@@ -150,7 +150,7 @@ var dropdownAppearanceSurface = {
|
|
|
150
150
|
surfacePrimary: {
|
|
151
151
|
fill: 'surfacePrimary',
|
|
152
152
|
fillActive: 'surfacePrimaryActive',
|
|
153
|
-
fillHover: '
|
|
153
|
+
fillHover: 'surfaceHoverPrimary',
|
|
154
154
|
labelTextColor: 'surfaceTextPrimary',
|
|
155
155
|
labelTextColorActive: 'surfaceTextPrimary',
|
|
156
156
|
labelTextColorActiveHover: 'surfaceTextPrimary',
|
|
@@ -189,7 +189,7 @@ var dropdownItemConfig = {
|
|
|
189
189
|
},
|
|
190
190
|
};
|
|
191
191
|
function DropdownItem(props) {
|
|
192
|
-
var className = props.className, appearance = props.appearance, label = props.label, desc = props.desc, isDisabled = props.isDisabled, badgeValue = props.badgeValue, emptyMessage = props.emptyMessage, showDivider = props.showDivider, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, isSkeleton = props.isSkeleton,
|
|
192
|
+
var className = props.className, appearance = props.appearance, label = props.label, desc = props.desc, isDisabled = props.isDisabled, badgeValue = props.badgeValue, emptyMessage = props.emptyMessage, showDivider = props.showDivider, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, isSkeleton = props.isSkeleton, onClick = props.onClick, onMouseEnter = props.onMouseEnter, children = props.children;
|
|
193
193
|
var appearanceConfig = useAppearanceConfig.useAppearanceConfig(appearance, dropdownItemConfig);
|
|
194
194
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
195
195
|
var directionClass = propsGenerator.directionClass, justifyContentClass = propsGenerator.justifyContentClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillDisabledClass = propsGenerator.fillDisabledClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextAlign = propsGenerator.labelTextAlign, labelTextColor = propsGenerator.labelTextColor, labelTextColorActive = propsGenerator.labelTextColorActive, labelTextColorActiveHover = propsGenerator.labelTextColorActiveHover, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextStyle = propsGenerator.labelTextStyle, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, descTextColor = propsGenerator.descTextColor, descTextColorHover = propsGenerator.descTextColorHover, descTextGradient = propsGenerator.descTextGradient, descTextSize = propsGenerator.descTextSize, descTextStyle = propsGenerator.descTextStyle, descTextWeight = propsGenerator.descTextWeight, descTextWrap = propsGenerator.descTextWrap, badgeAppearance = propsGenerator.badgeAppearance, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, dividerDirection = propsGenerator.dividerDirection, dividerFill = propsGenerator.dividerFill, dividerSize = propsGenerator.dividerSize, emptyMessageTextColor = propsGenerator.emptyMessageTextColor, emptyMessageTextColorHover = propsGenerator.emptyMessageTextColorHover, emptyMessageTextSize = propsGenerator.emptyMessageTextSize, emptyMessageTextStyle = propsGenerator.emptyMessageTextStyle, emptyMessageTextWeight = propsGenerator.emptyMessageTextWeight, emptyMessageTextWrap = propsGenerator.emptyMessageTextWrap, iconAfter = propsGenerator.iconAfter, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterFillSize = propsGenerator.iconAfterFillSize, iconAfterShape = propsGenerator.iconAfterShape, iconAfterSize = propsGenerator.iconAfterSize, iconAfterSrc = propsGenerator.iconAfterSrc, iconBadgeAppearance = propsGenerator.iconBadgeAppearance, iconBadgeShape = propsGenerator.iconBadgeShape, iconBadgeSize = propsGenerator.iconBadgeSize, iconBadgeTextColor = propsGenerator.iconBadgeTextColor, iconBadgeTextSize = propsGenerator.iconBadgeTextSize, iconBadgeValue = propsGenerator.iconBadgeValue, iconBefore = propsGenerator.iconBefore, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeFillSize = propsGenerator.iconBeforeFillSize, iconBeforeShape = propsGenerator.iconBeforeShape, iconBeforeSize = propsGenerator.iconBeforeSize, iconBeforeSrc = propsGenerator.iconBeforeSrc, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
@@ -199,7 +199,7 @@ function DropdownItem(props) {
|
|
|
199
199
|
? fillClass && "fill_".concat(fillClass)
|
|
200
200
|
: fillActiveClass && "fill_active_".concat(fillActiveClass), !isActive
|
|
201
201
|
? fillHoverClass && "fill_hover_".concat(fillHoverClass)
|
|
202
|
-
: fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), widthClass && "dropdown__item_width_".concat(widthClass), isDisabled && "dropdown__item_state_disabled", onClick && 'cursor_type_pointer',
|
|
202
|
+
: fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), widthClass && "dropdown__item_width_".concat(widthClass), isDisabled && "dropdown__item_state_disabled", onClick && 'cursor_type_pointer', isSkeleton && "dropdown__item_skeleton", justifyContentClass &&
|
|
203
203
|
"dropdown__item_justify-content_".concat(justifyContentClass)), style: dropdownItem, onClick: onClick, onMouseEnter: onMouseEnter, children: [jsxRuntime.jsx("div", { className: "dropdown__item-wrapper", children: jsxRuntime.jsxs(React.Fragment, { children: [before, (iconBefore || iconBeforeSrc) && (jsxRuntime.jsx(Icon.Icon, { className: clsx('dropdown__item_before', iconBadgeValue && 'dropdown__item_before-badge'), fill: iconBeforeFill, fillSize: iconBeforeFillSize, badgeAppearance: iconBadgeAppearance, badgeClass: 'dropdown__item_before_badge', badgeShape: iconBadgeShape, badgeSize: iconBadgeSize, badgeTextColor: iconBadgeTextColor, badgeTextSize: iconBadgeTextSize, badgeValue: iconBadgeValue, iconFill: iconBeforeFillIcon, iconSize: iconBeforeSize, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), children || (jsxRuntime.jsxs(React.Fragment, { children: [label && (jsxRuntime.jsx(Text.Text, { className: "dropdown__item-label", size: labelTextSize, textAlign: labelTextAlign, textColor: !isActive && labelTextColor, textColorActive: "accentTextPrimary", textColorActive: isActive && labelTextColorActive, textColorHover: !isActive && labelTextColorHover, textColorHoverActive: isActive && labelTextColorActiveHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, isActive: isActive, children: label })), badgeValue && (jsxRuntime.jsx(Icon.Badge, { appearance: badgeAppearance, size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), desc && (jsxRuntime.jsx(Text.Text, { className: "dropdown__item-desc", size: descTextSize, textColor: descTextColor, textColorGradient: descTextGradient, textColorHover: descTextColorHover, textStyle: descTextStyle, textWeight: descTextWeight, textWrap: descTextWrap, isActive: isActive, children: desc })), emptyMessage && (jsxRuntime.jsx(Text.Text, { className: "dropdown__item", size: emptyMessageTextSize, textColor: emptyMessageTextColor, textColorHover: emptyMessageTextColorHover, textStyle: emptyMessageTextStyle, textWeight: emptyMessageTextWeight, textWrap: emptyMessageTextWrap, isActive: isActive, children: emptyMessage }))] })), after, (iconAfter || iconAfterSrc) && (jsxRuntime.jsx(Icon.Icon, { className: clsx('dropdown__item_after', iconBadgeValue && 'dropdown__item_after-badge'), fill: iconAfterFill, fillSize: iconAfterFillSize, badgeAppearance: iconBadgeAppearance, badgeClass: 'dropdown__item_after_badge', badgeShape: iconBadgeShape, badgeSize: iconBadgeSize, badgeTextColor: iconBadgeTextColor, badgeTextSize: iconBadgeTextSize, badgeValue: iconBadgeValue, iconFill: iconAfterFillIcon, iconSize: iconAfterSize, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter }))] }) }), showDivider && (jsxRuntime.jsx(Divider.Divider, { width: "fill", direction: dividerDirection, size: dividerSize, fill: dividerFill }))] }));
|
|
204
204
|
}
|
|
205
205
|
|
|
@@ -148,7 +148,7 @@ var dropdownAppearanceSurface = {
|
|
|
148
148
|
surfacePrimary: {
|
|
149
149
|
fill: 'surfacePrimary',
|
|
150
150
|
fillActive: 'surfacePrimaryActive',
|
|
151
|
-
fillHover: '
|
|
151
|
+
fillHover: 'surfaceHoverPrimary',
|
|
152
152
|
labelTextColor: 'surfaceTextPrimary',
|
|
153
153
|
labelTextColorActive: 'surfaceTextPrimary',
|
|
154
154
|
labelTextColorActiveHover: 'surfaceTextPrimary',
|
|
@@ -187,7 +187,7 @@ var dropdownItemConfig = {
|
|
|
187
187
|
},
|
|
188
188
|
};
|
|
189
189
|
function DropdownItem(props) {
|
|
190
|
-
var className = props.className, appearance = props.appearance, label = props.label, desc = props.desc, isDisabled = props.isDisabled, badgeValue = props.badgeValue, emptyMessage = props.emptyMessage, showDivider = props.showDivider, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, isSkeleton = props.isSkeleton,
|
|
190
|
+
var className = props.className, appearance = props.appearance, label = props.label, desc = props.desc, isDisabled = props.isDisabled, badgeValue = props.badgeValue, emptyMessage = props.emptyMessage, showDivider = props.showDivider, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, isSkeleton = props.isSkeleton, onClick = props.onClick, onMouseEnter = props.onMouseEnter, children = props.children;
|
|
191
191
|
var appearanceConfig = useAppearanceConfig(appearance, dropdownItemConfig);
|
|
192
192
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
193
193
|
var directionClass = propsGenerator.directionClass, justifyContentClass = propsGenerator.justifyContentClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillDisabledClass = propsGenerator.fillDisabledClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextAlign = propsGenerator.labelTextAlign, labelTextColor = propsGenerator.labelTextColor, labelTextColorActive = propsGenerator.labelTextColorActive, labelTextColorActiveHover = propsGenerator.labelTextColorActiveHover, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextStyle = propsGenerator.labelTextStyle, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, descTextColor = propsGenerator.descTextColor, descTextColorHover = propsGenerator.descTextColorHover, descTextGradient = propsGenerator.descTextGradient, descTextSize = propsGenerator.descTextSize, descTextStyle = propsGenerator.descTextStyle, descTextWeight = propsGenerator.descTextWeight, descTextWrap = propsGenerator.descTextWrap, badgeAppearance = propsGenerator.badgeAppearance, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, dividerDirection = propsGenerator.dividerDirection, dividerFill = propsGenerator.dividerFill, dividerSize = propsGenerator.dividerSize, emptyMessageTextColor = propsGenerator.emptyMessageTextColor, emptyMessageTextColorHover = propsGenerator.emptyMessageTextColorHover, emptyMessageTextSize = propsGenerator.emptyMessageTextSize, emptyMessageTextStyle = propsGenerator.emptyMessageTextStyle, emptyMessageTextWeight = propsGenerator.emptyMessageTextWeight, emptyMessageTextWrap = propsGenerator.emptyMessageTextWrap, iconAfter = propsGenerator.iconAfter, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterFillSize = propsGenerator.iconAfterFillSize, iconAfterShape = propsGenerator.iconAfterShape, iconAfterSize = propsGenerator.iconAfterSize, iconAfterSrc = propsGenerator.iconAfterSrc, iconBadgeAppearance = propsGenerator.iconBadgeAppearance, iconBadgeShape = propsGenerator.iconBadgeShape, iconBadgeSize = propsGenerator.iconBadgeSize, iconBadgeTextColor = propsGenerator.iconBadgeTextColor, iconBadgeTextSize = propsGenerator.iconBadgeTextSize, iconBadgeValue = propsGenerator.iconBadgeValue, iconBefore = propsGenerator.iconBefore, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeFillSize = propsGenerator.iconBeforeFillSize, iconBeforeShape = propsGenerator.iconBeforeShape, iconBeforeSize = propsGenerator.iconBeforeSize, iconBeforeSrc = propsGenerator.iconBeforeSrc, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
@@ -197,7 +197,7 @@ function DropdownItem(props) {
|
|
|
197
197
|
? fillClass && "fill_".concat(fillClass)
|
|
198
198
|
: fillActiveClass && "fill_active_".concat(fillActiveClass), !isActive
|
|
199
199
|
? fillHoverClass && "fill_hover_".concat(fillHoverClass)
|
|
200
|
-
: fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), widthClass && "dropdown__item_width_".concat(widthClass), isDisabled && "dropdown__item_state_disabled", onClick && 'cursor_type_pointer',
|
|
200
|
+
: fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), widthClass && "dropdown__item_width_".concat(widthClass), isDisabled && "dropdown__item_state_disabled", onClick && 'cursor_type_pointer', isSkeleton && "dropdown__item_skeleton", justifyContentClass &&
|
|
201
201
|
"dropdown__item_justify-content_".concat(justifyContentClass)), style: dropdownItem, onClick: onClick, onMouseEnter: onMouseEnter, children: [jsx("div", { className: "dropdown__item-wrapper", children: jsxs(React.Fragment, { children: [before, (iconBefore || iconBeforeSrc) && (jsx(Icon, { className: clsx('dropdown__item_before', iconBadgeValue && 'dropdown__item_before-badge'), fill: iconBeforeFill, fillSize: iconBeforeFillSize, badgeAppearance: iconBadgeAppearance, badgeClass: 'dropdown__item_before_badge', badgeShape: iconBadgeShape, badgeSize: iconBadgeSize, badgeTextColor: iconBadgeTextColor, badgeTextSize: iconBadgeTextSize, badgeValue: iconBadgeValue, iconFill: iconBeforeFillIcon, iconSize: iconBeforeSize, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), children || (jsxs(React.Fragment, { children: [label && (jsx(Text, { className: "dropdown__item-label", size: labelTextSize, textAlign: labelTextAlign, textColor: !isActive && labelTextColor, textColorActive: "accentTextPrimary", textColorActive: isActive && labelTextColorActive, textColorHover: !isActive && labelTextColorHover, textColorHoverActive: isActive && labelTextColorActiveHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, isActive: isActive, children: label })), badgeValue && (jsx(Badge, { appearance: badgeAppearance, size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), desc && (jsx(Text, { className: "dropdown__item-desc", size: descTextSize, textColor: descTextColor, textColorGradient: descTextGradient, textColorHover: descTextColorHover, textStyle: descTextStyle, textWeight: descTextWeight, textWrap: descTextWrap, isActive: isActive, children: desc })), emptyMessage && (jsx(Text, { className: "dropdown__item", size: emptyMessageTextSize, textColor: emptyMessageTextColor, textColorHover: emptyMessageTextColorHover, textStyle: emptyMessageTextStyle, textWeight: emptyMessageTextWeight, textWrap: emptyMessageTextWrap, isActive: isActive, children: emptyMessage }))] })), after, (iconAfter || iconAfterSrc) && (jsx(Icon, { className: clsx('dropdown__item_after', iconBadgeValue && 'dropdown__item_after-badge'), fill: iconAfterFill, fillSize: iconAfterFillSize, badgeAppearance: iconBadgeAppearance, badgeClass: 'dropdown__item_after_badge', badgeShape: iconBadgeShape, badgeSize: iconBadgeSize, badgeTextColor: iconBadgeTextColor, badgeTextSize: iconBadgeTextSize, badgeValue: iconBadgeValue, iconFill: iconAfterFillIcon, iconSize: iconAfterSize, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter }))] }) }), showDivider && (jsx(Divider, { width: "fill", direction: dividerDirection, size: dividerSize, fill: dividerFill }))] }));
|
|
202
202
|
}
|
|
203
203
|
|
|
@@ -5,7 +5,7 @@ var clsx = require('clsx');
|
|
|
5
5
|
var useAppearanceConfig = require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
6
6
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
7
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
8
|
-
var Avatar = require('../../
|
|
8
|
+
var Avatar = require('../../Avatar_cjs_-cKfA1OW.js');
|
|
9
9
|
var Group = require('../../Group_cjs_DHNBxjH3.js');
|
|
10
10
|
var Text = require('../../Text_cjs_C-Ux7Tz5.js');
|
|
11
11
|
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
@@ -30,12 +30,12 @@ var logoConfig = {
|
|
|
30
30
|
},
|
|
31
31
|
};
|
|
32
32
|
var Logo = urlWithAssetPrefix.urlWithAssetPrefix(function Logo(props) {
|
|
33
|
-
var className = props.className, appearance = props.appearance,
|
|
33
|
+
var className = props.className, appearance = props.appearance, href = props.href, link = props.link;
|
|
34
34
|
var appearanceConfig = useAppearanceConfig.useAppearanceConfig(appearance, logoConfig);
|
|
35
35
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
36
|
-
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, alignItemsClass = propsGenerator.alignItemsClass, src = propsGenerator.src, title = propsGenerator.title, alt = propsGenerator.alt, widthClass = propsGenerator.widthClass;
|
|
36
|
+
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, alignItemsClass = propsGenerator.alignItemsClass, src = propsGenerator.src, title = propsGenerator.title, alt = propsGenerator.alt, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
37
37
|
var logo = useStyles.useStyles(props).styles;
|
|
38
|
-
return (jsxRuntime.jsx("div", { className: clsx(className, 'logo', alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignItemsClass && "logo_align-items_".concat(alignItemsClass),
|
|
38
|
+
return (jsxRuntime.jsx("div", { className: clsx(className, 'logo', alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignItemsClass && "logo_align-items_".concat(alignItemsClass), sizeClass && "logo_size_".concat(sizeClass), widthClass && "width_".concat(widthClass)), style: logo, children: link || href ? (jsxRuntime.jsx(Link.LinkWrapper, { className: "logo__link", href: link || href, children: jsxRuntime.jsx("img", { className: "logo__image", src: src, title: title || alt, alt: alt || title }) })) : (jsxRuntime.jsx("img", { className: "logo__image", src: src, title: title || alt, alt: alt || title })) }));
|
|
39
39
|
});
|
|
40
40
|
|
|
41
41
|
exports.Logo = Logo;
|
|
@@ -145,6 +145,7 @@ var menuItemAppearanceSurface = {
|
|
|
145
145
|
fillActive: 'surfaceHover',
|
|
146
146
|
fillActiveHover: 'surfaceHover',
|
|
147
147
|
fillHover: 'surfaceHover',
|
|
148
|
+
labelTextHoverColor: 'accentTextSecondary',
|
|
148
149
|
labelTextColor: 'surfaceTextPrimary',
|
|
149
150
|
borderColor: 'surfaceBorderQuaternary',
|
|
150
151
|
iconAfterFillIcon: 'surfaceItemPrimary',
|
|
@@ -8,7 +8,7 @@ var ReactPaginate = require('react-paginate');
|
|
|
8
8
|
var useAppearanceConfig = require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
9
9
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
10
10
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
11
|
-
var DropdownItem = require('../../
|
|
11
|
+
var DropdownItem = require('../../DropdownItem_cjs_DdjN_gRH.js');
|
|
12
12
|
var Icon = require('../../Icon_cjs_O7ILYzgW.js');
|
|
13
13
|
var Text = require('../../Text_cjs_C-Ux7Tz5.js');
|
|
14
14
|
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
@@ -4,7 +4,6 @@ var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
|
4
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var clsx = require('clsx');
|
|
7
|
-
var SVG = require('react-inlinesvg');
|
|
8
7
|
var urlWithAssetPrefix = require('../hoc/urlWithAssetPrefix.js');
|
|
9
8
|
var useAppearanceConfig = require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
10
9
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
@@ -26,6 +25,7 @@ require('../utils/setViewportProperty.js');
|
|
|
26
25
|
require('lodash/maxBy');
|
|
27
26
|
require('../hooks/useStyles/styleAttributes.js');
|
|
28
27
|
require('../../Icon_cjs_O7ILYzgW.js');
|
|
28
|
+
require('react-inlinesvg');
|
|
29
29
|
require('../../Link_cjs_BqT6eVl6.js');
|
|
30
30
|
require('../../Loader_cjs_DXJ1zsFJ.js');
|
|
31
31
|
|
|
@@ -167,14 +167,13 @@ var Response = urlWithAssetPrefix.urlWithAssetPrefix(function Response(props) {
|
|
|
167
167
|
return jsxRuntime.jsx(Image, tslib_es6.__assign({}, sizes));
|
|
168
168
|
}
|
|
169
169
|
if (src) {
|
|
170
|
-
if (src.endsWith('.svg') || src.startsWith('data:image/svg')) {
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
}
|
|
170
|
+
// if (src.endsWith('.svg') || src.startsWith('data:image/svg')) {
|
|
171
|
+
// if (svgFillClass) {
|
|
172
|
+
// return <SVG src={src} preProcessor={removeFillStroke} />
|
|
173
|
+
// } else {
|
|
174
|
+
// return <SVG src={src} />
|
|
175
|
+
// }
|
|
176
|
+
// }
|
|
178
177
|
return jsxRuntime.jsx("img", { src: src });
|
|
179
178
|
}
|
|
180
179
|
return null;
|
|
@@ -187,13 +186,6 @@ var Response = urlWithAssetPrefix.urlWithAssetPrefix(function Response(props) {
|
|
|
187
186
|
secondaryButton ||
|
|
188
187
|
appearanceConfig) && (jsxRuntime.jsxs(Group.Group, { className: "response__button", width: "fill", children: [primaryButtonLabel ? (jsxRuntime.jsx(Button.Button, { className: "response__button-item", appearance: primaryButtonAppearance, width: primaryButtonWidth || 'fill', size: primaryButtonSize, fill: primaryButtonFill, fillHover: primaryButtonFillHover, label: primaryButtonLabel, labelTextColor: primaryButtonLabelTextColor, labelTextSize: primaryButtonLabelTextSize, shape: primaryButtonShape, before: primaryButtonBefore, after: primaryButtonAfter, onClick: onClickPrimaryButton })) : (primaryButton), secondaryButtonLabel ? (jsxRuntime.jsx(Button.Button, { className: "response__button-item", appearance: secondaryButtonAppearance, width: secondaryButtonWidth || 'fill', size: secondaryButtonSize, fill: secondaryButtonFill, fillHover: secondaryButtonFillHover, label: secondaryButtonLabel, labelTextColor: secondaryButtonLabelTextColor, labelTextSize: secondaryButtonLabelTextSize, shape: secondaryButtonShape, before: secondaryButtonBefore, after: secondaryButtonAfter, onClick: onClickSecondaryButton })) : (secondaryButton)] })), after] }));
|
|
189
188
|
});
|
|
190
|
-
var removeFillStroke = function (code) {
|
|
191
|
-
return code
|
|
192
|
-
.replace(/fill=".*?"/g, 'fill=""')
|
|
193
|
-
.replace(/fill='.*?'/g, "fill=''")
|
|
194
|
-
.replace(/stroke=".*?"/g, 'stroke=""')
|
|
195
|
-
.replace(/stroke='.*?'/g, "stroke=''");
|
|
196
|
-
};
|
|
197
189
|
|
|
198
190
|
exports.Response = Response;
|
|
199
191
|
exports.responseAppearance = responseAppearance;
|
|
@@ -3,7 +3,7 @@ import clsx from 'clsx';
|
|
|
3
3
|
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
4
4
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
5
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
|
-
import { A as Avatar } from '../
|
|
6
|
+
import { A as Avatar } from '../Avatar_es_CSKFNChm.js';
|
|
7
7
|
import { G as Group } from '../Group_es_B2yGEJfj.js';
|
|
8
8
|
import { T as Text } from '../Text_es_BdFAdf7M.js';
|
|
9
9
|
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { D as Dropdown, a as DropdownItem, d as dropdownItemAppearance, b as dropdownItemConfig } from '../
|
|
1
|
+
export { D as Dropdown, a as DropdownItem, d as dropdownItemAppearance, b as dropdownItemConfig } from '../DropdownItem_es_DfEoMbef.js';
|
|
2
2
|
import 'react/jsx-runtime';
|
|
3
3
|
import 'react';
|
|
4
4
|
import 'clsx';
|
package/dist/components/Logo.js
CHANGED
|
@@ -28,12 +28,12 @@ var logoConfig = {
|
|
|
28
28
|
},
|
|
29
29
|
};
|
|
30
30
|
var Logo = urlWithAssetPrefix(function Logo(props) {
|
|
31
|
-
var className = props.className, appearance = props.appearance,
|
|
31
|
+
var className = props.className, appearance = props.appearance, href = props.href, link = props.link;
|
|
32
32
|
var appearanceConfig = useAppearanceConfig(appearance, logoConfig);
|
|
33
33
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
34
|
-
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, alignItemsClass = propsGenerator.alignItemsClass, src = propsGenerator.src, title = propsGenerator.title, alt = propsGenerator.alt, widthClass = propsGenerator.widthClass;
|
|
34
|
+
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, alignItemsClass = propsGenerator.alignItemsClass, src = propsGenerator.src, title = propsGenerator.title, alt = propsGenerator.alt, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
35
35
|
var logo = useStyles(props).styles;
|
|
36
|
-
return (jsx("div", { className: clsx(className, 'logo', alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignItemsClass && "logo_align-items_".concat(alignItemsClass),
|
|
36
|
+
return (jsx("div", { className: clsx(className, 'logo', alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignItemsClass && "logo_align-items_".concat(alignItemsClass), sizeClass && "logo_size_".concat(sizeClass), widthClass && "width_".concat(widthClass)), style: logo, children: link || href ? (jsx(LinkWrapper, { className: "logo__link", href: link || href, children: jsx("img", { className: "logo__image", src: src, title: title || alt, alt: alt || title }) })) : (jsx("img", { className: "logo__image", src: src, title: title || alt, alt: alt || title })) }));
|
|
37
37
|
});
|
|
38
38
|
|
|
39
39
|
export { Logo, logoConfig };
|
|
@@ -143,6 +143,7 @@ var menuItemAppearanceSurface = {
|
|
|
143
143
|
fillActive: 'surfaceHover',
|
|
144
144
|
fillActiveHover: 'surfaceHover',
|
|
145
145
|
fillHover: 'surfaceHover',
|
|
146
|
+
labelTextHoverColor: 'accentTextSecondary',
|
|
146
147
|
labelTextColor: 'surfaceTextPrimary',
|
|
147
148
|
borderColor: 'surfaceBorderQuaternary',
|
|
148
149
|
iconAfterFillIcon: 'surfaceItemPrimary',
|
|
@@ -6,7 +6,7 @@ import ReactPaginate from 'react-paginate';
|
|
|
6
6
|
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
7
7
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
8
8
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
9
|
-
import { D as Dropdown, a as DropdownItem } from '../
|
|
9
|
+
import { D as Dropdown, a as DropdownItem } from '../DropdownItem_es_DfEoMbef.js';
|
|
10
10
|
import { I as Icon } from '../Icon_es_BGR9vYtq.js';
|
|
11
11
|
import { T as Text } from '../Text_es_BdFAdf7M.js';
|
|
12
12
|
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
@@ -2,7 +2,6 @@ import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
|
2
2
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
3
|
import { useMemo } from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
|
-
import SVG from 'react-inlinesvg';
|
|
6
5
|
import { urlWithAssetPrefix } from '../hoc/urlWithAssetPrefix.js';
|
|
7
6
|
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
8
7
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
@@ -24,6 +23,7 @@ import '../utils/setViewportProperty.js';
|
|
|
24
23
|
import 'lodash/maxBy';
|
|
25
24
|
import '../hooks/useStyles/styleAttributes.js';
|
|
26
25
|
import '../Icon_es_BGR9vYtq.js';
|
|
26
|
+
import 'react-inlinesvg';
|
|
27
27
|
import '../Link_es_BnUIX0QT.js';
|
|
28
28
|
import '../Loader_es_D_NFpg8C.js';
|
|
29
29
|
|
|
@@ -165,14 +165,13 @@ var Response = urlWithAssetPrefix(function Response(props) {
|
|
|
165
165
|
return jsx(Image, __assign({}, sizes));
|
|
166
166
|
}
|
|
167
167
|
if (src) {
|
|
168
|
-
if (src.endsWith('.svg') || src.startsWith('data:image/svg')) {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
}
|
|
168
|
+
// if (src.endsWith('.svg') || src.startsWith('data:image/svg')) {
|
|
169
|
+
// if (svgFillClass) {
|
|
170
|
+
// return <SVG src={src} preProcessor={removeFillStroke} />
|
|
171
|
+
// } else {
|
|
172
|
+
// return <SVG src={src} />
|
|
173
|
+
// }
|
|
174
|
+
// }
|
|
176
175
|
return jsx("img", { src: src });
|
|
177
176
|
}
|
|
178
177
|
return null;
|
|
@@ -185,12 +184,5 @@ var Response = urlWithAssetPrefix(function Response(props) {
|
|
|
185
184
|
secondaryButton ||
|
|
186
185
|
appearanceConfig) && (jsxs(Group, { className: "response__button", width: "fill", children: [primaryButtonLabel ? (jsx(Button, { className: "response__button-item", appearance: primaryButtonAppearance, width: primaryButtonWidth || 'fill', size: primaryButtonSize, fill: primaryButtonFill, fillHover: primaryButtonFillHover, label: primaryButtonLabel, labelTextColor: primaryButtonLabelTextColor, labelTextSize: primaryButtonLabelTextSize, shape: primaryButtonShape, before: primaryButtonBefore, after: primaryButtonAfter, onClick: onClickPrimaryButton })) : (primaryButton), secondaryButtonLabel ? (jsx(Button, { className: "response__button-item", appearance: secondaryButtonAppearance, width: secondaryButtonWidth || 'fill', size: secondaryButtonSize, fill: secondaryButtonFill, fillHover: secondaryButtonFillHover, label: secondaryButtonLabel, labelTextColor: secondaryButtonLabelTextColor, labelTextSize: secondaryButtonLabelTextSize, shape: secondaryButtonShape, before: secondaryButtonBefore, after: secondaryButtonAfter, onClick: onClickSecondaryButton })) : (secondaryButton)] })), after] }));
|
|
187
186
|
});
|
|
188
|
-
var removeFillStroke = function (code) {
|
|
189
|
-
return code
|
|
190
|
-
.replace(/fill=".*?"/g, 'fill=""')
|
|
191
|
-
.replace(/fill='.*?'/g, "fill=''")
|
|
192
|
-
.replace(/stroke=".*?"/g, 'stroke=""')
|
|
193
|
-
.replace(/stroke='.*?'/g, "stroke=''");
|
|
194
|
-
};
|
|
195
187
|
|
|
196
188
|
export { Response, responseAppearance, responseConfig };
|
|
@@ -50,28 +50,6 @@
|
|
|
50
50
|
background-position: -200%;
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
|
-
.avatar {
|
|
54
|
-
&_shape {
|
|
55
|
-
&_circular {
|
|
56
|
-
^^&__image,
|
|
57
|
-
^^&__wrapper {
|
|
58
|
-
border-radius: 50%;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
&_geometric {
|
|
62
|
-
^^&__image,
|
|
63
|
-
^^&__wrapper {
|
|
64
|
-
border-radius: 0;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
&_rounded {
|
|
68
|
-
^^&__image,
|
|
69
|
-
^^&__wrapper {
|
|
70
|
-
border-radius: var(--avatar-shape-rounded);
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
53
|
/* stylelint-disable prettier/prettier */
|
|
76
54
|
.avatar {
|
|
77
55
|
&_size {
|
|
@@ -902,11 +902,13 @@ div.swiper-block__item {
|
|
|
902
902
|
|
|
903
903
|
.swiper-block {
|
|
904
904
|
&&_type_step {
|
|
905
|
-
min-height: 100vh;
|
|
906
905
|
display: flex;
|
|
907
906
|
align-items: center;
|
|
907
|
+
flex-grow: 1;
|
|
908
908
|
^&__swiper {
|
|
909
|
+
width: 100%;
|
|
909
910
|
height: 100%;
|
|
911
|
+
align-items: center;
|
|
910
912
|
display: flex;
|
|
911
913
|
}
|
|
912
914
|
& .swiper-wrapper {
|
|
@@ -1,49 +1,64 @@
|
|
|
1
|
+
%align-horizontal-reverse {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: row-reverse;
|
|
4
|
+
}
|
|
5
|
+
|
|
1
6
|
.align {
|
|
2
7
|
&_horizontal-reverse {
|
|
3
8
|
display: flex;
|
|
4
9
|
flex-direction: row-reverse;
|
|
5
|
-
|
|
10
|
+
@extend %align-horizontal-reverse;
|
|
11
|
+
&-top {
|
|
6
12
|
&-left {
|
|
7
13
|
align-items: flex-start;
|
|
14
|
+
@extend %align-horizontal-reverse;
|
|
8
15
|
}
|
|
9
16
|
&-center {
|
|
10
17
|
text-align: center;
|
|
11
18
|
justify-content: center;
|
|
12
19
|
align-items: flex-start;
|
|
20
|
+
@extend %align-horizontal-reverse;
|
|
13
21
|
}
|
|
14
22
|
&-right {
|
|
15
23
|
text-align: right;
|
|
16
24
|
justify-content: flex-end;
|
|
17
25
|
align-items: flex-start;
|
|
26
|
+
@extend %align-horizontal-reverse;
|
|
18
27
|
}
|
|
19
28
|
}
|
|
20
|
-
|
|
29
|
+
&-left {
|
|
21
30
|
align-items: center;
|
|
31
|
+
@extend %align-horizontal-reverse;
|
|
22
32
|
}
|
|
23
|
-
|
|
33
|
+
&-center {
|
|
24
34
|
text-align: center;
|
|
25
35
|
justify-content: center;
|
|
26
36
|
align-items: center;
|
|
37
|
+
@extend %align-horizontal-reverse;
|
|
27
38
|
}
|
|
28
|
-
|
|
39
|
+
&-right {
|
|
29
40
|
text-align: right;
|
|
30
41
|
justify-content: flex-end;
|
|
31
42
|
align-items: center;
|
|
43
|
+
@extend %align-horizontal-reverse;
|
|
32
44
|
}
|
|
33
|
-
|
|
45
|
+
&-bottom {
|
|
34
46
|
&-left {
|
|
35
47
|
flex-direction: row;
|
|
36
48
|
align-items: flex-end;
|
|
49
|
+
@extend %align-horizontal-reverse;
|
|
37
50
|
}
|
|
38
51
|
&-center {
|
|
39
52
|
text-align: center;
|
|
40
53
|
justify-content: center;
|
|
41
54
|
align-items: flex-end;
|
|
55
|
+
@extend %align-horizontal-reverse;
|
|
42
56
|
}
|
|
43
57
|
&-right {
|
|
44
58
|
text-align: right;
|
|
45
59
|
justify-content: flex-end;
|
|
46
60
|
align-items: flex-end;
|
|
61
|
+
@extend %align-horizontal-reverse;
|
|
47
62
|
}
|
|
48
63
|
}
|
|
49
64
|
}
|
|
@@ -1,63 +1,79 @@
|
|
|
1
|
+
%align-horizontal {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: row;
|
|
4
|
+
}
|
|
5
|
+
|
|
1
6
|
.align {
|
|
2
7
|
&_horizontal {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
&^&_top {
|
|
8
|
+
&_top {
|
|
9
|
+
@extend %align-horizontal;
|
|
6
10
|
align-items: flex-start;
|
|
7
11
|
&-left {
|
|
12
|
+
@extend %align-horizontal;
|
|
8
13
|
align-items: flex-start;
|
|
9
14
|
}
|
|
10
15
|
&-center {
|
|
16
|
+
@extend %align-horizontal;
|
|
11
17
|
text-align: center;
|
|
12
18
|
justify-content: center;
|
|
13
19
|
align-items: flex-start;
|
|
14
20
|
}
|
|
15
21
|
&-right {
|
|
22
|
+
@extend %align-horizontal;
|
|
16
23
|
text-align: right;
|
|
17
24
|
justify-content: flex-end;
|
|
18
25
|
align-items: flex-start;
|
|
19
26
|
}
|
|
20
27
|
&-auto {
|
|
28
|
+
@extend %align-horizontal;
|
|
21
29
|
text-align: right;
|
|
22
30
|
justify-content: space-between;
|
|
23
31
|
align-items: flex-start;
|
|
24
32
|
}
|
|
25
33
|
}
|
|
26
|
-
|
|
34
|
+
&-left {
|
|
35
|
+
@extend %align-horizontal;
|
|
27
36
|
align-items: center;
|
|
28
37
|
}
|
|
29
|
-
|
|
38
|
+
&-center {
|
|
39
|
+
@extend %align-horizontal;
|
|
30
40
|
text-align: center;
|
|
31
41
|
justify-content: center;
|
|
32
42
|
align-items: center;
|
|
33
43
|
&-auto {
|
|
44
|
+
@extend %align-horizontal;
|
|
34
45
|
text-align: center;
|
|
35
46
|
justify-content: space-between;
|
|
36
47
|
align-items: center;
|
|
37
48
|
}
|
|
38
49
|
}
|
|
39
|
-
|
|
50
|
+
&-right {
|
|
51
|
+
@extend %align-horizontal;
|
|
40
52
|
text-align: right;
|
|
41
53
|
justify-content: flex-end;
|
|
42
54
|
align-items: center;
|
|
43
55
|
}
|
|
44
|
-
|
|
56
|
+
&_bottom {
|
|
57
|
+
@extend %align-horizontal;
|
|
45
58
|
align-items: flex-end;
|
|
46
59
|
&-left {
|
|
47
|
-
|
|
60
|
+
@extend %align-horizontal;
|
|
48
61
|
align-items: flex-end;
|
|
49
62
|
}
|
|
50
63
|
&-center {
|
|
64
|
+
@extend %align-horizontal;
|
|
51
65
|
text-align: center;
|
|
52
66
|
justify-content: center;
|
|
53
67
|
align-items: flex-end;
|
|
54
68
|
}
|
|
55
69
|
&-right {
|
|
56
70
|
text-align: right;
|
|
71
|
+
@extend %align-horizontal;
|
|
57
72
|
justify-content: flex-end;
|
|
58
73
|
align-items: flex-end;
|
|
59
74
|
}
|
|
60
75
|
&-auto {
|
|
76
|
+
@extend %align-horizontal;
|
|
61
77
|
text-align: right;
|
|
62
78
|
justify-content: space-between;
|
|
63
79
|
align-items: flex-end;
|
|
@@ -1,45 +1,57 @@
|
|
|
1
|
+
%align-vertical-reverse {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: column-reverse;
|
|
4
|
+
}
|
|
5
|
+
|
|
1
6
|
.align {
|
|
2
7
|
&_vertical-reverse {
|
|
3
|
-
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
&^&_top {
|
|
8
|
+
&-top {
|
|
6
9
|
&-left {
|
|
10
|
+
@extend %align-horizontal-reverse;
|
|
7
11
|
align-items: flex-start;
|
|
8
12
|
}
|
|
9
13
|
&-center {
|
|
14
|
+
@extend %align-horizontal-reverse;
|
|
10
15
|
text-align: center;
|
|
11
16
|
align-items: center;
|
|
12
17
|
}
|
|
13
18
|
&-right {
|
|
19
|
+
@extend %align-horizontal-reverse;
|
|
14
20
|
text-align: right;
|
|
15
21
|
align-items: flex-end;
|
|
16
22
|
}
|
|
17
23
|
}
|
|
18
|
-
|
|
24
|
+
&-left {
|
|
25
|
+
@extend %align-horizontal-reverse;
|
|
19
26
|
justify-content: center;
|
|
20
27
|
align-items: flex-start;
|
|
21
28
|
}
|
|
22
|
-
|
|
29
|
+
&-center {
|
|
30
|
+
@extend %align-horizontal-reverse;
|
|
23
31
|
text-align: center;
|
|
24
32
|
justify-content: center;
|
|
25
33
|
align-items: center;
|
|
26
34
|
}
|
|
27
|
-
|
|
35
|
+
&-right {
|
|
36
|
+
@extend %align-horizontal-reverse;
|
|
28
37
|
text-align: right;
|
|
29
38
|
justify-content: center;
|
|
30
39
|
align-items: flex-end;
|
|
31
40
|
}
|
|
32
|
-
|
|
41
|
+
&-bottom {
|
|
33
42
|
&-left {
|
|
43
|
+
@extend %align-horizontal-reverse;
|
|
34
44
|
justify-content: flex-end;
|
|
35
45
|
align-items: flex-start;
|
|
36
46
|
}
|
|
37
47
|
&-center {
|
|
48
|
+
@extend %align-horizontal-reverse;
|
|
38
49
|
text-align: center;
|
|
39
50
|
justify-content: flex-end;
|
|
40
51
|
align-items: center;
|
|
41
52
|
}
|
|
42
53
|
&-right {
|
|
54
|
+
@extend %align-horizontal-reverse;
|
|
43
55
|
text-align: right;
|
|
44
56
|
justify-content: flex-end;
|
|
45
57
|
align-items: flex-end;
|
|
@@ -1,60 +1,75 @@
|
|
|
1
|
+
%align-vertical {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: column;
|
|
4
|
+
}
|
|
5
|
+
|
|
1
6
|
.align {
|
|
2
7
|
&_vertical {
|
|
3
|
-
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
&^&_top {
|
|
8
|
+
&-top {
|
|
6
9
|
&-left {
|
|
10
|
+
@extend %align-vertical;
|
|
7
11
|
align-items: flex-start;
|
|
8
12
|
}
|
|
9
13
|
&-center {
|
|
14
|
+
@extend %align-vertical;
|
|
10
15
|
text-align: center;
|
|
11
16
|
align-items: center;
|
|
12
17
|
}
|
|
13
18
|
&-right {
|
|
19
|
+
@extend %align-vertical;
|
|
14
20
|
text-align: right;
|
|
15
21
|
align-items: flex-end;
|
|
16
22
|
}
|
|
17
23
|
&-auto {
|
|
24
|
+
@extend %align-vertical;
|
|
18
25
|
text-align: center;
|
|
19
26
|
justify-content: space-between;
|
|
20
27
|
align-items: center;
|
|
21
28
|
}
|
|
22
29
|
}
|
|
23
|
-
|
|
30
|
+
&-left {
|
|
31
|
+
@extend %align-vertical;
|
|
24
32
|
justify-content: center;
|
|
25
33
|
align-items: flex-start;
|
|
26
34
|
}
|
|
27
|
-
|
|
35
|
+
&-center {
|
|
36
|
+
@extend %align-vertical;
|
|
28
37
|
text-align: center;
|
|
29
38
|
justify-content: center;
|
|
30
39
|
align-items: center;
|
|
31
40
|
&-auto {
|
|
41
|
+
@extend %align-vertical;
|
|
32
42
|
text-align: center;
|
|
33
43
|
justify-content: space-between;
|
|
34
44
|
align-items: center;
|
|
35
45
|
}
|
|
36
46
|
}
|
|
37
|
-
|
|
47
|
+
&-right {
|
|
48
|
+
@extend %align-vertical;
|
|
38
49
|
text-align: right;
|
|
39
50
|
justify-content: center;
|
|
40
51
|
align-items: flex-end;
|
|
41
52
|
}
|
|
42
|
-
|
|
53
|
+
&-bottom {
|
|
43
54
|
&-left {
|
|
55
|
+
@extend %align-vertical;
|
|
44
56
|
justify-content: flex-end;
|
|
45
57
|
align-items: flex-start;
|
|
46
58
|
}
|
|
47
59
|
&-center {
|
|
60
|
+
@extend %align-vertical;
|
|
48
61
|
text-align: center;
|
|
49
62
|
justify-content: flex-end;
|
|
50
63
|
align-items: center;
|
|
51
64
|
}
|
|
52
65
|
&-right {
|
|
66
|
+
@extend %align-vertical;
|
|
53
67
|
text-align: right;
|
|
54
68
|
justify-content: flex-end;
|
|
55
69
|
align-items: flex-end;
|
|
56
70
|
}
|
|
57
71
|
&-auto {
|
|
72
|
+
@extend %align-vertical;
|
|
58
73
|
text-align: center;
|
|
59
74
|
justify-content: space-between;
|
|
60
75
|
align-items: center;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
declare const avatarAppearanceShape: {
|
|
2
|
+
circular: {
|
|
3
|
+
shape: string;
|
|
4
|
+
};
|
|
5
|
+
rounded: {
|
|
6
|
+
shape: string;
|
|
7
|
+
};
|
|
8
|
+
roundedL: {
|
|
9
|
+
shape: string;
|
|
10
|
+
shapeStrength: string;
|
|
11
|
+
};
|
|
12
|
+
roundedM: {
|
|
13
|
+
shape: string;
|
|
14
|
+
shapeStrength: string;
|
|
15
|
+
};
|
|
16
|
+
roundedS: {
|
|
17
|
+
shape: string;
|
|
18
|
+
shapeStrength: string;
|
|
19
|
+
};
|
|
20
|
+
roundedXL: {
|
|
21
|
+
shape: string;
|
|
22
|
+
shapeStrength: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export { avatarAppearanceShape };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itcase/ui",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.60",
|
|
4
4
|
"description": "UI components (Modal, Loader, Popup, etc)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Modal",
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
"@emotion/is-prop-valid": "^1.3.1",
|
|
104
104
|
"@itcase/common": "^1.2.28",
|
|
105
105
|
"@itcase/icons": "^1.2.16",
|
|
106
|
-
"@itcase/storybook-config": "^1.1.
|
|
106
|
+
"@itcase/storybook-config": "^1.1.50",
|
|
107
107
|
"@itcase/tokens-am": "^1.1.19",
|
|
108
108
|
"@itcase/tokens-baikal": "^1.1.17",
|
|
109
109
|
"@itcase/tokens-palette": "^1.1.11",
|
|
@@ -142,8 +142,8 @@
|
|
|
142
142
|
"@babel/preset-react": "^7.27.1",
|
|
143
143
|
"@commitlint/cli": "^19.8.1",
|
|
144
144
|
"@commitlint/config-conventional": "^19.8.1",
|
|
145
|
-
"@itcase/config": "^1.0.
|
|
146
|
-
"@itcase/lint": "^1.1.
|
|
145
|
+
"@itcase/config": "^1.0.54",
|
|
146
|
+
"@itcase/lint": "^1.1.25",
|
|
147
147
|
"@itcase/types": "^1.0.6",
|
|
148
148
|
"@rollup/plugin-alias": "^5.1.1",
|
|
149
149
|
"@rollup/plugin-babel": "^6.0.4",
|