Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: tidy up custom theme story #10488

Merged
merged 1 commit into from
Oct 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 23 additions & 34 deletions packages/calcite-components/src/custom-theme.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,27 +121,32 @@ const kitchenSink = (args: Record<string, string>, useTestValues = false) =>
</div>
</div>`;

const componentTokens = {
...globalTokens,
...accordionTokens,
...accordionItemTokens,
...actionTokens,
...actionBarTokens,
...actionGroupTokens,
...actionMenuTokens,
...actionPadTokens,
...avatarTokens,
...cardTokens,
...alertTokens,
...chipTokens,
...checkboxTokens,
...handleTokens,
...popoverTokens,
...progressTokens,
...inputTokens,
...textAreaTokens,
};

export default {
title: "Theming/Custom Theme",
args: {
...globalTokens,
...accordionTokens,
...accordionItemTokens,
...actionTokens,
...actionBarTokens,
...actionGroupTokens,
...actionMenuTokens,
...actionPadTokens,
...avatarTokens,
...cardTokens,
...alertTokens,
...chipTokens,
...checkboxTokens,
...handleTokens,
...popoverTokens,
...progressTokens,
...inputTokens,
...textAreaTokens,
...componentTokens,
},
};

Expand All @@ -152,23 +157,7 @@ export const themingInteractive = (args: Record<string, string>): string => {
export const theming = (): string => {
return kitchenSink(
{
...accordionTokens,
...accordionItemTokens,
...actionTokens,
...actionBarTokens,
...actionGroupTokens,
...actionMenuTokens,
...actionPadTokens,
...avatarTokens,
...cardTokens,
...alertTokens,
...chipTokens,
...checkboxTokens,
...handleTokens,
...popoverTokens,
...progressTokens,
...inputTokens,
...textAreaTokens,
...componentTokens,
},
true,
);
Expand Down
Loading