Commit graph

2800 commits

Author SHA1 Message Date
Ebrahim Byagowi 845595cb8e Remove an outdated comment
No href will be added on the JS side either.

Change-Id: I4c78fef10c24a942db7e468106588b16012ab653
2024-11-05 14:48:02 +03:30
Ebrahim Byagowi 77b047b12b Remove page href from arrows
As having href causes arrows to be clickable before JavaScript
handler be loaded.

And since that disables visited logic, let's remove it.

Change-Id: Ice4c979d020342890fffd587bb5bee88fcc2a1ae
2024-11-05 13:06:36 +03:30
jenkins-bot cbde447eaf Merge "Remove unused parameter PPFrame $frame" 2024-11-04 17:47:02 +00:00
Fomafix 8c27daf29e Add parser tests
Change-Id: I13e373a38b6486f938ca7d86620e3672de4408bb
2024-11-04 15:38:45 +00:00
jenkins-bot 6f4d131768 Merge "Get mode from data-ct-options instead of data-ct-mode" 2024-11-04 15:20:58 +00:00
jenkins-bot beebea9bfb Merge "docs: Replace CategoryTreeFunctions.php by CategoryTree" 2024-11-04 14:58:30 +00:00
jenkins-bot eea2f1f640 Merge "Add type hint for parserHook" 2024-11-04 14:58:29 +00:00
Fomafix 46defa6251 docs: Replace CategoryTreeFunctions.php by CategoryTree
In 8e51ea4e3a CategoryTreeFunctions.php
was renamed to includes/CategoryTree.php. The class name was already
CategoryTree.

Change-Id: I2734c92810df0f653ae1ea402a149e42e7be08cb
2024-11-04 14:26:13 +00:00
Fomafix a62550b687 Get mode from data-ct-options instead of data-ct-mode
The attribute data-ct-options already contains the mode and attribute
data-ct-mode is just redundant. The attribute data-ct-mode is now not
needed anymore and removed from the rendered HTML.

Change-Id: If261f3cdab6c55243e80dc2ef3caa884538b02bc
2024-11-04 12:08:22 +00:00
Translation updater bot 747421aca3
Localisation updates from https://translatewiki.net.
Change-Id: I57b3419098050a2253210d8b0509c0f51b5b4c2d
2024-11-04 08:21:02 +01:00
Fomafix 2b55cfe576 Add type hint for parserHook
On a self-closing tag the first parameter is null.

Change-Id: I7a8cee1cb517a5b565617cdf5e1b1aeeb03b8de1
2024-11-02 10:19:51 +00:00
libraryupgrader 36364de1a4 build: Updating mediawiki/mediawiki-codesniffer to 45.0.0
Change-Id: I8d5f80585ac6e225942f1d9e3cc63220eac09081
2024-11-02 03:38:52 +00:00
Ammarpad a925bb10cd Fix handling of self-closing tag
self closing tag <categorytree/> is invalid, but where encountered
the content of the tag is null.

Convert the null to empty string since CategoryTree::getTag require one

Bug: T378765
Change-Id: Iede4499952295b75a19bd05a5963caab00a9cadd
2024-11-01 12:41:17 +01:00
Translation updater bot c2b69989fa
Localisation updates from https://translatewiki.net.
Change-Id: I90276a285318228b3cefdac1e2c8661d4c118e51
2024-11-01 08:35:06 +01:00
Translation updater bot d83b34de79
Localisation updates from https://translatewiki.net.
Change-Id: I432c2a82a8b5890b1dff322f9d725c638ff39267
2024-10-31 08:15:26 +01:00
Translation updater bot 67cee5c950
Localisation updates from https://translatewiki.net.
Change-Id: I28c86063aedcdb947585a5e96354ad5f0898a216
2024-10-29 08:39:47 +01:00
Translation updater bot 396f860981
Localisation updates from https://translatewiki.net.
Change-Id: Ife99ccb9b00897392d00eca7a24eac08983be8d5
2024-10-28 08:21:32 +01:00
Fomafix 23ddd8cfd1 Remove unused parameter PPFrame $frame
Change-Id: Ic014850a01fbf5820c2ad77d89ae98e1525dcb7b
2024-10-27 04:42:31 +00:00
Andre Klapper 63688178e9 Use explicit nullable type on parameter arguments (for PHP 8.4)
Implicitly marking parameter $... as nullable is deprecated in PHP
8.4. The explicit nullable type must be used instead.

Bug: T376276
Change-Id: I40bb7a0a02aaa467cbf0ae182adf5601ccbcb58e
2024-10-26 14:43:49 +02:00
Translation updater bot 669a25fa43
Localisation updates from https://translatewiki.net.
Change-Id: I679491d874a30883bbfd511a5933ea45d494581b
2024-10-25 09:46:06 +02:00
Translation updater bot bb36ea0527
Localisation updates from https://translatewiki.net.
Change-Id: I821e55fa005080f7c4e6d6627bc441d2dbb21f8f
2024-10-21 09:19:38 +02:00
Umherirrender 113ece0e54 Use namespaced PPFrame class
Change-Id: I5fff88a0c944cfbda33ffcab1bb6a01e5440a52a
2024-10-19 23:22:14 +02:00
Translation updater bot 8f0dca767d
Localisation updates from https://translatewiki.net.
Change-Id: I4ff3b3e2152cc63fad279b0bda90571c40cf1866
2024-10-15 09:39:49 +02:00
Translation updater bot b8ca605185
Localisation updates from https://translatewiki.net.
Change-Id: I86c3657c6e34ade49adaa484a4eeadd002e80d1a
2024-10-14 09:28:36 +02:00
Umherirrender e745abd03b build: Run stylelint for less file
less is used since 451aeceba1

