@stackoverflow/stacks 3.0.0-beta.3 → 3.0.0-beta.30

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 (108) hide show
  1. package/dist/controllers.d.ts +0 -2
  2. package/dist/css/stacks.css +14245 -15086
  3. package/dist/css/stacks.min.css +1 -1
  4. package/dist/js/stacks.js +0 -364
  5. package/dist/js/stacks.min.js +1 -1
  6. package/lib/atomic/backgrounds.less +67 -0
  7. package/lib/atomic/border-radius.less +38 -0
  8. package/lib/atomic/borders.less +73 -0
  9. package/lib/atomic/box-shadow.less +29 -0
  10. package/lib/atomic/box-sizing.less +3 -0
  11. package/lib/atomic/current-color.less +2 -0
  12. package/lib/atomic/cursors.less +8 -0
  13. package/lib/atomic/display.less +15 -0
  14. package/lib/atomic/flex.less +6 -34
  15. package/lib/atomic/floats.less +20 -0
  16. package/lib/atomic/gap.less +2 -0
  17. package/lib/atomic/grid.less +2 -0
  18. package/lib/atomic/height.less +22 -0
  19. package/lib/atomic/interactivity.less +45 -0
  20. package/lib/atomic/lists.less +29 -0
  21. package/lib/atomic/margin.less +48 -0
  22. package/lib/atomic/object-fit.less +9 -0
  23. package/lib/atomic/opacity.less +54 -0
  24. package/lib/atomic/outline.less +11 -0
  25. package/lib/atomic/overflow.less +17 -0
  26. package/lib/atomic/padding.less +12 -0
  27. package/lib/atomic/positioning.less +41 -0
  28. package/lib/atomic/sizing.less +51 -0
  29. package/lib/atomic/transitions.less +20 -0
  30. package/lib/atomic/truncation.less +58 -0
  31. package/lib/atomic/typography.less +71 -137
  32. package/lib/atomic/vertical-alignment.less +9 -0
  33. package/lib/atomic/visibility.less +18 -0
  34. package/lib/atomic/width.less +27 -0
  35. package/lib/atomic/z-index.less +12 -0
  36. package/lib/base/body.less +2 -4
  37. package/lib/base/configuration-static.less +3 -3
  38. package/lib/base/internal.less +3 -5
  39. package/lib/base/reset-normalize.less +3 -3
  40. package/lib/components/activity-indicator/activity-indicator.less +4 -20
  41. package/lib/components/anchor/anchor.less +28 -39
  42. package/lib/components/avatar/avatar.less +20 -19
  43. package/lib/components/badge/badge.less +227 -167
  44. package/lib/components/banner/banner.less +12 -11
  45. package/lib/components/bling/bling.less +47 -10
  46. package/lib/components/button/button.less +300 -380
  47. package/lib/components/checkbox_radio/checkbox_radio.less +195 -113
  48. package/lib/components/code-block/code-block.fixtures.ts +2 -2
  49. package/lib/components/code-block/code-block.less +2 -3
  50. package/lib/components/description/description.less +17 -2
  51. package/lib/components/empty-state/empty-state.less +17 -6
  52. package/lib/components/form-group/form-group.less +38 -0
  53. package/lib/components/input-fill/input-fill.less +3 -3
  54. package/lib/components/input-icon/input-icon.less +3 -3
  55. package/lib/components/input-message/input-message.less +1 -0
  56. package/lib/components/input_textarea/input_textarea.less +71 -58
  57. package/lib/components/label/label.less +12 -56
  58. package/lib/components/link/link.less +44 -98
  59. package/lib/components/loader/loader.less +88 -0
  60. package/lib/components/menu/menu.less +89 -19
  61. package/lib/components/modal/modal.less +10 -10
  62. package/lib/components/navigation/navigation.less +77 -42
  63. package/lib/components/notice/notice.less +90 -75
  64. package/lib/components/pagination/pagination.less +50 -42
  65. package/lib/components/popover/popover.less +9 -11
  66. package/lib/components/post-summary/post-summary.less +225 -385
  67. package/lib/components/prose/prose.less +49 -35
  68. package/lib/components/select/select.less +46 -41
  69. package/lib/components/sidebar-widget/sidebar-widget.less +26 -196
  70. package/lib/components/table/table.less +48 -22
  71. package/lib/components/tag/tag.less +25 -6
  72. package/lib/components/toast/toast.less +4 -2
  73. package/lib/components/toggle-switch/toggle-switch.less +15 -19
  74. package/lib/components/user-card/user-card.less +129 -92
  75. package/lib/components/vote/vote.less +134 -0
  76. package/lib/controllers.ts +0 -2
  77. package/lib/exports/color-sets.less +108 -81
  78. package/lib/exports/constants-helpers.less +9 -13
  79. package/lib/exports/constants-type.less +18 -36
  80. package/lib/exports/mixins.less +92 -272
  81. package/lib/index.ts +0 -4
  82. package/lib/stacks-static.less +44 -30
  83. package/lib/test/visual-test-utils.ts +42 -10
  84. package/lib/tsconfig.json +1 -1
  85. package/package.json +1 -1
  86. package/dist/components/expandable/expandable.d.ts +0 -17
  87. package/dist/components/uploader/uploader.d.ts +0 -48
  88. package/lib/atomic/border.less +0 -121
  89. package/lib/atomic/misc.less +0 -374
  90. package/lib/atomic/spacing.less +0 -98
  91. package/lib/atomic/width-height.less +0 -194
  92. package/lib/components/block-link/block-link.less +0 -82
  93. package/lib/components/breadcrumbs/breadcrumbs.less +0 -41
  94. package/lib/components/button-group/button-group.less +0 -81
  95. package/lib/components/card/card.less +0 -37
  96. package/lib/components/check-control/check-control.less +0 -17
  97. package/lib/components/check-group/check-group.less +0 -19
  98. package/lib/components/expandable/expandable.less +0 -119
  99. package/lib/components/expandable/expandable.ts +0 -238
  100. package/lib/components/link-preview/link-preview.less +0 -148
  101. package/lib/components/page-title/page-title.less +0 -51
  102. package/lib/components/progress-bar/progress-bar.less +0 -292
  103. package/lib/components/skeleton/skeleton.less +0 -73
  104. package/lib/components/spinner/spinner.less +0 -103
  105. package/lib/components/topbar/topbar.less +0 -553
  106. package/lib/components/uploader/uploader.less +0 -205
  107. package/lib/components/uploader/uploader.ts +0 -207
  108. package/lib/exports/spacing-mixins.less +0 -67
