Commit graph

3858 commits

Author SHA1 Message Date
Steph Toyofuku a0837cd3f5 Add tests for getTabsData and dependencies
I recently put up a change and was informed by jenkins-bot that I had
decreased PHP test coverage :/

As I would like to be the type of person that only  increases  test
coverage, I wrote the corresponding tests for my change, as well as the
member functions it depends on.  From what I can tell, this is the
correct method of writing unit tests, but please do let me know if there
is anything I'm missing!

Change-Id: Id5c4f76ae058d2b0d487245c28b9ccecc2deef8e
2024-01-02 15:15:29 -08:00
Translation updater bot 5c5255af9a Localisation updates from https://translatewiki.net.
Change-Id: I3af137f15fe5c3b76a8db473ce5cf386ad41b065
2024-01-02 10:19:52 +01:00
Translation updater bot 08bd800c52 Localisation updates from https://translatewiki.net.
Change-Id: Ib24c8e3223625bed14139614ddf23b941684a646
2023-12-28 14:52:15 +01:00
Translation updater bot 6ed1489588 Localisation updates from https://translatewiki.net.
Change-Id: I7a9b4d1bd57a07c3aaa6fbc273609252803eaa96
2023-12-26 14:45:36 +01:00
Translation updater bot 625d225325 Localisation updates from https://translatewiki.net.
Change-Id: Ie8d7e893a44337c7083aa124cd3651b2270183a3
2023-12-22 17:49:25 +01:00
Steph Toyofuku 2b41416c0d Allow addPortletLink to target tabs/associated pages
Currently `mw.util.addPortletLink` cannot properly add a portlet link to
the associated pages tabs, as there is no `p-associated-pages` id on
mobile.  This change pulls the id from the page data, and adds the
necessary class for the tab to be styled correctly - since tabs do not
have corresponding icons while most portlet links do, we also branch on
this class (effectively on whether we are in the tab container) to
ensure an icon is not inserted

Finally, I added a few comments and spacing in the sections of code that
I touched to make them more readable and resolve some of the linter
warnings, but happy to hear if these are not helpful!

Bug: T340728
Change-Id: I33fc12611a6238552a3eb47f6ca37f087903a92a
2023-12-21 16:37:28 -08:00
Translation updater bot c2a8c42ddf Localisation updates from https://translatewiki.net.
Change-Id: I5f9c5c4e85e355bcd4ba474b5149a5edc7b88015
2023-12-21 19:47:49 +01:00
jenkins-bot 6b3393eb2f Merge "Rework tabs to use unordered list" 2023-12-20 22:06:00 +00:00
jenkins-bot 459d04d121 Merge "History: Make sure entire history row is clickable" 2023-12-20 19:13:06 +00:00
Jon Robson 67403c89b6 Switch to non-compact mode on tablet breakpoint instead of desktop
Bug: T353478
Change-Id: I2b6141f949c663f3d3d720f087d0d0a0936f89f3
2023-12-20 18:42:31 +00:00
Jon Robson 8d305924c9 History: Make sure entire history row is clickable
Bug: T353485
Change-Id: Ie10088636e727c2d5b263426073a02a8f978b692
2023-12-20 18:26:12 +00:00
Translation updater bot d616c5fb0e Localisation updates from https://translatewiki.net.
Change-Id: I7d083ad5cef6eb087863c119f90e3ed097880d26
2023-12-20 14:07:08 +01:00
Steph Toyofuku 88caf181e5 Rework tabs to use unordered list
As part of my work on fixing addPortletLink for tabs on mobile (T340728)
we need these tabs to be correctly designated as an unordered list (note,
this is also how they are rendered in Vector).  In addition, update the
styles to account for the link being nested in a list item now

There should be no visual change as a result of this, but if there is
please let me know!!  I will be testing locally in pixel after pushing
to ensure the change is transparent

Bug: T340728
Change-Id: I922558a59aa909ce76079bab057811d76467f644
2023-12-19 15:28:11 -08:00
Translation updater bot 3e92e969dd Localisation updates from https://translatewiki.net.
Change-Id: Ib9becc64b6ba4e7e25664a4cc9be28c4ae9e0048
2023-12-18 18:22:05 +01:00
jenkins-bot 56a4b8686a Merge "Fix alignment for nearby and settings items in menu, and correctly hide when JS is disabled" 2023-12-14 22:34:13 +00:00
jenkins-bot 73099f12f8 Merge "show article footer on diff pages" 2023-12-14 22:12:15 +00:00
Steph Toyofuku 5e35d585cf Fix alignment for nearby and settings items in menu, and correctly hide when JS is disabled
Removes a `display: inherit` that was causing issues with the alignment of these two items in the menu.  In addition, correctly sets display to none for jsonly-specified list items when client js is disabled and rename the class to make it more specific to the menu items

