@mastra/playground-ui 7.0.0-beta.23 → 7.0.0-beta.25
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 +86 -0
- package/dist/index.cjs.js +1133 -264
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.css +10 -10
- package/dist/index.es.js +1120 -259
- package/dist/index.es.js.map +1 -1
- package/dist/spacings-Ddc7umGk.js +196 -0
- package/dist/spacings-Ddc7umGk.js.map +1 -0
- package/dist/spacings-bCnRJAUT.cjs +206 -0
- package/dist/spacings-bCnRJAUT.cjs.map +1 -0
- package/dist/src/domains/agents/components/agent-metadata/agent-metadata.d.ts +11 -0
- package/dist/src/domains/processors/components/index.d.ts +2 -0
- package/dist/src/domains/processors/components/processor-panel.d.ts +8 -0
- package/dist/src/domains/processors/components/processor-table/columns.d.ts +12 -0
- package/dist/src/domains/processors/components/processor-table/index.d.ts +2 -0
- package/dist/src/domains/processors/components/processor-table/processor-table.d.ts +7 -0
- package/dist/src/domains/processors/hooks/index.d.ts +1 -0
- package/dist/src/domains/processors/hooks/use-processors.d.ts +50 -0
- package/dist/src/domains/processors/index.d.ts +2 -0
- package/dist/src/domains/workflows/hooks/use-workflows.d.ts +3 -1
- package/dist/src/domains/workflows/workflow/workflow-input-data.d.ts +2 -1
- package/dist/src/ds/components/Alert/Alert.d.ts +2 -1
- package/dist/src/ds/components/Avatar/Avatar.d.ts +2 -1
- package/dist/src/ds/components/Badge/Badge.d.ts +1 -1
- package/dist/src/ds/components/Button/Button.d.ts +1 -1
- package/dist/src/ds/components/Card/Card.d.ts +26 -0
- package/dist/src/ds/components/Card/index.d.ts +2 -0
- package/dist/src/ds/components/Collapsible/collapsible.d.ts +4 -3
- package/dist/src/ds/components/EmptyState/EmptyState.d.ts +10 -9
- package/dist/src/ds/components/EmptyState/index.d.ts +2 -1
- package/dist/src/ds/components/Input/input.d.ts +2 -0
- package/dist/src/ds/components/Kbd/kbd.d.ts +2 -1
- package/dist/src/ds/components/Notification/notification.d.ts +1 -1
- package/dist/src/ds/components/Spinner/spinner.d.ts +2 -1
- package/dist/src/ds/components/StatusBadge/StatusBadge.d.ts +13 -0
- package/dist/src/ds/components/StatusBadge/index.d.ts +2 -0
- package/dist/src/ds/icons/ProcessorIcon.d.ts +2 -0
- package/dist/src/ds/icons/index.d.ts +1 -0
- package/dist/src/ds/primitives/form-element.d.ts +3 -2
- package/dist/src/ds/primitives/transitions.d.ts +22 -0
- package/dist/src/ds/tokens/animations.d.ts +5 -0
- package/dist/src/ds/tokens/colors.d.ts +2 -1
- package/dist/src/ds/tokens/index.d.ts +2 -0
- package/dist/src/ds/tokens/shadows.d.ts +14 -0
- package/dist/src/index.d.ts +1 -0
- package/dist/src/lib/ai-ui/tools/badges/tool-approval-buttons.d.ts +2 -1
- package/dist/src/lib/framework.d.ts +2 -0
- package/dist/src/services/tool-call-provider.d.ts +5 -1
- package/dist/tailwind.preset.cjs.js +38 -10
- package/dist/tailwind.preset.cjs.js.map +1 -1
- package/dist/tailwind.preset.es.js +29 -1
- package/dist/tailwind.preset.es.js.map +1 -1
- package/dist/tokens.cjs.js +17 -175
- package/dist/tokens.cjs.js.map +1 -1
- package/dist/tokens.es.js +8 -169
- package/dist/tokens.es.js.map +1 -1
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,91 @@
|
|
|
1
1
|
# @mastra/playground-ui
|
|
2
2
|
|
|
3
|
+
## 7.0.0-beta.25
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Added human-in-the-loop (HITL) tool approval support for `generate()` method. ([#12056](https://github.com/mastra-ai/mastra/pull/12056))
|
|
8
|
+
|
|
9
|
+
**Why:** This provides parity between `stream()` and `generate()` for tool approval flows, allowing non-streaming use cases to leverage `requireToolApproval` without needing to switch to streaming.
|
|
10
|
+
|
|
11
|
+
Previously, tool approval with `requireToolApproval` only worked with `stream()`. Now you can use the same approval flow with `generate()` for non-streaming use cases.
|
|
12
|
+
|
|
13
|
+
**Using tool approval with generate()**
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
const output = await agent.generate('Find user John', {
|
|
17
|
+
requireToolApproval: true,
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
// Check if a tool is waiting for approval
|
|
21
|
+
if (output.finishReason === 'suspended') {
|
|
22
|
+
console.log('Tool requires approval:', output.suspendPayload.toolName);
|
|
23
|
+
|
|
24
|
+
// Approve the tool call
|
|
25
|
+
const result = await agent.approveToolCallGenerate({
|
|
26
|
+
runId: output.runId,
|
|
27
|
+
toolCallId: output.suspendPayload.toolCallId,
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
console.log(result.text);
|
|
31
|
+
}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
**Declining a tool call**
|
|
35
|
+
|
|
36
|
+
```typescript
|
|
37
|
+
if (output.finishReason === 'suspended') {
|
|
38
|
+
const result = await agent.declineToolCallGenerate({
|
|
39
|
+
runId: output.runId,
|
|
40
|
+
toolCallId: output.suspendPayload.toolCallId,
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
**New methods added:**
|
|
46
|
+
- `agent.approveToolCallGenerate({ runId, toolCallId })` - Approves a pending tool call and returns the complete result
|
|
47
|
+
- `agent.declineToolCallGenerate({ runId, toolCallId })` - Declines a pending tool call and returns the complete result
|
|
48
|
+
|
|
49
|
+
**Server routes added:**
|
|
50
|
+
- `POST /api/agents/:agentId/approve-tool-call-generate`
|
|
51
|
+
- `POST /api/agents/:agentId/decline-tool-call-generate`
|
|
52
|
+
|
|
53
|
+
The playground UI now also supports tool approval when using generate mode.
|
|
54
|
+
|
|
55
|
+
- Fix navigation for processors Studio tab ([#12062](https://github.com/mastra-ai/mastra/pull/12062))
|
|
56
|
+
|
|
57
|
+
- Added Processors tab to Mastra Studio. You can now view all configured processors, see which agents use them, and test processors directly from the UI. Processor workflows automatically redirect to the workflow graph view with a simplified input mode for testing. ([#12059](https://github.com/mastra-ai/mastra/pull/12059))
|
|
58
|
+
|
|
59
|
+
- Updated dependencies [[`ed3e3dd`](https://github.com/mastra-ai/mastra/commit/ed3e3ddec69d564fe2b125e083437f76331f1283), [`6833c69`](https://github.com/mastra-ai/mastra/commit/6833c69607418d257750bbcdd84638993d343539), [`47b1c16`](https://github.com/mastra-ai/mastra/commit/47b1c16a01c7ffb6765fe1e499b49092f8b7eba3), [`47b1c16`](https://github.com/mastra-ai/mastra/commit/47b1c16a01c7ffb6765fe1e499b49092f8b7eba3), [`3a76a80`](https://github.com/mastra-ai/mastra/commit/3a76a80284cb71a0faa975abb3d4b2a9631e60cd), [`8538a0d`](https://github.com/mastra-ai/mastra/commit/8538a0d232619bf55dad7ddc2a8b0ca77c679a87), [`9312dcd`](https://github.com/mastra-ai/mastra/commit/9312dcd1c6f5b321929e7d382e763d95fdc030f5), [`7691bb3`](https://github.com/mastra-ai/mastra/commit/7691bb317f62d43b0733209aaa83b428414c8dd1)]:
|
|
60
|
+
- @mastra/core@1.0.0-beta.25
|
|
61
|
+
- @mastra/client-js@1.0.0-beta.25
|
|
62
|
+
- @mastra/react@1.0.0-beta.25
|
|
63
|
+
- @mastra/schema-compat@1.0.0-beta.8
|
|
64
|
+
- @mastra/ai-sdk@1.0.0-beta.16
|
|
65
|
+
|
|
66
|
+
## 7.0.0-beta.24
|
|
67
|
+
|
|
68
|
+
### Minor Changes
|
|
69
|
+
|
|
70
|
+
- Enhance design system components with visual polish and micro-interactions. ([#12045](https://github.com/mastra-ai/mastra/pull/12045))
|
|
71
|
+
|
|
72
|
+
Phase 2 of DS enhancement covering 40+ components:
|
|
73
|
+
- **Form Controls**: Checkbox, RadioGroup, Switch, Slider, Combobox with focus rings, hover states, and smooth transitions
|
|
74
|
+
- **Navigation**: Tabs with animated indicator, Steps with progress animation, Collapsible with icon rotation
|
|
75
|
+
- **Feedback**: Alert with entrance animation, Notification with slide animations, Skeleton with gradient shimmer
|
|
76
|
+
- **Display**: Badge with semantic variants, Avatar with interactive mode, StatusBadge enhancements
|
|
77
|
+
- **Layout**: SideDialog with backdrop blur, ScrollArea with visibility transitions
|
|
78
|
+
|
|
79
|
+
All components now use consistent design tokens (duration-normal, ease-out-custom, shadow-focus-ring) and GPU-accelerated properties for smooth 60fps animations.
|
|
80
|
+
|
|
81
|
+
### Patch Changes
|
|
82
|
+
|
|
83
|
+
- Updated dependencies [[`1dbd8c7`](https://github.com/mastra-ai/mastra/commit/1dbd8c729fb6536ec52f00064d76b80253d346e9), [`c59e13c`](https://github.com/mastra-ai/mastra/commit/c59e13c7688284bd96b2baee3e314335003548de), [`f93e2f5`](https://github.com/mastra-ai/mastra/commit/f93e2f575e775e627e5c1927cefdd72db07858ed), [`461e448`](https://github.com/mastra-ai/mastra/commit/461e448852fe999506a6046d50b1efc27d8aa378), [`f9a2509`](https://github.com/mastra-ai/mastra/commit/f9a25093ea72d210a5e52cfcb3bcc8b5e02dc25c), [`64554f4`](https://github.com/mastra-ai/mastra/commit/64554f48f26f028b738a04576d34ff992983529e), [`7a010c5`](https://github.com/mastra-ai/mastra/commit/7a010c56b846a313a49ae42fccd3d8de2b9f292d)]:
|
|
84
|
+
- @mastra/core@1.0.0-beta.24
|
|
85
|
+
- @mastra/schema-compat@1.0.0-beta.7
|
|
86
|
+
- @mastra/client-js@1.0.0-beta.24
|
|
87
|
+
- @mastra/react@1.0.0-beta.24
|
|
88
|
+
|
|
3
89
|
## 7.0.0-beta.23
|
|
4
90
|
|
|
5
91
|
### Patch Changes
|