Change-Id: I0b1af80a776b174a4a716f4698b81c93fa2c4eb0
2024-10-12 13:43:49 +02:00
Translation updater bot 8a5ebf8acc
Localisation updates from https://translatewiki.net.
Change-Id: Ib5bd554d6de0f7eac8ee544c683084d1872fe119
2024-10-11 09:24:28 +02:00
jenkins-bot bcdc686cac Merge "Stay on mode=categories after the first submit with all namespaces" 2024-10-10 16:45:11 +00:00
jenkins-bot 9399909bf3 Merge "Trigger CategoryTree::setHeaders only if subcategories available" 2024-10-10 16:45:10 +00:00
jenkins-bot 5a8fdcab95 Merge "Add link to T290062 on onlyroot deprecation message" 2024-10-10 16:45:09 +00:00
jenkins-bot 12e5a3a1cf Merge "Use namespace for ServiceWiringTest" 2024-10-10 16:45:08 +00:00
jenkins-bot fbc82558e8 Merge "Remove duplicate/unnecessary trim" 2024-10-10 16:45:07 +00:00
jenkins-bot 4d2836760f Merge "Move all Parser handling to Hooks::parserHook" 2024-10-10 16:45:06 +00:00
jenkins-bot ee0a3f1aab Merge "Remove $allowMissing and make the check directly on the hook" 2024-10-10 16:01:18 +00:00
jenkins-bot bb50f5e006 Merge "Remove redundant closure for all modules with packageFiles" 2024-10-10 15:53:44 +00:00
jenkins-bot a6eb9c0e57 Merge "Use ES6 features" 2024-10-10 15:53:42 +00:00
Fomafix 7f52cbc5b7 Stay on mode=categories after the first submit with all namespaces
After the first submit the URL contains &namespaces= with empty value.
This must be handled like a missing URL parameter.

Restore the default value '' removed in aec8d755.

Bug: T334289
Change-Id: I22d0eb334365472d411252f805d0d78a3cc265ab
2024-10-10 14:20:23 +00:00
Translation updater bot 267183e8d9
Localisation updates from https://translatewiki.net.
Change-Id: I9364d158c214b73370ef0b729ca4e8eb3fc0b736
2024-10-10 09:21:18 +02:00
Translation updater bot abb3b265d6
Localisation updates from https://translatewiki.net.
Change-Id: I5ca23a1eab9d219905157a23e2a1cf060b7345bb
2024-10-08 09:41:56 +02:00
jenkins-bot 77c080c761 Merge "Use margin-inline mixin to simplify direction specific styles" 2024-10-06 09:53:08 +00:00
Ebrahim Byagowi bd4efc18ee Define a variable to reuse a value
Change-Id: I2d9c62f5920bf82f564bd01a38a213e7a95b0205
2024-10-06 12:34:27 +03:30
Ebrahim Byagowi 6f8049b2ed Use margin-inline mixin to simplify direction specific styles
Bug: T371265
Change-Id: Iffc9c8ad36ae53b36c9135c206d1c1e02d67b6e2
2024-10-06 11:52:27 +03:30
jenkins-bot 3684f26994 Merge "Make CategoryTree arrow expansion work outside mw-content-{ltr,rtl}" 2024-10-06 06:18:58 +00:00
jenkins-bot c409cf2663 Merge "Make disabled arrow more distinguishable" 2024-10-06 05:42:45 +00:00
Ebrahim Byagowi b66d6a38c4 Make disabled arrow more distinguishable
Change-Id: I2b70195ce5135dc181ef8b80af1aead0304a9cfc
2024-10-06 00:03:30 +03:30
jenkins-bot 7aaf9f42be Merge "Replace use of getDirMark with HTML markup" 2024-10-05 17:32:34 +00:00
Ebrahim Byagowi be7320b4fc Make CategoryTree arrow expansion work outside mw-content-{ltr,rtl}
The old code relies on CSS Janus to transform the default case outside
mw-content-{ltr,rtl} which can't be applied here so let's consider
this case also by relying only on dir attributes, the same direction
as T371265.

In future we can use &:dir( ltr ) and &:dir( rtl ) as we do in new
codes but as that isn't supported on all browsers we support.

Change-Id: Icf6b8e184ce981e6e8f16dafa9e14a19154ff0e3
2024-10-05 16:59:46 +03:30
Fomafix 9c5ccf4b74 Remove redundant closure for all modules with packageFiles
Modules loaded with packageFiles are always executed in module scope
(with a closure), even in debug mode.

The behaviour of non-packageFiles debug mode is the only reason files
have closures.

https://www.mediawiki.org/wiki/Manual:Coding_conventions/JavaScript#Closure

Change-Id: I7ea2057029a63148a96333af7ff09a7885d2daa8
2024-10-05 06:49:13 +00:00
Fomafix 0eb9b7d86c Use ES6 features
Bug: T334853
Change-Id: I48eef3424f4b4028f4ac668a12692af95d79c288
2024-10-05 06:49:00 +00:00
jenkins-bot 5ba10fcef7 Merge "Make category links arrow link to actual categories" 2024-10-04 23:12:32 +00:00
Ebrahim Byagowi fcc3334125 Make category links arrow link to actual categories
I believe having arrows linked to the actual pages can
be much more useful than linking to '#' of the same
page. Linking to the correct page makes user to notice
if the page is already visited also using color of
the arrow.

If we didn't like link visited logic to be not used we
could've used a different link rather than color of links
and going makes us able to :visited logic of
If8b2b45b24351ee5c8fc9ee1380563f5d5b88678 also.

Personally however I'm in believe that having a useful
link that can be opened on a different tab using
Ctrl (or long click on phones) is always more useful.

Change-Id: Ib56fad0b711853d67b2d55617b36deff56141c74
2024-10-05 00:48:31 +03:30