exercises fix
[edumed.git] / catalogue / static / catalogue / css / exercise.scss
1 $px: 0.0625em;
2
3
4 @mixin bubble {
5     border-radius: 11*$px;
6     padding: 8*$px 11*$px;
7 }
8 @mixin bubble-drag {
9     background-color: #d4d6d8;
10     color: #363a3e;
11     cursor: pointer;
12     z-index: 2;
13 }
14 @mixin bubble-drag-disabled {
15     background-color: #eee;
16     color: #d4d6d8;
17 }
18 @mixin un-bubble-drag {
19     background-color: inherit;
20     color: inherit;
21     cursor: inherit;
22     z-index: inherit;
23 }
24
25 @mixin bubble-inline {
26     display: inline-block;
27     margin: 5*$px;
28     z-index: 2;
29 }
30 @mixin un-bubble-inline {
31     display: inline;
32     margin: 0;
33     padding: 0;
34     z-index: inherit;
35     border-radius: 0;
36 }
37 @mixin list-plain {
38     list-style: none;
39     margin: 0;
40     padding: 0;
41 }
42
43
44 .exercise {
45     img {
46         vertical-align: top;
47     }
48
49     .question-piece {
50         @include bubble;
51     }
52     .lista.punkt {
53         @include list-plain;
54     }
55     .lista {
56         li {
57             margin: 5*$px 0;
58         }
59     }
60
61     .question-piece.correct {
62         background-color: #16a487;
63         color: white;
64     }
65     .question-piece.incorrect {
66         background-color: #f00;
67         color: white;
68     }
69     
70     .placeholder.dragover {
71          background: #ed7831 !important;
72     }
73
74     .remove {
75         float: right;
76         display: inline-block;
77         border-radius: 8*$px;
78         padding: 4*$px 8*$px;
79         margin: -4*$px -8*$px -.25em 8*$px;
80         background: #ed7831;
81         color: white;
82     }
83
84     .buttons {
85         background: #5e6165;
86         border-radius: 9*$px;
87         height: 30*$px;
88         line-height: 30*$px;
89         overflow: hidden;
90         color: white;
91         margin-top: 30*$px;
92
93         input {
94             height: 100%;
95             border: 0;
96             background: #8e9093;
97             color: white;
98             text-transform: uppercase;
99             font-weight: bold;
100         }
101         .message {
102             float: right;
103             padding: 0 20*$px;
104             background: red;
105         }
106         .maxscore {
107             background: #16a487;
108         }
109
110         input.check {
111             background: #ed7831;
112             
113         }
114     }
115
116 }
117
118
119 .luki {
120     .question-piece {
121         @include bubble-drag;
122         @include bubble-inline;
123         max-width: 608*$px;
124     }
125     .question-piece.disabled {
126         @include bubble-drag-disabled;
127     }
128
129     .placeholder {
130         @include bubble;
131         @include bubble-inline;
132
133         width: 4em;
134         background-color: #eee;
135         z-index: 1;
136     }
137     .placeholder:after {
138         content: "\0000a0";
139     }
140 }
141
142
143 .zastap {
144     .question-piece {
145         @include bubble-drag;
146         @include bubble-inline;
147     }
148     .question-piece.disabled {
149         @include bubble-drag-disabled;
150     }
151     .question-piece.placeholder {
152         @include un-bubble-drag;
153         @include un-bubble-inline;
154     }
155 }
156
157 .uporzadkuj {
158     .question-piece {
159         @include bubble-drag;
160     }
161     .question-piece.disabled {
162         @include bubble-drag-disabled;
163     }
164     .lista {
165         @include list-plain;
166         counter-reset: answer;
167         li {
168             counter-increment: answer;
169             padding-right: 3em;
170             background-image: url(/static/img/ornaments/draggable.png);
171             background-repeat: no-repeat;
172             background-position: 100% 50%;
173         }
174         li:before {
175             @include bubble;
176             @include bubble-drag;
177             content: counter(answer);
178             float: left;
179             margin: -.5em 0 0 -3em;
180         }
181         li.ui-sortable-placeholder {
182             counter-increment: answer 0;
183         }
184         li.ui-sortable-helper:before {
185             content: none;
186         }
187     }
188 }
189
190 .przyporzadkuj {
191     .question-piece {
192         @include bubble-drag;
193         width: 618*$px;
194     }
195     span.question-piece {
196         display: inline-block;
197         margin: .1em;
198         width: auto;
199     }
200     .question-piece.disabled {
201         @include bubble-drag-disabled;
202     }
203     .predicate {
204         @include list-plain;
205
206         > li {
207             @include bubble;
208             display: inline-block;
209             background-color: #5e6165;
210             color: white;
211             width: 188*$px;
212             position: relative;
213             vertical-align: top;
214
215             .subjects {
216                 @include list-plain;
217                 min-height: 45*$px;
218                 position: relative;
219                 margin: 8*$px -11*$px -8*$px -11*$px;
220                 padding: 8*$px 11*$px;
221
222                 li {
223                     width: auto;
224                 }
225
226                 .placeholder {
227                     @include bubble;
228                     text-align: right;
229                     position:relative;
230                     padding: 8*$px 11*$px;
231                     margin: 0 -11*$px;
232                 }
233                 .multiple {
234                     position: absolute;
235                     z-index: -1;
236                     top: 0;
237                     bottom: 0;
238                     left: 0;
239                     right: 0;
240                     margin: 0;
241                 }
242                 
243                 .placeholder.dragover {
244                     z-index: 1;
245                 }
246                 .placeholder:after {
247                     content: "upuść tutaj";
248                     text-style: italic;
249                 }
250             }
251         }
252         .comment {
253         }
254     }
255     .subject {
256         @include list-plain;
257     }
258
259 }
260
261
262 .prawdafalsz .question {
263     li.question-piece {
264         position: relative;
265         padding-left: 11em;
266     }
267
268     .buttons {
269         margin-top: 0;
270         top: 0;
271         left: 0;
272         position: absolute;
273         
274         background-color: #d4d6d8;
275         color: #363a3e;
276         display: inline-block;
277
278         a {
279             color: #363a3e;
280             text-transform: uppercase;
281             font-weight: bold;
282             display: inline-block;
283             padding: 0 11*$px;
284         }
285         a.chosen {
286             background: #ed7831;
287             color: white;
288         }
289     }
290 }
291
292 .wybor .question {
293     .lista {
294         list-style: none;
295         padding: 0;
296         li {
297             margin: 0;
298         }
299     }
300 }