* New pix icon i/externallink
* New lang string opensinnewwindow
* Use the external link pix icon with "Opens in new window" lang string
as its alt text and add it to the "Give feedback about this software"
link.
* Update cta template to indicate whether the link opens in new window.
- Part of: MDL-69588
This changes the context header to switch the breadcrumbs to the
top in boost. It also changes the context header in the modules
to have the activity name instead of the course name, and adds
an icon for the activity.
The new drawers structure shows that some elements
are dependant from the page structure and broke some
behats. This commit fixes those components and tests.
The legacy M.core.event.BLOCK_CONTENT_UPDATED event has been replaced with a
new core_block/events::blockContentUpdated native DOM event.
The new event can be triggered using the `notifyBlockContentUpdated`
event, and by providing the HTMLElement that was updated, for example:
```
import {notifyBlockContentUpdated} from 'core_block/events';
const someHandler = e => {
// ...
const updatedBlock = e.target.closest('.block');
notifyBlockContentUpdated(updatedBlock);
};
```
The new event can be listened to at any point in the DOM using the
following syntax:
```
import {eventTypes} from 'core_block/events';
const handler = e => {
// The block that was updated.
e.target;
// The id of the updated block.
e.detail.instanceId;
};
document.addEventListener(eventTypes.blockContentUpdated, handler);
```
A backward-compatabibility layer is included to ensure that any legacy
YUI event listener is still called with the same arguments.
This legacy bridges will be removed after Moodle 4.3.
The form_autocomplete is essentially a custom element. Unfortunately the
`setValue()` function in Mink has undesired actions so it is necessary
to write our own handling for it.
The standard Mink `setValue()` function focuses the element, sets a
value, and then blurs the element. In the case of the autocomplete this
can cause the autocomplete suggestions list to be closed in some
situations. Instead of using the setValue we click, and type the value,
but do not immediately blur.
Fixed a regression caused by MDL-64194 resulting in Dashboard - Course
overview pagination not working from second page of courses onwards.
Course overview block should now do the following:
- Display no pagination controls when user has no courses
- Display no pagination controls when less than 12 courses to display
- Only display pagination controls up to the number of courses user is
enrolled in
- Work correctly when on a page greater than the second page.