on-demand release 3.2beta+
[moodle.git] / theme / boost / scss / moodle / modules.scss
CommitLineData
536f0460
DW
1/* modules.less */
2
3// The home for small tweaks to modules that don't require
4// changes drastic enough to pull in the full module css
5// and replace it completely
6// Plus some misc. odds and ends
7
8select {
9 width: auto;
10}
11
50302c40
DW
12.path-mod-feedback .feedback_form .col-form-label {
13 display: block !important; /* stylelint-disable-line declaration-no-important */
14}
f25185d7 15
63e4df60 16// Feedback module
ba5c5083
DW
17.path-mod-feedback .itemactions {
18 float: right;
19}
a5d4b548
DW
20.path-mod-feedback .itemhandle {
21 position: absolute;
22 right: 1rem;
23}
ba5c5083 24
536f0460
DW
25// Forum module
26
27.path-mod-forum .forumsearch {
28 input,
29 .helptooltip {
30 margin: 0 3px;
31 }
32}
33
34.path-mod-forum .forumheaderlist,
35.path-mod-forum .forumheaderlist td {
36 border: none;
37}
38
39.path-mod-forum {
40 .forumheaderlist {
41 thead .header,
42 tbody .discussion td {
43 white-space: normal;
44 vertical-align: top;
45 padding-left: 0.5em;
46 padding-right: 0.5em;
47 }
48
49 thead .header {
50 white-space: normal;
51 vertical-align: top;
52 }
53
54 thead .header.replies {
55 text-align: center;
56 }
f4143537 57
536f0460
DW
58 thead .header.lastpost {
59 text-align: right;
60 }
f4143537 61
536f0460 62 thead .header th,
f4143537 63 tbody .discussion td {
536f0460
DW
64 &.discussionsubscription {
65 width: 16px;
66 padding-left: 0.5em;
67 padding-right: 0.5em;
68 }
69 }
f4143537 70
536f0460 71 .discussion {
f4143537
DP
72 .author,
73 .replies,
74 .lastpost {
536f0460
DW
75 white-space: normal;
76 }
f4143537 77
536f0460
DW
78 .discussionsubscription,
79 .replies {
80 text-align: center;
81 }
f4143537 82
536f0460
DW
83 .topic,
84 .discussionsubscription,
85 .topic.starter,
86 .picture,
87 .author,
88 .replies,
89 .lastpost {
90 vertical-align: top;
91 }
92 }
93 }
94}
95
96.forumpost {
97 @extend .card;
98 padding: 6px;
f4143537 99
536f0460
DW
100 .header {
101 margin-bottom: 3px;
102 }
f4143537 103
536f0460
DW
104 .picture img {
105 margin: 3px;
f4143537 106
536f0460
DW
107 &.userpicture {
108 margin-left: 3px;
109 margin-right: 10px;
110 }
111 }
f4143537 112
536f0460
DW
113 .content {
114 .posting.fullpost {
115 margin-top: 8px;
116 }
117 }
f4143537 118
536f0460
DW
119 .row {
120 .topic,
121 .content-mask,
122 .options {
123 margin-left: 48px;
124 }
f4143537 125
536f0460
DW
126 &.side {
127 clear: both;
128 }
129 }
130}
131
132.forumpost .row .left {
133 width: 48px;
134}
135
136.forumpost .options .commands {
137 margin-left: 0;
138}
139
140.forumpost .subject {
141 font-weight: bold;
142}
143
144// Override hardcoded forum modules styling
145.forumsearch input[type=text] {
5142f564 146 margin-bottom: 0;
536f0460
DW
147}
148
149#page-mod-forum-discuss .discussioncontrols {
150 width: auto;
151 margin: 0;
7d41ccf0
DW
152
153 .form-inline input {
154 margin-top: -1px;
155 }
536f0460
DW
156}
157
f4143537
DP
158.maincalendar .calendarmonth td,
159.maincalendar .calendarmonth th {
536f0460
DW
160 border: 1px dotted $table-border-color;
161}
162
163.path-grade-report-grader h1 {
164 text-align: inherit;
165}
166
167#page-mod-chat-gui_basic input#message {
168 max-width: 100%;
169}
170
171#page-mod-data-view #singleimage {
172 width: auto;
173}
174
175.path-mod-data form {
176 margin-top: 10px;
177}
178
179.template_heading {
180 margin-top: 10px;
181}
182
183.breadcrumb-button {
184 float: right;
185 margin-top: 4px;
186}
187
188.breadcrumb-button .singlebutton {
189 float: left;
190 margin-left: 4px;
191}
192
193.navbar-fixed-top,
194.navbar-fixed-bottom {
195 z-index: 4030;
196}
197
198.ie .row-fluid .desktop-first-column {
199 margin-left: 0;
200}
f4143537 201
536f0460
DW
202.langmenu form {
203 margin: 0;
204}
536f0460
DW
205// contributed by Paul Hibbitts, see http://msdn.microsoft@mixin com/en-us/library/ie/jj583807(v=vs.85).aspx
206canvas {
207 -ms-touch-action: auto;
208}
209
210div#dock {
211 display: none;
212}
213
214// Choice module
215
536f0460
DW
216// Lesson module
217
63e4df60 218/** General styles (scope: all of lesson) **/
f4143537
DP
219.path-mod-lesson .invisiblefieldset.fieldsetfix {
220 display: block;
221}
536f0460
DW
222
223.path-mod-wiki .wiki_headingtitle,
224.path-mod-wiki .midpad,
225.path-mod-wiki .wiki_headingtime {
226 text-align: inherit;
227}
228
229.path-mod-wiki .wiki_contentbox {
230 width: 100%;
231}
232
137c289a
FM
233// Dropdown styling.
234.dropdown-menu {
235 margin-top: 11px;
236}
237
536f0460
DW
238// Survey module
239
240.path-mod-survey {
241 .surveytable {
f4143537
DP
242 > tbody > tr:nth-of-type(odd) {
243 background-color: $table-bg;
244 }
245
246 > tbody > tr:nth-of-type(even) {
247 background-color: $table-bg-accent;
248 }
249
250 .rblock label {
251 text-align: center;
252 }
536f0460 253 }
f4143537 254
536f0460
DW
255}
256
257.nav .caret {
258 margin-left: 4px;
259}
260
261// Dividers
262.nav {
263 .divider {
264 overflow: hidden;
265 width: 0;
536f0460
DW
266 }
267}
536f0460
DW
268
269// Usermenu
270.usermenu {
7001a3b2
FM
271 float: right;
272
536f0460 273 .login {
5f18da12 274 line-height: 2.25rem;
f4143537 275
536f0460 276 a {
5f18da12 277 color: $link-color;
536f0460
DW
278 &:hover,
279 &:focus {
5f18da12 280 color: $link-hover-color;
536f0460
DW
281 text-decoration: underline;
282 }
283 }
284 }
3313fdd6 285}
f4143537 286
7001a3b2
FM
287.userloggedinas,
288.userswitchedrole {
536f0460 289 .usermenu {
7001a3b2
FM
290 .usertext {
291 float: left;
292 text-align: right;
293 margin-right: $spacer / 2;
294 height: 35px;
295 .meta {
536f0460 296 display: block;
7001a3b2 297 font-size: $font-size-sm;
536f0460 298 }
7001a3b2
FM
299 }
300 .avatar {
301 img {
fde35b8f 302 margin: 0;
536f0460 303 }
536f0460
DW
304 }
305 }
306}
307
7001a3b2
FM
308.userloggedinas .usermenu {
309 .userbutton .avatars {
310 position: relative;
311 display: inline-block;
312 .avatar {
313 &.current {
314 display: inline-block;
315 position: absolute;
316 bottom: 0;
317 right: 0;
318 width: 20px;
319 height: 20px;
320 border-radius: 50%;
321 img {
322 vertical-align: baseline;
323 }
536f0460 324 }
7001a3b2
FM
325 img {
326 width: inherit;
327 height: inherit;
536f0460
DW
328 }
329 }
7001a3b2
FM
330 .realuser {
331 width: 35px;
332 height: 35px;
333 display: inline-block;
536f0460
DW
334 }
335 }
336}
337
7001a3b2
FM
338@include media-breakpoint-down(sm) {
339 .usertext {
340 display: none;
536f0460
DW
341 }
342}
343
344// Quiz module
345
346// Question navigation block.
347.path-mod-quiz #mod_quiz_navblock {
348 .qnbutton {
349 text-decoration: none;
350 font-size: 14px;
351 line-height: 20px;
352 font-weight: normal;
353 background-color: $body-color;
354 background-image: none;
355 height: 40px;
356 width: 30px;
357 border-radius: 3px;
358 border: 0;
359 overflow: visible;
360 margin: 0 6px 6px 0;
361 }
f4143537 362
536f0460
DW
363 span.qnbutton {
364 cursor: default;
365 background-color: $input-bg-disabled;
366 color: $gray;
367 }
f4143537 368
536f0460
DW
369 a.qnbutton:hover,
370 a.qnbutton:active,
371 a.qnbutton:focus {
372 text-decoration: underline;
373 }
374
375 .qnbutton .thispageholder {
376 border: 1px solid;
377 border-radius: 3px;
378 z-index: 1;
379 }
f4143537 380
536f0460
DW
381 .qnbutton.thispage .thispageholder {
382 border-width: 3px;
383 }
f4143537 384
536f0460
DW
385 .allquestionsononepage .qnbutton.thispage .thispageholder {
386 border-width: 1px;
387 }
388
389 .qnbutton.flagged .thispageholder {
fde35b8f 390 background: transparent url([[pix:theme|mod/quiz/flag-on]]) 15px 0 no-repeat;
536f0460
DW
391 }
392
393 .qnbutton .trafficlight {
394 border: 0;
f4143537 395 background: $body-color none center / 10px no-repeat scroll;
536f0460
DW
396 height: 20px;
397 margin-top: 20px;
398 border-radius: 0 0 3px 3px;
399 }
400
401 .qnbutton.notyetanswered .trafficlight,
402 .qnbutton.invalidanswer .trafficlight {
403 background-color: $body-color;
404 }
f4143537 405
536f0460
DW
406 .qnbutton.invalidanswer .trafficlight {
407 background-image: url([[pix:theme|mod/quiz/warningtriangle]]);
408 }
f4143537 409
536f0460
DW
410 .qnbutton.correct .trafficlight {
411 background-image: url([[pix:theme|mod/quiz/checkmark]]);
412 background-color: $state-success-text;
413 }
f4143537 414
536f0460
DW
415 .qnbutton.blocked .trafficlight {
416 background-image: url([[pix:core|t/locked]]);
417 background-color: $input-bg-disabled;
418 }
f4143537 419
536f0460
DW
420 .qnbutton.notanswered .trafficlight,
421 .qnbutton.incorrect .trafficlight {
422 background-color: $state-danger-text;
423 }
f4143537 424
536f0460
DW
425 .qnbutton.partiallycorrect .trafficlight {
426 background-image: url([[pix:theme|mod/quiz/whitecircle]]);
427 background-color: $state-warning-text;
428 }
f4143537 429
536f0460
DW
430 .qnbutton.complete .trafficlight,
431 .qnbutton.answersaved .trafficlight,
432 .qnbutton.requiresgrading .trafficlight {
433 background-color: $gray-light;
434 }
435}
bffc0ef1
FM
436
437/**
438 * Assign.
439 */
440.path-mod-assign [data-region="grade-actions-panel"] [data-region="grade-actions"] .collapse-buttons {
441 top: auto;
442}
ba5c5083
DW
443.path-mod-assign .no-overflow {
444 overflow: initial;
445}
f4143537 446
63e4df60 447.path-mod-assign [data-region="grade-panel"] .has-popout {
9cb41231 448 background-color: $card-bg;
f4143537 449
9cb41231
DP
450 @include border-radius($card-border-radius);
451 border: $card-border-width solid $card-border-color;
63e4df60 452}
f4143537 453
63e4df60
DW
454.path-mod-assign [data-region="grade-panel"] .popout {
455 background-color: $modal-content-bg;
456}
f4143537 457
63e4df60
DW
458.path-mod-assign [data-region="grade-panel"] .col-md-3 {
459 width: 100%;
460}
f4143537 461
63e4df60
DW
462.path-mod-assign [data-region="grade-panel"] .popout > .col-md-3 {
463 @extend .modal-header;
464 font-size: 1.5rem;
465}
f4143537 466
63e4df60
DW
467.path-mod-assign [data-region="grade-panel"] [data-region="popout-button"] {
468 margin-top: 0.5rem;
469}
f4143537 470
63e4df60
DW
471.path-mod-assign [data-region="grade-panel"] .popout [data-region="popout-button"] {
472 margin-top: 0;
473}
f4143537 474
bffc0ef1
FM
475.path-mod-assign [data-region="grade-panel"] h3 {
476 margin: 10px 0;
477 line-height: 40px;
478}
f4143537 479
ba5c5083
DW
480.path-mod-assign [data-region="assignment-info"] {
481 overflow-y: hidden;
482}
483
bffc0ef1
FM
484.path-mod-assign [data-region="grading-navigation"] {
485 padding: 6px;
486}
f4143537 487
bffc0ef1
FM
488.path-mod-assign [data-region="grade-actions"] {
489 padding: 10px;
490}
f4143537 491
bffc0ef1
FM
492.path-mod-assign [data-region="user-info"] .img-rounded {
493 margin-top: 0;
494}
f4143537 495
bffc0ef1
FM
496.path-mod-assign [data-region="grading-navigation-panel"] {
497 height: 85px;
498}
f4143537 499
bffc0ef1
FM
500.path-mod-assign [data-region="grading-navigation"] [data-region="input-field"] input {
501 width: auto;
502 display: inline-block;
503}
504
505/**
506 * Assign feedback.
507 */
508.assignfeedback_editpdf_widget * {
509 box-sizing: content-box;
510}
f4143537 511
bffc0ef1
FM
512.assignfeedback_editpdf_widget button {
513 box-sizing: border-box;
514}
f4143537 515
bffc0ef1
FM
516.assignfeedback_editpdf_widget .commentcolourbutton img {
517 border-width: 0;
518}
f4143537 519
bffc0ef1
FM
520.assignfeedback_editpdf_widget .label {
521 @extend .tag;
522 @extend .tag-info;
523}
524
525.assignfeedback_editpdf_menu {
526 padding: 0;
527}
63e4df60 528
3d979f96
FM
529
530/**
531 * Mod LTI.
532 */
533.path-admin-mod-lti {
534 .btn .loader img,
535 #tool-list-loader-container .loader img {
536 height: auto;
537 }
538}