Commit graph

1663 commits

Author SHA1 Message Date
bwang ff894e3682 Override default sublist styles
Bug: T364865
Change-Id: I179c059992b2ae614b984b8023774306764ccb57
2024-05-17 15:46:41 +00:00
bwang f13bc5ed80 Remove list-style-image used by ul elements
Bug: T364865
Change-Id: Id365e946e8c71f4812cbb9e4b00618fb73572554
2024-05-15 15:01:40 +00:00
Jan Drewniak 0d1de4773d [Follow-up] Override VE overlays in night-mode
Follow-up to 26d39ec, change VE overlay selector
from `.ve-ui-overlay-global` to `.ve-ui-overlay`.

Bug: T363861
Change-Id: Ie531ce6d03d81fbce374f7e17c785d4bb076bfda
2024-05-14 14:30:56 -04:00
Jan Drewniak 26d39ecafa Override VE overlays in night-mode
Creates a Less variable `@OOUIOverrideSelectors` which can serve
as a list of selectors that we want to treat the same as the `.notheme`
class (as an alternative to adding the `.notheme` class across repos).

Adds only one selector to this variable, `.ve-ui-overlay-global`
in order to force VE overlays to appear in light-mode while night-mode is
enabled.

This is a temporary measure until T363849 is resolved.

Bug: T363861
Change-Id: I3e3a209f1a9bd9130fc61915b9b2ff7134405e59
2024-05-13 21:58:20 +00:00
jenkins-bot 277135ef58 Merge "Fix red link color in dark mode" 2024-05-08 14:53:37 +00:00
bwang 337d608a56 Fix red link color in dark mode
Bug: T363778
Change-Id: Iae4fe2d793b8efbb10b54144ce4093c3e2112da2
2024-05-08 14:31:43 +00:00
Jon Robson 55e6dfd81c Fixes: exclusion logic for anonymous users
Bug: T364159
Change-Id: I7c7e9cff7b99f8e37f3f1ffb93464fd3f31c799b
2024-05-06 12:20:40 -04:00
Jon Robson ca0d404e50 Enable night theme in Vector
- New night theme added via Codex `.cdx-mode-dark();` mixin.
- CSS custom properties separated from skin.less.
- Font-size rem conversion removed since Codex now uses rems.
- bundlesize increased by 1kb ( followup from
Icfcb5c7418061a5727580f0685054356ba4edb72 ).
- Icons that use background-images are inverted for night-theme.
- Linter error fixed for long-lines in clientPreferences.js

Co-Author: <Bernard Wang> bwang@wikimedia.org
Bug: T354889
Depends-On: I1f54bf4f144eaec6ed317c04bd0c851c2f01b42c
Change-Id: I3a8a147b6be67bc830f0d3b816a4b85c26f99cf1
2024-05-02 13:22:59 -05:00
jenkins-bot c3987d472b Merge "Rename client preference menu to appearance menu" 2024-04-29 20:41:19 +00:00
bwang 0109218ab9 Rename client preference menu to appearance menu
Bug: T362808
Change-Id: Id6800d38eebf433cf0c9e3f179dd83df2eefd1fb
2024-04-29 15:38:20 +00:00
Jon Robson e84ec101f7 Prepare variables for night mode
* Drop all hexcodes
* Drop unused background-color-secondary - only applies in legacy
skin and replaced by background-color-secondary--modern
* Drop unused  border-color-content and border-color-content--tabs-inactive -
only apply to legacy Vector skin

Bug: T354889
Change-Id: Ie0accaaac2ac3717b6f034c5832f8c372b91c343
2024-04-25 21:29:23 +00:00
Eric Gardner cb8c7a17fd styles: Remove references to the legacy Codex build
Since Codex switched over to rem units, all differences between the
"legacy" and non-legacy builds of the library have disappeared.

This change removes references to the legacy version of the library
in preparation for the removal of these artifacts from Codex.

Bug: T360806
Change-Id: I158519eddc1738a5daeedb94eb7d2f692e74b84a
2024-04-22 18:41:05 +00:00
libraryupgrader d22fd0d7ab build: Updating npm dependencies
* eslint-config-wikimedia: 0.26.0 → 0.27.0
* @wikimedia/codex: 1.3.5 → 1.4.0
* @wikimedia/codex-icons: 1.3.5 → 1.4.0

Change-Id: I3dbc33dde89f03b188918e29f89434aafc3690a9
2024-04-21 21:57:17 +00:00
Jan Drewniak c3c7462951 [VISUAL CHANGE] Make spacing in UserLinks menus more consistent
Changes spacing around icons in the user-links menus
so that the spacing is more consistently 8px.

