* Declare variables inline, as per the current code conventions.
* Use built-in assert.true() and assert.false() in a few places.
* Use built-in QUnit.test.each() to remove need for ad-hoc loops and
inline composing of assertion messages with common prefixes. This
also creates clearer and more detailed test reports, and more granular
ability to re-run specific test cases.
* Remove unneeded use of `QUnit.newMwEnvironment()`.
* Simplify restoring of mw.Uri by storing the original reference
once outside the test, and then re-using that each time.
* Use mw.config.set() for improved familiarity and rely on natural
restoration instead of the extra 'config' key abstraction which is
another thing to learn and understand.
Change-Id: I796e034854203d2e0e78e510458f4b34603e9901
Note: this agitates T230232 again - when merging this please
make sure a merge for I929090848f3e04647a97f4979ec78682623fa070
is pending.
In various places we try to override the default mw-ui-icon behaviours
The hacks need to be removed as part of addressing the core problem.
Changes:
* Wherever we use mw-ui-icon-before in PHP - wrap the label with a span
so that label font-size is altered where needed - not the icon
* Where a small icon is needed us isSmall parameter for the Icon component
* Apply font-size to labels of mw-ui-icon-before elements
* The browser tests need a slight update to access the span element inside
a menu item - in the case of the logout button the label is always hidden,
so we need to check the visibility of the parent element (secondary_action)
Bug: T229440
Depends-On: I3f803ec4c9068b30aa93b803391aa4d65d8310ff
Change-Id: I07e4ae233979636b739f1117dd7703571e0a9366
Help with readability by using module.exports and require rather than the MobileFrontend
provided mw.mobileFrontend module manager (and avoid adopting webpack at this time)
Replace usages of mw.mobileFrontend.require with local require and module.exports
(compatible with RL or Node implementation)
Changes:
* Notifications modules are merged into skins.minerva.scripts and initialised
via a client side check.
* new file overlayManager for exporting an overlayManager singleton
rather than being hidden inside resources/skins.minerva.scripts/init.js
* All M.define/M.requires swapped out for require where possible
The `define` method is now forbidden in the repo.
Bug: T212944
Change-Id: I44790dd3fc6fe42bb502d79c39c4081c223bf2b1