]> git.plutz.net Git - serve0/blob - templates/common.css.sh
cfc84e7420cb174e62957075c7e9a8cf7d28d58e
[serve0] / templates / common.css.sh
1 # Copyright 2014, 2015 Paul Hänsch
2 #
3 # This file is part of Serve0
4
5 # Serve0 is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU Affero General Public License as published by
7 # the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
9
10 # Serve0 is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 # GNU Affero General Public License for more details.
14
15 # You should have received a copy of the GNU Affero General Public License
16 # along with Serve0  If not, see <http://www.gnu.org/licenses/>. 
17
18 cat <<EOF
19
20 * {
21   -moz-box-sizing: border-box;
22   box-sizing: border-box;
23   -moz-transition: all .3s linear;
24   transition: all .3s linear;
25 }
26
27 body {
28   padding: 0;
29   margin: 0;
30   background-color: #000;
31   color: #DDD;
32 }
33 a { color: #EEE; }
34 legend, label, .label { font-weight: bold; }
35
36 input.tabhandle { display: none; }
37 .tabcontent { display: none; }
38 input.tabhandle:checked + label.tabhandle + .tabcontent { display: inline-block; }
39 input.tabhandle:checked + .tabcontent { display: inline-block; }
40
41 textarea {
42   display: block;
43   width: 100%;
44 }
45
46 .info {
47   margin: 0;
48   padding: 0 .25em;
49   background-color: #BBD;
50   color: #000;
51   border: #000 1px solid;
52 }
53 .info.tag {
54   line-height: 1.6em;
55   background-color: #DBB;
56 }
57
58 .pagination_nav {
59   display: inline;
60   border: none;
61   position: absolute;
62   right: 1em;
63   padding-top: .125em;
64 }
65
66 /* == Panels == */
67
68 .panel {
69   display: block;
70   width: 100%;
71   margin: 0;
72   padding: .25em 1em;
73   background-color: #333;
74   border-width: 1px;
75   border-style: none none solid none;
76 }
77
78 a.panel {
79   font-weight: bold;
80   display: inline;
81   border: none;
82 }
83
84 .panel .help { display: block;}
85
86 /* == Top Panel == */
87 .panel#advfilter {
88   position: absolute;
89   top: 0;
90 }
91
92 /* == Bottom Panels == */
93 .panel#preferences,
94 .panel#tagger,
95 .panel#foot {
96   position: fixed;
97   bottom: 0px;
98   min-height: 2em;
99   border-style: solid none none none;
100 }
101
102
103 /* == Switchable Panels == */
104
105 .panel#advfilter,
106 .panel#tagger,
107 .panel#preferences {
108   z-index: 1;
109   overflow: hidden;
110   min-height: 0; max-height: 0;
111   padding-top: 0; padding-bottom: 0;
112 }
113 .panel#advfilter:target,
114 .panel#tagger:target,
115 .panel#preferences:target {
116   max-height: 100%;
117   overflow-y: scroll;
118 }
119 .panel#advfilter:target{ padding-bottom: 1em; }
120
121
122 /* == Panel Switches == */
123
124 .panel#advfilter a.panel,
125 .panel#preferences a.panel,
126 .panel#tagger a.panel {
127   display: block;
128   border-style: none none solid none;
129   border-width: 1px;
130 }
131 .panel#preferences a.panel,
132 .panel#tagger a.panel {
133   border-style: solid none none none;
134   margin-top: .5em;
135 }
136
137
138 /* == Panel Elements == */
139
140 .panel#advfilter .quicklinks,
141 .panel#advfilter .filter,
142 .panel#tagger .newtag,
143 .panel#tagger input[type=submit],
144 .panel#preferences > * {
145   display: inline-block;
146   vertical-align: top;
147   margin-top: 1em;
148 }
149
150
151 /* == Advanced Filters == */
152
153 /* == Filter Boxes == */
154 #advfilter .filter {
155   border: solid 1px #FFF;
156   border-radius: .25em;
157   padding: .25em .5em;
158 }
159 #advfilter .filter .tabcontainer {
160   position: relative;
161   width: 16em;
162   font-weight:normal;
163 }
164 #advfilter .filter .tabcontainer input + .category.tabhandle {
165   display: block;
166   width: 50%;
167 }
168 #advfilter .filter .tabcontainer input:checked + .category.tabhandle {
169   background: #FFF;
170   color: #000;
171 }
172 #advfilter .filter .tabcontainer .category.tabcontent {
173   position: absolute;
174   top: 0; right: 0;
175   width: 50%;
176   height: 100%;
177   min-height: 4em;
178   border: 2px #FFF solid;
179   border-radius: 0 .25em .25em 0;
180 }
181
182 #advfilter > label.tabhandle {
183   text-align: right;
184   width: 4em;
185   margin-left: 4em;
186 }
187
188 /* == Dynamic Appearance of Boxes == */
189 .panel#advfilter > .tabhandle + label { display: none; }
190 .panel#advfilter > .tabhandle:checked + label + .tabcontent + .tabhandle + label { display: inline-block; }
191 .panel#advfilter > .tabhandle:checked + label + .tabcontent + .tabhandle:checked + label { display: none; }
192 .panel#advfilter > .tabhandle + label + .tabcontent {
193   display: inline-block;
194   overflow: hidden;
195   max-width: 0;
196   max-height: 0;
197   padding: 0;
198   border: none;
199 }
200 .panel#advfilter > .tabhandle:checked + label + .tabcontent {
201   max-width: 100%;
202   max-height: 100%;
203   padding: .25em .5em;
204   border: solid 1px #FFF;
205 }
206
207 #advfilter .filter.final {
208   width: 16em;
209   margin-left: 1em;
210 }
211
212 #advfilter .quicklinks {max-width: 100%;}
213 #advfilter .quicklinks * {
214   display: block;
215   word-wrap: break-word;
216 }
217
218 /* == Thumblist == */
219
220 #thumblist {
221   width: 100%;
222   padding: .5em 0 3em 0;
223   text-align: center;
224 }
225
226 #thumblist .thumb {
227   display: inline-block;
228   text-align: left;
229   width: 90%;
230   padding: 0 .5em;
231   margin: .5%;
232   margin-bottom: .75em;
233   vertical-align: top;
234   word-wrap: break-word;
235 }
236 @media (min-width: 460px){#thumblist .thumb{width: 48%;}}
237 @media (min-width: 620px){#thumblist .thumb{width: 32%;}}
238 @media (min-width: 1004px){#thumblist .thumb{width: 250px; margin: 2px;}}
239
240 #thumblist .thumb img {
241   width: 100%;
242 }
243 #thumblist .thumb h2 {
244   font-size: 1em;
245   font-weight: normal;
246   margin: 0;
247 }
248 #thumblist .thumb a {
249   display: block;
250 }
251 #thumblist .thumb a.alt {
252   display: inline-block;
253   margin-top: .3em;
254 }
255 #thumblist input {
256   margin: .75em .5em;
257 }
258
259 /* == Filelist == */
260
261 #thumblist .file {
262   color: #000;
263   display: inline-block;
264   text-align: left;
265   width: 90%;
266   padding: .5em .5em;
267   margin: .5%;
268   margin-bottom: .75em;
269   vertical-align: top;
270   word-wrap: break-word;
271 }
272 @media (min-width: 460px){#thumblist .file{width: 48%;}}
273 @media (min-width: 620px){#thumblist .file{width: 32%;}}
274 @media (min-width: 1004px){#thumblist .file{width: 250px; margin: 2px;}}
275
276 #thumblist .file.directory { background-color: #BBD; }
277 #thumblist .file.plain { background-color: #111; color: #777; }
278 #thumblist .file.video { background-color: #DBB; }
279
280 .panel#tagger .newtag select,
281 .panel#tagger .newtag .label{
282   display: block;
283   width: 10em;
284 }
285
286 .panel#preferences > fieldset {
287   border: solid 1px;
288   border-radius: .25em;
289 }
290 .panel#preferences > input { display: block; }
291
292 #videoview a.panel {
293   position: absolute;
294   right: 1em;
295   width: auto;
296   border: none;
297 }
298 #videoview .video {
299   display: inline-block;
300   width: 60%;
301   vertical-align: top;
302 }
303 #videoview .video * {
304   display: block;
305 }
306 #videoview .videoinfo {
307   width: 39%;
308   margin-top: 2em;
309 }
310 #videoview .videoinfo h2 {
311   display: inline;
312
313 #videoview .videoinfo .meta:after {
314   content: "\A";
315   white-space: pre;
316 }
317 #videoview .videoinfo .label {
318   display: block;
319   margin-top: 1em;
320 }
321 #videoview .videoinfo .info.description {
322   display: block;
323   background-color: #DDF;
324 }
325 #videoview .videoinfo .edit {
326   width: 100%
327 }
328 EOF
329
330 # vi:set filetype=css: