material 3.7.2 → 3.7.3

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 (264) hide show
  1. package/README.md +2 -2
  2. package/dist/components/slider/features/controller.js +24 -8
  3. package/dist/elements/css/card.css +1 -1
  4. package/dist/elements/css/card.js +1 -1
  5. package/dist/elements/css/dialog.css +1 -1
  6. package/dist/elements/css/dialog.js +1 -1
  7. package/dist/elements/css/menu.css +1 -1
  8. package/dist/elements/css/menu.js +1 -1
  9. package/dist/elements/css/select.css +1 -1
  10. package/dist/elements/css/select.js +1 -1
  11. package/dist/elements/css/slider.css +1 -1
  12. package/dist/elements/css/slider.js +1 -1
  13. package/dist/elements/css/tabs.css +1 -1
  14. package/dist/elements/css/tabs.js +1 -1
  15. package/dist/elements/css/timepicker.css +1 -1
  16. package/dist/elements/css/timepicker.js +1 -1
  17. package/dist/elements/preupgrade/badge.css +1 -1
  18. package/dist/elements/preupgrade/bottom-app-bar.css +1 -1
  19. package/dist/elements/preupgrade/bottom-sheet.css +1 -1
  20. package/dist/elements/preupgrade/button-group.css +1 -1
  21. package/dist/elements/preupgrade/button.css +1 -1
  22. package/dist/elements/preupgrade/card.css +1 -1
  23. package/dist/elements/preupgrade/carousel.css +1 -1
  24. package/dist/elements/preupgrade/checkbox.css +1 -1
  25. package/dist/elements/preupgrade/chips.css +1 -1
  26. package/dist/elements/preupgrade/datepicker.css +1 -1
  27. package/dist/elements/preupgrade/dialog.css +1 -1
  28. package/dist/elements/preupgrade/divider.css +1 -1
  29. package/dist/elements/preupgrade/drawer.css +1 -1
  30. package/dist/elements/preupgrade/extended-fab.css +1 -1
  31. package/dist/elements/preupgrade/fab-menu.css +1 -1
  32. package/dist/elements/preupgrade/fab.css +1 -1
  33. package/dist/elements/preupgrade/icon-button.css +1 -1
  34. package/dist/elements/preupgrade/list.css +1 -1
  35. package/dist/elements/preupgrade/loading-indicator.css +1 -1
  36. package/dist/elements/preupgrade/menu.css +1 -1
  37. package/dist/elements/preupgrade/navigation-bar.css +1 -1
  38. package/dist/elements/preupgrade/navigation-rail.css +1 -1
  39. package/dist/elements/preupgrade/progress.css +1 -1
  40. package/dist/elements/preupgrade/radios.css +1 -1
  41. package/dist/elements/preupgrade/search.css +1 -1
  42. package/dist/elements/preupgrade/select.css +1 -1
  43. package/dist/elements/preupgrade/side-sheet.css +1 -1
  44. package/dist/elements/preupgrade/slider.css +1 -1
  45. package/dist/elements/preupgrade/snackbar.css +1 -1
  46. package/dist/elements/preupgrade/split-button.css +1 -1
  47. package/dist/elements/preupgrade/switch.css +1 -1
  48. package/dist/elements/preupgrade/tabs.css +1 -1
  49. package/dist/elements/preupgrade/text-field.css +1 -1
  50. package/dist/elements/preupgrade/timepicker.css +1 -1
  51. package/dist/elements/preupgrade/toolbar.css +1 -1
  52. package/dist/elements/preupgrade/tooltip.css +1 -1
  53. package/dist/elements/preupgrade/top-app-bar.css +1 -1
  54. package/dist/elements/preupgrade.css +1 -1
  55. package/dist/styles/badge.css +1 -1
  56. package/dist/styles/base-lite.css +1 -1
  57. package/dist/styles/base.css +1 -1
  58. package/dist/styles/bottom-app-bar.css +1 -1
  59. package/dist/styles/bottom-sheet.css +1 -1
  60. package/dist/styles/button-group.css +1 -1
  61. package/dist/styles/button.css +1 -1
  62. package/dist/styles/card.css +2 -2
  63. package/dist/styles/carousel.css +1 -1
  64. package/dist/styles/checkbox.css +1 -1
  65. package/dist/styles/chips.css +1 -1
  66. package/dist/styles/contrast.css +1 -1
  67. package/dist/styles/datepicker.css +1 -1
  68. package/dist/styles/dialog.css +2 -2
  69. package/dist/styles/divider.css +1 -1
  70. package/dist/styles/drawer.css +1 -1
  71. package/dist/styles/extended-fab.css +1 -1
  72. package/dist/styles/fab-menu.css +1 -1
  73. package/dist/styles/fab.css +1 -1
  74. package/dist/styles/icon-button.css +1 -1
  75. package/dist/styles/list.css +1 -1
  76. package/dist/styles/loading-indicator.css +1 -1
  77. package/dist/styles/menu.css +2 -2
  78. package/dist/styles/navigation-bar.css +1 -1
  79. package/dist/styles/navigation-rail.css +1 -1
  80. package/dist/styles/progress.css +1 -1
  81. package/dist/styles/radios.css +1 -1
  82. package/dist/styles/search.css +1 -1
  83. package/dist/styles/select.css +2 -2
  84. package/dist/styles/side-sheet.css +1 -1
  85. package/dist/styles/slider.css +2 -2
  86. package/dist/styles/snackbar.css +1 -1
  87. package/dist/styles/split-button.css +1 -1
  88. package/dist/styles/switch.css +1 -1
  89. package/dist/styles/tabs.css +2 -2
  90. package/dist/styles/text-field.css +1 -1
  91. package/dist/styles/timepicker.css +2 -2
  92. package/dist/styles/toolbar.css +1 -1
  93. package/dist/styles/tooltip.css +1 -1
  94. package/dist/styles/top-app-bar.css +1 -1
  95. package/dist/styles/typography.css +1 -1
  96. package/dist/styles/utilities.css +1 -1
  97. package/dist/styles.css +2 -2
  98. package/dist/themes/autumn-contrast.css +1 -1
  99. package/dist/themes/autumn.css +1 -1
  100. package/dist/themes/baseline-contrast.css +1 -1
  101. package/dist/themes/baseline.css +1 -1
  102. package/dist/themes/brownbeige-contrast.css +1 -1
  103. package/dist/themes/brownbeige.css +1 -1
  104. package/dist/themes/content-contrast.css +1 -1
  105. package/dist/themes/content.css +1 -1
  106. package/dist/themes/desert-contrast.css +1 -1
  107. package/dist/themes/desert.css +1 -1
  108. package/dist/themes/expressive-contrast.css +1 -1
  109. package/dist/themes/expressive.css +1 -1
  110. package/dist/themes/fidelity-contrast.css +1 -1
  111. package/dist/themes/fidelity.css +1 -1
  112. package/dist/themes/forest-contrast.css +1 -1
  113. package/dist/themes/forest.css +1 -1
  114. package/dist/themes/fruit-salad-contrast.css +1 -1
  115. package/dist/themes/fruit-salad.css +1 -1
  116. package/dist/themes/highcontrast-contrast.css +1 -1
  117. package/dist/themes/highcontrast.css +1 -1
  118. package/dist/themes/monochrome-contrast.css +1 -1
  119. package/dist/themes/monochrome.css +1 -1
  120. package/dist/themes/neutral-contrast.css +1 -1
  121. package/dist/themes/neutral.css +1 -1
  122. package/dist/themes/ocean-contrast.css +1 -1
  123. package/dist/themes/ocean.css +1 -1
  124. package/dist/themes/rainbow-contrast.css +1 -1
  125. package/dist/themes/rainbow.css +1 -1
  126. package/dist/themes/sageivory-contrast.css +1 -1
  127. package/dist/themes/sageivory.css +1 -1
  128. package/dist/themes/spring-contrast.css +1 -1
  129. package/dist/themes/spring.css +1 -1
  130. package/dist/themes/summer-contrast.css +1 -1
  131. package/dist/themes/summer.css +1 -1
  132. package/dist/themes/sunset-contrast.css +1 -1
  133. package/dist/themes/sunset.css +1 -1
  134. package/dist/themes/tealcaramel-contrast.css +1 -1
  135. package/dist/themes/tealcaramel.css +1 -1
  136. package/dist/themes/vibrant-contrast.css +1 -1
  137. package/dist/themes/vibrant.css +1 -1
  138. package/package.json +2 -1
  139. package/src/styles/abstract/_base.scss +0 -1
  140. package/src/styles/abstract/_direction.scss +121 -152
  141. package/src/styles/abstract/_emit.scss +7 -16
  142. package/src/styles/abstract/_floating-placement.scss +9 -10
  143. package/src/styles/abstract/_functions.scss +64 -79
  144. package/src/styles/abstract/_mixins.scss +355 -459
  145. package/src/styles/abstract/_theme.scss +122 -136
  146. package/src/styles/abstract/_variables.scss +320 -390
  147. package/src/styles/abstract/chips/_assist.scss +2 -3
  148. package/src/styles/abstract/chips/_filter.scss +2 -3
  149. package/src/styles/abstract/chips/_input.scss +2 -3
  150. package/src/styles/abstract/chips/_suggestion.scss +2 -3
  151. package/src/styles/base/_body-theme.scss +10 -15
  152. package/src/styles/base/_document.scss +10 -33
  153. package/src/styles/base/_reset.scss +20 -40
  154. package/src/styles/base/_tokens.scss +6 -21
  155. package/src/styles/base/_typescale-tokens.scss +12 -16
  156. package/src/styles/base/_typography.scss +28 -37
  157. package/src/styles/components/_badge.scss +171 -193
  158. package/src/styles/components/_bottom-app-bar.scss +72 -90
  159. package/src/styles/components/_bottom-sheet.scss +188 -232
  160. package/src/styles/components/_button-group.scss +140 -189
  161. package/src/styles/components/_button.scss +382 -478
  162. package/src/styles/components/_card.scss +349 -473
  163. package/src/styles/components/_carousel.scss +134 -156
  164. package/src/styles/components/_checkbox.scss +208 -249
  165. package/src/styles/components/_chips.scss +239 -304
  166. package/src/styles/components/_datepicker.scss +172 -222
  167. package/src/styles/components/_dialog.scss +428 -553
  168. package/src/styles/components/_divider.scss +37 -46
  169. package/src/styles/components/_drawer.scss +571 -678
  170. package/src/styles/components/_extended-fab.scss +263 -294
  171. package/src/styles/components/_fab-menu.scss +225 -267
  172. package/src/styles/components/_fab.scss +197 -218
  173. package/src/styles/components/_icon-button.scss +483 -588
  174. package/src/styles/components/_list.scss +115 -144
  175. package/src/styles/components/_loading-indicator.scss +23 -29
  176. package/src/styles/components/_menu.scss +543 -699
  177. package/src/styles/components/_navigation-bar.scss +189 -234
  178. package/src/styles/components/_navigation-rail.scss +256 -312
  179. package/src/styles/components/_progress.scss +60 -85
  180. package/src/styles/components/_radios.scss +170 -207
  181. package/src/styles/components/_search.scss +369 -455
  182. package/src/styles/components/_select.scss +78 -185
  183. package/src/styles/components/_side-sheet.scss +234 -292
  184. package/src/styles/components/_slider.scss +289 -367
  185. package/src/styles/components/_snackbar.scss +149 -198
  186. package/src/styles/components/_split-button.scss +139 -228
  187. package/src/styles/components/_switch.scss +282 -349
  188. package/src/styles/components/_tabs.scss +350 -547
  189. package/src/styles/components/_text-field.scss +788 -980
  190. package/src/styles/components/_timepicker.scss +435 -506
  191. package/src/styles/components/_toolbar.scss +178 -242
  192. package/src/styles/components/_tooltip.scss +152 -197
  193. package/src/styles/components/_top-app-bar.scss +206 -230
  194. package/src/styles/elements/_badge.scss +42 -61
  195. package/src/styles/elements/_bottom-app-bar.scss +14 -20
  196. package/src/styles/elements/_bottom-sheet.scss +0 -3
  197. package/src/styles/elements/_button-group.scss +80 -80
  198. package/src/styles/elements/_button.scss +72 -88
  199. package/src/styles/elements/_card.scss +48 -57
  200. package/src/styles/elements/_carousel.scss +2 -5
  201. package/src/styles/elements/_checkbox.scss +32 -43
  202. package/src/styles/elements/_chips.scss +18 -22
  203. package/src/styles/elements/_config.scss +11 -26
  204. package/src/styles/elements/_datepicker.scss +17 -22
  205. package/src/styles/elements/_dialog.scss +0 -3
  206. package/src/styles/elements/_divider.scss +11 -13
  207. package/src/styles/elements/_drawer.scss +9 -14
  208. package/src/styles/elements/_extended-fab.scss +36 -40
  209. package/src/styles/elements/_fab-menu.scss +21 -25
  210. package/src/styles/elements/_fab.scss +17 -20
  211. package/src/styles/elements/_field.scss +93 -114
  212. package/src/styles/elements/_icon-button.scss +34 -38
  213. package/src/styles/elements/_index.scss +0 -4
  214. package/src/styles/elements/_list.scss +19 -26
  215. package/src/styles/elements/_loading-indicator.scss +6 -9
  216. package/src/styles/elements/_menu.scss +0 -3
  217. package/src/styles/elements/_navigation-bar.scss +5 -9
  218. package/src/styles/elements/_navigation-rail.scss +10 -15
  219. package/src/styles/elements/_progress.scss +15 -18
  220. package/src/styles/elements/_radios.scss +24 -49
  221. package/src/styles/elements/_search.scss +19 -24
  222. package/src/styles/elements/_select.scss +4 -9
  223. package/src/styles/elements/_side-sheet.scss +0 -3
  224. package/src/styles/elements/_slider.scss +15 -35
  225. package/src/styles/elements/_snackbar.scss +0 -3
  226. package/src/styles/elements/_split-button.scss +33 -39
  227. package/src/styles/elements/_switch.scss +50 -90
  228. package/src/styles/elements/_tabs.scss +9 -13
  229. package/src/styles/elements/_text-field.scss +150 -178
  230. package/src/styles/elements/_timepicker.scss +0 -3
  231. package/src/styles/elements/_toolbar.scss +30 -35
  232. package/src/styles/elements/_tooltip.scss +0 -3
  233. package/src/styles/elements/_top-app-bar.scss +38 -45
  234. package/src/styles/main.scss +0 -15
  235. package/src/styles/themes/_autumn.scss +240 -258
  236. package/src/styles/themes/_base-theme.scss +96 -128
  237. package/src/styles/themes/_baseline.scss +273 -314
  238. package/src/styles/themes/_brownbeige.scss +242 -250
  239. package/src/styles/themes/_content.scss +240 -248
  240. package/src/styles/themes/_desert.scss +242 -250
  241. package/src/styles/themes/_expressive.scss +242 -250
  242. package/src/styles/themes/_fidelity.scss +240 -248
  243. package/src/styles/themes/_forest.scss +242 -259
  244. package/src/styles/themes/_fruit-salad.scss +242 -250
  245. package/src/styles/themes/_highcontrast.scss +164 -172
  246. package/src/styles/themes/_index.scss +0 -1
  247. package/src/styles/themes/_monochrome.scss +226 -234
  248. package/src/styles/themes/_neutral.scss +242 -250
  249. package/src/styles/themes/_ocean.scss +242 -259
  250. package/src/styles/themes/_rainbow.scss +242 -250
  251. package/src/styles/themes/_sageivory.scss +242 -250
  252. package/src/styles/themes/_spring.scss +238 -255
  253. package/src/styles/themes/_summer.scss +242 -250
  254. package/src/styles/themes/_sunset.scss +242 -259
  255. package/src/styles/themes/_tealcaramel.scss +242 -250
  256. package/src/styles/themes/_vibrant.scss +242 -250
  257. package/src/styles/utilities/_colors.scss +44 -50
  258. package/src/styles/utilities/_flexbox.scss +48 -59
  259. package/src/styles/utilities/_layout.scss +516 -591
  260. package/src/styles/utilities/_ripple.scss +61 -70
  261. package/src/styles/utilities/_spacing.scss +120 -127
  262. package/src/styles/utilities/_typography.scss +45 -58
  263. package/src/styles/utilities/_visibility.scss +61 -76
  264. package/dist/package.json +0 -488
@@ -1,13 +1,3 @@
1
- // src/styles/components/_snackbar.scss
2
- //
3
- // Snackbar, after the Material 3 tokens (Compose SnackbarTokens.kt): an
4
- // inverse-surface container at elevation level 3 with the extra-small corner,
5
- // 48dp for one line of body-medium and 68dp for two, an inverse-primary text
6
- // button for the action and an inverse-on-surface icon for the close
7
- // affordance. Spacing follows Compose Snackbar.kt: 16dp at the start, 8dp
8
- // between the text and the action, 8dp after the action, none after the
9
- // close icon, and 14dp above and below the text. The action moves below the
10
- // text when it is wider than 128dp (Android `maxActionInlineWidth`).
11
1
  @use '../../styles/abstract/base' as base;
12
2
  @use '../../styles/abstract/variables' as v;
13
3
  @use '../../styles/abstract/functions' as f;
@@ -19,195 +9,156 @@ $component: '#{base.$prefix}-snackbar';
19
9
  $button: '#{base.$prefix}-button';
20
10
  $icon-button: '#{base.$prefix}-icon-button';
21
11
 
22
- // Distance from the edges of the window. Neither source makes it a token:
23
- // the Android snackbar keeps 8dp, the Compose host 12dp.
24
12
  $margin: 16px;
