securityos/node_modules/next/dist/esm/server/font-utils.js.map

1 line
4.4 KiB
Plaintext

{"version":3,"sources":["../../src/server/font-utils.ts"],"names":["Log","GOOGLE_FONT_PROVIDER","DEFAULT_SERIF_FONT","DEFAULT_SANS_SERIF_FONT","capsizeFontsMetrics","require","https","CHROME_UA","IE_UA","isGoogleFont","url","startsWith","getFontForUA","UA","Promise","resolve","reject","rawData","get","headers","res","on","chunk","toString","e","getFontDefinitionFromNetwork","result","warn","getFontDefinitionFromManifest","manifest","find","font","content","parseGoogleFontName","css","regex","matches","matchAll","fontNames","Set","fontFamily","replace","add","formatName","str","word","index","toLowerCase","toUpperCase","formatOverrideValue","val","Math","abs","toFixed","calculateOverrideValues","fontName","fontKey","fontMetrics","category","ascent","descent","lineGap","unitsPerEm","fallbackFont","name","calculateSizeAdjustValues","xWidthAvg","mainFontAvgWidth","fallbackFontName","fallbackFontMetrics","fallbackFontAvgWidth","sizeAdjust","calculateOverrideCSS","trim","calculateSizeAdjustCSS","getFontOverrideCss","useSizeAdjust","calcFn","fontCss","reduce","cssStr","console","log"],"mappings":"AAAA,YAAYA,SAAS,sBAAqB;AAC1C,SACEC,oBAAoB,EACpBC,kBAAkB,EAClBC,uBAAuB,QAClB,0BAAyB;AAChC,MAAMC,sBAAsBC,QAAQ;AACpC,MAAMC,QAAQD,QAAQ;AAEtB,MAAME,YACJ;AACF,MAAMC,QAAQ;AASd,SAASC,aAAaC,GAAW;IAC/B,OAAOA,IAAIC,UAAU,CAACV;AACxB;AAEA,SAASW,aAAaF,GAAW,EAAEG,EAAU;IAC3C,OAAO,IAAIC,QAAQ,CAACC,SAASC;QAC3B,IAAIC,UAAe;QACnBX,MACGY,GAAG,CACFR,KACA;YACES,SAAS;gBACP,cAAcN;YAChB;QACF,GACA,CAACO;YACCA,IAAIC,EAAE,CAAC,QAAQ,CAACC;gBACdL,WAAWK;YACb;YACAF,IAAIC,EAAE,CAAC,OAAO;gBACZN,QAAQE,QAAQM,QAAQ,CAAC;YAC3B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