@tempoxyz/ds 0.3.10 → 0.3.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/docs/AGENTS.md +9 -0
- package/dist/docs/components/accordion.md +489 -0
- package/dist/docs/components/address-card.md +147 -0
- package/dist/docs/components/agent-logo.md +194 -0
- package/dist/docs/components/alert-dialog.md +631 -0
- package/dist/docs/components/alert.md +448 -0
- package/dist/docs/components/amount-input.md +305 -0
- package/dist/docs/components/amount.md +794 -0
- package/dist/docs/components/app-shell.md +559 -0
- package/dist/docs/components/asset-chip.md +294 -0
- package/dist/docs/components/autocomplete.md +619 -0
- package/dist/docs/components/avatar.md +321 -0
- package/dist/docs/components/badge.md +339 -0
- package/dist/docs/components/badged-logo.md +116 -0
- package/dist/docs/components/banner.md +379 -0
- package/dist/docs/components/bar-chart.md +208 -0
- package/dist/docs/components/breadcrumbs.md +380 -0
- package/dist/docs/components/button-group.md +286 -0
- package/dist/docs/components/button.md +650 -0
- package/dist/docs/components/calendar.md +375 -0
- package/dist/docs/components/callout.md +96 -0
- package/dist/docs/components/checkbox-group.md +521 -0
- package/dist/docs/components/checkbox.md +467 -0
- package/dist/docs/components/choice-group.md +516 -0
- package/dist/docs/components/choicebox.md +641 -0
- package/dist/docs/components/code.md +100 -0
- package/dist/docs/components/combobox.md +939 -0
- package/dist/docs/components/container.md +257 -0
- package/dist/docs/components/copy-button.md +642 -0
- package/dist/docs/components/date-picker.md +514 -0
- package/dist/docs/components/dialog.md +1332 -0
- package/dist/docs/components/drawer.md +966 -0
- package/dist/docs/components/empty.md +340 -0
- package/dist/docs/components/field.md +570 -0
- package/dist/docs/components/fieldset.md +398 -0
- package/dist/docs/components/frame.md +434 -0
- package/dist/docs/components/gauge.md +299 -0
- package/dist/docs/components/get-started-visual.md +117 -0
- package/dist/docs/components/grid.md +288 -0
- package/dist/docs/components/hero-visual.md +155 -0
- package/dist/docs/components/hex.md +487 -0
- package/dist/docs/components/icon-tile.md +292 -0
- package/dist/docs/components/identicon.md +371 -0
- package/dist/docs/components/inline.md +233 -0
- package/dist/docs/components/inset.md +225 -0
- package/dist/docs/components/kbd.md +423 -0
- package/dist/docs/components/list-group.md +981 -0
- package/dist/docs/components/loading-dots.md +237 -0
- package/dist/docs/components/menu.md +934 -0
- package/dist/docs/components/native-select.md +204 -0
- package/dist/docs/components/network-logo.md +248 -0
- package/dist/docs/components/number-field.md +543 -0
- package/dist/docs/components/otp-field.md +616 -0
- package/dist/docs/components/pagination.md +516 -0
- package/dist/docs/components/popover.md +544 -0
- package/dist/docs/components/progress.md +388 -0
- package/dist/docs/components/qr.md +314 -0
- package/dist/docs/components/radio-group.md +528 -0
- package/dist/docs/components/secret-value.md +406 -0
- package/dist/docs/components/select.md +751 -0
- package/dist/docs/components/separator.md +379 -0
- package/dist/docs/components/sidebar-menu.md +922 -0
- package/dist/docs/components/skeleton.md +517 -0
- package/dist/docs/components/slider.md +539 -0
- package/dist/docs/components/snippet.md +424 -0
- package/dist/docs/components/spinner.md +216 -0
- package/dist/docs/components/split-bar.md +139 -0
- package/dist/docs/components/split-button.md +464 -0
- package/dist/docs/components/stack.md +299 -0
- package/dist/docs/components/status-chip.md +226 -0
- package/dist/docs/components/status-indicator.md +119 -0
- package/dist/docs/components/status-row.md +174 -0
- package/dist/docs/components/stepper.md +451 -0
- package/dist/docs/components/success-hero.md +157 -0
- package/dist/docs/components/surface.md +639 -0
- package/dist/docs/components/switch.md +472 -0
- package/dist/docs/components/table.md +967 -0
- package/dist/docs/components/tabs.md +627 -0
- package/dist/docs/components/tempo-logo.md +185 -0
- package/dist/docs/components/text-input.md +624 -0
- package/dist/docs/components/textarea.md +352 -0
- package/dist/docs/components/toast.md +535 -0
- package/dist/docs/components/token-logo.md +371 -0
- package/dist/docs/components/token.md +247 -0
- package/dist/docs/components/tooltip.md +490 -0
- package/dist/docs/components/verification-code.md +116 -0
- package/dist/docs/components/visual.md +249 -0
- package/dist/docs/components.md +203 -0
- package/dist/docs/foundations/accessibility.md +377 -0
- package/dist/docs/foundations/agents.md +150 -0
- package/dist/docs/foundations/color.md +522 -0
- package/dist/docs/foundations/content/tone.md +194 -0
- package/dist/docs/foundations/content/voice.md +194 -0
- package/dist/docs/foundations/content/writing-style.md +406 -0
- package/dist/docs/foundations/iconography.md +282 -0
- package/dist/docs/foundations/intent.md +360 -0
- package/dist/docs/foundations/layout.md +508 -0
- package/dist/docs/foundations/linter.md +296 -0
- package/dist/docs/foundations/motion.md +151 -0
- package/dist/docs/foundations/radius-and-padding.md +86 -0
- package/dist/docs/foundations/typography.md +266 -0
- package/dist/docs/index.md +137 -0
- package/dist/docs/introduction/faq.md +132 -0
- package/dist/docs/introduction/getting-started.md +377 -0
- package/dist/docs/patterns/blockchain-values.md +709 -0
- package/dist/docs/patterns/dashboards.md +638 -0
- package/dist/docs/patterns/destructive-actions.md +626 -0
- package/dist/docs/patterns/empty-states.md +612 -0
- package/dist/docs/patterns/errors-and-validation.md +808 -0
- package/dist/docs/patterns/feedback-and-status.md +518 -0
- package/dist/docs/patterns/forms.md +679 -0
- package/dist/docs/patterns/loading.md +630 -0
- package/dist/docs/patterns/navigation.md +397 -0
- package/dist/docs/patterns/payments.md +765 -0
- package/dist/docs/patterns/responsive-layout.md +997 -0
- package/dist/docs/patterns/tables-and-lists.md +964 -0
- package/dist/docs/products/tempo-console.md +671 -0
- package/dist/docs/products/tempo-performance.md +437 -0
- package/dist/docs/products/tempo-wallet.md +438 -0
- package/package.json +1 -1
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
# Typography
|
|
2
|
+
|
|
3
|
+
Type sets for titles, body text, values, and code.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
Type in Tempo is quiet and direct. Inter carries the interface, Pilat gives titles and large numbers their character, and JetBrains Mono keeps addresses and code legible.
|
|
8
|
+
|
|
9
|
+
Each set bundles a family, size, weight, line height, and tracking into one token, so you choose a role instead of tuning properties. A set keeps one size at every screen width.
|
|
10
|
+
|
|
11
|
+
```tsx
|
|
12
|
+
import { style } from '@tempoxyz/ds'
|
|
13
|
+
|
|
14
|
+
namespace styles {
|
|
15
|
+
export const title = style({ typography: 'heading.h2' })
|
|
16
|
+
|
|
17
|
+
export const body = style({ color: 'content.secondary', typography: 'body.b2' })
|
|
18
|
+
}
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Typefaces
|
|
22
|
+
|
|
23
|
+
Three bundled families cover every set.
|
|
24
|
+
|
|
25
|
+
* **Inter (100 to 900):** Body text, labels, buttons, and table cells.
|
|
26
|
+
* **Pilat (100 to 900):** Titles, display text, and large values.
|
|
27
|
+
* **JetBrains Mono (400 to 700):** Addresses, hashes, keys, and code.
|
|
28
|
+
|
|
29
|
+
## Type Sets
|
|
30
|
+
|
|
31
|
+
Six sets cover the interface, from hero titles down to small labels.
|
|
32
|
+
|
|
33
|
+
### Display
|
|
34
|
+
|
|
35
|
+
Hero titles and large amounts, in light and regular weights that let size carry the emphasis. [Amount](/docs/components/amount) uses display type at its largest size.
|
|
36
|
+
|
|
37
|
+
* `display.d1`: 44px, weight 300, line height 41.8px
|
|
38
|
+
* `display.d2`: 36px, weight 400, line height 34.2px
|
|
39
|
+
|
|
40
|
+
### Value
|
|
41
|
+
|
|
42
|
+
Large readings, such as balances and dashboard numbers, with tight tracking so the digits read as one figure.
|
|
43
|
+
|
|
44
|
+
* `value.v1`: 80px, weight 400, line height normal
|
|
45
|
+
* `value.v2`: 52px, weight 400, line height normal
|
|
46
|
+
* `value.v3`: 40px, weight 400, line height normal
|
|
47
|
+
|
|
48
|
+
### Heading
|
|
49
|
+
|
|
50
|
+
Page, dialog, section, and card titles, in a medium weight. Tracking tightens as the size grows, so large titles stay compact.
|
|
51
|
+
|
|
52
|
+
* `heading.h1`: 32px, weight 500, line height 36.8px
|
|
53
|
+
* `heading.h2`: 24px, weight 500, line height 27.6px
|
|
54
|
+
* `heading.h3`: 20px, weight 500, line height 23px
|
|
55
|
+
* `heading.h4`: 18px, weight 500, line height 20.7px
|
|
56
|
+
|
|
57
|
+
### Body
|
|
58
|
+
|
|
59
|
+
Paragraphs, descriptions, labels, buttons, and table cells, in a regular and a strong weight at each size.
|
|
60
|
+
|
|
61
|
+
* `body.b1`: 16px, weight 400, line height 22px
|
|
62
|
+
* `body.b1Strong`: 16px, weight 500, line height 22px
|
|
63
|
+
* `body.b2`: 14px, weight 400, line height 20px
|
|
64
|
+
* `body.b2Strong`: 14px, weight 500, line height 20px
|
|
65
|
+
* `body.b3`: 12px, weight 400, line height 16px
|
|
66
|
+
* `body.b3Strong`: 12px, weight 500, line height 16px
|
|
67
|
+
|
|
68
|
+
* **Weight (400 and 500):** Strong sets add emphasis without a larger size.
|
|
69
|
+
* **Default (body.b1):** The page default, a size down on dense screens.
|
|
70
|
+
* **Inputs (body.b1):** Large fields keep 16px, so iOS Safari won't zoom.
|
|
71
|
+
* **Buttons (body.b2Strong):** Buttons set their own labels, one size per button.
|
|
72
|
+
|
|
73
|
+
### Mono
|
|
74
|
+
|
|
75
|
+
Addresses, hashes, keys, and code, in one size.
|
|
76
|
+
|
|
77
|
+
* **Addresses and Hashes (mono.m1):** Hex values and monospace table cells.
|
|
78
|
+
* **Commands and Keys (mono.m1):** Snippets and secret values.
|
|
79
|
+
|
|
80
|
+
### Utility
|
|
81
|
+
|
|
82
|
+
Short metadata labels in the mono family, with wide tracking. The design sets them in uppercase, which a component applies itself, since the sets keep the text's case.
|
|
83
|
+
|
|
84
|
+
* `utility.m1`: 12px, weight 400, line height 16px
|
|
85
|
+
* `utility.m2`: 10px, weight 400, line height 12px
|
|
86
|
+
|
|
87
|
+
* **Label (utility.m1):** Metadata labels above or beside a value.
|
|
88
|
+
* **Small Label (utility.m2):** The smaller size, for labels in tight spaces.
|
|
89
|
+
|
|
90
|
+
## Guidelines
|
|
91
|
+
|
|
92
|
+
### Build Hierarchy With Few Sizes
|
|
93
|
+
|
|
94
|
+
Build hierarchy with size and weight, not color. Most screens need a page title, section titles, and body text.
|
|
95
|
+
|
|
96
|
+
* **Page Title (heading.h2):** One per page, including app shell and dialog titles.
|
|
97
|
+
* **Section and Card Title (heading.h3):** Section, surface, and popover titles.
|
|
98
|
+
* **Small Title (body.b1Strong):** Compact titles, such as empty states and legends.
|
|
99
|
+
* **Body and Secondary Text (body.b1):** Reading text, in the primary or secondary color.
|
|
100
|
+
|
|
101
|
+
Keep headings in order. Choose the element by its place in the outline and the set by its look.
|
|
102
|
+
|
|
103
|
+
**Do:** Let the component set the label and description sizes.
|
|
104
|
+
|
|
105
|
+
```tsx
|
|
106
|
+
<Field.Root>
|
|
107
|
+
<Field.Label>Amount</Field.Label>
|
|
108
|
+
<TextInput.Group>
|
|
109
|
+
<TextInput.Control defaultValue="25.00" />
|
|
110
|
+
</TextInput.Group>
|
|
111
|
+
<Field.Description>Available balance: 120.00 USDC.</Field.Description>
|
|
112
|
+
</Field.Root>
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
**Don't:** Use all caps or bold every line to create hierarchy. Write in [sentence case](/docs/foundations/content/writing-style#capitalization).
|
|
116
|
+
|
|
117
|
+
```tsx
|
|
118
|
+
<p>
|
|
119
|
+
<strong>AMOUNT</strong>
|
|
120
|
+
</p>
|
|
121
|
+
<p>
|
|
122
|
+
<strong>Available balance: 120.00 USDC.</strong>
|
|
123
|
+
</p>
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Match Sets to Their Role
|
|
127
|
+
|
|
128
|
+
* **Wrapping Text (body):** Anything that can wrap.
|
|
129
|
+
* **Labels (body.b2Strong):** Field labels and short lines beside controls.
|
|
130
|
+
* **Titles (heading):** Page, dialog, section, and card titles.
|
|
131
|
+
* **Hero Numbers (display and value):** Balances and dashboard readings.
|
|
132
|
+
|
|
133
|
+
### Use Tabular Figures for Numbers
|
|
134
|
+
|
|
135
|
+
Tabular figures align digits in columns and keep live values from shifting. [Amount](/docs/components/amount), [NumberField](/docs/components/number-field), [Slider](/docs/components/slider), and numeric table cells already set them.
|
|
136
|
+
|
|
137
|
+
**Do:** Align amounts with tabular figures, such as `Amount` with `align="right"`.
|
|
138
|
+
|
|
139
|
+
```tsx
|
|
140
|
+
/**
|
|
141
|
+
* Do example for "Use Tabular Figures for Numbers" on the Typography page.
|
|
142
|
+
* Align amounts with tabular figures, such as `Amount` with `align="right"`.
|
|
143
|
+
* @module
|
|
144
|
+
*/
|
|
145
|
+
import { Amount, style } from '@tempoxyz/ds'
|
|
146
|
+
|
|
147
|
+
/** Renders the static preview, which the guideline card shows inert. */
|
|
148
|
+
export function Demo() {
|
|
149
|
+
return (
|
|
150
|
+
<div {...styles.column()}>
|
|
151
|
+
<Amount align="right" symbol="PathUSD" value="1111.11" />
|
|
152
|
+
<Amount align="right" symbol="PathUSD" value="8808.80" />
|
|
153
|
+
<Amount align="right" symbol="PathUSD" value="4170.25" />
|
|
154
|
+
</div>
|
|
155
|
+
)
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
namespace styles {
|
|
159
|
+
export const column = style({ display: 'grid', gap: '8', width: '12rem !custom' })
|
|
160
|
+
}
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
**Don't:** Stack amounts in proportional figures, where digits drift out of line.
|
|
164
|
+
|
|
165
|
+
```tsx
|
|
166
|
+
/**
|
|
167
|
+
* Don't example for "Use Tabular Figures for Numbers" on the Typography page.
|
|
168
|
+
* Don't stack amounts in proportional figures, where digits drift out of line.
|
|
169
|
+
* @module
|
|
170
|
+
*/
|
|
171
|
+
import { style } from '@tempoxyz/ds'
|
|
172
|
+
|
|
173
|
+
/** Renders the static preview, which the guideline card shows inert. */
|
|
174
|
+
export function Demo() {
|
|
175
|
+
return (
|
|
176
|
+
<div {...styles.column()}>
|
|
177
|
+
<span {...styles.amount()}>1,111.11 PathUSD</span>
|
|
178
|
+
<span {...styles.amount()}>8,808.80 PathUSD</span>
|
|
179
|
+
<span {...styles.amount()}>4,170.25 PathUSD</span>
|
|
180
|
+
</div>
|
|
181
|
+
)
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
namespace styles {
|
|
185
|
+
export const amount = style({
|
|
186
|
+
color: 'content.primary',
|
|
187
|
+
fontVariantNumeric: 'proportional-nums !custom',
|
|
188
|
+
textAlign: 'right',
|
|
189
|
+
typography: 'body.b2Strong',
|
|
190
|
+
})
|
|
191
|
+
|
|
192
|
+
export const column = style({ display: 'grid', gap: '8', width: '12rem !custom' })
|
|
193
|
+
}
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
If you render a number yourself, such as a metric tile, set tabular figures in its style.
|
|
197
|
+
|
|
198
|
+
```tsx
|
|
199
|
+
style({ fontVariantNumeric: 'tabular-nums !custom' })
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
### Use Monospace for Hashes and Code
|
|
203
|
+
|
|
204
|
+
Set addresses, hashes, keys, and code in monospace, so similar characters stay distinct and equal-length values align. [Hex](/docs/components/hex), [Snippet](/docs/components/snippet), and [SecretValue](/docs/components/secret-value) apply it. Labels and prose stay out of it.
|
|
205
|
+
|
|
206
|
+
**Do:** Set hashes in `mono.m1`, so they align and `I`, `l`, `0`, and `O` stay distinct.
|
|
207
|
+
|
|
208
|
+
```tsx
|
|
209
|
+
/**
|
|
210
|
+
* Do example for "Use Monospace for Hashes and Code" on the Typography page.
|
|
211
|
+
* Set hashes in a `.mono` set, so they align and `I`, `l`, `0`, and `O` stay distinct.
|
|
212
|
+
* @module
|
|
213
|
+
*/
|
|
214
|
+
import { style } from '@tempoxyz/ds'
|
|
215
|
+
|
|
216
|
+
/** Renders the static preview, which the guideline card shows inert. */
|
|
217
|
+
export function Demo() {
|
|
218
|
+
return (
|
|
219
|
+
<div {...styles.column()}>
|
|
220
|
+
<span {...styles.value()}>0x1f0a9c3e7b11d4e0</span>
|
|
221
|
+
<span {...styles.value()}>0x8d1Il0O4e2b7a96c</span>
|
|
222
|
+
<span {...styles.value()}>0x7777a1b2c3d4e5f6</span>
|
|
223
|
+
</div>
|
|
224
|
+
)
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
namespace styles {
|
|
228
|
+
export const column = style({ display: 'grid', gap: '8' })
|
|
229
|
+
|
|
230
|
+
export const value = style({ color: 'content.primary', typography: 'mono.m1' })
|
|
231
|
+
}
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
**Don't:** Set hashes in a proportional set, where equal-length values drift apart.
|
|
235
|
+
|
|
236
|
+
```tsx
|
|
237
|
+
/**
|
|
238
|
+
* Don't example for "Use Monospace for Hashes and Code" on the Typography page.
|
|
239
|
+
* Don't set hashes in a proportional set, where equal-length values drift apart.
|
|
240
|
+
* @module
|
|
241
|
+
*/
|
|
242
|
+
import { style } from '@tempoxyz/ds'
|
|
243
|
+
|
|
244
|
+
/** Renders the static preview, which the guideline card shows inert. */
|
|
245
|
+
export function Demo() {
|
|
246
|
+
return (
|
|
247
|
+
<div {...styles.column()}>
|
|
248
|
+
<span {...styles.value()}>0x1f0a9c3e7b11d4e0</span>
|
|
249
|
+
<span {...styles.value()}>0x8d1Il0O4e2b7a96c</span>
|
|
250
|
+
<span {...styles.value()}>0x7777a1b2c3d4e5f6</span>
|
|
251
|
+
</div>
|
|
252
|
+
)
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
namespace styles {
|
|
256
|
+
export const column = style({ display: 'grid', gap: '8' })
|
|
257
|
+
|
|
258
|
+
export const value = style({ color: 'content.primary', typography: 'body.b3' })
|
|
259
|
+
}
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
### Keep Lines Readable
|
|
263
|
+
|
|
264
|
+
* **Line Length (45 to 75 characters):** Cap paragraphs with `maxWidth: '65ch !custom'`. Dialogs already cap their width.
|
|
265
|
+
* **Alignment:** Left-align text. Center only short text, such as an empty state title.
|
|
266
|
+
* **Minimum Size (12px):** Don't set interface text smaller. The smallest body set, `body.b3`, stops here.
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
# Tempo Design System
|
|
2
|
+
|
|
3
|
+
> Foundations, guidelines, and components for Tempo products.
|
|
4
|
+
|
|
5
|
+
Each page is the Markdown of the documentation at ds.tehq.dev for this version of the package. A link to /docs/<path> in a page resolves to <path>.md in this folder.
|
|
6
|
+
|
|
7
|
+
## Introduction
|
|
8
|
+
|
|
9
|
+
- [FAQ](introduction/faq.md): Common questions about building with, and contributing to, Tempo Design System.
|
|
10
|
+
- [Getting Started](introduction/getting-started.md): Install Tempo Design System and render your first component.
|
|
11
|
+
|
|
12
|
+
## Foundations
|
|
13
|
+
|
|
14
|
+
- [Accessibility](foundations/accessibility.md): The accessibility baseline for every Tempo component, and what you still own.
|
|
15
|
+
- [Agents](foundations/agents.md): How coding agents read these docs and the source, and the rules they follow.
|
|
16
|
+
- [Color](foundations/color.md): Color tokens for text, surfaces, borders, and status, with contrast rules.
|
|
17
|
+
- [Tone](foundations/content/tone.md): How Tempo's voice adjusts to the reader, from a first visit to an error.
|
|
18
|
+
- [Voice](foundations/content/voice.md): Tempo's personality in words, consistent across every product.
|
|
19
|
+
- [Writing Style](foundations/content/writing-style.md): How Tempo writes interface text: sentence case, a verb first, and plain words.
|
|
20
|
+
- [Iconography](foundations/iconography.md): Icons from the Tempo catalog, and how to size, color, and label them.
|
|
21
|
+
- [Building From Intent](foundations/intent.md): Choose each component by the job of its content, not by the markup it replaces.
|
|
22
|
+
- [Layout](foundations/layout.md): Page structure, grid, spacing, radius, and elevation.
|
|
23
|
+
- [Linter](foundations/linter.md): Oxlint rules that check how your app uses Tempo Design System.
|
|
24
|
+
- [Motion](foundations/motion.md): Easing curves, durations, and reduced-motion rules for state changes.
|
|
25
|
+
- [Radius and Padding](foundations/radius-and-padding.md): How corner radius and padding pair, from fields to modals.
|
|
26
|
+
- [Typography](foundations/typography.md): Type sets for titles, body text, values, and code.
|
|
27
|
+
|
|
28
|
+
## Products
|
|
29
|
+
|
|
30
|
+
- [Tempo Console](products/tempo-console.md): Tempo Console is the web app for Tempo API projects, keys, usage, and billing.
|
|
31
|
+
- [Tempo Performance](products/tempo-performance.md): Tempo Performance is the public benchmark dashboard for the Tempo network.
|
|
32
|
+
- [Tempo Wallet](products/tempo-wallet.md): Tempo Wallet is the first-party wallet for balances, transfers, and deposits.
|
|
33
|
+
|
|
34
|
+
## Patterns
|
|
35
|
+
|
|
36
|
+
- [Blockchain Values](patterns/blockchain-values.md): Formats addresses, hashes, amounts, and timestamps so people can verify them.
|
|
37
|
+
- [Dashboards](patterns/dashboards.md): Summarizes system metrics, such as throughput, in tiles, filters, and charts.
|
|
38
|
+
- [Destructive Actions](patterns/destructive-actions.md): Match the safeguard on a destructive action to its impact and its reversibility.
|
|
39
|
+
- [Empty States](patterns/empty-states.md): Explain why a region has nothing to show, and offer the next step that fills it.
|
|
40
|
+
- [Errors and Validation](patterns/errors-and-validation.md): Check values at the right moment, and state how to fix each problem.
|
|
41
|
+
- [Feedback and Status](patterns/feedback-and-status.md): Name each system state once, and choose Toast, Alert, or Banner by urgency.
|
|
42
|
+
- [Forms](patterns/forms.md): Order fields, labels, and actions so a person completes a form in one pass.
|
|
43
|
+
- [Loading](patterns/loading.md): Show that content or an action is on its way, with an indicator to fit the wait.
|
|
44
|
+
- [Navigation](patterns/navigation.md): Move between product areas, page views, and nested pages in one shared frame.
|
|
45
|
+
- [Payments](patterns/payments.md): Build send, receive, and deposit flows, from the amount to the receipt.
|
|
46
|
+
- [Responsive Layout](patterns/responsive-layout.md): Adapt layouts from a 320px phone to a wide desktop with shared breakpoints.
|
|
47
|
+
- [Tables and Lists](patterns/tables-and-lists.md): Present records, such as payments and API keys, to scan, compare, and act on.
|
|
48
|
+
|
|
49
|
+
## Components
|
|
50
|
+
|
|
51
|
+
- [Overview](components.md): Components for building Tempo products, grouped by the job each one does.
|
|
52
|
+
- [Accordion](components/accordion.md): Stacks collapsible sections that each reveal a labelled panel.
|
|
53
|
+
- [AddressCard](components/address-card.md): Shows a wallet address to receive funds, with its QR code and networks.
|
|
54
|
+
- [AgentLogo](components/agent-logo.md): Shows the logo of an AI agent that works with a wallet.
|
|
55
|
+
- [Alert](components/alert.md): Shows an inline message tied to nearby content.
|
|
56
|
+
- [AlertDialog](components/alert-dialog.md): Asks you to confirm a critical action before it happens.
|
|
57
|
+
- [Amount](components/amount.md): Formats a number as money or a token amount.
|
|
58
|
+
- [AmountInput](components/amount-input.md): Accepts a decimal amount, such as a payment or transfer value.
|
|
59
|
+
- [AppShell](components/app-shell.md): Places a sticky sidebar beside the main content column.
|
|
60
|
+
- [AssetChip](components/asset-chip.md): Labels a supported asset or network in a small chip, which can also pick one.
|
|
61
|
+
- [Autocomplete](components/autocomplete.md): A text input that suggests values while people type.
|
|
62
|
+
- [Avatar](components/avatar.md): Represents a person, contact, or wallet with an image, initials, or an icon.
|
|
63
|
+
- [Badge](components/badge.md): Labels a status or category in a compact chip.
|
|
64
|
+
- [BadgedLogo](components/badged-logo.md): Marks a token or an app with a small badge on the corner of its logo.
|
|
65
|
+
- [Banner](components/banner.md): Shows a full-width message about the system or page.
|
|
66
|
+
- [BarChart](components/bar-chart.md): Shows values over time as stacked bars, such as the daily spend of each agent.
|
|
67
|
+
- [Breadcrumbs](components/breadcrumbs.md): Shows where the current page sits in the site hierarchy.
|
|
68
|
+
- [Button](components/button.md): Triggers an action, such as submitting a form or sending a payment.
|
|
69
|
+
- [ButtonGroup](components/button-group.md): Lays out the actions at the foot of a dialog or focused flow.
|
|
70
|
+
- [Calendar](components/calendar.md): A month grid for picking one date or a date range.
|
|
71
|
+
- [Callout](components/callout.md): Sets a short passage of body text apart in a subtle box.
|
|
72
|
+
- [Checkbox](components/checkbox.md): Turns a single independent option on or off.
|
|
73
|
+
- [CheckboxGroup](components/checkbox-group.md): Shares one value array across a group of checkboxes.
|
|
74
|
+
- [ChoiceGroup](components/choice-group.md): A segmented control for a few mutually exclusive options.
|
|
75
|
+
- [Choicebox](components/choicebox.md): A selectable tile with an optional icon, title, and description.
|
|
76
|
+
- [Code](components/code.md): Sets a command, identifier, or value apart inside a sentence.
|
|
77
|
+
- [Combobox](components/combobox.md): A text input that filters a list of fixed options while people type.
|
|
78
|
+
- [Container](components/container.md): Centers content at a maximum width.
|
|
79
|
+
- [CopyButton](components/copy-button.md): Copies a value to the clipboard and confirms the copy.
|
|
80
|
+
- [DatePicker](components/date-picker.md): Shows the selected date and opens a calendar in a popup.
|
|
81
|
+
- [Dialog](components/dialog.md): Opens a modal popup over the page.
|
|
82
|
+
- [Drawer](components/drawer.md): Slides a modal panel in from an edge of the viewport.
|
|
83
|
+
- [Empty](components/empty.md): Fills a region that has nothing to show yet.
|
|
84
|
+
- [Field](components/field.md): Links a label, description, and error message to a control.
|
|
85
|
+
- [Fieldset](components/fieldset.md): Groups related fields under a shared legend.
|
|
86
|
+
- [Frame](components/frame.md): Lays out a header, body, and footer in a column.
|
|
87
|
+
- [Gauge](components/gauge.md): Shows a measurement within a range as a ring.
|
|
88
|
+
- [GetStartedVisual](components/get-started-visual.md): Illustrates one step of a get started flow at the top of its card.
|
|
89
|
+
- [Grid](components/grid.md): Lays out children on a responsive grid.
|
|
90
|
+
- [HeroVisual](components/hero-visual.md): Shows animated streaks and a title beside the steps of a setup flow.
|
|
91
|
+
- [Hex](components/hex.md): Shows a hex string, such as an address, truncated to fit.
|
|
92
|
+
- [IconTile](components/icon-tile.md): Anchors a centered modal with one icon in a rounded square.
|
|
93
|
+
- [Identicon](components/identicon.md): Shows a unique gradient avatar derived from an address.
|
|
94
|
+
- [Inline](components/inline.md): Lays out children in a horizontal row.
|
|
95
|
+
- [Inset](components/inset.md): Pads content with spacing tokens.
|
|
96
|
+
- [Kbd](components/kbd.md): Shows a keyboard key or shortcut.
|
|
97
|
+
- [ListGroup](components/list-group.md): Stacks rows for details, pickers, checklists, and settings.
|
|
98
|
+
- [LoadingDots](components/loading-dots.md): Shows three pulsing dots for inline loading.
|
|
99
|
+
- [Menu](components/menu.md): Opens a list of actions from a button.
|
|
100
|
+
- [NativeSelect](components/native-select.md): A native select styled as a field, which opens the browser's own picker.
|
|
101
|
+
- [NetworkLogo](components/network-logo.md): Shows the logo of the network a token lives on.
|
|
102
|
+
- [NumberField](components/number-field.md): A numeric input with increment and decrement buttons.
|
|
103
|
+
- [OtpField](components/otp-field.md): Accepts a one-time passcode, one character per slot.
|
|
104
|
+
- [Pagination](components/pagination.md): Moves between pages of a long list.
|
|
105
|
+
- [Popover](components/popover.md): Opens a non-modal popup anchored to a trigger.
|
|
106
|
+
- [Progress](components/progress.md): Shows how far a task has advanced.
|
|
107
|
+
- [Qr](components/qr.md): Renders a value as a QR code.
|
|
108
|
+
- [RadioGroup](components/radio-group.md): Lets you pick a single option from a short list.
|
|
109
|
+
- [SecretValue](components/secret-value.md): Masks a secret and adds reveal and copy buttons.
|
|
110
|
+
- [Select](components/select.md): Opens a list of options for choosing one value.
|
|
111
|
+
- [Separator](components/separator.md): Draws a rule between groups of content.
|
|
112
|
+
- [SidebarMenu](components/sidebar-menu.md): Vertical navigation for sidebars and drawers.
|
|
113
|
+
- [Skeleton](components/skeleton.md): Holds the place of content while it loads.
|
|
114
|
+
- [Slider](components/slider.md): Picks a single value or a range by dragging.
|
|
115
|
+
- [Snippet](components/snippet.md): Shows a command or value with a copy button.
|
|
116
|
+
- [Spinner](components/spinner.md): Shows that something is loading.
|
|
117
|
+
- [SplitBar](components/split-bar.md): Splits one total between two parts, with a legend under the bar.
|
|
118
|
+
- [SplitButton](components/split-button.md): Pairs a primary action with a menu of alternatives.
|
|
119
|
+
- [Stack](components/stack.md): Lays out children in a vertical column.
|
|
120
|
+
- [StatusChip](components/status-chip.md): Names the status of a payment, an authorization, or a network.
|
|
121
|
+
- [StatusIndicator](components/status-indicator.md): Names the status of a system or a service with a dot and a label.
|
|
122
|
+
- [StatusRow](components/status-row.md): Follows the status of one payment or task while it runs.
|
|
123
|
+
- [Stepper](components/stepper.md): Shows progress through a fixed sequence of steps.
|
|
124
|
+
- [SuccessHero](components/success-hero.md): Confirms that a setup flow finished, on a dark card of animated streaks.
|
|
125
|
+
- [Surface](components/surface.md): A card container for grouping related content.
|
|
126
|
+
- [Switch](components/switch.md): Toggles a setting that applies immediately.
|
|
127
|
+
- [Table](components/table.md): Displays tabular data in rows and columns.
|
|
128
|
+
- [Tabs](components/tabs.md): Switches between related views.
|
|
129
|
+
- [TempoLogo](components/tempo-logo.md): Shows the Tempo brand logo.
|
|
130
|
+
- [TextInput](components/text-input.md): A text field with optional prefix, suffix, and clear button.
|
|
131
|
+
- [Textarea](components/textarea.md): A multi-line text field.
|
|
132
|
+
- [Toast](components/toast.md): Shows a brief notification that dismisses itself.
|
|
133
|
+
- [Token](components/token.md): Shows which token an amount is in, and opens a picker to change it.
|
|
134
|
+
- [TokenLogo](components/token-logo.md): Shows a token logo by contract address or symbol.
|
|
135
|
+
- [Tooltip](components/tooltip.md): Shows a short label for a control on hover or focus.
|
|
136
|
+
- [VerificationCode](components/verification-code.md): Shows a code that a person compares with the one another app shows.
|
|
137
|
+
- [Visual](components/visual.md): Illustrates the top of an onboarding or feature modal.
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
# FAQ
|
|
2
|
+
|
|
3
|
+
Common questions about building with, and contributing to, Tempo Design System.
|
|
4
|
+
|
|
5
|
+
## Getting Started
|
|
6
|
+
|
|
7
|
+
### Which Surface Should I Use?
|
|
8
|
+
|
|
9
|
+
Choose the surface by the platform you ship to. The surfaces share a design language but not code, so don't import one from the other.
|
|
10
|
+
|
|
11
|
+
| I am building... | Surface | Import |
|
|
12
|
+
| ------------------------- | ------- | --------------------- |
|
|
13
|
+
| A web application | Web | `@tempoxyz/ds` |
|
|
14
|
+
| A React Native mobile app | Mobile | `@tempoxyz/ds/mobile` |
|
|
15
|
+
|
|
16
|
+
Web components render DOM elements and compile with a Zyzz bundler plugin. Mobile components render React Native views and compile with Metro. [Getting Started](/docs/introduction/getting-started) shows each setup.
|
|
17
|
+
|
|
18
|
+
### Do I Need to Import a Stylesheet?
|
|
19
|
+
|
|
20
|
+
No. The library publishes no stylesheet.
|
|
21
|
+
|
|
22
|
+
* **Vite:** The [Vite plugin](/docs/introduction/getting-started#setup) emits the variables, the Inter, Pilat, and JetBrains Mono fonts, and keyframes once. Each component emits its own rules, so a build carries only the styles it uses.
|
|
23
|
+
* **Rollup, Webpack, and esbuild:** The adapters emit a generated `/zyzz.css` that you load once.
|
|
24
|
+
* **Mobile:** Metro compiles library and app styles during the bundle.
|
|
25
|
+
|
|
26
|
+
The Zyzz plugin is the only supported web setup.
|
|
27
|
+
|
|
28
|
+
### How Do I Style My Own Markup?
|
|
29
|
+
|
|
30
|
+
Use `style` and `variants` from `@tempoxyz/ds` with TDS tokens, such as `content.primary`, `background.elevated`, `'24'`, and `body.b2`. Group the definitions in a `namespace styles` block.
|
|
31
|
+
|
|
32
|
+
If your app needs its own tokens, extend `variables` in your own Zyzz config, as the Custom Variables setup in [Getting Started](/docs/introduction/getting-started#setup) shows.
|
|
33
|
+
|
|
34
|
+
## Components
|
|
35
|
+
|
|
36
|
+
### Can I Change How a Component Looks?
|
|
37
|
+
|
|
38
|
+
Use the component's props first, such as `variant` and `size`.
|
|
39
|
+
|
|
40
|
+
* **Web:** Components accept `className` and `style`, and keep your classes beside their own.
|
|
41
|
+
* **Mobile:** Components accept React Native `style`. Import variables from `@tempoxyz/ds/mobile`.
|
|
42
|
+
|
|
43
|
+
If you need a token the library does not have, extend `variables` as [How Do I Style My Own Markup?](#how-do-i-style-my-own-markup) shows.
|
|
44
|
+
|
|
45
|
+
### What If the Library Doesn't Have the Component I Need?
|
|
46
|
+
|
|
47
|
+
Build it in your app from library components and `style`, with TDS tokens. Keep that code in your app. If other products need it too, propose it for the library.
|
|
48
|
+
|
|
49
|
+
### How Do I Request a Component, Variant, or Token?
|
|
50
|
+
|
|
51
|
+
Open an issue in the Design System project in Linear. Include:
|
|
52
|
+
|
|
53
|
+
* The use case.
|
|
54
|
+
* The proposed contract, such as props, variants, or token names.
|
|
55
|
+
* Links to the relevant Figma designs.
|
|
56
|
+
* Consumer code or a pull request that shows the need.
|
|
57
|
+
|
|
58
|
+
If an issue already covers the proposal, reuse it. A proposal joins `@tempoxyz/ds` after designer approval and an approved Figma definition.
|
|
59
|
+
|
|
60
|
+
### Why Isn't a Figma Component in the Library?
|
|
61
|
+
|
|
62
|
+
The library includes only components with a verified production family in Figma. Archived and experimental Figma components stay out until a production version exists.
|
|
63
|
+
|
|
64
|
+
The [Components](/docs/components) overview lists what ships today. Sidebar pages marked 🚧 are not written yet.
|
|
65
|
+
|
|
66
|
+
### Which Components Exist on Mobile?
|
|
67
|
+
|
|
68
|
+
`@tempoxyz/ds/mobile` has a smaller set, and some names differ from web.
|
|
69
|
+
|
|
70
|
+
| Mobile | Web counterpart |
|
|
71
|
+
| ------------ | --------------------------------------------------------------------------------- |
|
|
72
|
+
| `Avatar` | [Avatar](/docs/components/avatar) |
|
|
73
|
+
| `Badge` | [Badge](/docs/components/badge) |
|
|
74
|
+
| `Button` | [Button](/docs/components/button) |
|
|
75
|
+
| `CodeInput` | [OtpField](/docs/components/otp-field) |
|
|
76
|
+
| `IconButton` | [Button](/docs/components/button) with `shape="icon"` |
|
|
77
|
+
| `Skeleton` | [Skeleton](/docs/components/skeleton) |
|
|
78
|
+
| `Spinner` | [Spinner](/docs/components/spinner) |
|
|
79
|
+
| `TextButton` | [Button](/docs/components/button) with `variant="tertiary"` |
|
|
80
|
+
| `TextInput` | [TextInput](/docs/components/text-input) inside a [Field](/docs/components/field) |
|
|
81
|
+
| `Toast` | [Toast](/docs/components/toast) |
|
|
82
|
+
| `Toggle` | [Switch](/docs/components/switch) |
|
|
83
|
+
|
|
84
|
+
### Do Web Components Work in Mobile Browsers?
|
|
85
|
+
|
|
86
|
+
Yes. [Responsive Layout](/docs/patterns/responsive-layout) shows how to adapt a layout from a phone to a desktop.
|
|
87
|
+
|
|
88
|
+
## Design
|
|
89
|
+
|
|
90
|
+
### How Do Light and Dark Schemes Work?
|
|
91
|
+
|
|
92
|
+
Every color has a light and a dark value, so you write each color once.
|
|
93
|
+
|
|
94
|
+
* **Web:** Values follow the inherited CSS `color-scheme`. Set `color-scheme: light dark` on the root to follow the system, or apply `vars({ colorScheme: 'dark' })` to fix one region.
|
|
95
|
+
* **Mobile:** `Provider colorScheme="system"` follows the device setting. To override it, pass `light` or `dark`. To render a subtree with inverse variables, pass `vars="inverse"`.
|
|
96
|
+
|
|
97
|
+
The library does not store a scheme preference. If your app offers a theme setting, persist the choice yourself.
|
|
98
|
+
|
|
99
|
+
### Which Is Right When Figma and Code Disagree?
|
|
100
|
+
|
|
101
|
+
Figma is the design reference. Variables, icons, and components are maintained by hand, so the two can drift.
|
|
102
|
+
|
|
103
|
+
If a component does not match its production Figma design, use Report issue on its page and include the Figma link. If you need the change before the library has it, keep the implementation in your app.
|
|
104
|
+
|
|
105
|
+
### Where Are the Figma Files?
|
|
106
|
+
|
|
107
|
+
The Figma files define every variable, icon, and component:
|
|
108
|
+
|
|
109
|
+
* [TPDS 1.0 Platform](https://www.figma.com/design/yE96kcymnNR88PJp6G1sPs/TPDS-1.0-Platform) for Web variables and components
|
|
110
|
+
* [TDS Platform](https://www.figma.com/design/pcO4NIuw8wx9U2nGJOcjzE) for Web icons
|
|
111
|
+
* [TDS App](https://www.figma.com/design/8iu5856rBEI3pnZ6YaIBgw) for Mobile, whose families the mobile components implement
|
|
112
|
+
|
|
113
|
+
## Docs
|
|
114
|
+
|
|
115
|
+
### How Do I Report a Docs Issue?
|
|
116
|
+
|
|
117
|
+
On wide screens, On this page includes two actions:
|
|
118
|
+
|
|
119
|
+
* **Report issue:** Opens a GitHub issue titled with the page name and its path.
|
|
120
|
+
* **Edit page:** Opens the MDX source of the page on GitHub.
|
|
121
|
+
|
|
122
|
+
On narrower screens, use the GitHub link at the bottom of the sidebar.
|
|
123
|
+
|
|
124
|
+
### How Should Coding Agents Use These Docs?
|
|
125
|
+
|
|
126
|
+
Every page has a Markdown twin, `/llms.txt` indexes them all, and the library documents each export in its source. [Agents](/docs/foundations/agents) lists the files and the rules an agent follows when it generates Tempo UI.
|
|
127
|
+
|
|
128
|
+
## License
|
|
129
|
+
|
|
130
|
+
### How Is the Library Licensed?
|
|
131
|
+
|
|
132
|
+
The library is open source under the [MIT license](https://github.com/tempoxyz/ds/blob/main/LICENSE-MIT).
|