The `randompage-url` message might not be defined, or be set to
'-' which means - this text do not exist. Minerva should respect
that, instead of showing a link that points nowhere/to a '-' page
Bug: T188697
Change-Id: If97d29b0e25f3635e94bf3b80b051355ea49cf7d
I want to remove the need for M.define in the Minerva repository.
It's no longer necessary with packageFiles and will help tame
a lot of the code we have here!
Change-Id: If6a35a23e84a44adb965fd9c41265ba37eb8368e
This test started failing on us for no apparent reason.
Example: Ic95f7b0
https://integration.wikimedia.org/ci/job/quibble-vendor-mysql-php72-docker/11469/consoleFull
Output: "test control group is about 25% (30.8%)"
It appears like the bucketing is not really done based on an actual
random number generator, but based on a hash that contains the session
ID. If this session ID is not really a random number, the hash might
not be random enough as well, but be skewed towards one or the other
direction.
We propose to take the normal distribution into account and change the
narrow +/- 10% margin to +/- 20%.
Change-Id: Ib163f1de4f9cff27aaf8dbc81189315142ff0d8a
The number of generic menu entry specific files is growing which is
cluttering the Menu/ directory. Move the entries to a new subfolder.
Bug: T214540
Change-Id: I807d6f6034ee1924e3a606f5e6782c3298896825
A list that toggles visibility via the checkbox hack is needed in at
least two spots: the page actions overflow menu and the user menu. This
patch makes several refactors to turn what was previously hardcoded into
page actions a reusable component:
- Start a new components directory. Components are reusable and
composable. The subdirectories are organized by function, not
ResourceLoader module bundling which greatly improves the ability to
see a component's full functionality in one directory instead of
examining the entire codebase. See updates to README.
- Extract pageactions.less into:
- ToggleList.less: LESS for any checkbox hack list.
- DropDownList.less: LESS for lists that open downwards.
- MenuListItem.less: LESS for list items of menus.
The division makes it easier to see concerns, dependencies, and change
code.
- Move pageActionMenu.mustache to a component and extract ToggleList
template.
- Extract ToggleList.js from Toolbar.js.
Bug: T214540
Change-Id: I171831469a6733c458bc5c7ba249a5096ca975b8
We would like to hide the user links and show only toobar when
OverflowMenu is visible. The User contributions link is available
only in user_links section only, as we're going to hide this
section, we need to move that link to the Toolbar.
Bug: T224735
Change-Id: Ib4f297993213fcc8fc3dd998e282e5b39957485e
Allow editors to define a different URL for random
by editing
/wiki/MediaWiki:Randompage-url
e.g. Special:RandomRootpage
Bug: T188697
Change-Id: I72bfbb9b02c99faa0c42c3212939f59b9b87149b
* Introduce a HomeMenuEntry class and use it for adding the home menu link
* Provide override methods for text and CSS class
Bug: T223210
Change-Id: I37160887478cba829a6e2f10a4d8f87d95167556
Two tests are failing. These are false positives that
obscure real failures. Both are removed for the following reason.
1) Editor test is covered by the redirect tests - failing due to
concurrent edits (possibly because multiple browser tests act on the same
page at the same time). However, editing is already covered by the other
2 cases.
2) Remove unwatch test - this is failing as there is a problem in the
setup - the page starts unwatched when it should be watched. The test
for checking that an article can be watched should suffice here.
Bug: T224947
Change-Id: I3049e1b190c3cb2ddc198a45681f59782f770d6a
User links bar has the items already rendered in toolbar/overflow
menus. There is no need to render user links if the overflow menu
is available.
Bug: T224735
Change-Id: I613fa68b6cd43acf07bcb85af77d0239dc6bba6b
Do the scrolling math manually, and only do horizontal scrolling on the
tab container. Don't do vertical scrolling, and don't scroll the
viewport.
Bug: T226112
Bug: T223142
Change-Id: Ie67e15bd51252906897a213505ae82cf29ba5cf2
MediaWiki Core defined $wgHideInterlanguageLinks that can be used to
disable the interwiki links. Minerva skin should respect this config,
furthermore, this config should take precedence over the Minerva's
$wgMinervaAlwaysShowLanguageButton config.
Bug: T214540
Bug: T221792
Change-Id: Id4fe8b67a17f9c28c00a8a3a207946e146502cde
The MainMenu is built using Builder pattern. The hamburger icon
is always the same, and it should be defined in the Menu builder,
not as a separte UI element.
For better code organization, all things related to MainMenu
building should stay in the Menu Director/Builders, not in the
SkinMinerva class.
Changes:
- moved hamburger icon build method into MainMenu/Director
(as the menu icon is the same for all builders)
- renamed stuff in BaseTemplate for better readability
- use MediaWikiServices::getInstance()->getSpecialPageFactory()
instead of deprecated SpecialPageFactory class.
Change-Id: Ie5b30c0dd1649d38a4023ccb40c99dee2a127a70
Is used only in Minerva, and it's so simple, there is no need to
have a special function for that (no improvement no performance,
nor readability)
Change-Id: Id5a4edb077671dc12f58df31273f00a1a816f097
We can define return types using `function(): TYPE` notation.
We should do that when it's possible.
For now, it's not possible to type nullable return type (PHP7.1
supports that, but PHP7.0 and most probably HVVM doesn't),
Change-Id: I6b58a882383832313ef47a296c726a4044a97954