@heyramzi/ui 6.0.1 → 7.0.0

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 (114) hide show
  1. package/COMPONENTS.md +7 -26
  2. package/README.md +12 -5
  3. package/package.json +14 -16
  4. package/scripts/sync-shadcn.mjs +12 -3
  5. package/src/agents/agent-avatar.svelte +639 -0
  6. package/src/agents/agent-cast.svelte +173 -0
  7. package/src/agents/demo.svelte +78 -0
  8. package/src/agents/index.ts +11 -0
  9. package/src/agents/types.ts +72 -0
  10. package/{LICENSE → src/agents/vendor/LICENSE} +1 -1
  11. package/src/agents/vendor/color.ts +155 -0
  12. package/src/agents/vendor/draw.ts +840 -0
  13. package/src/agents/vendor/engine.ts +845 -0
  14. package/src/agents/vendor/mesh.ts +838 -0
  15. package/src/agents/vendor/plastic.ts +4958 -0
  16. package/src/agents/vendor/presets.ts +103 -0
  17. package/src/agents/vendor/shapes.ts +41 -0
  18. package/src/agents/vendor/ticker.ts +67 -0
  19. package/src/agents/vendor/types.ts +261 -0
  20. package/src/agents/vendor/wear.ts +1699 -0
  21. package/src/ai/index.ts +0 -18
  22. package/src/animations/README.md +3 -3
  23. package/src/lib/sliding-pill.ts +68 -0
  24. package/src/lib/theme-transition.ts +4 -2
  25. package/src/shadcn/code-block/code-block-actions.svelte +23 -0
  26. package/src/shadcn/code-block/code-block-content.svelte +55 -0
  27. package/src/shadcn/code-block/code-block-copy-button.svelte +59 -0
  28. package/src/shadcn/code-block/code-block-footer.svelte +20 -0
  29. package/src/shadcn/code-block/code-block-header.svelte +23 -0
  30. package/src/shadcn/code-block/code-block-line.svelte +71 -0
  31. package/src/shadcn/code-block/code-block-title.svelte +23 -0
  32. package/src/shadcn/code-block/code-block.svelte +47 -0
  33. package/src/shadcn/code-block/index.ts +42 -0
  34. package/src/shadcn/hooks/highlighter.ts +132 -0
  35. package/src/shadcn/hooks/use-highlighted-code.svelte.ts +98 -0
  36. package/src/shadcn/kbd/index.ts +10 -0
  37. package/src/shadcn/kbd/kbd-group.svelte +20 -0
  38. package/src/shadcn/kbd/kbd.svelte +23 -0
  39. package/src/shadcn/message-scroller/index.ts +28 -0
  40. package/src/shadcn/message-scroller/message-scroller-button.svelte +52 -0
  41. package/src/shadcn/message-scroller/message-scroller-content.svelte +17 -0
  42. package/src/shadcn/message-scroller/message-scroller-item.svelte +22 -0
  43. package/src/shadcn/message-scroller/message-scroller-provider.svelte +7 -0
  44. package/src/shadcn/message-scroller/message-scroller-viewport.svelte +20 -0
  45. package/src/shadcn/message-scroller/message-scroller.svelte +20 -0
  46. package/src/shadcn/tabs/tabs-list.svelte +13 -2
  47. package/src/shadcn/tabs/tabs-trigger.svelte +1 -1
  48. package/src/shadcn/trace/index.ts +29 -0
  49. package/src/shadcn/trace/trace-collapsible-content.svelte +29 -0
  50. package/src/shadcn/trace/trace-collapsible-trigger.svelte +29 -0
  51. package/src/shadcn/trace/trace-collapsible.svelte +20 -0
  52. package/src/shadcn/trace/trace-description.svelte +20 -0
  53. package/src/shadcn/trace/trace-icon.svelte +24 -0
  54. package/src/shadcn/trace/trace-line.svelte +31 -0
  55. package/src/shadcn/trace/trace-title.svelte +20 -0
  56. package/src/shadcn/trace/trace.svelte +23 -0
  57. package/src/showcase/AiSection.svelte +0 -7
  58. package/src/showcase/demos/shadcn/code-block.svelte +80 -0
  59. package/src/showcase/demos/shadcn/index.ts +24 -0
  60. package/src/showcase/demos/shadcn/message-scroller.svelte +44 -0
  61. package/src/showcase/demos/shadcn/trace.svelte +51 -0
  62. package/src/showcase/kit.ts +1 -2
  63. package/src/ai/conversation/Conversation.svelte +0 -28
  64. package/src/ai/conversation/ConversationContent.svelte +0 -35
  65. package/src/ai/conversation/ConversationEmptyState.svelte +0 -46
  66. package/src/ai/conversation/ConversationScrollButton.svelte +0 -51
  67. package/src/ai/conversation/index.ts +0 -33
  68. package/src/ai/conversation/stick-to-bottom-context.svelte.ts +0 -131
  69. package/src/charts/animated-value.css +0 -7
  70. package/src/charts/animated-value.svelte +0 -110
  71. package/src/charts/area-chart.css +0 -29
  72. package/src/charts/area-chart.svelte +0 -195
  73. package/src/charts/bar-chart.css +0 -119
  74. package/src/charts/bar-chart.svelte +0 -269
  75. package/src/charts/charts.css +0 -201
  76. package/src/charts/crosshair.svelte +0 -35
  77. package/src/charts/donut-chart.css +0 -56
  78. package/src/charts/donut-chart.svelte +0 -158
  79. package/src/charts/edge-fade.svelte +0 -43
  80. package/src/charts/edge-fade.ts +0 -16
  81. package/src/charts/figure.css +0 -100
  82. package/src/charts/figure.svelte +0 -122
  83. package/src/charts/gauge-chart.css +0 -94
  84. package/src/charts/gauge-chart.svelte +0 -303
  85. package/src/charts/hover-band.test.ts +0 -30
  86. package/src/charts/hover-band.ts +0 -21
  87. package/src/charts/hover-focus.svelte +0 -85
  88. package/src/charts/index.ts +0 -30
  89. package/src/charts/legend.css +0 -131
  90. package/src/charts/legend.svelte +0 -112
  91. package/src/charts/line-chart.css +0 -26
  92. package/src/charts/line-chart.svelte +0 -256
  93. package/src/charts/motion.ts +0 -19
  94. package/src/charts/number-chart.css +0 -168
  95. package/src/charts/number-chart.svelte +0 -177
  96. package/src/charts/primitives/chart-container.svelte +0 -57
  97. package/src/charts/primitives/chart-style.svelte +0 -36
  98. package/src/charts/primitives/chart-tooltip.svelte +0 -161
  99. package/src/charts/primitives/chart-utils.ts +0 -54
  100. package/src/charts/primitives/index.ts +0 -11
  101. package/src/charts/reveal.svelte +0 -61
  102. package/src/charts/ring-chart.css +0 -96
  103. package/src/charts/ring-chart.svelte +0 -158
  104. package/src/charts/sparkline.css +0 -45
  105. package/src/charts/sparkline.svelte +0 -140
  106. package/src/charts/stat-card.css +0 -103
  107. package/src/charts/stat-card.svelte +0 -267
  108. package/src/charts/time-series-chart.css +0 -28
  109. package/src/charts/time-series-chart.svelte +0 -179
  110. package/src/charts/trend-pill.css +0 -38
  111. package/src/charts/trend-pill.svelte +0 -48
  112. package/src/lib/hooks/is-mobile.svelte.ts +0 -11
  113. package/src/showcase/ChartsSection.svelte +0 -458
  114. package/src/showcase/demos/ai/conversation.svelte +0 -59
