Commit graph

4596 commits

Author SHA1 Message Date
bwang 967fc5d350 Copy common styles into vector
Bug: T345766
Change-Id: Ib7a10d3351ad99c025237ab03ece84c1e2c1e257
2023-10-05 13:28:16 -05:00
jenkins-bot 18a310a42d Merge "Prevent legacy tab expand/collapse infinite loop if they have a border/margin" 2023-10-04 17:55:55 +00:00
Jan Drewniak 0232752097 [Prototype] Add screen resolution to Typography prototype
Adds screen resolution (`${window.innerWidth} x ${window.innerHeight}`)
to the prefilled feedback form for the typography prototype.

Change-Id: I38ec6fe5232c1d90df6d5d56b0f0cb32acdcc64e
2023-10-04 12:38:09 -04:00
Translation updater bot e2fc864c2d Localisation updates from https://translatewiki.net.
Change-Id: If33111cc8451b7f278317c07d37c78bc5585a18b
2023-10-04 09:12:07 +02:00
jenkins-bot 825e1dfad8 Merge "Preferences set to "disabled" return false when isEnabled is called" 2023-10-04 00:56:06 +00:00
Jon Robson 735dad995b Preferences set to "disabled" return false when isEnabled is called
The font size preference sets a preference to disabled rather than 0.

Rather than save this as 0, it would be useful to store this as a string
given in future it will evolve to have values small, medium, large

Change logic in UserPreferenceRequirement to support non-binary options.

Bug: T346987
Change-Id: I399aa1b1be4a45cab0aa3b8addb482e5af6c5bf3
2023-10-04 00:34:16 +00:00
jenkins-bot 111201d910 Merge "Remove unnecessary imports in component stylesheets, make variable and mixin imports consistent" 2023-10-03 21:35:24 +00:00
jenkins-bot fd006b5f29 Merge "Add columnStart container and update grid styles" 2023-10-03 19:30:06 +00:00
bwang 5e15edb9a2 Remove unnecessary imports in component stylesheets, make variable and mixin imports consistent
Bug: T345766
Change-Id: I2ae1d1668849a04520b73ac04fe16e1ff7f22fa6
2023-10-03 19:13:21 +00:00
Jan Drewniak a04ff40809 [Prototype] Change i18n message
Edits the translation message for the
readability prototype.

Bug: T347208
Change-Id: I961c656d529bb0e11baafbdefb89dbc347a2c12c
2023-10-03 14:07:37 -04:00
jenkins-bot 2226b02777 Merge "Correct a recently-added message" 2023-10-03 14:19:38 +00:00
Translation updater bot db4de55661 Localisation updates from https://translatewiki.net.
Change-Id: I241ceea07c068ec43b0fe1c15c65f4ed8e307330
2023-10-03 09:34:48 +02:00
Amir E. Aharoni 7fff1fd15a Correct a recently-added message
Change-Id: I415c664823c5dd79905ec46926c1deb7ec83681e
2023-10-02 19:06:17 -04:00
Jon Robson e5a849ff79 Codex-search NPM module was deprecated, use codex instead
Change-Id: I0dfb2c8372a423630db093ae1af82385293b017b
2023-10-02 22:41:54 +00:00
Jan Drewniak d4246e6ca6 Web typography prototype survey
Creates an interactive prototype for gathering
feedback on users typography preferences.
This prototype is meant to be temporary and is
built soley for feedback purposes for the
WMF Accessibility for reading project.

The prototype code is:
- for logged-in users only
- hidden under the API user preference "vector-typography-survey"
- disabled by default

It is intended to be enabled via a banner that calls
code similar to:
    new mw.Api().saveOption( 'vector-typography-survey', 1 )

Bug: T347208
Change-Id: I8d8914a0fa16d40cb22ed0e61832bc5bbabe1c78
2023-10-02 10:56:40 -07:00
bwang 3cb6e4c505 Add columnStart container and update grid styles
Bug: T323141
Change-Id: Id6d8736922077b26fb972b6e743cf02d048e669d
2023-10-02 12:30:45 -05:00
Porplemontage 3839f9d436 Prevent legacy tab expand/collapse infinite loop if they have a border/margin
Switching from width() to outerWidth(true) will output the same value for the default Vector legacy CSS, but for tabs given a border/margin with custom CSS, it will prevent an infinite expand/collapse loop at specific resolutions.

