vira 31.6.0 → 31.6.1
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.
|
@@ -43,13 +43,15 @@ export const ViraOverflowSwitch = defineViraElement()({
|
|
|
43
43
|
|
|
44
44
|
/**
|
|
45
45
|
* When the large content overflows, hide it but keep it in layout so we can measure it.
|
|
46
|
-
* The small content is then shown instead.
|
|
46
|
+
* The small content is then shown instead. Using height: 0 + overflow: hidden instead of
|
|
47
|
+
* position: absolute keeps the large element in flow so the host's width still reflects
|
|
48
|
+
* the available container space, allowing the ResizeObserver to detect when there is
|
|
49
|
+
* enough room to un-collapse.
|
|
47
50
|
*/
|
|
48
51
|
${hostClasses['vira-overflow-switch-show-small'].selector} .large {
|
|
49
52
|
visibility: hidden;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
left: 0;
|
|
53
|
+
height: 0;
|
|
54
|
+
overflow: hidden;
|
|
53
55
|
}
|
|
54
56
|
|
|
55
57
|
${hostClasses['vira-overflow-switch-show-small'].selector} .small {
|