Bug: T353987
Change-Id: I860ab858363f0535fd80e3a823cf90f91c2e9a86
2024-04-18 23:49:07 +00:00
jenkins-bot f6c0071bd7 Merge "Add exclusion notice for night mode feature" 2024-04-17 16:44:03 +00:00
Jan Drewniak a3801497b9 Add exclusion notice for night mode feature
If night-mode is disabled on a certain page via the
exclude list in skin.json, then the following class:
".skin-theme-clientpref-excluded" will be added to the HTML element.

In this scenario, the related client-preferences
menu options are visible, but disabled, and a notice
is rendered below the options informing users of this state.

Bug: T361158
Change-Id: I46d335d079a2d27c7a4122e23ac7e479c286b886
2024-04-16 22:38:35 -04:00
jenkins-bot f0673ac58a Merge "Use client preferences for appearances menu" 2024-04-16 18:02:38 +00:00
Jon Robson c8442ba32e Drop background base declaration
This has been confusing a few editors and breaks support with
Extension:DarkMode so let's remove for now.

Change-Id: I84a58b49f8f3d5af8765531bc14c43b42fe39a1d
2024-04-15 16:06:41 -07:00
bwang c69a53a16c Use client preferences for appearances menu
Bug: T361586
Change-Id: I636a557e724f23ea18da135bac59cb304ba81091
2024-04-15 22:36:48 +00:00
jenkins-bot de06d9e104 Merge "Add h1 headings to fix for applying font-sizes" 2024-04-05 07:04:34 +00:00
Arlo Breault ff2e6a48ec Add h1 headings to fix for applying font-sizes
h1 headings can be created in wikitext but are discouraged.  They
nevertheless appear in the corpus.

https://www.mediawiki.org/wiki/Help_talk:Formatting#Level_1

Bug: T359881
Follows-Up: I15eaf43c6750c76363ec804eda9b8ca6ec4709c2
Change-Id: I1caa6809e1be14f87c791faac852610a522d1c5e
2024-04-04 13:19:17 -04:00
Jon Harald Søby 8416fd3796 Add transparent bottom border to .mw-list-item.vector-tab-noicon
Add a 2px transparent bottom border to .mw-list-item.vector-tab-noicon
in order to prevent visible "jumps" when no item in the list is selected
and one is hovering items (thus giving them a 2px bottom border).

Bug: T361841
Change-Id: I5b6ccd6fc68bab399647c270cf5ef573034bb622
2024-04-04 16:17:25 +02:00
Jon Robson 3f7f355a2e Support legacy message box styles markup in JavaScript
Log a console warning to assist developers in migrating to the new
markup.

Bug: T360633
Change-Id: Iaa1a3fc3b910c5fe491459fc82c61bc329f3408d
2024-03-21 18:19:52 +00:00
Moh'd Khier Abualruz b3ab84f9e5 Vector - Rename the skin night mode classes to more readable classes
The classes:
- skin-night-mode-clientpref-0
- skin-night-mode-clientpref-1
- skin-night-mode-clientpref-2
is being replaced with
- skin-theme-clientpref-day
- skin-theme-clientpref-night
- skin-theme-clientpref-os

Other Changes:
- Change vector-night-mode preference to vector-theme
- Add skin-theme-os-label and other messages to skins.vector.clientPreferences
- Remove skin-night-mode-* messages from skins.vector.clientPreferences

Bug: T359983
Change-Id: I31eb086e623a97df9fbd004425559e05b0cae170
2024-03-20 23:54:47 +00:00
Ed Sanders 84c2e0ae05 Remove unbalanced padding from trailing paragraphs in popups
Bug: T360143
Change-Id: Ieed96c8be61ee4883daaa17d82d1d1214ef85869
2024-03-14 11:42:49 -07:00
Steph Toyofuku 1492669009 Reorder client preferences (color above width)
In accordance with the original design, reorder the client prefs so that
night mode is above limited width

Visual change for users who have access to night mode

Bug: T357707
Change-Id: I21a976655734a2accc57d541bacba391961070a8
2024-03-13 16:29:11 -07:00
jenkins-bot c38e0677c3 Merge "Migrate uses of codex-search in Vector to use CodexModule" 2024-03-13 16:27:55 +00:00
Moh'd Khier Abualruz 182bb7519b Migrate uses of codex-search in Vector to use CodexModule
- Loaded new skins.vector.search.codex.scripts module in skin.json, with only the CdxTypeaheadSearch component with codexScriptOnly flag set to true.
- Included skins.vector.search.codex.scripts in the script loading configuration for Vector22 within skin.json.
- Turned off the "interface-message-box" feature within Vector22's skins.vector.styles configuration in skin.json, as Codex now supplies these styles.
- Fix the style selector to add `.cdx-button` to `.vector-limited-width-toggle` in BottomDock.less since using the codex style
- Substituted "codex-search-styles" with "skins.vector.search.codex.styles" in the existing configuration.
- Ensured the availability of skins.vector.search.codex.scripts module for use, marking it in the list of modules in skin.js.
- Modified App.vue to utilize skins.vector.search.codex.scripts instead of @wikimedia/codex-search.
- Update App.test.js.snap to the latest output form
- Update bundlesize.config.json with newest values