25
13
 
26
14
  .#{$component} {
27
- @include m.typography('body-medium');
28
- box-sizing: border-box;
29
- position: fixed;
30
- bottom: $margin;
31
- z-index: f.get-z-index('snackbar');
32
- display: flex;
33
- align-items: center;
34
- min-width: 320px;
35
- max-width: 600px;
36
- min-height: 48px;
37
- padding: 0 16px;
38
- background-color: t.color('inverse-surface');
39
- color: t.color('inverse-on-surface');
40
- border-radius: f.get-shape('extra-small');
41
- @include m.elevation(3);
42
-
43
- // Enter and exit: a fade on the fast effects spring and a scale from 0.8 on
44
- // the fast spatial spring (Compose SnackbarHost FadeInFadeOutWithScale)
45
- opacity: 0;
46
- scale: 0.8;
47
- transition:
48
- opacity v.motion('spring-fast-effects-duration') v.motion('spring-fast-effects-easing'),
49
- scale v.motion('spring-fast-spatial-duration') v.motion('spring-fast-spatial-easing');
50
- pointer-events: none;
51
-
52
- &--visible {
53
- opacity: 1;
54
- scale: 1;
55
- pointer-events: auto;
56
- }
57
-
58
- // A top-layer snackbar is a popover (`layer: "top"`). The browser's popover
59
- // defaults centre it in the viewport inside a border; the snackbar keeps its
60
- // place at the bottom. `:where` keeps this rule under the positions and the
61
- // high-contrast border that follow.
62
- &:where([popover]) {
63
- inset: auto;
64
- bottom: $margin;
65
- margin: 0;
66
- border: 0;
67
- overflow: visible;
68
- }
69
-
70
- // ---------------------------------------------------------------------------
71
- // Position along the bottom edge
72
- // ---------------------------------------------------------------------------
73
- &--center {
74
- left: 50%;
75
- translate: -50% 0;
76
- }
77
-
78
- // The placement class sits on this root, which the runtime may also mark:
79
- // the self form covers a marker on the snackbar itself
80
- // (abstract/_direction.scss).
81
- &--start {
82
- @include d.start($margin, $self: true);
83
- }
84
-
85
- &--end {
86
- @include d.end($margin, $self: true);
87
- }
88
-
89
- // ---------------------------------------------------------------------------
90
- // Supporting text: up to two lines
91
- // ---------------------------------------------------------------------------
92
- // Vertical spacing is margin, not padding: the two-line clamp clips at the
93
- // padding box, so a third line would show through padding.
94
- &__text {
95
- @include m.truncate(2);
96
- flex: 1 1 auto;
97
- min-width: 0;
98
- margin: 14px 0;
99
- overflow-wrap: anywhere;
100
- }
101
-
102
- &--with-action &__text,
103
- &--dismissible &__text {
104
- padding-inline-end: 8px;
105
- }
106
-
107
- // ---------------------------------------------------------------------------
108
- // Action: the library's text button in the inverse colours
109
- // ---------------------------------------------------------------------------
110
- &--with-action {
111
- padding-inline-end: 8px;
112
- }
113
-
114
- &--dismissible {
115
- padding-inline-end: 0;
116
- }
117
-
118
- .#{$button}.#{$component}__action {
119
- flex: 0 0 auto;
120
- color: t.color('inverse-primary');
121
-
122
- &:hover {
123
- @include m.state-layer(t.color('inverse-primary'), 'hover');
124
- }
125
-
126
- &:focus-visible {
127
- @include m.state-layer(t.color('inverse-primary'), 'focus');
128
- // The focus ring keeps the button's 3dp and 2dp offset, in the action's
129
- // own colour: secondary does not reach 3:1 against inverse-surface
130
- // (WCAG 2.4.13 focus appearance).
131
- outline-color: t.color('inverse-primary');
132
- }
133
-
134
- &:active,
135
- &.#{$button}--active {
136
- @include m.state-layer(t.color('inverse-primary'), 'pressed');
137
- }
138
- }
139
-
140
- // ---------------------------------------------------------------------------
141
- // Close affordance: a standard icon button in inverse-on-surface
142
- // ---------------------------------------------------------------------------
143
- .#{$icon-button}.#{$component}__close {
144
- flex: 0 0 auto;
145
- color: t.color('inverse-on-surface');
146
-
147
- &:hover {
148
- color: t.color('inverse-on-surface');
149
- }
150
-
151
- &:focus-visible {
152
- outline-color: t.color('inverse-on-surface');
153
- }
154
- }
155
-
156
- // ---------------------------------------------------------------------------
157
- // A long action sits below the text, aligned to the end
158
- // (Compose NewLineButtonSnackbar: 4dp under the action row)
159
- // ---------------------------------------------------------------------------
160
- &--action-below {
161
- flex-wrap: wrap;
162
- padding-bottom: 4px;
163
-
164
- .#{$component}__text {
165
- flex-basis: 100%;
166
- padding-inline-end: 16px;
167
- }
168
-
169
- .#{$component}__action {
170
- margin-inline-start: auto;
171
- }
172
- }
173
-
174
- // ---------------------------------------------------------------------------
175
- // Compact windows: a fixed distance from the leading, trailing and bottom
176
- // edges, whatever the position (M3 snackbar guidelines, responsive layout)
177
- // ---------------------------------------------------------------------------
178
- @include m.breakpoint-down('sm') {
179
- min-width: 0;
180
- max-width: none;
181
- width: calc(100% - #{2 * $margin});
182
-
183
- &--center {
184
- left: $margin;
185
- translate: none;
186
- }
187
-
188
- &--start,
189
- &--end {
190
- inset-inline: $margin;
191
- }
192
- }
193
-
194
- // ---------------------------------------------------------------------------
195
- // Reduced motion: the fade stays, the scale goes
196
- // ---------------------------------------------------------------------------
197
- @include m.reduced-motion {
198
- scale: none;
199
- transition: opacity v.motion('spring-fast-effects-duration') v.motion('spring-fast-effects-easing');
200
-
201
- &--visible {
202
- scale: none;
203
- }
204
- }
205
-
206
- @include m.high-contrast {
207
- border: 1px solid CanvasText;
208
- }
209
-
210
- @include m.print {
211
- display: none;
212
- }
15
+ @include m.typography('body-medium');
16
+ box-sizing: border-box;
17
+ position: fixed;
18
+ bottom: $margin;
19
+ z-index: f.get-z-index('snackbar');
20
+ display: flex;
21
+ align-items: center;
22
+ min-width: 320px;
23
+ max-width: 600px;
24
+ min-height: 48px;
25
+ padding: 0 16px;
26
+ background-color: t.color('inverse-surface');
27
+ color: t.color('inverse-on-surface');
28
+ border-radius: f.get-shape('extra-small');
29
+ @include m.elevation(3);
30
+
31
+ opacity: 0;
32
+ scale: 0.8;
33
+ transition:
34
+ opacity v.motion('spring-fast-effects-duration') v.motion('spring-fast-effects-easing'),
35
+ scale v.motion('spring-fast-spatial-duration') v.motion('spring-fast-spatial-easing');
36
+ pointer-events: none;
37
+
38
+ &--visible {
39
+ opacity: 1;
40
+ scale: 1;
41
+ pointer-events: auto;
42
+ }
43
+
44
+ &:where([popover]) {
45
+ inset: auto;
46
+ bottom: $margin;
47
+ margin: 0;
48
+ border: 0;
49
+ overflow: visible;
50
+ }
51
+
52
+ &--center {
53
+ left: 50%;
54
+ translate: -50% 0;
55
+ }
56
+
57
+ &--start {
58
+ @include d.start($margin, $self: true);
59
+ }
60
+
61
+ &--end {
62
+ @include d.end($margin, $self: true);
63
+ }
64
+
65
+ &__text {
66
+ @include m.truncate(2);
67
+ flex: 1 1 auto;
68
+ min-width: 0;
69
+ margin: 14px 0;
70
+ overflow-wrap: anywhere;
71
+ }
72
+
73
+ &--with-action &__text,
74
+ &--dismissible &__text {
75
+ padding-inline-end: 8px;
76
+ }
77
+
78
+ &--with-action {
79
+ padding-inline-end: 8px;
80
+ }
81
+
82
+ &--dismissible {
83
+ padding-inline-end: 0;
84
+ }
85
+
86
+ .#{$button}.#{$component}__action {
87
+ flex: 0 0 auto;
88
+ color: t.color('inverse-primary');
89
+
90
+ &:hover {
91
+ @include m.state-layer(t.color('inverse-primary'), 'hover');
92
+ }
93
+
94
+ &:focus-visible {
95
+ @include m.state-layer(t.color('inverse-primary'), 'focus');
96
+ outline-color: t.color('inverse-primary');
97
+ }
98
+
99
+ &:active,
100
+ &.#{$button}--active {
101
+ @include m.state-layer(t.color('inverse-primary'), 'pressed');
102
+ }
103
+ }
104
+
105
+ .#{$icon-button}.#{$component}__close {
106
+ flex: 0 0 auto;
107
+ color: t.color('inverse-on-surface');
108
+
109
+ &:hover {
110
+ color: t.color('inverse-on-surface');
111
+ }
112
+
113
+ &:focus-visible {
114
+ outline-color: t.color('inverse-on-surface');
115
+ }
116
+ }
117
+
118
+ &--action-below {
119
+ flex-wrap: wrap;
120
+ padding-bottom: 4px;
121
+
122
+ .#{$component}__text {
123
+ flex-basis: 100%;
124
+ padding-inline-end: 16px;
125
+ }
126
+
127
+ .#{$component}__action {
128
+ margin-inline-start: auto;
129
+ }
130
+ }
131
+
132
+ @include m.breakpoint-down('sm') {
133
+ min-width: 0;
134
+ max-width: none;
135
+ width: calc(100% - #{2 * $margin});
136
+
137
+ &--center {
138
+ left: $margin;
139
+ translate: none;
140
+ }
141
+
142
+ &--start,
143
+ &--end {
144
+ inset-inline: $margin;
145
+ }
146
+ }
147
+
148
+ @include m.reduced-motion {
149
+ scale: none;
150
+ transition: opacity v.motion('spring-fast-effects-duration') v.motion('spring-fast-effects-easing');
151
+
152
+ &--visible {
153
+ scale: none;
154
+ }
155
+ }
156
+
157
+ @include m.high-contrast {
158
+ border: 1px solid CanvasText;
159
+ }
160
+
161
+ @include m.print {
162
+ display: none;
163
+ }
213
164
  }