@primer/css 0.0.0-20220120184157 → 0.0.0-2022020193741

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 (129) hide show
  1. package/CHANGELOG.md +6 -41
  2. package/actionlist/action-list-item.scss +49 -102
  3. package/actionlist/index.scss +0 -1
  4. package/autocomplete/autocomplete.scss +1 -1
  5. package/avatars/avatar-stack.scss +0 -1
  6. package/base/base.scss +0 -1
  7. package/base/index.scss +1 -0
  8. package/blankslate/index.scss +1 -0
  9. package/breadcrumb/breadcrumb.scss +1 -1
  10. package/buttons/button-group.scss +2 -3
  11. package/buttons/button.scss +35 -0
  12. package/buttons/misc.scss +7 -6
  13. package/color-modes/native.scss +0 -1
  14. package/color-modes/themes/dark.scss +1 -0
  15. package/color-modes/themes/dark_colorblind.scss +1 -0
  16. package/color-modes/themes/dark_dimmed.scss +1 -0
  17. package/color-modes/themes/dark_high_contrast.scss +1 -0
  18. package/color-modes/themes/light.scss +1 -0
  19. package/color-modes/themes/light_colorblind.scss +1 -0
  20. package/color-modes/themes/light_high_contrast.scss +1 -0
  21. package/core/index.scss +1 -5
  22. package/dist/actionlist.css +1 -1
  23. package/dist/actionlist.css.map +1 -1
  24. package/dist/alerts.css.map +1 -1
  25. package/dist/autocomplete.css.map +1 -1
  26. package/dist/avatars.css +1 -1
  27. package/dist/avatars.css.map +1 -1
  28. package/dist/base.css.map +1 -1
  29. package/dist/blankslate.css.map +1 -1
  30. package/dist/box.css.map +1 -1
  31. package/dist/branch-name.css.map +1 -1
  32. package/dist/breadcrumb.css.map +1 -1
  33. package/dist/buttons.css +1 -1
  34. package/dist/buttons.css.map +1 -1
  35. package/dist/color-modes.css +1 -1
  36. package/dist/color-modes.css.map +1 -1
  37. package/dist/core.css +1 -1
  38. package/dist/core.css.map +1 -1
  39. package/dist/dropdown.css.map +1 -1
  40. package/dist/forms.css.map +1 -1
  41. package/dist/header.css.map +1 -1
  42. package/dist/labels.css +1 -1
  43. package/dist/labels.css.map +1 -1
  44. package/dist/layout.css +1 -1
  45. package/dist/layout.css.map +1 -1
  46. package/dist/links.css.map +1 -1
  47. package/dist/loaders.css.map +1 -1
  48. package/dist/markdown.css.map +1 -1
  49. package/dist/marketing-buttons.css +1 -1
  50. package/dist/marketing-buttons.css.map +1 -1
  51. package/dist/marketing-type.css.map +1 -1
  52. package/dist/marketing-utilities.css +1 -1
  53. package/dist/marketing-utilities.css.map +1 -1
  54. package/dist/marketing.css +1 -1
  55. package/dist/marketing.css.map +1 -1
  56. package/dist/meta.json +84 -95
  57. package/dist/navigation.css.map +1 -1
  58. package/dist/pagination.css.map +1 -1
  59. package/dist/popover.css +1 -1
  60. package/dist/popover.css.map +1 -1
  61. package/dist/primer.css +4 -4
  62. package/dist/primer.css.map +1 -1
  63. package/dist/product.css +1 -1
  64. package/dist/product.css.map +1 -1
  65. package/dist/progress.css.map +1 -1
  66. package/dist/select-menu.css.map +1 -1
  67. package/dist/stats/actionlist.json +1 -1
  68. package/dist/stats/avatars.json +1 -1
  69. package/dist/stats/buttons.json +1 -1
  70. package/dist/stats/color-modes.json +1 -1
  71. package/dist/stats/core.json +1 -1
  72. package/dist/stats/labels.json +1 -1
  73. package/dist/stats/layout.json +1 -1
  74. package/dist/stats/marketing-buttons.json +1 -1
  75. package/dist/stats/marketing-utilities.json +1 -1
  76. package/dist/stats/marketing.json +1 -1
  77. package/dist/stats/popover.json +1 -1
  78. package/dist/stats/primer.json +1 -1
  79. package/dist/stats/product.json +1 -1
  80. package/dist/stats/utilities.json +1 -1
  81. package/dist/subhead.css.map +1 -1
  82. package/dist/timeline.css.map +1 -1
  83. package/dist/toasts.css.map +1 -1
  84. package/dist/tooltips.css.map +1 -1
  85. package/dist/truncate.css.map +1 -1
  86. package/dist/utilities.css +1 -1
  87. package/dist/utilities.css.map +1 -1
  88. package/forms/form-control.scss +0 -2
  89. package/labels/counters.scss +1 -1
  90. package/labels/index.scss +1 -0
  91. package/labels/labels.scss +0 -1
  92. package/layout/index.scss +1 -1
  93. package/layout/layout.scss +10 -6
  94. package/layout/mixins.scss +4 -30
  95. package/markdown/images.scss +2 -2
  96. package/marketing/buttons/button.scss +0 -8
  97. package/marketing/index.scss +0 -1
  98. package/marketing/type/typography.scss +0 -3
  99. package/marketing/utilities/animations.scss +0 -42
  100. package/navigation/filter-list.scss +2 -2
  101. package/navigation/menu.scss +2 -2
  102. package/navigation/sidenav.scss +2 -2
  103. package/navigation/subnav.scss +2 -2
  104. package/navigation/tabnav.scss +2 -2
  105. package/navigation/underline-nav.scss +2 -2
  106. package/package.json +13 -12
  107. package/pagination/pagination.scss +3 -3
  108. package/popover/popover.scss +1 -1
  109. package/select-menu/select-menu.scss +2 -2
  110. package/stylelint.config.cjs +11 -2
  111. package/support/mixins/color-modes.scss +0 -3
  112. package/support/mixins/misc.scss +13 -4
  113. package/support/mixins/typography.scss +2 -3
  114. package/support/variables/layout.scss +2 -1
  115. package/utilities/visibility-display.scss +3 -3
  116. package/actionlist/action-list-tree.scss +0 -92
  117. package/button-refactor/ButtonsLinksAPI.md +0 -111
  118. package/button-refactor/button-group.scss +0 -0
  119. package/button-refactor/button.scss +0 -245
  120. package/button-refactor/icon-button.scss +0 -14
  121. package/button-refactor/link-styled-as-button.scss +0 -75
  122. package/button-refactor/link.scss +0 -25
  123. package/dist/marketing-links.css +0 -2
  124. package/dist/marketing-links.css.map +0 -1
  125. package/dist/marketing-links.js +0 -1
  126. package/dist/stats/marketing-links.json +0 -1
  127. package/layout/page-layout.scss +0 -380
  128. package/marketing/links/index.scss +0 -3
  129. package/marketing/links/link.scss +0 -50