Bug: T356677
Change-Id: I7fc223db01171efe6656792530d4b625be4c8edc
2024-03-13 15:58:26 +00:00
bwang 0531fbd117 Increase line height for medium and large font settings
Bug: T359030
Change-Id: I5be2e06c01c1959241d8d5347cb4f37c62c7cee2
2024-03-12 14:25:19 -05:00
Reedy 3ce9fd814f Fix casing of MediaWiki
Change-Id: I1fd944ea6bdd8231d00feb7e5c5b48fbf808d729
2024-03-12 15:44:13 +00:00
Jon Robson 9048285310 Address FIXME relating to use of !important
The !important is no longer needed now that T354975 is done.

Change-Id: I62d9dfd03064167851a34e25751919b73734d1e2
2024-03-08 16:40:39 -08:00
Moh'd Khier Abualruz fb734a46f6 Interaction to Next Paint (INP) Core Web Vital Improvement
According to a Google contact, given we set viewport to 1000px
for mobile devices viewing Vector get a tap delay.

The solution was suggested in https://developer.chrome.com/blog/300ms-tap-delay-gone-away?hl=en
and Peter has confirmed helps improve performance.

A supports query is added to limit this rule to only browsers where
it applies.

Bug: T358380
Change-Id: Ifd7d8951e06e3ba0faaed354492d23e6e0bc8f69
2024-03-07 16:53:06 -08:00
bwang 230c837052 Remove language notice
Bug: T353619
Change-Id: I75430c8b1e66158f798fbe27eec4942a089f3931
2024-02-29 17:04:16 -06:00
Moh'd Khier Abualruz a8eb85f3d5 Replace use of codex-styles in beta feature with CodexModule ResourceLoader
- Add new module 'skins.vector.search.codex.styles' to skin.json
- Added 'skins.vector.search.codex.styles' to bundlesize.config.json
- Replace the old styles module 'codex-search-styles' with the new one 'skins.vector.search.codex.styles' in skin.js

Bug: T353844
Change-Id: If3cbcac64242c403b42811159882741fda132555
2024-02-27 17:40:11 +00:00
Moh'd Khier Abualruz cb8be96f3c Table of contents button goes transparent on hover
- Exclude the checkbox in the TOC from the hack done in https://phabricator.wikimedia.org/T333394
- This patch might not be needed as a restructure of codex import to vector could resolve most of the issues

Bug: T344066
Change-Id: I35b2ffa7a761e3ea1460fa97642966486791bab9
2024-02-23 14:10:21 +00:00
jenkins-bot baf9430f30 Merge "icons: restore "background-" CSS rules" 2024-02-22 16:43:09 +00:00
jenkins-bot f10d65e067 Merge "Move pinnable element spacing from the pinnable element to the container" 2024-02-22 15:33:35 +00:00
Eric Gardner d60a644264 icons: restore "background-" CSS rules
Temporarily hard-codes some CSS background rules after Codex's
CSS-icon mixins stopped supplying them upstream (after changing
to use mask-image in icons).

Bug: T358160
Change-Id: I13be424c58b105472ef22f14e4381693f2985cd8
2024-02-21 21:42:46 -08:00
jenkins-bot fea70bcab1 Merge "Do not use vertical gradient mixin" 2024-02-21 00:47:56 +00:00
Jon Robson 9f1b94ce20 Correct how font sizes apply to headings
The margin and font rules are being overriden in DiscussionsTools
using equal specificity. The correction to the load order in
ResourceLoader skin module in
I83ac918ad8807c65aab2cd1dd8d7d2cd34b512af will break this.

Bug: T354975
Bug: T357929
Change-Id: I15eaf43c6750c76363ec804eda9b8ca6ec4709c2
2024-02-20 19:38:56 +00:00
Jon Robson fb9eccc071 Remove redundant site notice styles
These are currently being overriden by styles inside core
which also set margin to 0.

In I83ac918ad8807c65aab2cd1dd8d7d2cd34b512af these would override the
default leading to unintended UI changes.

Bug: T354975
Change-Id: I379ad6293bd1aa2a9304369969978cea684da98a
2024-02-20 09:28:24 -08:00
Jon Robson b49ec394be Do not use vertical gradient mixin
The LESS mixin average is not compatible with CSS variables
so replace the call with the equivalent code.

Change-Id: I148eaca747352ffdc9d1423f20d34bd5a1d0e447
2024-02-16 02:14:30 +00:00
jenkins-bot f004beb8a1 Merge "Provide a visual hint that night mode is being triggered in Vector" 2024-02-14 05:27:47 +00:00
Jon Robson 4a2e3f8917 Provide a visual hint that night mode is being triggered in Vector
Working on feature flag not having this is causing confusion. This
will speed up development by allowing me to more easily determine what
mode I am in at all times.

