]> git.plutz.net Git - confetti/blob - templates/prescriptions.css.sh
scrolling fixes for firefox, different stroke-width for erazer
[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%/*}/attendees.css.sh
20
21 cat <<EOF
22 /**/
23
24 .prescription {
25   display: inline-block;
26   width: 96%; max-width: 460px;
27   color: #800;
28   background-color: #DDD;
29   margin: 1em -1% 0 2%; padding: 0;
30   border: 1px solid #888;
31   overflow: hidden;
32 }
33 form.prescription { padding-top: 1ex;}
34
35 .newprescription {
36   display: block;
37   margin: 0 2em; padding: .5ex 2ex;
38   background-color: #CFF;
39   border: 1px solid #888;
40   border-radius: 0 0 1ex 1ex;
41 }
42
43 .prescription * {
44   display: inline-block;
45   font-size: 1em;
46   line-height: 1em;
47   margin: 0; padding: 0;
48 }
49 .prescription label {
50   padding-left: .5ex;
51   font-size: .75em;
52 }
53
54 .prescription fieldset {
55   display: inline-block;
56   margin: 0; padding: 1ex;
57   margin-right: -.625ex;
58   border: none;
59   vertical-align: top;
60 }
61 .prescription fieldset br { display: none;}
62
63 .prescription span,
64 .prescription input,
65 .prescription textarea {
66   height: 1.5em;
67   border: 1px solid #800;
68   padding: .25ex;
69   background-color: #FFF;
70 }
71 .prescription span {
72   background-color: #EEE;
73   padding: .5ex .25ex;
74   white-space: pre-wrap;
75   font-size: .75em;
76   overflow: hidden;
77 }
78
79 .prescription input[type=checkbox],
80 .prescription input[type=radio] { display: none;}
81
82 .prescription label.checkbox,
83 .prescription label.radio,
84 .prescription input[type=checkbox] + label,
85 .prescription input[type=radio] + label { padding-left: 1.25em; font-size: 1em;}
86
87 .prescription label.checkbox:before,
88 .prescription label.radio:before,
89 .prescription input[type=checkbox] + label:before,
90 .prescription input[type=radio] + label:before {
91   display: inline-block;
92   position: absolute;
93   margin-left: -1.25em;
94   width: .75em; height: .75em;
95   background-color: #FFF;
96   border: 1px solid #800;
97   content: ' ';
98 }
99 .prescription label.radio:before,
100 .prescription input[type=radio] + label:before { border-radius: .5em;}
101 .prescription label.checkbox.checked:before,
102 .prescription label.radio.checked:before,
103 .prescription input[type=checkbox]:checked + label:before,
104 .prescription input[type=radio]:checked + label:before { content: "\2713";}
105
106 .prescription a.button,
107 .prescription input[type=submit],
108 .prescription button {
109   height: 1.5em;
110   color: #FFF;
111   background-color: #800;
112   text-align: center;
113   text-decoration: none;
114   margin: 0; padding: .125em 0 0 0;
115   border: none;
116 }
117 .prescription a.button {padding: .5ex;}
118
119 /* ======== Specific ========== */
120
121 .prescription label.presctype,
122 .prescription input[name=presctype] + label {
123   font-size: medium;
124   width: 22%;
125   margin: 0; margin-right: -.75ex;
126   vertical-align: bottom;
127   padding: .125em .5ex .25em 3ex;
128 }
129 .prescription label.presctype {
130   text-align: right;
131   font-weight: bold;
132   padding-right: 1ex;
133   padding-left: 0;
134 }
135
136 input[name=presctype][value\$=private]:checked  ~ fieldset,
137   input[name=presctype][value\$=private] + label,
138   .prescription.private { background-color: #CFC;}
139 input[name=presctype][value\$=selfpaid]:checked  ~ fieldset,
140   input[name=presctype][value\$=selfpaid]         + label,
141   .prescription.selfpaid { background-color: #FFC;}
142 input[name=presctype][value=doctor_compulsory]:checked  ~ fieldset,
143   input[name=presctype][value=doctor_compulsory]  + label,
144   .prescription.doctor.compulsory { background-color: #CFF;}
145 input[name=presctype][value=dentist_compulsory]:checked  ~ fieldset,
146   input[name=presctype][value=dentist_compulsory] + label,
147   .prescription.dentist.compulsory { background-color: #FCC;}
148 input[name=presctype][value^=altpractition]:checked  ~ fieldset,
149   input[name=presctype][value^=altpractition]     + label,
150   .prescription.altpractition { background-color: #FCF;}
151
152 .prescription .baseinfo { width: 60%;}
153
154   .baseinfo label[for=insurance],
155   .baseinfo #insurance { width: 100%; }
156  
157   .baseinfo label[for=name],
158   .baseinfo #name { width: 65%; margin-right: -.875ex;}
159   .baseinfo #name { height: 4em; }
160  
161   .baseinfo label[for=bday],
162   .baseinfo #bday { width: 35%;}
163   .baseinfo #bday { height: 4em; text-align: center; vertical-align: top;}
164  
165   .baseinfo label[for=date],
166   .baseinfo #date { width: 34%; margin-left: 65%;}
167   .baseinfo #date { text-align: right;}
168
169 .prescription .misc { width: 40%; }
170
171   .misc h1 {
172     font-size: 1.25em;
173     font-weight: bold;
174     width: 100%;
175   }
176   .misc label[for=addcontrib],
177   .misc label[for=contribconfirm] {width: 100%;}
178   .misc #addcontrib,
179   .misc #contribconfirm {width: 100%; text-align: right;}
180
181 .prescription label[for=prescreviewed] {
182   margin-left: 1ex;
183   font-weight: bold;
184   text-decoration: underline;
185   background-color: #FCC;
186 }
187 .prescription label[for=prescreviewed].checked,
188 .prescription :checked + label[for=prescreviewed] {
189   font-weight: normal;
190   text-decoration: none;
191   background-color: transparent;
192 }
193
194 .prescription .catalogue { width: 100%; }
195
196   .catalogue h2:nth-of-type(1) {
197     font-weight: bold;
198     width: 100%;
199     margin-bottom: .25em;
200   }
201   .catalogue label {
202     display: inline-block;
203     width: 33%;
204     margin-right: -.625ex;
205     margin-top: .25em;
206     vertical-align: top;
207   }
208   .catalogue label[for=presccontinual] { margin-right: 33%;}
209
210 .prescription .description { width: 100%; position: relative;}
211   .description * { margin-right: -.625ex; vertical-align: top; }
212   .description label {vertical-align: bottom;}
213   .description label[for=quantity1],
214   .description label[for=remidy1],
215   .description label[for=quantity_weekly1] {display: none;}
216
217   .description label[for=quantity] { width: 20%;}
218   .description #quantity,
219   .description #quantity1 { width: 20%;  height: 3em; text-align: center;}
220   .description label[for=remidy] { width: 60%; }
221   .description #remidy,
222   .description #remidy1 { width: 60%; height: 3em;}
223   .description label[for=quantity_weekly] { width: 20%;}
224   .description #quantity_weekly,
225   .description #quantity_weekly1 { width: 20%; height: 3em; text-align: center;}
226
227   .description .indicator_codes {display: inline-block; width: 20%; padding: 0; padding-top: 1.5ex;}
228   .description label[for=indicator],
229   .description label[for=icd10] { display: block; width: 100%;}
230   .description #icd10,
231   .description #indicator {width: 100%; text-align: right;}
232
233   .description .indicator_reading { display: inline-block; width: 78%; padding: 0; padding-top: 1.5ex;  margin-left: 2%;}
234   .description label[for=indicator_reading],
235   .description #indicator_reading { width: 100%; display: block;}
236   .description #indicator_reading { height: 4em;}
237
238 .prescription .controls { width: 100%; }
239   .controls a.button,
240   .controls button[value=save],
241   .controls button[value=cancel],
242   .controls button[value=delete] { width: 25%;}
243
244 EOF
245
246 # vi:set filetype=css: