@taiga-ui/styles 5.21.0-canary.d5429b6 → 5.22.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.
@@ -1,4 +1,4 @@
1
- [tuiList]:where(*&) {
1
+ :where([tuiList]:is(ul, ol)&) {
2
2
  list-style: none;
3
3
  padding: 0.25rem 0;
4
4
  margin-block: 0;
@@ -21,7 +21,6 @@
21
21
  float: left;
22
22
  unicode-bidi: plaintext;
23
23
  font-variant-numeric: tabular-nums;
24
- // physical shorthand margins keep the marker on the wrong side in RTL
25
24
  margin-block: 0;
26
25
  margin-inline: -1.5rem 0.5625rem;
27
26
  }
@@ -50,22 +49,21 @@
50
49
  margin-inline: 0;
51
50
  }
52
51
 
53
- &[data-size='l'] {
52
+ &:where([data-size='l']) {
54
53
  font: var(--tui-typography-body-l);
55
54
 
56
55
  &:is(ul) > li::before {
57
56
  inline-size: 0.875rem;
58
- // physical shorthand margins keep the marker on the wrong side in RTL
59
57
  margin-block: 0;
60
58
  margin-inline: -1.4375rem 0.5625rem;
61
59
  }
62
60
  }
63
61
 
64
- &[data-size='m'] {
62
+ &:where([data-size='m']) {
65
63
  font: var(--tui-typography-body-m);
66
64
  }
67
65
 
68
- &[data-size='s'] {
66
+ &:where([data-size='s']) {
69
67
  font: var(--tui-typography-ui-s);
70
68
 
71
69
  & > li {
@@ -73,3 +71,75 @@
73
71
  }
74
72
  }
75
73
  }
74
+
75
+ :where(dl[tuiList]&) {
76
+ display: grid;
77
+ grid-template-columns: minmax(20%, auto) auto;
78
+ font: var(--tui-typography-body-s);
79
+ margin: 0;
80
+
81
+ &:where([data-size='s']) {
82
+ dd,
83
+ dt {
84
+ padding: 0.25rem;
85
+ }
86
+ }
87
+
88
+ &:where([data-size='m']) {
89
+ dd,
90
+ dt {
91
+ padding: 0.625rem 0.375rem;
92
+ }
93
+ }
94
+
95
+ &:where([data-size='l']) {
96
+ font: var(--tui-typography-body-m);
97
+
98
+ dd,
99
+ dt {
100
+ padding: 1rem 0.5rem;
101
+ }
102
+ }
103
+
104
+ dt,
105
+ dd {
106
+ margin: 0;
107
+ font: inherit;
108
+
109
+ &:not(:last-of-type) {
110
+ box-shadow: 0 1px var(--tui-border-normal);
111
+ }
112
+ }
113
+
114
+ dt {
115
+ color: var(--tui-text-secondary);
116
+ padding-inline-start: 0;
117
+ }
118
+
119
+ dd {
120
+ padding-inline-end: 0;
121
+ }
122
+
123
+ &:where([compact]) {
124
+ dt,
125
+ dd {
126
+ padding-block-end: 0;
127
+ box-shadow: none;
128
+ clip-path: inset(0);
129
+ }
130
+
131
+ dt {
132
+ white-space: nowrap;
133
+ }
134
+
135
+ dt::after {
136
+ content: '';
137
+ display: inline-block;
138
+ block-size: 1px;
139
+ margin-inline-start: 0.25rem;
140
+ transform: scaleX(var(--tui-inline));
141
+ border-image: repeating-linear-gradient(90deg, var(--tui-text-tertiary) 0 0.0625rem, transparent 0 0.125rem)
142
+ fill 0 / calc(100% - 1px) 0 0/0 100vw 0 0 repeat;
143
+ }
144
+ }
145
+ }
@@ -0,0 +1,78 @@
1
+ // iOS liquid glass, shared by AppBar, TabBar and SearchBar.
2
+ // Apply `.liquid-glass-vars()` at the glass scope root and `.liquid-glass-dark()`
3
+ // in the component's dark theme selector: the surface and the bevel read the
4
+ // values through inherited private properties, so the pieces can sit on any
5
+ // element or pseudo element below the root
6
+
7
+ @tui-glass-bevel-light: linear-gradient(
8
+ 319deg,
9
+ #fff 4%,
10
+ #fff 19%,
11
+ rgba(255, 255, 255, 0.12) 40%,
12
+ rgba(255, 255, 255, 0.02) 45%,
13
+ rgba(255, 255, 255, 0) 48%,
14
+ rgba(255, 255, 255, 0) 50%,
15
+ rgba(255, 255, 255, 0) 52%,
16
+ rgba(255, 255, 255, 0.02) 55%,
17
+ rgba(255, 255, 255, 0.12) 60%,
18
+ #fff 80%,
19
+ #fff 96%
20
+ );
21
+ @tui-glass-bevel-dark: linear-gradient(
22
+ 319deg,
23
+ rgba(255, 255, 255, 0.2),
24
+ rgba(255, 255, 255, 0.12) 19%,
25
+ rgba(255, 255, 255, 0.04) 40%,
26
+ rgba(255, 255, 255, 0.02) 45%,
27
+ rgba(255, 255, 255, 0) 48%,
28
+ rgba(255, 255, 255, 0) 50%,
29
+ rgba(255, 255, 255, 0) 52%,
30
+ rgba(255, 255, 255, 0.02) 55%,
31
+ rgba(255, 255, 255, 0.04) 60%,
32
+ rgba(255, 255, 255, 0.12) 80%,
33
+ rgba(255, 255, 255, 0.2) 96%
34
+ );
35
+
36
+ .liquid-glass-vars() {
37
+ --t-glass-background: rgba(255, 255, 255, 0.7);
38
+ --t-glass-glow: var(--tui-background-base);
39
+ --t-glass-filter: blur(0.25rem) saturate(6) brightness(1.05);
40
+ --t-glass-bevel: @tui-glass-bevel-light;
41
+ --t-glass-bevel-filter: none;
42
+ }
43
+
44
+ .liquid-glass-dark() {
45
+ --t-glass-background: rgba(88, 88, 88, 0.31);
46
+ --t-glass-glow: rgba(31, 31, 31, 0.8);
47
+ --t-glass-filter: blur(0.25rem) saturate(4);
48
+ --t-glass-bevel: @tui-glass-bevel-dark;
49
+ --t-glass-bevel-filter: brightness(0.6);
50
+ }
51
+
52
+ // Frosted translucent surface with an inner glow
53
+ .liquid-glass(@shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.09)) {
54
+ backdrop-filter: var(--t-glass-filter);
55
+ background-color: var(--t-glass-background);
56
+ box-shadow:
57
+ @shadow,
58
+ inset 0 0 0.75rem var(--t-glass-glow);
59
+ }
60
+
61
+ // The bevel of the glass: a gradient clipped to a 1px ring by subtracting the
62
+ // content box from the border box. Put it on a pseudo element of a positioned,
63
+ // rounded container
64
+ .liquid-glass-bevel() {
65
+ content: '';
66
+ position: absolute;
67
+ inset: 0;
68
+ box-sizing: border-box;
69
+ border-radius: inherit;
70
+ pointer-events: none;
71
+ padding: 1px;
72
+ background: var(--t-glass-bevel);
73
+ filter: var(--t-glass-bevel-filter);
74
+ mask-image: linear-gradient(#000 0 0), linear-gradient(#000 0 0);
75
+ mask-origin: content-box, border-box;
76
+ mask-clip: content-box, border-box;
77
+ mask-composite: exclude;
78
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@taiga-ui/styles",
3
- "version": "5.21.0-canary.d5429b6",
3
+ "version": "5.22.0",
4
4
  "description": "Framework-agnostic package with styles for Taiga UI",
5
5
  "repository": {
6
6
  "type": "git",
package/utils.less CHANGED
@@ -3,6 +3,7 @@
3
3
  @import 'mixins/miscellaneous.less';
4
4
  @import 'mixins/slider.less';
5
5
  @import 'mixins/appearance.less';
6
+ @import 'mixins/liquid-glass.less';
6
7
  @import 'mixins/hitbox.less';
7
8
  @import 'variables/duration.less';
8
9
  @import 'variables/media.less';