Change-Id: I5d4168bbf7df41f4754b36c6e6aa4955dbc609bb
2024-02-13 22:52:00 +00:00
Derk-Jan Hartman 73f53882d5 Make vector-2022 mw-indicators flex-wrap
Using an 8px gap by default. 8px is used a few times in vector-2022.
Wrapping is useful for userpages with a lot of indicators.

Bug: T340810
Change-Id: I75b59c633a6ff7a8bfdc624e6e5ba06f35fb6aee
2024-02-13 21:01:32 +00:00
bwang 809576b341 Move pinnable element spacing from the pinnable element to the container
Bug: T354431
Change-Id: I8acdb29fab7a0cd4bc8578a85509847d43abbab2
2024-02-13 14:48:48 -06:00
jenkins-bot 46048e56ab Merge "Callback should only be run after completion of API save request" 2024-02-12 19:35:24 +00:00
Jon Robson 2b4b256d4e Callback should only be run after completion of API save request
Bug: T357212
Change-Id: Icee40b8f9b642e516583998f98cf0072a9e37dee
2024-02-12 08:52:46 -08:00
jenkins-bot a96dcb1099 Merge "Truncate long usernames with an ellipsis" 2024-02-08 19:23:53 +00:00
jenkins-bot 5a24f61c3b Merge "Fix extra space from pinned sticky container" 2024-02-08 17:45:21 +00:00
bwang de4b9faeba Fix extra space from pinned sticky container
VISUAL CHANGE:
* The gap between the title and the text "From mediawiki"
decreases - this is an improvement.

Bug: T357022
Change-Id: I436171448ca69413a004024157b24d502aa63bea
2024-02-08 17:11:47 +00:00
bwang 5012f7fff0 Zebra selector clean up
Change-Id: I6a942913ae2fec066b97c1824a09bb07a8eeef45
2024-02-08 10:49:49 -06:00
Jdlrobson 98817085b7 Changes to list spacing
Update <p> spacing to improve consistency of ul/ol spacing,
also update heading spacing to be more consistent,
relying on mw defaults more

This reverts commit 8d3bda7867.

Bug: T352875
Change-Id: I46bf5e3713b4648e9c3facf5e927e924ba51b23f
2024-02-07 20:21:17 +00:00
bwang e964cbb785 Add Vector night mode feature flag
Bug: T355065
Change-Id: Ica63eb61ee042e8684168f6787b27a5e58e38bee
2024-02-05 11:33:37 -08:00
Ed Sanders 1637b2bbdf Truncate long usernames with an ellipsis
Bug: T356349
Change-Id: I386a8f2165cb29e06e1752050bbd595eae134492
2024-02-01 18:58:46 +00:00
Jon Robson 63b3a23ead Register night mode as a client preference
The night mode setting should only show up if the feature flag
is enabled.

The messages are currently added to Vector, but we may want to upstream
these to core in future.

Change-Id: Idcd53399fa06821bbf5f463d1a242ecf59442c70
2024-01-31 10:14:30 -08:00
Jon Robson 29f73c960b Client preferences accept a callback
In the mobile site we want to show a notification when settings
are changed. In some cases we want to reload the page.

Bug: T350170
Change-Id: I71bd97de8e041d641aded02b8fdf84359f6d830b
2024-01-30 12:31:43 -08:00
jenkins-bot 3961cbcfb4 Merge "Deactivate sticky header menus and search when sticky header is hidden attempt 2" 2024-01-30 19:36:34 +00:00
Bernard Wang 8172710236 Deactivate sticky header menus and search when sticky header is hidden attempt 2
This reverts commit 47e58d53d4.

Reason for revert: second attempt at the patch

Bug: T325083
Change-Id: I2190005fcad41ad61bbd02ea3603e222fc58ceb8
2024-01-30 18:14:21 +00:00
jenkins-bot 851bc5aecd Merge "Revert "Deactivate sticky header menus and search when sticky header is hidden"" 2024-01-30 02:48:24 +00:00
Jdlrobson 47e58d53d4 Revert "Deactivate sticky header menus and search when sticky header is hidden"
This reverts commit 984a8a03ae.

Reason for revert: For anonymous users this was triggering the
error "Cannot read properties of null (reading 'contains')"