package/labels/index.scss CHANGED
@@ -1,5 +1,6 @@
1
1
  @import '../support/index.scss';
2
2
  @import './mixins.scss';
3
+
3
4
  @import './issue-labels.scss';
4
5
  @import './labels.scss';
5
6
  @import './states.scss';
@@ -10,7 +10,6 @@
10
10
  .label, // TODO: Deprecte
11
11
  .Label {
12
12
  @include labels-base;
13
-
14
13
  border-color: var(--color-border-default);
15
14
 
16
15
  &:hover {
package/layout/index.scss CHANGED
@@ -1,7 +1,7 @@
1
1
  @import '../support/index.scss';
2
2
  @import './mixins.scss';
3
+
3
4
  @import './container.scss';
4
5
  @import './grid.scss';
5
6
  @import './grid-offset.scss';
6
7
  @import './layout.scss';
7
- @import './page-layout.scss';
@@ -2,22 +2,21 @@
2
2
 
3
3
  .Layout {
4
4
  display: grid;
5
-
6
5
  --Layout-sidebar-width: #{map-get($sidebar-width, 'sm')};
7
6
  --Layout-gutter: 16px;
8
7
 
9
- @media (max-width: calc(#{$width-sm} - 0.02px)) {
8
+ @media (max-width: calc(#{$width-sm} - 1px)) {
10
9
  @include flow-as-row;
11
10
  }
12
11
 
13
12
  &.Layout--flowRow-until-md {
14
- @media (max-width: calc(#{$width-md} - 0.02px)) {
13
+ @media (max-width: calc(#{$width-md} - 1px)) {
15
14
  @include flow-as-row;
16
15
  }
17
16
  }
18
17
 
19
18
  &.Layout--flowRow-until-lg {
20
- @media (max-width: calc(#{$width-lg} - 0.02px)) {
19
+ @media (max-width: calc(#{$width-lg} - 1px)) {
21
20
  @include flow-as-row;
22
21
  }
23
22
  }
@@ -25,7 +24,8 @@
25
24
  // Flow as column
26
25
 
27
26
  grid-auto-flow: column;
28
- grid-template-columns: auto 0 minmax(0, calc(100% - var(--Layout-sidebar-width) - var(--Layout-gutter))); // sidebar column, separator, main column
27
+ grid-template-columns: auto 0 1fr; // sidebar column, separator, main column
28
+ // stylelint-disable-next-line primer/no-undefined-vars
29
29
  grid-gap: var(--Layout-gutter);
30
30
 
31
31
  .Layout-sidebar {
@@ -101,7 +101,7 @@
101
101
  }
102
102
 
103
103
  &.Layout--sidebarPosition-end {
104
- grid-template-columns: minmax(0, calc(100% - var(--Layout-sidebar-width) - var(--Layout-gutter))) 0 auto;
104
+ grid-template-columns: 1fr 0 auto;
105
105
 
106
106
  .Layout-main {
107
107
  grid-column: 1;
@@ -146,6 +146,7 @@
146
146
  }
147
147
 
148
148
  .Layout-sidebar {
149
+ // stylelint-disable-next-line primer/no-undefined-vars
149
150
  width: var(--Layout-sidebar-width);
150
151
  }
151
152
 
@@ -168,14 +169,17 @@
168
169
  }
169
170
 
170
171
  .Layout-main-centered-md {
172
+ // stylelint-disable-next-line primer/no-undefined-vars
171
173
  max-width: calc(#{$container-md} + var(--Layout-sidebar-width) + var(--Layout-gutter));
172
174
  }
173
175
 
174
176
  .Layout-main-centered-lg {
177
+ // stylelint-disable-next-line primer/no-undefined-vars
175
178
  max-width: calc(#{$container-lg} + var(--Layout-sidebar-width) + var(--Layout-gutter));
176
179
  }
177
180
 
178
181
  .Layout-main-centered-xl {
182
+ // stylelint-disable-next-line primer/no-undefined-vars
179
183
  max-width: calc(#{$container-xl} + var(--Layout-sidebar-width) + var(--Layout-gutter));
180
184
  }
181
185
  }
@@ -1,4 +1,4 @@
1
- // Layout alpha mixins
1
+ // Layout mixins
2
2
 
3
3
  @mixin flow-as-row {
4
4
  grid-auto-flow: row;
@@ -7,9 +7,9 @@
7
7
  .Layout-sidebar,
8
8
  .Layout-divider,
9
9
  .Layout-main {
10
- width: 100% !important;
11
- grid-column: 1 !important;
12
- }
10
+ width: 100% !important;
11
+ grid-column: 1 !important;
12
+ }
13
13
 
14
14
  &.Layout--sidebarPosition-flowRow-start {
15
15
  .Layout-sidebar {
@@ -77,29 +77,3 @@
77
77
  }
78
78
  }
79
79
  }
80
-
81
- // Layout beta mixins
82
-
83
- // responsive region dividers
84
-
85
- @mixin Layout-line-divider {
86
- position: absolute;
87
- left: calc(var(--Layout-outer-spacing-x) * -1);
88
- display: block;
89
- width: calc(100% + (var(--Layout-outer-spacing-x) * 2));
90
- height: 1px;
91
- content: '';
92
- background-color: $Layout-divider-color;
93
- }
94
-
95
- @mixin Layout-filled-divider {
96
- position: absolute;
97
- bottom: calc(#{$spacer-2} * -1); // -8px
98
- left: calc(var(--Layout-outer-spacing-x) * -1);
99
- display: block;
100
- width: calc(100% + (var(--Layout-outer-spacing-x) * 2));
101
- height: #{$spacer-2}; // 8px
102
- content: '';
103
- background-color: var(--color-canvas-inset);
104
- box-shadow: inset 0 1px $Layout-divider-color, inset 0 -1px $Layout-divider-color;
105
- }
@@ -10,12 +10,12 @@
10
10
  box-sizing: content-box;
11
11
  background-color: var(--color-canvas-default);
12
12
 
13
- &[align='right'] {
13
+ &[align=right] {
14
14
  // stylelint-disable-next-line primer/spacing
15
15
  padding-left: 20px;
16
16
  }
17
17
 
18
- &[align='left'] {
18
+ &[align=left] {
19
19
  // stylelint-disable-next-line primer/spacing
20
20
  padding-right: 20px;
21
21
  }
@@ -38,7 +38,6 @@
38
38
  }
39
39
 
40
40
  &:hover {
41
- text-decoration: none;
42
41
  box-shadow: var(--color-mktg-btn-shadow-hover) !important;
43
42
  }
44
43
 
@@ -69,13 +68,6 @@
69
68
  opacity: 0.5 !important;
70
69
  }
71
70
  }
72
-
73
- &.disabled,
74
- &[disabled] {
75
- pointer-events: none;
76
- cursor: default;
77
- opacity: 0.5;
78
- }
79
71
  }
80
72
 
81
73
  .btn-muted-mktg {
@@ -11,5 +11,4 @@
11
11
  // marketing specific css modules
12
12
  @import './type/index.scss';
13
13
  @import './buttons/index.scss';
14
- @import './links/index.scss';
15
14
  @import './utilities/index.scss';
@@ -21,7 +21,6 @@
21
21
 
22
22
  font-size: map-get($pairing, 'size') !important;
23
23
  line-height: map-get($pairing, 'lh') !important;
24
-
25
24
  @if (map-get($pairing, 'size') >= $mktg-header-weight-threshold) { font-weight: $mktg-header-weight-large !important; }
26
25
 
27
26
  @if (nth($sizes, 1) != nth($sizes, 2)) {
@@ -76,9 +75,7 @@
76
75
 
77
76
  font-size: map-get($pairing, 'size') !important;
78
77
  line-height: map-get($pairing, 'lh') !important;
79
-
80
78
  @if (map-get($pairing, 'size') >= $mktg-body-spacing-threshold) { letter-spacing: $mktg-body-spacing-large !important; }
81
-
82
79
  @if (map-get($pairing, 'size') >= $mktg-body-weight-threshold) { font-weight: $font-weight-semibold; }
83
80
 
84
81
  @if (nth($sizes, 1) != nth($sizes, 2)) {
@@ -7,45 +7,3 @@
7
7
  transform: scale3d(1.025, 1.025, 1.025);
8
8
  }
9
9
  }
10
-
11
- // Animated arrow symbol, used in marketing links, buttons, etc.
12
- .btn-mktg,
13
- .link-mktg,
14
- .arrow-target-mktg {
15
- .octicon {
16
- width: 1em;
17
- height: 1em;
18
- }
19
-
20
- .arrow-symbol-mktg {
21
- transition: transform 0.2s;
22
- transform: translateX(0);
23
-
24
- // stylelint-disable-next-line selector-max-type
25
- path:last-child {
26
- stroke-dasharray: 10;
27
- stroke-dashoffset: 10;
28
- transition: stroke-dashoffset 0.2s;
29
- }
30
- }
31
-
32
- @media screen and (prefers-reduced-motion: no-preference) {
33
- &:hover,
34
- &:focus {
35
- .arrow-symbol-mktg {
36
- transform: translateX(4px);
37
-
38
- // stylelint-disable-next-line selector-max-type, selector-max-specificity, max-nesting-depth
39
- path:last-child {
40
- stroke-dashoffset: 20;
41
- }
42
- }
43
- }
44
-
45
- &:active {
46
- .arrow-symbol-mktg {
47
- transform: translateX(6px);
48
- }
49
- }
50
- }
51
- }
@@ -41,8 +41,8 @@
41
41
  }
42
42
 
43
43
  &.selected,
44
- &[aria-selected='true'],
45
- &[aria-current]:not([aria-current='false']) {
44
+ &[aria-selected=true],
45
+ &[aria-current]:not([aria-current=false]) {
46
46
  color: var(--color-fg-on-emphasis);
47
47
  background-color: var(--color-accent-emphasis);
48
48
  }
@@ -49,8 +49,8 @@
49
49
  }
50
50
 
51
51
  &.selected,
52
- &[aria-selected='true'],
53
- &[aria-current]:not([aria-current='false']) {
52
+ &[aria-selected=true],
53
+ &[aria-current]:not([aria-current=false]) {
54
54
  cursor: default;
55
55
  background-color: var(--color-menu-bg-active);
56
56
 
@@ -59,7 +59,7 @@
59
59
  background-color: var(--color-canvas-subtle);
60
60
  }
61
61
 
62
- .SideNav-item[aria-current]:not([aria-current='false']),
62
+ .SideNav-item[aria-current]:not([aria-current=false]),
63
63
  .SideNav-item[aria-selected='true'] {
64
64
  background-color: var(--color-sidenav-selected-bg);
65
65
 
@@ -101,7 +101,7 @@
101
101
  outline: none;
102
102
  }
103
103
 
104
- .SideNav-subItem[aria-current]:not([aria-current='false']),
104
+ .SideNav-subItem[aria-current]:not([aria-current=false]),
105
105
  .SideNav-subItem[aria-selected='true'] {
106
106
  font-weight: $font-weight-semibold;
107
107
  color: var(--color-fg-default);
@@ -40,8 +40,8 @@
40
40
  }
41
41
 
42
42
  &.selected,
43
- &[aria-selected='true'],
44
- &[aria-current]:not([aria-current='false']) {
43
+ &[aria-selected=true],
44
+ &[aria-current]:not([aria-current=false]) {
45
45
  z-index: 2;
46
46
  color: var(--color-fg-on-emphasis);
47
47
  background-color: var(--color-accent-emphasis);
@@ -28,8 +28,8 @@
28
28
  transition: color 0.2s cubic-bezier(0.3, 0, 0.5, 1);
29
29
 
30
30
  &.selected,
31
- &[aria-selected='true'],
32
- &[aria-current]:not([aria-current='false']) {
31
+ &[aria-selected=true],
32
+ &[aria-current]:not([aria-current=false]) {
33
33
  color: var(--color-fg-default);
34
34
  background-color: var(--color-canvas-default); // cover bottom border
35
35
  border-color: var(--color-border-default);
@@ -35,8 +35,8 @@
35
35
  }
36
36
 
37
37
  &.selected,
38
- &[role='tab'][aria-selected='true'],
39
- &[aria-current]:not([aria-current='false']) {
38
+ &[role=tab][aria-selected=true],
39
+ &[aria-current]:not([aria-current=false]) {
40
40
  font-weight: $font-weight-bold;
41
41
  color: var(--color-fg-default);
42
42
  border-bottom-color: var(--color-primer-border-active);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@primer/css",
3
- "version": "0.0.0-20220120184157",
3
+ "version": "0.0.0-2022020193741",
4
4
  "description": "The CSS implementation of GitHub's Primer Design System",
5
5
  "homepage": "https://primer.style/css",
6
6
  "author": "GitHub, Inc.",
@@ -35,36 +35,37 @@
35
35
  "storybook": "cd docs && yarn && yarn storybook"
36
36
  },
37
37
  "dependencies": {
38
- "@primer/primitives": "^7.4.0"
38
+ "@primer/primitives": "^7.2.0"
39
39
  },
40
40
  "devDependencies": {
41
41
  "@changesets/changelog-github": "0.4.2",
42
- "@changesets/cli": "2.19.0",
42
+ "@changesets/cli": "2.18.1",
43
43
  "@github/prettier-config": "0.0.4",
44
44
  "@koddsson/postcss-sass": "5.0.0",
45
- "@primer/stylelint-config": "12.2.0",
46
- "autoprefixer": "10.4.1",
45
+ "@primer/stylelint-config": "12.1.1",
46
+ "autoprefixer": "10.4.0",
47
47
  "cssstats": "4.0.2",
48
- "eslint": "8.6.0",
48
+ "eslint": "8.3.0",
49
49
  "eslint-plugin-github": "4.3.5",
50
- "eslint-plugin-jest": "25.3.3",
50
+ "eslint-plugin-jest": "25.3.0",
51
51
  "eslint-plugin-prettier": "4.0.0",
52
52
  "filesize": "8.0.6",
53
53
  "front-matter": "4.0.2",
54
54
  "fs-extra": "10.0.0",
55
55
  "globby": "12.0.2",
56
- "jest": "27.4.5",
56
+ "jest": "27.4.2",
57
57
  "js-yaml": "4.1.0",
58
- "postcss": "8.4.5",
58
+ "postcss": "8.4.4",
59
59
  "postcss-calc": "8.0.0",
60
60
  "postcss-import": "14.0.2",
61
61
  "postcss-load-config": "3.1.0",
62
62
  "postcss-scss": "4.0.2",
63
63
  "postcss-simple-vars": "6.0.3",
64
- "prettier": "2.5.1",
64
+ "prettier": "2.5.0",
65
65
  "semver": "7.3.5",
66
- "stylelint": "14.2.0",
67
- "table": "6.7.5"
66
+ "stylelint": "14.1.0",
67
+ "stylelint-scss": "4.0.0",
68
+ "table": "6.7.3"
68
69
  },
69
70
  "jest": {
70
71
  "testEnvironment": "node",
@@ -42,7 +42,7 @@
42
42
 
43
43
  .current,
44
44
  .current:hover,
45
- [aria-current]:not([aria-current='false']) {
45
+ [aria-current]:not([aria-current=false]) {
46
46
  color: var(--color-fg-on-emphasis);
47
47
  background-color: var(--color-accent-emphasis);
48
48
  border-color: transparent;
@@ -50,10 +50,10 @@
50
50
 
51
51
  .gap,
52
52
  .disabled,
53
- [aria-disabled='true'],
53
+ [aria-disabled=true],
54
54
  .gap:hover,
55
55
  .disabled:hover,
56
- [aria-disabled='true']:hover {
56
+ [aria-disabled=true]:hover {
57
57
  color: var(--color-primer-fg-disabled);
58
58
  cursor: default;
59
59
  border-color: transparent;
@@ -196,7 +196,7 @@
196
196
  // Responsive Popover
197
197
  // For < md it will show full-width anchored to the bottom
198
198
 
199
- @media (max-width: ($width-md - 0.02px)) {
199
+ @media (max-width: ($width-md - 1px)) {
200
200
  .Popover {
201
201
  position: fixed;
202
202
  top: auto !important;
@@ -386,7 +386,7 @@ $SelectMenu-max-height: 480px !default;
386
386
  //
387
387
  // Visible when a user clicks/taps on a list item
388
388
 
389
- .SelectMenu-item[aria-checked='true'] {
389
+ .SelectMenu-item[aria-checked=true] {
390
390
  font-weight: $font-weight-semibold;
391
391
  color: var(--color-fg-default);
392
392
 
@@ -402,7 +402,7 @@ $SelectMenu-max-height: 480px !default;
402
402
  // Prevent list items to be selected
403
403
 
404
404
  .SelectMenu-item:disabled,
405
- .SelectMenu-item[aria-disabled='true'] {
405
+ .SelectMenu-item[aria-disabled=true] {
406
406
  color: var(--color-primer-fg-disabled);
407
407
  pointer-events: none;
408
408
  }
@@ -1,7 +1,16 @@
1
1
  module.exports = {
2
2
  extends: ['@primer/stylelint-config'],
3
- ignoreFiles: ['**/*.js', '**/*.cjs'],
3
+ plugins: ['stylelint-scss'],
4
+ customSyntax: require('postcss-scss'),
5
+ ignoreFiles: ['src/fonts/**/*'],
4
6
  rules: {
5
- 'primer/no-override': false
7
+ 'scss/dollar-variable-default': [true, {ignore: 'local'}],
8
+ 'primer/no-override': false,
9
+ 'primer/colors': true,
10
+ 'primer/borders': true,
11
+ 'primer/spacing': true,
12
+ 'primer/typography': true,
13
+ 'primer/box-shadow': true,
14
+ 'primer/no-undefined-vars': [true, {files: 'node_modules/@primer/primitives/dist/scss/colors*/*.scss'}]
6
15
  }
7
16
  }
@@ -8,7 +8,6 @@
8
8
  /*! */ // This is a fix for a cssstats bug see https://github.com/cssstats/cssstats/issues/331
9
9
  }
10
10
  }
11
-
12
11
  @else {
13
12
  [data-color-mode="light"][data-light-theme="#{$theme-name}"],
14
13
  [data-color-mode="dark"][data-dark-theme="#{$theme-name}"] {
@@ -37,7 +36,6 @@
37
36
  @content;
38
37
  }
39
38
  }
40
-
41
39
  @else {
42
40
  [data-color-mode="light"][data-light-theme*="#{$mode}"],
43
41
  [data-color-mode="dark"][data-dark-theme*="#{$mode}"] {
@@ -86,7 +84,6 @@
86
84
  @if $type == dark {
87
85
  $dark-colors: append($dark-colors, (--color-#{$name}, #{$color}));
88
86
  }
89
-
90
87
  @else {
91
88
  $light-colors: append($light-colors, (--color-#{$name}, #{$color}));
92
89
  }
@@ -25,9 +25,18 @@
25
25
  }
26
26
  }
27
27
 
28
- // global focus styles (copy from open PR)
28
+ // if min-width is undefined, return only min-height
29
+ @mixin minTouchTarget($min-height: 48px, $min-width: '') {
30
+ position: absolute;
31
+ top: 50%;
32
+ left: 50%;
33
+ width: 100%;
34
+ height: 100%;
35
+ min-height: $min-height;
36
+ content: '';
37
+ transform: translateX(-50%) translateY(-50%);
29
38
 
30
- @mixin focusOutline {
31
- outline: 2px solid var(--color-accent-fg);
32
- outline-offset: 2px;
39
+ @if $min-width != '' {
40
+ min-width: $min-width;
41
+ }
33
42
  }
@@ -47,6 +47,7 @@
47
47
 
48
48
  // 32px on desktop
49
49
  @include breakpoint(md) { font-size: $h1-size; }
50
+
50
51
  }
51
52
 
52
53
  @mixin f2-responsive {
@@ -61,6 +62,7 @@
61
62
 
62
63
  // 20px on desktop
63
64
  @include breakpoint(md) { font-size: $h3-size; }
65
+
64
66
  }
65
67
 
66
68
  // These use the mixins from above for responsive heading sizes.
@@ -68,18 +70,15 @@
68
70
  // couple the responsive font-size with the font-weight.
69
71
  @mixin h1-responsive {
70
72
  @include f1-responsive;
71
-
72
73
  font-weight: $font-weight-bold;
73
74
  }
74
75
 
75
76
  @mixin h2-responsive {
76
77
  @include f2-responsive;
77
-
78
78
  font-weight: $font-weight-bold;
79
79
  }
80
80
 
81
81
  @mixin h3-responsive {
82
82
  @include f3-responsive;
83
-
84
83
  font-weight: $font-weight-bold;
85
84
  }
@@ -178,8 +178,9 @@ $sidebar-narrow-width: (
178
178
  ) !default;
179
179
 
180
180
  $sidebar-wide-width: (
181
+ md: 296px,
181
182
  lg: 320px,
182
- xl: 336px
183
+ xl: 344px
183
184
  ) !default;
184
185
 
185
186
  $gutter: (
@@ -14,19 +14,19 @@
14
14
 
15
15
  // Hide utilities for each breakpoint
16
16
  // Each hide utility only applies to one breakpoint range.
17
- @media (max-width: $width-sm - 0.02px) {
17
+ @media (max-width: $width-sm - 1px) {
18
18
  .hide-sm {
19
19
  display: none !important;
20
20
  }
21
21
  }
22
22
 
23
- @media (min-width: $width-sm) and (max-width: $width-md - 0.02px) {
23
+ @media (min-width: $width-sm) and (max-width: $width-md - 1px) {
24
24
  .hide-md {
25
25
  display: none !important;
26
26
  }
27
27
  }
28
28
 
29
- @media (min-width: $width-md) and (max-width: $width-lg - 0.02px) {
29
+ @media (min-width: $width-md) and (max-width: $width-lg - 1px) {
30
30
  .hide-lg {
31
31
  display: none !important;
32
32
  }
@@ -1,92 +0,0 @@
1
- // tree-view variant
2
- // renders ActionList with default styling for tree-view
3
- // collapse/expand icons presents as leadingActions, rotate 90deg
4
- // connecting vertical lines between collapse groups
5
- // consistent font-size between nested groups
6
-
7
- @mixin treeConnectingLine($left) {
8
- position: absolute;
9
- left: $left;
10
- width: 1px;
11
- height: 100%;
12
- content: '';
13
- background: var(--color-action-list-item-inline-divider);
14
- }
15
-
16
- .ActionList--tree {
17
- --ActionList-tree-depth: 1;
18
- // TODO: remove with PVC implementation
19
- .ActionList-item--subItem > .ActionList-content {
20
- font-size: $body-font-size;
21
- }
22
-
23
- .ActionList-item {
24
- // nesting (infinate levels)
25
- // target items inside expanded subgroup
26
- &[aria-expanded] {
27
- .ActionList--subGroup {
28
- position: relative;
29
-
30
- // --ActionList-tree-depth is defined as an inline style referencing the aria-level of each item ie: aria-level="2"
31
- // stylelint-disable-next-line selector-max-specificity, max-nesting-depth, selector-max-compound-selectors
32
- .ActionList-content {
33
- // stylelint-disable-next-line primer/spacing
34
- padding-left: calc(#{$spacer-2} * var(--ActionList-tree-depth));
35
- }
36
- }
37
- }
38
-
39
- // tree-view specific collapse icon positioning/animation
40
- &[aria-expanded='true'] {
41
- .ActionList-item-collapseIcon {
42
- transition: transform 120ms linear;
43
- transform: rotate(0deg);
44
- }
45
- }
46
-
47
- &[aria-expanded='false'] {
48
- .ActionList-item-collapseIcon {
49
- transition: transform 120ms linear;
50
- transform: rotate(-90deg);
51
- }
52
- }
53
- }
54
-
55
- // expand/collapse group
56
- .ActionList-item--hasSubItem {
57
- .ActionList-item--subItem:not(.ActionList-item--hasSubItem) {
58
- // stylelint-disable-next-line selector-max-specificity, selector-max-compound-selectors
59
- .ActionList-content {
60
- // increase child padding by targeting content first child span (add to ActionList-content padding, not replace)
61
- // creates a slight indent of child items
62
- // stylelint-disable-next-line selector-max-specificity, selector-max-type, max-nesting-depth, selector-max-compound-selectors
63
- > span:first-child {
64
- padding-left: $spacer-4;
65
- }
66
- }
67
- }
68
- }
69
-
70
- // first subitem
71
- > [aria-level='1'].ActionList-item--hasSubItem {
72
- > .ActionList--subGroup {
73
- // stylelint-disable-next-line selector-max-specificity
74
- &::before {
75
- @include treeConnectingLine($left: $spacer-3);
76
- }
77
- }
78
- }
79
-
80
- // all other subitems
81
- // center connecting line with parent (line is 1px (8px - 1px)
82
- .ActionList-item--hasSubItem:not([aria-level='1']) {
83
- > .ActionList--subGroup {
84
- // stylelint-disable-next-line selector-max-specificity
85
- &::before {
86
- @include treeConnectingLine(
87
- $left: calc(#{$spacer-2} * (var(--ActionList-tree-depth)) + #{$spacer-2 - $border-width})
88
- );
89
- }
90
- }
91
- }
92
- }