@thalassic/themes 22.17.0 → 22.17.2
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/package.json
CHANGED
|
@@ -4,4 +4,31 @@
|
|
|
4
4
|
padding-block: var(--tls-textarea-padding-block);
|
|
5
5
|
|
|
6
6
|
font-family: inherit;
|
|
7
|
+
|
|
8
|
+
resize: var(--tls-textarea-resize);
|
|
9
|
+
|
|
10
|
+
// Autosizing is driven by `field-sizing: content`, which sizes the control to
|
|
11
|
+
// its content and in doing so makes the `rows` attribute inert. Row bounds are
|
|
12
|
+
// therefore restated as heights: a row is one line box, plus the padding and
|
|
13
|
+
// border that `box-sizing: border-box` counts toward a declared height.
|
|
14
|
+
&--autosize {
|
|
15
|
+
--tls-textarea-block-frame: calc(
|
|
16
|
+
2 * var(--tls-textarea-padding-block) + 2 * var(--tls-form-control-border-width)
|
|
17
|
+
);
|
|
18
|
+
|
|
19
|
+
min-height: calc(var(--tls-textarea-rows) * 1lh + var(--tls-textarea-block-frame));
|
|
20
|
+
field-sizing: content;
|
|
21
|
+
|
|
22
|
+
resize: none;
|
|
23
|
+
|
|
24
|
+
// Where `field-sizing` is unsupported the height stays fixed at the `rows`
|
|
25
|
+
// attribute, leaving the manual handle as the only way to resize.
|
|
26
|
+
@supports not (field-sizing: content) {
|
|
27
|
+
resize: var(--tls-textarea-resize);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
&--autosize-capped {
|
|
32
|
+
max-height: calc(var(--tls-textarea-max-rows) * 1lh + var(--tls-textarea-block-frame));
|
|
33
|
+
}
|
|
7
34
|
}
|