Change-Id: I0bd78d195768c95b188208fa6fbab60fb483ed87
2024-01-30 02:24:15 +00:00
bwang 142591afdc Hide limited width client prefs on screen sizes below 1400
Bug: T355331
Change-Id: Ic32cede70645637bdc887cfef23b1e7385a834a3
2024-01-30 02:14:50 +00:00
jenkins-bot 3d747b504a Merge "Deactivate sticky header menus and search when sticky header is hidden" 2024-01-30 00:56:46 +00:00
jenkins-bot 89def4131f Merge "Fix linter warnings" 2024-01-29 17:38:37 +00:00
bwang c893934ee7 Fix linter warnings
Change-Id: I24c3ecb7858142dc1b90cf1e34456691660157f1
2024-01-29 17:06:53 +00:00
jenkins-bot 293ef7776f Merge "Document button alignment edge cases" 2024-01-29 16:02:44 +00:00
jenkins-bot 4004add15c Merge "Revert "Update <p> spacing to improve consistency of ul/ol spacing, also update heading spacing to be more consistent, relying on mw defaults more"" 2024-01-24 22:27:13 +00:00
Jdrewniak 8d3bda7867 Revert "Update <p> spacing to improve consistency of ul/ol spacing, also update heading spacing to be more consistent, relying on mw defaults more"
This reverts commit ee73437745.

Reason for revert: This patch caused T355805

Bug: T355805
Bug: T354433
Change-Id: Ibe9edcf6c4d8f25c3cc0c35cebb3aadd5dc09b00
2024-01-24 21:15:46 +00:00
bwang a48a96a73e Document button alignment edge cases
Change-Id: Ib25fa1af2d76c9cb449002deeea6900d5e501c3c
2024-01-24 12:26:39 -08:00
jenkins-bot 04ed14432b Merge "Client preferences supports toggle switches" 2024-01-19 22:54:18 +00:00
Jon Robson 8c49b1eb49 Client preferences supports toggle switches
Bug: T350418
Change-Id: I359924874e7232eaee73b7dc3678b9e8e26794ac
2024-01-19 12:56:27 -08:00
bwang 984a8a03ae Deactivate sticky header menus and search when sticky header is hidden
Bug: T325083
Bug: T336965
Change-Id: Ie2cc38b1cadf239f8350d47eba1f2fefc60e1f28
2024-01-18 14:24:36 -06:00
jenkins-bot f2eb6fb2e8 Merge "Generalize skins.vector.clientPreferences library for use in MobileFrontend" 2024-01-18 05:28:00 +00:00
Jon Robson 7d5caf3f66 Generalize skins.vector.clientPreferences library for use in MobileFrontend
Bug: T354224
Change-Id: I6949c4f49ec34b8e47036da4222a5f3ff491af32
2024-01-17 14:51:29 -08:00
bwang ee73437745 Update <p> spacing to improve consistency of ul/ol spacing, also update heading spacing to be more consistent, relying on mw defaults more
Bug: T352875
Change-Id: I1f08681c8145bd95781752cb5728ebc9e84dd218
2024-01-16 19:48:33 +00:00
jenkins-bot 4fdf90c515 Merge "Simplify heading styles. Avoid using .vector-body" 2024-01-16 17:43:49 +00:00
bwang 91c5357917 Simplify heading styles. Avoid using .vector-body
Bug: T352875
Change-Id: Iba444d2324aeb578fa739cb12f1b31fb630c9ec7
2024-01-16 11:16:06 -06:00
jenkins-bot 23d1927e92 Merge "build: Upgrade eslint-config-wikimedia from 0.25.1 to 0.26.0" 2024-01-12 01:47:30 +00:00
Volker E 26f47fe0c3 build: Update 'svgo' to latest v3.2.0
The latest update of 'svgo' dependency includes three optimizations on
converting path commands, which
- improves closing paths and how we determine if to use absolute or
  relative commands.
- round arc or convert to lines based on the geometric sagitta
- convert cubic Bézier curves to quadratic Bézier curves where possible
Also unifiying npm command to qua standard notation `minify:svg`.

Bug: T354875
Change-Id: I4fffd9efd430786911fe36e409d2575bfab719bd
2024-01-11 23:28:28 +01:00
James D. Forrester 1c93d0514b build: Upgrade eslint-config-wikimedia from 0.25.1 to 0.26.0
Bug: T345100
Change-Id: I51fdef33d517ce4f2f50930bc46dddb2f497677c
2024-01-11 14:19:57 -05:00
jenkins-bot cb96b7b379 Merge "Remove cache related FIXMES for CSS" 2024-01-11 12:52:34 +00:00
Moh'd Khier Abualruz 0d7f38ccc2 [Zebra] Remove !important
- Complying to fix me comment

Bug: T347712
Change-Id: Iacd0065b5a736249046ba89bb618bb13f7c0250a
2024-01-09 19:21:20 +01:00
Jon Robson 0ec9d2ecd6 Remove cache related FIXMES for CSS
Change-Id: I0b8bff3e880bef3e97341c24e40405401381006a
2024-01-09 09:48:06 -08:00
Moh'd Khier Abualruz f83cca3cc5 [Zebra] Merge skins.vector.zebra.styles module into skins.vector.styles
Merges all of the styles in the Zebra module into the default styles.

- skins.vector.zebra.styles ResourceLoader module is removed.
- FIXME's related to Zebra styles are removed.
- Top-level "&" that were used for scoping to feature-flag are removed.
- `$wgVectorZebraDesign` feature flag is removed.

