mapbox-to-css-font
Advanced tools
Comparing version 2.4.2 to 2.4.3
21
index.js
var fontWeights = { | ||
thin: 100, | ||
hairline: 100, | ||
'ultra-light': 100, | ||
'extra-light': 100, | ||
light: 200, | ||
'ultra-light': 200, | ||
'extra-light': 200, | ||
light: 300, | ||
book: 300, | ||
@@ -17,11 +17,11 @@ regular: 400, | ||
bold: 700, | ||
heavy: 800, | ||
black: 800, | ||
'extra-bold': 800, | ||
'ultra-black': 900, | ||
'extra-black': 900, | ||
'ultra-bold': 900, | ||
'ultra-bold': 800, | ||
heavy: 900, | ||
black: 900, | ||
'heavy-black': 900, | ||
fat: 900, | ||
poster: 900 | ||
poster: 900, | ||
'ultra-black': 950, | ||
'extra-black': 950 | ||
}; | ||
@@ -49,2 +49,3 @@ var sp = ' '; | ||
style = haveStyle ? style : maybeWeight; | ||
haveStyle = true; | ||
parts.pop(); | ||
@@ -55,2 +56,3 @@ maybeWeight = parts[parts.length - 1].toLowerCase(); | ||
style = haveStyle ? style : parts[parts.length - 1].replace(maybeWeight, ''); | ||
haveStyle = true; | ||
} | ||
@@ -70,2 +72,3 @@ for (var w in fontWeights) { | ||
weight = maybeWeight; | ||
haveWeight = true; | ||
} | ||
@@ -72,0 +75,0 @@ var fontFamily = parts.join(sp) |
{ | ||
"name": "mapbox-to-css-font", | ||
"version": "2.4.2", | ||
"version": "2.4.3", | ||
"description": "Utility to convert Mapbox GL Style font names to CSS font definitions", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6188
80