@microsoft/atlas-css 3.43.0 → 3.44.1

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 (110) hide show
  1. package/README.md +42 -42
  2. package/dist/class-names.json +1 -1
  3. package/dist/index.css +1 -1
  4. package/dist/index.css.map +1 -1
  5. package/package.json +91 -91
  6. package/src/atomics/README.md +56 -56
  7. package/src/atomics/aspect-ratio.scss +13 -13
  8. package/src/atomics/background.scss +11 -11
  9. package/src/atomics/border.scss +113 -113
  10. package/src/atomics/colors.scss +204 -204
  11. package/src/atomics/display.scss +33 -33
  12. package/src/atomics/flex.scss +74 -71
  13. package/src/atomics/gap.scss +60 -60
  14. package/src/atomics/image.scss +15 -15
  15. package/src/atomics/index.scss +18 -18
  16. package/src/atomics/line-clamp.scss +15 -15
  17. package/src/atomics/list.scss +8 -3
  18. package/src/atomics/overflow.scss +9 -9
  19. package/src/atomics/position.scss +19 -19
  20. package/src/atomics/shadow.scss +19 -19
  21. package/src/atomics/spacing-auto.scss +52 -52
  22. package/src/atomics/spacing.scss +98 -98
  23. package/src/atomics/typography.scss +203 -203
  24. package/src/atomics/visually-hidden.scss +4 -4
  25. package/src/atomics/width.scss +44 -44
  26. package/src/components/README.md +69 -69
  27. package/src/components/banner.scss +69 -69
  28. package/src/components/breadcrumbs.scss +37 -37
  29. package/src/components/button-reset.scss +8 -8
  30. package/src/components/button.scss +241 -241
  31. package/src/components/buttons.scss +93 -93
  32. package/src/components/card.scss +252 -252
  33. package/src/components/form/checkbox.scss +141 -141
  34. package/src/components/form/form.scss +67 -67
  35. package/src/components/form/help.scss +18 -18
  36. package/src/components/form/index.scss +8 -8
  37. package/src/components/form/input.scss +143 -143
  38. package/src/components/form/label.scss +14 -14
  39. package/src/components/form/radio.scss +121 -121
  40. package/src/components/form/select.scss +116 -116
  41. package/src/components/form/textarea.scss +82 -82
  42. package/src/components/gradient-card.scss +14 -14
  43. package/src/components/gradient.scss +85 -85
  44. package/src/components/hero.scss +197 -197
  45. package/src/components/icon.scss +20 -20
  46. package/src/components/image.scss +44 -44
  47. package/src/components/index.scss +27 -27
  48. package/src/components/layout.scss +189 -189
  49. package/src/components/link-button.scss +34 -34
  50. package/src/components/markdown.scss +158 -158
  51. package/src/components/media.scss +22 -22
  52. package/src/components/message.scss +74 -74
  53. package/src/components/notification.scss +101 -101
  54. package/src/components/pagination.scss +183 -183
  55. package/src/components/persona.scss +60 -60
  56. package/src/components/popover.scss +42 -42
  57. package/src/components/scroll.scss +26 -26
  58. package/src/components/segmented-control.scss +128 -128
  59. package/src/components/site-header.scss +255 -255
  60. package/src/components/stretched-link.scss +8 -8
  61. package/src/components/table.scss +114 -114
  62. package/src/components/toggle.scss +86 -86
  63. package/src/core/animations.scss +55 -55
  64. package/src/core/bare-elements.scss +38 -38
  65. package/src/core/focus.scss +45 -45
  66. package/src/core/font-stack.scss +28 -28
  67. package/src/core/index.scss +7 -7
  68. package/src/core/minireset.scss +79 -79
  69. package/src/core/normalize.scss +353 -353
  70. package/src/core/themes.scss +91 -91
  71. package/src/index.scss +5 -5
  72. package/src/mixins/center.scss +11 -11
  73. package/src/mixins/code-block.scss +43 -43
  74. package/src/mixins/colors.scss +6 -6
  75. package/src/mixins/control.scss +43 -43
  76. package/src/mixins/dismiss.scss +22 -22
  77. package/src/mixins/focus.scss +23 -23
  78. package/src/mixins/font-size.scss +35 -35
  79. package/src/mixins/force-colors.scss +5 -5
  80. package/src/mixins/gradient.scss +11 -11
  81. package/src/mixins/index.scss +17 -17
  82. package/src/mixins/layout-gap.scss +7 -7
  83. package/src/mixins/line-clamp.scss +15 -15
  84. package/src/mixins/loader.scss +16 -16
  85. package/src/mixins/media-queries.scss +61 -61
  86. package/src/mixins/overlay.scss +12 -12
  87. package/src/mixins/transparency.scss +15 -15
  88. package/src/mixins/unselectable.scss +13 -13
  89. package/src/mixins/visually-hidden.scss +12 -12
  90. package/src/tokens/animation.scss +8 -8
  91. package/src/tokens/border.scss +12 -12
  92. package/src/tokens/breakpoints.scss +11 -11
  93. package/src/tokens/colors.scss +239 -239
  94. package/src/tokens/direction.scss +25 -25
  95. package/src/tokens/display.scss +5 -5
  96. package/src/tokens/focus.scss +9 -9
  97. package/src/tokens/font-stack.scss +10 -10
  98. package/src/tokens/index.scss +17 -17
  99. package/src/tokens/layout.scss +17 -17
  100. package/src/tokens/palette.scss +200 -200
  101. package/src/tokens/position.scss +5 -5
  102. package/src/tokens/schemes.scss +14 -14
  103. package/src/tokens/shadow.scss +11 -11
  104. package/src/tokens/spacing.scss +25 -25
  105. package/src/tokens/themes.scss +318 -318
  106. package/src/tokens/typography.scss +33 -33
  107. package/src/tokens/z-index.scss +20 -20
  108. package/tokens/README.md +34 -34
  109. package/tokens/index.js +246 -246
  110. package/tokens/types.d.ts +35 -35