Bug: T347712
Change-Id: I0177541ae87a5d070d5317629ca38de93613d620
2024-01-09 15:46:11 +01:00
bwang 5fda9dc241 Fix scrolling behavior in dropdowns
Bug: T352930
Change-Id: I894b91b5faaf86b1c0acaed35bd39756126711f2
2023-12-07 18:50:13 +00:00
jenkins-bot 0108ec3f32 Merge "Remove typography survey" 2023-12-07 16:36:31 +00:00
jenkins-bot cbc858cfaf Merge "Use Codex upstream icon" 2023-12-06 15:32:15 +00:00
Jon Robson dd7a4e9083 Use Codex upstream icon
Don't use icon defined in mixin which can get repeated every
time mixin is imported.

Bug: T352642
Change-Id: I5716a71a8347f519e13687a475d80233813756ed
2023-12-06 14:49:10 +00:00
ksarabia 515af497db Remove typography survey
* Removes code related to typography survey

Bug: T349337
Change-Id: Iae871ec0c61d630078108a5710705b4d3d118a54
2023-12-05 14:32:00 -06:00
bwang badd229bab Fix nonzebra sticky container scrolling behavior and scrollable indicator
- Remove unnecessary CSS from old grid styles
- Consolidate scrollable indicator styles, delete old styles

Bug: T352464
Change-Id: Id33e6d99dba2c680f02b246bbccf26a2aa7e77d9
2023-12-05 19:32:36 +00:00
jenkins-bot a9f7b251fd Merge "[Zebra] Update to 483c6bb Align sidebar TOC with main menu" 2023-12-05 17:00:16 +00:00
bwang 300028a42e [Zebra] Update to 483c6bb Align sidebar TOC with main menu
- Vertically aligns the sidebar TOC
and main-menu text, update after sticky-pinned
container was split into separate elements.
- Consolidate position: sticky and contain: paint styles onto sticky-pinned-container elements

47 expectecd visual changes to desktop-dev

Bug: T351697
Change-Id: I76b3e875f5793d3442e84215447a0ab9fa818300
2023-12-05 16:39:49 +00:00
Moh'd Khier Abualruz 2384a32323 [Zebra] Make .vector-column-start cache compatible
preparing html and css to avoid caching issues
caused by differences between zebra and non-zebra HTML.

Bug: T347712
Bug: T351830
Change-Id: I6f8ae635ba38937729b77ea8517ef2eae0ae12f7
2023-12-04 14:29:06 -06:00
Jon Robson 65908e0c7d Put font size control before limited width control
Bug: T351867
Change-Id: Ieab31c875ab87d3ffc103805e3012089ab118a28
2023-12-01 09:19:51 -08:00
Jan Drewniak 531cbcbd25 Increase "large" font-size option for client-preferences
Increases "large" font-size option from
@font-size-large (18px equivalent) to
@font-size-x-large (20px equivalent)

Bug: T351693
Change-Id: I9e3dd8346b1d6f6a9efd04bb1e43fee9bfd79154
2023-11-30 12:57:37 -05:00
jenkins-bot 35a616368b Merge "Add styles for new heading HTML" 2023-11-28 22:42:11 +00:00
Jon Robson 15250424b3 Fixes: Duplicate events for radio buttons
Bug: T352075
Change-Id: I9cec0b23618162ba74ccd9cd2e27e9171cdc8d6e
2023-11-28 10:09:06 -08:00
jenkins-bot 991419e877 Merge "Adjust .vector-body paragraph margins" 2023-11-27 23:04:03 +00:00
jenkins-bot f647138f9a Merge "i18n: Update copy" 2023-11-27 20:07:00 +00:00
Jan Drewniak 522d655007 Adjust .vector-body paragraph margins
Adds bigger bottom margin (1em) while keeping
the smaller top margin (0.5em) as was previously define.

This keeps the headings close to the paragraphs
while seperating paragraphs from each other.

Bug: T351754
Change-Id: I833372002654ea30deb110af44fb412722bc0ccd
2023-11-27 14:50:03 -05:00
Jon Robson 1c2dff5690 i18n: Update copy
* Switch from "has been" to "has"
* Reorder limited width options
* Change headings
* Change options
* Change copy of beta feature

Bug: T351998
Bug: T351867
Change-Id: I65494a3cc75b661339e48df1bea0e09a365c0657
2023-11-27 11:21:55 -08:00
jenkins-bot e55034f3ad Merge "Fix misc client pref bugs" 2023-11-27 18:07:10 +00:00
jenkins-bot e75b2cda57 Merge "Fix sticky styles for pinnable elements by moving sticky styles into separate vector-sticky-pinned-container element" 2023-11-27 17:56:07 +00:00
bwang a304223f04 Fix misc client pref bugs
- fixes unpinned popup message not showing
- fixes radio button spacing in client pref dropdown in Zebra

