11import { FontAssetType , generateFonts , OtherAssetType } from '@twbs/fantasticon'
2- import ansiColors from " ansi-colors"
3- import { execSync } from " child_process"
4- import { existsSync , mkdirSync , readFileSync } from "fs"
2+ import ansiColors from ' ansi-colors'
3+ import { execSync } from ' child_process'
4+ import { existsSync , mkdirSync , readFileSync } from 'fs'
55import SVGFixer from 'oslllo-svg-fixer'
6- import path from " path"
6+ import path from ' path'
77import codepoints from '../../icons/fonts/ProIcons.json' with { type : 'json' }
88
99const version = JSON . parse ( readFileSync ( 'package.json' , 'utf-8' ) ) . version
@@ -57,21 +57,19 @@ export async function buildFont(rebuild: boolean) {
5757 fontHeight : 500 ,
5858 codepoints,
5959 templates : {
60- html : path . resolve ( 'tools/data/html-font.hbs' )
60+ html : path . resolve ( 'tools/data/html-font.hbs' ) ,
6161 } ,
6262 fontTypes : [
6363 FontAssetType . TTF ,
6464 FontAssetType . WOFF ,
6565 FontAssetType . WOFF2 ,
6666 FontAssetType . EOT ,
6767 ] ,
68- assetTypes : [
69- OtherAssetType . HTML ,
70- OtherAssetType . CSS ,
71- ] ,
68+ assetTypes : [ OtherAssetType . HTML , OtherAssetType . CSS ] ,
7269 formatOptions : {
7370 ttf : {
74- description : 'Modern and open-source icons, designed by ProCode-Software' ,
71+ description :
72+ 'Modern and open-source icons, designed by ProCode-Software' ,
7573 version : version . slice ( 0 , - 2 ) ,
7674 url : 'https://procode-software.github.io/proicons' ,
7775 copyright : `©${ new Date ( ) . getFullYear ( ) } ProCode Software` ,
@@ -82,9 +80,8 @@ export async function buildFont(rebuild: boolean) {
8280 } )
8381
8482 console . log ( ansiColors . green ( 'Done building fonts!' ) )
85-
8683 } catch ( err ) {
8784 console . log ( ansiColors . red ( 'Error building fonts:' ) )
8885 throw new Error ( err )
8986 }
90- }
87+ }
0 commit comments