@meduza/ui-kit-2 1.4.7-b → 1.4.8

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.
@@ -4,11 +4,12 @@
4
4
 
5
5
  display: flex;
6
6
  flex-flow: column nowrap;
7
- gap: 20px;
7
+ gap: 30px;
8
8
 
9
- padding: 10px 20px 20px;
9
+ padding: 12px 20px 20px;
10
10
  overflow: hidden;
11
11
 
12
+ color: #000;
12
13
  text-decoration: none;
13
14
 
14
15
  background-color: #f7f7f7;
@@ -19,34 +20,62 @@
19
20
  box-shadow: 0 1px 0 0 rgba(0, 0, 0, 0.1);
20
21
  }
21
22
 
22
- .root:hover {
23
- @media $mobile {
24
- opacity: 0.95;
23
+ .root {
24
+ margin: 16px -20px;
25
+
26
+ @media $portraitTablet {
27
+ margin-top: 25px;
28
+ margin-bottom: 25px;
25
29
  }
26
30
  }
27
31
 
28
- .root {
29
- margin: 16px 0;
32
+ .root:first-child {
33
+ margin-top: 0;
34
+ }
35
+
36
+ .root:last-child {
37
+ margin-bottom: 0;
38
+ }
39
+
40
+ .isInCard {
41
+ margin-right: -11px;
42
+ margin-left: -11px;
30
43
 
31
44
  @media $portraitTablet {
32
- margin: 25px 0;
45
+ margin-right: 0;
46
+ margin-left: 0;
33
47
  }
34
48
  }
35
49
 
36
50
  .content {
37
51
  display: flex;
38
- flex-flow: row nowrap;
52
+ flex-flow: column nowrap;
39
53
  gap: 20px;
54
+
55
+ @media $portraitTablet {
56
+ flex-flow: row nowrap;
57
+ }
40
58
  }
41
59
 
42
60
  .cover {
43
61
  flex-shrink: 0;
44
- width: 200px;
62
+ width: 100%;
63
+
64
+ @media $portraitTablet {
65
+ width: 200px;
66
+ }
45
67
  }
46
68
 
47
69
  .body {
48
70
  display: flex;
49
71
  flex-flow: column nowrap;
72
+ gap: 16px;
73
+
74
+ transition: color 0.15s;
75
+ }
76
+
77
+ .root:hover .body {
78
+ color: #5c5c5c;
50
79
  }
51
80
 
52
81
  .isCard .cover {
@@ -62,19 +91,28 @@
62
91
  }
63
92
 
64
93
  .isCard .cover > div {
65
- width: 100px;
66
- height: 100px;
94
+ width: 180px;
95
+ height: 180px;
96
+
97
+ @media $portraitTablet {
98
+ width: 100px;
99
+ height: 100px;
100
+ }
67
101
  }
68
102
 
69
103
  .tag {
70
- color: rgba(0, 0, 0, 0.5);
104
+ display: flex;
105
+
106
+ color: #7f7f7f;
71
107
  }
72
108
 
73
109
  .center {
74
- width: 100%;
75
110
  max-width: 650px;
76
- margin-right: auto;
77
- margin-left: auto;
111
+
112
+ @media $mobile {
113
+ margin-right: auto;
114
+ margin-left: auto;
115
+ }
78
116
  }
79
117
 
80
118
  /* Display */
@@ -33,12 +33,12 @@ export const RelatedRichBlock: React.FC<RelatedRichBlockProps> = ({
33
33
  [styles[onlyOn], !!onlyOn && !!styles[onlyOn]]
34
34
  ]
35
35
 
36
- let context = ['isInMediaBlock']
36
+ let context = ['isInMediaBlock', 'richRelated']
37
37
 
38
38
  if (styleContext) {
39
39
  classNames = makeStyleContext(classNames, styleContext, styles)
40
40
 
41
- context = [...styleContext, 'isInMediaBlock']
41
+ context = [...styleContext, 'isInMediaBlock', 'richRelated']
42
42
  }
43
43
 
44
44
  return (
@@ -119,6 +119,26 @@
119
119
  }
120
120
  }
121
121
 
122
+ .root.richRelated {
123
+ margin: 0;
124
+
125
+ font-size: 18px;
126
+ line-height: 1.3;
127
+ letter-spacing: normal;
128
+ }
129
+
130
+ .root.richRelated span {
131
+ margin-top: 0;
132
+ padding-top: 0;
133
+
134
+ font-size: 16px;
135
+ line-height: 1.3;
136
+
137
+ @media $landscapeTablet {
138
+ font-size: 18px;
139
+ }
140
+ }
141
+
122
142
  .isInBookRelated {
123
143
  margin: 6px 0 20px;
124
144
 
@@ -52,6 +52,10 @@
52
52
  color: inherit;
53
53
  }
54
54
 
55
+ .overlay {
56
+ color: color-mix(in srgb, var(--overlayColor, #fff) 80%, transparent);
57
+ }
58
+
55
59
  .is1to1,
56
60
  .is1to2,
57
61
  .isInSuperBlock {
@@ -8,6 +8,7 @@ export type TagThemes =
8
8
  | 'gray'
9
9
  | 'light'
10
10
  | 'inherit'
11
+ | 'overlay'
11
12
  | 'custom'
12
13
 
13
14
  export type TagStyleContexts = 'isInToolbar' | 'isInSpoiler' | 'isInDropdown'
package/src/types.ts CHANGED
@@ -5,13 +5,7 @@ export interface OptimizedImageItem {
5
5
  '2x_webp': string
6
6
  }
7
7
 
8
- export type CallToActions =
9
- | 'fb'
10
- | 'tw'
11
- | 'tg'
12
- | 'reaction'
13
- | 'pdf'
14
- | 'cross'
8
+ export type CallToActions = 'fb' | 'tw' | 'tg' | 'reaction' | 'pdf' | 'cross'
15
9
 
16
10
  export type LightboxImage = {
17
11
  original: string