Commit graph

69 commits

Author SHA1 Message Date
Jan Drewniak 84b2d81809 [Prototype] Edit project link page on reading prototype
Changes project page link to use Special:MyLanguage

Change-Id: I99322f3492b85bd65828453a98d3cba50b9525c7
2023-10-05 14:31:22 -04: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
Amir E. Aharoni 7fff1fd15a Correct a recently-added message
Change-Id: I415c664823c5dd79905ec46926c1deb7ec83681e
2023-10-02 19:06:17 -04: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
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 7fc6bb0a6a Update label for Page tools navigation region
- Set aria-label to read 'Page tools' in the nav elements

Bug: T330326
Change-Id: I99119aebe98b329d6d1f4e2f8c9f37f77692e8ab
2023-09-05 18:41:38 +02:00
Moh'd Khier Abualruz d800e8b34f Update Vector localization message language redirect to top
- Update (vector-language-redirect-to-top) to be shorter and more accurate

Bug: T330805
Change-Id: Ibae37b7e4b148ef7ebfc13b8f929e3b694685731
2023-06-23 18:29:45 +02:00
Jon Robson 2622472983 Point out the limited width control
The limited control will be pointed to on page load
When wgVectorPageLoadIndicator is set to true (defaults
to false)

Clicking the button should show the indicator.

Additional change:
* Update config.json to reflect new state
(Follow up to 28ada2dc)

Bug: T333601
Change-Id: I188ed7226b9a1530e54b1aaa80caa0830bf73633
2023-04-14 17:15:56 +00:00
Moh'd Khier Abualruz 25f5f4975a Add indicator that appears when TOC & page tools menu have been hidden
Show a popup to the user to point them to the new location of the element

Bug: T311160
Change-Id: I967d027b23931d99767b31bd7a6af5f6410c8f5d
2023-03-23 21:46:51 +00:00
NikG d39b5c958a Update language dropdown for pages not supported in other languages
Pages that are not supported in other languages should not display the
ULS when the language button is clicked. Instead, a simple message
explaining that the page contents are supported in other languages
should be displayed inside the dropdown. Additionally, the language
button should be modified for these non-content pages, to non include
any label and be quiet instead of progressive.

This patch implements these specifications by appropriately modifying
the mustache templates and the underlying skin classes.

Bug: T316559
Change-Id: I37d8e61a1287b31d1a304d2a955f532b9b8fa505
2023-01-06 16:40:36 +00:00
Jon Robson cf56a37b00 Add label and title attribute/tooltip to full-screen toggle button
Bug: T323625
Change-Id: If12837cd0e3c443a023671b2a9ab85098ffd6119
2023-01-05 00:56:39 +00:00
Nicholas Ray a25dba2a19 Move toolbox and menus that follow into page tools
Uses all of the changes from Jon's patch in 866503 to move all of the sidebar
menus after and including the tools menu into the page tools component. The rest
of the menus remain in the main menu.

Additionally:

* Per T317898#8468437, the "Tools" label should be "General". It was also
assumed from the prototype that the "More" label should become "Actions"

Bug: T317898
Change-Id: Ic9c1586febd8ebfff4a17285e6bd59cee509bd34
2022-12-14 13:38:13 -07:00
Jon Robson a7f008b9bc Page tools: Main menu is a dropdown
This is an incomplete styling of the menu.

This should be enough to start an initial design
review and unblock other work on the dropdown.

Out of scope for this patch:
- Pinning (being done in T317900)
- Design (will be done in follow up)

This should cause no visual regressions in Pixel.

Bug: T317899
Change-Id: Id7b47cc16fc8cf93d406687198ba37acf7a9cf24
2022-12-07 23:19:29 +00:00
bwang 17bdb31de5 Rename TOC locales to be generic pin/unpin labels, standardize toc label locale name
- 'vector-toc-toggle-position-title' -> 'vector-pin-element-label'
- 'vector-toc-toggle-position-sidebar' -> 'vector-unpin-element-label'
- 'vector-toc-heading' -> 'vector-toc-label'

Change-Id: I4c45fa9a152e26691cc0b62ce8d40d00f8f2e617
2022-11-14 16:26:08 -06:00
bwang 8f5b33fee3 Replace 'more' menu with page tools pinnable dropdown
Bug: T317897
Change-Id: Ia94ebc32041bb3c2f86d461b310766b2d14c66a2
2022-11-10 15:33:16 -06:00
Moh'd Khier Abualruz 6487f962f2 i18n: Remove unnecessary comma in preference description
Follow-Up-To: I3525f8bfe27445e3af83ce5cd34b4da643178fe2

