Skip to content

Commit

Permalink
Include inset in shadow tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
taysea committed Sep 5, 2024
1 parent 290da67 commit ef65cdb
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 16 deletions.
13 changes: 13 additions & 0 deletions design-tokens/src/token_import.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,19 @@ const shadowToVariables = (name: any, values: any) => {
},
},
};
if (values.inset) {
res[`${name}/inset`] = {
$value: values.inset,
$type: 'boolean',
$extensions: {
'com.figma': {
hiddenFromPublishing: true,
scopes: undefined, // no scopes for boolean variables
codeSyntax: {},
},
},
};
}

return res;
};
Expand Down
30 changes: 15 additions & 15 deletions design-tokens/tokens/component/component.default.json
Original file line number Diff line number Diff line change
Expand Up @@ -4718,7 +4718,7 @@
}
},
"paddingX": {
"Narrow": {
"narrow": {
"$type": "number",
"$value": "{base.static.spacing.xxsmall}",
"$description": "",
Expand All @@ -4730,7 +4730,7 @@
}
}
},
"Standard": {
"default": {
"$type": "number",
"$value": "{base.static.spacing.xsmall}",
"$description": "",
Expand All @@ -4742,7 +4742,7 @@
}
}
},
"Wide": {
"wide": {
"$type": "number",
"$value": 9,
"$description": "",
Expand Down Expand Up @@ -4842,7 +4842,7 @@
}
},
"paddingX": {
"Narrow": {
"narrow": {
"$type": "number",
"$value": "{base.static.spacing.xxsmall}",
"$description": "",
Expand All @@ -4854,7 +4854,7 @@
}
}
},
"Standard": {
"default": {
"$type": "number",
"$value": "{base.static.spacing.xsmall}",
"$description": "",
Expand All @@ -4866,7 +4866,7 @@
}
}
},
"Wide": {
"wide": {
"$type": "number",
"$value": 9,
"$description": "",
Expand Down Expand Up @@ -4966,7 +4966,7 @@
}
},
"paddingX": {
"Narrow": {
"narrow": {
"$type": "number",
"$value": 5,
"$description": "",
Expand All @@ -4978,7 +4978,7 @@
}
}
},
"Standard": {
"default": {
"$type": "number",
"$value": 10,
"$description": "",
Expand All @@ -4990,7 +4990,7 @@
}
}
},
"Wide": {
"wide": {
"$type": "number",
"$value": 15,
"$description": "",
Expand Down Expand Up @@ -5090,7 +5090,7 @@
}
},
"paddingX": {
"Narrow": {
"narrow": {
"$type": "number",
"$value": 9,
"$description": "",
Expand All @@ -5102,7 +5102,7 @@
}
}
},
"Standard": {
"default": {
"$type": "number",
"$value": 18,
"$description": "",
Expand All @@ -5114,7 +5114,7 @@
}
}
},
"Wide": {
"wide": {
"$type": "number",
"$value": 24,
"$description": "",
Expand Down Expand Up @@ -5214,7 +5214,7 @@
}
},
"paddingX": {
"Narrow": {
"narrow": {
"$type": "number",
"$value": 16,
"$description": "",
Expand All @@ -5226,7 +5226,7 @@
}
}
},
"Standard": {
"default": {
"$type": "number",
"$value": 24,
"$description": "",
Expand All @@ -5238,7 +5238,7 @@
}
}
},
"Wide": {
"wide": {
"$type": "number",
"$value": 32,
"$description": "",
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6672,7 +6672,7 @@ hpack.js@^2.1.6:

"hpe-design-tokens-alpha@https://github.com/grommet/hpe-design-system/tarball/design-tokens-alpha-stable":
version "0.1.0"
resolved "https://github.com/grommet/hpe-design-system/tarball/design-tokens-alpha-stable#1506108616ea3ae59c03ad6ed086d5efd680b6f8"
resolved "https://github.com/grommet/hpe-design-system/tarball/design-tokens-alpha-stable#992c00977cae3cd2c6dcb56bc8359f164fee7bb0"
dependencies:
axios "^1.6.0"
dotenv "^16.3.1"
Expand Down

0 comments on commit ef65cdb

Please sign in to comment.