Per T234570, browser support for animations is solid now so we no longer
need to check for browser support.
However, due to some browsers firing css transitions on page load (see
https://bugs.chromium.org/p/chromium/issues/detail?id=332189), we still
need JS to add this wrapping class after CSS transitions are loaded to
prevent the transitions firing on page load for some components
(DropDownList and MainMenu). See MainMenu.less or DropDownList.less for
an example of how this is used.
MobileFrontend adds an animations class too rn, but that will be removed
in in I58f754740f7146f09c38220a7614285e57684924.
Bug: T234570
Change-Id: If0cf7113b40f7217a22b66a8669138466af2cf5d
These styles are unnecessary because the visited/active color
is inherited from the styles on the `a` element.
Also causes an issue when clicking on the logout link.
Bug: T240644
Change-Id: I908121043487bb01c55e76b3e366aa3d4c624ce7
Now that ToggleList is loaded in skins.minerva.mainMenu.styles
which is loaded for all users, we should not load it again in
skins.minerva.amc.styles
Change-Id: I6d33a83f20a20956427f261f1900f3cfd8e0153b
This CSS became dead when openNavigationDrawer was removed
in If4831fc700c7df3a2a389b5f95b6fbaea4b7d954
Bug: T225213
Change-Id: I67b5d9bc596be3cff93f3da96fa04c417f741a66
minerva.variables.less: added gray color variable
MainMenu.less: added shadow to navigation
NotificationOverlay.less: changed alpha color of shadow
drawers.less: replaced rgba color with the same color variable
Bug: T231205
Change-Id: Ib1e16804b941a8f3b0cc639673baf73dc749a60a
The div tag was replaced with section tag in
Id032df3a420d577e42572ab128ca89a006b67ffe. This commit updates the css
to reflect that on simplified talk pages.
Change-Id: I94641eac33d30133d69fff561fe20de606076024
Now the main menu is not using JavaScript we can simplify
the menu code to apply only to the Echo navigation drawer.
Bug: T225213
Change-Id: If4831fc700c7df3a2a389b5f95b6fbaea4b7d954
A new controller is added - drawers.js with methods for controlling
display and removal of drawers. The existing code in references is
moved there and extended to support scroll to hide behaviour
Console warnings will disappear with this change.
Additional changes:
* Standardise the page issues element selector - should be the container
not a link inside it (was a red link so triggering wrong behaviour)
Bug: T214045
Change-Id: Id4719b5209dd7647775e2959e46dbae0c3dde3ac
Converts the main menu button to work without JS using the CSS-only
"checkbox" hack, using the ToggleList module from the dropdown menus.
Bug: T225213
Change-Id: I0eff0439f7284ec74f6304324fab409e8a1b6245
Following Vector and OOUI in `@font-size-root` and put it in central
file. Removing duplicated code in `html` and `body` achieving the
same thing.
Also renaming `@font-size-body-mobile` to a distinct
`@font-size-body--feature-phone` ending the confusion that it's a
variable only used at `@width-breakpoint-mobile - 1`.
Change-Id: Ie355d015d882f61c813991c3244bfcb67f161791
The mw-ui-icon class sets a transparent color on icons, however
that rule is loosing a specificity battle with the rules that
color the main menu links.
Given this is the only known instance where this happens,
a transparent color is added to the logout button itself
instead of a more general solution (likely involving
adding multiple "!important"s).
Bug: T240644
Change-Id: I4675e14fa34770361bc8b30f3562b5cb72b3e42d
It's also set in content.styles/main.less and is preceding there.
This has already been merged in reset removal branch and is now
re-deleted on master after first branch attempt failed.
Bug: T222877
Change-Id: I1e9eb28360acd57e574d37e118058abbf5bc6b3e
It dates back before MinervaNeue was its own skin in Iff1f7e63e796cc
and was probably an idea to provide a simple one-stop solution for
a typography change of font size.
It isn't very well setup for this and also provides no value as of now,
for code simplicity's sake, let's remove it.
From a design perspective, we would approach this problem differently
nowadays.
Change-Id: If43ea2590468832e135b3f654022e8b2064b06c1
Enabling 'selector-max-id' rule, and changing in rare exceptions like
`#bodyContent` to `.mw-body > .content` where there's only one less
specific option.
Bug: T239183
Change-Id: I9d929eaae09475b2e20d96cb19081aba3aec5877
Replacing id CSS selector by lower specific class selector, if needed
with `.client-js` prefix.
We have already been there once in Ib1a874b644, we need to enable
`selector-max-id` stylelint rule in a follow-up in order to make
devs not introduce without clear need.
Change-Id: Id16d89280d2ef080907fca5871dca701554087fd
Currently the Special:Logout page will ask "do you want to logout"
even if we pass the logout token. To avoid that first let's log out
user via API Ajax call.
Bug: T232734
Change-Id: Ia4cc4253b99254d7a893a55d9e05918c5d8c87e5
Talk overlays are only needed on talk pages, so we can now
unconditionally load them on talk pages and drop usage of
the ResourceLoader loading module.
When binding the section click handlers, the ids of the
associated headings are now removed to avoid ambiguity in
their behaviour.
Bug: T230695
Change-Id: I9b0ef7c5bc389209ed79761582e2f8aa3058c39d
Loading Special:Homepage on mobile betalabs currently results in an error,
`TypeError: currentPage.titleObj.getTalkPage(...) is null`. The call to
canHaveTalkPage results in false because Special:Homepage is in a lower
namespace number than what canHaveTalkPage() checks for.
Before setting talkTitle, check to see if getTalkPage doesn't fail.
Theoretically we might want to wrap other usages of talkTitle to check if it's
undefined but it seems safe to leave them as is.
Bug: T239101
Change-Id: I913fc309458e014b84da054e25e636492e3ed12a
Removing obsolete code, now that cache has definitely expired from
I720e62a578f0c7a14f4b5a698004471c85e54bc8.
Change-Id: I4f8dc279ed7eeb185e0591b64b91e68c135cf235
Setting `overflow-y: scroll` to prevent reflow as soon as content
comes in. Adding it to `body` as there might be side-effects when
it's set on both, `html` and `body` and latter seems to be the
place where volunteers or third parties would have set it already.
Bug: T204084
Change-Id: I08e8ceeaea4d8488bc9aee23d26f7791ceaa7ee0
The default behaviour is only needed for the main menu and notification
drawer. In the case of a references drawer where no URL navigation has
occurred, do not reset the hash.
history.replaceState cannot be used here as that interferes with the
OverlayManager's work.
Bug: T237015
Change-Id: I51b8c755933f33a3274aa77dc4e4c0b929d872ec
Now that we have refactored TalkSectionAddOverlay to not use the
eventbus and instead exclusively use the passed in onSaveComplete
callback in I75158ff363d56d55ae385687baf64f8b9d5ca8b0, we can remove the
references in talk.js.
Bug: T230695
Depends-On: I75158ff363d56d55ae385687baf64f8b9d5ca8b0
Change-Id: Ia874fa04c125b00fd1997aa4be8b781d76a18763
Following up on Jon's POC, this will get rid of the talk board component in
favor of linking to the server rendered talk page.
Additional Changes:
* Cleaned up talk selenium tests. Removed talk_steps.rb which doesn't appear
to be used anymore.
* Changed talk add button classes to a single class
* Moved "Add discussion" button to postheadinghtml per design mock
* Added "...talk-explained", "...talk-explained-empty" messages to
postheadinghtml per design mock
* Due to undesirable jumps in window scroll caused by the section anchor
& Toggler.js code when opening the TalkSectionOverlay (read fixme in
code), a Promise is always returned from OverlayManager route to reset
the scroll position to the top when the section overlay is opened.
* Moved
"mobile-frontend-talk-fullpage",
"mobile-frontend-talk-reply-success",
"mobile-frontend-talk-topic-feedback",
"mobile-frontend-talk-explained"
"mobile-frontend-talk-explained-empty"
messages to minerva as minerva is
the one who initiates those messages now.
* Limited $talk selector to only `.talk` elements since amc talk tab
does not need to be targeted
* After saving a reply from TalkSectionOverlay, the DOM that is not
part of the overlay becomes out of sync since a new reply was created.
To get around this, an `onSaveComplete` callback was passed (similar to
the TalkSectionAddOverlay) to execute a full page refresh. Although this
is clunky, it is the easiest way to resync.
Bug: T230695
Depends-On: I80201394fd7015db6700446142b0b4b20829f12e
Change-Id: I243f1193bce0da9fa710fc3b5379f90b2d079680