Bug: T351141
Change-Id: Ieeb5caaa6ccbd83d28dae41d3ca30791c355fcc6
2023-11-27 11:40:53 -06:00
bwang b23f6f6722 Fix sticky styles for pinnable elements by moving sticky styles into separate vector-sticky-pinned-container element
Cached HTML change

Bug: T351141
Change-Id: I7d2b4417db15aad7ea788ac7adf131de2c702d27
2023-11-27 17:09:26 +00:00
Jan Drewniak edfdf05f12 Implement new font-sizes for custom front-size preference
Adds different font-sizes and line-heights for the custom
font-size UI. The custom font-size preference options are now:

1. Compact - 14px font-size & 22px line-height
2. Standard - 16px font-size & 24px line-height
3. Open - 20px font-size & 26px line-height

This removes the "xl" font-size option
(`vector-feature-custom-font-size-3`) and it's related i18n messages,
and changes the remaining message to match the new options.

The default font-size, when the custom font-size feature is disabled,
is "compact".

Bug: T351693
Change-Id: I5975a78ce7327f314fd55de55c222ac08d801fbd
2023-11-24 15:23:56 +00:00
Moh'd Khier Abualruz e480bfa2b5 Update theme icon for client preferences in user links
- Add appearance.svg file and classes
- Update the icon name in php
- Update icon name in test data and Snapshot

To test: change return value of
  isClientPreferencesPinned() from SkinVector22
  PHP Class to false

Bug: T351142
Change-Id: If61f3019430be3cb9c926b09bc397e27d8e636f2
2023-11-24 15:01:35 +00:00
jenkins-bot 9062e6f96e Merge "Follow-up to 7a8059d76 - Vector increase paragraph spacing to 1em" 2023-11-23 23:35:02 +00:00
jenkins-bot f26a8a0556 Merge "Revert "Vector increase paragraph spacing to 1em"" 2023-11-23 23:27:37 +00:00
Jan Drewniak 78f1f1c671 Follow-up to 7a8059d76 - Vector increase paragraph spacing to 1em
This patch changes the paragraph spacing for Vector 2022
instead of legacy Vector.

Bug: T351754
Change-Id: If205abd17236f9e325cb477b589fa35da246d623
2023-11-23 18:16:00 -05:00
Jdrewniak c3b10b4cac Revert "Vector increase paragraph spacing to 1em"
This reverts commit 7a8059d767.

Reason for revert: Didn't realize this changes the paragraph spacing in the legacy styles module instead of the Vector 2022 module.

Change-Id: I08f2a6b1f43fc088e6552fb6a9011b41ebb698a2
2023-11-23 23:09:03 +00:00
jenkins-bot a4ed8727cb Merge "Vector increase paragraph spacing to 1em" 2023-11-23 16:47:20 +00:00
jenkins-bot 37c2a0016f Merge "Make client prefs fully pinnable" 2023-11-23 16:34:33 +00:00
Moh'd Khier Abualruz 7a8059d767 Vector increase paragraph spacing to 1em
.vector-body p now should have top and bottom margins as 1em instead of 0.5em which translate now to 14px instead of 7px

Bug: T351754
Change-Id: Ifd405d7754f9062d9a84237560495a36d1dab8e9
2023-11-23 11:28:06 +01:00
bwang d2b413a721 Make client prefs fully pinnable
Bug: T351141
Change-Id: Ic4a166fb3234b27dbf3d37891abfdf15781c8867
2023-11-22 14:39:28 -06:00
jenkins-bot 84ce8cdd41 Merge "Fix the toc header underline" 2023-11-22 18:44:26 +00:00
Jan Drewniak 791b9bb0d5 [Zebra] Vertically align sidebar menus
Removes padding from the top and bottom of the
.mw-body element so that the border of the sidebar
menus align with border of the tab area.

Also removes the bottom margin on the sidebar menus
so that the bottom of the menus align with the bottom
of the content. (This was an artifact from the gray
background design).

**Visual Changes**
- The content will move up by 8px with this change.
- The bottom of the TOC will also move down by 24px
  to align with the content.

Bug: T351432
Change-Id: If0a8189b228ffb6fb63dfd8be40955653caa0b34
2023-11-21 18:59:15 +00:00
bwang b74b45d65d Fix the toc header underline
Bug: T340481
Change-Id: Iefbaae291c091b51910180c619993843895c9a20
2023-11-21 17:35:40 +00:00
Jan Drewniak 483c6bb51f [Zebra] Align sidebar TOC with main menu
Aligns the text of the sidebar TOC with the
main menu using negative margins. This only
affects the TOC in the sidebar position.

Bug: T351697
Change-Id: Ie4e78379e8682636ebf72913e995b69e922b4983
2023-11-21 16:02:10 +00:00
Jon Robson 845a0ab71d Make the limited width and font size controls work for logged in users
For time being manage classes inside Vector. Document with FIXME and a
test.

