@stackoverflow/stacks 0.71.0 → 0.72.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.
@@ -34,7 +34,13 @@
34
34
  cursor: pointer;
35
35
  user-select: none;
36
36
 
37
- .highcontrast-mode({ border-color: currentColor; });
37
+ .highcontrast-mode({
38
+ border-color: currentColor;
39
+
40
+ &:not(.s-btn__link):not(.s-btn__unset) {
41
+ text-decoration: none;
42
+ }
43
+ });
38
44
 
39
45
  button &,
40
46
  button[type="submit"] &,
@@ -206,6 +212,12 @@
206
212
  box-shadow: none;
207
213
  }
208
214
 
215
+ &:focus {
216
+ .highcontrast-mode({
217
+ box-shadow: 0 0 0 @su4 var(--focus-ring);
218
+ });
219
+ }
220
+
209
221
  &.is-selected {
210
222
  color: var(--theme-button-filled-selected-color);
211
223
  background-color: var(--theme-button-filled-selected-background-color);
@@ -293,6 +305,7 @@
293
305
 
294
306
  &:focus {
295
307
  box-shadow: 0 0 0 @su4 var(--focus-ring-muted);
308
+ .highcontrast-mode({ box-shadow: 0 0 0 @su4 var(--focus-ring-muted); });
296
309
  }
297
310
 
298
311
  &.is-selected {
@@ -341,6 +354,7 @@
341
354
 
342
355
  &:focus {
343
356
  box-shadow: 0 0 0 @su4 var(--focus-ring-error);
357
+ .highcontrast-mode({ box-shadow: 0 0 0 @su4 var(--focus-ring-error); });
344
358
  }
345
359
 
346
360
  &.is-selected {
@@ -373,6 +387,10 @@
373
387
  .highcontrast-mode({
374
388
  color: var(--white);
375
389
 
390
+ &:focus {
391
+ box-shadow: 0 0 0 @su4 var(--focus-ring-error);
392
+ }
393
+
376
394
  .s-btn--number {
377
395
  color: var(--black);
378
396
  }
@@ -437,7 +455,6 @@
437
455
  }
438
456
  });
439
457
 
440
-
441
458
  &:hover,
442
459
  &:focus,
443
460
  &:active {
@@ -450,6 +467,12 @@
450
467
  box-shadow: none;
451
468
  }
452
469
 
470
+ &:focus {
471
+ .highcontrast-mode({
472
+ box-shadow: 0 0 0 @su4 var(--focus-ring);
473
+ });
474
+ }
475
+
453
476
  &.is-selected {
454
477
  color: var(--theme-button-primary-selected-color);
455
478
  background-color: var(--theme-button-primary-selected-background-color);
@@ -476,10 +499,13 @@
476
499
  }
477
500
 
478
501
  &:active {
479
- border-color: var(--bc-darkest);
480
502
  background-color: var(--black-050);
481
503
  color: var(--black-900);
482
504
  }
505
+
506
+ &:focus {
507
+ box-shadow: 0 0 0 @su4 var(--focus-ring-muted);
508
+ }
483
509
  }
484
510
 
485
511
  .s-btn__facebook {
@@ -517,11 +543,16 @@
517
543
  background-color: var(--black-900);
518
544
  color: var(--white);
519
545
  }
546
+
547
+ &:focus {
548
+ box-shadow: 0 0 0 @su4 var(--focus-ring-muted);
549
+ }
520
550
  }
521
551
 
522
552
  .s-btn__unset,
523
553
  .s-btn__unset:hover,
524
- .s-btn__unset:active {
554
+ .s-btn__unset:active,
555
+ .s-btn__unset:focus {
525
556
  padding: 0;
526
557
  border: none;
527
558
  outline: none;
@@ -534,10 +565,6 @@
534
565
  user-select: auto;
535
566
  }
536
567
 
537
- .s-btn__unset:focus {
538
- color: unset;
539
- }
540
-
541
568
  .s-btn__link {
542
569
  display: inline;
543
570
  padding: 0;
@@ -556,6 +583,15 @@
556
583
  &:focus,
557
584
  &[disabled] {
558
585
  background: none;
586
+ box-shadow: none;
587
+ }
588
+
589
+ &.s-btn__dropdown {
590
+ padding-right: 0.9em;
591
+
592
+ &:after {
593
+ right: 0;
594
+ }
559
595
  }
560
596
  }
561
597
 
@@ -24,17 +24,6 @@
24
24
  }
