@transferwise/neptune-css 14.28.2 → 14.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/dist/css/accordion.css +24 -46
  2. package/dist/css/alerts.css +56 -124
  3. package/dist/css/badge.css +20 -30
  4. package/dist/css/breadcrumbs.css +6 -4
  5. package/dist/css/button-groups.css +116 -254
  6. package/dist/css/buttons.css +51 -90
  7. package/dist/css/circles.css +38 -76
  8. package/dist/css/close.css +1 -4
  9. package/dist/css/column-layout.css +38 -60
  10. package/dist/css/currency-flags.css +4 -17
  11. package/dist/css/decision.css +14 -12
  12. package/dist/css/dropdowns.css +59 -210
  13. package/dist/css/droppable.css +43 -38
  14. package/dist/css/flex.css +40 -136
  15. package/dist/css/footer.css +15 -14
  16. package/dist/css/grid.css +383 -1430
  17. package/dist/css/input-groups.css +254 -542
  18. package/dist/css/link-callout.css +2 -8
  19. package/dist/css/list-group.css +57 -92
  20. package/dist/css/loaders.css +11 -11
  21. package/dist/css/media.css +10 -34
  22. package/dist/css/modals.css +49 -59
  23. package/dist/css/navbar.css +372 -812
  24. package/dist/css/navs.css +59 -124
  25. package/dist/css/neptune-addons.css +687 -1234
  26. package/dist/css/neptune-core.css +123 -229
  27. package/dist/css/neptune-social-media.css +9 -33
  28. package/dist/css/neptune.css +3039 -6483
  29. package/dist/css/panels.css +143 -243
  30. package/dist/css/popovers.css +114 -295
  31. package/dist/css/process.css +64 -77
  32. package/dist/css/progress-bars.css +13 -19
  33. package/dist/css/select.css +21 -53
  34. package/dist/css/sequences.css +99 -219
  35. package/dist/css/table.css +48 -43
  36. package/dist/css/tick.css +10 -10
  37. package/dist/css/tooltip.css +49 -82
  38. package/dist/css/utilities.css +12 -40
  39. package/dist/css/wells.css +16 -16
  40. package/package.json +2 -2
  41. package/src/less/addons/_spacing-utilities.less +4 -4
  42. package/src/less/mixins/_logical-properties-IE-friendly.less +1 -0
  43. package/src/less/mixins/_logical-properties-modern-browsers.less +80 -41
  44. package/src/less/mixins/_logical-properties.less +3 -3
@@ -1,4 +1,3 @@
1
-
2
1
  // Mixin to support Logical properties/values for modern browsers
3
2
 
4
3
  // Custom property for the cases which doesn't exist a logical value. (Translations, linear-gradients)
@@ -17,20 +16,10 @@
17
16
 
18
17
  .float(@direction) {
19
18
  & when (@direction = left) {
20
- [dir="rtl"] & {
21
- float: right;
22
- }
23
-
24
- float: @direction;
25
19
  float: inline-start;
26
20
  }
27
21
 
28
22
  & when (@direction = right) {
29
- [dir="rtl"] & {
30
- float: left;
31
- }
32
-
33
- float: @direction;
34
23
  float: inline-end;
35
24
  }
36
25
  }
@@ -39,20 +28,10 @@
39
28
 
40
29
  .clear(@direction) {
41
30
  & when (@direction = left) {
42
- [dir="rtl"] & {
43
- clear: right;
44
- }
45
-
46
- clear: @direction;
47
31
  clear: inline-start;
48
32
  }
49
33
 
50
34
  & when (@direction = right) {
51
- [dir="rtl"] & {
52
- clear: left;
53
- }
54
-
55
- clear: @direction;
56
35
  clear: inline-end;
57
36
  }
58
37
  }
@@ -71,7 +50,27 @@
71
50
 
72
51
  // CSS Logical Properties: https://caniuse.com/css-logical-props
73
52
 
