forked from canonical/vanilla-framework
-
Notifications
You must be signed in to change notification settings - Fork 1
/
_patterns_forms.scss
68 lines (56 loc) · 1.25 KB
/
_patterns_forms.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
@import 'settings';
@mixin vf-p-forms {
@include vf-p-forms-stacked;
@include vf-p-forms-inline;
form + [class*='p-button'] {
margin-top: $spv-outer--scaleable;
}
}
@mixin vf-p-forms-stacked {
.p-form--stacked {
width: 100%;
.p-form__group {
@media screen and (min-width: $breakpoint-medium) {
align-items: baseline;
+ .p-form__group {
margin-top: $spv-inner--small;
}
}
}
}
}
@mixin vf-p-forms-inline {
.p-form--inline {
@media screen and (min-width: $breakpoint-medium) {
align-items: baseline;
display: inline-flex;
flex-direction: row;
> * {
margin: 0;
}
}
.p-form__group {
@media screen and (min-width: $breakpoint-medium) {
display: flex;
width: auto;
+ .p-form__group,
+ [class*='p-button'] {
margin-left: $sph-inner--large;
}
.p-form__label,
.p-form__control,
.p-form-validation__message {
align-self: baseline;
box-sizing: border-box;
}
.p-form__label {
flex-shrink: 0;
padding-right: $sph-inner;
}
.p-form__control {
display: inline-block;
}
}
}
}
}