25
25
  }
26
26
 
27
- // ============================================================================
28
- // $ LINKED CARDS
29
- // ----------------------------------------------------------------------------
30
- a.s-card:not(.s-card__muted) {
31
- &:hover,
32
- &:focus,
33
- &:active {
34
- border-color: var(--bc-darker);
35
- }
36
- }
37
-
38
27
  // ============================================================================
39
28
  // $ MODIFIERS
40
29
  // ----------------------------------------------------------------------------
@@ -46,3 +35,10 @@ a.s-card:not(.s-card__muted) {
46
35
  opacity: 0.65;
47
36
  }
48
37
  }
38
+
39
+ // ============================================================================
40
+ // $ LINKED CARDS
41
+ // ----------------------------------------------------------------------------
42
+ a.s-card {
43
+ text-decoration: none !important;
44
+ }
@@ -378,6 +378,11 @@ fieldset {
378
378
  background-color: var(--theme-secondary-400);
379
379
  background-image: url("data:image/svg+xml,%3Csvg width='11' height='11' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 3.41L8.59 2 4 6.59 2.41 5 1 6.41l3 3z' fill='%23fff'/%3E%3C/svg%3E");
380
380
 
381
+ .highcontrast-dark-mode({
382
+ border-color: var(--blue-700) !important;
383
+ background-color: var(--blue-300);
384
+ });
385
+
381
386
  &:focus {
382
387
  border-color: var(--theme-secondary-400);
383
388
  }
@@ -400,6 +405,11 @@ fieldset {
400
405
  border-color: var(--theme-secondary-400);
401
406
  border-width: 0.30769231em;
402
407
  background-color: @white; // This should always be white regardless of dark mode
408
+
409
+ .highcontrast-dark-mode({
410
+ border-color: var(--blue-300);
411
+ outline: 1px solid var(--black);
412
+ });
403
413
  }
404
414
 
405
415
  &:focus {
@@ -44,6 +44,8 @@ a.s-link-preview--title {
44
44
  &.s-link__visited:visited {
45
45
  color: var(--theme-link-color);
46
46
  text-decoration: none;
47
+
48
+ .highcontrast-mode({ text-decoration: underline; });
47
49
  }
48
50
 
49
51
  &:hover,
@@ -52,6 +54,8 @@ a.s-link-preview--title {
52
54
  &.s-link__visited:active {
53
55
  color: var(--theme-link-color-hover);
54
56
  text-decoration: none;
57
+
58
+ .highcontrast-mode({ text-decoration: underline; });
55
59
  }
56
60
  }
57
61
 
@@ -21,9 +21,12 @@ a,
21
21
  cursor: pointer;
22
22
  user-select: auto;
23
23
 
24
+ .highcontrast-mode({
25
+ text-decoration: underline;
26
+ });
27
+
24
28
  &.s-link__visited:visited {
25
29
  color: var(--theme-link-color-visited);
26
- text-decoration: none;
27
30
  }
28
31
 
29
32
  &:hover,
@@ -31,7 +34,6 @@ a,
31
34
  &:active,
32
35
  &.s-link__visited:active {
33
36
  color: var(--theme-link-color-hover);
34
- text-decoration: none;
35
37
  }
36
38
 
37
39
  &.s-link__grayscale {
@@ -92,6 +94,25 @@ a,
92
94
  &.s-link__underlined {
93
95
  text-decoration: underline !important;
94
96
  }
97
+
98
+ &.s-link__dropdown {
99
+ position: relative;
100
+ padding-right: 0.9em;
101
+
102
+ &:after {
103
+ content: "";
104
+ position: absolute;
105
+ z-index: @zi-active;
106
+ top: calc(50% - 2px);
107
+ right: 0;
108
+ border-style: solid;
109
+ border-width: @su4;
110
+ border-top-width: @su4;
111
+ border-bottom-width: 0;
112
+ border-color: currentColor transparent;
113
+ pointer-events: none;
114
+ }
115
+ }
95
116
  }
96
117
 
97
118
  button.s-link {
@@ -102,6 +123,7 @@ button.s-link {
102
123
  padding: 0;
103
124
  line-height: inherit;
104
125
  user-select: auto;
126
+ font-family: inherit;
105
127
 
106
128
  &:focus {
107
129
  outline: none;
@@ -158,6 +180,7 @@ button.s-link {
158
180
  border-radius: 0;
159
181
  text-align: left;
160
182
  line-height: inherit;
183
+ font-family: inherit;
161
184
 
162
185
  &:hover,
163
186
  &:active {
@@ -56,6 +56,14 @@
56
56
  &.is-selected {
57
57
  background: var(--theme-primary-color);
58
58
  color: var(--white);
59
+
60
+ &:hover,
61
+ &:active {
62
+ background: var(--theme-primary-600);
63
+ color: var(--white);
64
+ }
65
+
66
+ .highcontrast-mode({ text-decoration: none; });
59
67
  }
60
68
 
61
69
  &.s-navigation--item__dropdown {
@@ -30,6 +30,8 @@
30
30
  line-height: @lh-xl;
31
31
  color: var(--fc-medium);
32
32
 
33
+ .highcontrast-mode({ text-decoration: none; });
34
+
33
35
  &:hover {
34
36
  border-color: var(--bc-darker);
35
37
  background-color: var(--black-100);
@@ -182,3 +182,42 @@
182
182
  margin-left: auto;
183
183
  }
184
184
  }
185
+
186
+ .s-post-summary--answer {
187
+ position: relative;
188
+ margin: @su16 1em 0 1em;
189
+ padding: 0.5em 0 0.5em calc(1em + @su4);
190
+
191
+ + .s-post-summary--answer {
192
+ margin-top: @su16;
193
+ }
194
+
195
+ &:before {
196
+ content: "";
197
+ display: block;
198
+ position: absolute;
199
+ top: 0;
200
+ bottom: 0;
201
+ left: 0;
202
+ width: @su4;
203
+ border-radius: @su8;
204
+ background: var(--black-150);
205
+
206
+ .highcontrast-mode({
207
+ background: var(--black-600);
208
+ });
209
+ }
210
+
211
+ .s-post-summary--stats {
212
+ width: auto;
213
+ flex-direction: row;
214
+ align-items: center;
215
+ margin-bottom: @su4;
216
+ }
217
+
218
+ .s-post-summary--answer-excerpt {
219
+ color: var(--black-600);
220
+ margin-bottom: @su8;
221
+ .v-truncate4;
222
+ }
223
+ }
@@ -322,8 +322,8 @@
322
322
  top: 0;
323
323
  bottom: 0;
324
324
  left: 0;
325
- width: 4px;
326
- border-radius: 8px;
325
+ width: @su4;
326
+ border-radius: @su8;
327
327
  background: var(--black-150);
328
328
 
329
329
  .highcontrast-mode({
@@ -431,6 +431,11 @@
431
431
  border-radius: @br-sm;
432
432
  }
433
433
 
434
+ // When contained within a link, we want the code to be link-colored
435
+ *:not(.s-code-block) > a code {
436
+ color: var(--theme-link-color);
437
+ }
438
+
434
439
  pre {
435
440
  margin-top: 0;
436
441
  margin-bottom: calc(var(--s-prose-spacing) + 0.4em); // Increase this spacing for better optical alignment
@@ -84,6 +84,8 @@
84
84
 
85
85
  .s-tag-styles(@tags-border, @tags-background, @tags-color);
86
86
 
87
+ .highcontrast-mode({ text-decoration: none; });
88
+
87
89
  &.is-selected {
88
90
  .s-tag-selected-styles(@tags-selected-border, @tags-selected-background, @tags-selected-color);
89
91
  }