GoScrobble/web/node_modules/.cache/babel-loader/56de6fe0a026f5dfd47866b412080bca.json

1 line
5.0 KiB
JSON

{"ast":null,"code":"import { supportedKeyframes, supportedValue, supportedProperty } from 'css-vendor';\nimport { toCssValue } from 'jss';\n/**\n * Add vendor prefix to a property name when needed.\n *\n * @api public\n */\n\nfunction jssVendorPrefixer() {\n function onProcessRule(rule) {\n if (rule.type === 'keyframes') {\n var atRule = rule;\n atRule.at = supportedKeyframes(atRule.at);\n }\n }\n\n function prefixStyle(style) {\n for (var prop in style) {\n var value = style[prop];\n\n if (prop === 'fallbacks' && Array.isArray(value)) {\n style[prop] = value.map(prefixStyle);\n continue;\n }\n\n var changeProp = false;\n var supportedProp = supportedProperty(prop);\n if (supportedProp && supportedProp !== prop) changeProp = true;\n var changeValue = false;\n var supportedValue$1 = supportedValue(supportedProp, toCssValue(value));\n if (supportedValue$1 && supportedValue$1 !== value) changeValue = true;\n\n if (changeProp || changeValue) {\n if (changeProp) delete style[prop];\n style[supportedProp || prop] = supportedValue$1 || value;\n }\n }\n\n return style;\n }\n\n function onProcessStyle(style, rule) {\n if (rule.type !== 'style') return style;\n return prefixStyle(style);\n }\n\n function onChangeValue(value, prop) {\n return supportedValue(prop, toCssValue(value)) || value;\n }\n\n return {\n onProcessRule: onProcessRule,\n onProcessStyle: onProcessStyle,\n onChangeValue: onChangeValue\n };\n}\n\nexport default jssVendorPrefixer;","map":{"version":3,"sources":["/app/node_modules/jss-plugin-vendor-prefixer/dist/jss-plugin-vendor-prefixer.esm.js"],"names":["supportedKeyframes","supportedValue","supportedProperty","toCssValue","jssVendorPrefixer","onProcessRule","rule","type","atRule","at","prefixStyle","style","prop","value","Array","isArray","map","changeProp","supportedProp","changeValue","supportedValue$1","onProcessStyle","onChangeValue"],"mappings":"AAAA,SAASA,kBAAT,EAA6BC,cAA7B,EAA6CC,iBAA7C,QAAsE,YAAtE;AACA,SAASC,UAAT,QAA2B,KAA3B;AAEA;AACA;AACA;AACA;AACA;;AAEA,SA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lB,EAA2B,OAAOI,KAAP;AAC3B,WAAOD,WAAW,CAACC,KAAD,CAAlB;AACD;;AAED,WAASW,aAAT,CAAuBT,KAAvB,EAA8BD,IAA9B,EAAoC;AAClC,WAAOX,cAAc,CAACW,IAAD,EAAOT,UAAU,CAACU,KAAD,CAAjB,CAAd,IAA2CA,KAAlD;AACD;;AAED,SAAO;AACLR,IAAAA,aAAa,EAAEA,aADV;AAELgB,IAAAA,cAAc,EAAEA,cAFX;AAGLC,IAAAA,aAAa,EAAEA;AAHV,GAAP;AAKD;;AAED,eAAelB,iBAAf","sourcesContent":["import { supportedKeyframes, supportedValue, supportedProperty } from 'css-vendor';\nimport { toCssValue } from 'jss';\n\n/**\n * Add vendor prefix to a property name when needed.\n *\n * @api public\n */\n\nfunction jssVendorPrefixer() {\n function onProcessRule(rule) {\n if (rule.type === 'keyframes') {\n var atRule = rule;\n atRule.at = supportedKeyframes(atRule.at);\n }\n }\n\n function prefixStyle(style) {\n for (var prop in style) {\n var value = style[prop];\n\n if (prop === 'fallbacks' && Array.isArray(value)) {\n style[prop] = value.map(prefixStyle);\n continue;\n }\n\n var changeProp = false;\n var supportedProp = supportedProperty(prop);\n if (supportedProp && supportedProp !== prop) changeProp = true;\n var changeValue = false;\n var supportedValue$1 = supportedValue(supportedProp, toCssValue(value));\n if (supportedValue$1 && supportedValue$1 !== value) changeValue = true;\n\n if (changeProp || changeValue) {\n if (changeProp) delete style[prop];\n style[supportedProp || prop] = supportedValue$1 || value;\n }\n }\n\n return style;\n }\n\n function onProcessStyle(style, rule) {\n if (rule.type !== 'style') return style;\n return prefixStyle(style);\n }\n\n function onChangeValue(value, prop) {\n return supportedValue(prop, toCssValue(value)) || value;\n }\n\n return {\n onProcessRule: onProcessRule,\n onProcessStyle: onProcessStyle,\n onChangeValue: onChangeValue\n };\n}\n\nexport default jssVendorPrefixer;\n"]},"metadata":{},"sourceType":"module"}