Bug: T321038
Change-Id: Ide81563fdae96d5d8dcb76d18282764349a81352
2022-10-24 15:28:41 +00:00
Func 9afe5a6e87 i18n: Rename some messages to follow common practice
We usually prefix the message keys with the skin/extension name,
and use label/help/tooltip as postfix when needed.
The naming of the tooltip above is limited by Linker::tooltip(),
so not able to rename it. Maybe some work is needed in the core.

Other languages' work will be follow-up by the translation bot.

Bug: T319447
Change-Id: I3c88871540b7668f1699fe3a86a8146f97ff5282
2022-10-19 20:22:02 +08:00
Jon Robson d7f7302cee i18n: Fix typo and simplify preference description
Additional follow-up to 76d1135

Change-Id: Iea478cbfa7ae36b6f1d45ffd74eb58f358ad54f1
2022-10-18 08:21:42 +00:00
Moh'd Khier Abualruz 76d1135810 Create user preference to turn fixed width on and off
Additional changes:
* Move static classes (skin-vector-legacy and vector-toc-not-collapsed)
to skin.json

Bug: T319447
Change-Id: I3525f8bfe27445e3af83ce5cd34b4da643178fe2
2022-10-17 20:02:39 +00:00
Jan Drewniak 98068d9598 Restore navigation landmarks in page toolbar
Adds landmarks to the article toolbar
- Namespace navigation
- View navigation
- More options navigation

Removes the "tools" landmark and associated
aria-label (and translation message).

Makes the #left-navigation and #right-navigation
flexbox to ensure the new <nav> elements, along with
gadgets, align on one line. Moves the styles for
these elements from screen.less to ArticleToolbar.less.

Bug: T317440
Change-Id: Iceff337b0e250c1f368dbaea6cc41a977d8ee868
2022-10-03 10:39:39 -04:00
Clare Ming 1d1585d214 Add feature to hide/show collapsible TOC above desktop
- Add hide/show links to TOC template.
- Add i18n messages for hide/show text.
- Add event listener to TOC js.
- Update relevant TOC collapsed styles.
- Update test snapshot.

Bug: T307901
Change-Id: Ic94fda79bd14856ccda14985d5860aa54d3118d0
2022-07-29 14:19:55 -05:00
jenkins-bot e4b4f5bf9f Merge "Show ULS button when article exist only in single language" 2022-07-27 20:22:02 +00:00
Clare Ming 1297733a65 Add text to TOC collapsible button label for accessibility.
- Provide message translations.
- Include other TOC message that was missing.

Bug: T310810
Change-Id: Ibd612b48ea3ef3f9f31f4bb5791c0cb82e447ece
2022-07-22 10:45:40 -06:00
Santhosh Thottingal 40f6c5e29d Show ULS button when article exist only in single language
When the article exist only in one language, currently we do not show
language selector. This prevents showing the entry points to create article
in other languages by various means.

Show the language selector so that options like translate, interlanguage
links, language settings can be shown.

Bug: T275147
Bug: T290436
Depends-On: I42c5d44ec15e291d71723c9738ddb8f0d1cf0b09
Change-Id: I7fb68457c1203d824fe7433c9f272f300a483c44
2022-07-21 16:28:22 -07:00
Roan Kattouw ce77018b7c Search: Use Codex and Vue 3 instead of WVUI and Vue 2.
[Visual changes]
This should result in 9 visual regression failures relating to
increased height of search results and loading bar

[More details about change]
- Migrate search app from Vue 2 to Vue 3; update tests
  accordingly
- Remove dependence on WVUI and use Codex instead, via the special
  `@wikimedia/codex-search` package
- Update search app to use CdxTypeaheadSearch, which no longer
  takes in props related to the search client or fetch start/end
  instrumentation. Instead, directly use the restSearchClient
  and call fetch start/end events in the search app.
- Handle hideDirection in the search app/API response formatting
  code, not within the TypeaheadSearch component
- Handle showing/hiding the search button in the app
- Move the WVUI URL generator into Vector
- Update server-rendered search box styles to match design updates
  included with CdxTypeaheadSearch
