Commit Graph

819 Commits

Author SHA1 Message Date
Urbanecm 08329989a7 Revert "Clean up main menu selectors"
This reverts commit 6ebd77ae5a.

Reason for revert: makes the problem worse, per jan_drewniak

Change-Id: I4d82753e7ebf5294d86e37119413410b086be6c0
2022-08-23 21:05:24 +00:00
Urbanecm 18e0cb0df8 Revert "Remove grid row gap in favor of margins"
This reverts commit 6537e8913c.

Reason for revert: makes the problem worse, per jan_drewniak

Change-Id: Icc647f45e423459a2ac266650e0c845d27ce3166
2022-08-23 21:05:10 +00:00
bwang 6537e8913c Remove grid row gap in favor of margins
Bug: T315595
Change-Id: Ibf837775d972deb29e9619cc6c12c919aae5155a
2022-08-23 20:05:43 +00:00
bwang 6ebd77ae5a Clean up main menu selectors
Change-Id: Icb7595f2ef60108f6eaf6b953f37a291678f793e
(cherry picked from commit 2d6be2e6f0)
2022-08-23 17:18:58 +00:00
Jon Robson e0ff7634ac Layout: Restore disabling of max width on certain pages
Bug: T315460
Depends-On: Id3ee4fe97461dbc80f7c163c3585a9df2957bae0
Change-Id: I9bad936c06150cd01d4e60f4a92a5c4d28b5fe16
(cherry picked from commit ecbe2c2855)
2022-08-22 20:14:54 +00:00
bwang 197921bdbe Add back fixed width to main content
Bug: T315653
Change-Id: Iffd3f219e756b82397264f62fb9f88fc82a92ba9
(cherry picked from commit 0be4664c02)
2022-08-19 13:37:17 +00:00
jenkins-bot 8c3a4792e9 Merge "[ToC] Show new/modified sections after publishing an edit (new floating ToC)" 2022-08-16 08:37:30 +00:00
Moh'd Khier Abualruz 407046c759 [ToC] Show new/modified sections after publishing an edit (new floating ToC)
- All Frontend
- All in Skin

Bug: T307251
Change-Id: Icae2f03f0005b7607448127b793ff3c0010e5817
2022-08-15 20:02:49 +00:00
Jon Robson 6cd7098d05 [ToC] Content should be centered when TOC is collapsed
Bug: T314579
Change-Id: I8d182893267f740457b7233c38aa4615f08b814f
2022-08-15 14:53:54 -05:00
jenkins-bot 15ed1cf0e1 Merge "Prevent collapsed dropdowns from having height." 2022-08-15 19:31:24 +00:00
bwang 8eff2d0501 Follow up: Remove .vector-layout-grid, .mw-workspace-container classes
Bug: T313559
Change-Id: If93860d13fb3161c0b66f7ea9e3e1831b0a2fc1e
2022-08-15 10:10:01 -05:00
jenkins-bot e367136406 Merge "Revert "styles: Set `background-repeat: no-repeat` for menu tabs"" 2022-08-11 13:11:06 +00:00
bwang 006ea3517b Add collapsed TOC to sticky header by moving the TOC
Visual changes:
- TOC icon in sticky header
- Small update to the narrow screens collapsed TOC spacing when open

Bug: T311103
Depends-on: Ic94fda79bd14856ccda14985d5860aa54d3118d0
Change-Id: I977092f951ba2843816609e706bce4b99583f623
2022-08-11 11:25:21 +00:00
jenkins-bot 310bf970bd Merge "Remove .mw-ui-button styles from user-links overflow menu" 2022-08-10 07:39:39 +00:00
jenkins-bot 177e57b794 Merge "Refactor TOC A/B test to bucket users on backend" 2022-08-09 10:28:39 +00:00
Jan Drewniak 5676097135 Remove .mw-ui-button styles from user-links overflow menu
Removes the .mw-ui-button styles from the userpage link
and create account link in the user menu.

Overrides the userpage redlink style so that the link
remains blue even if the userpage doesn't exist.

Visual changes: userpage link and create account link
in header are no longer .mw-ui-buttton styles, but
look like standard blue links. The user links menu shifts
slightly because of this as well.

Bug: T312157
Change-Id: Id98e566952e5875527f38d1edbc8f6e058af4518
2022-08-08 22:12:07 -04:00
Clare Ming eb597645c3 Refactor TOC A/B test to bucket users on backend
- Include temporary feature requirement for TOC A/B test.
  - Assumes 100% of logged-in users with even/odd user ids
  being assigned to treatment/control buckets respectively.
  - Sampling rates passed in by config are not considered
  during bucketing.
- Update hook for adding needed TOC A/B test body classes.
- Add test for temp feature.

Note: the temporary feature requirement and associated hooks
should be removed once the 2nd TOC A/B test concludes.

