Skip to content

Commit 565372e

Browse files
committed
update primer-support to v4.0.0
1 parent f119162 commit 565372e

File tree

7 files changed

+46
-27
lines changed

7 files changed

+46
-27
lines changed

packages/primer-support/lib/mixins/buttons.scss

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
box-shadow: none;
7171
}
7272

73-
.counter {
73+
.Counter {
7474
color: darken($bg, 8%);
7575
background-color: $white;
7676
}
@@ -93,7 +93,7 @@
9393
background-image: linear-gradient(-180deg, lighten($color, 10%) 0%, $color 90%);
9494
border-color: $black-fade-50;
9595

96-
.counter {
96+
.Counter {
9797
color: $text-white;
9898
}
9999
}
@@ -123,7 +123,7 @@
123123
background-color: $bg-color;
124124
background-image: none;
125125

126-
.counter {
126+
.Counter {
127127
background-color: rgba(0, 0, 0, 0.07);
128128
}
129129

@@ -135,7 +135,7 @@
135135
background-image: none;
136136
border-color: $text-color;
137137

138-
.counter {
138+
.Counter {
139139
color: $text-color;
140140
background-color: $bg-color;
141141
}

packages/primer-support/lib/mixins/typography.scss

Lines changed: 26 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -40,37 +40,45 @@
4040
}
4141

4242
// Responsive heading mixins
43-
// There are no responsive mixins for h5 and h6 because they are small
43+
// There are no responsive mixins for h4—h6 because they are small
4444
// and don't need to be smaller on mobile.
45-
@mixin h1-reponsive {
46-
font-size: 26px;
47-
font-weight: $font-weight-bold;
45+
@mixin f1-responsive {
46+
font-size: $h1-size-mobile;
4847

49-
// Up to 32px in future
50-
@include breakpoint(md) { font-size: 30px; }
48+
// 32px on desktop
49+
@include breakpoint(md) { font-size: $h1-size; }
5150

5251
}
5352

54-
@mixin h2-responsive {
55-
font-size: 20px;
56-
font-weight: $font-weight-bold;
53+
@mixin f2-responsive {
54+
font-size: $h2-size-mobile;
5755

58-
// Up to 22px or 24px in future
59-
@include breakpoint(md) { font-size: 21px; }
56+
// 24px on desktop
57+
@include breakpoint(md) { font-size: $h2-size; }
6058
}
6159

62-
@mixin h3-responsive {
63-
font-size: 14px;
64-
font-weight: $font-weight-bold;
60+
@mixin f3-responsive {
61+
font-size: $h3-size-mobile;
6562

66-
@include breakpoint(md) { font-size: 16px; }
63+
// 20px on desktop
64+
@include breakpoint(md) { font-size: $h3-size; }
6765

6866
}
6967

70-
@mixin h4-responsive {
71-
font-size: 13px;
68+
// These use the mixins from above for responsive heading sizes.
69+
// The following mixins can be used where it's convenient or necessary to
70+
// couple the responsive font-size with the font-weight.
71+
@mixin h1-responsive {
72+
@include f1-responsive;
7273
font-weight: $font-weight-bold;
74+
}
7375

74-
@include breakpoint(md) { font-size: 14px; }
76+
@mixin h2-responsive {
77+
@include f2-responsive;
78+
font-weight: $font-weight-bold;
79+
}
7580

81+
@mixin h3-responsive {
82+
@include f3-responsive;
83+
font-weight: $font-weight-bold;
7684
}

packages/primer-support/lib/variables/colors.scss

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
// stylelint-disable declaration-bang-space-before
44

55
// State indicators.
6-
$status-renamed: $yellow-500 !default;
76
$status-pending: desaturate($yellow-700, 15%) !default;
87

98
// Repository type colors
@@ -24,9 +23,13 @@ $border-blue-light: $blue-200 !default;
2423
$border-green: $green-400 !default;
2524
$border-green-light: desaturate($green-300, 40%) !default;
2625

26+
$border-purple: $purple !default;
27+
2728
$border-red: $red !default;
2829
$border-red-light: desaturate($red-300, 60%) !default;
2930

31+
$border-purple: $purple !default;
32+
3033
$border-yellow: desaturate($yellow-300, 60%) !default;
3134

3235
$border-gray-dark: $gray-300 !default;

packages/primer-support/lib/variables/layout.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// 0 => 0px
77
// 1 => 4px
88
// 2 => 8px
9-
// 3 => 12px
9+
// 3 => 16px
1010
// 4 => 24px
1111
// 5 => 32px
1212
// 6 => 40px

packages/primer-support/lib/variables/misc.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ $exploregrid-item-border-radius: 4px;
1515
$box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1) !default;
1616
$box-shadow-medium: 0 1px 5px rgba(0, 0, 0, 0.15) !default;
1717
$box-shadow-large: 0 1px 15px rgba(0, 0, 0, 0.15) !default;
18-
$box-shadow-extra-large: 0 10px 50px rgba(0, 0, 0, 0.05) !default;
18+
$box-shadow-extra-large: 0 10px 50px rgba(0, 0, 0, 0.07) !default;
1919

2020
// Tooltips
2121
$tooltip-max-width: 250px !default;

packages/primer-support/lib/variables/typography.scss

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
// Typography variables
22
// stylelint-disable declaration-bang-space-before
33

4-
// Heading sizes
4+
// Heading sizes - mobile
5+
// h4—h6 remain the same size on both mobile & desktop
6+
$h00-size-mobile: 40px !default;
7+
$h0-size-mobile: 32px !default;
8+
$h1-size-mobile: 26px !default;
9+
$h2-size-mobile: 22px !default;
10+
$h3-size-mobile: 18px !default;
11+
12+
// Heading sizes - desktop
513
$h00-size: 48px !default;
614
$h0-size: 40px !default;
715
$h1-size: 32px !default;

packages/primer-support/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "3.0.2",
2+
"version": "4.0.0",
33
"name": "primer-support",
44
"description": "Sass variables, mixins, and functions for use in our components.",
55
"homepage": "http://primercss.io/",

0 commit comments

Comments
 (0)