Commit graph

4662 commits

Author SHA1 Message Date
Translation updater bot 71665e3285 Localisation updates from https://translatewiki.net.
Change-Id: If3191f89b931a3d78e8310774f797dd991547ce9
2023-10-31 09:11:03 +01:00
Translation updater bot 898d04ed3d Localisation updates from https://translatewiki.net.
Change-Id: Iaa53430d1c6f5cb03fe4f1ae0a29138b1afeccff
2023-10-30 18:01:28 +01:00
Translation updater bot 9937683cad Localisation updates from https://translatewiki.net.
Change-Id: I2be6425832f8d50634eeaeb0ea8304ec67e4948d
2023-10-30 13:53:56 +01:00
jenkins-bot db86c92704 Merge "Simplify teleport styles" 2023-10-27 20:43:59 +00:00
Moh'd Khier Abualruz 2690b5559e Remove trident-hack font-size from Vector
- The Less variable @font-size-base--trident-hack is removed
-  All instances of font-size: @font-size-base--trident-hack; usage is removed from Vector 2022

Bug: T349010
Change-Id: Ie131b8f0dbb4d8050d33df969c1c49963ddc95e2
2023-10-27 14:03:14 +00:00
Translation updater bot d61dcc801b Localisation updates from https://translatewiki.net.
Change-Id: Ie1451a36c558f3d0dc01b2bb104ad325094f5d10
2023-10-27 09:24:15 +02:00
jenkins-bot 1db7b69286 Merge "Trigger window.resize when toggeling pinnableElement" 2023-10-26 16:47:14 +00:00
Translation updater bot 7b786b5823 Localisation updates from https://translatewiki.net.
Change-Id: If6c66b7cd04e63bb20ef546ca3551ce340a6c211
2023-10-26 11:09:48 +02:00
Volker E b55d95c70c styles: Replace legacy Vector breakpoint tokens where applicable
Replacing the legacy Vector breakpoint tokens with the Codex
standard ones. All names have been unified, only some legacy values
remain for backwards compatibility.
Also
- replacing a wrongly applied min-width with the correct max-width
  token,
- replacing a width with an equal value min-width one and
- removing the now equal value mobile min-width one.

Note that we can't do some reference magic here alike
`@max-width-breakpoint-mobile: @min-width-breakpoint-tablet - 1px;` as
this would take the Codex value from skin variables and not the legacy
value.
Also note, that we could move all those Vector legacy definitions into
Vector's 'mediawiki.skin.variables.less' file(s), but that would mean
that extensions don't rely on the Codex default values, but on Vector's
and we want latter to move to the standard, also in foresight of
further standardization to build for all feature teams like a
shared Grid.

Bug: T331403
Change-Id: Ifb968b1977001edb1a79e20df387c61f27043542
2023-10-25 22:03:46 +00:00
jenkins-bot 0eb580f4f7 Merge "Update pinnableHeader class when moving pinnableElement." 2023-10-25 18:36:00 +00:00
Jan Drewniak f59ceb4390 Update pinnableHeader class when moving pinnableElement.
Adds functionality to update the pinnable header class
(pinned or unpinned) after is has been moved via
movePinnableElement().

Bug: T348039
Change-Id: I23552bdbb3390222c2c8efbd5f9122a4d5021a00
2023-10-25 17:44:12 +00:00
Jon Robson 329d91c99c Vector 2022: Support dropdown creation via addPortlet
Vector 2022:
mw.util.addPortlet('p-twinkle', 'TW', '#p-cactions');
mw.util.addPortletLink('p-twinkle','#', 'Hello world');

Or if preferred it can be added to the pinned menu
mw.util.addPortlet('p-twinkle-pinnable', 'TW', '#p-tb');
mw.util.addPortletLink('p-twinkle-pinnable','#', 'Hello world');

Bug: T342815
Change-Id: Id58515e72bfbd5f700aa573a122529c6efdfea9d
2023-10-25 15:44:45 +00:00
Jon Robson 6cf1757eed Simplify teleport styles
.vector-body is applying to the teleport target and
that in turn sets to the font size and z-index meaning
these existing rules are now redundant.

