mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-02 16:29:47 +02:00
chore: add baseline stylelint rules (#6372)
* chore: add baseline stylelint rules Use the Prettier config so not to conflict with rules. Add the Stylelint baseline recommended rules to catch additional lissues * enable those two rules * ooops * refactor scripts * revert script changes Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
This commit is contained in:
parent
2a1cdc3b8a
commit
284c6166e7
15 changed files with 70 additions and 43 deletions
|
@ -46,7 +46,7 @@ html[data-theme='light'] {
|
|||
background-color: var(--ifm-background-color);
|
||||
color: var(--ifm-color-gray-800);
|
||||
padding: 5px 15px;
|
||||
font: 400 13px Arial;
|
||||
font: 400 13px Arial, sans-serif;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
|
|
|
@ -52,6 +52,10 @@
|
|||
border: none;
|
||||
}
|
||||
|
||||
.showcaseCardSrcBtn:focus-visible {
|
||||
background-color: var(--ifm-color-secondary-dark);
|
||||
}
|
||||
|
||||
html[data-theme='dark'] .showcaseCardSrcBtn {
|
||||
background-color: var(--ifm-color-emphasis-200) !important;
|
||||
color: inherit;
|
||||
|
@ -61,10 +65,6 @@ html[data-theme='dark'] .showcaseCardSrcBtn:hover {
|
|||
background-color: var(--ifm-color-emphasis-300) !important;
|
||||
}
|
||||
|
||||
.showcaseCardSrcBtn:focus-visible {
|
||||
background-color: var(--ifm-color-secondary-dark);
|
||||
}
|
||||
|
||||
.showcaseCardBody {
|
||||
font-size: smaller;
|
||||
line-height: 1.66;
|
||||
|
|
|
@ -29,16 +29,6 @@
|
|||
0px 0px 2px 1px var(--ifm-color-primary-dark);
|
||||
}
|
||||
|
||||
input:focus-visible ~ .checkboxLabel::after {
|
||||
outline: 2px solid currentColor;
|
||||
}
|
||||
|
||||
.checkboxLabel > * {
|
||||
font-size: 0.8rem;
|
||||
color: inherit;
|
||||
transition: opacity 150ms ease-in 50ms;
|
||||
}
|
||||
|
||||
.checkboxLabel::after {
|
||||
position: absolute;
|
||||
content: '';
|
||||
|
@ -52,6 +42,16 @@ input:focus-visible ~ .checkboxLabel::after {
|
|||
transform: translateX(calc(var(--width) / 2 - var(--border)));
|
||||
}
|
||||
|
||||
input:focus-visible ~ .checkboxLabel::after {
|
||||
outline: 2px solid currentColor;
|
||||
}
|
||||
|
||||
.checkboxLabel > * {
|
||||
font-size: 0.8rem;
|
||||
color: inherit;
|
||||
transition: opacity 150ms ease-in 50ms;
|
||||
}
|
||||
|
||||
input:checked ~ .checkboxLabel::after {
|
||||
transform: translateX(calc(-1 * var(--border)));
|
||||
}
|
||||
|
|
|
@ -5,6 +5,11 @@
|
|||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
.checkboxLabel:hover {
|
||||
opacity: 1;
|
||||
box-shadow: 0px 0px 2px 1px var(--ifm-color-secondary-darkest);
|
||||
}
|
||||
|
||||
input[type='checkbox'] + .checkboxLabel {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
@ -17,11 +22,6 @@ input[type='checkbox'] + .checkboxLabel {
|
|||
border: 2px solid var(--ifm-color-secondary-darkest);
|
||||
}
|
||||
|
||||
.checkboxLabel:hover {
|
||||
opacity: 1;
|
||||
box-shadow: 0px 0px 2px 1px var(--ifm-color-secondary-darkest);
|
||||
}
|
||||
|
||||
input:focus-visible + .checkboxLabel {
|
||||
outline: 2px solid currentColor;
|
||||
}
|
||||
|
|
|
@ -41,9 +41,6 @@
|
|||
white-space: nowrap;
|
||||
height: 32px;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.checkboxListItem {
|
||||
margin-top: 0.5rem;
|
||||
margin-right: 0.5rem;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue