diff options
Diffstat (limited to 'resources/src/mediawiki.ui/components/utilities.less')
-rw-r--r-- | resources/src/mediawiki.ui/components/utilities.less | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/resources/src/mediawiki.ui/components/utilities.less b/resources/src/mediawiki.ui/components/utilities.less new file mode 100644 index 00000000..0bbb440f --- /dev/null +++ b/resources/src/mediawiki.ui/components/utilities.less @@ -0,0 +1,47 @@ +// Utilities +// +// Other things which effect the behaviour of components + +// Flush left +// +// Used when you want to push an element to the left of its containing element +// +// Markup: +// <div class="mw-ui-vform-field"> +// <label>Username <a href="#" class="mw-ui-flush-left">?</a></label> +// <input> +// </div> +.mw-ui-flush-left { + float: left; + margin-left: 0; + padding-left: 0; +} + +// Flush right +// +// Used when you want to push an element to the right of its containing element +// +// Markup: +// <div class="mw-ui-vform-field"> +// <label>Username <a href="#" class="mw-ui-flush-right">?</a></label> +// <input> +// </div> +.mw-ui-flush-right { + float: right; + padding-right: 0; + margin-right: 0; +} + +// Center block +// +// Centers the element in its containing element +// +// Markup: +// <div> +// <button class="mw-ui-center-block">click me</button> +// </div> +.mw-ui-center-block { + display: block; + margin-left: auto; + margin-right: auto; +} |