@motiadev/workbench 0.8.2-beta.140-628177 → 0.8.2-beta.140-027880
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/dist/components.json +1 -1
- package/dist/index.d.ts +7 -7
- package/dist/index.js +5 -5
- package/dist/middleware.d.ts +1 -1
- package/dist/middleware.js +3 -3
- package/dist/motia-plugin/__tests__/generator.test.js +97 -0
- package/dist/motia-plugin/__tests__/resolver.test.d.ts +1 -0
- package/dist/motia-plugin/__tests__/resolver.test.js +64 -0
- package/dist/motia-plugin/__tests__/validator.test.d.ts +1 -0
- package/dist/motia-plugin/__tests__/validator.test.js +59 -0
- package/dist/motia-plugin/generator.d.ts +78 -0
- package/dist/motia-plugin/generator.js +128 -0
- package/dist/motia-plugin/hmr.d.ts +22 -0
- package/dist/motia-plugin/hmr.js +116 -0
- package/dist/motia-plugin/index.d.ts +3 -0
- package/dist/motia-plugin/index.js +152 -0
- package/dist/motia-plugin/resolver.d.ts +63 -0
- package/dist/motia-plugin/resolver.js +92 -0
- package/dist/motia-plugin/types.d.ts +169 -0
- package/dist/motia-plugin/types.js +36 -0
- package/dist/motia-plugin/utils.d.ts +57 -0
- package/dist/motia-plugin/utils.js +75 -0
- package/dist/motia-plugin/validator.d.ts +19 -0
- package/dist/motia-plugin/validator.js +163 -0
- package/dist/postcss.config.mjs +1 -1
- package/dist/src/App.d.ts +1 -1
- package/dist/src/App.js +1 -18
- package/dist/src/components/flow/base-edge.d.ts +2 -2
- package/dist/src/components/flow/base-edge.js +1 -1
- package/dist/src/components/flow/flow-page.js +2 -2
- package/dist/src/components/flow/flow-tab-menu-item.js +2 -2
- package/dist/src/components/flow/flow-view.d.ts +3 -3
- package/dist/src/components/flow/hooks/use-get-flow-state.d.ts +2 -2
- package/dist/src/components/flow/hooks/use-get-flow-state.js +0 -4
- package/dist/src/components/flow/hooks/use-save-workflow-config.d.ts +1 -1
- package/dist/src/components/flow/node-organizer.d.ts +3 -3
- package/dist/src/components/flow/nodes/api-flow-node.d.ts +1 -1
- package/dist/src/components/flow/nodes/cron-flow-node.d.ts +1 -1
- package/dist/src/components/flow/nodes/event-flow-node.d.ts +1 -1
- package/dist/src/components/flow/nodes/noop-flow-node.d.ts +1 -1
- package/dist/src/components/header/deploy-button.js +2 -2
- package/dist/src/components/header/header.d.ts +1 -1
- package/dist/src/components/header/header.js +2 -2
- package/dist/src/components/root-motia.d.ts +2 -1
- package/dist/src/components/tutorial/engine/tutorial-engine.d.ts +1 -1
- package/dist/src/components/tutorial/hooks/use-tutorial-engine.d.ts +1 -1
- package/dist/src/components/tutorial/hooks/use-tutorial.d.ts +1 -1
- package/dist/src/components/tutorial/tutorial-button.d.ts +1 -1
- package/dist/src/components/tutorial/tutorial-button.js +1 -1
- package/dist/src/components/tutorial/tutorial-step.d.ts +2 -2
- package/dist/src/components/tutorial/tutorial-step.js +1 -1
- package/dist/src/components/tutorial/tutorial.css +8 -8
- package/dist/src/components/ui/json-editor.d.ts +1 -1
- package/dist/src/components/ui/json-editor.js +1 -1
- package/dist/src/components/ui/table.js +1 -1
- package/dist/src/components/ui/theme-toggle.d.ts +1 -1
- package/dist/src/components/ui/tooltip.d.ts +1 -1
- package/dist/src/hooks/use-fetch-flows.js +1 -1
- package/dist/src/hooks/use-update-handle-positions.d.ts +1 -1
- package/dist/src/index.css +5 -5
- package/dist/src/lib/plugins.js +3 -3
- package/dist/src/main.js +2 -3
- package/dist/src/project-view-mode.js +1 -1
- package/dist/src/publicComponents/api-node.d.ts +2 -2
- package/dist/src/publicComponents/base-node/base-handle.d.ts +3 -2
- package/dist/src/publicComponents/base-node/base-node.d.ts +3 -2
- package/dist/src/publicComponents/base-node/base-node.js +1 -1
- package/dist/src/publicComponents/base-node/code-display.d.ts +2 -2
- package/dist/src/publicComponents/base-node/code-display.js +1 -1
- package/dist/src/publicComponents/base-node/emits.d.ts +2 -2
- package/dist/src/publicComponents/base-node/feature-card.d.ts +2 -2
- package/dist/src/publicComponents/base-node/language-indicator.d.ts +2 -2
- package/dist/src/publicComponents/base-node/node-header.d.ts +3 -2
- package/dist/src/publicComponents/base-node/node-sidebar.d.ts +2 -2
- package/dist/src/publicComponents/base-node/subscribe.d.ts +1 -1
- package/dist/src/publicComponents/cron-node.d.ts +3 -2
- package/dist/src/publicComponents/event-node.d.ts +3 -2
- package/dist/src/publicComponents/node-props.d.ts +1 -1
- package/dist/src/publicComponents/noop-node.d.ts +3 -2
- package/dist/src/stores/use-global-store.d.ts +0 -6
- package/dist/src/stores/use-global-store.js +0 -6
- package/dist/src/types/flow.d.ts +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/tsconfig.node.tsbuildinfo +1 -1
- package/motia-plugin/__tests__/generator.test.ts +129 -0
- package/motia-plugin/__tests__/resolver.test.ts +82 -0
- package/motia-plugin/__tests__/validator.test.ts +71 -0
- package/motia-plugin/generator.ts +130 -0
- package/motia-plugin/hmr.ts +140 -0
- package/motia-plugin/index.ts +182 -0
- package/motia-plugin/resolver.ts +96 -0
- package/motia-plugin/types.ts +198 -0
- package/motia-plugin/utils.ts +70 -0
- package/motia-plugin/validator.ts +197 -0
- package/package.json +9 -9
- package/postcss.config.mjs +1 -1
- package/dist/src/components/observability/events/code/function-call.d.ts +0 -13
- package/dist/src/components/observability/events/code/function-call.js +0 -16
- package/dist/src/components/observability/events/event-icon.d.ts +0 -7
- package/dist/src/components/observability/events/event-icon.js +0 -16
- package/dist/src/components/observability/events/trace-emit-event.d.ts +0 -5
- package/dist/src/components/observability/events/trace-emit-event.js +0 -5
- package/dist/src/components/observability/events/trace-event.d.ts +0 -5
- package/dist/src/components/observability/events/trace-event.js +0 -20
- package/dist/src/components/observability/events/trace-log-event.d.ts +0 -5
- package/dist/src/components/observability/events/trace-log-event.js +0 -5
- package/dist/src/components/observability/events/trace-state-event.d.ts +0 -5
- package/dist/src/components/observability/events/trace-state-event.js +0 -5
- package/dist/src/components/observability/events/trace-stream-event.d.ts +0 -5
- package/dist/src/components/observability/events/trace-stream-event.js +0 -5
- package/dist/src/components/observability/hooks/use-get-endtime.d.ts +0 -2
- package/dist/src/components/observability/hooks/use-get-endtime.js +0 -15
- package/dist/src/components/observability/trace-item/trace-item-detail.d.ts +0 -8
- package/dist/src/components/observability/trace-item/trace-item-detail.js +0 -10
- package/dist/src/components/observability/trace-item/trace-item.d.ts +0 -10
- package/dist/src/components/observability/trace-item/trace-item.js +0 -14
- package/dist/src/components/observability/trace-status.d.ts +0 -8
- package/dist/src/components/observability/trace-status.js +0 -18
- package/dist/src/components/observability/trace-tab-label.d.ts +0 -1
- package/dist/src/components/observability/trace-tab-label.js +0 -5
- package/dist/src/components/observability/trace-timeline.d.ts +0 -6
- package/dist/src/components/observability/trace-timeline.js +0 -30
- package/dist/src/components/observability/traces-groups.d.ts +0 -9
- package/dist/src/components/observability/traces-groups.js +0 -9
- package/dist/src/components/observability/traces-page.d.ts +0 -1
- package/dist/src/components/observability/traces-page.js +0 -33
- package/dist/src/components/states/hooks/states-hooks.d.ts +0 -13
- package/dist/src/components/states/hooks/states-hooks.js +0 -26
- package/dist/src/components/states/state-details.d.ts +0 -7
- package/dist/src/components/states/state-details.js +0 -3
- package/dist/src/components/states/state-editor.d.ts +0 -7
- package/dist/src/components/states/state-editor.js +0 -71
- package/dist/src/components/states/state-sidebar.d.ts +0 -8
- package/dist/src/components/states/state-sidebar.js +0 -17
- package/dist/src/components/states/state-tab-label.d.ts +0 -1
- package/dist/src/components/states/state-tab-label.js +0 -5
- package/dist/src/components/states/states-page.d.ts +0 -1
- package/dist/src/components/states/states-page.js +0 -56
- package/dist/src/types/observability.d.ts +0 -78
- package/dist/vite-plugin-motia-plugins.d.ts +0 -9
- package/dist/vite-plugin-motia-plugins.js +0 -69
- /package/dist/{src/types/observability.js → motia-plugin/__tests__/generator.test.d.ts} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
import { ApiNodeProps } from './node-props';
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { ApiNodeProps } from './node-props';
|
|
3
3
|
type Props = PropsWithChildren<ApiNodeProps>;
|
|
4
4
|
export declare const ApiNode: ({ data, children }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import { type HandleProps } from '@xyflow/react';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
import type { HTMLAttributes } from 'react';
|
|
3
4
|
type Props = HandleProps & Omit<HTMLAttributes<HTMLDivElement>, 'id'> & {
|
|
4
5
|
isHidden?: boolean;
|
|
5
6
|
onTogglePosition?: () => void;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React
|
|
2
|
-
import {
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import { type PropsWithChildren } from 'react';
|
|
3
|
+
import type { BaseNodeProps } from '../node-props';
|
|
3
4
|
type Props = PropsWithChildren<{
|
|
4
5
|
title: string;
|
|
5
6
|
subtitle?: string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { useHandlePositions } from '@/hooks/use-update-handle-positions';
|
|
3
2
|
import { Button, cn } from '@motiadev/ui';
|
|
4
3
|
import { ScanSearch } from 'lucide-react';
|
|
5
4
|
import { useCallback, useEffect, useState } from 'react';
|
|
5
|
+
import { useHandlePositions } from '@/hooks/use-update-handle-positions';
|
|
6
6
|
import { BaseHandle } from './base-handle';
|
|
7
7
|
import { NodeHeader } from './node-header';
|
|
8
8
|
import { NodeSidebar } from './node-sidebar';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useThemeStore } from '@motiadev/ui';
|
|
3
|
-
import { FeatureCard } from './feature-card';
|
|
4
3
|
import { useRef, useState } from 'react';
|
|
5
4
|
import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
|
|
6
5
|
import { oneDark, oneLight } from 'react-syntax-highlighter/dist/esm/styles/prism';
|
|
6
|
+
import { FeatureCard } from './feature-card';
|
|
7
7
|
import { LanguageIndicator } from './language-indicator';
|
|
8
8
|
const codeTagProps = {
|
|
9
9
|
style: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { VariantProps } from 'class-variance-authority';
|
|
2
|
-
import React
|
|
1
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
import type { PropsWithChildren } from 'react';
|
|
3
4
|
declare const baseIcon: (props?: ({
|
|
4
5
|
variant?: "event" | "api" | "noop" | "cron" | null | undefined;
|
|
5
6
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import React
|
|
2
|
-
import {
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { PropsWithChildren } from 'react';
|
|
3
|
+
import type { CronNodeProps } from './node-props';
|
|
3
4
|
export declare const CronNode: React.FC<PropsWithChildren<CronNodeProps>>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { PropsWithChildren } from 'react';
|
|
3
|
+
import type { EventNodeProps } from './node-props';
|
|
3
4
|
export declare const EventNode: React.FC<PropsWithChildren<EventNodeProps>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApiNodeData, CronNodeData, EventNodeData, NoopNodeData } from '../types/flow';
|
|
1
|
+
import type { ApiNodeData, CronNodeData, EventNodeData, NoopNodeData } from '../types/flow';
|
|
2
2
|
export type NodeProps = EventNodeProps | NoopNodeProps | ApiNodeProps | CronNodeProps;
|
|
3
3
|
export type BaseNodeProps = {
|
|
4
4
|
id: string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import React
|
|
2
|
-
import {
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { PropsWithChildren } from 'react';
|
|
3
|
+
import type { NoopNodeProps } from './node-props';
|
|
3
4
|
export declare const NoopNode: React.FC<PropsWithChildren<NoopNodeProps>>;
|
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
type UseGlobalStore = {
|
|
2
2
|
selectedEndpointId?: string;
|
|
3
3
|
selectEndpointId: (endpointId?: string) => void;
|
|
4
|
-
selectedTraceGroupId?: string;
|
|
5
|
-
selectTraceGroupId: (traceGroupId?: string) => void;
|
|
6
|
-
selectedTraceId?: string;
|
|
7
|
-
selectTraceId: (traceId?: string) => void;
|
|
8
|
-
selectedStateId?: string;
|
|
9
|
-
selectStateId: (stateId?: string) => void;
|
|
10
4
|
};
|
|
11
5
|
export declare const useGlobalStore: import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<UseGlobalStore>, "setState" | "persist"> & {
|
|
12
6
|
setState(partial: UseGlobalStore | Partial<UseGlobalStore> | ((state: UseGlobalStore) => UseGlobalStore | Partial<UseGlobalStore>), replace?: false | undefined): unknown;
|
|
@@ -6,12 +6,6 @@ const select = (id, name) => (state) => {
|
|
|
6
6
|
export const useGlobalStore = create(persist((set) => ({
|
|
7
7
|
selectedEndpointId: undefined,
|
|
8
8
|
selectEndpointId: (endpointId) => set(select(endpointId, 'selectedEndpointId')),
|
|
9
|
-
selectedTraceGroupId: undefined,
|
|
10
|
-
selectTraceGroupId: (traceGroupId) => set(select(traceGroupId, 'selectedTraceGroupId')),
|
|
11
|
-
selectedTraceId: undefined,
|
|
12
|
-
selectTraceId: (traceId) => set(select(traceId, 'selectedTraceId')),
|
|
13
|
-
selectedStateId: undefined,
|
|
14
|
-
selectStateId: (stateId) => set(select(stateId, 'selectedStateId')),
|
|
15
9
|
}), {
|
|
16
10
|
name: 'motia-global-storage',
|
|
17
11
|
storage: createJSONStorage(() => localStorage),
|
package/dist/src/types/flow.d.ts
CHANGED