Skip to content

Commit

Permalink
Merge pull request #9 from factorial-io/hotfix/fix-resolution-non-glo…
Browse files Browse the repository at this point in the history
…bal-argument

hotfix/fix resolution non global argument
  • Loading branch information
dnnsjrng committed Sep 21, 2022
2 parents 6d38014 + 6c74fb5 commit 7302e88
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ module.exports = class Breakpoints {
return "1x";
}
const largestResolution = [...option.multipliers].sort().pop();
const regex = new RegExp(REGEXP.resolution);
const regex = new RegExp(REGEXP.resolution, "g");
const resolution = [...largestResolution.matchAll(regex)][0];
if (!resolution) {
return "";
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@factorial/drupal-breakpoints-css",
"description": "Drupal breakpoints to css customProperties",
"version": "0.1.0",
"version": "0.1.2",
"main": "index.js",
"license": "MIT",
"private": false,
Expand Down

0 comments on commit 7302e88

Please sign in to comment.