@tempoxyz/ds 0.3.14 → 0.3.15

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.
Files changed (131) hide show
  1. package/dist/docs/AGENTS.md +73 -10
  2. package/dist/docs/{marketing/introduction/getting-started.md → marketing.md} +28 -20
  3. package/dist/docs/product/components/actions.md +2058 -0
  4. package/dist/docs/product/components/blockchain.md +3825 -0
  5. package/dist/docs/product/components/data-display.md +5901 -0
  6. package/dist/docs/product/components/feedback-and-status.md +4008 -0
  7. package/dist/docs/product/components/forms-and-inputs.md +10543 -0
  8. package/dist/docs/product/components/layout.md +3339 -0
  9. package/dist/docs/product/components/navigation.md +2914 -0
  10. package/dist/docs/product/components/overlays.md +4917 -0
  11. package/dist/docs/product/components.md +125 -125
  12. package/dist/docs/product/foundations.md +4596 -0
  13. package/dist/docs/product/patterns.md +10129 -0
  14. package/package.json +1 -1
  15. package/dist/docs/index.md +0 -145
  16. package/dist/docs/product/components/accordion.md +0 -489
  17. package/dist/docs/product/components/address-card.md +0 -147
  18. package/dist/docs/product/components/agent-logo.md +0 -194
  19. package/dist/docs/product/components/alert-dialog.md +0 -631
  20. package/dist/docs/product/components/alert.md +0 -448
  21. package/dist/docs/product/components/amount-input.md +0 -305
  22. package/dist/docs/product/components/amount.md +0 -794
  23. package/dist/docs/product/components/app-shell.md +0 -559
  24. package/dist/docs/product/components/asset-chip.md +0 -294
  25. package/dist/docs/product/components/autocomplete.md +0 -620
  26. package/dist/docs/product/components/avatar.md +0 -321
  27. package/dist/docs/product/components/badge.md +0 -339
  28. package/dist/docs/product/components/badged-logo.md +0 -116
  29. package/dist/docs/product/components/banner.md +0 -379
  30. package/dist/docs/product/components/bar-chart.md +0 -208
  31. package/dist/docs/product/components/breadcrumbs.md +0 -380
  32. package/dist/docs/product/components/button-group.md +0 -286
  33. package/dist/docs/product/components/button.md +0 -650
  34. package/dist/docs/product/components/calendar.md +0 -375
  35. package/dist/docs/product/components/callout.md +0 -96
  36. package/dist/docs/product/components/checkbox-group.md +0 -521
  37. package/dist/docs/product/components/checkbox.md +0 -467
  38. package/dist/docs/product/components/choice-group.md +0 -516
  39. package/dist/docs/product/components/choicebox.md +0 -641
  40. package/dist/docs/product/components/code.md +0 -100
  41. package/dist/docs/product/components/combobox.md +0 -939
  42. package/dist/docs/product/components/container.md +0 -257
  43. package/dist/docs/product/components/copy-button.md +0 -642
  44. package/dist/docs/product/components/date-picker.md +0 -514
  45. package/dist/docs/product/components/dialog.md +0 -1332
  46. package/dist/docs/product/components/drawer.md +0 -966
  47. package/dist/docs/product/components/empty.md +0 -340
  48. package/dist/docs/product/components/field.md +0 -570
  49. package/dist/docs/product/components/fieldset.md +0 -398
  50. package/dist/docs/product/components/frame.md +0 -434
  51. package/dist/docs/product/components/gauge.md +0 -299
  52. package/dist/docs/product/components/get-started-visual.md +0 -117
  53. package/dist/docs/product/components/grid.md +0 -288
  54. package/dist/docs/product/components/hero-visual.md +0 -155
  55. package/dist/docs/product/components/hex.md +0 -487
  56. package/dist/docs/product/components/icon-tile.md +0 -292
  57. package/dist/docs/product/components/identicon.md +0 -371
  58. package/dist/docs/product/components/inline.md +0 -233
  59. package/dist/docs/product/components/inset.md +0 -225
  60. package/dist/docs/product/components/kbd.md +0 -423
  61. package/dist/docs/product/components/list-group.md +0 -981
  62. package/dist/docs/product/components/loading-dots.md +0 -237
  63. package/dist/docs/product/components/menu.md +0 -934
  64. package/dist/docs/product/components/native-select.md +0 -204
  65. package/dist/docs/product/components/network-logo.md +0 -248
  66. package/dist/docs/product/components/number-field.md +0 -543
  67. package/dist/docs/product/components/otp-field.md +0 -616
  68. package/dist/docs/product/components/pagination.md +0 -516
  69. package/dist/docs/product/components/popover.md +0 -544
  70. package/dist/docs/product/components/progress.md +0 -388
  71. package/dist/docs/product/components/qr.md +0 -314
  72. package/dist/docs/product/components/radio-group.md +0 -528
  73. package/dist/docs/product/components/secret-value.md +0 -406
  74. package/dist/docs/product/components/select.md +0 -751
  75. package/dist/docs/product/components/separator.md +0 -379
  76. package/dist/docs/product/components/sidebar-menu.md +0 -922
  77. package/dist/docs/product/components/skeleton.md +0 -517
  78. package/dist/docs/product/components/slider.md +0 -539
  79. package/dist/docs/product/components/snippet.md +0 -424
  80. package/dist/docs/product/components/spinner.md +0 -216
  81. package/dist/docs/product/components/split-bar.md +0 -139
  82. package/dist/docs/product/components/split-button.md +0 -464
  83. package/dist/docs/product/components/stack.md +0 -299
  84. package/dist/docs/product/components/status-chip.md +0 -226
  85. package/dist/docs/product/components/status-indicator.md +0 -119
  86. package/dist/docs/product/components/status-row.md +0 -174
  87. package/dist/docs/product/components/stepper.md +0 -451
  88. package/dist/docs/product/components/success-hero.md +0 -157
  89. package/dist/docs/product/components/surface.md +0 -639
  90. package/dist/docs/product/components/switch.md +0 -472
  91. package/dist/docs/product/components/table.md +0 -968
  92. package/dist/docs/product/components/tabs.md +0 -627
  93. package/dist/docs/product/components/tempo-logo.md +0 -185
  94. package/dist/docs/product/components/text-input.md +0 -624
  95. package/dist/docs/product/components/textarea.md +0 -352
  96. package/dist/docs/product/components/toast.md +0 -535
  97. package/dist/docs/product/components/token-logo.md +0 -371
  98. package/dist/docs/product/components/token.md +0 -247
  99. package/dist/docs/product/components/tooltip.md +0 -490
  100. package/dist/docs/product/components/verification-code.md +0 -116
  101. package/dist/docs/product/components/visual.md +0 -249
  102. package/dist/docs/product/foundations/accessibility.md +0 -377
  103. package/dist/docs/product/foundations/agents.md +0 -159
  104. package/dist/docs/product/foundations/color.md +0 -522
  105. package/dist/docs/product/foundations/content/tone.md +0 -194
  106. package/dist/docs/product/foundations/content/voice.md +0 -194
  107. package/dist/docs/product/foundations/content/writing-style.md +0 -406
  108. package/dist/docs/product/foundations/iconography.md +0 -282
  109. package/dist/docs/product/foundations/intent.md +0 -360
  110. package/dist/docs/product/foundations/layout.md +0 -508
  111. package/dist/docs/product/foundations/linter.md +0 -523
  112. package/dist/docs/product/foundations/motion.md +0 -151
  113. package/dist/docs/product/foundations/radius-and-padding.md +0 -86
  114. package/dist/docs/product/foundations/typography.md +0 -331
  115. package/dist/docs/product/introduction/faq.md +0 -133
  116. package/dist/docs/product/introduction/getting-started.md +0 -377
  117. package/dist/docs/product/patterns/blockchain-values.md +0 -709
  118. package/dist/docs/product/patterns/dashboards.md +0 -638
  119. package/dist/docs/product/patterns/destructive-actions.md +0 -626
  120. package/dist/docs/product/patterns/empty-states.md +0 -612
  121. package/dist/docs/product/patterns/errors-and-validation.md +0 -808
  122. package/dist/docs/product/patterns/feedback-and-status.md +0 -518
  123. package/dist/docs/product/patterns/forms.md +0 -679
  124. package/dist/docs/product/patterns/loading.md +0 -630
  125. package/dist/docs/product/patterns/navigation.md +0 -397
  126. package/dist/docs/product/patterns/payments.md +0 -765
  127. package/dist/docs/product/patterns/responsive-layout.md +0 -997
  128. package/dist/docs/product/patterns/tables-and-lists.md +0 -1170
  129. package/dist/docs/product/products/tempo-console.md +0 -671
  130. package/dist/docs/product/products/tempo-performance.md +0 -435
  131. package/dist/docs/product/products/tempo-wallet.md +0 -438
