Commit | Line | Data |
---|---|---|
dc9d5d64 RK |
1 | /* This Source Code Form is subject to the terms of the Mozilla Public |
2 | * License, v. 2.0. If a copy of the MPL was not distributed with this | |
3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/ */ | |
4 | ||
dc9d5d64 RK |
5 | #sidebar-panel-layoutview { |
6 | display: block; | |
7 | overflow: auto; | |
1ad21b1f | 8 | height: 100%; |
dc9d5d64 RK |
9 | } |
10 | ||
6f751fd1 RK |
11 | #layout-wrapper { |
12 | /* The sidebar-panel is not focusable, this wrapper will catch click events in | |
13 | all the empty area around the layout-container */ | |
14 | height: 100%; | |
15 | } | |
16 | ||
dc9d5d64 RK |
17 | #layout-container { |
18 | /* The view will grow bigger as the window gets resized, until 400px */ | |
19 | max-width: 400px; | |
20 | margin: 0px auto; | |
21 | padding: 0; | |
22 | /* "Contain" the absolutely positioned #layout-main element */ | |
23 | position: relative; | |
24 | } | |
25 | ||
26 | /* Header: contains the position and size of the element */ | |
27 | ||
dc9d5d64 RK |
28 | #layout-header { |
29 | box-sizing: border-box; | |
30 | width: 100%; | |
31 | padding: 4px 14px; | |
32 | display: -moz-box; | |
33 | vertical-align: top; | |
34 | } | |
35 | ||
dae45075 | 36 | #layout-header:dir(rtl) { |
dc9d5d64 RK |
37 | -moz-box-direction: reverse; |
38 | } | |
39 | ||
dc9d5d64 RK |
40 | #layout-header > span { |
41 | display: -moz-box; | |
42 | } | |
43 | ||
dc9d5d64 RK |
44 | #layout-element-size { |
45 | -moz-box-flex: 1; | |
46 | } | |
47 | ||
dae45075 | 48 | #layout-element-size:dir(rtl) { |
dc9d5d64 RK |
49 | -moz-box-pack: end; |
50 | } | |
51 | ||
52 | @media (max-height: 250px) { | |
dc9d5d64 RK |
53 | #layout-header { |
54 | padding-top: 0; | |
55 | padding-bottom: 0; | |
56 | margin-top: 10px; | |
57 | margin-bottom: 8px; | |
58 | } | |
59 | } | |
60 | ||
8cbd10f2 RK |
61 | #layout-geometry-editor { |
62 | visibility: hidden; | |
63 | } | |
64 | ||
65 | #layout-geometry-editor::before { | |
66 | background: url(images/geometry-editor.svg) no-repeat center center / 16px 16px; | |
67 | } | |
68 | ||
dc9d5d64 RK |
69 | /* Main: contains the box-model regions */ |
70 | ||
dc9d5d64 | 71 | #layout-main { |
8cbd10f2 | 72 | position: relative; |
dc9d5d64 RK |
73 | box-sizing: border-box; |
74 | /* The regions are semi-transparent, so the white background is partly | |
75 | visible */ | |
76 | background-color: #FF9F00; | |
77 | color: var(--theme-selection-color); | |
78 | /* Make sure there is some space between the window's edges and the regions */ | |
1ad21b1f | 79 | margin: 0 14px 4px 14px; |
dc9d5d64 RK |
80 | width: calc(100% - 2 * 14px); |
81 | } | |
82 | ||
dc9d5d64 RK |
83 | .layout-margin, |
84 | .layout-size { | |
85 | /* color: var(--theme-highlight-blue); */ | |
86 | } | |
87 | ||
88 | /* Regions are 3 nested elements with wide borders and outlines */ | |
89 | ||
dc9d5d64 | 90 | #layout-content { |
1ad21b1f | 91 | height: 18px; |
dc9d5d64 RK |
92 | } |
93 | ||
dc9d5d64 RK |
94 | #layout-margins, |
95 | #layout-borders, | |
96 | #layout-padding { | |
f36031bd | 97 | border-color: var(--theme-splitter-color); |
1ad21b1f | 98 | border-width: 18px; |
dc9d5d64 | 99 | border-style: solid; |
f36031bd | 100 | outline: dotted 1px var(--theme-splitter-color); |
dc9d5d64 RK |
101 | } |
102 | ||
dc9d5d64 RK |
103 | #layout-margins { |
104 | /* This opacity applies to all of the regions, since they are nested */ | |
105 | opacity: .8; | |
106 | } | |
107 | ||
dc9d5d64 RK |
108 | /* Regions colors */ |
109 | ||
dc9d5d64 RK |
110 | #layout-margins { |
111 | border-color: #FFCF00; | |
112 | } | |
113 | ||
dc9d5d64 RK |
114 | #layout-borders { |
115 | border-color: #A09090; | |
116 | } | |
117 | ||
dc9d5d64 RK |
118 | #layout-padding { |
119 | border-color: #8050B0; | |
120 | } | |
121 | ||
dc9d5d64 RK |
122 | #layout-content { |
123 | background-color: #008484; | |
124 | } | |
dc9d5d64 | 125 | |
dc9d5d64 RK |
126 | /* Editable region sizes are contained in absolutely positioned <p> */ |
127 | ||
dc9d5d64 RK |
128 | #layout-main > p { |
129 | position: absolute; | |
130 | pointer-events: none; | |
131 | margin: 0; | |
132 | text-align: center; | |
133 | } | |
134 | ||
dc9d5d64 RK |
135 | #layout-main > p > span, |
136 | #layout-main > p > input { | |
137 | vertical-align: middle; | |
138 | pointer-events: auto; | |
139 | } | |
140 | ||
141 | /* Coordinates for the region sizes */ | |
142 | ||
dc9d5d64 RK |
143 | .layout-top, |
144 | .layout-bottom { | |
145 | width: calc(100% - 2px); | |
146 | text-align: center; | |
147 | } | |
148 | ||
dc9d5d64 | 149 | .layout-padding.layout-top { |
1ad21b1f | 150 | top: 37px; |
dc9d5d64 RK |
151 | } |
152 | ||
dc9d5d64 | 153 | .layout-padding.layout-bottom { |
1ad21b1f | 154 | bottom: 38px; |
dc9d5d64 RK |
155 | } |
156 | ||
dc9d5d64 | 157 | .layout-border.layout-top { |
1ad21b1f | 158 | top: 19px; |
dc9d5d64 RK |
159 | } |
160 | ||
dc9d5d64 | 161 | .layout-border.layout-bottom { |
1ad21b1f | 162 | bottom: 20px; |
dc9d5d64 RK |
163 | } |
164 | ||
dc9d5d64 | 165 | .layout-margin.layout-top { |
1ad21b1f | 166 | top: 1px; |
dc9d5d64 RK |
167 | } |
168 | ||
dc9d5d64 | 169 | .layout-margin.layout-bottom { |
1ad21b1f | 170 | bottom: 2px; |
dc9d5d64 RK |
171 | } |
172 | ||
dc9d5d64 RK |
173 | .layout-size, |
174 | .layout-margin.layout-left, | |
175 | .layout-margin.layout-right, | |
176 | .layout-border.layout-left, | |
177 | .layout-border.layout-right, | |
178 | .layout-padding.layout-left, | |
179 | .layout-padding.layout-right { | |
180 | top: 22px; | |
1ad21b1f | 181 | line-height: 88px; |
dc9d5d64 RK |
182 | } |
183 | ||
dc9d5d64 RK |
184 | .layout-size { |
185 | width: calc(100% - 2px); | |
186 | } | |
187 | ||
dc9d5d64 RK |
188 | .layout-margin.layout-right, |
189 | .layout-margin.layout-left, | |
190 | .layout-border.layout-left, | |
191 | .layout-border.layout-right, | |
192 | .layout-padding.layout-right, | |
193 | .layout-padding.layout-left { | |
1ad21b1f | 194 | width: 21px; |
dc9d5d64 RK |
195 | } |
196 | ||
dc9d5d64 | 197 | .layout-padding.layout-left { |
1ad21b1f | 198 | left: 35px; |
dc9d5d64 RK |
199 | } |
200 | ||
dc9d5d64 | 201 | .layout-padding.layout-right { |
1ad21b1f | 202 | right: 35px; |
dc9d5d64 RK |
203 | } |
204 | ||
dc9d5d64 | 205 | .layout-border.layout-left { |
1ad21b1f | 206 | left: 16px; |
dc9d5d64 RK |
207 | } |
208 | ||
dc9d5d64 | 209 | .layout-border.layout-right { |
1ad21b1f | 210 | right: 17px; |
dc9d5d64 RK |
211 | } |
212 | ||
dc9d5d64 RK |
213 | .layout-margin.layout-right { |
214 | right: 0; | |
215 | } | |
216 | ||
dc9d5d64 RK |
217 | .layout-margin.layout-left { |
218 | left: 0; | |
219 | } | |
220 | ||
dc9d5d64 RK |
221 | .layout-rotate.layout-left:not(.layout-editing) { |
222 | transform: rotate(-90deg); | |
223 | } | |
224 | ||
dc9d5d64 RK |
225 | .layout-rotate.layout-right:not(.layout-editing) { |
226 | transform: rotate(90deg); | |
227 | } | |
228 | ||
dc9d5d64 RK |
229 | /* Legend, displayed inside regions */ |
230 | ||
dc9d5d64 RK |
231 | .layout-legend { |
232 | position: absolute; | |
1ad21b1f | 233 | margin: 2px 6px; |
dc9d5d64 RK |
234 | z-index: 1; |
235 | } | |
236 | ||
dc9d5d64 RK |
237 | .layout-legend[data-box="margin"] { |
238 | color: #000000; /*var(--theme-highlight-blue);*/ | |
239 | } | |
240 | ||
dc9d5d64 RK |
241 | /* Editable fields */ |
242 | ||
dc9d5d64 RK |
243 | .layout-editable { |
244 | border: 1px dashed transparent; | |
245 | -moz-user-select: text; | |
246 | } | |
247 | ||
dc9d5d64 RK |
248 | .layout-editable:hover { |
249 | border-bottom-color: #E7ADE7; | |
250 | } | |
251 | ||
252 | .styleinspector-propertyeditor { | |
253 | border: 1px solid #008484; | |
254 | padding: 0; | |
255 | } | |
256 | ||
257 | /* Make sure the content size doesn't appear as editable like the other sizes */ | |
258 | ||
dc9d5d64 RK |
259 | .layout-size > span { |
260 | cursor: default; | |
261 | } | |
262 | ||
8cbd10f2 | 263 | /* Layout info: contains the position and size of the element */ |
dc9d5d64 | 264 | |
8cbd10f2 RK |
265 | #layout-element-size { |
266 | flex: 1; | |
dc9d5d64 RK |
267 | } |
268 | ||
269 | #layout-position-group { | |
270 | display: flex; | |
271 | align-items: center; | |
272 | } |