Skip to content

Commit 41178ce

Browse files
committed
Fix: sticky – .row auf flexbox umschalten, float entfernen
position:sticky funktioniert nicht auf floated Elementen (Bootstrap 3). .row:has(#rex-lp-panel) bekommt display:flex + align-items:flex-start, float:none auf den Spalten – sticky auf .col-lg-4 greift jetzt.
1 parent e65ac5f commit 41178ce

File tree

1 file changed

+16
-7
lines changed

1 file changed

+16
-7
lines changed

assets/css/live_preview.css

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,17 +44,26 @@
4444

4545
/* ---- Sidebar sticky ---- */
4646
/*
47-
* Bootstrap 3 nutzt Floats: sticky muss auf der .col-lg-4 selbst sitzen,
48-
* nicht auf dem Kind-Container. :has() stellt sicher, dass nur die Column
49-
* mit dem Live-Preview-Panel betroffen ist.
50-
* height: fit-content verhindert, dass die Float-Column die volle Row-Höhe
51-
* einnimmt – sonst hat sticky keinen Scrollspiclraum mehr.
47+
* Bootstrap 3 setzt float:left auf .col-lg-4 – sticky funktioniert NICHT
48+
* auf gefloateten Elementen (CSS-Grundregel).
49+
* Lösung: .row auf display:flex umschalten + float entfernen.
50+
* Die Spaltenbreiten (66.66% / 33.33%) bleiben via Bootstrap-CSS erhalten.
5251
*/
52+
.row:has(.col-lg-4 #rex-lp-panel) {
53+
display: flex;
54+
align-items: flex-start;
55+
flex-wrap: wrap;
56+
}
57+
58+
.row:has(.col-lg-4 #rex-lp-panel) > .col-lg-8,
59+
.row:has(.col-lg-4 #rex-lp-panel) > .col-lg-4 {
60+
float: none;
61+
}
62+
5363
.col-lg-4:has(#rex-lp-panel) {
5464
position: sticky;
5565
top: 68px; /* REDAXO-Navbar-Höhe ~60px + 8px Puffer */
56-
height: fit-content;
57-
align-self: flex-start; /* Sicherheitsnetz falls Row per Flexbox */
66+
align-self: flex-start;
5867
z-index: 10;
5968
}
6069

0 commit comments

Comments
 (0)