- Replace references to WVUI with references to Codex
- Update values of various LESS variables to match Codex, and update
  searchBox styling to prevent jankiness when the searchBox is replaced
  with the Codex TypeaheadSearch component

The VectorWvuiSearchOptions config variable has been maintained and
will be updated to a code-agnostic name in a future patch.

Bug: T300573
Bug: T302137
Bug: T303558
Bug: T309722
Bug: T310525
Co-Authored-By: Anne Tomasevich <atomasevich@wikimedia.org>
Change-Id: I59fa3a006d988b14ebd8020cbd58e8d7bedbfe01
2022-07-18 12:54:47 -07:00
bwang 93e8cfcd90 Collapse ToC into page title at narrow view ports with CSS/template changes only
Bug: T307900
Change-Id: I72607ec9d8b46401468de5815cf47dac9f4612a5
2022-06-10 15:49:06 -06:00
Nicholas Ray 8038c2e545 Add message for the desktop improvements project's talk page
Vector-2022 skin requires that a link to the desktop improvements page
is shown next to the "Preview" link in the skin preferences options.
Adding this message will enable that.

Depends-On: I4e944504f013344661d0c6f05896a4fc1fe8f4b4
Bug: T307113
Change-Id: I370d820e12e9517d11423977b2fabebaf7df428a
2022-05-13 09:59:54 -06:00
Amir E. Aharoni 4af78713ef Change "Article tools" to "Tools"
"Article" is a Wikipedia-specific term.

See https://phabricator.wikimedia.org/T291304#7905753

Bug: T291304
Change-Id: I678e7bed8c32dee35c7047e3ae5bb1ec5d26f452
2022-05-05 10:20:29 +00:00
bwang d54029a523 Remove nav element from Vector menus and only render label elements in Vector menus when needed. Add new nav landmarks corresponding to user links, main site nav, and article editing tools. Split out legacy Menu template.
Bug: T291304
Bug: T301051
Change-Id: I35c20103e4b45139ef1d3f73c23f6a744aa87a3c
2022-04-27 16:52:20 +00:00
bwang 58b6831e4d Rely on core to provide accesskey/title attributes, update search toggle location in DOM
Bug: T299980
Depends-on: Ide214de5f246b38689799e20db9e8a4671d9b7ac
Change-Id: I43eb04ec095cc9c1d683df9da05887595c2eddfb
2022-04-14 13:53:07 -07:00
bwang f1c70e99b7 Update sticky header to use ARIA attributes for section collapsing and add accessible label to toggle buttons
Bug: T303766
Change-Id: Idda4f286a42152af1d233588a1839ada5491ce95
2022-04-06 17:24:34 -05:00
jenkins-bot cd04b72058 Merge "Table of contents links to beginning of article" 2022-03-24 23:51:52 +00:00
Jon Robson dfdf72140c Table of contents links to beginning of article
Bug: T301254
Change-Id: Icb0b0646f81c1070c8f47dd3297225a074f74773
2022-03-24 20:46:35 +00:00
jenkins-bot 08efa139be Merge "Remove custom handling of aria-expanded in Vector checkbox hack buttons" 2022-03-21 18:03:14 +00:00
Mortal303 ae50914d4e Remove custom handling of aria-expanded in Vector checkbox hack buttons
Removed class "vector-menu-checkbox-expanded" and "vector-menu-checkbox-collapsed" in
includes/templates/Menu.mustache and deleted the necessary lines in
resources/common/components/MenuDropdown.less, tests/jest/stickyHeader.test.js,
includes/templates/skin.mustache, skin.json, i18n/en.json and i18n/qqq.json.

Bug: T299173
Change-Id: Ibf8a08e6e5d1a6c607abf170c030a0285e84ad74
2022-03-21 23:14:51 +05:30
Jon Robson 6855979a92 [i18n] Table of contents heading
Should be translateable

Change-Id: I3c4515f16b5300a44f89ebdcd426a9d8ac6ad138
2022-03-16 17:18:51 +00:00
Ammarpad 5c4d917497 Update Vector SpecialVersion description
Bug: T300994
Change-Id: I3f624013ec4ce408c50d66eca7a91b55b1288ae9
2022-02-09 20:23:09 +01:00
jenkins-bot acbf2fb739 Merge "Changes the labels of the Vector skins" 2022-01-31 19:03:13 +00:00
Clare Ming 588d273360 Fix issues with language alert in sidebar:
- Don't show language alert if:
  - language button is not in header
  - on main page
  - on special page