Bug: T347793
Change-Id: I97bc01ce4c4117fe2a95dc7f0ff227cbc96ccbb9
2023-10-02 17:28:06 +00:00
Translation updater bot f350556604 Localisation updates from https://translatewiki.net.
Change-Id: I166b1d474fb3690824022488638387573d7493e6
2023-10-02 09:23:52 +00:00
jenkins-bot a3b9e27885 Merge "Add new utility function for detecting pinned elements" 2023-09-30 01:50:39 +00:00
ksarabia a1c2d5ca35 Add new utility function for detecting pinned elements
* Introduces a new utility function, `hasPinnedElements()`, that allows us to check whether there are any pinned elements in the HTML document based on their CSS class names.
* This function will be useful for detecting pinned elements and can be used within WikimediaEvents.


Bug: T346106
Change-Id: I4283cd234ba71acce1e5cbadabf8aeb17cd8d86e
2023-09-29 21:17:24 +00:00
jenkins-bot 7981c9b23e Merge "Add replace .vector-sidebar-container-no-toc with .vector-toc-available and .vector-toc-not-available" 2023-09-29 17:20:46 +00:00
bwang 11f156d5ff Add replace .vector-sidebar-container-no-toc with .vector-toc-available and .vector-toc-not-available
Bug: T318011
Change-Id: Ib07ace50e762c2e9f59e668ad6746574a60a144b
2023-09-29 16:57:42 +00:00
Lucas Werkmeister ca9ba6cc65 SECURITY: Properly escape vector-toc-toggle-button-label
CVE-2023-PENDING

The line param can contain some markup (since headings can contain
markup), so make that a raw param.

Bug: T340217
Change-Id: I9295a8e0f9f00b62d5206f6d7e40bb657f43651a
2023-09-29 09:08:57 -04:00
James D. Forrester 507de0f4e2 VectorComponentTableOfContentsTest: Add mocks for Message:: escaped() and rawParams()
Needed for new security patch.

Change-Id: I9295a8e0f9f00b62d5206f6d7e40bb657f436510
2023-09-28 20:30:48 -04:00
Lucas Werkmeister 124a4efa2f SECURITY: Catch MalformedTitleException from vector-intro-page
CVE-2023-PENDING

If the vector-intro-page message doesn’t parse as a valid title, skip
customizing the menu entry label instead of crashing. (Optionally, this
could maybe log a warning or something later.)

Bug: T340220
Change-Id: I2769c1f3115898bbe697ebe9c9c0eaf0ddc0d251
2023-09-28 23:16:30 +01:00
jenkins-bot 4a16173b7d Merge "Apply body styles to teleported elements in vector legacy" 2023-09-28 15:49:01 +00:00
Sergio Gimeno 30bddf7f35 Apply body styles to teleported elements in vector legacy
Bug: T347199
Follow-up: Ibd5d8c7cc7880678fae498a451cfd417f1f8e1b8
Change-Id: Ief1c88ce7c3110c2e92793bec3994b8b6a548a7d
2023-09-28 12:20:49 +02:00
jenkins-bot 9fa7eaea9f Merge "build: Update devDependencies" 2023-09-27 23:31:01 +00:00
Jon Robson d35db97615 It should be possible to persist Vector font size for registered users
Bug: T346987
Change-Id: I01e0fac5ba781480ee32a8b32f6ef7fafb8d1ca5
2023-09-27 20:04:22 +00:00
Translation updater bot fbc456b666 Localisation updates from https://translatewiki.net.
Change-Id: I45bb66413a7827228c1fb79b1cfd6934d8344fe8
2023-09-27 09:25:12 +02:00
jenkins-bot 618ec9249d Merge "Apply body styles to mw teleport target" 2023-09-26 20:33:57 +00:00
Sergio Gimeno 76c21734d6 Apply body styles to mw teleport target
Bug: T347199
Change-Id: Ibd5d8c7cc7880678fae498a451cfd417f1f8e1b8
2023-09-26 20:16:57 +00:00
Ed Sanders 1cd0d66bb9 build: Update devDependencies
Holding back some packages as they need some work to unbreak tests:
* mustache
* jest
* typescript

