@mastra/playground-ui 29.0.0-alpha.2 → 29.0.0-alpha.4

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/CHANGELOG.md CHANGED
@@ -1,5 +1,108 @@
1
1
  # @mastra/playground-ui
2
2
 
3
+ ## 29.0.0-alpha.4
4
+
5
+ ### Minor Changes
6
+
7
+ - Refreshed Button + Card design system tokens. ([#16769](https://github.com/mastra-ai/mastra/pull/16769))
8
+
9
+ **Button variants (breaking)**: consolidated to `default`, `primary`, `outline`, `ghost`. The `cta`, `contrast`, and unused `link` variants have been removed. `primary` now uses a high-contrast `neutral6` fill instead of `surface4`, so it reads clearly as the form submit action in both themes.
10
+
11
+ ```tsx
12
+ // Before
13
+ <Button variant="cta">Save</Button>
14
+ <Button variant="contrast">Done</Button>
15
+ <Button variant="link">Open</Button>
16
+
17
+ // After
18
+ <Button variant="primary">Save</Button> // cta → primary (no brand green; theme-aware high contrast)
19
+ <Button variant="primary">Done</Button> // contrast → primary (same recipe, renamed)
20
+ <Button as="a" href="…" variant="ghost">Open</Button> // link → ghost (or plain <a> for inline text links)
21
+ ```
22
+
23
+ **New tokens**: `--surface-overlay-soft` and `--surface-overlay-strong` — alpha overlays of the opposite-theme color, used by `SectionCard` header strip and `DashboardCard` fill so cards read consistently on any surface.
24
+
25
+ **Other**:
26
+ - DashboardCard radius reduced to `rounded-xl` and padding tightened to `px-4 py-3` for better grid density.
27
+ - SectionCard wrapper no longer fills its background — header strip + border carry definition.
28
+ - Dark `surface2` / `surface3` darkened slightly (16.84% → 16%, 19.13% → 18%) so the main frame reads as a distinct surface.
29
+ - Dark `border1` / `border2` alphas bumped (6% → 7%, 10% → 11%) for closer dark/light parity.
30
+ - Removed deprecated `--section-card-*` tokens and their `@utility` blocks.
31
+
32
+ ### Patch Changes
33
+
34
+ - Updated dependencies [[`c272d50`](https://github.com/mastra-ai/mastra/commit/c272d50610a54496b6b6d92ccd4d37b333a2613a), [`d8692af`](https://github.com/mastra-ai/mastra/commit/d8692afa253028e39cdce2aafa0ac414071a762e), [`841a222`](https://github.com/mastra-ai/mastra/commit/841a222560d8c19238f8213713f30535cdd82284)]:
35
+ - @mastra/core@1.36.0-alpha.4
36
+ - @mastra/client-js@1.20.0-alpha.4
37
+ - @mastra/react@0.4.0-alpha.4
38
+
39
+ ## 29.0.0-alpha.3
40
+
41
+ ### Minor Changes
42
+
43
+ - Removed `ButtonWithTooltip` from `@mastra/playground-ui`. Use `Button` with the `tooltip` prop instead. ([#16719](https://github.com/mastra-ai/mastra/pull/16719))
44
+
45
+ **Migration**
46
+
47
+ ```tsx
48
+ // before
49
+ import { ButtonWithTooltip } from '@mastra/playground-ui';
50
+
51
+ <ButtonWithTooltip tooltipContent="Search">
52
+ <Search />
53
+ </ButtonWithTooltip>;
54
+
55
+ // after
56
+ import { Button } from '@mastra/playground-ui';
57
+
58
+ <Button tooltip="Search">
59
+ <Search />
60
+ </Button>;
61
+ ```
62
+
63
+ `tooltip` supports the same values as `tooltipContent`. Icon-only buttons that pass a string `tooltip` now also get it as their `aria-label` automatically, matching how labelled controls have always behaved. Pass an explicit `aria-label` to override.
64
+
65
+ ### Patch Changes
66
+
67
+ - The Traces list now updates live via delta polling. Previously the list was refetched every 10 seconds, replacing the whole page with no signal about what changed; now new traces appear within a few seconds of being created, with a brief highlight to draw attention. Status changes on already-visible rows (running → success / error) also propagate without intervention, and returning to the tab after being idle re-syncs from a fresh cursor. ([#16727](https://github.com/mastra-ai/mastra/pull/16727))
68
+
69
+ **New `useTraces` return fields**
70
+ - `isRefetching` — true while any meaningful refetch is in flight. Use it to drive a heartbeat indicator.
71
+ - `autoRefetch` / `setAutoRefetch` — pause / resume all automatic polling so the consumer can render an opt-out toggle.
72
+ - `recentlyAddedKeys` — `Set<string>` of `traceId:spanId` for rows that just arrived via delta polling. Drives the temporary highlight in `TracesListView`.
73
+
74
+ **New polling config**
75
+
76
+ Every timing in the hook is tunable per-instance via a new `polling` option:
77
+
78
+ ```ts
79
+ import { useTraces, type TracesPollingConfig } from '@mastra/playground-ui';
80
+
81
+ useTraces({
82
+ filters,
83
+ listMode,
84
+ polling: {
85
+ deltaPollIntervalMs: 10_000,
86
+ idleGuardThresholdMs: 5 * 60_000,
87
+ },
88
+ });
89
+ ```
90
+
91
+ Omitted fields fall through to the defaults (delta poll every 5s, idle reset after 15 min, status refresh every 60s, etc).
92
+
93
+ **TracesListView**
94
+
95
+ New optional `recentlyAddedKeys?: Set<string>` prop. Rows whose `traceId:spanId` is in the set get the `animate-row-highlight` class — a brief fade-out to transparent, added to `index.css`.
96
+
97
+ **Compatibility**
98
+
99
+ Requires `@mastra/server` and `@mastra/client-js` at the versions that ship the observability delta-polling endpoints, and a store that opts into delta polling (`@mastra/clickhouse`, `@mastra/duckdb`, and the in-memory store today). When unavailable — older server or a store without delta capability — the hook silently falls back to page-mode interval refetching. No consumer changes required.
100
+
101
+ - Updated dependencies [[`5556cc1`](https://github.com/mastra-ai/mastra/commit/5556cc1befec71518d84f826b3bfe3a079a9daf7), [`5499303`](https://github.com/mastra-ai/mastra/commit/54993032c1ebc09642625b78d2014e0cf84a3cae), [`3498b49`](https://github.com/mastra-ai/mastra/commit/3498b4946be94f4313cd817733589680dcda5278), [`e47bca7`](https://github.com/mastra-ai/mastra/commit/e47bca7b72866d3abd173b9f530ac4318113a8ff), [`0031d0f`](https://github.com/mastra-ai/mastra/commit/0031d0f13831d7843ac5d498734a7d92862e2ce3), [`3498b49`](https://github.com/mastra-ai/mastra/commit/3498b4946be94f4313cd817733589680dcda5278), [`359439b`](https://github.com/mastra-ai/mastra/commit/359439bb8c635e048176306828195f8297f50021)]:
102
+ - @mastra/core@1.36.0-alpha.3
103
+ - @mastra/client-js@1.20.0-alpha.3
104
+ - @mastra/react@0.4.0-alpha.3
105
+
3
106
  ## 29.0.0-alpha.2
4
107
 
5
108
  ### Patch Changes