-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Darkside] Moved contrast-tokens to text group
feat: Moved contrast tokens to 'text' collection feat: Added support for adding custom scopes for each token
- Loading branch information
Showing
6 changed files
with
103 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 26 additions & 26 deletions
52
...t/core/tokens/darkside/tokens/contrast.ts → ...e/tokens/darkside/tokens/text-contrast.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,69 +1,69 @@ | ||
import { GlobalColorRoles, StyleDictionaryToken } from "../util"; | ||
|
||
export const contrastTokenConfig = (): { | ||
contrast: { | ||
[key in GlobalColorRoles]: StyleDictionaryToken<"color">; | ||
export const textContrastTokenConfig = (): { | ||
text: { | ||
[key in `${GlobalColorRoles}-contrast`]: StyleDictionaryToken<"color">; | ||
}; | ||
} => ({ | ||
contrast: { | ||
text: { | ||
/* core */ | ||
accent: { | ||
"accent-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
neutral: { | ||
"neutral-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
/* Status */ | ||
danger: { | ||
"danger-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
info: { | ||
"info-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
success: { | ||
"success-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
warning: { | ||
"warning-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
/* Brand */ | ||
brandOne: { | ||
"brandOne-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
brandTwo: { | ||
"brandTwo-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
brandThree: { | ||
"brandThree-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
/* Data */ | ||
dataOne: { | ||
"dataOne-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
dataTwo: { | ||
"dataTwo-contrast": { | ||
value: "{a.neutral.000.value}", | ||
type: "color", | ||
group: "contrast", | ||
group: "text", | ||
}, | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters