aboutsummaryrefslogtreecommitdiff
path: root/gulpfile.js
diff options
context:
space:
mode:
authorcodecalm <codecalm@gmail.com>2020-03-05 23:50:49 +0100
committercodecalm <codecalm@gmail.com>2020-03-05 23:50:49 +0100
commit6dd9d1d166d56df73545fe1aeea6d29795608320 (patch)
tree92629a0150083f0b74e98d7cec4669088fd7a742 /gulpfile.js
parentnews, refresh, sticker, archive, stroke icons (diff)
downloadtabler-icons-6dd9d1d166d56df73545fe1aeea6d29795608320.tar.xz
icons readme fixes
Diffstat (limited to 'gulpfile.js')
-rw-r--r--gulpfile.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/gulpfile.js b/gulpfile.js
index a60efe6..3294b79 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -8,7 +8,7 @@ const gulp = require('gulp'),
gulp.task('icons-sprite', function (cb) {
const columnsCount = 16,
padding = 30,
- paddingOuter = 24,
+ paddingOuter = 0,
iconSize = 24;
glob("_site/icons/*.svg", {}, function (er, files) {
@@ -44,7 +44,7 @@ gulp.task('icons-sprite', function (cb) {
}
});
- const svgContent = `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 ${width} ${height}" width="${width}" height="${height}" style="color: #354052"><rect x="0" y="0" width="${width}" height="${height}" fill="#fafbfc"></rect>\n${svgContentSymbols}\n${svgContentIcons}\n</svg>`;
+ const svgContent = `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 ${width} ${height}" width="${width}" height="${height}" style="color: #354052"><rect x="0" y="0" width="${width}" height="${height}" fill="#fff"></rect>\n${svgContentSymbols}\n${svgContentIcons}\n</svg>`;
fs.writeFileSync('icons.svg', svgContent);
cb();
@@ -57,7 +57,7 @@ gulp.task('icons-stroke', function (cb) {
strokes = ['.5', '1', '1.5', '2', '2.75'],
svgFileContent = fs.readFileSync(`_site/icons/tabler-${icon}.svg`).toString(),
padding = 32,
- paddingOuter = 32,
+ paddingOuter = 0,
iconSize = 128,
width = (strokes.length * (iconSize + padding) - padding) + paddingOuter * 2,
height = iconSize + paddingOuter * 2;
@@ -84,7 +84,7 @@ gulp.task('icons-stroke', function (cb) {
x += padding + iconSize;
});
- const svgContent = `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 ${width} ${height}" width="${width}" height="${height}" style="color: #354052"><rect x="0" y="0" width="${width}" height="${height}" fill="#fafbfc"></rect>\n${svgContentSymbols}\n${svgContentIcons}\n</svg>`;
+ const svgContent = `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 ${width} ${height}" width="${width}" height="${height}" style="color: #354052"><rect x="0" y="0" width="${width}" height="${height}" fill="#fff"></rect>\n${svgContentSymbols}\n${svgContentIcons}\n</svg>`;
fs.writeFileSync('icons-stroke.svg', svgContent);