nexus-shell 0.1.3 → 0.1.5
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/widgets/DataGrid.d.ts +22 -0
- package/dist/components/widgets/MockupReviewWidget.d.ts +3 -0
- package/dist/components/widgets/WelcomeTab.d.ts +8 -0
- package/dist/components/widgets/mockup-reviewer/ExecutionOverlay.d.ts +10 -0
- package/dist/components/widgets/mockup-reviewer/HtmlShadowRenderer.d.ts +9 -0
- package/dist/components/widgets/mockup-reviewer/ImplementationPlanWorkspace.d.ts +8 -0
- package/dist/components/widgets/mockup-reviewer/MockupReviewWorkspace.d.ts +10 -0
- package/dist/components/widgets/mockup-reviewer/ReviewSidebar.d.ts +3 -0
- package/dist/components/widgets/mockup-reviewer/ReviewToolbar.d.ts +12 -0
- package/dist/components/widgets/mockup-reviewer/WorkflowMapper.d.ts +7 -0
- package/dist/core/registry/PluginRegistry.d.ts +5 -0
- package/dist/core/services/MockupReviewService.d.ts +58 -0
- package/dist/{index-DG52PCQ8.js → index-HQz7gZzB.js} +22656 -19911
- package/dist/index.d.ts +4 -1
- package/dist/{maplibre-gl-BWsNxx57.js → maplibre-gl-Bwi3Dwff.js} +1 -1
- package/dist/nexus-shell.es.js +23 -20
- package/dist/nexus-shell.umd.js +465 -188
- package/dist/stories/DataGrid.stories.d.ts +12 -0
- package/dist/stories/MockupReviewWidget.stories.d.ts +9 -0
- package/dist/stories/MockupReviewerLayout.stories.d.ts +8 -0
- package/dist/style.css +1 -1
- package/package.json +3 -1
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface IDataGridColumn<T = any> {
|
|
4
|
+
key: string;
|
|
5
|
+
header: string;
|
|
6
|
+
width?: string | number;
|
|
7
|
+
sortable?: boolean;
|
|
8
|
+
render?: (value: any, row: T) => React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
export interface DataGridProps<T = any> {
|
|
11
|
+
columns: IDataGridColumn<T>[];
|
|
12
|
+
data: T[];
|
|
13
|
+
onRowClick?: (row: T) => void;
|
|
14
|
+
selectedRowId?: string | number;
|
|
15
|
+
rowKey?: keyof T;
|
|
16
|
+
virtualized?: boolean;
|
|
17
|
+
showFilter?: boolean;
|
|
18
|
+
loading?: boolean;
|
|
19
|
+
placeholder?: string;
|
|
20
|
+
className?: string;
|
|
21
|
+
}
|
|
22
|
+
export declare const DataGrid: <T extends Record<string, any>>({ columns, data, onRowClick, selectedRowId, rowKey, virtualized, showFilter, loading, placeholder, className, }: DataGridProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
interface ExecutionOverlayProps {
|
|
4
|
+
isExecuting: boolean;
|
|
5
|
+
setIsExecuting: (val: boolean) => void;
|
|
6
|
+
executionStep: number;
|
|
7
|
+
setExecutionStep: (step: number | ((prev: number) => number)) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const ExecutionOverlay: React.FC<ExecutionOverlayProps>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
interface HtmlShadowRendererProps {
|
|
4
|
+
htmlContent: string;
|
|
5
|
+
onElementClick?: (selector: string, clientX: number, clientY: number) => void;
|
|
6
|
+
shadowHostRef: React.RefObject<HTMLDivElement | null>;
|
|
7
|
+
}
|
|
8
|
+
export declare const HtmlShadowRenderer: React.FC<HtmlShadowRendererProps>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
interface ImplementationPlanWorkspaceProps {
|
|
4
|
+
setIsExecuting: (val: boolean) => void;
|
|
5
|
+
setExecutionStep: (step: number) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare const ImplementationPlanWorkspace: React.FC<ImplementationPlanWorkspaceProps>;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
interface MockupReviewWorkspaceProps {
|
|
4
|
+
tool: 'select' | 'pen' | 'rect' | 'circle' | 'arrow' | 'comment' | 'eraser';
|
|
5
|
+
color: string;
|
|
6
|
+
selectedAnnotationId: string | null;
|
|
7
|
+
setSelectedAnnotationId: (id: string | null) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const MockupReviewWorkspace: React.FC<MockupReviewWorkspaceProps>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
interface ReviewToolbarProps {
|
|
4
|
+
tool: 'select' | 'pen' | 'rect' | 'circle' | 'arrow' | 'comment' | 'eraser';
|
|
5
|
+
setTool: (t: 'select' | 'pen' | 'rect' | 'circle' | 'arrow' | 'comment' | 'eraser') => void;
|
|
6
|
+
color: string;
|
|
7
|
+
setColor: (c: string) => void;
|
|
8
|
+
selectedAnnotationId: string | null;
|
|
9
|
+
setSelectedAnnotationId: (id: string | null) => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const ReviewToolbar: React.FC<ReviewToolbarProps>;
|
|
12
|
+
export {};
|
|
@@ -5,12 +5,17 @@ export interface IPlugin {
|
|
|
5
5
|
deactivate: () => void;
|
|
6
6
|
}
|
|
7
7
|
export type PluginLoader = () => Promise<IPlugin>;
|
|
8
|
+
export type PluginStatus = 'registered' | 'inactive' | 'activating' | 'active' | 'failed' | 'deactivated';
|
|
8
9
|
export declare class PluginRegistry {
|
|
9
10
|
private plugins;
|
|
10
11
|
private loaders;
|
|
12
|
+
private statuses;
|
|
11
13
|
registerPlugin(plugin: IPlugin): void;
|
|
12
14
|
registerLazyPlugin(id: string, loader: PluginLoader): void;
|
|
13
15
|
activatePlugin(id: string): Promise<void>;
|
|
16
|
+
deactivatePlugin(id: string): Promise<void>;
|
|
17
|
+
getPluginStatus(id: string): PluginStatus | undefined;
|
|
18
|
+
getPluginStatuses(): Record<string, PluginStatus>;
|
|
14
19
|
getPlugin(id: string): IPlugin | undefined;
|
|
15
20
|
getAllPlugins(): IPlugin[];
|
|
16
21
|
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { Node, Edge } from 'reactflow';
|
|
2
|
+
|
|
3
|
+
export interface IMockupAnnotation {
|
|
4
|
+
id: string;
|
|
5
|
+
type: 'stroke' | 'rect' | 'circle' | 'arrow' | 'comment';
|
|
6
|
+
color: string;
|
|
7
|
+
points?: {
|
|
8
|
+
x: number;
|
|
9
|
+
y: number;
|
|
10
|
+
}[];
|
|
11
|
+
x?: number;
|
|
12
|
+
y?: number;
|
|
13
|
+
width?: number;
|
|
14
|
+
height?: number;
|
|
15
|
+
text?: string;
|
|
16
|
+
elementSelector?: string;
|
|
17
|
+
versionId: string;
|
|
18
|
+
}
|
|
19
|
+
export interface IMockupVersion {
|
|
20
|
+
id: string;
|
|
21
|
+
label: string;
|
|
22
|
+
timestamp: string;
|
|
23
|
+
htmlContent: string;
|
|
24
|
+
annotations: IMockupAnnotation[];
|
|
25
|
+
}
|
|
26
|
+
export interface IMockupView {
|
|
27
|
+
id: string;
|
|
28
|
+
name: string;
|
|
29
|
+
description?: string;
|
|
30
|
+
activeVersionId: string;
|
|
31
|
+
versions: IMockupVersion[];
|
|
32
|
+
parentId?: string | null;
|
|
33
|
+
}
|
|
34
|
+
interface MockupReviewState {
|
|
35
|
+
views: IMockupView[];
|
|
36
|
+
activeViewId: string | null;
|
|
37
|
+
compareVersionId: string | null;
|
|
38
|
+
nodes: Node[];
|
|
39
|
+
edges: Edge[];
|
|
40
|
+
implementationPlan: string;
|
|
41
|
+
setActiveViewId: (id: string | null) => void;
|
|
42
|
+
setActiveVersionId: (viewId: string, versionId: string) => void;
|
|
43
|
+
setCompareVersionId: (versionId: string | null) => void;
|
|
44
|
+
setViewParentId: (viewId: string, parentId: string | null) => void;
|
|
45
|
+
addAnnotation: (viewId: string, versionId: string, annotation: Omit<IMockupAnnotation, 'versionId'>) => void;
|
|
46
|
+
undoAnnotation: (viewId: string, versionId: string) => void;
|
|
47
|
+
deleteAnnotation: (viewId: string, versionId: string, annotationId: string) => void;
|
|
48
|
+
updateAnnotationText: (viewId: string, versionId: string, annotationId: string, text: string) => void;
|
|
49
|
+
addMockupView: (name: string, description?: string, htmlContent?: string) => string;
|
|
50
|
+
addMockupVersion: (viewId: string, label: string, htmlContent: string) => string;
|
|
51
|
+
updateWorkflow: (nodes: Node[], edges: Edge[]) => void;
|
|
52
|
+
setImplementationPlan: (plan: string) => void;
|
|
53
|
+
generateImplementationPlanAction: () => void;
|
|
54
|
+
refineImplementationPlanAction: (refinementPrompt: string) => void;
|
|
55
|
+
exportHistoryJson: () => string;
|
|
56
|
+
}
|
|
57
|
+
export declare const useMockupReviewStore: import('zustand').UseBoundStore<import('zustand').StoreApi<MockupReviewState>>;
|
|
58
|
+
export {};
|