dishui 0.0.65 → 0.0.67
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/_virtual/_rolldown/runtime.js +10 -11
- package/dist/chart.js +12 -46
- package/dist/code-editor.js +16 -43
- package/dist/components/Accordion/index.d.ts +39 -0
- package/dist/components/Accordion/index.js +70 -0
- package/dist/components/Accordion/index.js.map +1 -0
- package/dist/components/Avatar/index.d.ts +48 -0
- package/dist/components/Avatar/index.js +71 -0
- package/dist/components/Avatar/index.js.map +1 -0
- package/dist/components/Badge/index.js +10 -15
- package/dist/components/Badge/index.js.map +1 -1
- package/dist/components/Button/index.js +62 -89
- package/dist/components/Button/index.js.map +1 -1
- package/dist/components/Card/index.d.ts +142 -0
- package/dist/components/Card/index.js +368 -69
- package/dist/components/Card/index.js.map +1 -1
- package/dist/components/Chart/Chart.js +25 -25
- package/dist/components/Chart/Chart.js.map +1 -1
- package/dist/components/Checkbox/index.js +57 -65
- package/dist/components/Checkbox/index.js.map +1 -1
- package/dist/components/ChoicePicker/index.d.ts +44 -0
- package/dist/components/ChoicePicker/index.js +81 -0
- package/dist/components/ChoicePicker/index.js.map +1 -0
- package/dist/components/Column/index.d.ts +28 -0
- package/dist/components/Column/index.js +30 -0
- package/dist/components/Column/index.js.map +1 -0
- package/dist/components/DateTimeInput/index.d.ts +44 -0
- package/dist/components/DateTimeInput/index.js +48 -0
- package/dist/components/DateTimeInput/index.js.map +1 -0
- package/dist/components/Demo/index.js +107 -107
- package/dist/components/Demo/index.js.map +1 -1
- package/dist/components/Divider/index.d.ts +20 -0
- package/dist/components/Divider/index.js +30 -0
- package/dist/components/Divider/index.js.map +1 -0
- package/dist/components/EmptyState/index.js +24 -24
- package/dist/components/EmptyState/index.js.map +1 -1
- package/dist/components/FileUploader/DropZone.js +134 -136
- package/dist/components/FileUploader/DropZone.js.map +1 -1
- package/dist/components/FileUploader/FileItem.js +159 -163
- package/dist/components/FileUploader/FileItem.js.map +1 -1
- package/dist/components/FileUploader/FileUploader.js +126 -127
- package/dist/components/FileUploader/FileUploader.js.map +1 -1
- package/dist/components/FileUploader/UploadQueue.js +62 -62
- package/dist/components/FileUploader/UploadQueue.js.map +1 -1
- package/dist/components/FloatWindow/index.d.ts +28 -0
- package/dist/components/GridLayout/index.d.ts +42 -0
- package/dist/components/Icon/index.d.ts +26 -0
- package/dist/components/Icon/index.js +27 -0
- package/dist/components/Icon/index.js.map +1 -0
- package/dist/components/Image/index.d.ts +33 -0
- package/dist/components/Image/index.js +44 -0
- package/dist/components/Image/index.js.map +1 -0
- package/dist/components/Input/index.js +196 -197
- package/dist/components/Input/index.js.map +1 -1
- package/dist/components/Label/index.js +62 -74
- package/dist/components/Label/index.js.map +1 -1
- package/dist/components/Layout/index.js +134 -139
- package/dist/components/Layout/index.js.map +1 -1
- package/dist/components/List/index.js +45 -58
- package/dist/components/List/index.js.map +1 -1
- package/dist/components/Markdown/Markdown.js +106 -107
- package/dist/components/Markdown/Markdown.js.map +1 -1
- package/dist/components/Markdown/codeThemes.js +24 -33
- package/dist/components/Markdown/codeThemes.js.map +1 -1
- package/dist/components/Markdown/markdownComponents.js +203 -208
- package/dist/components/Markdown/markdownComponents.js.map +1 -1
- package/dist/components/Markdown/parseCodeBlockMeta.js +22 -22
- package/dist/components/Markdown/parseCodeBlockMeta.js.map +1 -1
- package/dist/components/Markdown/useMarkdownSource.js +46 -46
- package/dist/components/Markdown/useMarkdownSource.js.map +1 -1
- package/dist/components/Markdown/useMarkmapRenderer.js +35 -36
- package/dist/components/Markdown/useMarkmapRenderer.js.map +1 -1
- package/dist/components/Markdown/useMermaidRenderer.js +41 -42
- package/dist/components/Markdown/useMermaidRenderer.js.map +1 -1
- package/dist/components/Modal/index.js +82 -82
- package/dist/components/Modal/index.js.map +1 -1
- package/dist/components/MultipleChoice/index.d.ts +44 -0
- package/dist/components/MultipleChoice/index.js +52 -0
- package/dist/components/MultipleChoice/index.js.map +1 -0
- package/dist/components/Notification/index.d.ts +17 -0
- package/dist/components/Page/index.d.ts +1 -1
- package/dist/components/Page/index.js +40 -71
- package/dist/components/Page/index.js.map +1 -1
- package/dist/components/PageHeader/index.js +28 -28
- package/dist/components/PageHeader/index.js.map +1 -1
- package/dist/components/ProtectedRoute/index.js +8 -9
- package/dist/components/ProtectedRoute/index.js.map +1 -1
- package/dist/components/Row/index.d.ts +28 -0
- package/dist/components/Row/index.js +30 -0
- package/dist/components/Row/index.js.map +1 -0
- package/dist/components/Select/index.js +251 -254
- package/dist/components/Select/index.js.map +1 -1
- package/dist/components/SidebarToggleButton/index.js +56 -59
- package/dist/components/SidebarToggleButton/index.js.map +1 -1
- package/dist/components/Slider/index.d.ts +39 -0
- package/dist/components/Slider/index.js +52 -0
- package/dist/components/Slider/index.js.map +1 -0
- package/dist/components/Switch/index.d.ts +34 -0
- package/dist/components/Switch/index.js +55 -0
- package/dist/components/Switch/index.js.map +1 -0
- package/dist/components/Tab/index.d.ts +40 -0
- package/dist/components/Table/index.js +109 -121
- package/dist/components/Table/index.js.map +1 -1
- package/dist/components/Tabs/index.js +28 -38
- package/dist/components/Tabs/index.js.map +1 -1
- package/dist/components/Text/index.d.ts +43 -0
- package/dist/components/Text/index.js +55 -0
- package/dist/components/Text/index.js.map +1 -0
- package/dist/components/Tooltip/index.d.ts +23 -0
- package/dist/components/Tooltip/index.js +34 -0
- package/dist/components/Tooltip/index.js.map +1 -0
- package/dist/components/Tree/Tree.js +205 -205
- package/dist/components/Tree/Tree.js.map +1 -1
- package/dist/components/pro/ArticleContextMenu/index.js +86 -87
- package/dist/components/pro/ArticleContextMenu/index.js.map +1 -1
- package/dist/components/pro/ArticleControl/ArticleControl2.js +250 -250
- package/dist/components/pro/ArticleControl/ArticleControl2.js.map +1 -1
- package/dist/components/pro/ArticleControl/buildHeadingTree.js +31 -32
- package/dist/components/pro/ArticleControl/buildHeadingTree.js.map +1 -1
- package/dist/components/pro/ArticleControl/useArticleToc.js +100 -102
- package/dist/components/pro/ArticleControl/useArticleToc.js.map +1 -1
- package/dist/components/pro/Calendar/Calendar.d.ts +10 -0
- package/dist/components/pro/Calendar/hooks/useCalendarDrag.d.ts +47 -0
- package/dist/components/pro/Calendar/hooks/useCalendarState.d.ts +56 -0
- package/dist/components/pro/Calendar/index.d.ts +7 -0
- package/dist/components/pro/Calendar/types.d.ts +151 -0
- package/dist/components/pro/Calendar/utils.d.ts +94 -0
- package/dist/components/pro/Chat/Chat.d.ts +6 -0
- package/dist/components/pro/Chat/index.d.ts +2 -0
- package/dist/components/pro/Chat/types.d.ts +84 -0
- package/dist/components/pro/CodeEditor/editors/CodeEditor.js +287 -327
- package/dist/components/pro/CodeEditor/editors/CodeEditor.js.map +1 -1
- package/dist/components/pro/CodeEditor/editors/MarkdownEditor.js +167 -224
- package/dist/components/pro/CodeEditor/editors/MarkdownEditor.js.map +1 -1
- package/dist/components/pro/CodeEditor/editors/markdownExtensions.js +594 -613
- package/dist/components/pro/CodeEditor/editors/markdownExtensions.js.map +1 -1
- package/dist/components/pro/CodeEditor/extensions/contextMenu.js +54 -55
- package/dist/components/pro/CodeEditor/extensions/contextMenu.js.map +1 -1
- package/dist/components/pro/CodeEditor/extensions/index.js +152 -160
- package/dist/components/pro/CodeEditor/extensions/index.js.map +1 -1
- package/dist/components/pro/CodeEditor/langs/index.js +7 -15
- package/dist/components/pro/CodeEditor/langs/index.js.map +1 -1
- package/dist/components/pro/CodeEditor/langs/javascript.js +11 -48
- package/dist/components/pro/CodeEditor/langs/javascript.js.map +1 -1
- package/dist/components/pro/CodeEditor/langs/python.js +4 -40
- package/dist/components/pro/CodeEditor/langs/python.js.map +1 -1
- package/dist/components/pro/CodeEditor/langs/snippets.js +118 -147
- package/dist/components/pro/CodeEditor/langs/snippets.js.map +1 -1
- package/dist/components/pro/CodeEditor/panels/FootnotePanel.js +153 -153
- package/dist/components/pro/CodeEditor/panels/FootnotePanel.js.map +1 -1
- package/dist/components/pro/CodeEditor/panels/HistoryPanel.js +180 -190
- package/dist/components/pro/CodeEditor/panels/HistoryPanel.js.map +1 -1
- package/dist/components/pro/CodeEditor/panels/OutlinePanel.js +130 -137
- package/dist/components/pro/CodeEditor/panels/OutlinePanel.js.map +1 -1
- package/dist/components/pro/CodeEditor/panels/TableOfContentsPanel.js +228 -242
- package/dist/components/pro/CodeEditor/panels/TableOfContentsPanel.js.map +1 -1
- package/dist/components/pro/CodeEditor/panels/VariablePanel.js +208 -248
- package/dist/components/pro/CodeEditor/panels/VariablePanel.js.map +1 -1
- package/dist/components/pro/CodeEditor/themes.js +513 -483
- package/dist/components/pro/CodeEditor/themes.js.map +1 -1
- package/dist/components/pro/CodeEditor/types.d.ts +1 -1
- package/dist/components/pro/CodeEditor/utils.js +171 -175
- package/dist/components/pro/CodeEditor/utils.js.map +1 -1
- package/dist/components/pro/DataTable/DataTable.js +305 -306
- package/dist/components/pro/DataTable/DataTable.js.map +1 -1
- package/dist/components/pro/DataTable/Filters.js +299 -314
- package/dist/components/pro/DataTable/Filters.js.map +1 -1
- package/dist/components/pro/DataTable/PivotPanel.js +203 -204
- package/dist/components/pro/DataTable/PivotPanel.js.map +1 -1
- package/dist/components/pro/DataTable/PivotView.js +142 -144
- package/dist/components/pro/DataTable/PivotView.js.map +1 -1
- package/dist/components/pro/DataTable/components/BulkActions.js +42 -42
- package/dist/components/pro/DataTable/components/BulkActions.js.map +1 -1
- package/dist/components/pro/DataTable/components/ColumnSelector.js +84 -84
- package/dist/components/pro/DataTable/components/ColumnSelector.js.map +1 -1
- package/dist/components/pro/DataTable/components/FilterBar.js +58 -58
- package/dist/components/pro/DataTable/components/FilterBar.js.map +1 -1
- package/dist/components/pro/DataTable/components/TableBody.js +93 -94
- package/dist/components/pro/DataTable/components/TableBody.js.map +1 -1
- package/dist/components/pro/DataTable/components/TableHeader.js +78 -78
- package/dist/components/pro/DataTable/components/TableHeader.js.map +1 -1
- package/dist/components/pro/DataTable/components/TablePagination.js +77 -77
- package/dist/components/pro/DataTable/components/TablePagination.js.map +1 -1
- package/dist/components/pro/DataTable/components/TableToolbar.js +40 -40
- package/dist/components/pro/DataTable/components/TableToolbar.js.map +1 -1
- package/dist/components/pro/DataTable/extension.js +5 -5
- package/dist/components/pro/DataTable/extension.js.map +1 -1
- package/dist/components/pro/DataTable/pivotEngine.js +84 -92
- package/dist/components/pro/DataTable/pivotEngine.js.map +1 -1
- package/dist/components/pro/DataTable/pivotExtension.js +93 -93
- package/dist/components/pro/DataTable/pivotExtension.js.map +1 -1
- package/dist/components/pro/DataTable/rowDetailExtension.js +30 -30
- package/dist/components/pro/DataTable/rowDetailExtension.js.map +1 -1
- package/dist/components/pro/DataTable/tanstack-table.js +45 -62
- package/dist/components/pro/DataTable/tanstack-table.js.map +1 -1
- package/dist/components/pro/DataTable/treeDataUtils.js +37 -48
- package/dist/components/pro/DataTable/treeDataUtils.js.map +1 -1
- package/dist/components/pro/DataTable/useColumnDragReorder.js +68 -68
- package/dist/components/pro/DataTable/useColumnDragReorder.js.map +1 -1
- package/dist/components/pro/DataTable/utils.js +156 -168
- package/dist/components/pro/DataTable/utils.js.map +1 -1
- package/dist/components/pro/FileExplorer/Breadcrumb.js +180 -180
- package/dist/components/pro/FileExplorer/Breadcrumb.js.map +1 -1
- package/dist/components/pro/FileExplorer/CreateDialog.js +78 -78
- package/dist/components/pro/FileExplorer/CreateDialog.js.map +1 -1
- package/dist/components/pro/FileExplorer/FileExplorer.js +202 -205
- package/dist/components/pro/FileExplorer/FileExplorer.js.map +1 -1
- package/dist/components/pro/FileExplorer/FileIcon.js +189 -189
- package/dist/components/pro/FileExplorer/FileIcon.js.map +1 -1
- package/dist/components/pro/FileExplorer/GridView.js +100 -100
- package/dist/components/pro/FileExplorer/GridView.js.map +1 -1
- package/dist/components/pro/FileExplorer/ListView.js +209 -209
- package/dist/components/pro/FileExplorer/ListView.js.map +1 -1
- package/dist/components/pro/FileExplorer/Toolbar.js +199 -199
- package/dist/components/pro/FileExplorer/Toolbar.js.map +1 -1
- package/dist/components/pro/Flow/Flow.js +920 -948
- package/dist/components/pro/Flow/Flow.js.map +1 -1
- package/dist/components/pro/Flow/FlowCanvas.js +1626 -1662
- package/dist/components/pro/Flow/FlowCanvas.js.map +1 -1
- package/dist/components/pro/Flow/archify/build.js +85 -94
- package/dist/components/pro/Flow/archify/build.js.map +1 -1
- package/dist/components/pro/Flow/archify/convert.js +512 -519
- package/dist/components/pro/Flow/archify/convert.js.map +1 -1
- package/dist/components/pro/Flow/archify/palette.js +87 -104
- package/dist/components/pro/Flow/archify/palette.js.map +1 -1
- package/dist/components/pro/Flow/archify/presets.js +34 -37
- package/dist/components/pro/Flow/archify/presets.js.map +1 -1
- package/dist/components/pro/Flow/archify/spec.js +7 -7
- package/dist/components/pro/Flow/archify/spec.js.map +1 -1
- package/dist/components/pro/Flow/canvas/AlignmentGuides.js +25 -25
- package/dist/components/pro/Flow/canvas/AlignmentGuides.js.map +1 -1
- package/dist/components/pro/Flow/canvas/GridRenderer.js +54 -55
- package/dist/components/pro/Flow/canvas/GridRenderer.js.map +1 -1
- package/dist/components/pro/Flow/canvas/MiniMapRenderer.js +54 -58
- package/dist/components/pro/Flow/canvas/MiniMapRenderer.js.map +1 -1
- package/dist/components/pro/Flow/canvas/PixiApp.js +105 -102
- package/dist/components/pro/Flow/canvas/PixiApp.js.map +1 -1
- package/dist/components/pro/Flow/canvas/SelectionOverlay.js +38 -38
- package/dist/components/pro/Flow/canvas/SelectionOverlay.js.map +1 -1
- package/dist/components/pro/Flow/canvas/ViewportContainer.js +117 -117
- package/dist/components/pro/Flow/canvas/ViewportContainer.js.map +1 -1
- package/dist/components/pro/Flow/constants.js +266 -278
- package/dist/components/pro/Flow/constants.js.map +1 -1
- package/dist/components/pro/Flow/context/FlowAIContext.js +27 -28
- package/dist/components/pro/Flow/context/FlowAIContext.js.map +1 -1
- package/dist/components/pro/Flow/context/FlowContext.js +60 -61
- package/dist/components/pro/Flow/context/FlowContext.js.map +1 -1
- package/dist/components/pro/Flow/context/FlowUIContext.js +115 -117
- package/dist/components/pro/Flow/context/FlowUIContext.js.map +1 -1
- package/dist/components/pro/Flow/edges/EdgeRenderer.js +135 -138
- package/dist/components/pro/Flow/edges/EdgeRenderer.js.map +1 -1
- package/dist/components/pro/Flow/edges/edgeMarkers.js +11 -14
- package/dist/components/pro/Flow/edges/edgeMarkers.js.map +1 -1
- package/dist/components/pro/Flow/edges/edgePaths.js +351 -367
- package/dist/components/pro/Flow/edges/edgePaths.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useAlignmentGuides.js +49 -52
- package/dist/components/pro/Flow/hooks/useAlignmentGuides.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useClipboard.js +154 -154
- package/dist/components/pro/Flow/hooks/useClipboard.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useCompactMode.js +17 -17
- package/dist/components/pro/Flow/hooks/useCompactMode.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useDeleteSelection.js +40 -40
- package/dist/components/pro/Flow/hooks/useDeleteSelection.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useDraggablePanel.js +51 -51
- package/dist/components/pro/Flow/hooks/useDraggablePanel.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useEdgeMutations.js +157 -157
- package/dist/components/pro/Flow/hooks/useEdgeMutations.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useFlowImportExport.js +190 -201
- package/dist/components/pro/Flow/hooks/useFlowImportExport.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useKeyboardShortcuts.js +32 -38
- package/dist/components/pro/Flow/hooks/useKeyboardShortcuts.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useLayoutActions.js +172 -180
- package/dist/components/pro/Flow/hooks/useLayoutActions.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useLineMutations.js +57 -57
- package/dist/components/pro/Flow/hooks/useLineMutations.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useMindMap.js +229 -238
- package/dist/components/pro/Flow/hooks/useMindMap.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useNodeMutations.js +102 -102
- package/dist/components/pro/Flow/hooks/useNodeMutations.js.map +1 -1
- package/dist/components/pro/Flow/hooks/usePdfExport.js +55 -56
- package/dist/components/pro/Flow/hooks/usePdfExport.js.map +1 -1
- package/dist/components/pro/Flow/hooks/usePixiApp.js +55 -57
- package/dist/components/pro/Flow/hooks/usePixiApp.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useResizablePanel.js +31 -31
- package/dist/components/pro/Flow/hooks/useResizablePanel.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useSelection.js +69 -69
- package/dist/components/pro/Flow/hooks/useSelection.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useUndoRedo.js +27 -27
- package/dist/components/pro/Flow/hooks/useUndoRedo.js.map +1 -1
- package/dist/components/pro/Flow/hooks/useViewport.js +28 -28
- package/dist/components/pro/Flow/hooks/useViewport.js.map +1 -1
- package/dist/components/pro/Flow/lines/FreehandTool.js +63 -63
- package/dist/components/pro/Flow/lines/FreehandTool.js.map +1 -1
- package/dist/components/pro/Flow/lines/GeometricLineTool.js +80 -80
- package/dist/components/pro/Flow/lines/GeometricLineTool.js.map +1 -1
- package/dist/components/pro/Flow/lines/LineRenderer.js +88 -88
- package/dist/components/pro/Flow/lines/LineRenderer.js.map +1 -1
- package/dist/components/pro/Flow/lines/lineSmoothing.js +32 -34
- package/dist/components/pro/Flow/lines/lineSmoothing.js.map +1 -1
- package/dist/components/pro/Flow/nodes/DataNodeView.js +236 -242
- package/dist/components/pro/Flow/nodes/DataNodeView.js.map +1 -1
- package/dist/components/pro/Flow/nodes/MediaContent.js +236 -246
- package/dist/components/pro/Flow/nodes/MediaContent.js.map +1 -1
- package/dist/components/pro/Flow/nodes/MediaOverlay.js +63 -63
- package/dist/components/pro/Flow/nodes/MediaOverlay.js.map +1 -1
- package/dist/components/pro/Flow/nodes/Model3DView.js +111 -113
- package/dist/components/pro/Flow/nodes/Model3DView.js.map +1 -1
- package/dist/components/pro/Flow/nodes/NodeHandles.js +74 -80
- package/dist/components/pro/Flow/nodes/NodeHandles.js.map +1 -1
- package/dist/components/pro/Flow/nodes/NodeRenderer.js +303 -314
- package/dist/components/pro/Flow/nodes/NodeRenderer.js.map +1 -1
- package/dist/components/pro/Flow/nodes/NodeText.js +25 -29
- package/dist/components/pro/Flow/nodes/NodeText.js.map +1 -1
- package/dist/components/pro/Flow/nodes/aiClient.js +124 -137
- package/dist/components/pro/Flow/nodes/aiClient.js.map +1 -1
- package/dist/components/pro/Flow/nodes/animAnchors.js +42 -49
- package/dist/components/pro/Flow/nodes/animAnchors.js.map +1 -1
- package/dist/components/pro/Flow/nodes/dataUtils.js +246 -267
- package/dist/components/pro/Flow/nodes/dataUtils.js.map +1 -1
- package/dist/components/pro/Flow/nodes/nodeUtils.js +23 -28
- package/dist/components/pro/Flow/nodes/nodeUtils.js.map +1 -1
- package/dist/components/pro/Flow/nodes/shapes.js +556 -589
- package/dist/components/pro/Flow/nodes/shapes.js.map +1 -1
- package/dist/components/pro/Flow/nodes/svgIconTexture.js +37 -39
- package/dist/components/pro/Flow/nodes/svgIconTexture.js.map +1 -1
- package/dist/components/pro/Flow/nodes/svgIcons.js +684 -689
- package/dist/components/pro/Flow/nodes/svgIcons.js.map +1 -1
- package/dist/components/pro/Flow/panels/AIPanel.js +464 -491
- package/dist/components/pro/Flow/panels/AIPanel.js.map +1 -1
- package/dist/components/pro/Flow/panels/Breadcrumb.js +41 -41
- package/dist/components/pro/Flow/panels/Breadcrumb.js.map +1 -1
- package/dist/components/pro/Flow/panels/ContextMenu.js +37 -37
- package/dist/components/pro/Flow/panels/ContextMenu.js.map +1 -1
- package/dist/components/pro/Flow/panels/DataInspectorSection.js +428 -432
- package/dist/components/pro/Flow/panels/DataInspectorSection.js.map +1 -1
- package/dist/components/pro/Flow/panels/ExpandableTextarea.js +61 -62
- package/dist/components/pro/Flow/panels/ExpandableTextarea.js.map +1 -1
- package/dist/components/pro/Flow/panels/FlowPanelGroup.js +114 -114
- package/dist/components/pro/Flow/panels/FlowPanelGroup.js.map +1 -1
- package/dist/components/pro/Flow/panels/FlowToolbar.js +347 -391
- package/dist/components/pro/Flow/panels/FlowToolbar.js.map +1 -1
- package/dist/components/pro/Flow/panels/InspectorPanel.js +1792 -1798
- package/dist/components/pro/Flow/panels/InspectorPanel.js.map +1 -1
- package/dist/components/pro/Flow/panels/OutlinePanel.js +242 -248
- package/dist/components/pro/Flow/panels/OutlinePanel.js.map +1 -1
- package/dist/components/pro/Flow/panels/PresentationMode.js +137 -140
- package/dist/components/pro/Flow/panels/PresentationMode.js.map +1 -1
- package/dist/components/pro/Flow/panels/ProjectTitle.js +46 -46
- package/dist/components/pro/Flow/panels/ProjectTitle.js.map +1 -1
- package/dist/components/pro/Flow/panels/ShapePalette.js +557 -572
- package/dist/components/pro/Flow/panels/ShapePalette.js.map +1 -1
- package/dist/components/pro/Flow/panels/toolbarIcons.d.ts +0 -1
- package/dist/components/pro/Flow/panels/toolbarIcons.js +508 -557
- package/dist/components/pro/Flow/panels/toolbarIcons.js.map +1 -1
- package/dist/components/pro/Flow/types.js +26 -26
- package/dist/components/pro/Flow/types.js.map +1 -1
- package/dist/components/pro/Flow/utils/dashedLine.js +113 -117
- package/dist/components/pro/Flow/utils/dashedLine.js.map +1 -1
- package/dist/components/pro/Flow/utils/gradient.js +55 -55
- package/dist/components/pro/Flow/utils/gradient.js.map +1 -1
- package/dist/components/pro/Flow/utils/pdfExport.js +50 -89
- package/dist/components/pro/Flow/utils/pdfExport.js.map +1 -1
- package/dist/components/pro/Flow/utils/themeColor.js +185 -195
- package/dist/components/pro/Flow/utils/themeColor.js.map +1 -1
- package/dist/components/pro/Gantt/Gantt.d.ts +7 -0
- package/dist/components/pro/Gantt/hooks/useGanttDrag.d.ts +31 -0
- package/dist/components/pro/Gantt/hooks/useGanttState.d.ts +58 -0
- package/dist/components/pro/Gantt/index.d.ts +6 -0
- package/dist/components/pro/Gantt/types.d.ts +478 -0
- package/dist/components/pro/Gantt/utils.d.ts +124 -0
- package/dist/components/pro/Resizable/Resizable.d.ts +30 -0
- package/dist/components/pro/Resizable/index.d.ts +2 -0
- package/dist/components/pro/RichTextEditor/AIRewrite.js +323 -334
- package/dist/components/pro/RichTextEditor/AIRewrite.js.map +1 -1
- package/dist/components/pro/RichTextEditor/BlockHandle.js +314 -316
- package/dist/components/pro/RichTextEditor/BlockHandle.js.map +1 -1
- package/dist/components/pro/RichTextEditor/BubbleToolbar.js +97 -97
- package/dist/components/pro/RichTextEditor/BubbleToolbar.js.map +1 -1
- package/dist/components/pro/RichTextEditor/CommentDialog.js +88 -88
- package/dist/components/pro/RichTextEditor/CommentDialog.js.map +1 -1
- package/dist/components/pro/RichTextEditor/CommentPanel.js +240 -240
- package/dist/components/pro/RichTextEditor/CommentPanel.js.map +1 -1
- package/dist/components/pro/RichTextEditor/CommentPopover.js +234 -234
- package/dist/components/pro/RichTextEditor/CommentPopover.js.map +1 -1
- package/dist/components/pro/RichTextEditor/ContextMenu.js +251 -252
- package/dist/components/pro/RichTextEditor/ContextMenu.js.map +1 -1
- package/dist/components/pro/RichTextEditor/RichTextEditor.js +267 -271
- package/dist/components/pro/RichTextEditor/RichTextEditor.js.map +1 -1
- package/dist/components/pro/RichTextEditor/SlashMenu.js +214 -214
- package/dist/components/pro/RichTextEditor/SlashMenu.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/ColorPicker.js +44 -75
- package/dist/components/pro/RichTextEditor/Toolbar/ColorPicker.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/FloatingDialogMenu.js +261 -261
- package/dist/components/pro/RichTextEditor/Toolbar/FloatingDialogMenu.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/MarkdownTemplates.js +172 -526
- package/dist/components/pro/RichTextEditor/Toolbar/MarkdownTemplates.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/SelectDropdown.js +112 -114
- package/dist/components/pro/RichTextEditor/Toolbar/SelectDropdown.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/TableOpsMenu.js +194 -194
- package/dist/components/pro/RichTextEditor/Toolbar/TableOpsMenu.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/Toolbar.js +970 -973
- package/dist/components/pro/RichTextEditor/Toolbar/Toolbar.js.map +1 -1
- package/dist/components/pro/RichTextEditor/Toolbar/ToolbarButton.js +11 -12
- package/dist/components/pro/RichTextEditor/Toolbar/ToolbarButton.js.map +1 -1
- package/dist/components/pro/RichTextEditor/extensions/CodeBlockView.js +310 -344
- package/dist/components/pro/RichTextEditor/extensions/CodeBlockView.js.map +1 -1
- package/dist/components/pro/RichTextEditor/extensions/CommentMark.js +38 -39
- package/dist/components/pro/RichTextEditor/extensions/CommentMark.js.map +1 -1
- package/dist/components/pro/RichTextEditor/extensions/FloatingDialog.js +620 -625
- package/dist/components/pro/RichTextEditor/extensions/FloatingDialog.js.map +1 -1
- package/dist/components/pro/RichTextEditor/extensions/FontSize.js +25 -25
- package/dist/components/pro/RichTextEditor/extensions/FontSize.js.map +1 -1
- package/dist/components/pro/RichTextEditor/extensions/MarkdownBlock.js +167 -176
- package/dist/components/pro/RichTextEditor/extensions/MarkdownBlock.js.map +1 -1
- package/dist/components/pro/RichTextEditor/types.js +75 -75
- package/dist/components/pro/RichTextEditor/types.js.map +1 -1
- package/dist/contexts/AppContext.d.ts +1 -1
- package/dist/contexts/AppContext.js +216 -221
- package/dist/contexts/AppContext.js.map +1 -1
- package/dist/data-table.js +15 -41
- package/dist/data-table.js.map +1 -1
- package/dist/dishui.css +1 -1
- package/dist/flow.js +27 -83
- package/dist/hooks/useClickOutside.js +18 -18
- package/dist/hooks/useClickOutside.js.map +1 -1
- package/dist/hooks/useContainerElement.js +9 -9
- package/dist/hooks/useContainerElement.js.map +1 -1
- package/dist/hooks/useControllableState.js +33 -35
- package/dist/hooks/useControllableState.js.map +1 -1
- package/dist/hooks/useCopyToClipboard.js +16 -16
- package/dist/hooks/useCopyToClipboard.js.map +1 -1
- package/dist/hooks/useDebounce.js +14 -14
- package/dist/hooks/useDebounce.js.map +1 -1
- package/dist/hooks/useDraggable.js +50 -50
- package/dist/hooks/useDraggable.js.map +1 -1
- package/dist/hooks/useTableColumns.js +39 -41
- package/dist/hooks/useTableColumns.js.map +1 -1
- package/dist/hooks/useTableData.js +67 -68
- package/dist/hooks/useTableData.js.map +1 -1
- package/dist/index-nostyled.d.ts +8 -0
- package/dist/index.d.ts +31 -3
- package/dist/index.js +106 -241
- package/dist/layouts/MainLayout.js +56 -56
- package/dist/layouts/MainLayout.js.map +1 -1
- package/dist/layouts/Navbar.js +214 -214
- package/dist/layouts/Navbar.js.map +1 -1
- package/dist/layouts/Sidebar.js +184 -186
- package/dist/layouts/Sidebar.js.map +1 -1
- package/dist/layouts/headbar/Headbar.js +25 -25
- package/dist/layouts/headbar/Headbar.js.map +1 -1
- package/dist/layouts/headbar/HeadbarLangSwitcher.js +39 -39
- package/dist/layouts/headbar/HeadbarLangSwitcher.js.map +1 -1
- package/dist/layouts/headbar/HeadbarSearch.js +120 -120
- package/dist/layouts/headbar/HeadbarSearch.js.map +1 -1
- package/dist/layouts/headbar/HeadbarThemeSwitcher.js +27 -27
- package/dist/layouts/headbar/HeadbarThemeSwitcher.js.map +1 -1
- package/dist/layouts/headbar/HeadbarTitle.js +26 -26
- package/dist/layouts/headbar/HeadbarTitle.js.map +1 -1
- package/dist/lite.js +9 -24
- package/dist/markdown.js +4 -9
- package/dist/pages/components/Calendar/index.d.ts +3 -0
- package/dist/pages/components/Calendar/index.en.d.ts +3 -0
- package/dist/pages/components/Calendar/index.zh.d.ts +3 -0
- package/dist/pages/components/Chat/index.d.ts +3 -0
- package/dist/pages/components/Chat/index.en.d.ts +3 -0
- package/dist/pages/components/Chat/index.zh.d.ts +3 -0
- package/dist/pages/components/FloatWindow/index.d.ts +3 -0
- package/dist/pages/components/FloatWindow/index.en.d.ts +3 -0
- package/dist/pages/components/FloatWindow/index.zh.d.ts +3 -0
- package/dist/pages/components/Gantt/index.d.ts +3 -0
- package/dist/pages/components/Gantt/index.en.d.ts +3 -0
- package/dist/pages/components/Gantt/index.zh.d.ts +3 -0
- package/dist/pages/components/GridLayout/index.d.ts +3 -0
- package/dist/pages/components/GridLayout/index.en.d.ts +3 -0
- package/dist/pages/components/GridLayout/index.zh.d.ts +3 -0
- package/dist/pages/components/Notification/index.d.ts +3 -0
- package/dist/pages/components/Notification/index.en.d.ts +3 -0
- package/dist/pages/components/Notification/index.zh.d.ts +3 -0
- package/dist/pages/components/Resizable/index.d.ts +3 -0
- package/dist/pages/components/Resizable/index.en.d.ts +3 -0
- package/dist/pages/components/Resizable/index.zh.d.ts +3 -0
- package/dist/pages/components/Tab/index.d.ts +3 -0
- package/dist/pages/components/Tab/index.en.d.ts +3 -0
- package/dist/pages/components/Tab/index.zh.d.ts +3 -0
- package/dist/styles/themeStyles.js +87 -86
- package/dist/styles/themeStyles.js.map +1 -1
- package/dist/utils/cn.d.ts +13 -0
- package/dist/utils/cn.js +16 -0
- package/dist/utils/cn.js.map +1 -0
- package/dist/utils/i18n.js +700 -602
- package/dist/utils/i18n.js.map +1 -1
- package/dist/utils/menu.js +94 -94
- package/dist/utils/menu.js.map +1 -1
- package/dist/utils/rehype-code-meta.js +14 -14
- package/dist/utils/rehype-code-meta.js.map +1 -1
- package/dist/utils/remark-code-meta.js +9 -9
- package/dist/utils/remark-code-meta.js.map +1 -1
- package/dist/utils/routerBuilder.js +59 -60
- package/dist/utils/routerBuilder.js.map +1 -1
- package/dist/utils/selection.js +28 -29
- package/dist/utils/selection.js.map +1 -1
- package/dist/utils/themes.js +275 -255
- package/dist/utils/themes.js.map +1 -1
- package/package.json +19 -6
- package/dist/components/StatCard/index.d.ts +0 -24
- package/dist/components/StatCard/index.js +0 -90
- package/dist/components/StatCard/index.js.map +0 -1
|
@@ -1,282 +1,270 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
"solid",
|
|
210
|
-
"dashed",
|
|
211
|
-
"dotted",
|
|
212
|
-
"dynamic"
|
|
213
|
-
], d = [
|
|
214
|
-
"solid",
|
|
215
|
-
"dashed",
|
|
216
|
-
"dotted",
|
|
217
|
-
"dynamic"
|
|
1
|
+
//#region src/components/pro/Flow/constants.ts
|
|
2
|
+
var e = "root", t = {
|
|
3
|
+
label: "Text",
|
|
4
|
+
fill: "theme:base-100",
|
|
5
|
+
stroke: "theme:base-content",
|
|
6
|
+
strokeWidth: 2,
|
|
7
|
+
color: "theme:base-content",
|
|
8
|
+
fontSize: 14,
|
|
9
|
+
attributes: []
|
|
10
|
+
}, n = {
|
|
11
|
+
label: "Label",
|
|
12
|
+
fill: "transparent",
|
|
13
|
+
stroke: "transparent",
|
|
14
|
+
strokeWidth: 0,
|
|
15
|
+
color: "theme:base-content",
|
|
16
|
+
fontSize: 14,
|
|
17
|
+
attributes: []
|
|
18
|
+
}, r = {
|
|
19
|
+
strokeColor: "theme:base-content",
|
|
20
|
+
strokeWidth: 2,
|
|
21
|
+
lineStyle: "solid",
|
|
22
|
+
markerEnd: "arrowclosed"
|
|
23
|
+
}, i = [
|
|
24
|
+
{
|
|
25
|
+
type: "shapeRect",
|
|
26
|
+
width: 140,
|
|
27
|
+
height: 72,
|
|
28
|
+
data: {
|
|
29
|
+
...t,
|
|
30
|
+
label: "Rectangle"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
type: "shapeRoundRect",
|
|
35
|
+
width: 140,
|
|
36
|
+
height: 72,
|
|
37
|
+
data: {
|
|
38
|
+
...t,
|
|
39
|
+
label: "Rounded"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
type: "shapeEllipse",
|
|
44
|
+
width: 120,
|
|
45
|
+
height: 120,
|
|
46
|
+
data: {
|
|
47
|
+
...t,
|
|
48
|
+
label: "Ellipse"
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
type: "shapeDiamond",
|
|
53
|
+
width: 120,
|
|
54
|
+
height: 120,
|
|
55
|
+
data: {
|
|
56
|
+
...t,
|
|
57
|
+
label: "Diamond"
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
type: "shapeDocument",
|
|
62
|
+
width: 120,
|
|
63
|
+
height: 80,
|
|
64
|
+
data: {
|
|
65
|
+
...t,
|
|
66
|
+
label: "Document"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
type: "shapeParallelogram",
|
|
71
|
+
width: 140,
|
|
72
|
+
height: 72,
|
|
73
|
+
data: {
|
|
74
|
+
...t,
|
|
75
|
+
label: "Parallelogram"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
type: "shapeTriangle",
|
|
80
|
+
width: 120,
|
|
81
|
+
height: 100,
|
|
82
|
+
data: {
|
|
83
|
+
...t,
|
|
84
|
+
label: "Triangle"
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
type: "shapeTrapezoid",
|
|
89
|
+
width: 140,
|
|
90
|
+
height: 72,
|
|
91
|
+
data: {
|
|
92
|
+
...t,
|
|
93
|
+
label: "Trapezoid"
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
type: "shapePentagon",
|
|
98
|
+
width: 100,
|
|
99
|
+
height: 100,
|
|
100
|
+
data: {
|
|
101
|
+
...t,
|
|
102
|
+
label: "Pentagon"
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
type: "shapeHexagon",
|
|
107
|
+
width: 120,
|
|
108
|
+
height: 100,
|
|
109
|
+
data: {
|
|
110
|
+
...t,
|
|
111
|
+
label: "Hexagon"
|
|
112
|
+
}
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
type: "shapeStar",
|
|
116
|
+
width: 100,
|
|
117
|
+
height: 100,
|
|
118
|
+
data: {
|
|
119
|
+
...t,
|
|
120
|
+
label: "Star"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
type: "shapeHexagram",
|
|
125
|
+
width: 100,
|
|
126
|
+
height: 100,
|
|
127
|
+
data: {
|
|
128
|
+
...t,
|
|
129
|
+
label: "Hexagram"
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
type: "shapeRightTriangle",
|
|
134
|
+
width: 120,
|
|
135
|
+
height: 100,
|
|
136
|
+
data: {
|
|
137
|
+
...t,
|
|
138
|
+
label: "Right Triangle"
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
type: "shapeCorner",
|
|
143
|
+
width: 100,
|
|
144
|
+
height: 100,
|
|
145
|
+
data: {
|
|
146
|
+
...t,
|
|
147
|
+
label: "Corner"
|
|
148
|
+
}
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
type: "textLabel",
|
|
152
|
+
width: 120,
|
|
153
|
+
height: 40,
|
|
154
|
+
data: {
|
|
155
|
+
...n,
|
|
156
|
+
label: "Label"
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
type: "animAnchor",
|
|
161
|
+
width: 320,
|
|
162
|
+
height: 240,
|
|
163
|
+
data: {
|
|
164
|
+
...t,
|
|
165
|
+
label: "Anchor",
|
|
166
|
+
fill: "transparent",
|
|
167
|
+
stroke: "#8b5cf6",
|
|
168
|
+
strokeWidth: 1.5,
|
|
169
|
+
borderStyle: "dashed"
|
|
170
|
+
}
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
type: "flowGroup",
|
|
174
|
+
width: 200,
|
|
175
|
+
height: 160,
|
|
176
|
+
data: {
|
|
177
|
+
...t,
|
|
178
|
+
label: "Group",
|
|
179
|
+
fill: "#f0f9ff",
|
|
180
|
+
stroke: "#9ca3af",
|
|
181
|
+
strokeWidth: 1.5,
|
|
182
|
+
borderStyle: "dotted",
|
|
183
|
+
isGroup: !0
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
type: "geometryGroup",
|
|
188
|
+
width: 200,
|
|
189
|
+
height: 160,
|
|
190
|
+
data: {
|
|
191
|
+
...t,
|
|
192
|
+
label: "Geo Group",
|
|
193
|
+
fill: "#fefce8",
|
|
194
|
+
stroke: "#9ca3af",
|
|
195
|
+
strokeWidth: 1.5,
|
|
196
|
+
borderStyle: "dashed",
|
|
197
|
+
isGroup: !0
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
], a = [
|
|
201
|
+
"smoothstep",
|
|
202
|
+
"step",
|
|
203
|
+
"straight",
|
|
204
|
+
"simplebezier"
|
|
205
|
+
], o = [
|
|
206
|
+
"none",
|
|
207
|
+
"arrow",
|
|
208
|
+
"arrowclosed"
|
|
218
209
|
], s = [
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
210
|
+
"solid",
|
|
211
|
+
"dashed",
|
|
212
|
+
"dotted",
|
|
213
|
+
"dynamic"
|
|
214
|
+
], c = [
|
|
215
|
+
"solid",
|
|
216
|
+
"dashed",
|
|
217
|
+
"dotted",
|
|
218
|
+
"dynamic"
|
|
219
|
+
], l = [
|
|
220
|
+
"sparse",
|
|
221
|
+
"medium",
|
|
222
|
+
"dense"
|
|
223
|
+
], u = [
|
|
224
|
+
{
|
|
225
|
+
value: "to-r",
|
|
226
|
+
label: "Left → Right"
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
value: "to-l",
|
|
230
|
+
label: "Right → Left"
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
value: "to-b",
|
|
234
|
+
label: "Top → Bottom"
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
value: "to-t",
|
|
238
|
+
label: "Bottom → Top"
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
value: "to-br",
|
|
242
|
+
label: "Top-Left → Bottom-Right"
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
value: "to-tl",
|
|
246
|
+
label: "Bottom-Right → Top-Left"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
value: "to-tr",
|
|
250
|
+
label: "Bottom-Left → Top-Right"
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
value: "to-bl",
|
|
254
|
+
label: "Top-Right → Bottom-Left"
|
|
255
|
+
}
|
|
256
|
+
], d = .1;
|
|
257
|
+
function f() {
|
|
258
|
+
return {
|
|
259
|
+
canvases: { [e]: {
|
|
260
|
+
nodes: [],
|
|
261
|
+
edges: [],
|
|
262
|
+
lines: []
|
|
263
|
+
} },
|
|
264
|
+
stack: [e]
|
|
265
|
+
};
|
|
265
266
|
}
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
s as DASH_DENSITY_OPTIONS,
|
|
269
|
-
l as DEFAULT_EDGE_DATA,
|
|
270
|
-
e as DEFAULT_NODE_DATA,
|
|
271
|
-
i as EDGE_LINE_STYLE_OPTIONS,
|
|
272
|
-
r as EDGE_MARKER_OPTIONS,
|
|
273
|
-
h as EDGE_TYPE_OPTIONS,
|
|
274
|
-
p as GRADIENT_DIRECTION_OPTIONS,
|
|
275
|
-
n as MIN_ZOOM,
|
|
276
|
-
o as PALETTE_ITEMS,
|
|
277
|
-
t as ROOT_CANVAS_ID,
|
|
278
|
-
a as TEXT_NODE_DATA,
|
|
279
|
-
b as createEmptyDocument
|
|
280
|
-
};
|
|
267
|
+
//#endregion
|
|
268
|
+
export { c as BORDER_STYLE_OPTIONS, l as DASH_DENSITY_OPTIONS, r as DEFAULT_EDGE_DATA, t as DEFAULT_NODE_DATA, s as EDGE_LINE_STYLE_OPTIONS, o as EDGE_MARKER_OPTIONS, a as EDGE_TYPE_OPTIONS, u as GRADIENT_DIRECTION_OPTIONS, d as MIN_ZOOM, i as PALETTE_ITEMS, e as ROOT_CANVAS_ID, n as TEXT_NODE_DATA, f as createEmptyDocument };
|
|
281
269
|
|
|
282
270
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","names":[],"sources":["../../../../src/components/pro/Flow/constants.ts"],"sourcesContent":["import type {\n FlowNodeData,\n FlowShapeType,\n FlowEdgeTypeName,\n FlowEdgeMarkerKind,\n FlowEdgeLineStyle,\n FlowEdgeDashDensity,\n FlowBorderStyle,\n GradientDirection,\n FlowDocument,\n FlowEdgeData,\n} from './types';\n\nexport const ROOT_CANVAS_ID = 'root';\n\nexport const DEFAULT_NODE_DATA: FlowNodeData = {\n label: 'Text',\n fill: 'theme:base-100',\n stroke: 'theme:base-content',\n strokeWidth: 2,\n color: 'theme:base-content',\n fontSize: 14,\n attributes: [],\n};\n\nexport const TEXT_NODE_DATA: FlowNodeData = {\n label: 'Label',\n fill: 'transparent',\n stroke: 'transparent',\n strokeWidth: 0,\n color: 'theme:base-content',\n fontSize: 14,\n attributes: [],\n};\n\nexport const DEFAULT_EDGE_DATA: FlowEdgeData = {\n strokeColor: 'theme:base-content',\n strokeWidth: 2,\n lineStyle: 'solid',\n markerEnd: 'arrowclosed',\n};\n\nexport const PALETTE_ITEMS: Array<{\n type: FlowShapeType;\n width: number;\n height: number;\n data: FlowNodeData;\n}> = [\n { type: 'shapeRect', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Rectangle' } },\n { type: 'shapeRoundRect', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Rounded' } },\n { type: 'shapeEllipse', width: 120, height: 120, data: { ...DEFAULT_NODE_DATA, label: 'Ellipse' } },\n { type: 'shapeDiamond', width: 120, height: 120, data: { ...DEFAULT_NODE_DATA, label: 'Diamond' } },\n { type: 'shapeDocument', width: 120, height: 80, data: { ...DEFAULT_NODE_DATA, label: 'Document' } },\n { type: 'shapeParallelogram', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Parallelogram' } },\n { type: 'shapeTriangle', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Triangle' } },\n { type: 'shapeTrapezoid', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Trapezoid' } },\n { type: 'shapePentagon', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Pentagon' } },\n { type: 'shapeHexagon', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Hexagon' } },\n { type: 'shapeStar', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Star' } },\n { type: 'shapeHexagram', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Hexagram' } },\n { type: 'shapeRightTriangle', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Right Triangle' } },\n { type: 'shapeCorner', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Corner' } },\n { type: 'textLabel', width: 120, height: 40, data: { ...TEXT_NODE_DATA, label: 'Label' } },\n { type: 'animAnchor', width: 320, height: 240, data: { ...DEFAULT_NODE_DATA, label: 'Anchor', fill: 'transparent', stroke: '#8b5cf6', strokeWidth: 1.5, borderStyle: 'dashed' } },\n { type: 'flowGroup', width: 200, height: 160, data: { ...DEFAULT_NODE_DATA, label: 'Group', fill: '#f0f9ff', stroke: '#9ca3af', strokeWidth: 1.5, borderStyle: 'dotted', isGroup: true } },\n { type: 'geometryGroup', width: 200, height: 160, data: { ...DEFAULT_NODE_DATA, label: 'Geo Group', fill: '#fefce8', stroke: '#9ca3af', strokeWidth: 1.5, borderStyle: 'dashed', isGroup: true } },\n];\n\nexport const EDGE_TYPE_OPTIONS: FlowEdgeTypeName[] = [\n 'smoothstep',\n 'step',\n 'straight',\n 'simplebezier',\n];\n\nexport const EDGE_MARKER_OPTIONS: FlowEdgeMarkerKind[] = [\n 'none',\n 'arrow',\n 'arrowclosed',\n];\n\nexport const EDGE_LINE_STYLE_OPTIONS: FlowEdgeLineStyle[] = [\n 'solid',\n 'dashed',\n 'dotted',\n 'dynamic',\n];\n\nexport const BORDER_STYLE_OPTIONS: FlowBorderStyle[] = [\n 'solid',\n 'dashed',\n 'dotted',\n 'dynamic',\n];\n\nexport const DASH_DENSITY_OPTIONS: FlowEdgeDashDensity[] = [\n 'sparse',\n 'medium',\n 'dense',\n];\n\nexport const GRADIENT_DIRECTION_OPTIONS: Array<{\n value: GradientDirection;\n label: string;\n}> = [\n { value: 'to-r', label: 'Left → Right' },\n { value: 'to-l', label: 'Right → Left' },\n { value: 'to-b', label: 'Top → Bottom' },\n { value: 'to-t', label: 'Bottom → Top' },\n { value: 'to-br', label: 'Top-Left → Bottom-Right' },\n { value: 'to-tl', label: 'Bottom-Right → Top-Left' },\n { value: 'to-tr', label: 'Bottom-Left → Top-Right' },\n { value: 'to-bl', label: 'Top-Right → Bottom-Left' },\n];\n\nexport const MIN_ZOOM = 0.1;\nexport const MAX_ZOOM = 4;\nexport const DEFAULT_GRID_SIZE = 20;\nexport const ZOOM_SENSITIVITY = 0.001;\nexport const SNAP_THRESHOLD = 5;\nexport const HANDLE_SIZE = 8;\n\nexport function createEmptyDocument(): FlowDocument {\n return {\n canvases: { [ROOT_CANVAS_ID]: { nodes: [], edges: [], lines: [] } },\n stack: [ROOT_CANVAS_ID],\n };\n}\n"],"mappings":"AAaA,IAAa,IAAiB,QAEjB,IAAkC;
|
|
1
|
+
{"version":3,"file":"constants.js","names":[],"sources":["../../../../src/components/pro/Flow/constants.ts"],"sourcesContent":["import type {\n FlowNodeData,\n FlowShapeType,\n FlowEdgeTypeName,\n FlowEdgeMarkerKind,\n FlowEdgeLineStyle,\n FlowEdgeDashDensity,\n FlowBorderStyle,\n GradientDirection,\n FlowDocument,\n FlowEdgeData,\n} from './types';\n\nexport const ROOT_CANVAS_ID = 'root';\n\nexport const DEFAULT_NODE_DATA: FlowNodeData = {\n label: 'Text',\n fill: 'theme:base-100',\n stroke: 'theme:base-content',\n strokeWidth: 2,\n color: 'theme:base-content',\n fontSize: 14,\n attributes: [],\n};\n\nexport const TEXT_NODE_DATA: FlowNodeData = {\n label: 'Label',\n fill: 'transparent',\n stroke: 'transparent',\n strokeWidth: 0,\n color: 'theme:base-content',\n fontSize: 14,\n attributes: [],\n};\n\nexport const DEFAULT_EDGE_DATA: FlowEdgeData = {\n strokeColor: 'theme:base-content',\n strokeWidth: 2,\n lineStyle: 'solid',\n markerEnd: 'arrowclosed',\n};\n\nexport const PALETTE_ITEMS: Array<{\n type: FlowShapeType;\n width: number;\n height: number;\n data: FlowNodeData;\n}> = [\n { type: 'shapeRect', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Rectangle' } },\n { type: 'shapeRoundRect', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Rounded' } },\n { type: 'shapeEllipse', width: 120, height: 120, data: { ...DEFAULT_NODE_DATA, label: 'Ellipse' } },\n { type: 'shapeDiamond', width: 120, height: 120, data: { ...DEFAULT_NODE_DATA, label: 'Diamond' } },\n { type: 'shapeDocument', width: 120, height: 80, data: { ...DEFAULT_NODE_DATA, label: 'Document' } },\n { type: 'shapeParallelogram', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Parallelogram' } },\n { type: 'shapeTriangle', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Triangle' } },\n { type: 'shapeTrapezoid', width: 140, height: 72, data: { ...DEFAULT_NODE_DATA, label: 'Trapezoid' } },\n { type: 'shapePentagon', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Pentagon' } },\n { type: 'shapeHexagon', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Hexagon' } },\n { type: 'shapeStar', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Star' } },\n { type: 'shapeHexagram', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Hexagram' } },\n { type: 'shapeRightTriangle', width: 120, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Right Triangle' } },\n { type: 'shapeCorner', width: 100, height: 100, data: { ...DEFAULT_NODE_DATA, label: 'Corner' } },\n { type: 'textLabel', width: 120, height: 40, data: { ...TEXT_NODE_DATA, label: 'Label' } },\n { type: 'animAnchor', width: 320, height: 240, data: { ...DEFAULT_NODE_DATA, label: 'Anchor', fill: 'transparent', stroke: '#8b5cf6', strokeWidth: 1.5, borderStyle: 'dashed' } },\n { type: 'flowGroup', width: 200, height: 160, data: { ...DEFAULT_NODE_DATA, label: 'Group', fill: '#f0f9ff', stroke: '#9ca3af', strokeWidth: 1.5, borderStyle: 'dotted', isGroup: true } },\n { type: 'geometryGroup', width: 200, height: 160, data: { ...DEFAULT_NODE_DATA, label: 'Geo Group', fill: '#fefce8', stroke: '#9ca3af', strokeWidth: 1.5, borderStyle: 'dashed', isGroup: true } },\n];\n\nexport const EDGE_TYPE_OPTIONS: FlowEdgeTypeName[] = [\n 'smoothstep',\n 'step',\n 'straight',\n 'simplebezier',\n];\n\nexport const EDGE_MARKER_OPTIONS: FlowEdgeMarkerKind[] = [\n 'none',\n 'arrow',\n 'arrowclosed',\n];\n\nexport const EDGE_LINE_STYLE_OPTIONS: FlowEdgeLineStyle[] = [\n 'solid',\n 'dashed',\n 'dotted',\n 'dynamic',\n];\n\nexport const BORDER_STYLE_OPTIONS: FlowBorderStyle[] = [\n 'solid',\n 'dashed',\n 'dotted',\n 'dynamic',\n];\n\nexport const DASH_DENSITY_OPTIONS: FlowEdgeDashDensity[] = [\n 'sparse',\n 'medium',\n 'dense',\n];\n\nexport const GRADIENT_DIRECTION_OPTIONS: Array<{\n value: GradientDirection;\n label: string;\n}> = [\n { value: 'to-r', label: 'Left → Right' },\n { value: 'to-l', label: 'Right → Left' },\n { value: 'to-b', label: 'Top → Bottom' },\n { value: 'to-t', label: 'Bottom → Top' },\n { value: 'to-br', label: 'Top-Left → Bottom-Right' },\n { value: 'to-tl', label: 'Bottom-Right → Top-Left' },\n { value: 'to-tr', label: 'Bottom-Left → Top-Right' },\n { value: 'to-bl', label: 'Top-Right → Bottom-Left' },\n];\n\nexport const MIN_ZOOM = 0.1;\nexport const MAX_ZOOM = 4;\nexport const DEFAULT_GRID_SIZE = 20;\nexport const ZOOM_SENSITIVITY = 0.001;\nexport const SNAP_THRESHOLD = 5;\nexport const HANDLE_SIZE = 8;\n\nexport function createEmptyDocument(): FlowDocument {\n return {\n canvases: { [ROOT_CANVAS_ID]: { nodes: [], edges: [], lines: [] } },\n stack: [ROOT_CANVAS_ID],\n };\n}\n"],"mappings":"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"}
|
|
@@ -1,32 +1,31 @@
|
|
|
1
|
-
import { createContext as
|
|
2
|
-
import { jsx as
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
import { createContext as e, useContext as t, useMemo as n, useState as r } from "react";
|
|
2
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
3
|
+
//#region src/components/pro/Flow/context/FlowAIContext.tsx
|
|
4
|
+
var a = {
|
|
5
|
+
gateway: "",
|
|
6
|
+
protocol: "openai",
|
|
7
|
+
model: ""
|
|
8
|
+
}, o = e(null);
|
|
9
|
+
function s() {
|
|
10
|
+
let e = t(o);
|
|
11
|
+
if (!e) throw Error("useFlowAI must be used within FlowAIProvider");
|
|
12
|
+
return e;
|
|
12
13
|
}
|
|
13
|
-
function
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
14
|
+
function c({ initialConfig: e, showAIConfig: t = !0, children: s }) {
|
|
15
|
+
let [c, l] = r({
|
|
16
|
+
...a,
|
|
17
|
+
...e
|
|
18
|
+
}), u = n(() => ({
|
|
19
|
+
aiConfig: c,
|
|
20
|
+
setAIConfig: l,
|
|
21
|
+
showAIConfig: t
|
|
22
|
+
}), [c, t]);
|
|
23
|
+
return /* @__PURE__ */ i(o.Provider, {
|
|
24
|
+
value: u,
|
|
25
|
+
children: s
|
|
26
|
+
});
|
|
26
27
|
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
f as useFlowAI
|
|
30
|
-
};
|
|
28
|
+
//#endregion
|
|
29
|
+
export { c as FlowAIProvider, s as useFlowAI };
|
|
31
30
|
|
|
32
31
|
//# sourceMappingURL=FlowAIContext.js.map
|