@primer/css 0.0.0-20220120020705 → 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.
- package/CHANGELOG.md +6 -53
- package/actionlist/action-list-item.scss +54 -120
- package/actionlist/index.scss +0 -1
- package/autocomplete/autocomplete.scss +1 -1
- package/avatars/avatar-stack.scss +0 -1
- package/base/base.scss +0 -1
- package/base/index.scss +1 -0
- package/blankslate/index.scss +1 -0
- package/breadcrumb/breadcrumb.scss +1 -1
- package/buttons/button-group.scss +2 -3
- package/buttons/button.scss +35 -0
- package/buttons/misc.scss +7 -6
- package/color-modes/native.scss +0 -12
- package/color-modes/themes/dark.scss +1 -0
- package/color-modes/themes/dark_colorblind.scss +1 -0
- package/color-modes/themes/dark_dimmed.scss +1 -0
- package/color-modes/themes/dark_high_contrast.scss +1 -0
- package/color-modes/themes/light.scss +1 -0
- package/color-modes/themes/light_colorblind.scss +1 -0
- package/color-modes/themes/light_high_contrast.scss +1 -0
- package/dist/actionlist.css +1 -1
- package/dist/actionlist.css.map +1 -1
- package/dist/alerts.css.map +1 -1
- package/dist/autocomplete.css.map +1 -1
- package/dist/avatars.css +1 -1
- package/dist/avatars.css.map +1 -1
- package/dist/base.css.map +1 -1
- package/dist/blankslate.css.map +1 -1
- package/dist/box.css.map +1 -1
- package/dist/branch-name.css.map +1 -1
- package/dist/breadcrumb.css.map +1 -1
- package/dist/buttons.css +1 -1
- package/dist/buttons.css.map +1 -1
- package/dist/color-modes.css +1 -1
- package/dist/color-modes.css.map +1 -1
- package/dist/core.css +1 -1
- package/dist/core.css.map +1 -1
- package/dist/dropdown.css.map +1 -1
- package/dist/forms.css.map +1 -1
- package/dist/header.css.map +1 -1
- package/dist/labels.css +1 -1
- package/dist/labels.css.map +1 -1
- package/dist/layout.css +1 -1
- package/dist/layout.css.map +1 -1
- package/dist/links.css.map +1 -1
- package/dist/loaders.css.map +1 -1
- package/dist/markdown.css.map +1 -1
- package/dist/marketing-buttons.css +1 -1
- package/dist/marketing-buttons.css.map +1 -1
- package/dist/marketing-type.css.map +1 -1
- package/dist/marketing-utilities.css +1 -1
- package/dist/marketing-utilities.css.map +1 -1
- package/dist/marketing.css +1 -1
- package/dist/marketing.css.map +1 -1
- package/dist/meta.json +84 -95
- package/dist/navigation.css.map +1 -1
- package/dist/pagination.css +1 -1
- package/dist/pagination.css.map +1 -1
- package/dist/popover.css +1 -1
- package/dist/popover.css.map +1 -1
- package/dist/primer.css +4 -4
- package/dist/primer.css.map +1 -1
- package/dist/product.css +1 -1
- package/dist/product.css.map +1 -1
- package/dist/progress.css.map +1 -1
- package/dist/select-menu.css.map +1 -1
- package/dist/stats/actionlist.json +1 -1
- package/dist/stats/avatars.json +1 -1
- package/dist/stats/buttons.json +1 -1
- package/dist/stats/color-modes.json +1 -1
- package/dist/stats/core.json +1 -1
- package/dist/stats/labels.json +1 -1
- package/dist/stats/layout.json +1 -1
- package/dist/stats/marketing-buttons.json +1 -1
- package/dist/stats/marketing-utilities.json +1 -1
- package/dist/stats/marketing.json +1 -1
- package/dist/stats/pagination.json +1 -1
- package/dist/stats/popover.json +1 -1
- package/dist/stats/primer.json +1 -1
- package/dist/stats/product.json +1 -1
- package/dist/stats/utilities.json +1 -1
- package/dist/subhead.css.map +1 -1
- package/dist/timeline.css.map +1 -1
- package/dist/toasts.css.map +1 -1
- package/dist/tooltips.css.map +1 -1
- package/dist/truncate.css.map +1 -1
- package/dist/utilities.css +1 -1
- package/dist/utilities.css.map +1 -1
- package/forms/form-control.scss +0 -2
- package/labels/counters.scss +1 -1
- package/labels/index.scss +1 -0
- package/labels/labels.scss +0 -1
- package/layout/index.scss +1 -1
- package/layout/layout.scss +11 -8
- package/layout/mixins.scss +4 -30
- package/markdown/images.scss +2 -2
- package/marketing/buttons/button.scss +0 -8
- package/marketing/index.scss +0 -1
- package/marketing/type/typography.scss +0 -3
- package/marketing/utilities/animations.scss +0 -42
- package/navigation/filter-list.scss +2 -2
- package/navigation/menu.scss +2 -2
- package/navigation/sidenav.scss +2 -2
- package/navigation/subnav.scss +2 -2
- package/navigation/tabnav.scss +2 -2
- package/navigation/underline-nav.scss +2 -2
- package/package.json +13 -14
- package/pagination/pagination.scss +4 -41
- package/popover/popover.scss +1 -1
- package/select-menu/select-menu.scss +2 -2
- package/stylelint.config.cjs +11 -2
- package/support/mixins/color-modes.scss +0 -3
- package/support/mixins/misc.scss +16 -0
- package/support/mixins/typography.scss +2 -3
- package/support/variables/layout.scss +2 -1
- package/utilities/visibility-display.scss +3 -3
- package/actionlist/action-list-tree.scss +0 -92
- package/dist/marketing-links.css +0 -2
- package/dist/marketing-links.css.map +0 -1
- package/dist/marketing-links.js +0 -1
- package/dist/stats/marketing-links.json +0 -1
- package/layout/page-layout.scss +0 -380
- package/marketing/links/index.scss +0 -3
- package/marketing/links/link.scss +0 -50
package/labels/index.scss
CHANGED
package/labels/labels.scss
CHANGED
package/layout/index.scss
CHANGED
package/layout/layout.scss
CHANGED
|
@@ -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} -
|
|
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} -
|
|
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} -
|
|
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
|
|
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 {
|
|
@@ -47,8 +47,7 @@
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
&.Layout--gutter-none {
|
|
50
|
-
|
|
51
|
-
--Layout-gutter: 0px;
|
|
50
|
+
--Layout-gutter: 0;
|
|
52
51
|
}
|
|
53
52
|
|
|
54
53
|
&.Layout--gutter-condensed {
|
|
@@ -102,7 +101,7 @@
|
|
|
102
101
|
}
|
|
103
102
|
|
|
104
103
|
&.Layout--sidebarPosition-end {
|
|
105
|
-
grid-template-columns:
|
|
104
|
+
grid-template-columns: 1fr 0 auto;
|
|
106
105
|
|
|
107
106
|
.Layout-main {
|
|
108
107
|
grid-column: 1;
|
|
@@ -147,6 +146,7 @@
|
|
|
147
146
|
}
|
|
148
147
|
|
|
149
148
|
.Layout-sidebar {
|
|
149
|
+
// stylelint-disable-next-line primer/no-undefined-vars
|
|
150
150
|
width: var(--Layout-sidebar-width);
|
|
151
151
|
}
|
|
152
152
|
|
|
@@ -169,14 +169,17 @@
|
|
|
169
169
|
}
|
|
170
170
|
|
|
171
171
|
.Layout-main-centered-md {
|
|
172
|
+
// stylelint-disable-next-line primer/no-undefined-vars
|
|
172
173
|
max-width: calc(#{$container-md} + var(--Layout-sidebar-width) + var(--Layout-gutter));
|
|
173
174
|
}
|
|
174
175
|
|
|
175
176
|
.Layout-main-centered-lg {
|
|
177
|
+
// stylelint-disable-next-line primer/no-undefined-vars
|
|
176
178
|
max-width: calc(#{$container-lg} + var(--Layout-sidebar-width) + var(--Layout-gutter));
|
|
177
179
|
}
|
|
178
180
|
|
|
179
181
|
.Layout-main-centered-xl {
|
|
182
|
+
// stylelint-disable-next-line primer/no-undefined-vars
|
|
180
183
|
max-width: calc(#{$container-xl} + var(--Layout-sidebar-width) + var(--Layout-gutter));
|
|
181
184
|
}
|
|
182
185
|
}
|
package/layout/mixins.scss
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Layout
|
|
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
|
-
|
|
11
|
-
|
|
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
|
-
}
|
package/markdown/images.scss
CHANGED
|
@@ -10,12 +10,12 @@
|
|
|
10
10
|
box-sizing: content-box;
|
|
11
11
|
background-color: var(--color-canvas-default);
|
|
12
12
|
|
|
13
|
-
&[align=
|
|
13
|
+
&[align=right] {
|
|
14
14
|
// stylelint-disable-next-line primer/spacing
|
|
15
15
|
padding-left: 20px;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
&[align=
|
|
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 {
|
package/marketing/index.scss
CHANGED
|
@@ -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=
|
|
45
|
-
&[aria-current]:not([aria-current=
|
|
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
|
}
|
package/navigation/menu.scss
CHANGED
package/navigation/sidenav.scss
CHANGED
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
background-color: var(--color-canvas-subtle);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
.SideNav-item[aria-current]:not([aria-current=
|
|
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=
|
|
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);
|
package/navigation/subnav.scss
CHANGED
|
@@ -40,8 +40,8 @@
|
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
&.selected,
|
|
43
|
-
&[aria-selected=
|
|
44
|
-
&[aria-current]:not([aria-current=
|
|
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);
|
package/navigation/tabnav.scss
CHANGED
|
@@ -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=
|
|
32
|
-
&[aria-current]:not([aria-current=
|
|
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=
|
|
39
|
-
&[aria-current]:not([aria-current=
|
|
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-
|
|
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.",
|
|
@@ -24,7 +24,6 @@
|
|
|
24
24
|
],
|
|
25
25
|
"scripts": {
|
|
26
26
|
"dist": "script/dist.js",
|
|
27
|
-
"dist:watch": "chokidar \"src/**/*.scss\" -c \"script/dist.js\"",
|
|
28
27
|
"stylelint": "stylelint --quiet 'src/**/*.scss'",
|
|
29
28
|
"eslint": "eslint deprecations.js __tests__ script",
|
|
30
29
|
"prepublishOnly": "script/prepublish",
|
|
@@ -36,37 +35,37 @@
|
|
|
36
35
|
"storybook": "cd docs && yarn && yarn storybook"
|
|
37
36
|
},
|
|
38
37
|
"dependencies": {
|
|
39
|
-
"@primer/primitives": "^7.
|
|
38
|
+
"@primer/primitives": "^7.2.0"
|
|
40
39
|
},
|
|
41
40
|
"devDependencies": {
|
|
42
41
|
"@changesets/changelog-github": "0.4.2",
|
|
43
|
-
"@changesets/cli": "2.
|
|
42
|
+
"@changesets/cli": "2.18.1",
|
|
44
43
|
"@github/prettier-config": "0.0.4",
|
|
45
44
|
"@koddsson/postcss-sass": "5.0.0",
|
|
46
|
-
"@primer/stylelint-config": "12.
|
|
47
|
-
"autoprefixer": "10.4.
|
|
48
|
-
"chokidar-cli": "3.0.0",
|
|
45
|
+
"@primer/stylelint-config": "12.1.1",
|
|
46
|
+
"autoprefixer": "10.4.0",
|
|
49
47
|
"cssstats": "4.0.2",
|
|
50
|
-
"eslint": "8.
|
|
48
|
+
"eslint": "8.3.0",
|
|
51
49
|
"eslint-plugin-github": "4.3.5",
|
|
52
|
-
"eslint-plugin-jest": "25.3.
|
|
50
|
+
"eslint-plugin-jest": "25.3.0",
|
|
53
51
|
"eslint-plugin-prettier": "4.0.0",
|
|
54
52
|
"filesize": "8.0.6",
|
|
55
53
|
"front-matter": "4.0.2",
|
|
56
54
|
"fs-extra": "10.0.0",
|
|
57
55
|
"globby": "12.0.2",
|
|
58
|
-
"jest": "27.4.
|
|
56
|
+
"jest": "27.4.2",
|
|
59
57
|
"js-yaml": "4.1.0",
|
|
60
|
-
"postcss": "8.4.
|
|
58
|
+
"postcss": "8.4.4",
|
|
61
59
|
"postcss-calc": "8.0.0",
|
|
62
60
|
"postcss-import": "14.0.2",
|
|
63
61
|
"postcss-load-config": "3.1.0",
|
|
64
62
|
"postcss-scss": "4.0.2",
|
|
65
63
|
"postcss-simple-vars": "6.0.3",
|
|
66
|
-
"prettier": "2.5.
|
|
64
|
+
"prettier": "2.5.0",
|
|
67
65
|
"semver": "7.3.5",
|
|
68
|
-
"stylelint": "14.
|
|
69
|
-
"
|
|
66
|
+
"stylelint": "14.1.0",
|
|
67
|
+
"stylelint-scss": "4.0.0",
|
|
68
|
+
"table": "6.7.3"
|
|
70
69
|
},
|
|
71
70
|
"jest": {
|
|
72
71
|
"testEnvironment": "node",
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
a,
|
|
5
5
|
span,
|
|
6
6
|
em {
|
|
7
|
+
display: inline-block;
|
|
7
8
|
min-width: 32px;
|
|
8
9
|
// stylelint-disable-next-line primer/spacing
|
|
9
10
|
padding: 5px 10px;
|
|
@@ -41,7 +42,7 @@
|
|
|
41
42
|
|
|
42
43
|
.current,
|
|
43
44
|
.current:hover,
|
|
44
|
-
[aria-current]:not([aria-current=
|
|
45
|
+
[aria-current]:not([aria-current=false]) {
|
|
45
46
|
color: var(--color-fg-on-emphasis);
|
|
46
47
|
background-color: var(--color-accent-emphasis);
|
|
47
48
|
border-color: transparent;
|
|
@@ -49,10 +50,10 @@
|
|
|
49
50
|
|
|
50
51
|
.gap,
|
|
51
52
|
.disabled,
|
|
52
|
-
[aria-disabled=
|
|
53
|
+
[aria-disabled=true],
|
|
53
54
|
.gap:hover,
|
|
54
55
|
.disabled:hover,
|
|
55
|
-
[aria-disabled=
|
|
56
|
+
[aria-disabled=true]:hover {
|
|
56
57
|
color: var(--color-primer-fg-disabled);
|
|
57
58
|
cursor: default;
|
|
58
59
|
border-color: transparent;
|
|
@@ -83,44 +84,6 @@
|
|
|
83
84
|
clip-path: polygon(6.2px 3.2px, 7.3px 3.2px, 11.5px 7.5px, 11.5px 8.5px, 7.3px 12.8px, 6.2px 11.7px, 9.9px 8px, 6.2px 4.3px, 6.2px 3.2px);
|
|
84
85
|
}
|
|
85
86
|
}
|
|
86
|
-
|
|
87
|
-
// Responsive
|
|
88
|
-
|
|
89
|
-
// Hide everything by default
|
|
90
|
-
> * {
|
|
91
|
-
display: none;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
// 0 -> sm
|
|
95
|
-
// Only show [Previous] [Next]
|
|
96
|
-
|
|
97
|
-
> :first-child,
|
|
98
|
-
> :last-child,
|
|
99
|
-
> .previous_page,
|
|
100
|
-
> .next_page {
|
|
101
|
-
display: inline-block;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
// sm -> md
|
|
105
|
-
// Also show [first] [last] [current number] and [...]
|
|
106
|
-
|
|
107
|
-
@include breakpoint(sm) {
|
|
108
|
-
> :nth-child(2),
|
|
109
|
-
> :nth-last-child(2),
|
|
110
|
-
> .current,
|
|
111
|
-
> .gap {
|
|
112
|
-
display: inline-block;
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
// md -> or more
|
|
117
|
-
// Show everything
|
|
118
|
-
|
|
119
|
-
@include breakpoint(md) {
|
|
120
|
-
> * {
|
|
121
|
-
display: inline-block;
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
87
|
}
|
|
125
88
|
|
|
126
89
|
// Unified centered pagination across the site
|
package/popover/popover.scss
CHANGED
|
@@ -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=
|
|
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=
|
|
405
|
+
.SelectMenu-item[aria-disabled=true] {
|
|
406
406
|
color: var(--color-primer-fg-disabled);
|
|
407
407
|
pointer-events: none;
|
|
408
408
|
}
|
package/stylelint.config.cjs
CHANGED
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
module.exports = {
|
|
2
2
|
extends: ['@primer/stylelint-config'],
|
|
3
|
-
|
|
3
|
+
plugins: ['stylelint-scss'],
|
|
4
|
+
customSyntax: require('postcss-scss'),
|
|
5
|
+
ignoreFiles: ['src/fonts/**/*'],
|
|
4
6
|
rules: {
|
|
5
|
-
'
|
|
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
|
}
|
package/support/mixins/misc.scss
CHANGED
|
@@ -24,3 +24,19 @@
|
|
|
24
24
|
background-color: $border;
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
|
+
|
|
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%);
|
|
38
|
+
|
|
39
|
+
@if $min-width != '' {
|
|
40
|
+
min-width: $min-width;
|
|
41
|
+
}
|
|
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
|
}
|
|
@@ -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 -
|
|
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 -
|
|
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 -
|
|
29
|
+
@media (min-width: $width-md) and (max-width: $width-lg - 1px) {
|
|
30
30
|
.hide-lg {
|
|
31
31
|
display: none !important;
|
|
32
32
|
}
|