mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-12-04 18:58:37 +00:00
2e42a46654
Defines an HTML attribute, `data-ve-target-container` that gives skins the ability to choose which element they want to act as VE's target. This attribute addresses a need in the Vector 2022 skin, where the default selector, `#content` was no longer suitable to act as VE's content container and more flexible approach was needed, so that the skin itself could define which element VE should use. This selector falls back to `#content` as was the case previously. Additional change: Update modules/ve-mw/preinit/styles/ve.init.mw.DesktopArticleTarget.init-vector.less to account for the planned change to retain line between tabs and toolbar in new layout. Bug: T310197 Change-Id: Idae6755c90eacaab1a9daa88c6e28850d427810c
47 lines
1.4 KiB
Plaintext
47 lines
1.4 KiB
Plaintext
/*!
|
|
* VisualEditor MediaWiki DesktopArticleTarget Vector skin init styles.
|
|
*
|
|
* @copyright 2011-2020 VisualEditor Team and others; see AUTHORS.txt
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
*/
|
|
|
|
// Local copy of Vector variables.
|
|
// Can be removed after I87c5502530cd0039b090fbd3cfa7615d6cd64b36 is merged.
|
|
@padding-top-content: 0.5em;
|
|
@padding-horizontal-content: 0.5em;
|
|
// End local copy of Vector variables.
|
|
|
|
@padding-top-toolbar: -@padding-top-content/0.875;
|
|
@padding-horizontal-toolbar: -@padding-horizontal-content/0.875;
|
|
|
|
.ve-init-mw-desktopArticleTarget-toolbar,
|
|
.ve-init-mw-desktopArticleTarget-toolbarPlaceholder {
|
|
font-size: 0.875em;
|
|
|
|
// New Vector with $wgVectorTitleAboveTabs = false
|
|
margin: @padding-top-toolbar @padding-horizontal-toolbar -@padding-top-toolbar @padding-horizontal-toolbar;
|
|
|
|
// New Vector with $wgVectorTitleAboveTabs = true
|
|
/* stylelint-disable-next-line selector-class-pattern */
|
|
.vector-article-toolbar ~ .vector-body & {
|
|
margin: 0;
|
|
}
|
|
|
|
// Legacy Vector
|
|
.skin-vector-legacy & {
|
|
/* 1/0.875 */
|
|
margin: -1.14em -1.14em 1.14em -1.14em;
|
|
|
|
/* High-definition-specific styles (because Vector adds 1em to the leftNav if width is 982px+ */
|
|
@media screen and ( min-width: 982px ) {
|
|
/* 1.25/0.875, 1.5/0.875 */
|
|
margin: -1.43em -1.71em 1.43em -1.71em;
|
|
}
|
|
}
|
|
}
|
|
|
|
.ve-init-mw-desktopArticleTarget-toolbarPlaceholder-floating {
|
|
margin-top: 0;
|
|
margin-bottom: 0;
|
|
}
|