@cloud-ru/ds-uikit-product-card-predefined 3.1.3 → 3.1.4-preview-a2208aeb.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/cjs/components/CardCustom/Footer/components/CallToAction/styles.module.css +4 -4
- package/dist/cjs/components/CardCustom/FunctionBadge/styles.module.css +4 -3
- package/dist/cjs/components/CardCustom/Header/styles.module.css +1 -7
- package/dist/cjs/components/CardCustom/Image/styles.module.css +3 -3
- package/dist/cjs/components/CardServiceInfo/styles.module.css +11 -11
- package/dist/cjs/components/CardServiceLight/styles.module.css +7 -7
- package/dist/cjs/components/CardServiceSmall/CardServiceSmall.js +1 -1
- package/dist/cjs/components/CardServiceSmall/styles.module.css +6 -0
- package/dist/cjs/helperComponents/CardAction/CardAction.js +1 -1
- package/dist/cjs/helperComponents/CardAction/styles.module.css +8 -1
- package/dist/cjs/helperComponents/CardActionsSurface/styles.module.css +5 -4
- package/dist/cjs/helperComponents/FunctionBadgeWrapper/styles.module.css +4 -3
- package/dist/cjs/style.css +53 -43
- package/dist/esm/components/CardCustom/Footer/components/CallToAction/styles.module.css +4 -4
- package/dist/esm/components/CardCustom/FunctionBadge/styles.module.css +4 -3
- package/dist/esm/components/CardCustom/Header/styles.module.css +1 -7
- package/dist/esm/components/CardCustom/Image/styles.module.css +3 -3
- package/dist/esm/components/CardServiceInfo/styles.module.css +11 -11
- package/dist/esm/components/CardServiceLight/styles.module.css +7 -7
- package/dist/esm/components/CardServiceSmall/CardServiceSmall.js +1 -1
- package/dist/esm/components/CardServiceSmall/styles.module.css +6 -0
- package/dist/esm/helperComponents/CardAction/CardAction.js +1 -1
- package/dist/esm/helperComponents/CardAction/styles.module.css +8 -1
- package/dist/esm/helperComponents/CardActionsSurface/styles.module.css +5 -4
- package/dist/esm/helperComponents/FunctionBadgeWrapper/styles.module.css +4 -3
- package/dist/esm/style.css +53 -43
- package/dist/tsconfig.cjs.tsbuildinfo +1 -1
- package/dist/tsconfig.esm.tsbuildinfo +1 -1
- package/package.json +18 -18
- package/src/components/CardCustom/Footer/components/CallToAction/styles.module.scss +2 -2
- package/src/components/CardCustom/FunctionBadge/styles.module.scss +2 -1
- package/src/components/CardCustom/Header/styles.module.scss +2 -6
- package/src/components/CardCustom/Image/styles.module.scss +2 -3
- package/src/components/CardServiceInfo/styles.module.scss +2 -2
- package/src/components/CardServiceLight/styles.module.scss +2 -2
- package/src/components/CardServiceSmall/CardServiceSmall.tsx +2 -1
- package/src/components/CardServiceSmall/styles.module.scss +6 -0
- package/src/components/CardSuggest/styles.module.scss +18 -11
- package/src/helperComponents/CardAction/CardAction.tsx +2 -2
- package/src/helperComponents/CardAction/styles.module.scss +7 -0
- package/src/helperComponents/CardActionsSurface/styles.module.scss +1 -0
- package/src/helperComponents/FunctionBadgeWrapper/styles.module.scss +1 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloud-ru/ds-uikit-product-card-predefined",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.4-preview-a2208aeb.0",
|
|
4
4
|
"description": "Пресеты карточек Product UI Kit — CardBanner, CardService, CardServiceLight, CardServiceSmall, CardSuggest, CardCustom.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -41,23 +41,23 @@
|
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"classnames": "^2.5.1",
|
|
43
43
|
"merge-refs": "^2.0.0",
|
|
44
|
-
"@cloud-ru/ds-button": "
|
|
45
|
-
"@cloud-ru/ds-adaptive": "
|
|
46
|
-
"@cloud-ru/ds-
|
|
47
|
-
"@cloud-ru/ds-
|
|
48
|
-
"@cloud-ru/ds-
|
|
49
|
-
"@cloud-ru/ds-locale": "
|
|
50
|
-
"@cloud-ru/ds-
|
|
51
|
-
"@cloud-ru/ds-promo-tag": "
|
|
52
|
-
"@cloud-ru/ds-
|
|
53
|
-
"@cloud-ru/ds-
|
|
54
|
-
"@cloud-ru/ds-
|
|
55
|
-
"@cloud-ru/ds-
|
|
56
|
-
"@cloud-ru/ds-
|
|
57
|
-
"@cloud-ru/ds-
|
|
58
|
-
"@cloud-ru/ds-utils": "
|
|
59
|
-
"@cloud-ru/ds-
|
|
60
|
-
"@cloud-ru/ds-
|
|
44
|
+
"@cloud-ru/ds-button": "1.0.3-preview-a2208aeb.0",
|
|
45
|
+
"@cloud-ru/ds-adaptive": "1.0.1",
|
|
46
|
+
"@cloud-ru/ds-card": "1.0.14-preview-a2208aeb.0",
|
|
47
|
+
"@cloud-ru/ds-icons": "1.2.1-preview-a2208aeb.0",
|
|
48
|
+
"@cloud-ru/ds-icon-predefined": "1.0.2-preview-a2208aeb.0",
|
|
49
|
+
"@cloud-ru/ds-locale": "1.0.0",
|
|
50
|
+
"@cloud-ru/ds-list": "2.2.1-preview-a2208aeb.0",
|
|
51
|
+
"@cloud-ru/ds-promo-tag": "1.0.2-preview-a2208aeb.0",
|
|
52
|
+
"@cloud-ru/ds-materials": "1.0.2-preview-a2208aeb.0",
|
|
53
|
+
"@cloud-ru/ds-tag": "1.1.3-preview-a2208aeb.0",
|
|
54
|
+
"@cloud-ru/ds-toggles": "1.1.5-preview-a2208aeb.0",
|
|
55
|
+
"@cloud-ru/ds-theme": "1.1.1-preview-a2208aeb.0",
|
|
56
|
+
"@cloud-ru/ds-tooltip": "1.0.6-preview-a2208aeb.0",
|
|
57
|
+
"@cloud-ru/ds-truncate-string": "1.0.6-preview-a2208aeb.0",
|
|
58
|
+
"@cloud-ru/ds-utils": "1.1.0",
|
|
59
|
+
"@cloud-ru/ds-typography": "1.0.0",
|
|
60
|
+
"@cloud-ru/ds-uikit-product-promo-tag-predefined": "1.0.6-preview-a2208aeb.0"
|
|
61
61
|
},
|
|
62
62
|
"publishConfig": {
|
|
63
63
|
"access": "public"
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
color: base.$sn-theme-color-primary-text;
|
|
27
27
|
|
|
28
28
|
svg {
|
|
29
|
-
width: base.$sn-density-
|
|
30
|
-
height: base.$sn-density-
|
|
29
|
+
width: base.$sn-density-icon-s !important; /* stylelint-disable-line declaration-no-important */
|
|
30
|
+
height: base.$sn-density-icon-s !important; /* stylelint-disable-line declaration-no-important */
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
33
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
$function-badge-size: base.$sn-primitive-dimension-32;
|
|
4
4
|
$function-badge-border-radius: base.$sn-brand-anatomy-radius-card-toggles-xs;
|
|
5
|
-
$icon-size: base.$sn-density-
|
|
5
|
+
$icon-size: base.$sn-density-icon-s;
|
|
6
6
|
|
|
7
7
|
.button {
|
|
8
8
|
cursor: pointer;
|
|
@@ -13,6 +13,7 @@ $icon-size: base.$sn-density-size-icon-s;
|
|
|
13
13
|
align-items: center;
|
|
14
14
|
justify-content: center;
|
|
15
15
|
|
|
16
|
+
box-sizing: border-box;
|
|
16
17
|
width: $function-badge-size;
|
|
17
18
|
height: $function-badge-size;
|
|
18
19
|
border: 0;
|
|
@@ -23,12 +23,8 @@
|
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
[data-card-custom-image] + .titleLayout {
|
|
27
|
-
|
|
28
|
-
&[data-size='#{$size}'] {
|
|
29
|
-
padding-top: 0;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
26
|
+
[data-card-custom-image] + .titleLayout[data-size] {
|
|
27
|
+
padding-top: 0;
|
|
32
28
|
}
|
|
33
29
|
|
|
34
30
|
.contentLayout {
|
|
@@ -3,9 +3,8 @@
|
|
|
3
3
|
|
|
4
4
|
$modes: 'little', 'middle', 'background';
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
//
|
|
8
|
-
$image-little-height: 144px;
|
|
6
|
+
$image-little-height: base.$sn-primitive-dimension-144;
|
|
7
|
+
// Нет токена: шкала primitive-dimension заканчивается на 152.
|
|
9
8
|
$image-middle-height: 240px;
|
|
10
9
|
|
|
11
10
|
// mask-image использует только альфа-канал стопов: RGB роли не играет, важна
|
|
@@ -81,8 +81,8 @@ $actions-counts: 1, 2;
|
|
|
81
81
|
|
|
82
82
|
.icon {
|
|
83
83
|
flex-shrink: 0;
|
|
84
|
-
width: base.$sn-density-
|
|
85
|
-
height: base.$sn-density-
|
|
84
|
+
width: base.$sn-density-icon-s;
|
|
85
|
+
height: base.$sn-density-icon-s;
|
|
86
86
|
color: base.$sn-theme-color-available-version-textTertiary;
|
|
87
87
|
}
|
|
88
88
|
|
|
@@ -128,6 +128,7 @@ export function CardServiceSmall<T extends ElementType = 'div'>({
|
|
|
128
128
|
innerRef={mergeRefs(innerRef, cardRef)}
|
|
129
129
|
disabled={disabled}
|
|
130
130
|
interactive
|
|
131
|
+
radius='s'
|
|
131
132
|
checked={checked}
|
|
132
133
|
view={outline ? 'outline' : undefined}
|
|
133
134
|
className={styles.card}
|
|
@@ -137,7 +138,7 @@ export function CardServiceSmall<T extends ElementType = 'div'>({
|
|
|
137
138
|
>
|
|
138
139
|
<div className={styles.contentWrapper}>
|
|
139
140
|
{IconComponent ? (
|
|
140
|
-
<IconComponent className={styles.icon
|
|
141
|
+
<IconComponent className={cn(styles.icon, styles.iconSvg)} />
|
|
141
142
|
) : (
|
|
142
143
|
!isIconEmblem(emblem) && <div className={styles.icon}>{emblem}</div>
|
|
143
144
|
)}
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
|
|
22
22
|
.wrapper {
|
|
23
23
|
position: relative;
|
|
24
|
+
box-sizing: border-box;
|
|
24
25
|
|
|
25
26
|
&:hover,
|
|
26
27
|
&:focus-within {
|
|
@@ -53,6 +54,11 @@
|
|
|
53
54
|
color: base.$sn-theme-color-available-version-textMain;
|
|
54
55
|
}
|
|
55
56
|
|
|
57
|
+
.iconSvg {
|
|
58
|
+
width: base.$sn-density-icon-s;
|
|
59
|
+
height: base.$sn-density-icon-s;
|
|
60
|
+
}
|
|
61
|
+
|
|
56
62
|
.contentLayout {
|
|
57
63
|
overflow: hidden;
|
|
58
64
|
display: block;
|
|
@@ -1,5 +1,17 @@
|
|
|
1
|
+
@use 'sass:map';
|
|
1
2
|
@use '@cloud-ru/ds-figma-variables/build/scss/styles/styles.module' as base;
|
|
2
3
|
|
|
4
|
+
$content-spacing: (
|
|
5
|
+
'm': (
|
|
6
|
+
'gap': base.$sn-primitive-dimension-8,
|
|
7
|
+
'padding': base.$sn-primitive-dimension-16,
|
|
8
|
+
),
|
|
9
|
+
's': (
|
|
10
|
+
'gap': base.$sn-primitive-dimension-4,
|
|
11
|
+
'padding': base.$sn-primitive-dimension-8,
|
|
12
|
+
),
|
|
13
|
+
);
|
|
14
|
+
|
|
3
15
|
.content {
|
|
4
16
|
position: relative;
|
|
5
17
|
|
|
@@ -29,17 +41,12 @@
|
|
|
29
41
|
box-sizing: border-box;
|
|
30
42
|
text-decoration: none;
|
|
31
43
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
&[data-size='s'] {
|
|
40
|
-
.content {
|
|
41
|
-
gap: base.$sn-primitive-dimension-4;
|
|
42
|
-
padding: base.$sn-primitive-dimension-8;
|
|
44
|
+
@each $size, $spacing in $content-spacing {
|
|
45
|
+
&[data-size='#{$size}'] {
|
|
46
|
+
.content {
|
|
47
|
+
gap: map.get($spacing, 'gap');
|
|
48
|
+
padding: map.get($spacing, 'padding');
|
|
49
|
+
}
|
|
43
50
|
}
|
|
44
51
|
}
|
|
45
52
|
}
|
|
@@ -15,11 +15,11 @@ type CardActionProps = {
|
|
|
15
15
|
export function CardAction({ actionLabel, className }: CardActionProps): ReactElement {
|
|
16
16
|
return (
|
|
17
17
|
<div className={cn(styles.root, className)}>
|
|
18
|
-
<Typography as='span' variant='label' size='
|
|
18
|
+
<Typography as='span' variant='label' size='m'>
|
|
19
19
|
{actionLabel}
|
|
20
20
|
</Typography>
|
|
21
21
|
|
|
22
|
-
<ArrowRightSVG
|
|
22
|
+
<ArrowRightSVG className={styles.icon} />
|
|
23
23
|
</div>
|
|
24
24
|
);
|
|
25
25
|
}
|
|
@@ -5,7 +5,14 @@
|
|
|
5
5
|
gap: base.$sn-primitive-dimension-4;
|
|
6
6
|
align-items: center;
|
|
7
7
|
|
|
8
|
+
box-sizing: border-box;
|
|
8
9
|
height: base.$sn-primitive-dimension-32;
|
|
9
10
|
|
|
10
11
|
color: base.$sn-theme-color-primary-text;
|
|
11
12
|
}
|
|
13
|
+
|
|
14
|
+
.icon {
|
|
15
|
+
flex-shrink: 0;
|
|
16
|
+
width: base.$sn-density-icon-s;
|
|
17
|
+
height: base.$sn-density-icon-s;
|
|
18
|
+
}
|