|
1 | 1 | <script> |
2 | | - import { Theme, Button } from "carbon-components-svelte"; |
| 2 | + import { |
| 3 | + Theme, |
| 4 | + Button, |
| 5 | + Link, |
| 6 | + Tag, |
| 7 | + TextInput, |
| 8 | + Checkbox, |
| 9 | + Toggle, |
| 10 | + Tile, |
| 11 | + InlineNotification, |
| 12 | + } from "carbon-components-svelte"; |
3 | 13 | </script> |
4 | 14 |
|
5 | 15 | <Theme |
6 | 16 | theme="g90" |
7 | 17 | tokens={{ |
8 | | - "interactive-01": "#d02670", |
9 | | - "hover-primary": "#ee5396", |
10 | | - "active-primary": "#9f1853", |
| 18 | + // Interactive elements |
| 19 | + "interactive-01": "#d02670", // Primary button background |
| 20 | + "hover-primary": "#ee5396", // Primary button hover |
| 21 | + "active-primary": "#9f1853", // Primary button active |
| 22 | + "interactive-02": "#6f6f6f", // Secondary button background |
| 23 | + "hover-secondary": "#5e5e5e", // Secondary button hover |
| 24 | + |
| 25 | + // Links |
| 26 | + "link-01": "#ff6eb3", // Link text color |
| 27 | + |
| 28 | + // Tags |
| 29 | + "tag-background-blue": "#4a1942", // Tag background |
| 30 | + "tag-color-blue": "#ffb3d9", // Tag text color |
| 31 | + |
| 32 | + // Form elements |
| 33 | + "field-01": "#2d2d2d", // Input field background |
| 34 | + "ui-01": "#2d2d2d", // Tile background |
| 35 | + focus: "#ff6eb3", // Focus indicator color |
| 36 | + |
| 37 | + // Text colors |
| 38 | + "text-01": "#ffffff", // Primary text |
| 39 | + "text-02": "#c6c6c6", // Secondary text |
| 40 | + |
| 41 | + // Notification colors |
| 42 | + "support-04": "#a855f7", // Info notification color |
11 | 43 | }} |
12 | 44 | /> |
13 | 45 |
|
14 | | -<Button>Primary button</Button> |
| 46 | +<div style="display: flex; flex-direction: column; gap: 1rem;"> |
| 47 | + <div> |
| 48 | + <Button>Primary button</Button> |
| 49 | + <Button kind="secondary">Secondary button</Button> |
| 50 | + </div> |
| 51 | + |
| 52 | + <div> |
| 53 | + <Link href="#example">Themed link</Link> |
| 54 | + </div> |
| 55 | + |
| 56 | + <div> |
| 57 | + <Tag type="blue">Themed tag</Tag> |
| 58 | + </div> |
| 59 | + |
| 60 | + <TextInput labelText="Text input" placeholder="Enter text..." /> |
| 61 | + |
| 62 | + <Checkbox labelText="Checkbox with themed focus" /> |
| 63 | + |
| 64 | + <Toggle labelText="Toggle with themed colors" /> |
| 65 | + |
| 66 | + <Tile> |
| 67 | + <p>Tile with themed background</p> |
| 68 | + </Tile> |
| 69 | + |
| 70 | + <InlineNotification |
| 71 | + kind="info" |
| 72 | + title="Info notification" |
| 73 | + subtitle="With themed colors" |
| 74 | + hideCloseButton |
| 75 | + lowContrast |
| 76 | + /> |
| 77 | +</div> |
0 commit comments