- Update message with sitename.

Bug: T299581
Bug: T295555
Change-Id: I6290ea440e6b4673f29939376ac47ab53a882001
2022-01-28 13:58:31 -07:00
jdlrobson a357b13ce0 Changes the labels of the Vector skins
In preparation for roll out of SkinMigration everywhere.
(Change to configuration will be done via backports throughout
the week)

Bug: T299927
Change-Id: Iebe60b560069c8cfcdeed3f5986b8be35501dcbc
2022-01-27 19:13:55 +00:00
Jon Robson 1149d3d611 Drop watchlist in user menu feature flag
Working correctly. No longer needed.

Additional change:
* add tooltip to menu

Depends-On: I418ce75bda8015520d1f1742ddcdfefbc8b9a162
Bug: T289619
Change-Id: I42f21ca8836e5042d07102e1516ca386478dfabc
2022-01-19 16:10:32 +00:00
jdlrobson 7d2d50873f Vector is split into 2 skins
A new vector-2022 skin is added. This will be the eventual home
of the new Vector skin when we are ready to migrate.

Please see SkinVector class for the migration plan to simulate this
as part of testing.

Bug: T291098
Change-Id: Ibaddf94a5bfb5e21bbbaf1e0aa1b343a3f566d2d
2022-01-06 15:52:10 -08:00
Clare Ming 9dcfc1ff27 Add language switching alert in sidebar for language in header
- Add i18n messages.
- Update relevant data methods in Vector.
- Update sidebar template + styles.
- Add new template partial for sidebar actions.
- Add feature flag to turn on/off alert.

Bug: T295555
Change-Id: I232ce13770917d51495391f4b8d8d1a3a8a7afb8
2021-12-09 16:37:36 -07:00
bwang b196d68326 Use searchFooterText slot in typeahead search component
- Create new 'vector-searchsuggest-containing' translation for WVUI search footer text
- Use 'search-footer-text' slot in WVUI typeahead search
- Remove instances of old 'footerSearchText' prop

Bug: T290392
Depends-on: I8fb7761e60be330e58cd017872318fe3675c0be1
Change-Id: I9c946f85c3e4a603c362c3ea4b8016c585cdd212
2021-11-12 10:47:55 -06:00
Bernard Wang 7575cf97a5 Revert "Use searchFooterText slot in typeahead search component"
This reverts commit b7728ddda5.

Reason for revert: Depends on WVUI release

Change-Id: If97551a8609433b569fbc88800a7bf9ffc137587
2021-10-13 14:34:08 +00:00
bwang b7728ddda5 Use searchFooterText slot in typeahead search component
- Create new 'vector-searchsuggest-containing' translation for WVUI search footer text
- Use 'search-footer-text' slot in WVUI typeahead search
- Remove instances of old 'footerSearchText' prop

Bug: T290392
Depends-on: Ic92721d5aaf6b833c882a26e9a60b42ab91546fa
Change-Id: I34a184cc8f10172a7ebf67981731c3694d008446
2021-10-06 11:37:26 -05:00
bwang 8e35a09964 Update anon user menu introduction link to be localized and not hardcoded
Bug: T290813
Change-Id: I38bd95abbca0fea68a795986971da02ea25b1c36
2021-09-24 13:40:16 -05:00
Amir E. Aharoni 9afae1fcaf Update the wording of vector-language-button-aria-label
1. "Change article language" can be understood as changing the article
   itself. I'm changing it to "Go to an article in another language."
2. Remove comma splice.

Change-Id: I46c484129ecfda263603defe87c84906c1881c2b
2021-09-21 10:51:11 +03:00
Clare Ming bdc8852a1c Add aria-label to language dropdown menus
- Update portlet data.
- Update menu template.
- Add translatable strings.

Bug: T289523
Change-Id: I9b8f40843609c0192afdabd3117167b933155842
2021-09-15 12:25:23 -06:00
Clare Ming 21c45837ef Spoof aria-expanded for dropdown menus using checkbox hack
- Mimic expanded/collapsed state of menu without JS.
- Update template, styles, i18n to make accessibility of dropdowns accurate.

Bug: T253650
Change-Id: I58ecebf520d6107554dbb81470dee69a5d4a7f1d
2021-09-01 16:12:26 -06:00