Depends-On: I17d78ac94e2fa8ca0558306497beb278fef40969
Bug: T348289
Change-Id: I174a1c125e4ee451ec9b203654f6eff2d335bb5d
2023-10-25 12:36:05 +00:00
jenkins-bot 1eb75ab7b1 Merge "Vector legacy: Support dropdown creation via addPortlet" 2023-10-25 10:15:05 +00:00
Jon Robson cb8a500e7a Vector legacy: Support dropdown creation via addPortlet
Vector:
    mw.util.addPortlet('p-twinkle', 'TW', '#p-cactions');
    mw.util.addPortletLink('p-twinkle','#', 'Hello world');

Additional changes:
* Add aria labels to gadget created menus

Additional changes to template
* Remove self closing tag on input[checkbox] in template
* Rearrange vector-menu and vector-menu-dropdown classes
for consistency between two approaches

Bug: T342815
Change-Id: I938928c3625099ad49bec8aafb11f91190a9f494
2023-10-25 10:39:30 +02:00
Translation updater bot ffdb3f05e5 Localisation updates from https://translatewiki.net.
Change-Id: I6d31eefa93f3183d72f7b11d932630934841ac33
2023-10-25 09:04:13 +02:00
Jan Drewniak 751454d7a8 [Visual change] Normalize small font sizes in Vector 2022
Replaces font-sizes that are between 12-14
px with ones that equal 14px. This involved
converting some values to rems as well as changing
their size.

@font-size-tabs (a computed 13px value) is removed
in favour of unit( @font-size-small, rem).

This removal requires the following changes:

* Removing max-height & box-sizing from tabs, since
  they used @font-size-tabs for size calculations
* modifying .mixin-vector-arrowed-dropdown-toggle()
  to use `unit( 12 / @font-size-browser, rem )` instead
  of `unit( 16 / @font-size-tabs / @font-size-browser, em )`
* Changes to the position of `.vector-toc-toggle` since
  it's width/height depended on
  .mixin-vector-arrowed-dropdown-toggle()

Opportunistic refactor:
- `.mixin-vector-legacy-menu-heading-arrow()`
  is removed from Zebra

Expected visual changes:
font-sizes below refer to computed values, actual values
are now set in rems.

* Text in tabs is 14px not 13px
* #siteSub is 14px not 12.8px
* #contentSub is 14px not 11.76px
* #contentSub line height is default, not 1.2
* dropdown [hide] labels are 14px instead of 13px

*************************
*****VISUAL CHANGE*****
*************************
: 91 changes in Pixel due to content being pushed
down due to bigger font-size in toolbar.

Bug: T346062
Bug: T261334
Change-Id: I6cfc800bb8dfed206670e5365bdc55e5d7357a4a
2023-10-24 22:50:15 +00:00
jenkins-bot 0c4b6d9874 Merge "Introduce CSS custom properties under font-size feature flag" 2023-10-24 19:03:16 +00:00
Jon Robson 076f957c5d Drop p-namespaces backwards compatibility script
Bug: T347907
Change-Id: Ib2bec20315440f89a0ca375f0e2b65b7a041006d
2023-10-24 18:43:28 +00:00
jenkins-bot 319fd57e0f Merge "Follow-up to 74b5834: Add language prefix to Readability survey" 2023-10-24 17:58:05 +00:00
Jan Drewniak b4fe7c35b9 Follow-up to 74b5834: Add language prefix to Readability survey
Changes the language of the preload page
based on the wikis content language.

Bug: T349232
Change-Id: Ie4233e6e31f57d09c319835c03c427dc7e83aea9
2023-10-24 16:50:29 +00:00
jenkins-bot 91658a803f Merge "styles: Remove references to WikimediaUI Base and use skin variables" 2023-10-24 16:50:17 +00:00
Jan Drewniak 2223cb8c1b Introduce CSS custom properties under font-size feature flag
Introduces CSS custom properties for the purposes
of enabling client-side customizable font sizes.

