Skip to content

Commit cec96bb

Browse files
committed
feat: add support for vertical resizing in design mode
1 parent 733a86c commit cec96bb

1 file changed

Lines changed: 33 additions & 6 deletions

File tree

src/extensionsIntegrated/Phoenix-live-preview/live-preview.css

Lines changed: 33 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
}
5252

5353
.frame-container.responsive-viewport {
54+
position: relative;
5455
justify-content: center;
5556
align-items: stretch;
5657
background: #1a1a1e;
@@ -61,11 +62,8 @@
6162
}
6263

6364
.responsive-handle {
64-
width: 6px;
65-
cursor: ew-resize;
6665
background: transparent;
6766
flex-shrink: 0;
68-
position: relative;
6967
z-index: 5;
7068
transition: background 0.15s;
7169
}
@@ -75,7 +73,13 @@
7573
background: rgba(66, 133, 244, 0.5);
7674
}
7775

78-
.responsive-handle::after {
76+
.responsive-handle-horizontal {
77+
width: 6px;
78+
cursor: ew-resize;
79+
position: relative;
80+
}
81+
82+
.responsive-handle-horizontal::after {
7983
content: '';
8084
position: absolute;
8185
top: 50%;
@@ -87,8 +91,31 @@
8791
background: rgba(255, 255, 255, 0.25);
8892
}
8993

90-
.responsive-handle:hover::after,
91-
.responsive-handle.dragging::after {
94+
.responsive-handle-horizontal:hover::after,
95+
.responsive-handle-horizontal.dragging::after {
96+
background: rgba(255, 255, 255, 0.6);
97+
}
98+
99+
.responsive-handle-vertical {
100+
position: absolute;
101+
height: 6px;
102+
cursor: ns-resize;
103+
}
104+
105+
.responsive-handle-vertical::after {
106+
content: '';
107+
position: absolute;
108+
top: 50%;
109+
left: 50%;
110+
transform: translate(-50%, -50%);
111+
width: 24px;
112+
height: 2px;
113+
border-radius: 1px;
114+
background: rgba(255, 255, 255, 0.25);
115+
}
116+
117+
.responsive-handle-vertical:hover::after,
118+
.responsive-handle-vertical.dragging::after {
92119
background: rgba(255, 255, 255, 0.6);
93120
}
94121

0 commit comments

Comments
 (0)