Skip to content

Commit bc72363

Browse files
committed
change classes prefix
1 parent 407c54d commit bc72363

File tree

2 files changed

+2328
-2325
lines changed

2 files changed

+2328
-2325
lines changed

core/scripts/tokens/index.mjs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ const {
2424
} = utils;
2525
import StyleDictionary from 'style-dictionary';
2626

27-
// Set the prefix for variables and classes
28-
setPrefixValue('token');
29-
3027
// Register a custom file header
3128
StyleDictionary.registerFileHeader({
3229
name: 'custom-header',
@@ -41,6 +38,9 @@ StyleDictionary.registerFormat({
4138
format: function ({ dictionary }) { // Use 'format' for Style Dictionary v3
4239
console.log('Generating SCSS variables...');
4340

41+
// Set the prefix for variables
42+
setPrefixValue('token');
43+
4444
const primitiveProperties = dictionary.allTokens.filter((prop) => prop.path[0] === 'primitives');
4545
const scaleProperties = dictionary.allTokens.filter((prop) => prop.path[0] === 'scale');
4646
const borderProperties = dictionary.allTokens.filter((prop) => prop.path[0] === 'border');
@@ -94,6 +94,9 @@ StyleDictionary.registerFormat({
9494
format: function ({ dictionary }) { // Use 'format' for Style Dictionary v3
9595
console.log('Generating Utility-Classes...');
9696

97+
// Set the prefix for classes
98+
setPrefixValue('ion');
99+
97100
// Arrays to store specific utility classes
98101
const typographyUtilityClasses = [];
99102
const otherUtilityClasses = [];

0 commit comments

Comments
 (0)