@motiadev/workbench 0.17.6-beta.188-784886 → 0.17.7-beta.188

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.
@@ -664,33 +664,13 @@ const applyMiddleware = async ({ app, port, workbenchBase, plugins }) => {
664
664
  path.join(__dirname, "./node_modules")
665
665
  ] }
666
666
  },
667
- resolve: {
668
- dedupe: [
669
- "react",
670
- "react-dom",
671
- "react/jsx-runtime",
672
- "@motiadev/stream-client-react",
673
- "@motiadev/stream-client-browser",
674
- "@motiadev/stream-client"
675
- ],
676
- alias: {
677
- "@": path.resolve(__dirname, "./src"),
678
- "@/assets": path.resolve(__dirname, "./src/assets"),
679
- "lucide-react/dynamic": "lucide-react/dynamic.mjs",
680
- "lucide-react": "lucide-react/dist/cjs/lucide-react.js"
681
- }
682
- },
683
- optimizeDeps: {
684
- exclude: ["@motiadev/workbench"],
685
- include: [
686
- "@motiadev/stream-client-react",
687
- "@motiadev/stream-client-browser",
688
- "@motiadev/stream-client",
689
- "react/jsx-runtime",
690
- "react",
691
- "react-dom"
692
- ]
693
- },
667
+ resolve: { alias: {
668
+ "@": path.resolve(__dirname, "./src"),
669
+ "@/assets": path.resolve(__dirname, "./src/assets"),
670
+ "lucide-react/dynamic": "lucide-react/dynamic.mjs",
671
+ "lucide-react": "lucide-react/dist/cjs/lucide-react.js"
672
+ } },
673
+ optimizeDeps: { exclude: ["@motiadev/workbench"] },
694
674
  plugins: [
695
675
  react({ babel: { plugins: ["babel-plugin-react-compiler"] } }),
696
676
  processCwdPlugin(),
@@ -3,7 +3,6 @@ import { memo } from 'react'
3
3
  import { useShallow } from 'zustand/react/shallow'
4
4
  import { type AppTabsState, TabLocation, useAppTabsStore } from '../stores/use-app-tabs-store'
5
5
  import { useTabsStore } from '../stores/use-tabs-store'
6
- import { TabErrorBoundary } from './tab-error-boundary'
7
6
 
8
7
  const bottomTabsSelector = (state: AppTabsState) => state.tabs[TabLocation.BOTTOM]
9
8
  const bottomPanelId = 'bottom-panel'
@@ -31,9 +30,7 @@ export const BottomPanel = memo(() => {
31
30
  >
32
31
  {tabs.map(({ id, content: Element }) => (
33
32
  <TabsContent key={id} value={id} className="h-full">
34
- <TabErrorBoundary tabId={id}>
35
- <Element />
36
- </TabErrorBoundary>
33
+ <Element />
37
34
  </TabsContent>
38
35
  ))}
39
36
  </CollapsiblePanel>
@@ -3,7 +3,6 @@ import { memo } from 'react'
3
3
  import { useShallow } from 'zustand/react/shallow'
4
4
  import { type AppTabsState, TabLocation, useAppTabsStore } from '../stores/use-app-tabs-store'
5
5
  import { useTabsStore } from '../stores/use-tabs-store'
6
- import { TabErrorBoundary } from './tab-error-boundary'
7
6
 
8
7
  const topTabsSelector = (state: AppTabsState) => state.tabs[TabLocation.TOP]
9
8
  const topPanelId = 'top-panel'
@@ -32,9 +31,7 @@ export const TopPanel = memo(() => {
32
31
  >
33
32
  {tabs.map(({ id, content: Element }) => (
34
33
  <TabsContent key={id} value={id} className="h-full">
35
- <TabErrorBoundary tabId={id}>
36
- <Element />
37
- </TabErrorBoundary>
34
+ <Element />
38
35
  </TabsContent>
39
36
  ))}
40
37
  </CollapsiblePanel>
@@ -1,7 +1,6 @@
1
1
  import { APP_SIDEBAR_CONTAINER_ID, Panel } from '@motiadev/ui'
2
2
  import { memo } from 'react'
3
3
  import { useShallow } from 'zustand/react/shallow'
4
- import { TabErrorBoundary } from './components/tab-error-boundary'
5
4
  import { type AppTabsState, TabLocation, useAppTabsStore } from './stores/use-app-tabs-store'
6
5
 
7
6
  const topTabs = (state: AppTabsState) => state.tabs[TabLocation.TOP]
@@ -20,11 +19,7 @@ export const ProjectViewMode = memo(() => {
20
19
  return {
21
20
  label: tab.id,
22
21
  labelComponent: <LabelComponent />,
23
- content: (
24
- <TabErrorBoundary tabId={tab.id}>
25
- <Element />
26
- </TabErrorBoundary>
27
- ),
22
+ content: <Element />,
28
23
  'data-testid': tab.id,
29
24
  }
30
25
  })}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@motiadev/workbench",
3
3
  "description": "A web-based interface for building and managing Motia workflows.",
4
- "version": "0.17.6-beta.188-784886",
4
+ "version": "0.17.7-beta.188",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "module": "./dist/index.js",
@@ -23,10 +23,10 @@
23
23
  "dagre": "^0.8.5",
24
24
  "fast-deep-equal": "^3.1.3",
25
25
  "json-schema": "^0.4.0",
26
- "lucide-react": "^0.555.0",
26
+ "lucide-react": "^0.554.0",
27
27
  "postcss": "^8.5.6",
28
- "react": "^19.2.3",
29
- "react-dom": "^19.2.3",
28
+ "react": "^19.2.0",
29
+ "react-dom": "^19.2.0",
30
30
  "react-router-dom": "^7.9.6",
31
31
  "react-syntax-highlighter": "^16.1.0",
32
32
  "react18-json-view": "^0.2.9",
@@ -38,10 +38,10 @@
38
38
  "babel-plugin-react-compiler": "^1.0.0",
39
39
  "vite": "^7.2.4",
40
40
  "zod": "^4.1.13",
41
- "zustand": "^5.0.9",
42
- "@motiadev/core": "0.17.6-beta.188-784886",
43
- "@motiadev/stream-client-react": "0.17.6-beta.188-784886",
44
- "@motiadev/ui": "0.17.6-beta.188-784886"
41
+ "zustand": "^5.0.8",
42
+ "@motiadev/core": "0.17.7-beta.188",
43
+ "@motiadev/stream-client-react": "0.17.7-beta.188",
44
+ "@motiadev/ui": "0.17.7-beta.188"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@rollup/plugin-babel": "^6.1.0",
@@ -1,119 +0,0 @@
1
- import { AlertTriangle, ChevronDown, ChevronRight, RefreshCw } from 'lucide-react'
2
- import { Component, type ErrorInfo, type ReactNode } from 'react'
3
-
4
- interface TabErrorBoundaryProps {
5
- tabId: string
6
- children: ReactNode
7
- }
8
-
9
- interface TabErrorBoundaryState {
10
- hasError: boolean
11
- error: Error | null
12
- errorInfo: ErrorInfo | null
13
- isDetailsExpanded: boolean
14
- }
15
-
16
- export class TabErrorBoundary extends Component<TabErrorBoundaryProps, TabErrorBoundaryState> {
17
- constructor(props: TabErrorBoundaryProps) {
18
- super(props)
19
- this.state = {
20
- hasError: false,
21
- error: null,
22
- errorInfo: null,
23
- isDetailsExpanded: false,
24
- }
25
- }
26
-
27
- static getDerivedStateFromError(error: Error): Partial<TabErrorBoundaryState> {
28
- return { hasError: true, error }
29
- }
30
-
31
- componentDidCatch(error: Error, errorInfo: ErrorInfo): void {
32
- this.setState({ errorInfo })
33
- console.error(`Error in tab "${this.props.tabId}":`, error, errorInfo)
34
- }
35
-
36
- handleRetry = (): void => {
37
- this.setState({
38
- hasError: false,
39
- error: null,
40
- errorInfo: null,
41
- isDetailsExpanded: false,
42
- })
43
- }
44
-
45
- toggleDetails = (): void => {
46
- this.setState((prev) => ({ isDetailsExpanded: !prev.isDetailsExpanded }))
47
- }
48
-
49
- render(): ReactNode {
50
- if (this.state.hasError) {
51
- const { error, errorInfo, isDetailsExpanded } = this.state
52
- const { tabId } = this.props
53
-
54
- return (
55
- <div className="flex flex-col items-center justify-center h-full p-6 text-foreground">
56
- <div className="flex flex-col items-center gap-4 max-w-lg w-full">
57
- <div className="flex items-center gap-3 text-destructive">
58
- <AlertTriangle className="w-8 h-8" />
59
- <h2 className="text-xl font-semibold">Something went wrong</h2>
60
- </div>
61
-
62
- <p className="text-sm text-muted-foreground text-center">
63
- An error occurred in the <span className="font-mono text-foreground">{tabId}</span> tab.
64
- </p>
65
-
66
- <button
67
- onClick={this.handleRetry}
68
- className="flex items-center gap-2 px-4 py-2 bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors"
69
- >
70
- <RefreshCw className="w-4 h-4" />
71
- Retry
72
- </button>
73
-
74
- <div className="w-full mt-4 border border-border rounded-lg overflow-hidden">
75
- <button
76
- onClick={this.toggleDetails}
77
- className="flex items-center gap-2 w-full px-4 py-3 bg-muted/50 hover:bg-muted transition-colors text-left"
78
- >
79
- {isDetailsExpanded ? <ChevronDown className="w-4 h-4" /> : <ChevronRight className="w-4 h-4" />}
80
- <span className="text-sm font-medium">Error Details</span>
81
- </button>
82
-
83
- {isDetailsExpanded && (
84
- <div className="p-4 bg-card text-sm space-y-4 overflow-auto max-h-80">
85
- <div>
86
- <h4 className="font-semibold text-destructive mb-1">Error Message</h4>
87
- <pre className="whitespace-pre-wrap break-words font-mono text-xs bg-muted p-2 rounded">
88
- {error?.message || 'Unknown error'}
89
- </pre>
90
- </div>
91
-
92
- {error?.stack && (
93
- <div>
94
- <h4 className="font-semibold text-muted-foreground mb-1">Stack Trace</h4>
95
- <pre className="whitespace-pre-wrap break-words font-mono text-xs bg-muted p-2 rounded overflow-x-auto">
96
- {error.stack}
97
- </pre>
98
- </div>
99
- )}
100
-
101
- {errorInfo?.componentStack && (
102
- <div>
103
- <h4 className="font-semibold text-muted-foreground mb-1">Component Stack</h4>
104
- <pre className="whitespace-pre-wrap break-words font-mono text-xs bg-muted p-2 rounded overflow-x-auto">
105
- {errorInfo.componentStack}
106
- </pre>
107
- </div>
108
- )}
109
- </div>
110
- )}
111
- </div>
112
- </div>
113
- </div>
114
- )
115
- }
116
-
117
- return this.props.children
118
- }
119
- }