@@ -3,18 +3,17 @@
3
3
  --_mo-bg: fade(.set-black()[600], 50%); // Background remains fixed
4
4
  --_mo-hmx: unset;
5
5
  --_mo-wmx: unset;
6
- --_mo-close-t: var(--su8);
7
6
  --_mo-dialog-bg: var(--white);
8
7
  --_mo-dialog-pt: var(--su24);
9
- --_mo-header-fc: var(--fc-dark);
8
+ --_mo-dialog-ou: 0;
10
9
 
11
10
  // CONTEXTUAL STYLES
12
11
  .dark-mode({
13
- --_mo-dialog-bg: var(--black-225);
12
+ --_mo-dialog-bg: var(--black-100);
14
13
  });
15
14
 
16
- .highcontrast-dark-mode({
17
- --_mo-dialog-bg: var(--black-200);
15
+ .highcontrast-mode({
16
+ --_mo-dialog-ou: var(--su2) solid var(--black-500);
18
17
  });
19
18
 
20
19
  &[aria-hidden="false"] {
@@ -46,7 +45,6 @@
46
45
  &.has-danger,
47
46
  &&__danger {
48
47
  --_mo-bg: darken(fade(.set-red()[600], 50%), 18%);
49
- --_mo-header-fc: var(--red-500);
50
48
  }
51
49
 
52
50
  // CHILD ELEMENTS
@@ -61,16 +59,17 @@
61
59
  margin: 0 !important;
62
60
  }
63
61
 
64
- padding: var(--su12) !important; // [1]
62
+ padding: var(--su6) !important; // [1]
65
63
  position: absolute !important; // [1]
66
- right: var(--su8);
67
- top: var(--_mo-close-t);
64
+ right: var(--su16);
65
+ top: var(--su16);
68
66
  }
69
67
 
70
68
  & &--dialog {
71
69
  padding: var(--_mo-dialog-pt) var(--su24) var(--su24);
72
70
 
73
71
  @scrollbar-styles();
72
+ position: relative;
74
73
  backface-visibility: hidden;
75
74
  background-color: var(--_mo-dialog-bg);
76
75
  border-radius: var(--br-md);
@@ -83,6 +82,7 @@
83
82
  transition: opacity 200ms var(--te-smooth) 0s, z-index 0s 100ms, visibility 0s 100ms, transform 100ms var(--te-smooth) 0s, transform 100ms var(--te-smooth) 0s; // Transition out
84
83
  visibility: hidden;
85
84
  z-index: var(--zi-hide); // Make sure it's also below everything so we can't interact with it.
85
+ outline: var(--_mo-dialog-ou);
86
86
  }
87
87
 
88
88
  & &--footer {
@@ -90,7 +90,7 @@
90
90
  }
91
91
 
92
92
  & &--header {
93
- color: var(--_mo-header-fc);
93
+ color: var(--fc-dark);
94
94
 
95
95
  font-size: var(--fs-headline1);
96
96
  font-weight: normal;
@@ -1,26 +1,32 @@
1
- .s-navigation {
1
+ .s-navigation,
2
+ .s-navigation ul {
2
3
  --_na-fd: row;
3
4
  --_na-fw: wrap;
4
5
  --_na-p: var(--su2) 0;
5
6
  --_na-gap: var(--su4);
6
7
  --_na-item-bg: none;
7
- --_na-item-fc: var(--black-500);
8
+ --_na-item-fc: var(--black-400);
8
9
  --_na-item-fs: unset;
9
- --_na-item-p: var(--su6) var(--su12);
10
- --_na-item-py: var(--su12);
10
+ --_na-item-p: calc(var(--su12) - var(--su1)) var(--su16);
11
11
  --_na-item-ws: nowrap;
12
- --_na-item-bg-hover: var(--black-200);
12
+ --_na-item-bg-hover: var(--black-100);
13
13
  --_na-item-fc-hover: var(--_na-item-fc);
14
- --_na-item-selected-bg: var(--theme-primary);
15
- --_na-item-selected-fc: var(--white);
16
- --_na-item-selected-bg-hover: var(--theme-primary-500);
14
+ --_na-item-selected-bg: none;
15
+ --_na-item-selected-fc: var(--black-600);
16
+ --_na-item-selected-bg-hover: var(--_na-item-bg-hover);
17
+ --_na-item-selected-h: var(--su2);
17
18
  --_na-item-text-ta: center;
18
- --_na-title-mt: var(--su16);
19
+ --_na-after-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M11.35 4.35 6 9.71.65 4.35l.7-.7L6 8.29l4.65-4.64z'/%3E%3C/svg%3E");
20
+ --_na-after-bg-color: var(--black-400);
19
21
 
20
22
  // CONTEXTUAL STYLES
21
23
  .highcontrast-mode({
22
24
  --_na-item-bg-hover: var(--black-500);
23
25
  --_na-item-fc-hover: var(--black-225);
26
+
27
+ a[href].s-navigation--item {
28
+ text-decoration: underline;
29
+ }
24
30
  });
25
31
 
26
32
  // MODIFIERS
@@ -33,28 +39,32 @@
33
39
 
34
40
  &&__sm {
35
41
  --_na-item-fs: var(--fs-caption);
36
- --_na-item-p: var(--su4) var(--su12);
42
+ --_na-item-p: var(--su6) var(--su4);
37
43
  }
38
44
 
39
- &&__vertical {
45
+ &&__vertical,
46
+ &&__vertical ul {
40
47
  --_na-fd: column;
41
48
  --_na-gap: 0;
42
49
  --_na-p: 0;
43
50
  --_na-item-text-ta: unset;
44
51
  --_na-item-ws: normal;
45
- }
52
+ --_na-item-selected-h: 0;
53
+ --_na-item-p: var(--su6) var(--su8);
54
+ --_na-item-fc: var(--black-600);
55
+
56
+ & .s-navigation--item {
57
+ &.is-selected {
58
+ --_na-item-bg: var(--black-150);
59
+ }
46
60
 
47
- // VARIANTS
48
- &&__muted {
49
- --_na-item-selected-bg: var(--black-150);
50
- --_na-item-selected-fc: var(--black-600);
51
- --_na-item-selected-bg-hover: var(--_na-item-bg);
52
-
53
- .highcontrast-mode({
54
- --_na-item-selected-bg: var(--black-600);
55
- --_na-item-selected-fc: var(--black-150);
56
- --_na-item-selected-bg-hover: var(--black-600);
57
- });
61
+ &:has(.s-navigation--icon) {
62
+ --_na-item-p: calc(var(--su12) - var(--su1)) var(--su8);
63
+ }
64
+ &:has(.s-navigation--avatar) {
65
+ --_na-item-p: var(--su12) var(--su8);
66
+ }
67
+ }
58
68
  }
59
69
 
60
70
  // CHILD ELEMENTS
@@ -65,8 +75,18 @@
65
75
  --_na-item-fc-hover: var(--_na-item-fc);
66
76
  --_na-item-bg-hover: var(--_na-item-selected-bg-hover);
67
77
 
78
+ &:before {
79
+ content: "";
80
+ position: absolute;
81
+ bottom: 0;
82
+ left: 0;
83
+ right: 0;
84
+ height: var(--_na-item-selected-h);
85
+ background-color: var(--_na-item-selected-fc);
86
+ }
87
+
68
88
  .highcontrast-mode({
69
- text-decoration: none;
89
+ --_na-item-fc-hover: var(--white);
70
90
  });
71
91
 
72
92
  font-weight: bold;
@@ -75,22 +95,22 @@
75
95
  // TODO: include child component class (without variant) on selector
76
96
  &__dropdown {
77
97
  &:after {
78
- border-style: solid;
79
- border-width: var(--su-static4) var(--su-static4) 0 var(--su-static4);
80
- border-color: currentColor transparent;
98
+ mask-image: var(--_na-after-mask);
99
+ mask-size: contain;
100
+ mask-repeat: no-repeat;
101
+ background-color: var(--_na-after-bg-color);
81
102
  content: "";
82
- pointer-events: none;
83
- position: absolute;
84
- right: 0.9em;
85
- top: calc(50% - var(--su-static2)); // 50% - 2px
86
- z-index: var(--zi-active);
103
+ height: var(--su12);
104
+ width: var(--su12);
105
+ margin-left: var(--su8);
87
106
  }
88
-
89
- padding-right: 2em;
90
107
  }
91
108
 
92
109
  &:hover,
93
110
  &:active {
111
+ .highcontrast-mode({
112
+ --_na-after-bg-color: var(--white);
113
+ });
94
114
  background-color: var(--_na-item-bg-hover);
95
115
  color: var(--_na-item-fc-hover);
96
116
  }
@@ -108,11 +128,12 @@
108
128
 
109
129
  align-items: center;
110
130
  border: none; // Reset some things for when the navigation item is also a button
111
- border-radius: 1000px;
131
+ border-radius: var(--br-md);
112
132
  box-shadow: none;
113
133
  cursor: pointer;
114
134
  display: flex;
115
135
  position: relative;
136
+ text-decoration: none;
116
137
  user-select: auto;
117
138
  }
118
139
 
@@ -132,16 +153,30 @@
132
153
  }
133
154
 
134
155
  & &--title {
135
- &:first-child {
136
- --_na-title-mt: 0;
156
+ & .s-btn {
157
+ color: var(--black-400);
137
158
  }
138
159
 
139
- margin-top: var(--_na-title-mt);
140
-
160
+ margin-bottom: 0;
141
161
  font-size: var(--fs-fine);
142
- font-weight: bold;
143
- padding: var(--su6) var(--su12);
144
- text-transform: uppercase;
162
+ font-weight: normal;
163
+ color: var(--black-400);
164
+ padding: calc(var(--su16) + var(--su2)) var(--su8);
165
+ }
166
+
167
+ //Add top margin to titles except the first one
168
+ & > li ~ li .s-navigation--title {
169
+ margin-top: var(--su24);
170
+ }
171
+
172
+ & &--icon {
173
+ color: inherit;
174
+ margin-right: var(--su4);
175
+ }
176
+
177
+ & &--avatar {
178
+ margin-right: var(--su8);
179
+ background: transparent;
145
180
  }
146
181
 
147
182
  flex-direction: var(--_na-fd);
@@ -9,85 +9,52 @@
9
9
  */
10
10
  .generate-variant-variables(@colorName: "", @modifier: "") {
11
11
  & when (@modifier = "") {
12
- --_no-bc: ~"var(--@{colorName}-300)";
13
12
  --_no-bg: ~"var(--@{colorName}-100)";
14
- --_no-btn-bg-active: ~"var(--@{colorName}-200)";
15
- --_no-btn-bg-focus: ~"var(--@{colorName}-200)";
16
- --_no-btn-fc: ~"var(--@{colorName}-500)";
13
+ --_no-icon-bg: ~"var(--@{colorName}-200)";
17
14
  --_no-code-bc: ~"var(--@{colorName}-300)";
18
15
  --_no-code-bg: ~"var(--@{colorName}-200)";
19
-
20
- .highcontrast-mode({
21
- --_no-bc: ~"var(--@{colorName}-400)";
22
- });
23
16
  }
24
17
 
25
18
  & when (@modifier = important) {
26
- --_no-bc: var(--_no-bg);
27
19
  --_no-bg: ~"var(--@{colorName}-400)";
20
+ --_no-icon-bg: ~"var(--@{colorName}-500)";
28
21
  --_no-fc: var(--white);
29
- --_no-btn-bg-active: ~"var(--@{colorName}-500)";
30
- --_no-btn-bg-focus: ~"var(--@{colorName}-500)";
31
- --_no-btn-fc: ~"var(--@{colorName}-100)";
32
22
  --_no-code-bc: ~"var(--@{colorName}-300)";
33
23
  --_no-code-bg: ~"var(--@{colorName}-500)";
34
-
35
- .highcontrast-mode({
36
- --_no-bg: ~"var(--@{colorName}-500)";
37
- });
38
24
  }
39
25
  }
40
26
 
41
27
  /**
42
28
  * Generate styles for a notice-based component
43
29
  *
44
- * Usage example:
30
+ * Usage examples:
45
31
  * .construct-notice-component(s-banner);
32
+ * .construct-notice-component(s-notice);
46
33
  *
47
34
  * @baseClass - The base class name for the notice component
48
35
  */
49
36
  .construct-notice-component(@baseClass) {
50
- --_no-bc: var(--black-225);
51
- --_no-bg: var(--black-100);
52
- --_no-fc: var(--black-500);
53
- --_no-btn-bg-active: var(--black-250);
54
- --_no-btn-bg-focus: var(--black-225);
55
- --_no-btn-fc: var(--_no-fc);
37
+ --_no-bg: var(--black-150);
38
+ --_no-icon-bg: var(--black-200);
39
+ --_no-fc: var(--black-600);
56
40
  --_no-code-bc: var(--black-300);
57
41
  --_no-code-bg: var(--black-200);
58
42
  --_no-code-fc: var(--_no-fc);
59
43
 
60
44
  // CONTEXTUAL STYLES
61
45
  .highcontrast-mode({
62
- &,
63
- &.@{baseClass}__danger,
64
- &.@{baseClass}__info,
65
- &.@{baseClass}__success,
66
- &.@{baseClass}__warning {
67
- --_no-code-bc: var(--black-400);
68
- --_no-code-bg: var(--white);
69
- --_no-code-fc: var(--black);
70
-
71
- &.@{baseClass}__important {
72
- --_no-code-bc: var(--black-200);
73
- --_no-code-bg: var(--black);
74
- --_no-code-fc: var(--white);
75
- }
46
+ &:not(&__important) {
47
+ --_no-icon-bc: var(--_no-code-bc);
76
48
  }
77
-
78
- --_no-bc: var(--black-400);
79
49
  });
80
50
 
81
51
  // MODIFIERS
82
- &__important:not(.@{baseClass}__danger):not(.@{baseClass}__info):not(.@{baseClass}__success):not(.@{baseClass}__warning) {
83
- --_no-bc: var(--_no-bg);
84
- --_no-bg: var(--black-500);
52
+ &__important {
53
+ --_no-bg: var(--black-400);
54
+ --_no-icon-bg: var(--black-500);
85
55
  --_no-fc: var(--white);
86
- --_no-btn-bg-focus: var(--black-600);
87
- --_no-btn-bg-active: var(--black-600);
88
- --_no-btn-fc: var(--_no-fc);
89
56
  --_no-code-bc: var(--black-300);
90
- --_no-code-bg: var(--black-600);
57
+ --_no-code-bg: var(--black-500);
91
58
  }
92
59
 
93
60
  // VARIANTS
@@ -103,11 +70,11 @@
103
70
 
104
71
  &__info {
105
72
  &:not(.@{baseClass}__important) {
106
- .generate-variant-variables(theme-secondary);
73
+ .generate-variant-variables(blue);
107
74
  }
108
75
 
109
76
  &.@{baseClass}__important {
110
- .generate-variant-variables(theme-secondary, important);
77
+ .generate-variant-variables(blue, important);
111
78
  }
112
79
  }
113
80
 
@@ -121,33 +88,56 @@
121
88
  }
122
89
  }
123
90
 
91
+ &__featured {
92
+ &:not(.@{baseClass}__important) {
93
+ .generate-variant-variables(purple);
94
+ }
95
+
96
+ &.@{baseClass}__important {
97
+ .generate-variant-variables(purple, important);
98
+ }
99
+ }
100
+
101
+ &__activity {
102
+ &:not(.@{baseClass}__important) {
103
+ .generate-variant-variables(pink);
104
+ }
105
+
106
+ &.@{baseClass}__important {
107
+ .generate-variant-variables(pink, important);
108
+ }
109
+ }
110
+
124
111
  &__warning {
125
112
  &:not(.@{baseClass}__important) {
126
113
  .generate-variant-variables(yellow);
127
- --_no-btn-fc: var(--yellow-600);
128
114
  }
129
115
 
130
116
  &.@{baseClass}__important {
131
- --_no-bc: var(--_no-bg);
132
- --_no-bg: var(--yellow-400);
117
+ --_no-bg: var(--yellow-300);
118
+ --_no-icon-bg: var(--yellow-400);
133
119
  --_no-fc: var(--black);
134
- --_no-btn-fc: var(--_no-fc);
135
- --_no-btn-bg-active: var(--yellow-300);
136
- --_no-btn-bg-focus: var(--yellow-300);
137
- --_no-code-bc: var(--yellow-500);
138
- --_no-code-bg: var(--yellow-300);
120
+ --_no-code-bc: var(--yellow-400);
121
+ --_no-code-bg: var(--yellow-200);
122
+
123
+ .s-notice--icon {
124
+ color: var(--white);
125
+ }
139
126
 
140
127
  .dark-mode({
141
128
  --_no-fc: var(--white);
142
129
  --_no-code-bc: var(--yellow-300);
143
130
  --_no-code-bg: var(--yellow-500);
131
+ --_no-bg: var(--yellow-400);
132
+ --_no-icon-bg: var(--yellow-500);
144
133
  });
145
134
 
146
135
  .highcontrast-mode({
147
- --_no-bg: var(--yellow-500);
136
+ --_no-bg: var(--yellow-400);
137
+ --_no-icon-bg: var(--yellow-500);
138
+ --_no-code-bc: var(--yellow-300);
139
+ --_no-code-bg: var(--yellow-500);
148
140
  --_no-fc: var(--white);
149
- --_no-btn-bg-active: transparent;
150
- --_no-btn-bg-focus: transparent;
151
141
  });
152
142
  }
153
143
  }
@@ -156,42 +146,67 @@
156
146
  code {
157
147
  background-color: var(--_no-code-bg);
158
148
  color: var(--_no-code-fc);
159
- outline: var(--su-static1) solid var(--_no-code-bc);
160
-
161
- border-radius: var(--br-md);
149
+ outline: var(--su1) solid var(--_no-code-bc);
162
150
  padding-left: var(--su2);
163
151
  padding-right: var(--su2);
152
+ white-space: nowrap;
164
153
  }
165
154
 
166
- & &--btn {
167
- // TODO: decouple .s-notice--btn from .s-btn
155
+ button&--dismiss {
168
156
  &:active {
169
- background-color: var(--_no-btn-bg-active, inherit) !important;
157
+ background-color: var(--_no-fc);
158
+ color: var(--_no-bg);
170
159
  }
171
160
 
172
161
  &:focus-visible,
173
162
  &:hover,
174
163
  &.focus-inset-bordered {
175
- background-color: var(--_no-btn-bg-focus, inherit) !important;
164
+ background-color: var(--_no-fc);
165
+ color: var(--_no-bg);
176
166
  }
167
+ color: var(--_no-fc);
168
+ }
169
+
170
+ &--actions {
171
+ display: flex;
172
+ margin-left: auto;
173
+ align-self: flex-start;
174
+ padding-left: var(--su24);
175
+ color: var(--_no-fc);
176
+ gap: calc(var(--su24) - var(--su2)); //22px
177
+
178
+ //Fix css issue caused by svelte-sonner-toast in the NoticeAction svelte component
179
+ overflow-wrap: initial !important;
180
+ }
177
181
 
178
- color: var(--_no-btn-fc, inherit) !important;
179
- padding: var(--su8);
182
+ //Fix notice action color for __important variant
183
+ &--actions > .s-link:not(&--dismiss) {
184
+ color: var(--_no-fc);
180
185
  }
181
186
 
182
187
  // STYLES MODIFIED BY COMPONENT-SPECIFIC CUSTOM PROPERTIES
183
188
  background: var(--_no-bg);
184
- border-color: var(--_no-bc);
185
189
  color: var(--_no-fc);
186
-
187
- border-style: solid;
188
- font-size: var(--fs-body1);
189
190
  }
190
191
 
191
192
  .s-notice {
192
193
  .construct-notice-component(s-notice);
193
194
 
194
- border-radius: var(--br-md);
195
- border-width: var(--su-static1);
196
- padding: var(--su16);
195
+ display: flex;
196
+ align-items: center;
197
+
198
+ --_no-pd: var(--su8);
199
+ padding: var(--_no-pd) var(--su12) var(--_no-pd) 0;
200
+
201
+ &--icon {
202
+ background: var(--_no-icon-bg);
203
+ border: var(--su1) solid var(--_no-icon-bc, var(--_no-icon-bg));
204
+ padding: var(--_no-pd);
205
+ margin-right: var(--su12);
206
+ align-self: stretch;
207
+
208
+ //Negative margin to make up for s-notice's padding
209
+ margin-top: calc(var(--_no-pd) * -1);
210
+ margin-bottom: calc(var(--_no-pd) * -1);
211
+ }
197
212
  }
@@ -8,70 +8,78 @@
8
8
  }
9
9
 
10
10
  & &--item {
11
- --_pa-item-bg: transparent;
12
- --_pa-item-bc: var(--bc-darker);
13
- --_pa-item-fc: var(--fc-medium);
14
- --_pa-item-bg-focus: var(--black-400);
15
- --_pa-item-fc-focus: var(--white);
16
- --_pa-item-bg-hover: var(--black-225);
17
- --_pa-item-bc-hover: var(--bc-darker);
18
- --_pa-item-fc-hover: var(--fc-dark);
11
+ --_pa-item-bg: unset;
12
+ --_pa-item-br: unset;
13
+ --_pa-item-fc: var(--black-400);
14
+ --_pa-item-p: var(--su4);
19
15
 
20
- // CONTEXTUAL STYLES
21
- .highcontrast-mode({ text-decoration: none; });
16
+ .highcontrast-mode({
17
+ &[href] {
18
+ text-decoration: underline;
19
+ }
20
+ });
22
21
 
23
22
  // MODIFIERS
24
23
  &.is-selected {
25
- --_pa-item-bg: var(--theme-primary);
26
- --_pa-item-bc: transparent;
27
- --_pa-item-fc: var(--white);
28
- --_pa-item-bg-focus: var(--theme-primary-400);
29
- }
30
- &.s-pagination--item__clear {
31
- --_pa-item-bg: transparent;
32
- --_pa-item-bc: transparent;
33
- --_pa-item-fc: inherit;
24
+ --_pa-item-fc: var(--black-600);
25
+
26
+ &:not(:hover):not(:focus-visible):before {
27
+ background-color: var(--black-600);
28
+ content: "";
29
+ height: var(--su2);
30
+ left: 0;
31
+ position: absolute;
32
+ right: 0;
33
+ top: 100%;
34
+ }
34
35
  }
35
- // override hover styles to match base styles
36
- &.is-selected,
37
- &.s-pagination--item__clear {
38
- --_pa-item-bc-hover: var(--_pa-item-bc);
39
- --_pa-item-bg-hover: var(--_pa-item-bg);
40
- --_pa-item-fc-hover: var(--_pa-item-fc);
36
+ &.s-pagination--item__nav {
37
+ --_pa-item-bg: var(--black-150);
38
+ --_pa-item-br: var(--br-circle);
39
+ --_pa-item-fc: var(--black-600);
40
+ --_pa-item-p: var(--su6);
41
+
42
+ aspect-ratio: 1 / 1;
43
+
44
+ &:hover {
45
+ --_pa-item-bg: var(--black-200);
46
+ }
41
47
  }
42
48
 
43
49
  // INTERACTION
44
- &:hover {
45
- background-color: var(--_pa-item-bg-hover);
46
- border-color: var(--_pa-item-bc-hover);
47
- color: var(--_pa-item-fc-hover);
50
+ &[href]:hover:not(&__nav) {
51
+ --_pa-item-bg: var(--black-150);
52
+ --_pa-item-br: var(--br-pill);
53
+ --_pa-item-fc: var(--black-600);
48
54
  }
49
-
50
55
  &:focus-visible {
51
- .focus-styles(true, true);
56
+ --_pa-item-bg: var(--black-150);
57
+ --_pa-item-fc: var(--black-600);
58
+ .focus-styles(false, true);
52
59
  }
53
-
54
- &:focus-visible,
60
+ &:focus-visible:not(&__nav),
55
61
  &.focus-inset-bordered {
56
- background-color: var(--_pa-item-bg-focus);
57
- color: var(--_pa-item-fc-focus);
62
+ --_pa-item-br: var(--br-md);
58
63
  }
59
64
 
60
65
  background-color: var(--_pa-item-bg);
61
- border: 1px solid var(--_pa-item-bc);
66
+ border-radius: var(--_pa-item-br);
62
67
  color: var(--_pa-item-fc);
68
+ padding: var(--_pa-item-p);
63
69
 
64
- border-radius: var(--br-md);
65
- display: inline-block;
66
- font-size: var(--fs-body1);
67
- line-height: var(--lh-xl);
68
- padding: 0 var(--su8);
70
+ display: inline-flex;
71
+ align-items: center;
72
+ justify-content: center;
73
+ margin: var(--su1);
74
+ position: relative;
75
+ text-decoration: none;
69
76
  }
70
77
 
71
78
  &,
72
79
  ul {
73
80
  display: flex;
81
+ align-items: center;
74
82
  flex-wrap: wrap;
75
- gap: var(--su4);
83
+ gap: var(--su2);
76
84
  }
77
85
  }