Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

5680 Sass linter #5699

Closed
wants to merge 23 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .prettierrc

This file was deleted.

40 changes: 40 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"extends": ["stylelint-config-standard-scss", "stylelint-config-css-modules"],
"plugins": ["stylelint-scss"],
"rules": {
"at-rule-empty-line-before": null,
"color-named": "never",
"declaration-block-no-redundant-longhand-properties": null,
"declaration-colon-space-after": "always",
"font-family-no-missing-generic-family-keyword": null,
"no-descending-specificity": null,
"no-duplicate-selectors": null,
"no-eol-whitespace": true,
"property-no-vendor-prefix": null,
"rule-empty-line-before": null,
"scss/at-extend-no-missing-placeholder": null,
"scss/comment-no-empty": null,
"scss/dollar-variable-pattern": null,
"scss/double-slash-comment-empty-line-before": null,
"scss/double-slash-comment-whitespace-inside": null,
"scss/function-no-unknown": null,
"scss/no-global-function-names": null,
"selector-class-pattern": null
},
"TODO: remove these overrides as we move toward industry standards": [
"at-rule-empty-line-before",
"declaration-block-no-redundant-longhand-properties",
"declaration-colon-space-after",
"font-family-no-missing-generic-family-keyword",
"no-descending-specificity",
"no-duplicate-selectors",
"rule-empty-line-before",
"scss/at-extend-no-missing-placeholder",
"scss/comment-no-empty",
"scss/dollar-variable-pattern",
"scss/double-slash-comment-whitespace-inside",
"scss/function-no-unknown",
"scss/no-global-function-names",
"selector-class-pattern"
]
}
3 changes: 3 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"recommendations": ["stylelint.vscode-stylelint"]
}
2 changes: 1 addition & 1 deletion fec/data/templates/partials/warnings.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</div>
</noscript>

<div id="ie_warning" style="display: none;">
<div id="ie-warning" style="display: none;">
<h2>Your web browser is not supported</h2>
<p>You&apos;re using Internet Explorer, some features might not work. Please switch to another browser like Chrome, Firefox, or Edge for a better experience.</p>
</div>
14 changes: 10 additions & 4 deletions fec/fec/static/scss/components/_accordions.scss
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,11 @@

.accordion__button {
@include u-icon-bg($plus-circle, $primary);

background-size: u(2rem);
background-position: 95% 50%;
border-bottom: 1px solid $base;
margin: 0 0 -1px 0;
margin: 0 0 -1px;
color: $base;
font-size: u(1.4rem);
font-weight: bold;
Expand All @@ -43,15 +44,17 @@

&[aria-expanded='true'] {
@include u-icon-bg($minus-circle, $primary);

border-bottom: none;
}

&.email__button {
padding: u(1rem 4rem 1rem 1rem);
&::before {
content:'';
content: '';
@extend .button--envelope;
padding: u(1rem 0rem 1rem 0);

padding: u(1rem 0 1rem 0);
}
}

Expand All @@ -64,7 +67,8 @@
}

.accordion__content {
@include clearfix();
@include clearfix;

border-bottom: 1px solid $base;
padding: u(2rem);
font-family: $sans-serif;
Expand Down Expand Up @@ -112,6 +116,7 @@
.accordion--inverse {
.accordion__button {
@include u-icon-bg($plus-circle, $inverse);

background-position: 100% 50%;
border-color: $inverse;
color: $inverse;
Expand All @@ -123,6 +128,7 @@

.accordion__content {
@include u-font-color($inverse);

border-color: $inverse;
}
}
7 changes: 5 additions & 2 deletions fec/fec/static/scss/components/_agendas.scss
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@

&::before {
@include heading(h3);

position: absolute;
left: 0;
top: 0;
Expand All @@ -46,6 +47,7 @@

&::before {
@include u-icon($document, $base, 3rem, 3rem, 50%);

background-position: 0 50%;
content: '';
display: inline-block;
Expand Down Expand Up @@ -84,6 +86,7 @@

&::before {
@include u-icon($document, $base, 3rem, 3rem, 50%);

background-position: 0 50%;
content: '';
display: inline-block;
Expand All @@ -106,8 +109,8 @@
left: 0;
right: 0;
bottom: 0;
width:100%;
height:100%;
width: 100%;
height: 100%;
}
}

Expand Down
14 changes: 8 additions & 6 deletions fec/fec/static/scss/components/_articles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@
}

.block-paragraph + .block-table {
margin-top: u(-4rem);
}
margin-top: u(-4rem);
}

}
.block-table {
table {
@extend .simple-table-cms;
}
.block-table {
table {
@extend .simple-table-cms;
}
}



Expand Down Expand Up @@ -80,6 +80,7 @@

.icon--email--author {
@extend .icon--inline--right;

margin-left: u(.5rem);
max-width: 20px;

Expand Down Expand Up @@ -109,6 +110,7 @@

.read_next__image__container {
@include span-columns(3);

display: block;
}
}
3 changes: 2 additions & 1 deletion fec/fec/static/scss/components/_breadcrumbs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
}

.breadcrumbs__item {
@include u-truncate();
@include u-truncate;

float: left;
max-width: u(20rem);
padding: u(.8rem 0);
Expand Down
6 changes: 3 additions & 3 deletions fec/fec/static/scss/components/_breakdowns.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@

}
.bar-container {
margin-left: 0;
background: $gray-lightest;
}
margin-left: 0;
background: $gray-lightest;
}
Loading