-
-
Notifications
You must be signed in to change notification settings - Fork 931
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor to migrate
unit-disallowed-list
to new media query parser
- Loading branch information
1 parent
165c827
commit 9b6f395
Showing
4 changed files
with
156 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
'use strict'; | ||
|
||
const HAS_DIMENSION_LIKE_VALUES = /\d[%\w-]/; | ||
|
||
/** | ||
* Check if a value contains any dimension-like values. | ||
* | ||
* @param {string} value | ||
* @returns {boolean} | ||
*/ | ||
module.exports = function hasDimension(value) { | ||
return HAS_DIMENSION_LIKE_VALUES.test(value); | ||
}; |