Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
codecalm committed Apr 11, 2022
2 parents fcaf6b3 + e97b378 commit 94e0fc6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 8 additions & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ if (fs.existsSync('./compile-options.json')) {
}
})
}

if (typeof tempOptions.excludeIcons !== "undefined") {
if (!Array.isArray(tempOptions.excludeIcons)) {
throw "property excludeIcons is not an array"
Expand All @@ -64,6 +64,13 @@ if (fs.existsSync('./compile-options.json')) {
})
}

if (typeof tempOptions.excludeOffIcons !== "undefined" && tempOptions.excludeOffIcons) {
// Exclude `*-off` icons
compileOptions.includeIcons = compileOptions.includeIcons.filter(function (icon) {
return !icon.endsWith('-off');
})
}

if (typeof tempOptions.strokeWidth !== "undefined") {
if (typeof tempOptions.strokeWidth !== "string" && typeof tempOptions.strokeWidth !== "number") {
throw "property strokeWidth is not a string or number"
Expand Down
2 changes: 1 addition & 1 deletion src/tags.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{ {% for icon in site.icons %}
{% assign slug-tags = icon.slug | split: '-' %}{% assign tags = slug-tags | concat: icon.tags %} "{{ icon.slug }}": {
"category": "{{ icon.category }}",
"tags": [{% for tag in tags %}"{{ tag }}"{% unless forloop.last %}, {% endunless %}{% endfor %}],
"tags": ["{{ tags | join: '", "' }}"],
"version": "{{ icon.version }}"
}{% unless forloop.last %}, {% endunless %}{% endfor %}
}

0 comments on commit 94e0fc6

Please sign in to comment.