Change-Id: If2b9e27bd83c43c6e7d8c0ac1b6d25b2aa74499b
2023-09-26 07:56:34 +01:00
Translation updater bot 0595a86b5e Localisation updates from https://translatewiki.net.
Change-Id: I2de91055da5a7d558b97afd5998ff42277a6db35
2023-09-26 08:46:46 +02:00
jenkins-bot 315eb55b05 Merge "[anon prefs] Update TOC pin/unpin classes for Zebra" 2023-09-25 22:57:20 +00:00
Translation updater bot ec33b0bd78 Localisation updates from https://translatewiki.net.
Change-Id: Icf13ba2a535fde62f6f1553bd341d3de71d8aead
2023-09-25 08:49:23 +02:00
Translation updater bot 5d7018722d Localisation updates from https://translatewiki.net.
Change-Id: I893fa9c68d61b0529b2b51421f8f382ef1119f51
2023-09-22 08:49:51 +02:00
Jon Robson 0f354e3950 Fixes saving of limited width
Bug: T345363
Change-Id: I3fee7e2b3a063d86a8d91ffa832cca4b72b48610
2023-09-21 19:13:38 +00:00
Translation updater bot 9352cc80e3 Localisation updates from https://translatewiki.net.
Change-Id: I36c2ab08b9d829f60dca2b7e909c766f7d94b795
2023-09-21 10:18:44 +02:00
jenkins-bot edad71e454 Merge "Clean up FIXMES now the cache has cleared" 2023-09-20 07:50:12 +00:00
Translation updater bot 639351e214 Localisation updates from https://translatewiki.net.
Change-Id: I289f33ce263c28faf7ede6a7a6ed53fdd3c94704
2023-09-20 08:58:31 +02:00
Jon Robson d6544e4c5c Clean up FIXMES now the cache has cleared
Follow up to Iad8523037ed364f09962b2d6ca0a3d50d7bd2266

Bug: T346401
Change-Id: Ifa4ab87e43cf28143dc7d753e264d4f0957dcbfa
2023-09-19 20:28:56 +00:00
jenkins-bot 8a2da26eec Merge "Disable client preferences by default" 2023-09-19 20:23:29 +00:00
Jon Robson 2edf135018 Disable client preferences by default
Also make code safe to run when the preferences are
disabled.

Bug: T345363
Change-Id: I00554f3d7b0338170c537ae21d937da35303e8e6
2023-09-19 19:52:21 +00:00
Translation updater bot 67660dc6a8 Localisation updates from https://translatewiki.net.
Change-Id: I40090eb9286aa0869de630dbd5de299bff4e45d1
2023-09-19 09:27:48 +02:00
bwang 09781a5a96 [anon prefs] Update TOC pin/unpin classes for Zebra
Change-Id: I15cc4597d75a18f07bf96491df7a21113b0376ba
2023-09-18 16:27:30 -05:00
jenkins-bot 2049e71435 Merge "Feature: Client preferences interface" 2023-09-18 18:10:47 +00:00
Translation updater bot 4a26581901 Localisation updates from https://translatewiki.net.
Change-Id: I36c06378a6d97db19250bc0bf18efa0915d7c584
2023-09-18 08:47:40 +02:00
Jon Robson 65c48d4eb2 Feature: Client preferences interface
Notes:
* This is functional but intentionally not designed until the design
has been finalized.
* A feature flag is added that swaps out the limited width toggle with
a settings cog
* The preferences module is kept in a separate ResourceLoader module
(skins.vector.clientPreferences) to make it more portable for
when we eventually want to add it to Minerva as well.
* Intentionally have not focused on non-jS version given we will
likely revise this again in a future version/upstream to core.

Bug: T345363
Change-Id: I0c793b73e0676e32f031c6168c292f63908c72e3
2023-09-15 10:03:28 -07:00
Moh'd Khier Abualruz c88d72f1d7 [anon prefs] TOC pinned / unpinned
- Status should persist across page views for anonymous users
- Added 'toc-pinned' as a persistable feature in features.js and FeatureManager.php.
- Handling for cached HTML supporting both new and old class names for pinned/unpinned TOC

Based-On: I0fbe0ab458c5bd55d659d3c35a8fbaa6cd6ec0e1

Bug: T316060
Change-Id: Iad8523037ed364f09962b2d6ca0a3d50d7bd2266
2023-09-14 21:37:50 +00:00