+
{{{navigation}}}
{{/navigation}}
+{{#js}}
+require(['jquery', 'core_calendar/month_navigation_drag_drop'], function($, DragDrop) {
+ var root = $('#month-navigation-{{uniqid}}');
+ DragDrop.init(root);
+});
+{{/js}}
diff --git a/theme/boost/scss/moodle/calendar.scss b/theme/boost/scss/moodle/calendar.scss
index df6829ee144..2c047052fc3 100644
--- a/theme/boost/scss/moodle/calendar.scss
+++ b/theme/boost/scss/moodle/calendar.scss
@@ -48,6 +48,7 @@ $calendarEventUserColor: #dce7ec !default; // Pale blue.
.previous {
text-align: left;
+ border: 1px solid transparent;
}
.current {
@@ -57,6 +58,12 @@ $calendarEventUserColor: #dce7ec !default; // Pale blue.
.next {
text-align: right;
+ border: 1px solid transparent;
+ }
+
+ .drop-target {
+ box-sizing: border-box;
+ border: 1px dashed $brand-primary;
}
}
diff --git a/theme/bootstrapbase/less/moodle/bs4-compat.less b/theme/bootstrapbase/less/moodle/bs4-compat.less
index 15d05d2ad51..ccc168ee750 100644
--- a/theme/bootstrapbase/less/moodle/bs4-compat.less
+++ b/theme/bootstrapbase/less/moodle/bs4-compat.less
@@ -254,3 +254,46 @@
text-overflow: ellipsis;
white-space: nowrap;
}
+
+.text-white {
+ color: @white;
+}
+
+// Bg utilities.
+.bg {
+ // Important (red)
+ &-danger {
+ background-color: @errorText;
+ }
+ &-danger[href] {
+ background-color: darken(@errorText, 10%);
+ }
+ // Warnings (orange)
+ &-warning {
+ background-color: @orange;
+ }
+ &-warning[href] {
+ background-color: darken(@orange, 10%);
+ }
+ // Success (green)
+ &-success {
+ background-color: @successText;
+ }
+ &-success[href] {
+ background-color: darken(@successText, 10%);
+ }
+ // Info (turquoise)
+ &-info {
+ background-color: @infoText;
+ }
+ &-info[href] {
+ background-color: darken(@infoText, 10%);
+ }
+ // Primary (blue)
+ &-primary {
+ background-color: @blue;
+ }
+ &-primary[href] {
+ background-color: darken(@blue, 10%);
+ }
+}
diff --git a/theme/bootstrapbase/less/moodle/calendar.less b/theme/bootstrapbase/less/moodle/calendar.less
index 1111eb3fede..578f8bbab22 100644
--- a/theme/bootstrapbase/less/moodle/calendar.less
+++ b/theme/bootstrapbase/less/moodle/calendar.less
@@ -42,6 +42,8 @@
}
.previous {
text-align: left;
+ border: 1px solid transparent;
+ box-sizing: border-box;
}
.current {
text-align: center;
@@ -49,6 +51,12 @@
}
.next {
text-align: right;
+ border: 1px solid transparent;
+ box-sizing: border-box;
+ }
+ .drop-target {
+ box-sizing: border-box;
+ border: 1px dashed @blue;
}
}
.filters {
diff --git a/theme/bootstrapbase/less/moodle/core.less b/theme/bootstrapbase/less/moodle/core.less
index 69fef7b347d..54574836433 100644
--- a/theme/bootstrapbase/less/moodle/core.less
+++ b/theme/bootstrapbase/less/moodle/core.less
@@ -2407,3 +2407,7 @@ h3.sectionname .inplaceeditable.inplaceeditingon .editinstructions {
}
}
}
+
+[data-drag-type="move"] {
+ cursor: move;
+}
diff --git a/theme/bootstrapbase/style/moodle.css b/theme/bootstrapbase/style/moodle.css
index 42d89c0e209..65c23c7c6f6 100644
--- a/theme/bootstrapbase/style/moodle.css
+++ b/theme/bootstrapbase/style/moodle.css
@@ -4795,6 +4795,9 @@ h3.sectionname .inplaceeditable.inplaceeditingon .editinstructions {
height: 40px;
width: 40px;
}
+[data-drag-type="move"] {
+ cursor: move;
+}
/* admin.less */
.formtable tbody th {
font-weight: normal;
@@ -5591,6 +5594,8 @@ img.iconsmall {
}
.path-calendar .calendar-controls .previous {
text-align: left;
+ border: 1px solid transparent;
+ box-sizing: border-box;
}
.path-calendar .calendar-controls .current {
text-align: center;
@@ -5598,6 +5603,12 @@ img.iconsmall {
}
.path-calendar .calendar-controls .next {
text-align: right;
+ border: 1px solid transparent;
+ box-sizing: border-box;
+}
+.path-calendar .calendar-controls .drop-target {
+ box-sizing: border-box;
+ border: 1px dashed #049cdb;
}
.path-calendar .filters table {
border-collapse: separate;
@@ -21854,3 +21865,36 @@ ul.indented-list {
text-overflow: ellipsis;
white-space: nowrap;
}
+.text-white {
+ color: #fff;
+}
+.bg-danger {
+ background-color: #b94a48;
+}
+.bg-danger[href] {
+ background-color: #953b39;
+}
+.bg-warning {
+ background-color: #f89406;
+}
+.bg-warning[href] {
+ background-color: #c67605;
+}
+.bg-success {
+ background-color: #468847;
+}
+.bg-success[href] {
+ background-color: #356635;
+}
+.bg-info {
+ background-color: #3a87ad;
+}
+.bg-info[href] {
+ background-color: #2d6987;
+}
+.bg-primary {
+ background-color: #049cdb;
+}
+.bg-primary[href] {
+ background-color: #0378a9;
+}