1 // Form elements and layouts
3 // --------------------------------------------------------------------------
5 // --------------------------------------------------------------------------
7 // The FancyCaptcha image CAPTCHA used on WMF wikis drives the width of the
8 // 'VForm' design, the form can't be narrower than this.
9 $captchaContainerWidth: 290px;
10 $defaultFormWidth: $captchaContainerWidth;
12 // Style a compact vertical stacked form ("VForm") and the elements in divs
15 @include box-sizing(border-box);
17 width: $defaultFormWidth;
19 // Immediate divs in a vform are block and spaced-out.
26 // MW currently doesn't use the type attribute everywhere on inputs.
30 @include box-sizing(border-box);
35 // We exclude these because they'll generally use mw-ui-button.
36 // Otherwise, we'll unintentionally override that.
37 input:not([type=button]):not([type=submit]):not([type=file]), {
38 @include agora-field-styling; // mixins/_forms.scss
43 @include box-sizing(border-box);
44 @include agora-label-styling;
50 // Override input styling just for checkboxes and radio inputs.
51 input[type="checkbox"],
54 @include box-sizing(content-box);
60 // HTMLForm uses error, SpecialUserlogin (login and create account) uses
62 // TODO move errorbox from mediawiki.special.vforms.css into here.
64 -webkit-box-sizing: border-box;
65 -moz-box-sizing: border-box;
66 box-sizing: border-box;
71 border: 1px solid #fac5c5;
72 background-color: #fae3e3;
73 text-shadow: 0 1px #fae3e3;
74 word-wrap: break-word;
78 // --------------------------------------------------------------------------
80 // --------------------------------------------------------------------------
82 // Apply this to individual elements to style them.
83 // You generally don't need to use this class on divs within an Agora
84 // form container such as mw-ui-vform
85 // XXX DRY: This repeats earlier styling, use an @include agora-div-styling ?
93 // Apply mw-ui-input to individual input fields to style them.
94 // You generally don't need to use this class if <input> is within an Agora
95 // form container such as mw-ui-vform
97 @include agora-field-styling; // mixins/_forms.scss
100 // Apply mw-ui-label to individual elements to style them.
101 // You generally don't need to use this class if <label> is within an Agora
102 // form container such as mw-ui-vform
104 @include agora-label-styling; // mixins/_forms.scss
107 // Nesting an input checkbox or radio button inside a label with this class
108 // improves alignment, e.g.
109 // <label class="mw-ui-checkbox-label">
110 // <input type="checkbox">The label text
112 .mw-ui-checkbox-label, .mw-ui-radio-label {
113 @include agora-inline-label-styling;