MDL-85435 course: Render HTML in activity overview name mustache

This commit is contained in:
Amaia Anabitarte
2025-05-21 17:35:41 +02:00
parent b4a8c83ea3
commit 7976fa47cd
2 changed files with 13 additions and 1 deletions
@@ -30,7 +30,7 @@
}}
<div class="d-flex flex-column">
<div class="fw-bold">
<a href="{{activityurl}}" class="activityname">{{activityname}}</a>
<a href="{{activityurl}}" class="activityname">{{{activityname}}}</a>
</div>
{{#sectiontitle}}
<div>
@@ -301,3 +301,15 @@ Feature: Users can access the course activities overview page
And I should see "-" in the "Activity 2" "table_row"
When I am on the "Course 1" "course > activities > lesson" page logged in as "teacher1"
And I should not see "Grade" in the "lesson_overview_collapsible" "region"
Scenario: Activities name is properly filtered and rendered
Given the following config values are set as admin:
| formatstringstriptags | 0 |
And the following "activity" exists:
| activity | assign |
| course | C1 |
| section | 1 |
| idnumber | mathjax |
| name | <span class="filter_mathjaxloader_equation">Announcements$$(a+b)=2$$<span class="nolink">$$(a+b)=2$$</span></span> |
When I am on the "Course 1" "course > activities > assign" page logged in as "teacher1"
Then I should not see "span" in the "assign_overview_collapsible" "region"