forked from trampgeek/moodle-qtype_coderunner
-
Notifications
You must be signed in to change notification settings - Fork 0
/
styles.css
491 lines (407 loc) · 11.6 KB
/
styles.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
/* Question and results page */
.que.coderunner div.coderunner-examples,
.que.coderunner div.coderunner-test-results {
width: 100%;
overflow-x: auto;
box-sizing: border-box;
}
#page-question-type-coderunner table.coderunner-test-results td,
#page-question-type-coderunner table.coderunner-test-results th,
.que.coderunner table.coderunner-test-results td,
.que.coderunner table.coderunnerexamples td,
.que.coderunner textarea.edit_code {
font-family: courier, monospace;
vertical-align: top;
}
.que.coderunner textarea.edit_code {
width: 100%;
max-width: 100%;
box-sizing: border-box;
}
.que.coderunner div.initialisationerror {
color: #ca3120;
}
.que.coderunner div.coderunnerexamples {
padding-bottom: 10px;
}
#page-question-type-coderunner div.ui_wrapper,
.que.coderunner div.ui_wrapper {
max-width: 100%;
box-sizing: border-box;
background-color: #f0f0f0;
}
.que.coderunner .ace_editor,
body#page-question-type-coderunner .ace_editor {
font-size: 100%;
line-height: 18px;
}
.que.coderunner p.for-example-para {
font-weight: bold;
}
.que.coderunner .btn {
margin-right: 10px;
}
.que.coderunner div.coderunner-test-results {
padding: 0.5em;
}
.que.coderunner label.answerprompt {
font-weight: bold;
}
.que.coderunner div.prompt {
margin-top: 20px;
margin-bottom: 7px;
}
.que.coderunner div.coderunner-lang-select-div {
padding-top: 10px;
padding-bottom: 3px;
}
.que.coderunner select.coderunner-lang-select {
margin: 0 0 0 10px;
padding: 1px 5px 1px 5px;
}
.que.coderunner input.answer_reset_btn {
margin-bottom: 5px;
}
#page-question-type-coderunner table.coderunner-test-results td,
#page-question-type-coderunner table.coderunner-test-results th,
.que.coderunner table.coderunner-test-results td,
.que.coderunner table.coderunner-test-results th,
.que.coderunner table.coderunnerexamples td,
.que.coderunner table.coderunnerexamples th {
border: 1px solid #b0b0b0;
padding: 0.4em;
}
#page-question-type-coderunner table.coderunner-test-results .header,
.que.coderunner table.coderunner-test-results .header,
.que.coderunner table.coderunnerexamples .header {
text-align: left;
background-color: #f8f8ff;
}
.que.coderunner table.coderunner-test-results tr.hidden-test {
opacity: 0.5;
}
#page-question-type-coderunner table.coderunner-test-results {
margin-top: 0.5em;
margin-bottom: 0;
}
.que.coderunner table.coderunner-test-results,
.que.coderunner table.coderunnerexamples {
margin-bottom: 1em;
}
#page-question-type-coderunner div.coderunner-test-results td:last-child,
#page-question-type-coderunner div.coderunner-test-results td:first-child
.que.coderunner div.coderunner-test-results td:last-child,
.que.coderunner div.coderunner-test-results td:first-child {
min-width: 16px;
}
.que.coderunner textarea.coderunner-answer[cols] {
max-width: 100%;
width: auto;
line-height: 18px;
}
.que.coderunner div.coderunner-test-results {
color: black;
}
.que.coderunner div.precheck h3 {
margin: 3px 0;
font-size: 24px;
color: #333;
}
.que.coderunner pre.tablecell {
background-color: inherit;
border: none;
padding: 0;
white-space: pre;
}
.que.coderunner div.coderunner-test-results pre,
.que.coderunner div.coderunner-examples pre {
margin-bottom: 0;
}
.que.coderunner div.coderunner-test-results.good,
#page-question-type-coderunner tr.coderunner-failed-test.fixed {
background-color: #afa;
}
.que.coderunner div.coderunner-test-results.outputonly {
background-color: #f0f0f0;
}
.que.coderunner div.coderunner-test-results.good.precheck {
background: repeating-linear-gradient(0deg, #fff, #fff 8px, #f8f1f9 8px, #f8f1f9 16px);
}
.que.coderunner div.coderunner-test-results.bad,
.que.coderunner div.pre_syntax_error,
.que.coderunner div.pre_question_error {
background-color: #faa;
}
.que.coderunner div.coderunner-test-results.bad.precheck,
.que.coderunner pre.pre_syntax_error .precheck {
background: repeating-linear-gradient(0deg, #fdd, #fdd 8px, #fee 8px, #fee 16px);
}
.que.coderunner pre.pre_syntax_error,
.que.coderunner div.pre_question_error {
border: none;
}
div.coderunner-test-results.partial {
background-color: #fff3bf;
}
.que.coderunner span.answerprompt {
font-weight: bold;
}
.que.coderunner span.penaltyregime {
padding-left: 0.6em;
}
/* Ins and del elements are used to show differences. ins elements are
always hidden and del elements are always displayed (without decoration),
but the background colour of del elements is toggled by the
Show/Hide differences button.
*/
.que.coderunner div.coderunner-test-results del {
text-decoration: none;
background-color: #e0e000;
}
/* Add lines I seem to have somehow overridden in styles.php */
.que.coderunner tr.r0 td {
background-color: #f5f5f5;
}
.que.coderunner tr.r1 td {
background-color: #e5e5e5;
}
.que.coderunner div.im-controls p.penaltyregime {
display: inline;
float: right;
}
.que.coderunner .ace_wrapper {
border: 1px solid #d9edf7;
}
.que.coderunner .ace_gutter-cell {
border-right: solid 1px #000;
}
.que.coderunner .ace_fold-widget {
background-color: transparent;
background-image: none;
border: none;
}
.que.coderunner .ace_fold-widget:hover {
border: 1px solid gray;
margin-top: 1px;
}
/* expand */
.que.coderunner .ace_fold-widget.ace_closed::before {
content: '►';
color: gray;
font-size: 80%;
margin: 0 2px;
margin-top: -4px;
}
/* collapse */
.que.coderunner .ace_fold-widget.ace_open::before {
content: '▼';
color: gray;
font-size: 60%;
margin: 0 2px;
}
.que.coderunner .ace_line .ace_fold {
padding-right: 1px;
line-height: 9px;
}
.que.coderunner .ace_line .ace_fold::before {
background-image: none;
content: '←→';
float: right;
margin-top: -1px;
}
/* Fullscreen and exit fullscreen */
.que.coderunner .button-exit-fullscreen,
body#page-question-type-coderunner .button-exit-fullscreen {
bottom: 0;
}
.que.coderunner .button-fullscreen,
body#page-question-type-coderunner .button-fullscreen {
bottom: -1px;
}
.que.coderunner .button-fullscreen,
.que.coderunner .button-exit-fullscreen,
body#page-question-type-coderunner .button-fullscreen,
body#page-question-type-coderunner .button-exit-fullscreen {
border: none;
background: transparent;
margin: 0 0 2px 0;
height: 15px;
width: 20px;
padding: 0;
right: 15px;
z-index: 10;
}
.que.coderunner .button-fullscreen:focus,
.que.coderunner .button-exit-fullscreen:focus,
body#page-question-type-coderunner .button-fullscreen:focus,
body#page-question-type-coderunner .button-exit-fullscreen:focus {
display: flex;
justify-content: center;
outline: 2px solid black;
}
.que.coderunner .button-fullscreen img.icon:hover,
.que.coderunner .button-exit-fullscreen img.icon:hover,
body#page-question-type-coderunner .button-fullscreen img.icon:hover,
body#page-question-type-coderunner .button-exit-fullscreen img.icon:hover {
animation: scaletooriginalsize 0.3s ease-in-out 0.1s forwards;
transform: scale(1.2);
}
@keyframes scaletooriginalsize {
to {
transform: scale(1);
}
}
.que.coderunner .button-exit-fullscreen img.icon,
.que.coderunner .button-fullscreen img.icon,
body#page-question-type-coderunner .button-exit-fullscreen img.icon,
body#page-question-type-coderunner .button-fullscreen img.icon {
margin-right: unset;
margin-bottom: 10px;
width: 15px;
height: 15px;
}
/* Editing form. */
body#page-question-type-coderunner div.edit_code textarea {
width: 100%;
max-width: 100%;
box-sizing: border-box;
font-family: courier, monospace;
}
body#page-question-type-coderunner pre.templateparamserror {
color: #ca3120;
}
body#page-question-type-coderunner .qtype_coderunner_prototype_message {
color: #7e7f7f;
}
body#page-question-type-coderunner div#id_qtype_coderunner_error_div:empty,
body#page-question-type-coderunner div#id_qtype_coderunner_warning_div:empty {
display: none;
}
body#page-question-type-coderunner div#id_qtype_coderunner_error_div {
font-size: 120%;
font-weight: bold;
color: red;
border: 2px solid red;
padding: 4px;
margin-bottom: 6px;
}
body#page-question-type-coderunner div#id_qtype_coderunner_warning_div {
font-size: 120%;
font-weight: bold;
color: blue;
border: 2px solid blue;
padding: 4px;
margin-bottom: 6px;
}
body#page-question-type-coderunner textarea#id_templateparams {
resize: both;
}
body#page-question-type-coderunner .uiparamtablediv {
padding-top: 8px;
}
body#page-question-type-coderunner table.uiparamtable,
body#page-question-type-coderunner table.uiparamtable th,
body#page-question-type-coderunner table.uiparamtable td {
border: 1px solid #ccc;
padding: 4px;
background-color: #f8f8f8;
}
body#page-question-type-coderunner button.toggleuidetails {
border: none;
color: blue;
}
body#page-question-type-coderunner .ace_wrapper {
border: 1px solid #bbb;
}
body#page-question-type-coderunner div[id^=fitem_id_],
body#page-question-type-coderunner div[id^=fgroup_id_] {
background: #eee;
margin-bottom: 0;
margin-top: 0;
padding-bottom: 5px;
padding-top: 5px;
border: 1px solid #bbb;
border-top: 0;
border-bottom: 0;
overflow: visible;
}
body#page-question-type-coderunner label[for^=id_useasexample],
body#page-question-type-coderunner label[for^=id_hiderestiffail],
body#page-question-type-coderunner label.form-check {
padding: 5px;
border: 1px solid lightgray;
}
body#page-question-type-coderunner p.question-type-details-header {
font-size: 130%;
}
body#page-question-type-coderunner div[id^=fgroup_id_][id*=show_columns]
.felement span {
margin-right: 2em;
}
body#page-question-type-coderunner div[id^=fgroup_id_][id*=show_columns] {
padding-top: 16px;
padding-bottom: 16px;
}
body#page-question-type-coderunner select#id_coderunner_type {
margin-right: 2em;
}
body#page-question-type-coderunner div[id^=fitem_id_testcode]:not(:first-of-type) {
margin-top: 14px;
border: 1px solid #bbb;
border-bottom: 0;
padding-top: 8px;
}
body#page-question-type-coderunner div[id=fitem_id_addanswers] {
margin-top: 14px;
border: 1px solid #bbb;
padding-top: 8px;
}
body#page-question-type-coderunner input[name="usecurrentcat"] {
margin-right: 1px;
margin-left: 2em;
}
body#page-question-type-coderunner input[type="checkbox"] + label {
margin-right: 1em;
}
body#page-question-type-coderunner textarea.edit_code {
width: 100%;
box-sizing: border-box;
font-family: courier, monospace;
}
body#page-question-type-coderunner textarea.uiloadfailed {
border: 6px solid orange;
}
body#page-question-type-coderunner div.uiloadfailed {
background-color: orange;
padding-left: 10px;
}
body#page-question-type-coderunner input.testcasemark,
body#page-question-type-coderunner input.coderunner_answerbox_size,
body#page-question-type-coderunner input#id_cputimelimitsecs,
body#page-question-type-coderunner input#id_memlimitmb {
width: auto;
}
body#page-question-type-coderunner label + select,
body#page-question-type-coderunner label + input {
margin-right: 1em;
}
body#page-question-type-coderunner div.testcaseexpression {
padding-top: 10px;
border-top: 1px solid lightgrey;
}
/* Bulk tester */
li.bulktest.coderunner.context.quiz {
padding-left: 1.5em;
list-style-type: none;
}
/* Ace gapfiller ui */
.ace-gap-background {
position: absolute;
background-color: SeaShell;
border-radius: 0;
}
.ace-gap-outline {
position: absolute;
outline: 1px solid;
outline-color: rgba(0, 0, 0, 0.5);
}