CSS custom properties are contained in a Less file,
which imports values from Codex and converted them to rems
using the Less unit() function.

Includes ADR on CSS custom properties decisions.

Bug: T348984
Change-Id: Ic5e62d55f3c3585fe3a00e41f29f88d3a2f7470b
2023-10-24 14:33:33 +00:00
Translation updater bot f0603ed967 Localisation updates from https://translatewiki.net.
Change-Id: I5063b5675b9325d10b6960382c44b9aa4fa95bb4
2023-10-24 09:40:56 +02:00
Translation updater bot 169dadb88d Localisation updates from https://translatewiki.net.
Change-Id: I6b3ec523107c7d231e3f3507b03e9ec9f919fd5e
2023-10-23 09:53:41 +02:00
Volker E eb8f186a79 styles: Remove references to WikimediaUI Base and use skin variables
Removing all references to WikimediaUI Base and replacing them with
the Codex equivalents.
Also removing variables redefinitions that are not needed anymore.
Only value difference is a last family added before general fallback
called 'Source Serif Pro', which basically will never be visible due to
the general availability of Georgia and Times.
Also removing general font stack comments, see Codex design tokens
comments for these context explanations.

Bug: T334934
Change-Id: I61aa44e40830ffdb308aaea4ca30af0f25ba2274
2023-10-22 19:18:03 -07:00
Umherirrender ae1584ade5 Simplify SkinVector22::isTocAvailable
No need to check $tocData for empty before checking if a key is set on
the array, as empty suppress the error when $tocData is null

Change-Id: I3f1fd4bfdfd7f29e6750d72af75c286668b5f09c
2023-10-22 16:50:22 +02:00
Umherirrender cb8fc5c8c1 Replace empty() with falsy check
empty() should only be used to suppress errors
When the type of the variable is array,
a falsy check is the same (checks for null, false and empty array)
Found by a new phan plugin (T234237)

Change-Id: I84ced7c17157b322f858640362e1013e37773d43
2023-10-22 11:45:42 +02:00
Umherirrender b962638262 Replace empty() with a string compare
empty() should only be used to suppress errors
Found by a new phan plugin (T234237)

Change-Id: I10b562aa04eb9cf974e301567e74f2f620027ba8
2023-10-21 20:26:30 +02:00
Translation updater bot 97f8f4e6b5 Localisation updates from https://translatewiki.net.
Change-Id: Idb93ff9284fd46b391825c298e4eecc3ae3dfa8a
2023-10-20 09:23:58 +02:00
jenkins-bot 8b9cbc7150 Merge "Make Vector feature flags compatible with beta features" 2023-10-19 17:22:49 +00:00
Moh'd Khier Abualruz 173c91a0f5 Make Vector feature flags compatible with beta features
- Added Key 'beta' to features config in skin.json. As usual this also supported by global configs.
- Added feature management logic to check for beta feature enabled status and the user's selection of utilising the vector beta features.
- Added VECTOR_BETA_FEATURES to Constants.php which is an array that holds features names that would be enabled.
- Removed final from class declaration of OverridableConfigRequirement class, as it does interfere with the mocking in the current setup

Remaining Work:
- Missing images to be added in the hook to show in beta features under Special:Preferences -- this will be added in a followup

Bug: T347772
Change-Id: I7bf8284e328c66c019c392f57207cab21ce0d4f6
2023-10-19 18:22:57 +02:00
Translation updater bot f8dd7725f3 Localisation updates from https://translatewiki.net.
Change-Id: I84ad95c5f32eb0614a0dcc2bc21328acab84ff00
2023-10-19 08:46:36 +02:00
Jan Drewniak 3712de4b23 Use Architectural Decision Records in Vector
Change-Id: Icd14a471074684e063804259050e6944393654af
2023-10-18 18:08:53 +00:00
WMDE-Fisch 7e63cdb219 Trigger window.resize when toggeling pinnableElement
The width of the screen changes when the pinnableElement is pinned
or un-pinned. Other features may need to react to this, like for
example the RevisionSlider extension.

