mediawiki-extensions-Visual.../modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css
Timo Tijhof 77f016ae8f mw.ViewPageTarget: Hide ve-ce-surface during deactivation
While showing the content earlier as soon as possible is nice, the ve-ce-surface
remained visible until toolbar and surface were torn down.

This avoids the split second where the new pageview content *and*
CE surface were visible in the page (this it also messed with the scroll position,
and would temporarily cause a scrollbar to appear).

Bug: T91442
Change-Id: I0a7232cd0264bff28ad66aa328de29d339891aa1
2015-03-10 02:48:24 +01:00

83 lines
2.1 KiB
CSS

/*!
* VisualEditor MediaWiki Initialization ViewPageTarget styles.
*
* @copyright 2011-2015 VisualEditor Team and others; see AUTHORS.txt
* @license The MIT License (MIT); see LICENSE.txt
*/
/*!
* State | <html> classes
* Reading | ve-available
* Activate editor | ve-available ve-activated ve-activating
* Active | ve-available ve-activated ve-active
* Deactivate editor | ve-available ve-deactivating
* Deactivated | ve-available
*/
.ve-activated #toc,
.ve-activated #siteNotice,
.ve-activated .mw-indicators,
/* Most of bodyContent can be hidden as VE has an equivalent of most children
in ve-init-target (sibling of #bodyContent). However, we can't hide it
completely as subs should remain visible (for persistence with read mode),
and ve-ui-mwTocWidget is also part of #bodyContent. */
.ve-active #bodyContent > :not(#siteSub):not(#contentSub):not(.ve-ui-mwTocWidget),
.ve-activated #t-print,
.ve-activated #t-permalink,
.ve-activated #p-coll-print_export,
.ve-activated #t-cite,
.ve-deactivating .ve-ce-surface {
display: none;
}
.ve-activating #bodyContent,
.ve-activated #firstHeading,
.ve-activated #siteSub,
.ve-activated #contentSub {
opacity: 0.6;
}
.ve-activated #firstHeading {
cursor: default;
}
/* Toolbar */
.ve-activating .ve-init-mw-viewPageTarget-toolbar,
.ve-deactivating .ve-init-mw-viewPageTarget-toolbar {
overflow: hidden;
transition: height 0.4s ease;
}
.ve-ui-toolbar-floating .oo-ui-toolbar-bar {
transform: translateY(-100%);
transition: transform 0.4s ease;
}
.ve-active .ve-ui-toolbar-floating .oo-ui-toolbar-bar {
transform: translateY(0);
}
.ve-init-mw-viewPageTarget-toolbar-utilities,
.ve-init-mw-viewPageTarget-toolbar-actions {
display: inline-block;
vertical-align: middle;
}
.ve-init-mw-viewPageTarget-toolbar-actions {
font-size: 0.8em;
vertical-align: top;
padding: 0.25em;
}
.ve-init-mw-viewPageTarget-toolbar-utilities > .oo-ui-buttonElement-frameless {
margin-right: 0.2em;
margin-top: 0.2em;
}
.ve-init-mw-viewPageTarget-toolbar-actions > .oo-ui-buttonElement-framed {
margin-left: 0.25em;
margin-right: 0.25em;
margin-top: 0.2em;
}