Bug: T313435
Change-Id: If9c75235614af289cd50182baab29bec3155eb81
2022-08-08 15:50:28 -06:00
Jan Drewniak 942cd5b0f6 Sticky header AB test bucketing for 2 treatment buckets
For idwiki/viwiki, we wish to run the sticky header edit button AB
test so that treatment1 group sees the sticky header without edit
buttons, treatment2 groups sees the sticky header with edit buttons,
and the control/unsampled groups see no sticky header at all.

This patch overrides the configuration to make the sticky header
w/o edit buttons for treatment1, sticky header w/ edit buttons for
treatment2, and hides sticky header for everyone else. This depends
on a configuration with the treatment groups having "treatment1"
and "treatment2" as substrings in their bucket names.

The full configuration for idwiki/viwiki would be something like
the following:

```
$wgVectorStickyHeader = [
	"logged_in" =>  true,
	"logged_out" => false,
];

$wgVectorStickyHeaderEdit = [
		"logged_in" => true,
		"logged_out" => false,
];

$wgVectorWebABTestEnrollment = [
	"name" => "vector.sticky_header_edit",
	"enabled" => true,
	"buckets" => [
		"unsampled" => [
			"samplingRate" => 0
		],
                "noStickyHeaderControl" => [
                        "samplingRate" => 0.34
                ],
		"stickyHeaderNoEditButtonTreatment1" => [
			"samplingRate" => 0.33
		],
		"stickyHeaderEditButtonTreatment2" => [
			"samplingRate" => 0.33
		]
	],
];
```

Bug: T312573
Change-Id: I15c360fdf5393f5594602acc33b5b916e904016d
2022-08-08 21:14:02 +00:00
bwang d4d50d2dc5 Fix grid blowout bug
Bug: T314756
Change-Id: If1a84f5c3606dab7195a9b0a320e416fba702027
2022-08-08 18:19:23 +00:00
jenkins-bot 0a7588f55b Merge "Remove vector-layout-legacy styles and grid feature flag" 2022-08-08 17:13:42 +00:00
Jan Drewniak 4bafaa2453 Prevent collapsed dropdowns from having height.
Collapsed dropdowns are hidden via `opacity:0;` and
`visiblility:hidden;`. This doesn't prevent them from having a
height, which can be an issue when the language selector is
at the bottom of the page, producing a large gap near the footer.

Bug: T314546
Change-Id: Iec5d78469c8d5e10bd78e5d062f9e46a54fb3a98
2022-08-08 10:39:29 -04:00
Jon Robson 8a46797eec Express sidebar width in pixel for font size
Bug: T313817
Change-Id: Ic8917bf14eb688f84ca8dfbaea055f93fe829469
2022-08-08 08:25:21 +00:00
bwang ef2b0a2372 Remove vector-layout-legacy styles and grid feature flag
Bug: T313559
Change-Id: I050d0e243186ba4341accc26f8d644f55ff995b7
2022-08-08 08:22:26 +00:00
jenkins-bot f366c2ad9c Merge "Fix collapsible user links issue on tablet breakpoint" 2022-08-08 08:20:21 +00:00
bwang 64566249a3 Fix collapsible user links issue on tablet breakpoint
Bug: T314757
Change-Id: I595d27a03bd607f5b2ab8230e4931a1124222312
2022-08-08 07:59:50 +00:00
Clare Ming 5b55a2f894 Minor fixes to TOC hide/show buttons
Bug: T307901
Change-Id: I37c6b3b4c5c20e914423c311795dbccce2a7b3fd
2022-08-04 15:20:58 -06:00
Jdlrobson 86f39007fb Revert "styles: Set `background-repeat: no-repeat` for menu tabs"
This reverts commit 1f94104cdf.

Reason for revert: I3427b9ca05957b33a95bba4de4ddf87b61b5ccc7 would
be a more future proof solution to this problem.

Depends-On: I3427b9ca05957b33a95bba4de4ddf87b61b5ccc7
Change-Id: Ie09ccad772e25689c89608bba73c5248a55b4a7d
2022-08-04 17:29:56 +00:00
jenkins-bot 1a2b6d59a5 Merge "UserLinksLegacy: Move layout rule into UserLinks rule" 2022-08-04 12:14:43 +00:00
jenkins-bot 6a92bad382 Merge "styles: Set `background-repeat: no-repeat` for menu tabs" 2022-08-04 12:10:25 +00:00
Jon Robson 0be8fe1534 UserLinksLegacy: Move layout rule into UserLinks rule
This is component CSS, not a general layout rule

