]> git.plutz.net Git - confetti/blob - templates/prescriptions.css.sh
issuer field on prescription document
[confetti] / templates / prescriptions.css.sh
1 # /*
2 # Copyright 2016 Paul Hänsch
3 #
4 # This file is part of Confetti.
5
6 # Confetti is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU Affero General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
10
11 # Confetti is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU Affero General Public License for more details.
15
16 # You should have received a copy of the GNU Affero General Public License
17 # along with Confetti.  If not, see <http://www.gnu.org/licenses/>. 
18
19 . ${0%/*}/cards.css.sh
20
21 cat <<EOF
22 /**/
23 body {padding-bottom: 3em; }
24
25 .trailbtn { display: none; }
26 .trailbtn + .trailbox { display: none; }
27 .trailbtn:checked + .trailbox { display: inline-block; }
28 .trailbtn:checked + .trailbox + .trailbtn { display: block; }
29 .trailbtn:checked + .trailbox + .trailbtn:before {
30    display: block; content: '+';
31    width: 3ex; text-align: center;
32    margin-top: .25em; padding: .25em 0;
33    background-color: #FFF;
34    border-width: 1px; border-style: solid;
35 }
36 .trailbtn:checked + .trailbox + .trailbtn:checked,
37 .trailbtn:checked { display: none; }
38
39 .prescription {
40   display: inline-block;
41   width: 96%; max-width: 460px;
42   color: #800;
43   background-color: #DDD;
44   margin: 1em -1% 0 2%; padding: 0;
45   border: 1px solid #888;
46   overflow: hidden;
47   vertical-align: top;
48 }
49 form.prescription { padding-top: 1ex;}
50
51 .newprescription {
52   display: block;
53   margin: 0 2em; padding: .5ex 2ex;
54   background-color: #CFF;
55   border: 1px solid #888;
56   border-radius: 0 0 1ex 1ex;
57 }
58
59 .prescription * {
60   display: inline-block;
61   font-size: 1em;
62   line-height: 1em;
63   margin: 0; padding: 0;
64 }
65 .prescription label {
66   padding-left: .5ex;
67   font-size: .75em;
68 }
69
70 .prescription fieldset {
71   display: inline-block;
72   margin: 0; padding: 1ex;
73   margin-right: -.625ex;
74   border: none;
75   vertical-align: top;
76 }
77 .prescription fieldset br { display: none;}
78
79 .prescription span,
80 .prescription input,
81 .prescription textarea {
82   height: 1.5em;
83   border: 1px solid #800;
84   padding: .25ex;
85   background-color: #FFF;
86 }
87 .prescription span {
88   background-color: #EEE;
89   padding: .5ex .25ex;
90   white-space: pre-wrap;
91   font-size: .75em;
92   overflow: hidden;
93 }
94
95 .prescription input[type=checkbox],
96 .prescription input[type=radio] { display: none;}
97
98 .prescription label.checkbox,
99 .prescription label.radio,
100 .prescription input[type=checkbox] + label,
101 .prescription input[type=radio] + label { padding-left: 1.25em; font-size: 1em;}
102
103 .prescription label.checkbox:before,
104 .prescription label.radio:before,
105 .prescription input[type=checkbox] + label:before,
106 .prescription input[type=radio] + label:before {
107   display: inline-block;
108   position: absolute;
109   margin-left: -1.25em;
110   width: .75em; height: .75em;
111   background-color: #FFF;
112   border: 1px solid #800;
113   content: ' ';
114 }
115 .prescription label.radio:before,
116 .prescription input[type=radio] + label:before { border-radius: .5em;}
117 .prescription label.checkbox.checked:before,
118 .prescription label.radio.checked:before,
119 .prescription input[type=checkbox]:checked + label:before,
120 .prescription input[type=radio]:checked + label:before { content: "\2713";}
121
122 .prescription a.button,
123 .prescription input[type=submit],
124 .prescription button {
125   height: 1.5em;
126   color: #FFF;
127   background-color: #800;
128   text-align: center;
129   text-decoration: none;
130   margin: 0; padding: .125em 0 0 0;
131   border: none;
132 }
133 .prescription a.button {padding: .5ex;}
134
135 /* ======== Specific ========== */
136
137 .prescription label.presctype,
138 .prescription input[name=presctype] + label {
139   font-size: medium;
140   width: 22%;
141   margin: 0; margin-right: -.5ex;
142   vertical-align: top;
143   padding: .25em .5ex .25em 3ex;
144   height: 2.5em;
145   border-top: 1px solid #DDD;
146 }
147 .prescription label.presctype {
148   text-align: right;
149   font-weight: bold;
150   font-size: .875em;
151   padding-right: 1ex;
152   padding-left: 0;
153 }
154
155 input[name=presctype][value\$=private]:checked  ~ fieldset,
156   input[name=presctype][value\$=private] + label,
157   .prescription.private { background-color: #CFC;}
158 input[name=presctype][value\$=selfpaid]:checked  ~ fieldset,
159   input[name=presctype][value\$=selfpaid]         + label,
160   .prescription.selfpaid { background-color: #FFC;}
161 input[name=presctype][value=doctor_compulsory]:checked  ~ fieldset,
162   input[name=presctype][value=doctor_compulsory]  + label,
163   .prescription.doctor.compulsory { background-color: #CFF;}
164 input[name=presctype][value=dentist_compulsory]:checked  ~ fieldset,
165   input[name=presctype][value=dentist_compulsory] + label,
166   .prescription.dentist.compulsory { background-color: #FCC;}
167 input[name=presctype][value^=altpractition]:checked  ~ fieldset,
168   input[name=presctype][value^=altpractition]     + label,
169   .prescription.altpractition { background-color: #FCF;}
170
171 .prescription .baseinfo { width: 60%;}
172
173   .baseinfo label[for=insurance],
174   .baseinfo #insurance { width: 100%; }
175  
176   .baseinfo label[for=name],
177   .baseinfo #name { width: 65%; margin-right: -.875ex;}
178   .baseinfo #name { height: 4em; }
179  
180   .baseinfo label[for=bday],
181   .baseinfo #bday { width: 35%;}
182   .baseinfo #bday { height: 4em; text-align: center; vertical-align: top;}
183  
184   .baseinfo label[for=date],
185   .baseinfo #date { width: 34%; margin-left: 65%;}
186   .baseinfo #date { text-align: right;}
187
188 .prescription .misc { width: 40%; }
189
190   .misc h1 {
191     font-size: 1.25em;
192     font-weight: bold;
193     width: 100%;
194   }
195   .misc label[for=addcontrib],
196   .misc label[for=contribconfirm] {width: 100%;}
197   .misc #addcontrib,
198   .misc #contribconfirm {width: 100%; text-align: right;}
199
200 .prescription label[for=prescreviewed] {
201   margin-left: 1ex;
202   font-weight: bold;
203   text-decoration: underline;
204   background-color: #FCC;
205 }
206 .prescription label[for=prescreviewed].checked,
207 .prescription :checked + label[for=prescreviewed] {
208   font-weight: normal;
209   text-decoration: none;
210   background-color: transparent;
211 }
212
213 .prescription .catalogue { width: 100%; }
214
215   .catalogue h2:nth-of-type(1) {
216     font-weight: bold;
217     width: 100%;
218     margin-bottom: .25em;
219   }
220   .catalogue label {
221     display: inline-block;
222     width: 33%;
223     margin-right: -.625ex;
224     margin-top: .25em;
225     vertical-align: top;
226   }
227   .catalogue label[for=presccontinual] { margin-right: 33%;}
228
229 .prescription .description { width: 100%; position: relative;}
230   .description * { margin-right: -.625ex; vertical-align: top; }
231   .description label {vertical-align: bottom;}
232
233   .description label[for=quantity] { width: 20%;}
234   .description label[for=remidy] { width: 60%; }
235   .description label[for=quantity_weekly] { width: 20%;}
236   .description #quantity,
237   .description .quantity { width: 20%;  height: 3em; text-align: center;}
238   .description #remidy,
239   .description .remidy { width: 60%; height: 3em;}
240   .description #quantity_weekly,
241   .description .quantity_weekly { width: 20%; height: 3em; text-align: center;}
242
243   .description .indicator_codes {display: inline-block; width: 20%; padding: 0; padding-top: 1.5ex;}
244   .description label[for=indicator],
245   .description label[for=icd10] { display: block; width: 100%;}
246   .description #icd10,
247   .description #indicator {width: 100%; text-align: right;}
248
249   .description .indicator_reading { display: inline-block; width: 78%; padding: 0; padding-top: 1.5ex;  margin-left: 2%;}
250   .description label[for=indicator_reading],
251   .description #indicator_reading { width: 100%; display: block;}
252   .description #indicator_reading { height: 4em;}
253
254   .description .issuer { display: inline-block; width: 50%; padding: 0; padding-top: 0; margin-left: 50%;}
255   .description .issuer label:first-of-type {
256      display: block;
257      position: relative;
258      width: 50%; left: -50%; top: 2.25em;
259      font-size: 1em;
260      text-align: right;
261      padding-right: 1ex;
262    }
263   .description .issuer input[type=radio] + label:before { content: none; }
264   .description .issuer input[type=radio] { display: none; }
265   .description .issuer input[type=radio] + label {
266     display: inline-block;
267     width: 50%;
268     padding: .25ex 0; margin: 0;
269     text-align: center;
270     border: 1px solid black;
271   }
272   .description .issuer input[type=radio]:checked + label {
273     font-weight: bold;
274     background-color: #FFF;
275     border-width: 1px;
276     border-bottom: 1px solid #FFF;
277   }
278   .description .issuer input[type=radio] + label + input + label + select,
279   .description .issuer input[type=radio] + label + select + input { display: none; }
280   .description .issuer input[type=radio]:checked + label + input + label + select,
281   .description .issuer input[type=radio]:checked + label + select + input {
282     display: block; width: 100%;
283     border: 1px solid black;
284     background-color: #FFF;
285     border-width: 0 1px 1px 1px;
286     padding: .25ex .5ex;
287     margin-top: -1px;
288   }
289   .description .issuer input[type=radio]:checked + label + input + label + select option { display: block;}
290   .description span#issuer { width: 100%; height: 3em; padding: 1ex 2ex;}
291
292 .prescription .controls { width: 100%; }
293   .controls a.button,
294   .controls button[value=save],
295   .controls button[value=cancel],
296   .controls button[value=delete] { width: 25%;}
297
298 EOF
299
300 # vi:set filetype=css: