(property: string)
| 43 | const prefixRegex = new RegExp(`^-(${prefixes.join("|")})-`); |
| 44 | |
| 45 | const normalizeProperty = (property: string): CssProperty => { |
| 46 | // convert unprefixed used by webflow version into prefixed one |
| 47 | if (property === "tap-highlight-color") { |
| 48 | return "-webkit-tap-highlight-color"; |
| 49 | } |
| 50 | if (property === "font-smoothing") { |
| 51 | return "-webkit-font-smoothing"; |
| 52 | } |
| 53 | if (prefixedProperties.includes(property)) { |
| 54 | return property as CssProperty; |
| 55 | } |
| 56 | // remove old or unexpected prefixes |
| 57 | return property.replace(prefixRegex, "") as CssProperty; |
| 58 | }; |
| 59 | |
| 60 | /** |
| 61 | * Store prefixed properties without change |
no outgoing calls
no test coverage detected