@@ -1,458 +0,0 @@
1
- <!-- ========================== -->
2
- <!-- IMPORTS -->
3
- <!-- ========================== -->
4
- <script lang="ts">
5
- import {
6
- AreaChart,
7
- BarChart,
8
- DonutChart,
9
- GaugeChart,
10
- Legend,
11
- LineChart,
12
- NumberChart,
13
- RingChart,
14
- Sparkline,
15
- StatCard,
16
- } from "../charts/index.js";
17
- import ShowcaseStage from "./ShowcaseStage.svelte";
18
- import ShowcaseVariant from "./ShowcaseVariant.svelte";
19
-
20
- // =========================
21
- // STATE
22
- // =========================
23
- const monthly = [
24
- { month: "Jan", revenue: 4200, costs: 2800 },
25
- { month: "Feb", revenue: 5100, costs: 3100 },
26
- { month: "Mar", revenue: 4800, costs: 2950 },
27
- { month: "Apr", revenue: 6200, costs: 3400 },
28
- { month: "May", revenue: 7100, costs: 3600 },
29
- { month: "Jun", revenue: 6800, costs: 3500 },
30
- ];
31
-
32
- const distribution = [
33
- { label: "Search", users: 420, color: "var(--chart-1)" },
34
- { label: "Direct", users: 310, color: "var(--chart-2)" },
35
- { label: "Social", users: 180, color: "var(--chart-3)" },
36
- { label: "Email", users: 90, color: "var(--chart-4)" },
37
- ];
38
-
39
- const channels = [
40
- { label: "Organic", value: 4250, maxValue: 5000, color: "var(--chart-1)" },
41
- { label: "Paid", value: 3120, maxValue: 5000, color: "var(--chart-2)" },
42
- { label: "Email", value: 2100, maxValue: 5000, color: "var(--chart-3)" },
43
- { label: "Social", value: 1580, maxValue: 5000, color: "var(--chart-4)" },
44
- ];
45
- let ringHover = $state<number | null>(null);
46
-
47
- const sparkSeries = Array.from({ length: 24 }, (_, i) => ({
48
- i,
49
- v: 50 + Math.sin(i / 2) * 20 + Math.random() * 10,
50
- }));
51
-
52
- // Rising 12-month series for the stat-card hero (bklit-style).
53
- const revenueTrend = [
54
- { month: "Jan", revenue: 4700 },
55
- { month: "Feb", revenue: 5200 },
56
- { month: "Mar", revenue: 4950 },
57
- { month: "Apr", revenue: 4780 },
58
- { month: "May", revenue: 5600 },
59
- { month: "Jun", revenue: 6100 },
60
- { month: "Jul", revenue: 5900 },
61
- { month: "Aug", revenue: 6400 },
62
- { month: "Sep", revenue: 7200 },
63
- { month: "Oct", revenue: 6950 },
64
- { month: "Nov", revenue: 7600 },
65
- { month: "Dec", revenue: 8200 },
66
- ];
67
-
68
- // Smooth, gently rising session series for the line stat card (no noise so
69
- // curveBasis reads as flowing waves rather than spikes).
70
- const sessions = Array.from({ length: 16 }, (_, i) => ({
71
- i,
72
- v: 1080 + Math.sin(i / 2.1) * 110 + i * 16,
73
- }));
74
- </script>
75
-
76
- <!-- ========================== -->
77
- <!-- MARKUP -->
78
- <!-- ========================== -->
79
- <header class="group-head">
80
- <h2 class="group-title">Charts</h2>
81
- <p class="group-note">Visualisation primitives. Drop into any layout.</p>
82
- </header>
83
- <div class="grid">
84
- <ShowcaseStage
85
- title="BarChart"
86
- note="single series, vertical"
87
- importPath={"import { BarChart } from '@heyramzi/ui/charts';"}
88
- >
89
- <div class="full">
90
- <BarChart data={monthly} xKey="month" yKey="revenue" color="var(--chart-1)" />
91
- </div>
92
- </ShowcaseStage>
93
-
94
- <ShowcaseStage
95
- title="AreaChart"
96
- note="multi-series stacked, distinct colors"
97
- importPath={"import { AreaChart } from '@heyramzi/ui/charts';"}
98
- >
99
- <div class="full">
100
- <AreaChart
101
- data={monthly}
102
- xKey="month"
103
- series={[
104
- { key: "revenue", label: "Revenue", color: "var(--chart-1)" },
105
- { key: "costs", label: "Costs", color: "var(--chart-2)" },
106
- ]}
107
- stacked
108
- />
109
- </div>
110
- </ShowcaseStage>
111
-
112
- <ShowcaseStage
113
- title="LineChart"
114
- note="gradient fill, point markers, dashed in-progress tail"
115
- importPath={"import { LineChart } from '@heyramzi/ui/charts';"}
116
- >
117
- <div class="full">
118
- <LineChart
119
- data={monthly}
120
- xKey="month"
121
- yKey="revenue"
122
- color="var(--chart-1)"
123
- showMarkers
124
- dashFromIndex={4}
125
- />
126
- </div>
127
- </ShowcaseStage>
128
-
129
- <ShowcaseStage
130
- title="DonutChart"
131
- note="explicit colors per slice"
132
- importPath={"import { DonutChart } from '@heyramzi/ui/charts';"}
133
- >
134
- <div class="full">
135
- <DonutChart data={distribution} valueKey="users" labelKey="label" colorKey="color" />
136
- </div>
137
- </ShowcaseStage>
138
-
139
- <ShowcaseStage
140
- title="GaugeChart"
141
- note="notched radial meter, count-up center value, format options"
142
- importPath={"import { GaugeChart } from '@heyramzi/ui/charts';"}
143
- >
144
- <div class="gauge">
145
- <GaugeChart
146
- value={66}
147
- centerValue={428000}
148
- defaultLabel="ARR run rate"
149
- formatOptions={{ style: "currency", currency: "USD", notation: "compact" }}
150
- />
151
- </div>
152
- </ShowcaseStage>
153
-
154
- <ShowcaseStage
155
- title="RingChart + Legend"
156
- note="concentric progress rings, hover-synced legend with progress bars"
157
- importPath={"import { RingChart, Legend } from '@heyramzi/ui/charts';"}
158
- >
159
- <div class="ring-row">
160
- <div class="ring-slot">
161
- <RingChart data={channels} bind:hoveredIndex={ringHover} defaultLabel="Sessions" />
162
- </div>
163
- <Legend items={channels} bind:hoveredIndex={ringHover} showProgress showPercentage />
164
- </div>
165
- </ShowcaseStage>
166
-
167
- <ShowcaseStage
168
- title="Legend"
169
- note="standalone: progress bars, percentages, hover-dim, keyboard focus"
170
- importPath={"import { Legend } from '@heyramzi/ui/charts';"}
171
- >
172
- <div class="full">
173
- <Legend title="Traffic by channel" items={channels} showProgress showPercentage />
174
- </div>
175
- </ShowcaseStage>
176
-
177
- <ShowcaseStage
178
- title="Sparkline"
179
- note="a trendline the width of whatever holds it"
180
- importPath={"import { Sparkline } from '@heyramzi/ui/charts';"}
181
- >
182
- <ShowcaseVariant label="showLast: end-cap dot and inline value">
183
- <div class="full">
184
- <Sparkline data={sparkSeries} xKey="i" yKey="v" color="var(--chart-1)" showLast />
185
- </div>
186
- </ShowcaseVariant>
187
- <ShowcaseVariant label="bare: no chrome, for the foot of a card that links">
188
- <div class="full">
189
- <Sparkline data={sparkSeries} xKey="i" yKey="v" color="var(--chart-1)" height={48} bare />
190
- </div>
191
- </ShowcaseVariant>
192
- </ShowcaseStage>
193
-
194
- <ShowcaseStage title="Chart tokens" note="Theme charts globally with five CSS custom properties">
195
- <!-- WHY the name sits beside the colour and not on it: five arbitrary palette entries cannot all carry legible text, and a fixed near-black label read -->
196
- <!-- 2.9:1 on --chart-1. A chip plus a label on the ground is AA whatever the token is set to, which is the point of a token showcase. -->
197
- <div class="swatches">
198
- {#each [1, 2, 3, 4, 5] as n (n)}
199
- <div class="swatch">
200
- <span class="swatch-chip" style="background: var(--chart-{n})"></span>
201
- <span class="swatch-name">--chart-{n}</span>
202
- </div>
203
- {/each}
204
- </div>
205
- </ShowcaseStage>
206
- </div>
207
-
208
- <header class="group-head">
209
- <h2 class="group-title">Cards</h2>
210
- <p class="group-note">
211
- Composed KPI blocks: one figure on its own, or a Figure (label, value, trend) over a chart, on a
212
- card.
213
- </p>
214
- </header>
215
- <div class="grid">
216
- <ShowcaseStage
217
- title="NumberChart"
218
- note="a figure on its own, with or without a scale under it"
219
- importPath={"import { NumberChart } from '@heyramzi/ui/charts';"}
220
- >
221
- <ShowcaseVariant label="size=lg: count-up, direction-aware delta">
222
- <div class="full">
223
- <NumberChart
224
- label="Total cash"
225
- value={128400}
226
- delta={6.1}
227
- direction="up-good"
228
- size="lg"
229
- caption="across 4 accounts"
230
- formatOptions={{ style: "currency", currency: "USD", maximumFractionDigits: 0 }}
231
- />
232
- </div>
233
- </ShowcaseVariant>
234
- <ShowcaseVariant label="share: the scale a lone number cannot carry">
235
- <div class="full">
236
- <NumberChart
237
- label="Expenses"
238
- value={41250}
239
- delta={-3.4}
240
- direction="down-good"
241
- share={0.38}
242
- shareLabel="of revenue"
243
- color="var(--chart-4)"
244
- formatOptions={{ style: "currency", currency: "USD", maximumFractionDigits: 0 }}
245
- />
246
- </div>
247
- </ShowcaseVariant>
248
- <ShowcaseVariant label="bare: no chrome, for a figure inside a band or a panel">
249
- <div class="full">
250
- <NumberChart
251
- bare
252
- label="Net income"
253
- value={67150}
254
- delta={0.2}
255
- direction="up-good"
256
- share={0.62}
257
- shareLabel="of revenue"
258
- color="var(--chart-2)"
259
- formatOptions={{ style: "currency", currency: "USD", maximumFractionDigits: 0 }}
260
- />
261
- </div>
262
- </ShowcaseVariant>
263
- </ShowcaseStage>
264
-
265
- <ShowcaseStage
266
- title="StatCard"
267
- note="a Figure over a chart, on a card: three chart kinds"
268
- importPath={"import { StatCard } from '@heyramzi/ui/charts';"}
269
- >
270
- <ShowcaseVariant label="variant=area: edge-to-edge chart, trend pill, count-up value">
271
- <div class="full">
272
- <StatCard
273
- label="Total Revenue"
274
- value={8200}
275
- delta={12.4}
276
- caption="Avg"
277
- data={revenueTrend}
278
- xKey="month"
279
- yKey="revenue"
280
- variant="area"
281
- formatValue={(v) =>
282
- v.toLocaleString("en-US", {
283
- style: "currency",
284
- currency: "USD",
285
- maximumFractionDigits: 0,
286
- })}
287
- />
288
- </div>
289
- </ShowcaseVariant>
290
- <ShowcaseVariant label="variant=line: denser series">
291
- <div class="full">
292
- <StatCard
293
- label="Active sessions"
294
- value={1344}
295
- delta={8.2}
296
- caption="Avg"
297
- data={sessions}
298
- xKey="i"
299
- yKey="v"
300
- variant="line"
301
- color="var(--chart-3)"
302
- />
303
- </div>
304
- </ShowcaseVariant>
305
- <ShowcaseVariant label="variant=bar: negative trend, down state">
306
- <div class="full">
307
- <StatCard
308
- label="Refunds"
309
- value={3500}
310
- delta={-2.8}
311
- caption="vs last month"
312
- data={monthly}
313
- xKey="month"
314
- yKey="costs"
315
- variant="bar"
316
- color="var(--chart-4)"
317
- formatValue={(v) =>
318
- v.toLocaleString("en-US", {
319
- style: "currency",
320
- currency: "USD",
321
- maximumFractionDigits: 0,
322
- })}
323
- />
324
- </div>
325
- </ShowcaseVariant>
326
- </ShowcaseStage>
327
-
328
- <!-- The other two forms drop half the card, so they read together and not as
329
- the tail of a row of three charts. -->
330
- <ShowcaseStage
331
- title="StatCard"
332
- note="the two forms that drop half the card"
333
- importPath={"import { StatCard } from '@heyramzi/ui/charts';"}
334
- >
335
- <ShowcaseVariant label="variant=gauge: figure left, radial gauge right">
336
- <div class="full">
337
- <StatCard
338
- variant="gauge"
339
- label="Deliverables"
340
- caption="2 of 6 complete"
341
- gaugeValue={33}
342
- delta={5}
343
- color="var(--chart-1)"
344
- />
345
- </div>
346
- </ShowcaseVariant>
347
- <ShowcaseVariant label="figureOnly: the bare edge-to-edge chart, no labels">
348
- <div class="full">
349
- <StatCard
350
- figureOnly
351
- data={revenueTrend}
352
- xKey="month"
353
- yKey="revenue"
354
- variant="area"
355
- height={170}
356
- />
357
- </div>
358
- </ShowcaseVariant>
359
- </ShowcaseStage>
360
- </div>
361
-
362
- <!-- ========================== -->
363
- <!-- STYLE -->
364
- <!-- ========================== -->
365
- <style>
366
- .group-head {
367
- display: flex;
368
- flex-direction: column;
369
- gap: 0.125rem;
370
- }
371
- /* WHY: the second group ("Cards") needs breathing room from the grid above it. */
372
- .group-head:not(:first-child) {
373
- margin-top: 2.5rem;
374
- }
375
- .group-title {
376
- font-size: 1.125rem;
377
- font-weight: 600;
378
- letter-spacing: -0.01em;
379
- margin: 0 0 0.125rem;
380
- }
381
- .group-note {
382
- margin: 0 0 1rem;
383
- font-size: 0.8125rem;
384
- color: var(--muted-foreground);
385
- }
386
- /* One demo per row, the rule ShowcaseSection states for `.sc-stack`. A
387
- quarter-width column is also what squeezed the gauge card's title into
388
- its trend pill. */
389
- .grid {
390
- display: grid;
391
- grid-template-columns: minmax(0, 1fr);
392
- column-gap: 1rem;
393
- row-gap: 0;
394
- }
395
-
396
- /*
397
- * Every card in a band starts and ends on the same line. The stage's header and its ground are two tracks of this grid, so a two-line title no longer
398
- */
399
-
400
- /*
401
- * pushes its own card down past its neighbour's. Row gap is zero because the stage's own padding-block already separates the bands, and a subgrid
402
- */
403
-
404
- /*
405
- * inherits the parent's gutters into the tracks it spans.
406
- */
407
- .grid > :global(.sc-stage) {
408
- display: grid;
409
- grid-template-rows: subgrid;
410
- grid-row: span 2;
411
- }
412
-
413
- .full {
414
- width: 100%;
415
- }
416
- .gauge {
417
- display: flex;
418
- justify-content: center;
419
- width: 100%;
420
- }
421
- .gauge :global(.hr-gauge) {
422
- max-width: 240px;
423
- }
424
- .ring-row {
425
- display: flex;
426
- flex-wrap: wrap;
427
- align-items: center;
428
- gap: 1.25rem 1.5rem;
429
- }
430
- .ring-slot {
431
- flex: 0 0 auto;
432
- width: 180px;
433
- }
434
- .ring-row :global(.hr-legend) {
435
- flex: 1 1 160px;
436
- }
437
- .swatches {
438
- display: flex;
439
- flex-direction: column;
440
- gap: 0.375rem;
441
- width: 100%;
442
- }
443
- .swatch {
444
- display: flex;
445
- align-items: center;
446
- gap: 0.625rem;
447
- font-size: 0.75rem;
448
- font-family: ui-monospace, SFMono-Regular, monospace;
449
- color: var(--foreground);
450
- }
451
- .swatch-chip {
452
- width: 2.5rem;
453
- height: 1.25rem;
454
- flex: none;
455
- border-radius: 0.375rem;
456
- box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--border) 65%, transparent);
457
- }
458
- </style>
@@ -1,59 +0,0 @@
1
- <script lang="ts">
2
- import { Conversation, ConversationContent, Response } from "../../../ai/index.js";
3
- import * as Message from "../../../shadcn/message/index.js";
4
- import * as Bubble from "../../../shadcn/bubble/index.js";
5
- import { Button } from "../../../shadcn/button/index.js";
6
- import Copy from "@lucide/svelte/icons/copy";
7
- import RefreshCw from "@lucide/svelte/icons/refresh-cw";
8
- import ThumbsUp from "@lucide/svelte/icons/thumbs-up";
9
-
10
- const answer = `Here's the plan:
11
-
12
- 1. **Extract** \`AnimatedBeam\` into \`@heyramzi/ui\`
13
- 2. **Showcase** it on the Effects page
14
- 3. **Migrate** both apps onto the shared copy
15
-
16
- Want me to start?`;
17
- </script>
18
-
19
- <div class="convo">
20
- <Conversation>
21
- <ConversationContent class="space-y-4 p-1">
22
- <Message.Root align="end">
23
- <Message.Content>
24
- <Bubble.Root variant="default" align="end">
25
- <Bubble.Content>How should I DRY up our beam effects?</Bubble.Content>
26
- </Bubble.Root>
27
- </Message.Content>
28
- </Message.Root>
29
- <Message.Root align="start">
30
- <Message.Content>
31
- <Bubble.Root variant="muted" align="start">
32
- <Bubble.Content><Response content={answer} /></Bubble.Content>
33
- </Bubble.Root>
34
- <Message.Footer>
35
- <Button variant="ghost" size="sm" icon class="size-7" title="Copy">
36
- <Copy class="size-3.5" />
37
- <span class="sr-only">Copy</span>
38
- </Button>
39
- <Button variant="ghost" size="sm" icon class="size-7" title="Regenerate">
40
- <RefreshCw class="size-3.5" />
41
- <span class="sr-only">Regenerate</span>
42
- </Button>
43
- <Button variant="ghost" size="sm" icon class="size-7" title="Good answer">
44
- <ThumbsUp class="size-3.5" />
45
- <span class="sr-only">Good answer</span>
46
- </Button>
47
- </Message.Footer>
48
- </Message.Content>
49
- </Message.Root>
50
- </ConversationContent>
51
- </Conversation>
52
- </div>
53
-
54
- <style>
55
- .convo {
56
- height: 17rem;
57
- width: 100%;
58
- }
59
- </style>