Note: this will have a visual impact as it is fixing what is currently a visual bug.  The jsonly hiding will also not work with cached content, but since it's currently broken we figured this was acceptable

Bug: T346670
Change-Id: I56d2c4fcba09d199a0fd6aad2f1621509bbfaba5
2023-12-14 21:58:39 +00:00
jenkins-bot edd1b0652e Merge "Show tabs on history page" 2023-12-14 20:47:16 +00:00
jsn c5bced40fb show article footer on diff pages
Bug: T350637
Change-Id: Ib1b75956a2595b4fc51bfe2acfd83b251dcec079
2023-12-14 14:13:19 -06:00
jenkins-bot ab64229a4d Merge "Fix broken reference popup when name contains # character" 2023-12-14 10:45:50 +00:00
Translation updater bot 15d9579a27 Localisation updates from https://translatewiki.net.
Change-Id: Iadda3febc0e43b4993e6f3e768064c3919c6561c
2023-12-14 08:30:04 +01:00
jenkins-bot eadc1b37da Merge "Relax CSS selector to apply to checkboxes as well as radio buttons" 2023-12-14 05:06:00 +00:00
Jon Robson d3b3b93d18 Show tabs on history page
Bug: T353403
Change-Id: I1a9090add87a3ba584a37381fd85f8b52e1f193a
2023-12-13 14:30:55 -10:00
Jon Robson b1b374b5b3 Relax CSS selector to apply to checkboxes as well as radio buttons
Bug: T353401
Change-Id: I520261fabf404c3a4f96ae4449ce9c445e7da270
2023-12-13 14:00:46 -10:00
thiemowmde e0d893c0f5 Fix broken reference popup when name contains # character
The fragment in a URL like http://example.com/foo#bar#baz doesn't end
when there is another # somewhere. That # is part of the fragment.

I'm not sure since when this issue exists. It's already in the first
version of this codebase from 2017, see Iff1f7e6.

Bug: T332007
Change-Id: I3b0726380d2f385475f5ba53aeab16932d7ccaa7
2023-12-12 15:08:55 +01:00
Translation updater bot 14cd6c3a4d Localisation updates from https://translatewiki.net.
Change-Id: Ia0cbb9f8781baf568d7936a1773836ebe557f52c
2023-12-11 10:46:14 +01:00
Translation updater bot 918005815a Localisation updates from https://translatewiki.net.
Change-Id: I46c33d51047092e75c66a968c68c927dc002998e
2023-12-08 14:49:11 +01:00
jenkins-bot a93e9cd07c Merge "Swap conditions in onSpecialPageBeforeExecute" 2023-12-07 17:32:52 +00:00
Translation updater bot cfd9785832 Localisation updates from https://translatewiki.net.
Change-Id: Idd99b840be8e7df4a6381fbb72500f13507c4b4f
2023-12-07 10:06:11 +01:00
Umherirrender b67f2800d3 Swap conditions in onSpecialPageBeforeExecute
Avoid use of the context when not needed as this is also called for
special page transclusion, avoid initialize of the skin in that newly
created context.

Change-Id: I56573491262a194f44bccb7fd6170eb7bf21c6ed
2023-12-06 20:18:52 +01:00
Moh'd Khier Abualruz 41a5ac75c5 Update modules to not use data URIs to reduce bundle size
- Add "useDataURI": false to following modules:
 -- skins.minerva.mainMenu.advanced.icons
 -- skins.minerva.personalMenu.icons
 -- Remove .mw-ui-icon-mf-next-invert old class kept for caching from edit.page.js

Bug: T346162
Change-Id: I362fdc9c68a7483c182e3540cba6501d9b12959d
2023-12-06 00:24:22 +00:00
Translation updater bot ef301a36d0 Localisation updates from https://translatewiki.net.
Change-Id: If3dff83399e65c5cea597340558e175b35ad6edc
2023-12-05 09:18:42 +01:00
Translation updater bot 372cd72d13 Localisation updates from https://translatewiki.net.
Change-Id: Id4c466d1cc7013d708562d858d33c34f23e87fc8
2023-12-04 09:09:09 +01:00
jenkins-bot e38e01daf6 Merge "Show diff switcher on narrow screens" 2023-12-02 22:10:58 +00:00
Fomafix 698a3ea2e3 Use namespaced ResourceLoader classes
The old class names are deprecated since 1.39.