@@ -1,241 +1,241 @@
1
- @use 'sass:map';
2
-
3
- $button-color: $text !default;
4
- $button-background-color: $body-background !default;
5
-
6
- $button-lg-font-size: $font-size-6 !default;
7
- $button-sm-font-size: $font-size-8 !default;
8
-
9
- $button-icon-font-size: 0.875em !default;
10
-
11
- $button-border-color: $text-subtle !default;
12
- $button-border-width: $control-border-width !default;
13
- $button-border-radius: $control-radius !default;
14
-
15
- $button-padding-vertical: calc(0.375em - #{$button-border-width}) !default;
16
- $button-padding-horizontal: 0.75em !default;
17
-
18
- $button-hover-color: $text !default;
19
- $button-hover-border-color: $default-hover !default;
20
- $button-hover-background-color: $default-hover-invert !default;
21
-
22
- $button-disabled-background-color: $body-background-medium !default;
23
- $button-disabled-shadow: none !default;
24
- $button-disabled-opacity: 0.5 !default;
25
-
26
- $button-icon-spacing: 0.375em !default;
27
- $button-font-weight: $weight-semibold !default;
28
-
29
- .button {
30
- @include control;
31
- @include unselectable;
32
-
33
- justify-content: center;
34
- padding-block-start: $button-padding-vertical;
35
- padding-block-end: $button-padding-vertical;
36
- border-width: $button-border-width;
37
- border-radius: $button-border-radius;
38
- border-color: $button-border-color;
39
- background-color: $button-background-color;
40
- color: $button-color;
41
- font-weight: $button-font-weight;
42
- text-align: center;
43
- text-decoration: none;
44
- cursor: pointer;
45
- padding-inline-start: $button-padding-horizontal;
46
- padding-inline-end: $button-padding-horizontal;
47
-
48
- strong {
49
- color: inherit;
50
- }
51
-
52
- .icon {
53
- font-size: $button-icon-font-size;
54
-
55
- &:only-child {
56
- margin: 0;
57
- }
58
-
59
- &:first-child:not(:only-child) {
60
- margin-inline-end: $button-icon-spacing;
61
- }
62
-
63
- &:last-child:not(:only-child) {
64
- margin-inline-start: $button-icon-spacing;
65
- }
66
- }
67
-
68
- &:hover,
69
- &.is-hovered {
70
- border-color: $button-hover-border-color;
71
- background-color: $button-hover-background-color;
72
- color: $button-hover-color;
73
- }
74
-
75
- &:visited {
76
- color: $button-color;
77
- }
78
-
79
- // Sizes
80
-
81
- &.button-sm {
82
- font-size: $button-sm-font-size;
83
- }
84
-
85
- &.button-lg {
86
- font-size: $button-lg-font-size;
87
- }
88
-
89
- // Modifiers
90
-
91
- &.is-disabled,
92
- &[disabled] {
93
- border-color: currentColor;
94
- background-color: $button-disabled-background-color;
95
- opacity: $button-disabled-opacity;
96
- box-shadow: $button-disabled-shadow;
97
- }
98
-
99
- &.button-block {
100
- display: flex;
101
- width: 100%;
102
- }
103
-
104
- &.is-loading {
105
- color: transparent !important;
106
- pointer-events: none;
107
-
108
- &::after {
109
- @include loader;
110
- @include center(1em);
111
-
112
- position: absolute !important;
113
- border-block-end-color: $text;
114
- border-inline-start-color: $text;
115
- }
116
- }
117
-
118
- @each $name, $color-set in $colors {
119
- $base: nth($color-set, $color-index-base);
120
- $dark: nth($color-set, $color-index-dark);
121
- $background: nth($color-set, $color-index-background);
122
-
123
- &.button-#{$name} {
124
- @if $name == 'warning' {
125
- border-color: $dark;
126
- color: $dark;
127
- } @else {
128
- border-color: $base;
129
- color: $base;
130
- }
131
-
132
- &:hover,
133
- &.is-hovered {
134
- background-color: $background;
135
- color: $dark;
136
- }
137
-
138
- &.is-loading::after {
139
- border-color: transparent transparent $base $base !important;
140
- }
141
- }
142
- }
143
- }
144
-
145
- $button-clear-hover-background-color: transparentize(#8e8e8e, 0.95) !default;
146
-
147
- .button.button-clear {
148
- border-color: transparent;
149
- background-color: transparent;
150
-
151
- &.border {
152
- // an allowed hack to make for flexible outlined buttons
153
- // does not support loading states
154
- border-color: currentColor !important;
155
- }
156
-
157
- &,
158
- &:visited {
159
- color: currentColor;
160
- }
161
-
162
- &.is-hovered,
163
- &:hover,
164
- &:active {
165
- background-color: $button-clear-hover-background-color;
166
- }
167
-
168
- @each $name, $color-set in $colors {
169
- $base: nth($color-set, $color-index-base);
170
- $dark: nth($color-set, $color-index-dark);
171
- $background: nth($color-set, $color-index-background);
172
-
173
- &.button-#{$name} {
174
- color: $base;
175
- @if $name == 'warning' {
176
- color: $dark;
177
- }
178
-
179
- &:hover,
180
- &.is-hovered {
181
- background-color: $background;
182
- color: $dark;
183
- }
184
-
185
- &.is-disabled,
186
- &[disabled] {
187
- background-color: transparent;
188
- color: $base;
189
- box-shadow: none;
190
- }
191
- }
192
- }
193
- }
194
-
195
- $button-filled-background-color: $alternate-background-medium !default;
196
- $button-filled-background-color-hover: $alternate-background !default;
197
- $button-filled-text-color: $text-invert !default;
198
-
199
- .button.button-filled {
200
- border-color: $button-filled-background-color;
201
- background-color: $button-filled-background-color;
202
- color: $button-filled-text-color;
203
-
204
- &:hover,
205
- &.is-hovered {
206
- background-color: $button-filled-background-color-hover;
207
- }
208
-
209
- &.is-loading::after {
210
- @include loader;
211
-
212
- border-color: transparent transparent $button-filled-text-color $button-filled-text-color !important;
213
- }
214
-
215
- @each $name, $color-set in $colors {
216
- $base: nth($color-set, $color-index-base);
217
- $hover: nth($color-set, $color-index-hover);
218
- $active: nth($color-set, $color-index-active);
219
- $invert: nth($color-set, $color-index-invert);
220
- $background: nth($color-set, $color-index-background);
221
-
222
- &.button-#{$name} {
223
- border-color: $base;
224
- background-color: $base;
225
- color: $invert;
226
-
227
- &:hover,
228
- &.is-hovered {
229
- border-color: $hover;
230
- background-color: $hover;
231
- color: $invert;
232
- }
233
-
234
- &.is-loading::after {
235
- @include loader;
236
-
237
- border-color: transparent transparent $invert $invert !important;
238
- }
239
- }
240
- }
241
- }
1
+ @use 'sass:map';
2
+
3
+ $button-color: $text !default;
4
+ $button-background-color: $body-background !default;
5
+
6
+ $button-lg-font-size: $font-size-6 !default;
7
+ $button-sm-font-size: $font-size-8 !default;
8
+
9
+ $button-icon-font-size: 0.875em !default;
10
+
11
+ $button-border-color: $text-subtle !default;
12
+ $button-border-width: $control-border-width !default;
13
+ $button-border-radius: $control-radius !default;
14
+
15
+ $button-padding-vertical: calc(0.375em - #{$button-border-width}) !default;
16
+ $button-padding-horizontal: 0.75em !default;
17
+
18
+ $button-hover-color: $text !default;
19
+ $button-hover-border-color: $default-hover !default;
20
+ $button-hover-background-color: $default-hover-invert !default;
21
+
22
+ $button-disabled-background-color: $body-background-medium !default;
23
+ $button-disabled-shadow: none !default;
24
+ $button-disabled-opacity: 0.5 !default;
25
+
26
+ $button-icon-spacing: 0.375em !default;
27
+ $button-font-weight: $weight-semibold !default;
28
+
29
+ .button {
30
+ @include control;
31
+ @include unselectable;
32
+
33
+ justify-content: center;
34
+ padding-block-start: $button-padding-vertical;
35
+ padding-block-end: $button-padding-vertical;
36
+ border-width: $button-border-width;
37
+ border-radius: $button-border-radius;
38
+ border-color: $button-border-color;
39
+ background-color: $button-background-color;
40
+ color: $button-color;
41
+ font-weight: $button-font-weight;
42
+ text-align: center;
43
+ text-decoration: none;
44
+ cursor: pointer;
45
+ padding-inline-start: $button-padding-horizontal;
46
+ padding-inline-end: $button-padding-horizontal;
47
+
48
+ strong {
49
+ color: inherit;
50
+ }
51
+
52
+ .icon {
53
+ font-size: $button-icon-font-size;
54
+
55
+ &:only-child {
56
+ margin: 0;
57
+ }
58
+
59
+ &:first-child:not(:only-child) {
60
+ margin-inline-end: $button-icon-spacing;
61
+ }
62
+
63
+ &:last-child:not(:only-child) {
64
+ margin-inline-start: $button-icon-spacing;
65
+ }
66
+ }
67
+
68
+ &:hover,
69
+ &.is-hovered {
70
+ border-color: $button-hover-border-color;
71
+ background-color: $button-hover-background-color;
72
+ color: $button-hover-color;
73
+ }
74
+
75
+ &:visited {
76
+ color: $button-color;
77
+ }
78
+
79
+ // Sizes
80
+
81
+ &.button-sm {
82
+ font-size: $button-sm-font-size;
83
+ }
84
+
85
+ &.button-lg {
86
+ font-size: $button-lg-font-size;
87
+ }
88
+
89
+ // Modifiers
90
+
91
+ &.is-disabled,
92
+ &[disabled] {
93
+ border-color: currentColor;
94
+ background-color: $button-disabled-background-color;
95
+ opacity: $button-disabled-opacity;
96
+ box-shadow: $button-disabled-shadow;
97
+ }
98
+
99
+ &.button-block {
100
+ display: flex;
101
+ width: 100%;
102
+ }
103
+
104
+ &.is-loading {
105
+ color: transparent !important;
106
+ pointer-events: none;
107
+
108
+ &::after {
109
+ @include loader;
110
+ @include center(1em);
111
+
112
+ position: absolute !important;
113
+ border-block-end-color: $text;
114
+ border-inline-start-color: $text;
115
+ }
116
+ }
117
+
118
+ @each $name, $color-set in $colors {
119
+ $base: nth($color-set, $color-index-base);
120
+ $dark: nth($color-set, $color-index-dark);
121
+ $background: nth($color-set, $color-index-background);
122
+
123
+ &.button-#{$name} {
124
+ @if $name == 'warning' {
125
+ border-color: $dark;
126
+ color: $dark;
127
+ } @else {
128
+ border-color: $base;
129
+ color: $base;
130
+ }
131
+
132
+ &:hover,
133
+ &.is-hovered {
134
+ background-color: $background;
135
+ color: $dark;
136
+ }
137
+
138
+ &.is-loading::after {
139
+ border-color: transparent transparent $base $base !important;
140
+ }
141
+ }
142
+ }
143
+ }
144
+
145
+ $button-clear-hover-background-color: transparentize(#8e8e8e, 0.95) !default;
146
+
147
+ .button.button-clear {
148
+ border-color: transparent;
149
+ background-color: transparent;
150
+
151
+ &.border {
152
+ // an allowed hack to make for flexible outlined buttons
153
+ // does not support loading states
154
+ border-color: currentColor !important;
155
+ }
156
+
157
+ &,
158
+ &:visited {
159
+ color: currentColor;
160
+ }
161
+
162
+ &.is-hovered,
163
+ &:hover,
164
+ &:active {
165
+ background-color: $button-clear-hover-background-color;
166
+ }
167
+
168
+ @each $name, $color-set in $colors {
169
+ $base: nth($color-set, $color-index-base);
170
+ $dark: nth($color-set, $color-index-dark);
171
+ $background: nth($color-set, $color-index-background);
172
+
173
+ &.button-#{$name} {
174
+ color: $base;
175
+ @if $name == 'warning' {
176
+ color: $dark;
177
+ }
178
+
179
+ &:hover,
180
+ &.is-hovered {
181
+ background-color: $background;
182
+ color: $dark;
183
+ }
184
+
185
+ &.is-disabled,
186
+ &[disabled] {
187
+ background-color: transparent;
188
+ color: $base;
189
+ box-shadow: none;
190
+ }
191
+ }
192
+ }
193
+ }
194
+
195
+ $button-filled-background-color: $alternate-background-medium !default;
196
+ $button-filled-background-color-hover: $alternate-background !default;
197
+ $button-filled-text-color: $text-invert !default;
198
+
199
+ .button.button-filled {
200
+ border-color: $button-filled-background-color;
201
+ background-color: $button-filled-background-color;
202
+ color: $button-filled-text-color;
203
+
204
+ &:hover,
205
+ &.is-hovered {
206
+ background-color: $button-filled-background-color-hover;
207
+ }
208
+
209
+ &.is-loading::after {
210
+ @include loader;
211
+
212
+ border-color: transparent transparent $button-filled-text-color $button-filled-text-color !important;
213
+ }
214
+
215
+ @each $name, $color-set in $colors {
216
+ $base: nth($color-set, $color-index-base);
217
+ $hover: nth($color-set, $color-index-hover);
218
+ $active: nth($color-set, $color-index-active);
219
+ $invert: nth($color-set, $color-index-invert);
220
+ $background: nth($color-set, $color-index-background);
221
+
222
+ &.button-#{$name} {
223
+ border-color: $base;
224
+ background-color: $base;
225
+ color: $invert;
226
+
227
+ &:hover,
228
+ &.is-hovered {
229
+ border-color: $hover;
230
+ background-color: $hover;
231
+ color: $invert;
232
+ }
233
+
234
+ &.is-loading::after {
235
+ @include loader;
236
+
237
+ border-color: transparent transparent $invert $invert !important;
238
+ }
239
+ }
240
+ }
241
+ }
@@ -1,93 +1,93 @@
1
- /* stylelint-disable selector-max-specificity, max-nesting-depth */
2
-
3
- .buttons {
4
- display: flex;
5
- flex-wrap: wrap;
6
- align-items: center;
7
- justify-content: flex-start;
8
-
9
- &.buttons-centered {
10
- justify-content: center;
11
- }
12
-
13
- &.buttons-right {
14
- justify-content: flex-end;
15
- }
16
-
17
- .button {
18
- margin-block-end: 0.5rem;
19
- margin-inline-end: 0.5rem;
20
-
21
- &:only-child,
22
- &.is-fullwidth,
23
- &.is-full-width {
24
- margin-inline-end: 0;
25
- }
26
-
27
- &.is-full-width-mobile,
28
- &.is-fullwidth-mobile {
29
- margin-inline-end: 0;
30
-
31
- @include tablet {
32
- margin-inline-end: 0.5rem;
33
- }
34
- }
35
- }
36
-
37
- &:last-child {
38
- margin-block-end: -0.5rem;
39
- }
40
-
41
- &:not(:last-child) {
42
- margin-block-end: 1rem;
43
- }
44
-
45
- &.buttons-addons {
46
- .button {
47
- &:not(:first-child) {
48
- border-bottom-#{$user-left}-radius: 0;
49
- border-top-#{$user-left}-radius: 0;
50
- }
51
-
52
- &:not(:last-child) {
53
- border-bottom-#{$user-right}-radius: 0;
54
- border-top-#{$user-right}-radius: 0;
55
- margin-inline-end: -1px;
56
- }
57
-
58
- &:last-child {
59
- margin-inline-end: 0;
60
- }
61
-
62
- &:hover,
63
- &.is-hovered {
64
- z-index: $zindex-hover;
65
- }
66
-
67
- &.is-focused,
68
- &:active,
69
- &.is-active,
70
- &.is-selected {
71
- z-index: $zindex-focus;
72
-
73
- &:hover {
74
- z-index: $zindex-multi;
75
- }
76
- }
77
-
78
- @include focus-visible {
79
- z-index: $zindex-focus;
80
-
81
- &:hover {
82
- z-index: $zindex-multi;
83
- }
84
- }
85
-
86
- &.is-expanded {
87
- flex-grow: 1;
88
- }
89
- }
90
- }
91
- }
92
-
93
- /* stylelint-enable selector-max-specificity, max-nesting-depth */
1
+ /* stylelint-disable selector-max-specificity, max-nesting-depth */
2
+
3
+ .buttons {
4
+ display: flex;
5
+ flex-wrap: wrap;
6
+ align-items: center;
7
+ justify-content: flex-start;
8
+
9
+ &.buttons-centered {
10
+ justify-content: center;
11
+ }
12
+
13
+ &.buttons-right {
14
+ justify-content: flex-end;
15
+ }
16
+
17
+ .button {
18
+ margin-block-end: 0.5rem;
19
+ margin-inline-end: 0.5rem;
20
+
21
+ &:only-child,
22
+ &.is-fullwidth,
23
+ &.is-full-width {
24
+ margin-inline-end: 0;
25
+ }
26
+
27
+ &.is-full-width-mobile,
28
+ &.is-fullwidth-mobile {
29
+ margin-inline-end: 0;
30
+
31
+ @include tablet {
32
+ margin-inline-end: 0.5rem;
33
+ }
34
+ }
35
+ }
36
+
37
+ &:last-child {
38
+ margin-block-end: -0.5rem;
39
+ }
40
+
41
+ &:not(:last-child) {
42
+ margin-block-end: 1rem;
43
+ }
44
+
45
+ &.buttons-addons {
46
+ .button {
47
+ &:not(:first-child) {
48
+ border-bottom-#{$user-left}-radius: 0;
49
+ border-top-#{$user-left}-radius: 0;
50
+ }
51
+
52
+ &:not(:last-child) {
53
+ border-bottom-#{$user-right}-radius: 0;
54
+ border-top-#{$user-right}-radius: 0;
55
+ margin-inline-end: -1px;
56
+ }
57
+
58
+ &:last-child {
59
+ margin-inline-end: 0;
60
+ }
61
+
62
+ &:hover,
63
+ &.is-hovered {
64
+ z-index: $zindex-hover;
65
+ }
66
+
67
+ &.is-focused,
68
+ &:active,
69
+ &.is-active,
70
+ &.is-selected {
71
+ z-index: $zindex-focus;
72
+
73
+ &:hover {
74
+ z-index: $zindex-multi;
75
+ }
76
+ }
77
+
78
+ @include focus-visible {
79
+ z-index: $zindex-focus;
80
+
81
+ &:hover {
82
+ z-index: $zindex-multi;
83
+ }
84
+ }
85
+
86
+ &.is-expanded {
87
+ flex-grow: 1;
88
+ }
89
+ }
90
+ }
91
+ }
92
+
93
+ /* stylelint-enable selector-max-specificity, max-nesting-depth */