74
- .padding(@direction, @value) {
53
+ .padding(@direction, @value, @oppositeValue: ~"") {
54
+ & when (@direction = left) {
55
+ padding-inline-start: @value;
56
+ & when not (@oppositeValue = ~"") {
57
+ [dir="rtl"] & {
58
+ padding-inline-end: @oppositeValue;
59
+ }
60
+ }
61
+ }
62
+
63
+ & when (@direction = right) {
64
+ padding-inline-end: @value;
65
+ & when not (@oppositeValue = ~"") {
66
+ [dir="rtl"] & {
67
+ padding-inline-start: @oppositeValue;
68
+ }
69
+ }
70
+ }
71
+ }
72
+
73
+ .padding-for-spacing(@direction, @value) {
75
74
  & when (@direction = left) {
76
75
  padding-inline-start: @value;
77
76
  }
@@ -85,25 +84,45 @@
85
84
  // Use for single value shorthand 'padding: var(--foo);' -> '.padding-shorthand(var(--foo))'
86
85
  // Use for multiple value shorthand 'padding: var(--foo1) var(--foo2) var(--foo3) var(--foo4);' -> '.padding-shorthand(var(--foo1), var(--foo2), var(--foo3), var(--foo4))'
87
86
 
88
- .padding-shorthand(@value1, @value2: ~'', @value3: ~'', @value4: ~'') {
89
- [dir="rtl"] & {
90
- padding: @value1 @value4 @value3 @value2;
87
+ .padding-shorthand(@value1, @value2: ~"", @value3: ~"", @value4: ~"") {
88
+ & when (@value2 = ~"") {
89
+ padding: @value1;
91
90
  }
92
-
93
- html:not([dir="rtl"]) & {
94
- padding: @value1 @value2 @value3 @value4;
91
+ & when not (@value2 = ~"") {
92
+ padding-block: @value1 @value3;
93
+ padding-inline: @value4 @value2;
95
94
  }
96
95
  }
97
96
 
98
97
  // CSS Logical Properties: https://caniuse.com/css-logical-props
99
98
 
100
- .margin(@direction, @value) {
99
+ .margin(@direction, @value, @oppositeValue: ~"") {
101
100
  & when (@direction = left) {
102
101
  margin-inline-start: @value;
102
+ & when not (@oppositeValue = ~"") {
103
+ [dir="rtl"] & {
104
+ margin-inline-end: @oppositeValue;
105
+ }
106
+ }
103
107
  }
104
108
 
105
109
  & when (@direction = right) {
106
- padding-inline-end: @value;
110
+ margin-inline-end: @value;
111
+ & when not (@oppositeValue = ~"") {
112
+ [dir="rtl"] & {
113
+ margin-inline-start: @oppositeValue;
114
+ }
115
+ }
116
+ }
117
+ }
118
+
119
+ .margin-for-spacing(@direction, @value) {
120
+ & when (@direction = left) {
121
+ margin-inline-start: @value;
122
+ }
123
+
124
+ & when (@direction = right) {
125
+ margin-inline-end: @value;
107
126
  }
108
127
  }
109
128
 
@@ -111,29 +130,39 @@
111
130
  // Use for single value shorthand 'margin: var(--foo);' -> '.margin-shorthand(var(--foo))'
112
131
  // Use for multiple value shorthand 'margin: var(--foo1) var(--foo2) var(--foo3) var(--foo4);' -> '.margin-shorthand(var(--foo1), var(--foo2), var(--foo3), var(--foo4))'
113
132
 
114
- .margin-shorthand(@value1, @value2: ~'', @value3: ~'', @value4: ~'') {
115
- [dir="rtl"] & {
116
- margin: @value1 @value4 @value3 @value2;
133
+ .margin-shorthand(@value1, @value2: ~"", @value3: ~"", @value4: ~"") {
134
+ & when (@value2 = ~"") {
135
+ margin: @value1;
117
136
  }
118
-
119
- html:not([dir="rtl"]) & {
120
- margin: @value1 @value2 @value3 @value4;
137
+ & when not (@value2 = ~"") {
138
+ margin-block: @value1 @value3;
139
+ margin-inline: @value4 @value2;
121
140
  }
122
141
  }
123
142
 
124
143
  // CSS property: inset-inline (positions): https://caniuse.com/mdn-css_properties_inset-inline
125
144
 
126
- .left(@value) {
145
+ .left(@value, @oppositeValue: ~"") {
127
146
  inset-inline-start: @value;
147
+ & when not (@oppositeValue = ~"") {
148
+ [dir="rtl"] & {
149
+ inset-inline-end: @oppositeValue;
150
+ }
151
+ }
128
152
  }
129
153
 
130
- .right(@value) {
154
+ .right(@value, @oppositeValue: ~"") {
131
155
  inset-inline-end: @value;
156
+ & when not (@oppositeValue = ~"") {
157
+ [dir="rtl"] & {
158
+ inset-inline-start: @oppositeValue;
159
+ }
160
+ }
132
161
  }
133
162
 
134
163
  // CSS property: border-inline-start https://caniuse.com/mdn-css_properties_border-inline-start
135
164
 
136
- .border(@direction, @size, @style: ~'', @color: ~'') {
165
+ .border(@direction, @size, @style: ~"", @color: ~"") {
137
166
  & when (@direction = left) {
138
167
  border-inline-start: @size @style @color;
139
168
  }
@@ -193,7 +222,7 @@
193
222
 
194
223
  // Background position
195
224
 
196
- .background-position(@direction, @vertical-direction: ~'') {
225
+ .background-position(@direction, @vertical-direction: ~"") {
197
226
  & when (@direction = left) {
198
227
  background-position: var(--left) @vertical-direction;
199
228
  }
@@ -215,9 +244,19 @@
215
244
  }
216
245
  }
217
246
 
247
+ // Rotations
248
+
249
+ .rotate(@deg) {
250
+ [dir="rtl"] & {
251
+ transform: rotate(@deg * -1);
252
+ }
253
+
254
+ transform: rotate(@deg);
255
+ }
256
+
218
257
  // Horizontal translations
219
258
 
220
- .translateX(@value, @transform2: ~'', @transform3: ~'') {
259
+ .translateX(@value, @transform2: ~"", @transform3: ~"") {
221
260
  [dir="rtl"] & {
222
261
  transform: translateX(@value * -1) @transform2 @transform3;
223
262
  }
@@ -1,5 +1,5 @@
1
1
  // Custom support for logical properties/values. Select one of the options:
2
2
 
3
- // @import '../mixins/_physical-properties.less';
4
- @import "./_logical-properties-IE-friendly.less";
5
- // @import '../mixins/_logical-properties-modern-browsers.less';
3
+ // @import "./_physical-properties.less";
4
+ // @import './_logical-properties-IE-friendly.less';
5
+ @import "../mixins/_logical-properties-modern-browsers.less";