Change-Id: Ie24b28ba27c5ce3c98e57a14117f01f4ca42824f
2023-12-01 13:35:19 +00:00
Translation updater bot c50be58250 Localisation updates from https://translatewiki.net.
Change-Id: Ifcd620cadb37cfc435ba859a63529e5b5610306d
2023-12-01 09:44:26 +01:00
Ed Sanders 86289e7b26 Show diff switcher on narrow screens
The visual diff is sometimes cluttered at narrow widths, but as
we show the switcher on tablet and desktop, and it stores a preference,
users may see the visual diff on phones anyway.

The layout is sometimes cluttered but not completely useless, and
users can always switch back.

As a follow-up we should improve the layout of the visual diff sidebar
on narrow screens.

Bug: T351946
Change-Id: I5533126195331b46040e708b7b35627e74a3001d
2023-11-30 18:43:39 +00:00
gerritbot 6419c847e9 Update UserOptionsLookup's FQN
User-options related classes are being moved to the MediaWiki\User\Options namespace in MediaWiki Core; reflect that change here.

Bug: T352284
Depends-On: I9822eb1553870b876d0b8a927e4e86c27d83bd52
Change-Id: I5a540772aafd2c4686e02f748b5fc61155920397
2023-11-29 12:41:59 +00:00
Translation updater bot 859f07d30d Localisation updates from https://translatewiki.net.
Change-Id: I6d1e3150d5edfacb9cf29fad8c61b5bdfa6c6749
2023-11-29 08:33:39 +01:00
jenkins-bot 3fe16038c0 Merge "Add styles for new heading HTML" 2023-11-28 21:05:55 +00:00
jenkins-bot 6d196bb4fe Merge "Reduce CSS size & specificity for headings" 2023-11-27 20:28:09 +00:00
jenkins-bot dc3ffae59d Merge "Disable another flakey test" 2023-11-27 20:27:15 +00:00
jenkins-bot ea6cf440cf Merge "Revert "Revert "Disable flakey test""" 2023-11-27 20:07:23 +00:00
Bartosz Dziewoński 97aed1ad86 Add styles for new heading HTML
Add CSS to support new HTML markup for headings with section edit
links, which will soon be used by Parsoid page views (T269630)
and by the old parser (T13555). Keep the old rules to provide
temporary support for cached page HTML and emergency opt-outs,
as well as permanent support for plain headings on special pages
and in Parsoid edit mode HTML.

See documentation page for further explanation:
https://www.mediawiki.org/wiki/Heading_HTML_changes

Depends-On: I44587461582d648b56ef0c9c7ae0c322895c69c2
Bug: T13555
Bug: T269630
Change-Id: Ib97d034ab533124f06441e788c8608fb274dccf0
2023-11-27 20:03:16 +00:00
Bartosz Dziewoński 8c6067584b Disable another flakey test
Bug: T348539
Change-Id: Icb79bbd404b445a1c42d52b060475250d155490a
2023-11-27 20:48:05 +01:00
Bartosz Dziewoński 7c645549a6 Revert "Revert "Disable flakey test""
This reverts commit 49e2acf2f4.

Bug: T334634
Change-Id: I672e2a6ad31b02118051a21246d808ea94f0a7e4
2023-11-27 19:45:00 +00:00
jenkins-bot f38f448712 Merge "Restore section edit link styles" 2023-11-27 19:40:02 +00:00
Bartosz Dziewoński 6294ca7196 Reduce CSS size & specificity for headings
Nesting these rules inside `h1, h2, h3, h4, h5, h6 { … }` generated
some enormously long selectors (as the whole selector had to be
repeated 6 times). It's not needed, as these elements do not occur
anywhere else.

Change-Id: I1647e37ff9a0c975d9320e4c34857f210a1858c2
2023-11-27 18:31:54 +00:00
Bartosz Dziewoński d3c5b8a6b2 Restore section edit link styles
The 'edit-page' class is no longer applied to section edit links.
Follow-up to I9f768706c0a0f14f14ee4b3812288218bef36018.

Remove a rule that seems no longer needed.

Bug: T351853
Change-Id: I0891332d613d152374c37f232ed596292d89b583
2023-11-27 19:29:31 +01:00
Translation updater bot a0c0d98f0a Localisation updates from https://translatewiki.net.
Change-Id: Id73c49fcaa246a17598f62cd3dd559e0062f277b
2023-11-27 08:35:55 +01:00