@@ -1,86 +0,0 @@
1
- # Radius and Padding
2
-
3
- How corner radius and padding pair, from fields to modals.
4
-
5
- ## Overview
6
-
7
- Corners in Tempo are squircles that ease into each edge. Each kind of element has its own radius, from fields and buttons up to modals, and the radius stays the same at every size of that element.
8
-
9
- Padding keeps content clear of the curve. Boxes and modals pad by their own radius, and corners step down the scale as layers nest.
10
-
11
- ## Scale
12
-
13
- * **Fields, Buttons, and Alerts (xs):** A 12px corner at every size, padded by at least 16px.
14
- * **Boxes and Tiles (sm):** A 16px corner, padded by 16px, as in a list group.
15
- * **Small Modals (md):** A 24px corner, padded by 24px, for one decision.
16
- * **Medium and Large Modals (lg):** A 32px corner, padded by 32px, for longer tasks.
17
- * **Pills (full):** Icon buttons, avatars, and token chips.
18
-
19
- **Do:** Pad a corner by at least its radius, so content sits clear of the curve.
20
-
21
- ```tsx
22
- <RadiusDemo kind="padded" />
23
- ```
24
-
25
- **Don't:** Pad a container by less than its radius.
26
-
27
- ```tsx
28
- <RadiusDemo kind="cramped" />
29
- ```
30
-
31
- ## Squircles
32
-
33
- Every corner is a squircle where the browser supports it, and a round corner of the same radius everywhere else.
34
-
35
- * **Squircle (corner-shape):** Supporting browsers draw each radius token as a squircle.
36
- * **Fallback (border-radius):** Other browsers draw the same token as a round corner.
37
- * **Circles and Pills (full):** Full radius stays round, so circles keep their shape.
38
-
39
- To keep your own circle or pill round, set the round corner shape beside the full radius.
40
-
41
- ```tsx
42
- import { style } from '@tempoxyz/ds'
43
-
44
- namespace styles {
45
- export const badge = style({ borderRadius: 'full', cornerShape: 'round' })
46
- }
47
- ```
48
-
49
- ## Nested Corners
50
-
51
- A layer inside another takes a smaller radius: a modal at 32px holds boxes at 16px, which hold fields at 12px.
52
-
53
- **Do:** Step the radius down at each layer, from modal to box to field.
54
-
55
- ```tsx
56
- <RadiusDemo kind="nested" />
57
- ```
58
-
59
- **Don't:** Repeat the outer radius on the layers inside it.
60
-
61
- ```tsx
62
- <RadiusDemo kind="repeated" />
63
- ```
64
-
65
- ## Corner Controls
66
-
67
- * **Close and Back Buttons (First line):** Align with the title beside them, not with the corner.
68
-
69
- ## Bleed
70
-
71
- * **Edge-Aligned Controls (Up to the padding):** Lines a text button's label up with the content edge.
72
- * **Full-Bleed Content (Exactly the padding):** Lets rows and tables reach both edges of the box.
73
-
74
- ## Related
75
-
76
- [Layout](layout.md)
77
-
78
- Covers the radius, spacing, and shadow scales.
79
-
80
- [Surface](../components/surface.md)
81
-
82
- Use for padded boxes and cards.
83
-
84
- [Dialog](../components/dialog.md)
85
-
86
- Use for modals.
@@ -1,331 +0,0 @@
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 and its numbers, Pilat gives titles 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, table cells, and numbers.
26
- * **Pilat (100 to 900):** Page, dialog, section, card, and hero titles only.
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 in Pilat, in light and regular weights that let size carry the emphasis.
36
-
37
- * `display.d1`: Pilat, 44px, weight 300, line height 41.8px
38
- * `display.d2`: Pilat, 36px, weight 400, line height 34.2px
39
-
40
- ### Value
41
-
42
- Large readings in Inter, such as a balance, with tight tracking so the digits read as one figure.
43
-
44
- * `value.v1`: Inter, 80px, weight 400, line height normal
45
- * `value.v2`: Inter, 52px, weight 400, line height normal
46
- * `value.v3`: Inter, 40px, weight 400, line height normal
47
-
48
- ### Heading
49
-
50
- Page, dialog, section, and card titles, in Pilat at a medium weight. Only the heading and display sets use Pilat. Tracking tightens as the size grows, so large titles stay compact.
51
-
52
- * `heading.h1`: Pilat, 32px, weight 500, line height 36.8px
53
- * `heading.h2`: Pilat, 24px, weight 500, line height 27.6px
54
- * `heading.h3`: Pilat, 20px, weight 500, line height 23px
55
- * `heading.h4`: Pilat, 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`: Inter, 16px, weight 400, line height 22px
62
- * `body.b1Strong`: Inter, 16px, weight 500, line height 22px
63
- * `body.b2`: Inter, 14px, weight 400, line height 20px
64
- * `body.b2Strong`: Inter, 14px, weight 500, line height 20px
65
- * `body.b3`: Inter, 12px, weight 400, line height 16px
66
- * `body.b3Strong`: Inter, 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`: JetBrains Mono, 12px, weight 400, line height 16px
85
- * `utility.m2`: JetBrains Mono, 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](content/writing-style.md#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 (value):** One balance or reading per screen, in Inter.
132
-
133
- ### Reserve Pilat for Titles
134
-
135
- Pilat sets titles only: page, dialog, section, and card titles in the heading sets, and hero titles in the display sets, from 18px up. Inter sets everything else, including labels, tabs, toasts, buttons, and numbers.
136
-
137
- **Do:** Set the title in Pilat and the text below it in Inter.
138
-
139
- ```tsx
140
- <Surface.Title>Recent payments</Surface.Title>
141
- <TypeDemo kind="body" />
142
- ```
143
-
144
- **Don't:** Set Pilat on labels, tabs, toasts, or numbers, or below 18px.
145
-
146
- ```tsx
147
- <Snippet size="small">{"fontFamily: 'heading'"}</Snippet>
148
- ```
149
-
150
- ### Use Five Styles per Screen
151
-
152
- Dense screens, such as consoles and internal tools, use at most five styles. Add `mono.m1` as a sixth only where the screen shows hex values or code.
153
-
154
- * **Page Title (heading.h2):** One per screen, in Pilat.
155
- * **Section Title (heading.h3):** Sections, cards, and dialogs, in Pilat.
156
- * **Body (body.b2):** Text, table cells, and descriptions.
157
- * **Strong (body.b2Strong):** Labels, buttons, and emphasis.
158
- * **Meta (body.b3):** Timestamps, hints, and secondary details.
159
- * **Hex and Code (mono.m1):** The sixth style, only for hex values and code.
160
-
161
- * **Families (2 per screen):** Inter and Pilat, plus mono only for hex and code.
162
- * **Content Sizes (3 per screen):** Below the titles, use weight and color before size.
163
-
164
- ### Let Components Set Their Type
165
-
166
- Components set the type of their own parts, such as a field label, a table cell, or a button. Pass text as children, and don't restyle it.
167
-
168
- * **Component Text (children):** Pass plain text. The component applies its set and color.
169
- * **Your Own Text (typography):** Choose a set by role, from the five styles above.
170
-
171
- ### Set Type With One Set
172
-
173
- Set your own text with one `typography` set. Don't combine a family, size, or weight from different sets, which renders a style that the designs don't define. The [Linter](linter.md#set-type-with-a-typography-set) reports these.
174
-
175
- **Do:** Set the role as one set.
176
-
177
- ```tsx
178
- <Snippet size="small" style={{ width: 240 }}>
179
- {"typography: 'body.b2'"}
180
- </Snippet>
181
- ```
182
-
183
- **Don't:** Build or adjust a style with separate type properties.
184
-
185
- ```tsx
186
- <Snippet size="small" style={{ width: 240 }}>
187
- {"fontWeight: '600 !custom'"}
188
- </Snippet>
189
- ```
190
-
191
- ### Reserve the Expressive Sets
192
-
193
- * **Display (display):** One hero title per screen, in Pilat. Never in cards, tables, or dialogs.
194
- * **Value (value):** One headline reading per screen, in Inter. Not for a row of metrics.
195
- * **Utility (utility):** A metadata label above a value. No other text uses all caps.
196
- * **Mono (mono):** Hex values and code only. Not for numbers, amounts, dates, or labels.
197
-
198
- ### Use Tabular Figures for Numbers
199
-
200
- Tabular figures align digits in columns and keep live values from shifting. [Amount](../components/amount.md), [NumberField](../components/number-field.md), [Slider](../components/slider.md), and numeric table cells already set them.
201
-
202
- **Do:** Align amounts with tabular figures, such as `Amount` with `align="right"`.
203
-
204
- ```tsx
205
- /**
206
- * Do example for "Use Tabular Figures for Numbers" on the Typography page.
207
- * Align amounts with tabular figures, such as `Amount` with `align="right"`.
208
- * @module
209
- */
210
- import { Amount, style } from '@tempoxyz/ds'
211
-
212
- /** Renders the static preview, which the guideline card shows inert. */
213
- export function Demo() {
214
- return (
215
- <div {...styles.column()}>
216
- <Amount align="right" symbol="PathUSD" value="1111.11" />
217
- <Amount align="right" symbol="PathUSD" value="8808.80" />
218
- <Amount align="right" symbol="PathUSD" value="4170.25" />
219
- </div>
220
- )
221
- }
222
-
223
- namespace styles {
224
- export const column = style({ display: 'grid', gap: '8', width: '12rem !custom' })
225
- }
226
- ```
227
-
228
- **Don't:** Stack amounts in proportional figures, where digits drift out of line.
229
-
230
- ```tsx
231
- /**
232
- * Don't example for "Use Tabular Figures for Numbers" on the Typography page.
233
- * Don't stack amounts in proportional figures, where digits drift out of line.
234
- * @module
235
- */
236
- import { style } from '@tempoxyz/ds'
237
-
238
- /** Renders the static preview, which the guideline card shows inert. */
239
- export function Demo() {
240
- return (
241
- <div {...styles.column()}>
242
- <span {...styles.amount()}>1,111.11 PathUSD</span>
243
- <span {...styles.amount()}>8,808.80 PathUSD</span>
244
- <span {...styles.amount()}>4,170.25 PathUSD</span>
245
- </div>
246
- )
247
- }
248
-
249
- namespace styles {
250
- export const amount = style({
251
- color: 'content.primary',
252
- fontVariantNumeric: 'proportional-nums !custom',
253
- textAlign: 'right',
254
- typography: 'body.b2Strong',
255
- })
256
-
257
- export const column = style({ display: 'grid', gap: '8', width: '12rem !custom' })
258
- }
259
- ```
260
-
261
- If you render a number yourself, such as a metric tile, set tabular figures in its style.
262
-
263
- ```tsx
264
- style({ fontVariantNumeric: 'tabular-nums !custom' })
265
- ```
266
-
267
- ### Use Monospace for Hashes and Code
268
-
269
- Set addresses, hashes, keys, and code in monospace, so similar characters stay distinct and equal-length values align. [Hex](../components/hex.md), [Snippet](../components/snippet.md), and [SecretValue](../components/secret-value.md) apply it. Labels and prose stay out of it.
270
-
271
- **Do:** Set hashes in `mono.m1`, so they align and `I`, `l`, `0`, and `O` stay distinct.
272
-
273
- ```tsx
274
- /**
275
- * Do example for "Use Monospace for Hashes and Code" on the Typography page.
276
- * Set hashes in a `.mono` set, so they align and `I`, `l`, `0`, and `O` stay distinct.
277
- * @module
278
- */
279
- import { style } from '@tempoxyz/ds'
280
-
281
- /** Renders the static preview, which the guideline card shows inert. */
282
- export function Demo() {
283
- return (
284
- <div {...styles.column()}>
285
- <span {...styles.value()}>0x1f0a9c3e7b11d4e0</span>
286
- <span {...styles.value()}>0x8d1Il0O4e2b7a96c</span>
287
- <span {...styles.value()}>0x7777a1b2c3d4e5f6</span>
288
- </div>
289
- )
290
- }
291
-
292
- namespace styles {
293
- export const column = style({ display: 'grid', gap: '8' })
294
-
295
- export const value = style({ color: 'content.primary', typography: 'mono.m1' })
296
- }
297
- ```
298
-
299
- **Don't:** Set hashes in a proportional set, where equal-length values drift apart.
300
-
301
- ```tsx
302
- /**
303
- * Don't example for "Use Monospace for Hashes and Code" on the Typography page.
304
- * Don't set hashes in a proportional set, where equal-length values drift apart.
305
- * @module
306
- */
307
- import { style } from '@tempoxyz/ds'
308
-
309
- /** Renders the static preview, which the guideline card shows inert. */
310
- export function Demo() {
311
- return (
312
- <div {...styles.column()}>
313
- <span {...styles.value()}>0x1f0a9c3e7b11d4e0</span>
314
- <span {...styles.value()}>0x8d1Il0O4e2b7a96c</span>
315
- <span {...styles.value()}>0x7777a1b2c3d4e5f6</span>
316
- </div>
317
- )
318
- }
319
-
320
- namespace styles {
321
- export const column = style({ display: 'grid', gap: '8' })
322
-
323
- export const value = style({ color: 'content.primary', typography: 'body.b3' })
324
- }
325
- ```
326
-
327
- ### Keep Lines Readable
328
-
329
- * **Line Length (45 to 75 characters):** Cap paragraphs with `maxWidth: '65ch !custom'`. Dialogs already cap their width.
330
- * **Alignment:** Left-align text. Center only short text, such as an empty state title.
331
- * **Minimum Size (12px):** Don't set interface text smaller. The smallest body set, `body.b3`, stops here.
@@ -1,133 +0,0 @@
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
- | A marketing website | Marketing | `@tempoxyz/ds/marketing` |
16
-
17
- Web components render DOM elements and compile with a Zyzz bundler plugin. Mobile components render React Native views and compile with Metro. [Getting Started](getting-started.md) shows each setup.
18
-
19
- ### Do I Need to Import a Stylesheet?
20
-
21
- No. The library publishes no stylesheet.
22
-
23
- * **Vite:** The [Vite plugin](getting-started.md#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.
24
- * **Rollup, Webpack, and esbuild:** The adapters emit a generated `/zyzz.css` that you load once.
25
- * **Mobile:** Metro compiles library and app styles during the bundle.
26
-
27
- The Zyzz plugin is the only supported web setup.
28
-
29
- ### How Do I Style My Own Markup?
30
-
31
- 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.
32
-
33
- If your app needs its own tokens, extend `variables` in your own Zyzz config, as the Custom Variables setup in [Getting Started](getting-started.md#setup) shows.
34
-
35
- ## Components
36
-
37
- ### Can I Change How a Component Looks?
38
-
39
- Use the component's props first, such as `variant` and `size`.
40
-
41
- * **Web:** Components accept `className` and `style`, and keep your classes beside their own.
42
- * **Mobile:** Components accept React Native `style`. Import variables from `@tempoxyz/ds/mobile`.
43
-
44
- 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.
45
-
46
- ### What If the Library Doesn't Have the Component I Need?
47
-
48
- 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.
49
-
50
- ### How Do I Request a Component, Variant, or Token?
51
-
52
- Open an issue in the Design System project in Linear. Include:
53
-
54
- * The use case.
55
- * The proposed contract, such as props, variants, or token names.
56
- * Links to the relevant Figma designs.
57
- * Consumer code or a pull request that shows the need.
58
-
59
- If an issue already covers the proposal, reuse it. A proposal joins `@tempoxyz/ds` after designer approval and an approved Figma definition.
60
-
61
- ### Why Isn't a Figma Component in the Library?
62
-
63
- The library includes only components with a verified production family in Figma. Archived and experimental Figma components stay out until a production version exists.
64
-
65
- The [Components](../components.md) overview lists what ships today. Sidebar pages marked 🚧 are not written yet.
66
-
67
- ### Which Components Exist on Mobile?
68
-
69
- `@tempoxyz/ds/mobile` has a smaller set, and some names differ from web.
70
-
71
- | Mobile | Web counterpart |
72
- | ------------ | --------------------------------------------------------------------------------- |
73
- | `Avatar` | [Avatar](../components/avatar.md) |
74
- | `Badge` | [Badge](../components/badge.md) |
75
- | `Button` | [Button](../components/button.md) |
76
- | `CodeInput` | [OtpField](../components/otp-field.md) |
77
- | `IconButton` | [Button](../components/button.md) with `shape="icon"` |
78
- | `Skeleton` | [Skeleton](../components/skeleton.md) |
79
- | `Spinner` | [Spinner](../components/spinner.md) |
80
- | `TextButton` | [Button](../components/button.md) with `variant="tertiary"` |
81
- | `TextInput` | [TextInput](../components/text-input.md) inside a [Field](../components/field.md) |
82
- | `Toast` | [Toast](../components/toast.md) |
83
- | `Toggle` | [Switch](../components/switch.md) |
84
-
85
- ### Do Web Components Work in Mobile Browsers?
86
-
87
- Yes. [Responsive Layout](../patterns/responsive-layout.md) shows how to adapt a layout from a phone to a desktop.
88
-
89
- ## Design
90
-
91
- ### How Do Light and Dark Schemes Work?
92
-
93
- Every color has a light and a dark value, so you write each color once.
94
-
95
- * **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.
96
- * **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"`.
97
-
98
- The library does not store a scheme preference. If your app offers a theme setting, persist the choice yourself.
99
-
100
- ### Which Is Right When Figma and Code Disagree?
101
-
102
- Figma is the design reference. Variables, icons, and components are maintained by hand, so the two can drift.
103
-
104
- 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.
105
-
106
- ### Where Are the Figma Files?
107
-
108
- The Figma files define every variable, icon, and component:
109
-
110
- * [TPDS 1.0 Platform](https://www.figma.com/design/yE96kcymnNR88PJp6G1sPs/TPDS-1.0-Platform) for Web variables and components
111
- * [TDS Platform](https://www.figma.com/design/pcO4NIuw8wx9U2nGJOcjzE) for Web icons
112
- * [TDS App](https://www.figma.com/design/8iu5856rBEI3pnZ6YaIBgw) for Mobile, whose families the mobile components implement
113
-
114
- ## Docs
115
-
116
- ### How Do I Report a Docs Issue?
117
-
118
- On wide screens, On this page includes two actions:
119
-
120
- * **Report issue:** Opens a GitHub issue titled with the page name and its path.
121
- * **Edit page:** Opens the MDX source of the page on GitHub.
122
-
123
- On narrower screens, use the GitHub link at the bottom of the sidebar.
124
-
125
- ### How Should Coding Agents Use These Docs?
126
-
127
- Every page has a Markdown twin, `/llms.txt` indexes them all, and the library documents each export in its source. [Agents](../foundations/agents.md) lists the files and the rules an agent follows when it generates Tempo UI.
128
-
129
- ## License
130
-
131
- ### How Is the Library Licensed?
132
-
133
- The library is open source under the [MIT license](https://github.com/tempoxyz/ds/blob/main/LICENSE-MIT).