diff --git a/calendar/amd/build/view_manager.min.js b/calendar/amd/build/view_manager.min.js index dd946d4f9fd..e61502877e8 100644 --- a/calendar/amd/build/view_manager.min.js +++ b/calendar/amd/build/view_manager.min.js @@ -1 +1 @@ -define(["jquery","core/templates","core/str","core/notification","core_calendar/repository","core_calendar/events","core_calendar/selectors","core/modal_factory","core/modal_events","core_calendar/summary_modal"],function(a,b,c,d,e,f,g,h,i,j){var k=function(b){b=a(b),b.on("click",g.links.eventLink,function(b){var c,d=a(b.target),e=null;c=d.is(g.actions.viewEvent)?d:d.closest(g.actions.viewEvent),e=c.length?c.data("eventId"):d.find(g.actions.viewEvent).data("eventId"),e&&(b.preventDefault(),b.stopPropagation(),w(e))}),b.on("click",g.links.navLink,function(c){var d=b.find(g.wrapper),e=d.data("view"),f=d.data("courseid"),h=d.data("categoryid"),i=a(c.currentTarget);"month"===e?(m(b,i.attr("href"),i.data("year"),i.data("month"),f,h),c.preventDefault()):"day"===e&&(q(b,i.attr("href"),i.data("year"),i.data("month"),i.data("day"),f,h),c.preventDefault())})},l=function(c,h,i,j,k,l){r(c),l=l||c.find(g.wrapper),M.util.js_pending([c.get("id"),h,i,j].join("-"));var m=c.data("includenavigation"),n=c.data("mini");return e.getCalendarMonthData(h,i,j,k,m,n).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(l,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return M.util.js_complete([c.get("id"),h,i,j].join("-")),s(c)}).fail(d.exception)},m=function(b,c,d,e,g,h){return l(b,d,e,g,h).then(function(){return c.length&&"#"!==c&&window.history.pushState({},"",c),arguments}).then(function(){return a("body").trigger(f.monthChanged,[d,e,g,h]),arguments})},n=function(a,b,c){var d=a.find(g.wrapper).data("year"),e=a.find(g.wrapper).data("month");return"undefined"==typeof b&&(b=a.find(g.wrapper).data("courseid")),"undefined"==typeof c&&(c=a.find(g.wrapper).data("categoryid")),l(a,d,e,b,c)},o=function(c,h,i,j,k,l,m){r(c),m=m||c.find(g.wrapper),M.util.js_pending([c.get("id"),h,i,j,k,l].join("-"));var n=c.data("includenavigation");return e.getCalendarDayData(h,i,j,k,l,n).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(m,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return M.util.js_complete([c.get("id"),h,i,j,k,l].join("-")),s(c)}).fail(d.exception)},p=function(a,b,c){var d=a.find(g.wrapper),e=d.data("year"),f=d.data("month"),h=d.data("day");return b||(b=a.find(g.wrapper).data("courseid")),"undefined"==typeof c&&(c=a.find(g.wrapper).data("categoryid")),o(a,e,f,h,b,c)},q=function(b,c,d,e,g,h,i){return o(b,d,e,g,h,i).then(function(){return c.length&&"#"!==c&&window.history.pushState({},"",c),arguments}).then(function(){return a("body").trigger(f.dayChanged,[d,e,g,h,i]),arguments})},r=function(a){var b=a.find(g.containers.loadingIcon);b.removeClass("hidden")},s=function(a){var b=a.find(g.containers.loadingIcon);b.addClass("hidden")},t=function(c,h,i){r(c);var j=c.find(g.wrapper);return"undefined"==typeof h&&(h=c.find(g.wrapper).data("courseid")),"undefined"==typeof i&&(i=c.find(g.wrapper).data("categoryid")),e.getCalendarUpcomingData(h,i).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(j,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return s(c)}).fail(d.exception)},u=function(a){switch(a){case"user":return"user";case"site":return"site";case"group":return"group";case"category":return"category";default:return"course"}},v=function(a){return"calendar_event_"+u(a)},w=function(a){var c="";e.getEventById(a).then(function(b){if(!b.event)throw new Error("Error encountered while trying to fetch calendar event with ID: "+a);var d=b.event;return c=v(d.eventtype),x(d.eventtype).then(function(a){return d.eventtype=a,d})}).then(function(a){var d={title:a.name,type:j.TYPE,body:b.render("core_calendar/event_summary_body",a),templateContext:{canedit:a.canedit,candelete:a.candelete,headerclasses:c,isactionevent:a.isactionevent,url:a.url}};return h.create(d)}).done(function(a){a.getRoot().on(i.hidden,function(){a.destroy()}),a.show()}).fail(d.exception)},x=function(a){var b="type"+u(a);return c.get_string(b,"core_calendar").then(function(a){return a})};return{init:function(a){k(a)},reloadCurrentMonth:n,changeMonth:m,refreshMonthContent:l,reloadCurrentDay:p,changeDay:q,refreshDayContent:o,reloadCurrentUpcoming:t}}); \ No newline at end of file +define(["jquery","core/templates","core/str","core/notification","core_calendar/repository","core_calendar/events","core_calendar/selectors","core/modal_factory","core/modal_events","core_calendar/summary_modal"],function(a,b,c,d,e,f,g,h,i,j){var k=function(b){b=a(b),b.on("click",g.links.eventLink,function(b){var c,d=a(b.target),e=null;c=d.is(g.actions.viewEvent)?d:d.closest(g.actions.viewEvent),e=c.length?c.data("eventId"):d.find(g.actions.viewEvent).data("eventId"),e&&(b.preventDefault(),b.stopPropagation(),v(e))}),b.on("click",g.links.navLink,function(c){var d=b.find(g.wrapper),e=d.data("view"),f=d.data("courseid"),h=d.data("categoryid"),i=a(c.currentTarget);"month"===e?(m(b,i.attr("href"),i.data("year"),i.data("month"),f,h),c.preventDefault()):"day"===e&&(q(b,i.attr("href"),i.data("year"),i.data("month"),i.data("day"),f,h),c.preventDefault())})},l=function(c,h,i,j,k,l){r(c),l=l||c.find(g.wrapper),M.util.js_pending([c.get("id"),h,i,j].join("-"));var m=c.data("includenavigation"),n=c.data("mini");return e.getCalendarMonthData(h,i,j,k,m,n).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(l,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return M.util.js_complete([c.get("id"),h,i,j].join("-")),s(c)}).fail(d.exception)},m=function(b,c,d,e,g,h){return l(b,d,e,g,h).then(function(){return c.length&&"#"!==c&&window.history.pushState({},"",c),arguments}).then(function(){return a("body").trigger(f.monthChanged,[d,e,g,h]),arguments})},n=function(a,b,c){var d=a.find(g.wrapper).data("year"),e=a.find(g.wrapper).data("month");return"undefined"==typeof b&&(b=a.find(g.wrapper).data("courseid")),"undefined"==typeof c&&(c=a.find(g.wrapper).data("categoryid")),l(a,d,e,b,c)},o=function(c,h,i,j,k,l,m){r(c),m=m||c.find(g.wrapper),M.util.js_pending([c.get("id"),h,i,j,k,l].join("-"));var n=c.data("includenavigation");return e.getCalendarDayData(h,i,j,k,l,n).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(m,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return M.util.js_complete([c.get("id"),h,i,j,k,l].join("-")),s(c)}).fail(d.exception)},p=function(a,b,c){var d=a.find(g.wrapper),e=d.data("year"),f=d.data("month"),h=d.data("day");return b||(b=a.find(g.wrapper).data("courseid")),"undefined"==typeof c&&(c=a.find(g.wrapper).data("categoryid")),o(a,e,f,h,b,c)},q=function(b,c,d,e,g,h,i){return o(b,d,e,g,h,i).then(function(){return c.length&&"#"!==c&&window.history.pushState({},"",c),arguments}).then(function(){return a("body").trigger(f.dayChanged,[d,e,g,h,i]),arguments})},r=function(a){var b=a.find(g.containers.loadingIcon);b.removeClass("hidden")},s=function(a){var b=a.find(g.containers.loadingIcon);b.addClass("hidden")},t=function(c,h,i){r(c);var j=c.find(g.wrapper);return"undefined"==typeof h&&(h=c.find(g.wrapper).data("courseid")),"undefined"==typeof i&&(i=c.find(g.wrapper).data("categoryid")),e.getCalendarUpcomingData(h,i).then(function(a){return b.render(c.attr("data-template"),a)}).then(function(a,c){return b.replaceNode(j,a,c)}).then(function(){a("body").trigger(f.viewUpdated)}).always(function(){return s(c)}).fail(d.exception)},u=function(a){return"calendar_event_"+a},v=function(a){var c="";e.getEventById(a).then(function(b){if(!b.event)throw new Error("Error encountered while trying to fetch calendar event with ID: "+a);var d=b.event;return c=u(d.normalisedeventtype),d}).then(function(a){var d={title:a.name,type:j.TYPE,body:b.render("core_calendar/event_summary_body",a),templateContext:{canedit:a.canedit,candelete:a.candelete,headerclasses:c,isactionevent:a.isactionevent,url:a.url}};return h.create(d)}).done(function(a){a.getRoot().on(i.hidden,function(){a.destroy()}),a.show()}).fail(d.exception)};return{init:function(a){k(a)},reloadCurrentMonth:n,changeMonth:m,refreshMonthContent:l,reloadCurrentDay:p,changeDay:q,refreshDayContent:o,reloadCurrentUpcoming:t}}); \ No newline at end of file diff --git a/calendar/amd/src/view_manager.js b/calendar/amd/src/view_manager.js index 2c59a72ba6d..7043f75e355 100644 --- a/calendar/amd/src/view_manager.js +++ b/calendar/amd/src/view_manager.js @@ -339,28 +339,6 @@ define([ .fail(Notification.exception); }; - /** - * Convert the given event type into one of either user, site, - * group, category, or course. - * - * @param {String} eventType The calendar event type - * @return {String} - */ - var normaliseEventType = function(eventType) { - switch (eventType) { - case 'user': - return 'user'; - case 'site': - return 'site'; - case 'group': - return 'group'; - case 'category': - return 'category'; - default: - return 'course'; - } - }; - /** * Get the CSS class to apply for the given event type. * @@ -368,7 +346,7 @@ define([ * @return {String} */ var getEventTypeClassFromType = function(eventType) { - return 'calendar_event_' + normaliseEventType(eventType); + return 'calendar_event_' + eventType; }; /** @@ -385,12 +363,9 @@ define([ throw new Error('Error encountered while trying to fetch calendar event with ID: ' + eventId); } var eventData = getEventResponse.event; - typeClass = getEventTypeClassFromType(eventData.eventtype); + typeClass = getEventTypeClassFromType(eventData.normalisedeventtype); - return getEventType(eventData.eventtype).then(function(eventType) { - eventData.eventtype = eventType; - return eventData; - }); + return eventData; }).then(function(eventData) { // Build the modal parameters from the event data. var modalParams = { @@ -422,19 +397,6 @@ define([ }).fail(Notification.exception); }; - /** - * Get the event type lang string. - * - * @param {String} eventType The event type. - * @return {promise} The lang string promise. - */ - var getEventType = function(eventType) { - var lang = 'type' + normaliseEventType(eventType); - return Str.get_string(lang, 'core_calendar').then(function(langStr) { - return langStr; - }); - }; - return { init: function(root) { registerEventListeners(root); diff --git a/calendar/classes/external/calendar_event_exporter.php b/calendar/classes/external/calendar_event_exporter.php index f4b629f204e..ea32de3521a 100644 --- a/calendar/classes/external/calendar_event_exporter.php +++ b/calendar/classes/external/calendar_event_exporter.php @@ -52,9 +52,6 @@ class calendar_event_exporter extends event_exporter_base { 'type' => PARAM_BOOL, 'default' => false, ]; - $values['calendareventtype'] = [ - 'type' => PARAM_TEXT, - ]; $values['popupname'] = [ 'type' => PARAM_RAW, ]; @@ -172,8 +169,6 @@ class calendar_event_exporter extends event_exporter_base { $values['popupname'] = get_string('eventnameandcourse', 'calendar', $eventnameparams); } - $values['calendareventtype'] = $this->get_calendar_event_type(); - if ($event->get_course_module()) { $values = array_merge($values, $this->get_module_timestamp_limits($event)); } else if ($hascourse && $course->id != SITEID && empty($event->get_group())) { diff --git a/calendar/classes/external/event_exporter.php b/calendar/classes/external/event_exporter.php index 51ee3e41169..015d71acb77 100644 --- a/calendar/classes/external/event_exporter.php +++ b/calendar/classes/external/event_exporter.php @@ -55,7 +55,6 @@ class event_exporter extends event_exporter_base { 'type' => event_action_exporter::read_properties_definition(), 'optional' => true, ]; - return $values; } diff --git a/calendar/classes/external/event_exporter_base.php b/calendar/classes/external/event_exporter_base.php index d20cfb3d093..b3fb837be21 100644 --- a/calendar/classes/external/event_exporter_base.php +++ b/calendar/classes/external/event_exporter_base.php @@ -236,6 +236,12 @@ class event_exporter_base extends exporter { 'default' => null, 'null' => NULL_ALLOWED ], + 'normalisedeventtype' => [ + 'type' => PARAM_TEXT + ], + 'normalisedeventtypetext' => [ + 'type' => PARAM_TEXT + ], ]; } @@ -254,11 +260,14 @@ class event_exporter_base extends exporter { $values['isactionevent'] = false; $values['iscourseevent'] = false; $values['iscategoryevent'] = false; + $values['normalisedeventtype'] = $event->get_type(); if ($moduleproxy = $event->get_course_module()) { // We need a separate property to flag if an event is action event. // That's required because canedit return true but action action events cannot be edited on the calendar UI. // But they are considered editable because you can drag and drop the event on the month view. $values['isactionevent'] = true; + // Activity events are normalised to "look" like course events. + $values['normalisedeventtype'] = 'course'; } else if ($event->get_type() == 'course') { $values['iscourseevent'] = true; } else if ($event->get_type() == 'category') { @@ -266,6 +275,7 @@ class event_exporter_base extends exporter { } $timesort = $event->get_times()->get_sort_time()->getTimestamp(); $iconexporter = new event_icon_exporter($event, ['context' => $context]); + $values['normalisedeventtypetext'] = get_string('type' . $values['normalisedeventtype'], 'calendar'); $values['icon'] = $iconexporter->export($output); diff --git a/calendar/templates/calendar_day.mustache b/calendar/templates/calendar_day.mustache index 7d75b5779f6..e82e42a1b63 100644 --- a/calendar/templates/calendar_day.mustache +++ b/calendar/templates/calendar_day.mustache @@ -15,7 +15,7 @@ along with Moodle. If not, see . }} {{! - @template calendar/calendar_day + @template core_calendar/calendar_day Calendar day view. diff --git a/calendar/templates/day_detailed.mustache b/calendar/templates/day_detailed.mustache index 74d48bb4342..fde6b2f4417 100644 --- a/calendar/templates/day_detailed.mustache +++ b/calendar/templates/day_detailed.mustache @@ -15,7 +15,7 @@ along with Moodle. If not, see . }} {{! - @template calendar/day_detailed + @template core_calendar/day_detailed Calendar day view. diff --git a/calendar/templates/event_details.mustache b/calendar/templates/event_details.mustache new file mode 100644 index 00000000000..86fcda4cc9b --- /dev/null +++ b/calendar/templates/event_details.mustache @@ -0,0 +1,120 @@ +{{! + This file is part of Moodle - http://moodle.org/ + + Moodle is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + Moodle is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with Moodle. If not, see . +}} +{{! + @template core_calendar/event_details + + Calendar event details. + + The purpose of this template is to render the event details. + + This template is used in the summary modal, day and upcoming views to output event information consistently + across the calendar. + + Classes required for JS: + * none + + Data attributes required for JS: + * none + + Example context (json): + { + "formattedtime": "Wednesday, 17 April, 9:27 AM", + "normalisedeventtype": "Group", + "description": "An random event description", + "location": "Moodle HQ", + "isactionevent": "true", + "course": { + "viewurl": "http://mymoodlesite/course/view.php?id=1", + "fullname": "Course name" + }, + "source": "Ical imported", + "groupname": "Group 1", + "iscategoryevent": "true", + "category": { + "nestedname": "Category name" + }, + "iscourseevent": "true", + "groupname": "Group name", + "subscription": "true", + "displayeventsource": "true", + "subscriptionname": "Subscription name", + "subscriptionurl": "http://subscriptionurl" + } +}} +
+
{{#pix}} i/calendareventtime, core, {{#str}} when, core_calendar {{/str}} {{/pix}}
+
{{{formattedtime}}}
+
+
+
{{#pix}} i/calendar, core, {{#str}} eventtype, core_calendar {{/str}} {{/pix}}
+
{{normalisedeventtypetext}}
+
+{{#description}} +
+
{{#pix}} i/calendareventdescription, core, {{#str}} description {{/str}} {{/pix}}
+
{{{.}}}
+
+{{/description}} +{{#location}} +
+
{{#pix}} i/location, core, {{#str}} location {{/str}} {{/pix}}
+
{{{.}}}
+
+{{/location}} +{{#isactionevent}} +
+
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
+ +
+{{/isactionevent}} +{{#iscategoryevent}} +
+
{{#pix}} i/categoryevent, core, {{#str}} category {{/str}} {{/pix}}
+
{{{category.nestedname}}}
+
+{{/iscategoryevent}} +{{#iscourseevent}} +
+
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
+ +
+{{/iscourseevent}} +{{#groupname}} +
+
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
+ +
+
+
{{#pix}} i/groupevent, core, {{#str}} group {{/str}} {{/pix}}
+
{{{groupname}}}
+
+{{/groupname}} +{{#subscription}} + {{#displayeventsource}} +
+
{{#pix}} i/rss, core, {{#str}} eventsource, core_calendar {{/str}} {{/pix}}
+
+ {{#subscriptionurl}} +

{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}

+ {{/subscriptionurl}} + {{^subscriptionurl}} +

{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}

+ {{/subscriptionurl}} +
+
+ {{/displayeventsource}} +{{/subscription}} diff --git a/calendar/templates/event_item.mustache b/calendar/templates/event_item.mustache index 98431ea91a0..ccbf7739e85 100644 --- a/calendar/templates/event_item.mustache +++ b/calendar/templates/event_item.mustache @@ -15,7 +15,7 @@ along with Moodle. If not, see . }} {{! - @template calendar/event_item + @template core_calendar/event_item Calendar event item. @@ -29,19 +29,35 @@ Example context (json): { + "id": 1, + "name": "Sample event name", + "normalisedeventtype": "course", + "course": { + "id": 1 + }, + "canedit": true, + "candelete": true, + "isactionevent": true, + "icon": { + "key": "i/courseevent", + "component": "core", + "alttext": "Some course event" + }, + "editurl": "#", + "url": "#" } }} -
-
+
+
{{#canedit}} {{#candelete}} @@ -59,23 +75,15 @@ {{#icon}}
{{#pix}} {{key}}, {{component}}, {{alttext}} {{/pix}}
{{/icon}}

{{{name}}}

- {{{formattedtime}}} -
{{#location}}{{{location}}}{{/location}}
-
-

{{{description}}}

- {{#iscourseevent}} - - {{/iscourseevent}} - {{> core_calendar/event_subscription}} - {{#isactionevent}} - {{#str}} gotoactivity, core_calendar {{/str}} - {{/isactionevent}} - {{#groupname}} - -
{{{groupname}}}
- {{/groupname}} +
+ {{> core_calendar/event_details }}
+ {{#isactionevent}} + + {{/isactionevent}}
diff --git a/calendar/templates/event_list.mustache b/calendar/templates/event_list.mustache index f75157a80ad..ae276ae2047 100644 --- a/calendar/templates/event_list.mustache +++ b/calendar/templates/event_list.mustache @@ -15,7 +15,7 @@ along with Moodle. If not, see . }} {{! - @template calendar/event_list + @template core_calendar/event_list Calendar event list. diff --git a/calendar/templates/event_summary_body.mustache b/calendar/templates/event_summary_body.mustache index 22d8d27d9e8..2d333b4ac08 100644 --- a/calendar/templates/event_summary_body.mustache +++ b/calendar/templates/event_summary_body.mustache @@ -40,68 +40,6 @@ }} data-edit-url="{{editurl}}"{{! }}>
-
-
{{#pix}} i/calendareventtime, core, {{#str}} when, core_calendar {{/str}} {{/pix}}
-
{{{formattedtime}}}
-
-
-
{{#pix}} i/calendar, core, {{#str}} eventtype, core_calendar {{/str}} {{/pix}}
-
{{eventtype}}
-
- {{#description}} -
-
{{#pix}} i/calendareventdescription, core, {{#str}} description {{/str}} {{/pix}}
-
{{{.}}}
-
- {{/description}} - {{#location}} -
-
{{#pix}} i/location, core, {{#str}} location {{/str}} {{/pix}}
-
{{{.}}}
-
- {{/location}} - {{#isactionevent}} -
-
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
- -
- {{/isactionevent}} - {{#iscategoryevent}} -
-
{{#pix}} i/categoryevent, core, {{#str}} category {{/str}} {{/pix}}
-
{{{category.nestedname}}}
-
- {{/iscategoryevent}} - {{#iscourseevent}} -
-
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
- -
- {{/iscourseevent}} - {{#groupname}} -
-
{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}
- -
-
-
{{#pix}} i/groupevent, core, {{#str}} group {{/str}} {{/pix}}
-
{{{groupname}}}
-
- {{/groupname}} - {{#subscription}} - {{#displayeventsource}} -
-
{{#pix}} i/rss, core, {{#str}} eventsource, core_calendar {{/str}} {{/pix}}
-
- {{#subscriptionurl}} -

{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}

- {{/subscriptionurl}} - {{^subscriptionurl}} -

{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}

- {{/subscriptionurl}} -
-
- {{/displayeventsource}} - {{/subscription}} + {{> core_calendar/event_details }}
diff --git a/calendar/templates/month_detailed.mustache b/calendar/templates/month_detailed.mustache index 5041ca2abae..84ce421e89e 100644 --- a/calendar/templates/month_detailed.mustache +++ b/calendar/templates/month_detailed.mustache @@ -87,7 +87,7 @@ {{/underway}} {{^underway}}
  • - +   {{> core_calendar/event_icon}} diff --git a/calendar/templates/month_mini.mustache b/calendar/templates/month_mini.mustache index 2a34335462c..b1aa06f1b14 100644 --- a/calendar/templates/month_mini.mustache +++ b/calendar/templates/month_mini.mustache @@ -135,7 +135,7 @@ {{$nocontent}}{{#str}}eventnone, calendar{{/str}}{{/nocontent}} {{$content}} {{#events}} -
    +
    {{#modulename}} {{#pix}} icon, {{modulename}} {{/pix}} {{/modulename}} diff --git a/calendar/templates/upcoming_mini.mustache b/calendar/templates/upcoming_mini.mustache index 082d5bcd922..c95287773c7 100644 --- a/calendar/templates/upcoming_mini.mustache +++ b/calendar/templates/upcoming_mini.mustache @@ -41,7 +41,7 @@ {{#events}} {{#icon}}{{#pix}} {{key}}, {{component}}, {{alttext}} {{/pix}}{{/icon}} diff --git a/theme/boost/scss/moodle/calendar.scss b/theme/boost/scss/moodle/calendar.scss index 97a40a04ea2..8326790c506 100644 --- a/theme/boost/scss/moodle/calendar.scss +++ b/theme/boost/scss/moodle/calendar.scss @@ -427,14 +427,12 @@ table.calendartable caption { } } -.summary-modal-container { - .description-content { - > p { - margin: 0; - } - } +.location-content { + overflow-wrap: break-word; +} - .location-content { - overflow-wrap: break-word; +.description-content { + > p { + margin: 0; } } diff --git a/theme/boost/style/moodle.css b/theme/boost/style/moodle.css index d6188477ad4..eccfabaa2fc 100644 --- a/theme/boost/style/moodle.css +++ b/theme/boost/style/moodle.css @@ -11659,12 +11659,12 @@ table.calendartable caption { .day-popover-content:empty + .day-popover-alternate { display: block; } -.summary-modal-container .description-content > p { - margin: 0; } - -.summary-modal-container .location-content { +.location-content { overflow-wrap: break-word; } +.description-content > p { + margin: 0; } + /* course.less */ /* COURSE CONTENT */ .section-modchooser-link img { diff --git a/theme/classic/style/moodle.css b/theme/classic/style/moodle.css index 663712eb675..5e200a13a75 100644 --- a/theme/classic/style/moodle.css +++ b/theme/classic/style/moodle.css @@ -11900,12 +11900,12 @@ table.calendartable caption { .day-popover-content:empty + .day-popover-alternate { display: block; } -.summary-modal-container .description-content > p { - margin: 0; } - -.summary-modal-container .location-content { +.location-content { overflow-wrap: break-word; } +.description-content > p { + margin: 0; } + /* course.less */ /* COURSE CONTENT */ .section-modchooser-link img {