Bug: T351447
Change-Id: Icc084a59a0141ec2b7c772cf92e8cc58c11f15b1
2023-11-21 02:16:52 +00:00
Bartosz Dziewoński 3c2602b682 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: I62d7e8ad7d8f25d145ec1f33230d6043982aec1e
2023-11-17 20:36:56 +00:00
ksarabia 45332cfcb6 Fix alignment issue in Zebra
Addresses misalignment of client pref in zebra

Bug: T350417
Change-Id: Ib4b80b13dc67d00362abf168853c3ae58ae808b3
2023-11-16 13:53:41 -06:00
ksarabia 1a15dbd4d0 Fix sidebar component order
* This moves down the client pref menu
* For now when page tools is collapsed the client preference menu
is hidden. This will be revisited when we implement pinning
in the next sprint.

Bug: T350417
Change-Id: Ic94d6fd2c4ccb667b0ae602d03c564f88a14b8ec
2023-11-16 00:30:28 +00:00
Jon Robson 5a0678c77d Allow client side preferences to render in a dropdown
Known problems:

- For now, this can only be rendered by manually updating
the isClientPreferencesPinned local variable in SkinVector22
This will be addressed in T351141
- The icon is not correct. This will be addressed in
https://phabricator.wikimedia.org/T351142

Bug: T350195
Change-Id: I0b1ec445c4d292bbf417a39dbc5d2032b563f525
2023-11-15 12:50:54 +01:00
Moh'd Khier Abualruz 412c1f2d83 Create a sidebar for user preferences
* Adds mustache for sidebar
* Adds file to render sidebar

Bug: T350417
Change-Id: I691c8a0487e158e96027109c223569224f03a102
2023-11-14 14:33:01 -08:00
jenkins-bot 8664294709 Merge "Remove Zebra A/B test code" 2023-11-13 22:17:52 +00:00
Jon Robson 0a33ffffac Remove Zebra A/B test code
Additional change:
* Remove duplicate A/B test requirement for language in header

Bug: T339957
Change-Id: I0258e71ac0e270682ec1f3bcb0f10198892f058d
2023-11-13 21:56:34 +00:00
Jan Drewniak 6fcecec64e [Zebra] Remove underline from pages with blank title
Removes the underline below the page title if it's blank.

Bug: T351119
Change-Id: Ie177aecc92bd7f18175e1dc875e5f8471b38c7bb
2023-11-13 21:39:29 +00:00
Jon Robson 07a26a9448 Refactor VectorComponentUserLinks to not use hooks
Bug: T350195
Change-Id: I6cbf45587475f0477657a7ce9309b2cd42da33c1
2023-11-09 17:32:10 -08:00
Jon Robson 44d9f74c8f Client preferences: Support different render locations, use Codex
* Refactor client preferences to support different render locations
such as the sidebar or user menu.
* Make use of Codex markup.

Bug: T350195
Bug: T350417
Change-Id: I13eeb9cafc888faba4a5bf0390c1b6db1e3f0259
2023-11-09 19:04:03 +00:00
ksarabia 5e6d6124d0 Remove TOC state from logic
* This makes the function hyper-specific and only looks for main menu
  and page tools pinned states to return true.
* Renames function

Bug: T349924
Change-Id: I8e3a90b71c7f9acc5c217d76ed3a004342c503cd
2023-11-07 13:39:29 -06:00
Moh'd Khier Abualruz 9428bd2a0c Add images to Vector 2022 beta feature
- Add images to resource/images
- Use images in the config of onGetBetaFeaturePreferences for vector-2022

Bug: T349321
Change-Id: Ib359d49719dd5854c3f060f3484c098d93c35c06
2023-11-07 18:47:38 +01:00
Jon Robson 4cf50596bb Avoid nullish coalescing operators
Bug: T350519
Change-Id: If9a8a68aa9c6766b8cf9fb84ed526317d4d723ca
2023-11-06 11:10:44 -08:00
Jan Drewniak cedf6d9438 Change Zebra module to match current Vector styles
Changes the skins.vector.zebra.styles module to match
the current Vector 2022 styles.

**Visual changes**
(All pertaining to zebra.vector.zebra.styles)
- There are no grey backgrounds
- Context boxes with white backgrounds and drop-shadows
  are removed
- Page-tools sidebar width is the same as TOC sidebar width
- Content container is narrowed from 960px to 948px to prevent
  shifting content when pinning TOC or main menu.

Bug: T347638
Change-Id: If6e1ef21f076f6a9f0f8cafb2d745a7c13afb471
2023-11-02 18:15:02 +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
jenkins-bot 1db7b69286 Merge "Trigger window.resize when toggeling pinnableElement" 2023-10-26 16:47:14 +00: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
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
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
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
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
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