mirror of
https://github.com/tabler/tabler-icons.git
synced 2025-08-11 08:34:10 +02:00
Merge branches 'dev' and 'master' of https://github.com/tabler/tabler-icons into dev
Conflicts: .github/icons.png package.json
This commit is contained in:
@@ -91,6 +91,7 @@ gulp.task('icons-sprite', function (cb) {
|
|||||||
let svg = `<svg xmlns="http://www.w3.org/2000/svg"><defs>${svgContent}</defs></svg>`;
|
let svg = `<svg xmlns="http://www.w3.org/2000/svg"><defs>${svgContent}</defs></svg>`;
|
||||||
|
|
||||||
fs.writeFileSync('tabler-sprite.svg', svg);
|
fs.writeFileSync('tabler-sprite.svg', svg);
|
||||||
|
fs.writeFileSync('tabler-sprite-nostroke.svg', svg.replace(/stroke-width="2"\s/g, ''));
|
||||||
cb();
|
cb();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -189,7 +190,7 @@ gulp.task('optimize', function (cb) {
|
|||||||
.replace(/><\/(polyline|line|rect|circle|path)>/g, '/>')
|
.replace(/><\/(polyline|line|rect|circle|path)>/g, '/>')
|
||||||
.replace(/rx="([^"]+)"\s+ry="\1"/g, 'rx="$1"')
|
.replace(/rx="([^"]+)"\s+ry="\1"/g, 'rx="$1"')
|
||||||
.replace(/\s?\/>/g, ' />')
|
.replace(/\s?\/>/g, ' />')
|
||||||
.replace(/\n\s*<(line|circle|path|polyline)/g, "\n <$1")
|
.replace(/\n\s*<(line|circle|path|polyline|rect)/g, "\n <$1")
|
||||||
.replace(/polyline points="([0-9.]+)\s([0-9.]+)\s([0-9.]+)\s([0-9.]+)"/g, 'line x1="$1" y1="$2" x2="$3" y2="$4"')
|
.replace(/polyline points="([0-9.]+)\s([0-9.]+)\s([0-9.]+)\s([0-9.]+)"/g, 'line x1="$1" y1="$2" x2="$3" y2="$4"')
|
||||||
.replace(/a\s?([0-9.]+)\s([0-9.]+)\s([0-9.]+)\s?([0-1])\s?([0-1])\s?(-?[0-9.]+)\s?(-?[0-9.]+)/g, 'a$1 $2 $3 $4 $5 $6 $7')
|
.replace(/a\s?([0-9.]+)\s([0-9.]+)\s([0-9.]+)\s?([0-1])\s?([0-1])\s?(-?[0-9.]+)\s?(-?[0-9.]+)/g, 'a$1 $2 $3 $4 $5 $6 $7')
|
||||||
.replace(/\n\n+/g, "\n");
|
.replace(/\n\n+/g, "\n");
|
||||||
@@ -334,7 +335,7 @@ gulp.task('changelog-diff', function(cb) {
|
|||||||
gulp.task('build-zip', function() {
|
gulp.task('build-zip', function() {
|
||||||
const version = p.version;
|
const version = p.version;
|
||||||
|
|
||||||
return gulp.src('{icons/**/*,icons-png/**/*,tabler-sprite.svg}')
|
return gulp.src('{icons/**/*,icons-png/**/*,tabler-sprite.svg,tabler-sprite-nostroke.svg}')
|
||||||
.pipe(zip(`tabler-icons-${version}.zip`))
|
.pipe(zip(`tabler-icons-${version}.zip`))
|
||||||
.pipe(gulp.dest('packages'))
|
.pipe(gulp.dest('packages'))
|
||||||
});
|
});
|
||||||
@@ -371,4 +372,4 @@ gulp.task('svg-to-png', gulp.series('build-jekyll', 'clean-png', async (cb) => {
|
|||||||
cb();
|
cb();
|
||||||
}));
|
}));
|
||||||
|
|
||||||
gulp.task('build', gulp.series('build-jekyll', 'build-copy', 'build-zip'));
|
gulp.task('build', gulp.series('optimize', 'build-jekyll', 'build-copy', 'icons-sprite', 'icons-preview', 'build-zip'));
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "tabler-icons",
|
"name": "tabler-icons",
|
||||||
"version": "1.0.0",
|
"version": "1.0.2",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://github.com/tabler/tabler-icons.git"
|
"url": "git+https://github.com/tabler/tabler-icons.git"
|
||||||
@@ -13,7 +13,8 @@
|
|||||||
"files": [
|
"files": [
|
||||||
"icons/*",
|
"icons/*",
|
||||||
"icons-png/*",
|
"icons-png/*",
|
||||||
"tabler-sprite.svg"
|
"tabler-sprite.svg",
|
||||||
|
"tabler-sprite-nostroke.svg"
|
||||||
],
|
],
|
||||||
"homepage": "https://github.com/tabler/tabler-icons#readme",
|
"homepage": "https://github.com/tabler/tabler-icons#readme",
|
||||||
"main": "gulpfile.js",
|
"main": "gulpfile.js",
|
||||||
@@ -21,7 +22,7 @@
|
|||||||
"precommit": "gulp optimize",
|
"precommit": "gulp optimize",
|
||||||
"optimize": "gulp optimize",
|
"optimize": "gulp optimize",
|
||||||
"start": "bundle exec jekyll serve --watch --livereload",
|
"start": "bundle exec jekyll serve --watch --livereload",
|
||||||
"build": "gulp optimize && gulp build && gulp icons-preview && gulp icons-sprite",
|
"build": "gulp build",
|
||||||
"png": "gulp svg-to-png",
|
"png": "gulp svg-to-png",
|
||||||
"zip": "gulp build-zip"
|
"zip": "gulp build-zip"
|
||||||
},
|
},
|
||||||
|
1
tabler-sprite-nostroke.svg
Normal file
1
tabler-sprite-nostroke.svg
Normal file
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 105 KiB |
Reference in New Issue
Block a user