Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Allow non-lowercase values in font, font-family, Sass variables starting with polaris, Sass/CSS variables containing font #49

Merged
merged 7 commits into from
Apr 3, 2019
Merged
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: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Changelog

<!-- ## [Unreleased] -->
## [Unreleased]

- Allow non-lowercase values in properties such as `font`, `font-family`, `--anything-with-font-in-its-name`, or Sass variables starting with `$polaris` or containing `font` ([#49](https://github.com/Shopify/stylelint-config-shopify/pull/49))

## [7.1.0] - 2019-01-07

Expand Down
13 changes: 12 additions & 1 deletion rules/value.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
module.exports = {
// Specify lowercase or uppercase for keywords values.
'value-keyword-case': 'lower',
'value-keyword-case': [
'lower',
{
ignoreProperties: [
'font',
'font-family',
/^--.*font/,
/^\$.*font/,
/^\$polaris/,
],
},
],
// Require a newline or disallow whitespace after the commas of value lists.
'value-list-comma-newline-after': 'always-multi-line',
// Require a newline or disallow whitespace before the commas of value lists.
Expand Down