{"version":3,"file":"strip-light-dark.cjs","sources":["../../../../../../src/core/tokens/style-dictionary/transforms/strip-light-dark.ts"],"sourcesContent":["import type {\n    TransformedToken,\n    Transform,\n    DesignToken,\n} from \"style-dictionary/types\";\n\nconst excludeFromTokenPath = (token: TransformedToken, exclude: string[]) =>\n    token.path.filter((step) => !exclude.includes(step));\n\nconst stripLightDarkTransform: Transform = {\n    name: \"strip/light-dark\",\n    type: \"name\",\n    filter: (token: DesignToken) =>\n        token.path.includes(\"light\") || token.path.includes(\"dark\"),\n    transform: (token: TransformedToken) => {\n        const tokenPath = excludeFromTokenPath(token, [\"light\", \"dark\"]);\n        return tokenPath.join(\"-\");\n    },\n};\n\nexport default stripLightDarkTransform;\n"],"names":["stripLightDarkTransform","name","type","filter","token","path","includes","transform","exclude","step","excludeFromTokenPath","join"],"mappings":"aAMA,MAGMA,EAAqC,CACvCC,KAAM,mBACNC,KAAM,OACNC,OAASC,GACLA,EAAMC,KAAKC,SAAS,UAAYF,EAAMC,KAAKC,SAAS,QACxDC,UAAYH,GARa,EAACA,EAAyBI,IACnDJ,EAAMC,KAAKF,OAAQM,IAAUD,EAAQF,SAASG,IAQxBC,CAAqBN,EAAO,CAAC,QAAS,SACvCO,KAAK"}