Triggering a window.resize is a generic way to make sure these
changes can be handled by other elements on the page.

Bug: T336729
Depends-On: Iba22924b660f2709c0680aa6fbeb0feba92cfa76
Change-Id: I49878fdd8794273919bf961648fd93fdcf9511af
2023-10-18 13:39:06 +00:00
jenkins-bot ce5c5dba93 Merge "Add multiple font size to logged-in users" 2023-10-17 21:56:42 +00:00
Moh'd Khier Abualruz 22e97fe383 Add multiple font size to logged-in users
Read Value from user preference for logged-in users.

Depends-On: I041a0cb21e872700ceeeddd3a39922e456aa7bb8
Bug: T346954
Change-Id: I6afa39624c3cadd31632d63a36b919d641983ae6
2023-10-17 19:42:30 +02:00
Jan Drewniak 74b58348f6 Add language prefix to Readability survey
Changes the language of the preloaded form
by using Special:MyLanguage.

Bug: T347208
Change-Id: I34759fc17f2078eb34dfcf4f8d86dfb082eeb6d6
2023-10-17 12:26:28 -04:00
Jon Robson 004b4c96f3 Add multiple font size to frontend
Use integer value going forward as it will be easier
to manage.

Bug: T346954
Change-Id: I041a0cb21e872700ceeeddd3a39922e456aa7bb8
2023-10-17 12:43:02 +00:00
Translation updater bot 77ea8245a6 Localisation updates from https://translatewiki.net.
Change-Id: I235d3a6e3fdbbed4345184843a3677161b87ae89
2023-10-17 09:37:08 +02:00
jenkins-bot 48f2a52c96 Merge "Simplify TOC design for pinned TOC on no js small viewports" 2023-10-17 04:11:30 +00:00
Jan Drewniak 8a3e24e346 Simplify TOC design for pinned TOC on no js small viewports
Bug: T340571
Change-Id: Ie34d7d478b3a73cade9f5328439515e419692eb7
2023-10-16 23:31:18 -04:00
jenkins-bot 23aae68630 Merge "Add config option to disable Readability survery & minor fixes" 2023-10-17 00:29:18 +00:00
jenkins-bot 79dad6453c Merge "Define stable and internal APIs" 2023-10-16 17:42:42 +00:00
Translation updater bot 07d2e24316 Localisation updates from https://translatewiki.net.
Change-Id: I8296b2578b40664490db816ac1f1ac342ba29510
2023-10-16 09:18:32 +02:00
Jan Drewniak dcdcecd3db Add config option to disable Readability survery & minor fixes
Adds a config option to control the Readability prototype
survey tool on a per-wiki basis.

Minor fixes:
- Adds missing i18n messages to the tool for slider labels
- Ensures tool only runs on Vector 2022 skin
- Wraps the initialization in an IIFE

Change-Id: Ia65a0043dab5e9a23d4ef401ed83914e4f3d2882
2023-10-16 00:45:59 +00:00
jenkins-bot 6b9055e593 Merge "Allow user preferences to be overriden by query string parameter" 2023-10-13 17:33:12 +00:00
Translation updater bot deace145fb Localisation updates from https://translatewiki.net.
Change-Id: I3e1f057b29f755172b8178bd3a52643f6568f984
2023-10-13 09:00:06 +02:00
jenkins-bot 48a3efbae2 Merge "Vector sticky header dynamic edit icons order" 2023-10-12 19:18:03 +00:00
Jon Robson 411f9ce69a Allow user preferences to be overriden by query string parameter
Currently only features that are associated with LocalSettings configuration
can be overriden by query string. Going forward we'd like to expand this to apply
to user preference too.

A generic OverrideableRequirement is created.
The existing OverridableConfigRequirement is refactored to extend OverrideableRequirement
The /UserPreferenceRequirement now extends it

This allows http://localhost:8888/wiki/Spain?vectortypographysurvey=1
to work

Bug: T347900
Change-Id: I11efd6b07192d5d2333f4506e9d87a8c0638d657
2023-10-12 19:05:10 +00:00