Change-Id: I3b49989b3265b336810beca2e07f68020600f888
2022-08-04 11:54:44 +00:00
jenkins-bot 4f4317c708 Merge "Only apply sticky header offset if it is showing sticky" 2022-08-04 08:08:46 +00:00
bwang e1e9552bf3 Followup contentSub contentSub2 styling
Bug: T311421
Change-Id: I4319142361b83758bbbe3c1a22e9b6ccab47352d
2022-08-03 20:57:35 +00:00
jenkins-bot a4949503f6 Merge "Update #siteSub, #contentSub and #contentSub2 to fix spacing, conditionally render #contentSub and #contentSub2" 2022-08-03 20:16:51 +00:00
jenkins-bot c71bd6a27b Merge "Followup to ce007e0 - Unify dropdown styles" 2022-08-03 19:04:52 +00:00
Andre Klapper 1f94104cdf styles: Set `background-repeat: no-repeat` for menu tabs
Images are used e.g. by the ProofreadPage extension.

Bug: T314028
Change-Id: I278fff4f02dd91effe5d8ace2f4a21a437a5114b
2022-08-03 19:00:01 +00:00
jenkins-bot 4aeaf4a428 Merge "Ensure collapsible TOC is closed when links are clicked" 2022-08-03 03:15:25 +00:00
bwang b89307c6bb Update #siteSub, #contentSub and #contentSub2 to fix spacing, conditionally render #contentSub and #contentSub2
Visual changes:
- Reduced spacing above #siteSub
- Updated spacing from #contentSub and #contentSub2

Bug: T311421
Change-Id: I7fd78d2c92007b231cfc49af0fbd02a4f74f3901
2022-08-03 01:14:30 +00:00
Jan Drewniak 4aa5602c52 Followup to ce007e0 - Unify dropdown styles
Provide better compatibility with gadgets that create dropdowns
like Twinkle by explicitly setting the font-weight and font-size
on `.vector-menu-heading`.

This is needed because in legacy Vector, menu headings
were <H3>'s, which have bold text and a larger font size.

Bug: T312157
Change-Id: Ic414cef4c7145740812e590f431294bc85a405b4
2022-08-02 16:57:02 -04:00
bwang 37149c9e67 Remove custom rendering of the user links overflow menu in favor of using 'vector-user-menu-overflow', a vector specific menu bucket in Hooks.php
- Rename 'vector-user-menu-more' class to 'vector-user-menu-overflow'
- Update storybook and tests

Visual changes
- Small intentional change on the create account button

Bug: T306662
Change-Id: I371bb11903d8cdd8f0da89266fcf549050c0da8c
2022-08-01 20:18:46 +00: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 9e0d9ebcd4 Merge "Unify dropdown styles" 2022-07-28 21:26:23 +00:00
Jan Drewniak ce007e059e Unify dropdown styles
This affects all dropdowns in Vector 2022, including the
user menu in the header and the language variants and
"more" menu in the article toolbar.

By relying on shared styles instead of separate implementations,
this change also reduces the size of the skins.vector.styles
module by 1.6kB (uncompressed).

Visual changes:
- The links in the user menu are now blue
- Dropdown links in the user menu and tabs are blue
- The dropdown labels in the tabs are black not dark gray.

Bug: T312157
Bug: T308344
Change-Id: I002d5454838a5516b6ee6c7c38721209ed28508b
2022-07-28 16:41:39 -04:00
Jdrewniak c035d8babd Revert "styles: Unify on standard external link icon"
This reverts commit cffd494107.

Reason for revert: Reverting due to how the new icon doesn't scale well at 2x resolution. https://phabricator.wikimedia.org/T261391#8111726

Bug: T261391
Change-Id: I6d49fed2b9e249de15cf40216c01153c7b793ee2
2022-07-28 14:43:51 +00:00
jenkins-bot ee91a813d3 Merge "styles: Replace LanguageButton variable nomenclature" 2022-07-27 20:28:18 +00:00
jenkins-bot e4b4f5bf9f Merge "Show ULS button when article exist only in single language" 2022-07-27 20:22:02 +00:00
jenkins-bot 225efaaabb Merge "Page toolbar visual tweaks and code clean up" 2022-07-27 19:40:17 +00:00
jenkins-bot 3fb45cfc14 Merge "Hide TOC button on print" 2022-07-27 17:33:28 +00:00
bwang 7b34e14d25 Page toolbar visual tweaks and code clean up
Visual changes: 11 expected in Pixel
- Elements on the right side of page toolbar are now flush with the rest of the content

Change-Id: Id02cd379687fa292188a447c85951e7a87ade509
2022-07-27 17:10:22 +00:00
jenkins-bot 54ac78bba0 Merge "Make site banner full width in grid layout" 2022-07-27 16:57:05 +00:00
Clare Ming 7a63671b51 Hide TOC button on print
Bug: T313298
Change-Id: Ibf5281ce9deabc32f59df9c088af6dcb29b86ddf
2022-07-27 10:24:19 -06:00