office-ui-fabric-core-rails 5.0.1.0 → 5.1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/office-ui-fabric-core-rails/version.rb +2 -2
- data/package.json +2 -2
- data/vendor/assets/css/fabric.css +470 -428
- data/vendor/assets/css/fabric.min.css +2 -2
- data/vendor/assets/css/fabric.rtl.css +50 -8
- data/vendor/assets/css/fabric.rtl.min.css +2 -2
- data/vendor/assets/scss/Fabric.Animations.Output.scss +419 -419
- data/vendor/assets/scss/Fabric.Animations.RTL.Output.scss +80 -80
- data/vendor/assets/scss/Fabric.Base.Output.scss +14 -14
- data/vendor/assets/scss/Fabric.Brand.Icons.Output.scss +18 -18
- data/vendor/assets/scss/Fabric.Color.Mixins.Output.scss +443 -443
- data/vendor/assets/scss/Fabric.Grid.Output.scss +32 -32
- data/vendor/assets/scss/Fabric.Icons.Font.Output.scss +21 -20
- data/vendor/assets/scss/Fabric.Icons.Output.scss +751 -740
- data/vendor/assets/scss/Fabric.Icons.RTL.Output.scss +149 -149
- data/vendor/assets/scss/Fabric.RTL.scss +39 -39
- data/vendor/assets/scss/Fabric.Responsive.Utilities.Output.scss +1012 -1012
- data/vendor/assets/scss/Fabric.Typography.Fonts.Extended.Output.scss +67 -67
- data/vendor/assets/scss/Fabric.Typography.Fonts.Output.scss +12 -12
- data/vendor/assets/scss/Fabric.Typography.Language.Overrides.Output.scss +52 -52
- data/vendor/assets/scss/Fabric.Typography.Output.scss +389 -389
- data/vendor/assets/scss/Fabric.Utilities.Output.scss +45 -45
- data/vendor/assets/scss/Fabric.scss +43 -43
- data/vendor/assets/scss/_Fabric.Animations.RTL.scss +79 -79
- data/vendor/assets/scss/_Fabric.Animations.scss +237 -237
- data/vendor/assets/scss/_Fabric.Base.scss +13 -13
- data/vendor/assets/scss/_Fabric.Brand.Icons.scss +50 -50
- data/vendor/assets/scss/_Fabric.Color.Mixins.scss +418 -418
- data/vendor/assets/scss/_Fabric.Color.Variables.scss +93 -93
- data/vendor/assets/scss/_Fabric.Common.scss +16 -16
- data/vendor/assets/scss/_Fabric.Grid.scss +33 -33
- data/vendor/assets/scss/_Fabric.Icons.scss +779 -770
- data/vendor/assets/scss/_Fabric.Mixins.RTL.scss +324 -324
- data/vendor/assets/scss/_Fabric.Mixins.scss +281 -281
- data/vendor/assets/scss/_Fabric.Responsive.Utilities.Variables.scss +1423 -1423
- data/vendor/assets/scss/_Fabric.Responsive.Variables.scss +34 -34
- data/vendor/assets/scss/_Fabric.Typography.Fonts.scss +167 -167
- data/vendor/assets/scss/_Fabric.Typography.Language.Overrides.scss +49 -49
- data/vendor/assets/scss/_Fabric.Typography.Mixins.scss +11 -11
- data/vendor/assets/scss/_Fabric.Typography.Variables.scss +29 -29
- data/vendor/assets/scss/_Fabric.Typography.scss +345 -345
- data/vendor/assets/scss/_Fabric.Utilities.scss +75 -75
- data/vendor/assets/scss/_Fabric.ZIndex.Variables.scss +32 -32
- data/vendor/assets/scss/_Fabric.i18n.scss +315 -315
- metadata +2 -2
@@ -1,76 +1,76 @@
|
|
1
|
-
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
-
|
3
|
-
//
|
4
|
-
// Office UI Fabric
|
5
|
-
// --------------------------------------------------
|
6
|
-
// Utility classes and mixins used throughout Fabric.
|
7
|
-
|
8
|
-
@import "Fabric.Mixins";
|
9
|
-
|
10
|
-
// The best box is a border box.
|
11
|
-
@mixin ms-u-borderBox {
|
12
|
-
box-sizing: border-box;
|
13
|
-
}
|
14
|
-
|
15
|
-
// For setting the border base width
|
16
|
-
@mixin ms-u-borderBase {
|
17
|
-
border: 1px solid;
|
18
|
-
}
|
19
|
-
|
20
|
-
// Ensures the block expands to the full height to enclose its floated childen.
|
21
|
-
@mixin ms-u-clearfix {
|
22
|
-
*zoom: 1;
|
23
|
-
&::before,
|
24
|
-
&::after {
|
25
|
-
display: table;
|
26
|
-
content: "";
|
27
|
-
line-height: 0;
|
28
|
-
}
|
29
|
-
&::after {
|
30
|
-
clear: both;
|
31
|
-
}
|
32
|
-
}
|
33
|
-
|
34
|
-
// Basic border-box, margin, and padding reset.
|
35
|
-
@mixin ms-u-normalize {
|
36
|
-
@include ms-u-borderBox;
|
37
|
-
@include resetMargins;
|
38
|
-
@include resetPadding;
|
39
|
-
@include resetBoxShadow;
|
40
|
-
}
|
41
|
-
|
42
|
-
// To set various text alignment styles
|
43
|
-
// @param [variable list] $alignments
|
44
|
-
@mixin ms-u-textAlign($alignments...) {
|
45
|
-
@each $align in $alignments {
|
46
|
-
$alignStr: inspect($align);
|
47
|
-
.ms-u-textAlign#{to-upper-case(str-slice($alignStr, 1, 1)) + str-slice($alignStr, 2)} {
|
48
|
-
text-align: $align;
|
49
|
-
}
|
50
|
-
}
|
51
|
-
}
|
52
|
-
|
53
|
-
// To hide content while still making it readable by screen readers (Accessibility)
|
54
|
-
@mixin ms-u-screenReaderOnly {
|
55
|
-
position: absolute;
|
56
|
-
width: 1px;
|
57
|
-
height: 1px;
|
58
|
-
padding: 0;
|
59
|
-
margin: -1px;
|
60
|
-
overflow: hidden;
|
61
|
-
clip: rect(0,0,0,0);
|
62
|
-
border: 0;
|
63
|
-
}
|
64
|
-
|
65
|
-
// To add truncation with ellipsis
|
66
|
-
@mixin ms-u-textTruncate {
|
67
|
-
overflow: hidden;
|
68
|
-
text-overflow: ellipsis;
|
69
|
-
white-space: nowrap;
|
70
|
-
word-wrap: normal; // Fix for IE 8/9 in case 'word-wrap: break-word' is set on parent nodes
|
71
|
-
}
|
72
|
-
|
73
|
-
// To disable text wrapping
|
74
|
-
@mixin ms-u-noWrap {
|
75
|
-
white-space: nowrap;
|
1
|
+
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
+
|
3
|
+
//
|
4
|
+
// Office UI Fabric
|
5
|
+
// --------------------------------------------------
|
6
|
+
// Utility classes and mixins used throughout Fabric.
|
7
|
+
|
8
|
+
@import "Fabric.Mixins";
|
9
|
+
|
10
|
+
// The best box is a border box.
|
11
|
+
@mixin ms-u-borderBox {
|
12
|
+
box-sizing: border-box;
|
13
|
+
}
|
14
|
+
|
15
|
+
// For setting the border base width
|
16
|
+
@mixin ms-u-borderBase {
|
17
|
+
border: 1px solid;
|
18
|
+
}
|
19
|
+
|
20
|
+
// Ensures the block expands to the full height to enclose its floated childen.
|
21
|
+
@mixin ms-u-clearfix {
|
22
|
+
*zoom: 1;
|
23
|
+
&::before,
|
24
|
+
&::after {
|
25
|
+
display: table;
|
26
|
+
content: "";
|
27
|
+
line-height: 0;
|
28
|
+
}
|
29
|
+
&::after {
|
30
|
+
clear: both;
|
31
|
+
}
|
32
|
+
}
|
33
|
+
|
34
|
+
// Basic border-box, margin, and padding reset.
|
35
|
+
@mixin ms-u-normalize {
|
36
|
+
@include ms-u-borderBox;
|
37
|
+
@include resetMargins;
|
38
|
+
@include resetPadding;
|
39
|
+
@include resetBoxShadow;
|
40
|
+
}
|
41
|
+
|
42
|
+
// To set various text alignment styles
|
43
|
+
// @param [variable list] $alignments
|
44
|
+
@mixin ms-u-textAlign($alignments...) {
|
45
|
+
@each $align in $alignments {
|
46
|
+
$alignStr: inspect($align);
|
47
|
+
.ms-u-textAlign#{to-upper-case(str-slice($alignStr, 1, 1)) + str-slice($alignStr, 2)} {
|
48
|
+
text-align: $align;
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
// To hide content while still making it readable by screen readers (Accessibility)
|
54
|
+
@mixin ms-u-screenReaderOnly {
|
55
|
+
position: absolute;
|
56
|
+
width: 1px;
|
57
|
+
height: 1px;
|
58
|
+
padding: 0;
|
59
|
+
margin: -1px;
|
60
|
+
overflow: hidden;
|
61
|
+
clip: rect(0,0,0,0);
|
62
|
+
border: 0;
|
63
|
+
}
|
64
|
+
|
65
|
+
// To add truncation with ellipsis
|
66
|
+
@mixin ms-u-textTruncate {
|
67
|
+
overflow: hidden;
|
68
|
+
text-overflow: ellipsis;
|
69
|
+
white-space: nowrap;
|
70
|
+
word-wrap: normal; // Fix for IE 8/9 in case 'word-wrap: break-word' is set on parent nodes
|
71
|
+
}
|
72
|
+
|
73
|
+
// To disable text wrapping
|
74
|
+
@mixin ms-u-noWrap {
|
75
|
+
white-space: nowrap;
|
76
76
|
}
|
@@ -1,32 +1,32 @@
|
|
1
|
-
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
-
|
3
|
-
//
|
4
|
-
// Office UI Fabric
|
5
|
-
// --------------------------------------------------
|
6
|
-
// Z-Index Layeringz
|
7
|
-
|
8
|
-
|
9
|
-
// Base Layer Variables
|
10
|
-
$ms-zIndex-0: 0 !default;
|
11
|
-
$ms-zIndex-1: 100 !default;
|
12
|
-
$ms-zIndex-2: 200 !default;
|
13
|
-
$ms-zIndex-3: 300 !default;
|
14
|
-
$ms-zIndex-4: 400 !default;
|
15
|
-
$ms-zIndex-5: 500 !default;
|
16
|
-
|
17
|
-
// Base Layer Modifier Variables
|
18
|
-
$ms-zIndex-back: 0 !default;
|
19
|
-
$ms-zIndex-middle: 5 !default;
|
20
|
-
$ms-zIndex-front: 10 !default;
|
21
|
-
|
22
|
-
|
23
|
-
// Fabric Component Base Layer Assignments
|
24
|
-
|
25
|
-
$ms-zIndex-Callout: $ms-zIndex-1 !default;
|
26
|
-
$ms-zIndex-ContextualMenu: $ms-zIndex-1 !default;
|
27
|
-
$ms-zIndex-Overlay: $ms-zIndex-2 !default;
|
28
|
-
$ms-zIndex-Panel: $ms-zIndex-3 !default;
|
29
|
-
$ms-zIndex-DatePicker: $ms-zIndex-3 !default;
|
30
|
-
$ms-zIndex-Dialog: $ms-zIndex-3 !default;
|
31
|
-
$ms-zIndex-PeoplePicker: $ms-zIndex-3 !default;
|
32
|
-
$ms-zIndex-Dropdown: $ms-zIndex-4 !default;
|
1
|
+
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
+
|
3
|
+
//
|
4
|
+
// Office UI Fabric
|
5
|
+
// --------------------------------------------------
|
6
|
+
// Z-Index Layeringz
|
7
|
+
|
8
|
+
|
9
|
+
// Base Layer Variables
|
10
|
+
$ms-zIndex-0: 0 !default;
|
11
|
+
$ms-zIndex-1: 100 !default;
|
12
|
+
$ms-zIndex-2: 200 !default;
|
13
|
+
$ms-zIndex-3: 300 !default;
|
14
|
+
$ms-zIndex-4: 400 !default;
|
15
|
+
$ms-zIndex-5: 500 !default;
|
16
|
+
|
17
|
+
// Base Layer Modifier Variables
|
18
|
+
$ms-zIndex-back: 0 !default;
|
19
|
+
$ms-zIndex-middle: 5 !default;
|
20
|
+
$ms-zIndex-front: 10 !default;
|
21
|
+
|
22
|
+
|
23
|
+
// Fabric Component Base Layer Assignments
|
24
|
+
|
25
|
+
$ms-zIndex-Callout: $ms-zIndex-1 !default;
|
26
|
+
$ms-zIndex-ContextualMenu: $ms-zIndex-1 !default;
|
27
|
+
$ms-zIndex-Overlay: $ms-zIndex-2 !default;
|
28
|
+
$ms-zIndex-Panel: $ms-zIndex-3 !default;
|
29
|
+
$ms-zIndex-DatePicker: $ms-zIndex-3 !default;
|
30
|
+
$ms-zIndex-Dialog: $ms-zIndex-3 !default;
|
31
|
+
$ms-zIndex-PeoplePicker: $ms-zIndex-3 !default;
|
32
|
+
$ms-zIndex-Dropdown: $ms-zIndex-4 !default;
|
@@ -1,316 +1,316 @@
|
|
1
|
-
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
-
|
3
|
-
//
|
4
|
-
// Office UI Fabric
|
5
|
-
// --------------------------------------------------
|
6
|
-
// Internationalization mixins
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
// Base left-to-right mixin definition.
|
11
|
-
@mixin LTR {
|
12
|
-
html[dir='ltr'] & {
|
13
|
-
@content;
|
14
|
-
}
|
15
|
-
}
|
16
|
-
|
17
|
-
// Base right-to-left mixin definition.
|
18
|
-
@mixin RTL {
|
19
|
-
html[dir='rtl'] & {
|
20
|
-
@content;
|
21
|
-
}
|
22
|
-
}
|
23
|
-
|
24
|
-
// Use baseRTL on a root element (e.g. page or region) that needs RTL support.
|
25
|
-
@mixin baseRtl {
|
26
|
-
@include RTL {
|
27
|
-
direction: rtl;
|
28
|
-
unicode-bidi: bidi-override;
|
29
|
-
}
|
30
|
-
}
|
31
|
-
|
32
|
-
|
33
|
-
// Common CSS property mixins with support for RTL.
|
34
|
-
// Use to automatically create RTL versions of your properties.
|
35
|
-
|
36
|
-
// Border styles.
|
37
|
-
@mixin border-color($top, $right, $bottom, $left) {
|
38
|
-
border-color: $top $right $bottom $left;
|
39
|
-
|
40
|
-
@include RTL {
|
41
|
-
border-color: $top $left $bottom $right;
|
42
|
-
}
|
43
|
-
}
|
44
|
-
|
45
|
-
@mixin border-left($width, $style, $color) {
|
46
|
-
@include LTR {
|
47
|
-
border-left: $width $style $color;
|
48
|
-
}
|
49
|
-
|
50
|
-
@include RTL {
|
51
|
-
border-right: $width $style $color;
|
52
|
-
}
|
53
|
-
}
|
54
|
-
|
55
|
-
@mixin border-left-color($color) {
|
56
|
-
@include LTR {
|
57
|
-
border-left-color: $color;
|
58
|
-
}
|
59
|
-
|
60
|
-
@include RTL {
|
61
|
-
border-right-color: $color;
|
62
|
-
}
|
63
|
-
}
|
64
|
-
|
65
|
-
@mixin border-left-style($style) {
|
66
|
-
@include LTR {
|
67
|
-
border-left-style: $style;
|
68
|
-
}
|
69
|
-
|
70
|
-
@include RTL {
|
71
|
-
border-right-style: $style;
|
72
|
-
}
|
73
|
-
}
|
74
|
-
|
75
|
-
@mixin border-left-width($width) {
|
76
|
-
@include LTR {
|
77
|
-
border-left-width: $width;
|
78
|
-
}
|
79
|
-
|
80
|
-
@include RTL {
|
81
|
-
border-right-width: $width;
|
82
|
-
}
|
83
|
-
}
|
84
|
-
|
85
|
-
@mixin border-radius($topLeft, $topRight, $bottomRight, $bottomLeft) {
|
86
|
-
border-radius: $topLeft $topRight $bottomRight $bottomLeft;
|
87
|
-
|
88
|
-
@include RTL {
|
89
|
-
border-radius: $topRight $topLeft $bottomLeft $bottomRight;
|
90
|
-
}
|
91
|
-
}
|
92
|
-
|
93
|
-
@mixin border-right($width, $style, $color) {
|
94
|
-
@include LTR {
|
95
|
-
border-right: $width $style $color;
|
96
|
-
}
|
97
|
-
|
98
|
-
@include RTL {
|
99
|
-
border-left: $width $style $color;
|
100
|
-
}
|
101
|
-
}
|
102
|
-
|
103
|
-
@mixin border-right-color($color) {
|
104
|
-
@include LTR {
|
105
|
-
border-right-color: $color;
|
106
|
-
}
|
107
|
-
|
108
|
-
@include RTL {
|
109
|
-
border-left-color: $color;
|
110
|
-
}
|
111
|
-
}
|
112
|
-
|
113
|
-
@mixin border-right-style($style) {
|
114
|
-
@include LTR {
|
115
|
-
border-right-style: $style;
|
116
|
-
}
|
117
|
-
|
118
|
-
@include RTL {
|
119
|
-
border-left-style: $style;
|
120
|
-
}
|
121
|
-
}
|
122
|
-
|
123
|
-
@mixin border-right-width($width) {
|
124
|
-
@include LTR {
|
125
|
-
border-right-width: $width;
|
126
|
-
}
|
127
|
-
|
128
|
-
@include RTL {
|
129
|
-
border-left-width: $width;
|
130
|
-
}
|
131
|
-
}
|
132
|
-
|
133
|
-
// Floats.
|
134
|
-
@mixin clear($side) {
|
135
|
-
@if $side == left {
|
136
|
-
@include LTR {
|
137
|
-
clear: $side;
|
138
|
-
}
|
139
|
-
|
140
|
-
@include RTL {
|
141
|
-
clear: right;
|
142
|
-
}
|
143
|
-
} @else if $side == right {
|
144
|
-
@include LTR {
|
145
|
-
clear: $side;
|
146
|
-
}
|
147
|
-
|
148
|
-
@include RTL {
|
149
|
-
clear: left;
|
150
|
-
}
|
151
|
-
} @else {
|
152
|
-
clear: $side;
|
153
|
-
}
|
154
|
-
}
|
155
|
-
|
156
|
-
@mixin float($direction) {
|
157
|
-
@if $direction == left {
|
158
|
-
@include LTR {
|
159
|
-
float: left;
|
160
|
-
}
|
161
|
-
|
162
|
-
@include RTL {
|
163
|
-
float: right;
|
164
|
-
}
|
165
|
-
} @else {
|
166
|
-
@include LTR {
|
167
|
-
float: right;
|
168
|
-
}
|
169
|
-
|
170
|
-
@include RTL {
|
171
|
-
float: left;
|
172
|
-
}
|
173
|
-
}
|
174
|
-
}
|
175
|
-
|
176
|
-
// Positioning.
|
177
|
-
@mixin left($distance) {
|
178
|
-
@include LTR {
|
179
|
-
left: $distance;
|
180
|
-
}
|
181
|
-
|
182
|
-
@include RTL {
|
183
|
-
right: $distance;
|
184
|
-
}
|
185
|
-
}
|
186
|
-
|
187
|
-
@mixin right($distance) {
|
188
|
-
@include LTR {
|
189
|
-
right: $distance;
|
190
|
-
}
|
191
|
-
|
192
|
-
@include RTL {
|
193
|
-
left: $distance;
|
194
|
-
}
|
195
|
-
}
|
196
|
-
|
197
|
-
// Margins.
|
198
|
-
@mixin margin($top, $right, $bottom, $left) {
|
199
|
-
margin: $top $right $bottom $left;
|
200
|
-
|
201
|
-
@include RTL {
|
202
|
-
margin: $top $left $bottom $right;
|
203
|
-
}
|
204
|
-
}
|
205
|
-
|
206
|
-
@mixin margin-left($distance) {
|
207
|
-
@include LTR {
|
208
|
-
margin-left: $distance;
|
209
|
-
}
|
210
|
-
|
211
|
-
@include RTL {
|
212
|
-
margin-right: $distance;
|
213
|
-
}
|
214
|
-
}
|
215
|
-
|
216
|
-
@mixin margin-right($distance) {
|
217
|
-
@include LTR {
|
218
|
-
margin-right: $distance;
|
219
|
-
}
|
220
|
-
@include RTL {
|
221
|
-
margin-left: $distance;
|
222
|
-
}
|
223
|
-
}
|
224
|
-
|
225
|
-
// Padding.
|
226
|
-
@mixin padding($top, $right, $bottom, $left) {
|
227
|
-
padding: $top $right $bottom $left;
|
228
|
-
|
229
|
-
@include RTL {
|
230
|
-
padding: $top $left $bottom $right;
|
231
|
-
}
|
232
|
-
}
|
233
|
-
|
234
|
-
@mixin padding-left($distance) {
|
235
|
-
@include LTR {
|
236
|
-
padding-left: $distance;
|
237
|
-
}
|
238
|
-
|
239
|
-
@include RTL {
|
240
|
-
padding-right: $distance;
|
241
|
-
}
|
242
|
-
}
|
243
|
-
|
244
|
-
@mixin padding-right($distance) {
|
245
|
-
@include LTR {
|
246
|
-
padding-right: $distance;
|
247
|
-
}
|
248
|
-
|
249
|
-
@include RTL {
|
250
|
-
padding-left: $distance;
|
251
|
-
}
|
252
|
-
}
|
253
|
-
|
254
|
-
// Text-alignment.
|
255
|
-
@mixin text-align($direction) {
|
256
|
-
@if $direction == left {
|
257
|
-
@include LTR {
|
258
|
-
text-align: left;
|
259
|
-
}
|
260
|
-
|
261
|
-
@include RTL {
|
262
|
-
text-align: right;
|
263
|
-
}
|
264
|
-
} @else {
|
265
|
-
@include LTR {
|
266
|
-
text-align: right;
|
267
|
-
}
|
268
|
-
|
269
|
-
@include RTL {
|
270
|
-
text-align: left;
|
271
|
-
}
|
272
|
-
}
|
273
|
-
}
|
274
|
-
|
275
|
-
// Box-shadow.
|
276
|
-
@mixin box-shadow($left, $etc) {
|
277
|
-
@include LTR {
|
278
|
-
box-shadow: $left $etc;
|
279
|
-
}
|
280
|
-
|
281
|
-
@include RTL {
|
282
|
-
box-shadow: -$left $etc;
|
283
|
-
}
|
284
|
-
}
|
285
|
-
|
286
|
-
// Transforms.
|
287
|
-
@mixin transform-rtl() {
|
288
|
-
@include LTR {
|
289
|
-
transform: scaleX(1);
|
290
|
-
}
|
291
|
-
|
292
|
-
@include RTL {
|
293
|
-
transform: scaleX(-1);
|
294
|
-
}
|
295
|
-
}
|
296
|
-
|
297
|
-
// Transitions. Only supported when ONLY left/right are declared
|
298
|
-
@mixin transition-property($direction) {
|
299
|
-
@if $direction == left {
|
300
|
-
@include LTR {
|
301
|
-
transition-property: left;
|
302
|
-
}
|
303
|
-
|
304
|
-
@include RTL {
|
305
|
-
transition-property: right;
|
306
|
-
}
|
307
|
-
} @else {
|
308
|
-
@include LTR {
|
309
|
-
transition-property: right;
|
310
|
-
}
|
311
|
-
|
312
|
-
@include RTL {
|
313
|
-
transition-property: left;
|
314
|
-
}
|
315
|
-
}
|
1
|
+
// Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information.
|
2
|
+
|
3
|
+
//
|
4
|
+
// Office UI Fabric
|
5
|
+
// --------------------------------------------------
|
6
|
+
// Internationalization mixins
|
7
|
+
|
8
|
+
|
9
|
+
|
10
|
+
// Base left-to-right mixin definition.
|
11
|
+
@mixin LTR {
|
12
|
+
html[dir='ltr'] & {
|
13
|
+
@content;
|
14
|
+
}
|
15
|
+
}
|
16
|
+
|
17
|
+
// Base right-to-left mixin definition.
|
18
|
+
@mixin RTL {
|
19
|
+
html[dir='rtl'] & {
|
20
|
+
@content;
|
21
|
+
}
|
22
|
+
}
|
23
|
+
|
24
|
+
// Use baseRTL on a root element (e.g. page or region) that needs RTL support.
|
25
|
+
@mixin baseRtl {
|
26
|
+
@include RTL {
|
27
|
+
direction: rtl;
|
28
|
+
unicode-bidi: bidi-override;
|
29
|
+
}
|
30
|
+
}
|
31
|
+
|
32
|
+
|
33
|
+
// Common CSS property mixins with support for RTL.
|
34
|
+
// Use to automatically create RTL versions of your properties.
|
35
|
+
|
36
|
+
// Border styles.
|
37
|
+
@mixin border-color($top, $right, $bottom, $left) {
|
38
|
+
border-color: $top $right $bottom $left;
|
39
|
+
|
40
|
+
@include RTL {
|
41
|
+
border-color: $top $left $bottom $right;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
|
45
|
+
@mixin border-left($width, $style, $color) {
|
46
|
+
@include LTR {
|
47
|
+
border-left: $width $style $color;
|
48
|
+
}
|
49
|
+
|
50
|
+
@include RTL {
|
51
|
+
border-right: $width $style $color;
|
52
|
+
}
|
53
|
+
}
|
54
|
+
|
55
|
+
@mixin border-left-color($color) {
|
56
|
+
@include LTR {
|
57
|
+
border-left-color: $color;
|
58
|
+
}
|
59
|
+
|
60
|
+
@include RTL {
|
61
|
+
border-right-color: $color;
|
62
|
+
}
|
63
|
+
}
|
64
|
+
|
65
|
+
@mixin border-left-style($style) {
|
66
|
+
@include LTR {
|
67
|
+
border-left-style: $style;
|
68
|
+
}
|
69
|
+
|
70
|
+
@include RTL {
|
71
|
+
border-right-style: $style;
|
72
|
+
}
|
73
|
+
}
|
74
|
+
|
75
|
+
@mixin border-left-width($width) {
|
76
|
+
@include LTR {
|
77
|
+
border-left-width: $width;
|
78
|
+
}
|
79
|
+
|
80
|
+
@include RTL {
|
81
|
+
border-right-width: $width;
|
82
|
+
}
|
83
|
+
}
|
84
|
+
|
85
|
+
@mixin border-radius($topLeft, $topRight, $bottomRight, $bottomLeft) {
|
86
|
+
border-radius: $topLeft $topRight $bottomRight $bottomLeft;
|
87
|
+
|
88
|
+
@include RTL {
|
89
|
+
border-radius: $topRight $topLeft $bottomLeft $bottomRight;
|
90
|
+
}
|
91
|
+
}
|
92
|
+
|
93
|
+
@mixin border-right($width, $style, $color) {
|
94
|
+
@include LTR {
|
95
|
+
border-right: $width $style $color;
|
96
|
+
}
|
97
|
+
|
98
|
+
@include RTL {
|
99
|
+
border-left: $width $style $color;
|
100
|
+
}
|
101
|
+
}
|
102
|
+
|
103
|
+
@mixin border-right-color($color) {
|
104
|
+
@include LTR {
|
105
|
+
border-right-color: $color;
|
106
|
+
}
|
107
|
+
|
108
|
+
@include RTL {
|
109
|
+
border-left-color: $color;
|
110
|
+
}
|
111
|
+
}
|
112
|
+
|
113
|
+
@mixin border-right-style($style) {
|
114
|
+
@include LTR {
|
115
|
+
border-right-style: $style;
|
116
|
+
}
|
117
|
+
|
118
|
+
@include RTL {
|
119
|
+
border-left-style: $style;
|
120
|
+
}
|
121
|
+
}
|
122
|
+
|
123
|
+
@mixin border-right-width($width) {
|
124
|
+
@include LTR {
|
125
|
+
border-right-width: $width;
|
126
|
+
}
|
127
|
+
|
128
|
+
@include RTL {
|
129
|
+
border-left-width: $width;
|
130
|
+
}
|
131
|
+
}
|
132
|
+
|
133
|
+
// Floats.
|
134
|
+
@mixin clear($side) {
|
135
|
+
@if $side == left {
|
136
|
+
@include LTR {
|
137
|
+
clear: $side;
|
138
|
+
}
|
139
|
+
|
140
|
+
@include RTL {
|
141
|
+
clear: right;
|
142
|
+
}
|
143
|
+
} @else if $side == right {
|
144
|
+
@include LTR {
|
145
|
+
clear: $side;
|
146
|
+
}
|
147
|
+
|
148
|
+
@include RTL {
|
149
|
+
clear: left;
|
150
|
+
}
|
151
|
+
} @else {
|
152
|
+
clear: $side;
|
153
|
+
}
|
154
|
+
}
|
155
|
+
|
156
|
+
@mixin float($direction) {
|
157
|
+
@if $direction == left {
|
158
|
+
@include LTR {
|
159
|
+
float: left;
|
160
|
+
}
|
161
|
+
|
162
|
+
@include RTL {
|
163
|
+
float: right;
|
164
|
+
}
|
165
|
+
} @else {
|
166
|
+
@include LTR {
|
167
|
+
float: right;
|
168
|
+
}
|
169
|
+
|
170
|
+
@include RTL {
|
171
|
+
float: left;
|
172
|
+
}
|
173
|
+
}
|
174
|
+
}
|
175
|
+
|
176
|
+
// Positioning.
|
177
|
+
@mixin left($distance) {
|
178
|
+
@include LTR {
|
179
|
+
left: $distance;
|
180
|
+
}
|
181
|
+
|
182
|
+
@include RTL {
|
183
|
+
right: $distance;
|
184
|
+
}
|
185
|
+
}
|
186
|
+
|
187
|
+
@mixin right($distance) {
|
188
|
+
@include LTR {
|
189
|
+
right: $distance;
|
190
|
+
}
|
191
|
+
|
192
|
+
@include RTL {
|
193
|
+
left: $distance;
|
194
|
+
}
|
195
|
+
}
|
196
|
+
|
197
|
+
// Margins.
|
198
|
+
@mixin margin($top, $right, $bottom, $left) {
|
199
|
+
margin: $top $right $bottom $left;
|
200
|
+
|
201
|
+
@include RTL {
|
202
|
+
margin: $top $left $bottom $right;
|
203
|
+
}
|
204
|
+
}
|
205
|
+
|
206
|
+
@mixin margin-left($distance) {
|
207
|
+
@include LTR {
|
208
|
+
margin-left: $distance;
|
209
|
+
}
|
210
|
+
|
211
|
+
@include RTL {
|
212
|
+
margin-right: $distance;
|
213
|
+
}
|
214
|
+
}
|
215
|
+
|
216
|
+
@mixin margin-right($distance) {
|
217
|
+
@include LTR {
|
218
|
+
margin-right: $distance;
|
219
|
+
}
|
220
|
+
@include RTL {
|
221
|
+
margin-left: $distance;
|
222
|
+
}
|
223
|
+
}
|
224
|
+
|
225
|
+
// Padding.
|
226
|
+
@mixin padding($top, $right, $bottom, $left) {
|
227
|
+
padding: $top $right $bottom $left;
|
228
|
+
|
229
|
+
@include RTL {
|
230
|
+
padding: $top $left $bottom $right;
|
231
|
+
}
|
232
|
+
}
|
233
|
+
|
234
|
+
@mixin padding-left($distance) {
|
235
|
+
@include LTR {
|
236
|
+
padding-left: $distance;
|
237
|
+
}
|
238
|
+
|
239
|
+
@include RTL {
|
240
|
+
padding-right: $distance;
|
241
|
+
}
|
242
|
+
}
|
243
|
+
|
244
|
+
@mixin padding-right($distance) {
|
245
|
+
@include LTR {
|
246
|
+
padding-right: $distance;
|
247
|
+
}
|
248
|
+
|
249
|
+
@include RTL {
|
250
|
+
padding-left: $distance;
|
251
|
+
}
|
252
|
+
}
|
253
|
+
|
254
|
+
// Text-alignment.
|
255
|
+
@mixin text-align($direction) {
|
256
|
+
@if $direction == left {
|
257
|
+
@include LTR {
|
258
|
+
text-align: left;
|
259
|
+
}
|
260
|
+
|
261
|
+
@include RTL {
|
262
|
+
text-align: right;
|
263
|
+
}
|
264
|
+
} @else {
|
265
|
+
@include LTR {
|
266
|
+
text-align: right;
|
267
|
+
}
|
268
|
+
|
269
|
+
@include RTL {
|
270
|
+
text-align: left;
|
271
|
+
}
|
272
|
+
}
|
273
|
+
}
|
274
|
+
|
275
|
+
// Box-shadow.
|
276
|
+
@mixin box-shadow($left, $etc) {
|
277
|
+
@include LTR {
|
278
|
+
box-shadow: $left $etc;
|
279
|
+
}
|
280
|
+
|
281
|
+
@include RTL {
|
282
|
+
box-shadow: -$left $etc;
|
283
|
+
}
|
284
|
+
}
|
285
|
+
|
286
|
+
// Transforms.
|
287
|
+
@mixin transform-rtl() {
|
288
|
+
@include LTR {
|
289
|
+
transform: scaleX(1);
|
290
|
+
}
|
291
|
+
|
292
|
+
@include RTL {
|
293
|
+
transform: scaleX(-1);
|
294
|
+
}
|
295
|
+
}
|
296
|
+
|
297
|
+
// Transitions. Only supported when ONLY left/right are declared
|
298
|
+
@mixin transition-property($direction) {
|
299
|
+
@if $direction == left {
|
300
|
+
@include LTR {
|
301
|
+
transition-property: left;
|
302
|
+
}
|
303
|
+
|
304
|
+
@include RTL {
|
305
|
+
transition-property: right;
|
306
|
+
}
|
307
|
+
} @else {
|
308
|
+
@include LTR {
|
309
|
+
transition-property: right;
|
310
|
+
}
|
311
|
+
|
312
|
+
@include RTL {
|
313
|
+
transition-property: left;
|
314
|
+
}
|
315
|
+
}
|
316
316
|
}
|