Conversation
Conflicts: package.json yarn.lock
🦋 Changeset detectedLatest commit: 8d50080 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Conflicts: yarn.lock
| line-height: $body-line-height; | ||
| word-wrap: break-word; | ||
|
|
||
| @import "../base/kbd.scss"; // adds support for keyboard shortcuts |
There was a problem hiding this comment.
Is importing a file like that not possible in dart-sass? If so, we might need to just duplicate those styles?
There was a problem hiding this comment.
Hello inspect the styles on me
yes, I meant to say. dart-sass didn't like this. but checking the .markdown-body kbd and the normal kbd that's included in base both apply in dotcom. So I'm unsure if this more specific import is needed?
If it is, we can try putting .markdown-body kbd, kbd {} in the base/kbd.scss file.
koddsson
left a comment
There was a problem hiding this comment.
I'm not super into how compiling primer CSS works but this looks pretty good too me.
What is the difference between the outputs? It might help with confidence in this change if we diff the outputs.
|
This is the selector diff between this branch and the 18 major release. --- before.txt 2021-09-23 08:49:42.000000000 -0700
+++ after.txt 2021-09-23 08:49:42.000000000 -0700
@@ -228,3 +228,3 @@
.Link--muted:hover
-.Link--muted:hover [class*="color-text"]
+.Link--muted:hover [class*=color-text]
.Link--onHover:hover
@@ -232,6 +232,6 @@
.Link--primary:hover
-.Link--primary:hover [class*="color-text"]
+.Link--primary:hover [class*=color-text]
.Link--secondary
.Link--secondary:hover
-.Link--secondary:hover [class*="color-text"]
+.Link--secondary:hover [class*=color-text]
.Link:hover
@@ -306,4 +306,4 @@
.SelectMenu-tab:hover
-.SelectMenu-tab:not([aria-selected="true"]):active
-.SelectMenu-tab[aria-selected="true"]
+.SelectMenu-tab:not([aria-selected=true]):active
+.SelectMenu-tab[aria-selected=true]
.SelectMenu-tabs
@@ -323,4 +323,4 @@
.SideNav-item[aria-current]:not([aria-current=false])::before
-.SideNav-item[aria-selected="true"]
-.SideNav-item[aria-selected="true"]::before
+.SideNav-item[aria-selected=true]
+.SideNav-item[aria-selected=true]::before
.SideNav-subItem
@@ -329,3 +329,3 @@
.SideNav-subItem[aria-current]:not([aria-current=false])
-.SideNav-subItem[aria-selected="true"]
+.SideNav-subItem[aria-selected=true]
.State
@@ -972,3 +972,3 @@
.dropdown-item:focus
-.dropdown-item:focus [class*="color-text-"]
+.dropdown-item:focus [class*=color-text-]
.dropdown-item:focus>.Label
@@ -976,6 +976,6 @@
.dropdown-item:hover
-.dropdown-item:hover [class*="color-text-"]
+.dropdown-item:hover [class*=color-text-]
.dropdown-item:hover>.Label
.dropdown-item:hover>.octicon
-.dropdown-item[aria-checked="false"] .octicon-check
+.dropdown-item[aria-checked=false] .octicon-check
.dropdown-menu
@@ -1259,4 +1259,4 @@
.form-checkbox-details
-.form-checkbox-details-trigger:checked ~ * .form-checkbox-details
-.form-checkbox-details-trigger:checked ~ .form-checkbox-details
+.form-checkbox-details-trigger:checked~* .form-checkbox-details
+.form-checkbox-details-trigger:checked~.form-checkbox-details
.form-control
@@ -1342,30 +1342,30 @@
.gutter-condensed
-.gutter-condensed>[class*="col-"]
+.gutter-condensed>[class*=col-]
.gutter-lg
.gutter-lg-condensed
-.gutter-lg-condensed>[class*="col-"]
+.gutter-lg-condensed>[class*=col-]
.gutter-lg-spacious
-.gutter-lg-spacious>[class*="col-"]
-.gutter-lg>[class*="col-"]
+.gutter-lg-spacious>[class*=col-]
+.gutter-lg>[class*=col-]
.gutter-md
.gutter-md-condensed
-.gutter-md-condensed>[class*="col-"]
+.gutter-md-condensed>[class*=col-]
.gutter-md-spacious
-.gutter-md-spacious>[class*="col-"]
-.gutter-md>[class*="col-"]
+.gutter-md-spacious>[class*=col-]
+.gutter-md>[class*=col-]
.gutter-sm
.gutter-sm-condensed
-.gutter-sm-condensed>[class*="col-"]
+.gutter-sm-condensed>[class*=col-]
.gutter-sm-spacious
-.gutter-sm-spacious>[class*="col-"]
-.gutter-sm>[class*="col-"]
+.gutter-sm-spacious>[class*=col-]
+.gutter-sm>[class*=col-]
.gutter-spacious
-.gutter-spacious>[class*="col-"]
+.gutter-spacious>[class*=col-]
.gutter-xl
.gutter-xl-condensed
-.gutter-xl-condensed>[class*="col-"]
+.gutter-xl-condensed>[class*=col-]
.gutter-xl-spacious
-.gutter-xl-spacious>[class*="col-"]
-.gutter-xl>[class*="col-"]
-.gutter>[class*="col-"]
+.gutter-xl-spacious>[class*=col-]
+.gutter-xl>[class*=col-]
+.gutter>[class*=col-]
.h0-mktg
@@ -1646,3 +1646,2 @@
.markdown-body img[align=right]
-.markdown-body kbd
.markdown-body li+li
@@ -1654,4 +1653,4 @@
.markdown-body ol[type="1"]
-.markdown-body ol[type="a"]
-.markdown-body ol[type="i"]
+.markdown-body ol[type=a]
+.markdown-body ol[type=i]
.markdown-body p
@@ -3074,4 +3073,4 @@
.suggester li:last-child
-.suggester li[aria-selected="true"]
-.suggester li[aria-selected="true"] small
+.suggester li[aria-selected=true]
+.suggester li[aria-selected=true] small
.suggester-container
@@ -3288,38 +3287,38 @@
:root
-[data-color-mode="auto"][data-dark-theme*="dark"]
-[data-color-mode="auto"][data-dark-theme*="dark"] .form-select
-[data-color-mode="auto"][data-dark-theme*="light"]
-[data-color-mode="auto"][data-dark-theme="dark"]
-[data-color-mode="auto"][data-dark-theme="dark_dimmed"]
-[data-color-mode="auto"][data-dark-theme="dark_high_contrast"]
-[data-color-mode="auto"][data-dark-theme="dark_protanopia"]
-[data-color-mode="auto"][data-dark-theme="light"]
-[data-color-mode="auto"][data-dark-theme="light_protanopia"]
-[data-color-mode="auto"][data-light-theme*="dark"]
-[data-color-mode="auto"][data-light-theme*="dark"] .form-select
-[data-color-mode="auto"][data-light-theme*="light"]
-[data-color-mode="auto"][data-light-theme="dark"]
-[data-color-mode="auto"][data-light-theme="dark_dimmed"]
-[data-color-mode="auto"][data-light-theme="dark_high_contrast"]
-[data-color-mode="auto"][data-light-theme="dark_protanopia"]
-[data-color-mode="auto"][data-light-theme="light"]
-[data-color-mode="auto"][data-light-theme="light_protanopia"]
-[data-color-mode="dark"][data-dark-theme*="dark"]
-[data-color-mode="dark"][data-dark-theme*="dark"] .form-select
-[data-color-mode="dark"][data-dark-theme*="light"]
-[data-color-mode="dark"][data-dark-theme="dark"]
-[data-color-mode="dark"][data-dark-theme="dark_dimmed"]
-[data-color-mode="dark"][data-dark-theme="dark_high_contrast"]
-[data-color-mode="dark"][data-dark-theme="dark_protanopia"]
-[data-color-mode="dark"][data-dark-theme="light"]
-[data-color-mode="dark"][data-dark-theme="light_protanopia"]
-[data-color-mode="light"][data-light-theme*="dark"]
-[data-color-mode="light"][data-light-theme*="dark"] .form-select
-[data-color-mode="light"][data-light-theme*="light"]
-[data-color-mode="light"][data-light-theme="dark"]
-[data-color-mode="light"][data-light-theme="dark_dimmed"]
-[data-color-mode="light"][data-light-theme="dark_high_contrast"]
-[data-color-mode="light"][data-light-theme="dark_protanopia"]
-[data-color-mode="light"][data-light-theme="light"]
-[data-color-mode="light"][data-light-theme="light_protanopia"]
+[data-color-mode=auto][data-dark-theme*=dark]
+[data-color-mode=auto][data-dark-theme*=dark] .form-select
+[data-color-mode=auto][data-dark-theme*=light]
+[data-color-mode=auto][data-dark-theme=dark]
+[data-color-mode=auto][data-dark-theme=dark_dimmed]
+[data-color-mode=auto][data-dark-theme=dark_high_contrast]
+[data-color-mode=auto][data-dark-theme=dark_protanopia]
+[data-color-mode=auto][data-dark-theme=light]
+[data-color-mode=auto][data-dark-theme=light_protanopia]
+[data-color-mode=auto][data-light-theme*=dark]
+[data-color-mode=auto][data-light-theme*=dark] .form-select
+[data-color-mode=auto][data-light-theme*=light]
+[data-color-mode=auto][data-light-theme=dark]
+[data-color-mode=auto][data-light-theme=dark_dimmed]
+[data-color-mode=auto][data-light-theme=dark_high_contrast]
+[data-color-mode=auto][data-light-theme=dark_protanopia]
+[data-color-mode=auto][data-light-theme=light]
+[data-color-mode=auto][data-light-theme=light_protanopia]
+[data-color-mode=dark][data-dark-theme*=dark]
+[data-color-mode=dark][data-dark-theme*=dark] .form-select
+[data-color-mode=dark][data-dark-theme*=light]
+[data-color-mode=dark][data-dark-theme=dark]
+[data-color-mode=dark][data-dark-theme=dark_dimmed]
+[data-color-mode=dark][data-dark-theme=dark_high_contrast]
+[data-color-mode=dark][data-dark-theme=dark_protanopia]
+[data-color-mode=dark][data-dark-theme=light]
+[data-color-mode=dark][data-dark-theme=light_protanopia]
+[data-color-mode=light][data-light-theme*=dark]
+[data-color-mode=light][data-light-theme*=dark] .form-select
+[data-color-mode=light][data-light-theme*=light]
+[data-color-mode=light][data-light-theme=dark]
+[data-color-mode=light][data-light-theme=dark_dimmed]
+[data-color-mode=light][data-light-theme=dark_high_contrast]
+[data-color-mode=light][data-light-theme=dark_protanopia]
+[data-color-mode=light][data-light-theme=light]
+[data-color-mode=light][data-light-theme=light_protanopia]
[data-color-mode]
@@ -3340,17 +3339,17 @@
[open]>.btn-transparent
-[type="button"]:-moz-focusring
-[type="button"]::-moz-focus-inner
-[type="checkbox"]
-[type="number"]::-webkit-inner-spin-button
-[type="number"]::-webkit-outer-spin-button
-[type="radio"]
-[type="reset"]
-[type="reset"]:-moz-focusring
-[type="reset"]::-moz-focus-inner
-[type="search"]
-[type="search"]::-webkit-search-cancel-button
-[type="search"]::-webkit-search-decoration
-[type="submit"]
-[type="submit"]:-moz-focusring
-[type="submit"]::-moz-focus-inner
+[type=button]:-moz-focusring
+[type=button]::-moz-focus-inner
+[type=checkbox]
+[type=number]::-webkit-inner-spin-button
+[type=number]::-webkit-outer-spin-button
+[type=radio]
+[type=reset]
+[type=reset]:-moz-focusring
+[type=reset]::-moz-focus-inner
+[type=search]
+[type=search]::-webkit-search-cancel-button
+[type=search]::-webkit-search-decoration
+[type=submit]
+[type=submit]:-moz-focusring
+[type=submit]::-moz-focus-inner
a
@@ -3402,3 +3401,3 @@
html
-html [type="button"]
+html [type=button]
img |
Similar to the work @koddsson did in dotcom, I wanted to update our internal build tools to use
dart-sasssincenode-sassis now end-of-life.I extracted this out into a file
script/primer-css-compiler.jsthat I would like to build into a package we can publish and share across our codebases.Things of note:
[type="button"]quotes in this situation and outputs[type=button]. So we will see a huge diff in the release pr..node-versionfile which was necessary because node-sass wouldn't compile on a version larger than 14./cc @primer/css-reviewers