@atom8n/n8n-editor-ui 2.2.0
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/.stylelintcache +1 -0
- package/README.md +59 -0
- package/biome.jsonc +8 -0
- package/build.log +55 -0
- package/data/node-popularity.json +3998 -0
- package/dist/assets/AddDataTableModal-UINkk54_.js +1555 -0
- package/dist/assets/AgentEditorModal-CVww87TJ.js +358 -0
- package/dist/assets/Alert-Dy86dyOr.js +102 -0
- package/dist/assets/AnimatedSpinner-DmPN4poP.js +15 -0
- package/dist/assets/AnnotationTagsDropdown.ee-BJ7N9lek.js +71 -0
- package/dist/assets/AuthView-D2LWHrMp.js +106 -0
- package/dist/assets/BottomMenu-CIQiK_dJ.js +532 -0
- package/dist/assets/CalendarDate-DgQUMbNo.js +875 -0
- package/dist/assets/ChangePasswordView-Z6tUkw0u.js +133 -0
- package/dist/assets/ChatAgentAvatar-50YBnv3N.js +67 -0
- package/dist/assets/ChatFile-xZxmc2nV.js +146 -0
- package/dist/assets/ChatLayout-CTE_5SiM.js +96 -0
- package/dist/assets/ChatPersonalAgentsView-BGpHk03K.js +149 -0
- package/dist/assets/ChatSidebar-BkVwIypC.js +528 -0
- package/dist/assets/ChatView-BbbdeU9x.js +1559 -0
- package/dist/assets/ChatWorkflowAgentsView-BtunOxlC.js +116 -0
- package/dist/assets/CollectionParameter-BdcPG1lu.js +52 -0
- package/dist/assets/CommitMonoVariable-ytizKI8U.woff2 +0 -0
- package/dist/assets/CommunityNodeUpdateInfo-C37kca4W.js +273 -0
- package/dist/assets/CopyInput-DDZVu2iU.js +74 -0
- package/dist/assets/CredentialIcon-8YdTTFZ1.js +80 -0
- package/dist/assets/CredentialPicker-DWtj314o.js +293 -0
- package/dist/assets/CredentialSelectorModal-DTW2fKh0.js +138 -0
- package/dist/assets/CredentialsView-BjUchcCu.js +480 -0
- package/dist/assets/DataTableActions-DpAkoxg_.js +95 -0
- package/dist/assets/DataTableDetailsView-Coq7zdW5.js +41922 -0
- package/dist/assets/DataTableView-Cs-BIkzw.js +293 -0
- package/dist/assets/DemoFooter-Cga3jvi-.js +65 -0
- package/dist/assets/Draggable-vfvXl9Sp.js +105 -0
- package/dist/assets/EmptySharedSectionActionBox-DOXZtTCv.js +36 -0
- package/dist/assets/EnterpriseEdition.ee-D_rCFexM.js +15 -0
- package/dist/assets/EntityNotFound-3dhTRWsE.js +85 -0
- package/dist/assets/EntityUnAuthorised-ChJYZakE.js +66 -0
- package/dist/assets/ErrorView-zT9cX76a.js +61 -0
- package/dist/assets/EvaluationsRootView-C-OVWYnY.js +523 -0
- package/dist/assets/EvaluationsView-CJwJTruc.js +469 -0
- package/dist/assets/ExecutionsTime-DEQiyozR.js +573 -0
- package/dist/assets/ExecutionsView-Bd5Oh8TH.js +791 -0
- package/dist/assets/ExternalSecretsProviderConnectionSwitch.ee-C7Ih-uRo.js +191 -0
- package/dist/assets/FixedCollectionParameter-CYuTDW9t.js +496 -0
- package/dist/assets/ForgotMyPasswordView-Bs_L9P27.js +102 -0
- package/dist/assets/InsightsChartAverageRuntime-Bp3VA8_7.js +62 -0
- package/dist/assets/InsightsChartFailed-KPaNWoEr.js +52 -0
- package/dist/assets/InsightsChartFailureRate-DE6kE3FM.js +54 -0
- package/dist/assets/InsightsChartTimeSaved-auABNZlc.js +68 -0
- package/dist/assets/InsightsChartTotal-BKzYRKE7.js +56 -0
- package/dist/assets/InsightsDashboard-JWx4W6Db.js +473 -0
- package/dist/assets/InsightsPaywall-C8zLLKe8.js +63 -0
- package/dist/assets/InsightsSummary-cmN1lHDm.js +210 -0
- package/dist/assets/InsightsTableWorkflows-CqcC3IbQ.js +203 -0
- package/dist/assets/InterVariable-DiVDrmQJ.woff2 +0 -0
- package/dist/assets/InterVariable-Italic-FCBEiFp6.woff2 +0 -0
- package/dist/assets/ItemsRenderer-DC8WVyMv.js +922 -0
- package/dist/assets/KeyboardShortcutTooltip-D8PAK5JP.js +31 -0
- package/dist/assets/LogsPanel-BR06u9RK.js +52 -0
- package/dist/assets/LogsPanel-C-_acMHp.js +2325 -0
- package/dist/assets/MCPConnectWorkflowsModal-3g8_iUa4.js +303 -0
- package/dist/assets/MainHeader-DiQc1edn.js +2153 -0
- package/dist/assets/MainSidebar-CoPGG5Ea.js +804 -0
- package/dist/assets/MigrationRuleDetail-BAxk1Pvl.js +295 -0
- package/dist/assets/MigrationRules-IW9lZMpE.js +285 -0
- package/dist/assets/Modal-CIzXlZdZ.js +204 -0
- package/dist/assets/ModelByIdSelectorModal-DLvBjzJO.js +115 -0
- package/dist/assets/NDVEmptyState-33UoX00I.js +19743 -0
- package/dist/assets/NodeCreation-BNzbSWSB.js +240 -0
- package/dist/assets/NodeCreator-BftgCKx7.js +1288 -0
- package/dist/assets/NodeDetailsView-CsoQCpcF.js +1075 -0
- package/dist/assets/NodeDetailsViewV2-C_wNQR_3.js +981 -0
- package/dist/assets/NodeIcon-B9VW6tX6.js +87 -0
- package/dist/assets/NodeSettings-ZwVip6VR.js +1872 -0
- package/dist/assets/NodeView-D4WUEvLB.js +2452 -0
- package/dist/assets/OAuthConsentView-DlrUqZbT.js +230 -0
- package/dist/assets/PageViewLayout-NT1KPFgy.js +12 -0
- package/dist/assets/ParameterInputList-sG2nz-Jo.js +38091 -0
- package/dist/assets/PrebuiltAgentTemplatesView-Csi5U8dc.js +154 -0
- package/dist/assets/ProjectBreadcrumb-C_XiY7sc.js +98 -0
- package/dist/assets/ProjectCardBadge-t_hs7vzx.js +209 -0
- package/dist/assets/ProjectHeader-Dq5Ihb26.js +549 -0
- package/dist/assets/ProjectIcon-DY8gGuHX.js +64 -0
- package/dist/assets/ProjectRoleView-Du-KTrAC.js +435 -0
- package/dist/assets/ProjectRolesView-DjxM_y4u.js +239 -0
- package/dist/assets/ProjectSettings-C6kWuV21.js +966 -0
- package/dist/assets/ProjectSharing-CVUgNWAY.js +262 -0
- package/dist/assets/ProjectVariables-CJlAo3dv.js +467 -0
- package/dist/assets/ProviderSettingsModal-BUFC2ZLv.js +307 -0
- package/dist/assets/PushConnectionTracker-DPBnGV0v.js +27 -0
- package/dist/assets/ResolversView-3BdkvvYA.js +209 -0
- package/dist/assets/ResourceFiltersDropdown-dgyXpcEX.js +159 -0
- package/dist/assets/ResourcesListLayout-qBLtomK6.js +631 -0
- package/dist/assets/RunDataHtml-BrW0OQra.js +7 -0
- package/dist/assets/RunDataHtml-Cleia4Cj.js +40 -0
- package/dist/assets/RunDataJson-uxkrhYRK.js +227 -0
- package/dist/assets/RunDataJsonActions-DkPk7E8d.js +5007 -0
- package/dist/assets/RunDataParsedAiContent-CtPRjig-.js +26 -0
- package/dist/assets/RunDataParsedAiContent-WAuqLQ5M.js +192 -0
- package/dist/assets/RunDataSearch-YBWUr93C.js +141 -0
- package/dist/assets/RunDataTable-DcXaBynW.js +631 -0
- package/dist/assets/SamlOnboarding-BTdQ_hr3.js +78 -0
- package/dist/assets/SaveButton-D5sQSxIk.js +89 -0
- package/dist/assets/SelectedItemsInfo-BHZ-NvF5.js +58 -0
- package/dist/assets/SettingsApiView-IfZTMXx1.js +313 -0
- package/dist/assets/SettingsChatHubView-gWh2X6vX.js +285 -0
- package/dist/assets/SettingsCommunityNodesView-D8VQtpGY.js +349 -0
- package/dist/assets/SettingsExternalSecrets-CpMc7mkW.js +233 -0
- package/dist/assets/SettingsLdapView-CU5a2MAy.js +2553 -0
- package/dist/assets/SettingsLogStreamingView-uojTe-oX.js +375 -0
- package/dist/assets/SettingsMCPView-B5Swp1C_.js +1214 -0
- package/dist/assets/SettingsPersonalView-Cr3aGood.js +402 -0
- package/dist/assets/SettingsSourceControl-DXOvFDEY.js +547 -0
- package/dist/assets/SettingsSso-27MfU1HV.js +1032 -0
- package/dist/assets/SettingsUsageAndPlan-DqIO-G46.js +419 -0
- package/dist/assets/SettingsUsersView-DfHB4_Kh.js +833 -0
- package/dist/assets/SettingsView-C4sA7Uny.js +90 -0
- package/dist/assets/SetupTemplateFormStep-BmiSzZin.js +258 -0
- package/dist/assets/SetupView-VORZ-L_u.js +112 -0
- package/dist/assets/SetupWorkflowCredentialsButton-DTmkOAW5.js +73 -0
- package/dist/assets/SetupWorkflowFromTemplateView-B9NupdJE.js +286 -0
- package/dist/assets/SeverityTag-CX1qTTNA.js +45 -0
- package/dist/assets/SigninView-D9_Pm16j.js +358 -0
- package/dist/assets/SignoutView-BFsjEAGz.js +19 -0
- package/dist/assets/SignupView-Am4ot0QZ.js +137 -0
- package/dist/assets/SkeletonAgentCard-C5TL-h8F.js +191 -0
- package/dist/assets/TagsDropdown-Bvx_Hd6Q.js +230 -0
- package/dist/assets/TemplateCard-CyQ1GuVz.js +105 -0
- package/dist/assets/TemplateDetails-CZRusTxE.js +124 -0
- package/dist/assets/TemplateList-DKvbwuiY.js +333 -0
- package/dist/assets/TemplatesCollectionView-D8dxU8By.js +184 -0
- package/dist/assets/TemplatesSearchView-CebC_GLs.js +1230 -0
- package/dist/assets/TemplatesView-025CcmIY.js +57 -0
- package/dist/assets/TemplatesWorkflowView-C2JfwJAn.js +170 -0
- package/dist/assets/TestRunDetailView-Ck78TTWO.js +395 -0
- package/dist/assets/TextWithHighlights-BxumwGnv.js +57 -0
- package/dist/assets/TimeAgo-C6EN4lCs.js +123 -0
- package/dist/assets/ToolsSelectorModal-8QJoUvRL.js +368 -0
- package/dist/assets/TriggerPanel-B6pacLkk.js +1225 -0
- package/dist/assets/VirtualSchema-B3zGe_8b.js +2402 -0
- package/dist/assets/VirtualSchema-Dkh0Cu5z.js +37 -0
- package/dist/assets/VueMarkdown-CQqJL9vK.js +28 -0
- package/dist/assets/WorkerView-Caznsljo.js +563 -0
- package/dist/assets/WorkflowActivationErrorMessage-CGrfPi9O.js +17 -0
- package/dist/assets/WorkflowActivator-BINnz0f7.js +362 -0
- package/dist/assets/WorkflowExecutionsInfoAccordion-Dg37yEfT.js +166 -0
- package/dist/assets/WorkflowExecutionsLandingPage-V2wdubhK.js +93 -0
- package/dist/assets/WorkflowExecutionsPreview-DdJaqYV6.js +616 -0
- package/dist/assets/WorkflowExecutionsView-DV8ySTfn.js +808 -0
- package/dist/assets/WorkflowHistory-GtaBMzIM.js +973 -0
- package/dist/assets/WorkflowLocation-CQ9Sq-2y.js +164 -0
- package/dist/assets/WorkflowOnboardingView-C49gt0Jr.js +61 -0
- package/dist/assets/WorkflowPreview-CXdvv4Nq.js +186 -0
- package/dist/assets/WorkflowTagsDropdown-QwbICWjN.js +71 -0
- package/dist/assets/WorkflowsView-B-MWIECO.js +3253 -0
- package/dist/assets/_MapCache-CcdIl4Ae.js +363 -0
- package/dist/assets/_baseOrderBy-N8Be_6z6.js +2989 -0
- package/dist/assets/_initCloneObject-viQQyT6o.js +80 -0
- package/dist/assets/_plugin-vue_export-helper-BwBpWJRZ.js +6 -0
- package/dist/assets/aiTemplatesStarterCollection.store-nL9nePkK.js +656 -0
- package/dist/assets/apiKeys.store-BhOFmP2j.js +51 -0
- package/dist/assets/assistant.store-CNywgN4S.js +518 -0
- package/dist/assets/auth.eventBus-CWXS0Qp7.js +5 -0
- package/dist/assets/banners.store-CGEcBTDn.js +195 -0
- package/dist/assets/builder.store-Czk2ipDE.js +31417 -0
- package/dist/assets/buttons.esm-yintpW2E.js +364 -0
- package/dist/assets/chart-CNvyywtJ.js +10958 -0
- package/dist/assets/chartjs.utils-BAE52Cv9.js +155 -0
- package/dist/assets/chat.store-290YeyrQ.js +865 -0
- package/dist/assets/chatPanel.store-NDaawEZL.js +118 -0
- package/dist/assets/chunk-6z4oVpB-.js +36 -0
- package/dist/assets/col-Cmt4cmuS.js +158 -0
- package/dist/assets/constants-C8OH4tTq.js +106256 -0
- package/dist/assets/constants-DMrsrpD7.js +32 -0
- package/dist/assets/core-B9gt_4yk.js +4 -0
- package/dist/assets/core-CP5FY4aX.js +1202 -0
- package/dist/assets/core-CRbPymLT.js +9741 -0
- package/dist/assets/dataTable.store-DmipQsol.js +207 -0
- package/dist/assets/date-picker-2IDsBs2n.js +4115 -0
- package/dist/assets/dateFormatter-ik4-9_9r.js +33 -0
- package/dist/assets/dateformat-hG8NERse.js +181 -0
- package/dist/assets/dialog-lMho1TD8.js +425 -0
- package/dist/assets/dist-Cw46Is-h.js +151 -0
- package/dist/assets/doppler-B__k0MeW.webp +0 -0
- package/dist/assets/element-icons-B-tDfklg.woff +0 -0
- package/dist/assets/element-icons-_lZGOqcG.ttf +0 -0
- package/dist/assets/empty-BuGRxzl4.js +2210 -0
- package/dist/assets/en-CF30SCh2.js +95 -0
- package/dist/assets/en-DyO2pPiC.js +2 -0
- package/dist/assets/es-BkUFJVtD.js +43338 -0
- package/dist/assets/evaluation.constants-GYAwmJnh.js +284 -0
- package/dist/assets/executions.store-B9uRYwgv.js +205 -0
- package/dist/assets/exports-Crx_gvt_.js +1799 -0
- package/dist/assets/externalSecrets.ee.store-BJh4a_6G.js +118 -0
- package/dist/assets/fileUtils-CRWqOQje.js +20 -0
- package/dist/assets/folders.store-yAFj-5Vl.js +235 -0
- package/dist/assets/get-BcEmeOxn.js +2781 -0
- package/dist/assets/index-SL8542zQ.js +28372 -0
- package/dist/assets/insights.constants-BkJCYJTL.js +55 -0
- package/dist/assets/insights.store-BFc3kDUo.js +61 -0
- package/dist/assets/insights.utils-CcLXdrrz.js +77 -0
- package/dist/assets/isEmpty-C3XXoHqJ.js +35216 -0
- package/dist/assets/languageModules-9LyndCqU.js +13862 -0
- package/dist/assets/logStreaming.store-IZhWe_VK.js +190 -0
- package/dist/assets/mcp.constants-_Jcn7fPq.js +10 -0
- package/dist/assets/mcp.store-B9yfcAN9.js +116 -0
- package/dist/assets/merge-DhuTk1HM.js +564 -0
- package/dist/assets/nodeCreator.store-Bpnrwp2l.js +5444 -0
- package/dist/assets/nodeIcon-D6X-ENYt.js +102 -0
- package/dist/assets/nodeTransforms-RzcOM0v2.js +42 -0
- package/dist/assets/orderBy-Cu9F9DU_.js +15 -0
- package/dist/assets/path-browserify-RUt2u7iT.js +328 -0
- package/dist/assets/personalizedTemplatesV3.store-BGYp0YBN.js +334 -0
- package/dist/assets/pickBy-UI0Jt4wC.js +18 -0
- package/dist/assets/preload-helper-dyVz7ck7.js +59 -0
- package/dist/assets/radio-CSce3UT0.js +262 -0
- package/dist/assets/readyToRun.store-YEMvPUqo.js +626 -0
- package/dist/assets/readyToRunWorkflows.store-G3srgIze.js +1319 -0
- package/dist/assets/retry-BgHaYzbB.js +23 -0
- package/dist/assets/roles.store-CRf_zJTb.js +51 -0
- package/dist/assets/router-DNpzz3GH.js +2631 -0
- package/dist/assets/sanitize-html-CbW56HUN.js +10758 -0
- package/dist/assets/schemaPreview.store-DUgN1yVE.js +113 -0
- package/dist/assets/semver-Bk6DGseV.js +1306 -0
- package/dist/assets/smartDecimal-DAZl4HKA.js +6 -0
- package/dist/assets/sortByProperty-Cn7iGKYu.js +8 -0
- package/dist/assets/sourceControl.eventBus-D47xXSc_.js +3 -0
- package/dist/assets/sqlite3-DBpDb1lf.wasm +0 -0
- package/dist/assets/sqlite3-opfs-async-proxy-vVtmDGHX.js +461 -0
- package/dist/assets/sqlite3-worker1-bundler-friendly-DLarOZDL.js +9405 -0
- package/dist/assets/src-jviYSG25.js +55454 -0
- package/dist/assets/sso.store-DyApJwhx.js +139 -0
- package/dist/assets/style-E3CrYFV8.css +111829 -0
- package/dist/assets/table-we1DjFMV.js +3944 -0
- package/dist/assets/templateActions-bEDSARw2.js +65 -0
- package/dist/assets/templateTransforms-BHWiRbtR.js +43 -0
- package/dist/assets/truncate-C0KYt7i3.js +4176 -0
- package/dist/assets/typescript.worker-CYqLvLHh.js +152048 -0
- package/dist/assets/uniqBy-xDyuCRP0.js +10 -0
- package/dist/assets/usage.store-CU5J_nGm.js +100 -0
- package/dist/assets/useActions-B1JckIRj.js +255 -0
- package/dist/assets/useBeforeUnload-DiDkvI8p.js +40 -0
- package/dist/assets/useCanvasMapping-BXT7rGhC.js +12570 -0
- package/dist/assets/useCanvasOperations-8ULLtMkY.js +1765 -0
- package/dist/assets/useClipboard-DvjhVHqJ.js +39 -0
- package/dist/assets/useCommandBar-C4tLJbKt.js +2425 -0
- package/dist/assets/useCredentialResolvers-BKeFGJnY.js +78 -0
- package/dist/assets/useCustomAgent-DpILEt5e.js +471 -0
- package/dist/assets/useDebounce-Br5_1ug-.js +147 -0
- package/dist/assets/useExecutionData-M5iKsX6z.js +23 -0
- package/dist/assets/useExecutionDebugging-8azMzbnd.js +191 -0
- package/dist/assets/useExecutionHelpers-BgRRhpBM.js +91 -0
- package/dist/assets/useImportCurlCommand-CKiEmX5P.js +8891 -0
- package/dist/assets/useIntersectionObserver-BWMwOueh.js +33 -0
- package/dist/assets/useKeybindings-B2jfN6rd.js +62 -0
- package/dist/assets/useLogsTreeExpand-sZViUfdM.js +843 -0
- package/dist/assets/useMcp-DoMOIfqT.js +27 -0
- package/dist/assets/usePageRedirectionHelper-DjkznpX6.js +51 -0
- package/dist/assets/usePinnedData-BhZkqttf.js +203 -0
- package/dist/assets/usePushConnection-DMS-F_IW.js +513 -0
- package/dist/assets/useRecentResources-BVORr7eM.js +118 -0
- package/dist/assets/useRunWorkflow-LO7ffLp9.js +950 -0
- package/dist/assets/useSettingsItems-BhZXwMZn.js +144 -0
- package/dist/assets/useTelemetryContext-V6bv4YRq.js +34 -0
- package/dist/assets/useWorkflowActivate-DeSmDXjI.js +152 -0
- package/dist/assets/useWorkflowsCache-DtcEEAIR.js +179 -0
- package/dist/assets/userRoleProvisioning.store-kkSIdeTo.js +33 -0
- package/dist/assets/utils-DI7dLldp.js +54 -0
- package/dist/assets/versions.store-B1z2OrLE.js +191 -0
- package/dist/assets/vue-CydWIhxN.js +4378 -0
- package/dist/assets/vue-json-pretty-CsGX66mG.js +1130 -0
- package/dist/assets/vue.runtime.esm-bundler-tP5dCd7J.js +7325 -0
- package/dist/assets/xml-B_oj6Mle.js +2060 -0
- package/dist/favicon.ico +0 -0
- package/dist/index.html +157 -0
- package/dist/static/base-path.js +1 -0
- package/dist/static/community_package_tooltip_img.png +0 -0
- package/dist/static/data-mapping-gif.gif +0 -0
- package/dist/static/form-grey.svg +1 -0
- package/dist/static/google-auth/disabled.dark.png +0 -0
- package/dist/static/google-auth/disabled.png +0 -0
- package/dist/static/google-auth/focus.dark.png +0 -0
- package/dist/static/google-auth/focus.png +0 -0
- package/dist/static/google-auth/normal.dark.png +0 -0
- package/dist/static/google-auth/normal.png +0 -0
- package/dist/static/google-auth/pressed.dark.png +0 -0
- package/dist/static/google-auth/pressed.png +0 -0
- package/dist/static/n8n-logo.png +0 -0
- package/dist/static/og_image.png +0 -0
- package/dist/static/open-ai.svg +1 -0
- package/dist/static/openChat.png +0 -0
- package/dist/static/posthog.init.js +41 -0
- package/dist/static/prefers-color-scheme.css +5 -0
- package/dist/static/webhook-icon.svg +1 -0
- package/dist/tree-sitter-bash.wasm +0 -0
- package/dist/tree-sitter.wasm +0 -0
- package/eslint.config.mjs +59 -0
- package/index.html +45 -0
- package/index.js +0 -0
- package/package.json +147 -0
- package/postcss.config.cjs +6 -0
- package/scripts/fetch-node-popularity.mjs +102 -0
- package/stylelint.config.mjs +9 -0
- package/tailwind.config.js +8 -0
- package/tsconfig.json +36 -0
- package/vite/i18n-locales-hmr-helpers.ts +19 -0
- package/vite/source-map-js-shim.ts +1 -0
- package/vite/vite-plugin-node-popularity.mts +32 -0
- package/vite.config.mts +304 -0
|
@@ -0,0 +1,922 @@
|
|
|
1
|
+
import { o as __toESM } from "./chunk-6z4oVpB-.js";
|
|
2
|
+
import { C as computed, Cn as toDisplayString, D as createElementBlock, E as createCommentVNode, Gt as unref, Ht as toRefs, I as guardReactiveProps, It as ref, M as createVNode, P as defineComponent, Pt as reactive, Q as onUnmounted, T as createBlock, W as mergeProps, Z as onMounted, _ as Fragment, _t as watch, at as renderSlot, bn as normalizeStyle, bt as withCtx, et as openBlock, h as withModifiers, it as renderList, j as createTextVNode, k as createSlots, n as Transition, p as vShow, st as resolveDirective, vn as normalizeClass, w as createBaseVNode, xt as withDirectives, yn as normalizeProps } from "./vue.runtime.esm-bundler-tP5dCd7J.js";
|
|
3
|
+
import { rt as useI18n } from "./core-CRbPymLT.js";
|
|
4
|
+
import { A as N8nNodeIcon_default, Cn as N8nIcon_default, at as N8nLoading_default, bn as N8nText_default, ht as N8nTooltip_default, j as N8nNodeCreatorNode_default, xn as N8nButton_default } from "./src-jviYSG25.js";
|
|
5
|
+
import { t as __plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BwBpWJRZ.js";
|
|
6
|
+
import { Er as useUsersStore, P as useWorkflowsStore, Pt as useNodeTypesStore, R as DEFAULT_NODE_SIZE, Y as getNewNodePosition, Yt as removePreviewToken, Zt as shouldShowCommunityNodeDetails, k as useTelemetry, qt as isNodePreviewKey, ua as COMMUNITY_NODES_INSTALLATION_DOCS_URL } from "./builder.store-Czk2ipDE.js";
|
|
7
|
+
import { Gt as CREDENTIAL_ONLY_NODE_PREFIX, L as DRAG_EVENT_DATA_KEY, Ta as isCommunityPackageName, _t as DEFAULT_SUBCATEGORY, bt as HITL_SUBCATEGORY, hr as WEBHOOK_NODE_TYPE } from "./constants-C8OH4tTq.js";
|
|
8
|
+
import { n as useNodeType } from "./usePinnedData-BhZkqttf.js";
|
|
9
|
+
import { d as useViewStacks, f as useKeyboardNavigation, t as useNodeCreatorStore, v as require_camelCase } from "./nodeCreator.store-Bpnrwp2l.js";
|
|
10
|
+
import { t as NodeIcon_default } from "./NodeIcon-B9VW6tX6.js";
|
|
11
|
+
import { t as useActions } from "./useActions-B1JckIRj.js";
|
|
12
|
+
var _sfc_main = {};
|
|
13
|
+
function _sfc_render(_ctx, _cache) {
|
|
14
|
+
return openBlock(), createBlock(Transition, { name: "slide" }, {
|
|
15
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
16
|
+
_: 3
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
var SlideTransition_default = /* @__PURE__ */ __plugin_vue_export_helper_default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-c503546a"]]);
|
|
20
|
+
var _hoisted_1$4 = {
|
|
21
|
+
viewBox: "0 0 24 24",
|
|
22
|
+
width: "1.2em",
|
|
23
|
+
height: "1.2em"
|
|
24
|
+
};
|
|
25
|
+
function render(_ctx, _cache) {
|
|
26
|
+
return openBlock(), createElementBlock("svg", _hoisted_1$4, _cache[0] || (_cache[0] = [createBaseVNode("path", {
|
|
27
|
+
fill: "currentColor",
|
|
28
|
+
d: "m23 12l-2.44-2.78l.34-3.68l-3.61-.82l-1.89-3.18L12 3L8.6 1.54L6.71 4.72l-3.61.81l.34 3.68L1 12l2.44 2.78l-.34 3.69l3.61.82l1.89 3.18L12 21l3.4 1.46l1.89-3.18l3.61-.82l-.34-3.68zm-13 5l-4-4l1.41-1.41L10 14.17l6.59-6.59L18 9z"
|
|
29
|
+
}, null, -1)]));
|
|
30
|
+
}
|
|
31
|
+
var verified_default = {
|
|
32
|
+
name: "mdi-verified",
|
|
33
|
+
render
|
|
34
|
+
};
|
|
35
|
+
var NodeItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
36
|
+
__name: "NodeItem",
|
|
37
|
+
props: {
|
|
38
|
+
nodeType: {},
|
|
39
|
+
subcategory: { default: void 0 },
|
|
40
|
+
active: {
|
|
41
|
+
type: Boolean,
|
|
42
|
+
default: false
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
setup(__props) {
|
|
46
|
+
const props = __props;
|
|
47
|
+
const i18n = useI18n();
|
|
48
|
+
const telemetry = useTelemetry();
|
|
49
|
+
const { actions } = useNodeCreatorStore();
|
|
50
|
+
const { getAddedNodesAndConnections } = useActions();
|
|
51
|
+
const { activeViewStack } = useViewStacks();
|
|
52
|
+
const { isSubNodeType } = useNodeType({ nodeType: props.nodeType });
|
|
53
|
+
const nodeTypesStore = useNodeTypesStore();
|
|
54
|
+
const dragging = ref(false);
|
|
55
|
+
const draggablePosition = ref({
|
|
56
|
+
x: -100,
|
|
57
|
+
y: -100
|
|
58
|
+
});
|
|
59
|
+
const draggableDataTransfer$2 = ref(null);
|
|
60
|
+
const description = computed(() => {
|
|
61
|
+
if (isCommunityNodePreview.value) return props.nodeType.description;
|
|
62
|
+
if (isSendAndWaitCategory.value) return "";
|
|
63
|
+
if (props.subcategory === "*" && !props.nodeType.name.startsWith("n8n-creds-base")) return "";
|
|
64
|
+
return i18n.headerText({
|
|
65
|
+
key: `headers.${shortNodeType.value}.description`,
|
|
66
|
+
fallback: props.nodeType.description
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
const showActionArrow = computed(() => {
|
|
70
|
+
if (shouldShowCommunityNodeDetails(isCommunityNode.value, activeViewStack)) return true;
|
|
71
|
+
return hasActions.value && !isSendAndWaitCategory.value;
|
|
72
|
+
});
|
|
73
|
+
const isSendAndWaitCategory = computed(() => activeViewStack.subcategory === HITL_SUBCATEGORY);
|
|
74
|
+
const dataTestId = computed(() => hasActions.value ? "node-creator-action-item" : "node-creator-node-item");
|
|
75
|
+
const hasActions = computed(() => {
|
|
76
|
+
return nodeActions.value.length > 1 && !activeViewStack.hideActions;
|
|
77
|
+
});
|
|
78
|
+
const nodeActions = computed(() => {
|
|
79
|
+
return actions[props.nodeType.name] || [];
|
|
80
|
+
});
|
|
81
|
+
const shortNodeType = computed(() => i18n.shortNodeType(props.nodeType.name) || "");
|
|
82
|
+
const draggableStyle = computed(() => ({
|
|
83
|
+
top: `${draggablePosition.value.y}px`,
|
|
84
|
+
left: `${draggablePosition.value.x}px`
|
|
85
|
+
}));
|
|
86
|
+
const isCommunityNode = computed(() => isCommunityPackageName(props.nodeType.name));
|
|
87
|
+
const isCommunityNodePreview = computed(() => isNodePreviewKey(props.nodeType.name));
|
|
88
|
+
const displayName = computed(() => {
|
|
89
|
+
const trimmedDisplayName = props.nodeType.displayName.trimEnd();
|
|
90
|
+
return i18n.headerText({
|
|
91
|
+
key: `headers.${shortNodeType.value}.displayName`,
|
|
92
|
+
fallback: hasActions.value ? trimmedDisplayName.replace("Trigger", "") : trimmedDisplayName
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
const isTrigger = computed(() => {
|
|
96
|
+
return props.nodeType.group.includes("trigger") && !hasActions.value;
|
|
97
|
+
});
|
|
98
|
+
const communityNodeType = computed(() => {
|
|
99
|
+
return nodeTypesStore.communityNodeType(removePreviewToken(props.nodeType.name));
|
|
100
|
+
});
|
|
101
|
+
const isOfficial = computed(() => {
|
|
102
|
+
return communityNodeType.value?.isOfficialNode ?? false;
|
|
103
|
+
});
|
|
104
|
+
const author = computed(() => {
|
|
105
|
+
return communityNodeType.value?.displayName ?? displayName.value;
|
|
106
|
+
});
|
|
107
|
+
const tag = computed(() => {
|
|
108
|
+
if (props.nodeType.tag) return props.nodeType.tag;
|
|
109
|
+
if (description.value.toLowerCase().includes("deprecated")) return {
|
|
110
|
+
text: i18n.baseText("nodeCreator.nodeItem.deprecated"),
|
|
111
|
+
type: "info"
|
|
112
|
+
};
|
|
113
|
+
});
|
|
114
|
+
function onDragStart(event) {
|
|
115
|
+
if (event.dataTransfer) {
|
|
116
|
+
event.dataTransfer.effectAllowed = "copy";
|
|
117
|
+
event.dataTransfer.dropEffect = "copy";
|
|
118
|
+
event.dataTransfer.setDragImage(draggableDataTransfer$2.value, 0, 0);
|
|
119
|
+
event.dataTransfer.setData(DRAG_EVENT_DATA_KEY, JSON.stringify(getAddedNodesAndConnections([{ type: props.nodeType.name }])));
|
|
120
|
+
}
|
|
121
|
+
dragging.value = true;
|
|
122
|
+
}
|
|
123
|
+
function onDragEnd() {
|
|
124
|
+
dragging.value = false;
|
|
125
|
+
setTimeout(() => {
|
|
126
|
+
draggablePosition.value = {
|
|
127
|
+
x: -100,
|
|
128
|
+
y: -100
|
|
129
|
+
};
|
|
130
|
+
}, 300);
|
|
131
|
+
}
|
|
132
|
+
function onCommunityNodeTooltipClick(event) {
|
|
133
|
+
if (event.target.localName === "a") telemetry.track("user clicked cnr docs link", { source: "nodes panel node" });
|
|
134
|
+
}
|
|
135
|
+
return (_ctx, _cache) => {
|
|
136
|
+
const _directive_n8n_html = resolveDirective("n8n-html");
|
|
137
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
138
|
+
draggable: !showActionArrow.value,
|
|
139
|
+
class: normalizeClass(_ctx.$style.nodeItem),
|
|
140
|
+
description: description.value,
|
|
141
|
+
title: displayName.value,
|
|
142
|
+
"show-action-arrow": showActionArrow.value,
|
|
143
|
+
"is-trigger": isTrigger.value,
|
|
144
|
+
"is-official": isOfficial.value,
|
|
145
|
+
"data-test-id": dataTestId.value,
|
|
146
|
+
tag: tag.value,
|
|
147
|
+
onDragstart: onDragStart,
|
|
148
|
+
onDragend: onDragEnd
|
|
149
|
+
}, createSlots({
|
|
150
|
+
icon: withCtx(() => [unref(isSubNodeType) ? (openBlock(), createElementBlock("div", {
|
|
151
|
+
key: 0,
|
|
152
|
+
class: normalizeClass(_ctx.$style.subNodeBackground)
|
|
153
|
+
}, null, 2)) : createCommentVNode("", true), createVNode(NodeIcon_default, {
|
|
154
|
+
class: normalizeClass(_ctx.$style.nodeIcon),
|
|
155
|
+
"node-type": _ctx.nodeType,
|
|
156
|
+
"color-default": "var(--color--foreground--shade-2)"
|
|
157
|
+
}, null, 8, ["class", "node-type"])]),
|
|
158
|
+
dragContent: withCtx(() => [withDirectives(createBaseVNode("div", {
|
|
159
|
+
ref_key: "draggableDataTransfer",
|
|
160
|
+
ref: draggableDataTransfer$2,
|
|
161
|
+
class: normalizeClass(_ctx.$style.draggable),
|
|
162
|
+
style: normalizeStyle(draggableStyle.value)
|
|
163
|
+
}, [createVNode(NodeIcon_default, {
|
|
164
|
+
"node-type": _ctx.nodeType,
|
|
165
|
+
size: 40,
|
|
166
|
+
shrink: false,
|
|
167
|
+
"color-default": "var(--color--foreground--shade-2)",
|
|
168
|
+
onClickCapture: _cache[0] || (_cache[0] = withModifiers(() => {}, ["stop"]))
|
|
169
|
+
}, null, 8, ["node-type"])], 6), [[vShow, dragging.value]])]),
|
|
170
|
+
_: 2
|
|
171
|
+
}, [isOfficial.value ? {
|
|
172
|
+
name: "extraDetails",
|
|
173
|
+
fn: withCtx(() => [createVNode(unref(N8nTooltip_default), {
|
|
174
|
+
placement: "top",
|
|
175
|
+
"show-after": 500
|
|
176
|
+
}, {
|
|
177
|
+
content: withCtx(() => [createTextVNode(toDisplayString(unref(i18n).baseText("generic.officialNode.tooltip", { interpolate: { author: author.value } })), 1)]),
|
|
178
|
+
default: withCtx(() => [createVNode(unref(verified_default), { class: normalizeClass([_ctx.$style.icon, _ctx.$style.official]) }, null, 8, ["class"])]),
|
|
179
|
+
_: 1
|
|
180
|
+
})]),
|
|
181
|
+
key: "0"
|
|
182
|
+
} : isCommunityNode.value && !isCommunityNodePreview.value && !unref(activeViewStack)?.communityNodeDetails ? {
|
|
183
|
+
name: "extraDetails",
|
|
184
|
+
fn: withCtx(() => [createVNode(unref(N8nTooltip_default), {
|
|
185
|
+
placement: "top",
|
|
186
|
+
"show-after": 500
|
|
187
|
+
}, {
|
|
188
|
+
content: withCtx(() => [withDirectives(createBaseVNode("p", {
|
|
189
|
+
class: normalizeClass(_ctx.$style.communityNodeIcon),
|
|
190
|
+
onClick: onCommunityNodeTooltipClick
|
|
191
|
+
}, null, 2), [[_directive_n8n_html, unref(i18n).baseText("generic.communityNode.tooltip", { interpolate: {
|
|
192
|
+
packageName: _ctx.nodeType.name.split(".")[0],
|
|
193
|
+
docURL: unref(COMMUNITY_NODES_INSTALLATION_DOCS_URL)
|
|
194
|
+
} })]])]),
|
|
195
|
+
default: withCtx(() => [createVNode(unref(N8nIcon_default), {
|
|
196
|
+
size: "small",
|
|
197
|
+
class: normalizeClass(_ctx.$style.icon),
|
|
198
|
+
icon: "box"
|
|
199
|
+
}, null, 8, ["class"])]),
|
|
200
|
+
_: 1
|
|
201
|
+
})]),
|
|
202
|
+
key: "1"
|
|
203
|
+
} : void 0]), 1032, [
|
|
204
|
+
"draggable",
|
|
205
|
+
"class",
|
|
206
|
+
"description",
|
|
207
|
+
"title",
|
|
208
|
+
"show-action-arrow",
|
|
209
|
+
"is-trigger",
|
|
210
|
+
"is-official",
|
|
211
|
+
"data-test-id",
|
|
212
|
+
"tag"
|
|
213
|
+
]);
|
|
214
|
+
};
|
|
215
|
+
}
|
|
216
|
+
});
|
|
217
|
+
var NodeItem_vue_vue_type_style_index_0_lang_module_default = {
|
|
218
|
+
nodeItem: "_nodeItem_4xp4b_123",
|
|
219
|
+
nodeIcon: "_nodeIcon_4xp4b_131",
|
|
220
|
+
subNodeBackground: "_subNodeBackground_4xp4b_135",
|
|
221
|
+
communityNodeIcon: "_communityNodeIcon_4xp4b_145",
|
|
222
|
+
draggable: "_draggable_4xp4b_149",
|
|
223
|
+
draggableDataTransfer: "_draggableDataTransfer_4xp4b_163",
|
|
224
|
+
icon: "_icon_4xp4b_168",
|
|
225
|
+
official: "_official_4xp4b_173"
|
|
226
|
+
};
|
|
227
|
+
var NodeItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(NodeItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": NodeItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
228
|
+
var import_camelCase = /* @__PURE__ */ __toESM(require_camelCase());
|
|
229
|
+
var SubcategoryItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
230
|
+
__name: "SubcategoryItem",
|
|
231
|
+
props: { item: {} },
|
|
232
|
+
setup(__props) {
|
|
233
|
+
const props = __props;
|
|
234
|
+
const i18n = useI18n();
|
|
235
|
+
const subcategoryName = computed(() => (0, import_camelCase.default)(props.item.subcategory || props.item.title));
|
|
236
|
+
return (_ctx, _cache) => {
|
|
237
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
238
|
+
class: normalizeClass(_ctx.$style.subCategory),
|
|
239
|
+
title: unref(i18n).baseText(`nodeCreator.subcategoryNames.${subcategoryName.value}`),
|
|
240
|
+
"is-trigger": false,
|
|
241
|
+
description: unref(i18n).baseText(`nodeCreator.subcategoryDescriptions.${subcategoryName.value}`),
|
|
242
|
+
"show-action-arrow": true
|
|
243
|
+
}, {
|
|
244
|
+
icon: withCtx(() => [createVNode(unref(N8nNodeIcon_default), mergeProps({
|
|
245
|
+
type: "icon",
|
|
246
|
+
name: _ctx.item.icon,
|
|
247
|
+
circle: false,
|
|
248
|
+
"show-tooltip": false
|
|
249
|
+
}, _ctx.item.iconProps), null, 16, ["name"])]),
|
|
250
|
+
_: 1
|
|
251
|
+
}, 8, [
|
|
252
|
+
"class",
|
|
253
|
+
"title",
|
|
254
|
+
"description"
|
|
255
|
+
]);
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
var SubcategoryItem_vue_vue_type_style_index_0_lang_module_default = { subCategory: "_subCategory_162af_123" };
|
|
260
|
+
var SubcategoryItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(SubcategoryItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": SubcategoryItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
261
|
+
var _hoisted_1$3 = ["textContent"];
|
|
262
|
+
var LabelItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
263
|
+
__name: "LabelItem",
|
|
264
|
+
props: { item: {} },
|
|
265
|
+
setup(__props) {
|
|
266
|
+
return (_ctx, _cache) => {
|
|
267
|
+
return openBlock(), createElementBlock("div", { class: normalizeClass(_ctx.$style.label) }, [createBaseVNode("span", {
|
|
268
|
+
class: normalizeClass(_ctx.$style.name),
|
|
269
|
+
textContent: toDisplayString(_ctx.item.key)
|
|
270
|
+
}, null, 10, _hoisted_1$3)], 2);
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
});
|
|
274
|
+
var LabelItem_vue_vue_type_style_index_0_lang_module_default = { label: "_label_crtw6_123" };
|
|
275
|
+
var LabelItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(LabelItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": LabelItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
276
|
+
var ActionItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
277
|
+
__name: "ActionItem",
|
|
278
|
+
props: {
|
|
279
|
+
nodeType: {},
|
|
280
|
+
action: {}
|
|
281
|
+
},
|
|
282
|
+
setup(__props) {
|
|
283
|
+
const props = __props;
|
|
284
|
+
const telemetry = useTelemetry();
|
|
285
|
+
const { getActionData, getAddedNodesAndConnections, setAddedNodeActionParameters } = useActions();
|
|
286
|
+
const { activeViewStack } = useViewStacks();
|
|
287
|
+
const state = reactive({
|
|
288
|
+
dragging: false,
|
|
289
|
+
draggablePosition: {
|
|
290
|
+
x: -100,
|
|
291
|
+
y: -100
|
|
292
|
+
},
|
|
293
|
+
storeWatcher: null,
|
|
294
|
+
draggableDataTransfer: null
|
|
295
|
+
});
|
|
296
|
+
const draggableStyle = computed(() => ({
|
|
297
|
+
top: `${state.draggablePosition.y}px`,
|
|
298
|
+
left: `${state.draggablePosition.x}px`
|
|
299
|
+
}));
|
|
300
|
+
const actionData = computed(() => getActionData(props.action));
|
|
301
|
+
const isTriggerAction = (action$1) => action$1.name?.toLowerCase().includes("trigger") || action$1.name === "n8n-nodes-base.webhook";
|
|
302
|
+
function onDragStart(event) {
|
|
303
|
+
document.body.addEventListener("dragover", onDragOver);
|
|
304
|
+
const { pageX: x, pageY: y } = event;
|
|
305
|
+
if (event.dataTransfer && actionData.value.key) {
|
|
306
|
+
event.dataTransfer.effectAllowed = "copy";
|
|
307
|
+
event.dataTransfer.dropEffect = "copy";
|
|
308
|
+
event.dataTransfer.setDragImage(state.draggableDataTransfer, 0, 0);
|
|
309
|
+
event.dataTransfer.setData(DRAG_EVENT_DATA_KEY, JSON.stringify(getAddedNodesAndConnections([{ type: actionData.value.key }])));
|
|
310
|
+
if (telemetry) state.storeWatcher = setAddedNodeActionParameters(actionData.value, telemetry, activeViewStack.rootView);
|
|
311
|
+
document.body.addEventListener("dragend", onDragEnd);
|
|
312
|
+
}
|
|
313
|
+
state.dragging = true;
|
|
314
|
+
state.draggablePosition = {
|
|
315
|
+
x,
|
|
316
|
+
y
|
|
317
|
+
};
|
|
318
|
+
}
|
|
319
|
+
function onDragOver(event) {
|
|
320
|
+
if (!state.dragging || event.pageX === 0 && event.pageY === 0) return;
|
|
321
|
+
const [x, y] = getNewNodePosition([], [event.pageX - DEFAULT_NODE_SIZE[0] / 2, event.pageY - DEFAULT_NODE_SIZE[1] / 2]);
|
|
322
|
+
state.draggablePosition = {
|
|
323
|
+
x,
|
|
324
|
+
y
|
|
325
|
+
};
|
|
326
|
+
}
|
|
327
|
+
function onDragEnd() {
|
|
328
|
+
if (state.storeWatcher) state.storeWatcher();
|
|
329
|
+
document.body.removeEventListener("dragend", onDragEnd);
|
|
330
|
+
document.body.removeEventListener("dragover", onDragOver);
|
|
331
|
+
state.dragging = false;
|
|
332
|
+
setTimeout(() => {
|
|
333
|
+
state.draggablePosition = {
|
|
334
|
+
x: -100,
|
|
335
|
+
y: -100
|
|
336
|
+
};
|
|
337
|
+
}, 300);
|
|
338
|
+
}
|
|
339
|
+
const { draggableDataTransfer: draggableDataTransfer$2, dragging } = toRefs(state);
|
|
340
|
+
return (_ctx, _cache) => {
|
|
341
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
342
|
+
draggable: "",
|
|
343
|
+
class: normalizeClass(_ctx.$style.action),
|
|
344
|
+
title: _ctx.action.displayName,
|
|
345
|
+
"is-trigger": isTriggerAction(_ctx.action),
|
|
346
|
+
"data-keyboard-nav": "true",
|
|
347
|
+
onDragstart: onDragStart,
|
|
348
|
+
onDragend: onDragEnd
|
|
349
|
+
}, {
|
|
350
|
+
dragContent: withCtx(() => [createBaseVNode("div", {
|
|
351
|
+
ref_key: "draggableDataTransfer",
|
|
352
|
+
ref: draggableDataTransfer$2,
|
|
353
|
+
class: normalizeClass(_ctx.$style.draggableDataTransfer)
|
|
354
|
+
}, null, 2), withDirectives(createBaseVNode("div", {
|
|
355
|
+
class: normalizeClass(_ctx.$style.draggable),
|
|
356
|
+
style: normalizeStyle(draggableStyle.value)
|
|
357
|
+
}, [createVNode(NodeIcon_default, {
|
|
358
|
+
"node-type": _ctx.nodeType,
|
|
359
|
+
size: 40,
|
|
360
|
+
shrink: false,
|
|
361
|
+
onClickCapture: _cache[0] || (_cache[0] = withModifiers(() => {}, ["stop"]))
|
|
362
|
+
}, null, 8, ["node-type"])], 6), [[vShow, unref(dragging)]])]),
|
|
363
|
+
icon: withCtx(() => [createVNode(NodeIcon_default, { "node-type": _ctx.action }, null, 8, ["node-type"])]),
|
|
364
|
+
_: 1
|
|
365
|
+
}, 8, [
|
|
366
|
+
"class",
|
|
367
|
+
"title",
|
|
368
|
+
"is-trigger"
|
|
369
|
+
]);
|
|
370
|
+
};
|
|
371
|
+
}
|
|
372
|
+
});
|
|
373
|
+
var ActionItem_vue_vue_type_style_index_0_lang_module_default = {
|
|
374
|
+
action: "_action_26pq8_123",
|
|
375
|
+
nodeIcon: "_nodeIcon_26pq8_135",
|
|
376
|
+
draggable: "_draggable_26pq8_139",
|
|
377
|
+
draggableDataTransfer: "_draggableDataTransfer_26pq8_153"
|
|
378
|
+
};
|
|
379
|
+
var ActionItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(ActionItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": ActionItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
380
|
+
var ViewItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
381
|
+
__name: "ViewItem",
|
|
382
|
+
props: { view: {} },
|
|
383
|
+
setup(__props) {
|
|
384
|
+
return (_ctx, _cache) => {
|
|
385
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
386
|
+
class: normalizeClass(_ctx.$style.view),
|
|
387
|
+
title: _ctx.view.title,
|
|
388
|
+
tag: _ctx.view.tag,
|
|
389
|
+
"is-trigger": false,
|
|
390
|
+
description: _ctx.view.description,
|
|
391
|
+
"show-action-arrow": true
|
|
392
|
+
}, {
|
|
393
|
+
icon: withCtx(() => [createVNode(unref(N8nNodeIcon_default), {
|
|
394
|
+
type: "icon",
|
|
395
|
+
name: _ctx.view.icon,
|
|
396
|
+
circle: false,
|
|
397
|
+
"show-tooltip": false
|
|
398
|
+
}, null, 8, ["name"])]),
|
|
399
|
+
_: 1
|
|
400
|
+
}, 8, [
|
|
401
|
+
"class",
|
|
402
|
+
"title",
|
|
403
|
+
"tag",
|
|
404
|
+
"description"
|
|
405
|
+
]);
|
|
406
|
+
};
|
|
407
|
+
}
|
|
408
|
+
});
|
|
409
|
+
var ViewItem_vue_vue_type_style_index_0_lang_module_default = { view: "_view_6bjau_123" };
|
|
410
|
+
var ViewItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(ViewItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": ViewItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
411
|
+
var LinkItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
412
|
+
__name: "LinkItem",
|
|
413
|
+
props: { link: {} },
|
|
414
|
+
setup(__props) {
|
|
415
|
+
return (_ctx, _cache) => {
|
|
416
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
417
|
+
class: normalizeClass(_ctx.$style.creatorLink),
|
|
418
|
+
title: _ctx.link.title,
|
|
419
|
+
"is-trigger": false,
|
|
420
|
+
description: _ctx.link.description,
|
|
421
|
+
tag: _ctx.link.tag,
|
|
422
|
+
"show-action-arrow": true
|
|
423
|
+
}, {
|
|
424
|
+
icon: withCtx(() => [createVNode(unref(N8nNodeIcon_default), {
|
|
425
|
+
type: "icon",
|
|
426
|
+
name: _ctx.link.icon,
|
|
427
|
+
circle: false,
|
|
428
|
+
"show-tooltip": false
|
|
429
|
+
}, null, 8, ["name"])]),
|
|
430
|
+
_: 1
|
|
431
|
+
}, 8, [
|
|
432
|
+
"class",
|
|
433
|
+
"title",
|
|
434
|
+
"description",
|
|
435
|
+
"tag"
|
|
436
|
+
]);
|
|
437
|
+
};
|
|
438
|
+
}
|
|
439
|
+
});
|
|
440
|
+
var LinkItem_vue_vue_type_style_index_0_lang_module_default = { creatorLink: "_creatorLink_g3v4r_123" };
|
|
441
|
+
var LinkItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(LinkItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": LinkItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
442
|
+
var CommunityNodeInstallHint_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
443
|
+
__name: "CommunityNodeInstallHint",
|
|
444
|
+
props: { hint: {} },
|
|
445
|
+
setup(__props) {
|
|
446
|
+
const isOwner = computed(() => useUsersStore().isInstanceOwner);
|
|
447
|
+
return (_ctx, _cache) => {
|
|
448
|
+
return isOwner.value ? (openBlock(), createElementBlock("div", {
|
|
449
|
+
key: 0,
|
|
450
|
+
class: normalizeClass(_ctx.$style.container)
|
|
451
|
+
}, [createVNode(unref(N8nIcon_default), {
|
|
452
|
+
color: "text-light",
|
|
453
|
+
icon: "info",
|
|
454
|
+
size: "large"
|
|
455
|
+
}), createVNode(unref(N8nText_default), {
|
|
456
|
+
color: "text-base",
|
|
457
|
+
size: "medium"
|
|
458
|
+
}, {
|
|
459
|
+
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.hint), 1)]),
|
|
460
|
+
_: 1
|
|
461
|
+
})], 2)) : createCommentVNode("", true);
|
|
462
|
+
};
|
|
463
|
+
}
|
|
464
|
+
});
|
|
465
|
+
var CommunityNodeInstallHint_vue_vue_type_style_index_0_lang_module_default = { container: "_container_ikrhv_123" };
|
|
466
|
+
var CommunityNodeInstallHint_default = /* @__PURE__ */ __plugin_vue_export_helper_default(CommunityNodeInstallHint_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": CommunityNodeInstallHint_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
467
|
+
var CommunityNodeItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
468
|
+
__name: "CommunityNodeItem",
|
|
469
|
+
props: { isPreview: { type: Boolean } },
|
|
470
|
+
setup(__props) {
|
|
471
|
+
const i18n = useI18n();
|
|
472
|
+
return (_ctx, _cache) => {
|
|
473
|
+
return openBlock(), createElementBlock("div", null, [_ctx.isPreview ? (openBlock(), createBlock(CommunityNodeInstallHint_default, {
|
|
474
|
+
key: 0,
|
|
475
|
+
hint: unref(i18n).baseText("communityNodeItem.node.hint")
|
|
476
|
+
}, null, 8, ["hint"])) : (openBlock(), createElementBlock("div", {
|
|
477
|
+
key: 1,
|
|
478
|
+
class: normalizeClass(_ctx.$style.marginLeft)
|
|
479
|
+
}, [createVNode(unref(N8nButton_default), {
|
|
480
|
+
size: "medium",
|
|
481
|
+
type: "secondary",
|
|
482
|
+
icon: "plus",
|
|
483
|
+
label: unref(i18n).baseText("communityNodeItem.label"),
|
|
484
|
+
outline: ""
|
|
485
|
+
}, null, 8, ["label"])], 2))]);
|
|
486
|
+
};
|
|
487
|
+
}
|
|
488
|
+
});
|
|
489
|
+
var CommunityNodeItem_vue_vue_type_style_index_0_lang_module_default = { marginLeft: "_marginLeft_1q8y4_123" };
|
|
490
|
+
var CommunityNodeItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(CommunityNodeItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": CommunityNodeItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
491
|
+
var _hoisted_1$2 = ["textContent"];
|
|
492
|
+
var CategoryItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
493
|
+
__name: "CategoryItem",
|
|
494
|
+
props: {
|
|
495
|
+
expanded: {
|
|
496
|
+
type: Boolean,
|
|
497
|
+
default: true
|
|
498
|
+
},
|
|
499
|
+
active: { type: Boolean },
|
|
500
|
+
count: {},
|
|
501
|
+
name: {},
|
|
502
|
+
isTrigger: { type: Boolean }
|
|
503
|
+
},
|
|
504
|
+
setup(__props) {
|
|
505
|
+
const props = __props;
|
|
506
|
+
const categoryName = computed(() => {
|
|
507
|
+
const itemsCount = props.count || 0;
|
|
508
|
+
return itemsCount > 0 ? `${props.name} (${itemsCount})` : props.name;
|
|
509
|
+
});
|
|
510
|
+
return (_ctx, _cache) => {
|
|
511
|
+
return openBlock(), createElementBlock("div", mergeProps({ class: _ctx.$style.categoryWrapper }, _ctx.$attrs, {
|
|
512
|
+
"data-keyboard-nav": "true",
|
|
513
|
+
"data-test-id": "node-creator-category-item"
|
|
514
|
+
}), [createBaseVNode("div", { class: normalizeClass({
|
|
515
|
+
[_ctx.$style.category]: true,
|
|
516
|
+
[_ctx.$style.active]: _ctx.active
|
|
517
|
+
}) }, [createBaseVNode("span", { class: normalizeClass(_ctx.$style.name) }, [
|
|
518
|
+
createBaseVNode("span", { textContent: toDisplayString(categoryName.value) }, null, 8, _hoisted_1$2),
|
|
519
|
+
_ctx.isTrigger ? (openBlock(), createBlock(unref(N8nIcon_default), {
|
|
520
|
+
key: 0,
|
|
521
|
+
icon: "bolt-filled",
|
|
522
|
+
size: "xsmall",
|
|
523
|
+
class: normalizeClass(_ctx.$style.triggerIcon)
|
|
524
|
+
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
525
|
+
renderSlot(_ctx.$slots, "default")
|
|
526
|
+
], 2), _ctx.expanded ? (openBlock(), createBlock(unref(N8nIcon_default), {
|
|
527
|
+
key: 0,
|
|
528
|
+
icon: "chevron-down",
|
|
529
|
+
color: "text-light",
|
|
530
|
+
size: "large"
|
|
531
|
+
})) : (openBlock(), createBlock(unref(N8nIcon_default), {
|
|
532
|
+
key: 1,
|
|
533
|
+
icon: "chevron-up",
|
|
534
|
+
color: "text-light",
|
|
535
|
+
size: "large"
|
|
536
|
+
}))], 2)], 16);
|
|
537
|
+
};
|
|
538
|
+
}
|
|
539
|
+
});
|
|
540
|
+
var CategoryItem_vue_vue_type_style_index_0_lang_module_default = {
|
|
541
|
+
triggerIcon: "_triggerIcon_2nqmq_123",
|
|
542
|
+
category: "_category_2nqmq_128",
|
|
543
|
+
active: "_active_2nqmq_149",
|
|
544
|
+
name: "_name_2nqmq_153"
|
|
545
|
+
};
|
|
546
|
+
var CategoryItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(CategoryItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": CategoryItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
547
|
+
var _hoisted_1$1 = ["data-category-collapsed"];
|
|
548
|
+
var CategorizedItemsRenderer_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
549
|
+
__name: "CategorizedItemsRenderer",
|
|
550
|
+
props: {
|
|
551
|
+
elements: { default: () => [] },
|
|
552
|
+
category: {},
|
|
553
|
+
disabled: { type: Boolean },
|
|
554
|
+
activeIndex: {},
|
|
555
|
+
isTriggerCategory: { type: Boolean },
|
|
556
|
+
mouseOverTooltip: {},
|
|
557
|
+
expanded: { type: Boolean }
|
|
558
|
+
},
|
|
559
|
+
setup(__props) {
|
|
560
|
+
const props = __props;
|
|
561
|
+
const { popViewStack, activeViewStack } = useViewStacks();
|
|
562
|
+
const { registerKeyHook } = useKeyboardNavigation();
|
|
563
|
+
const { workflowId } = useWorkflowsStore();
|
|
564
|
+
const nodeCreatorStore = useNodeCreatorStore();
|
|
565
|
+
const i18n = useI18n();
|
|
566
|
+
const activeItemId = computed(() => useKeyboardNavigation()?.activeItemId);
|
|
567
|
+
const actionCount = computed(() => props.elements.filter(({ type }) => type === "action").length);
|
|
568
|
+
const expanded = ref(props.expanded ?? false);
|
|
569
|
+
const isPreview = computed(() => activeViewStack.communityNodeDetails && !activeViewStack.communityNodeDetails.installed);
|
|
570
|
+
function toggleExpanded() {
|
|
571
|
+
setExpanded(!expanded.value);
|
|
572
|
+
}
|
|
573
|
+
function setExpanded(isExpanded) {
|
|
574
|
+
const prev = expanded.value;
|
|
575
|
+
expanded.value = isExpanded;
|
|
576
|
+
if (expanded.value && !prev) nodeCreatorStore.onCategoryExpanded({
|
|
577
|
+
category_name: props.category,
|
|
578
|
+
workflow_id: workflowId
|
|
579
|
+
});
|
|
580
|
+
}
|
|
581
|
+
function arrowRight() {
|
|
582
|
+
if (expanded.value) return;
|
|
583
|
+
setExpanded(true);
|
|
584
|
+
}
|
|
585
|
+
function arrowLeft() {
|
|
586
|
+
if (!expanded.value) {
|
|
587
|
+
popViewStack();
|
|
588
|
+
return;
|
|
589
|
+
}
|
|
590
|
+
setExpanded(false);
|
|
591
|
+
}
|
|
592
|
+
watch(() => props.elements, () => {
|
|
593
|
+
setExpanded(true);
|
|
594
|
+
});
|
|
595
|
+
registerKeyHook(`CategoryRight_${props.category}`, {
|
|
596
|
+
keyboardKeys: ["ArrowRight"],
|
|
597
|
+
condition: (type, activeItemId$1) => type === "category" && props.category === activeItemId$1,
|
|
598
|
+
handler: arrowRight
|
|
599
|
+
});
|
|
600
|
+
registerKeyHook(`CategoryToggle_${props.category}`, {
|
|
601
|
+
keyboardKeys: ["Enter"],
|
|
602
|
+
condition: (type, activeItemId$1) => type === "category" && props.category === activeItemId$1,
|
|
603
|
+
handler: toggleExpanded
|
|
604
|
+
});
|
|
605
|
+
registerKeyHook(`CategoryLeft_${props.category}`, {
|
|
606
|
+
keyboardKeys: ["ArrowLeft"],
|
|
607
|
+
condition: (type, activeItemId$1) => type === "category" && props.category === activeItemId$1,
|
|
608
|
+
handler: arrowLeft
|
|
609
|
+
});
|
|
610
|
+
return (_ctx, _cache) => {
|
|
611
|
+
const _directive_n8n_html = resolveDirective("n8n-html");
|
|
612
|
+
return openBlock(), createElementBlock("div", {
|
|
613
|
+
class: normalizeClass(_ctx.$style.categorizedItemsRenderer),
|
|
614
|
+
"data-category-collapsed": !expanded.value
|
|
615
|
+
}, [
|
|
616
|
+
createVNode(CategoryItem_default, {
|
|
617
|
+
class: normalizeClass(_ctx.$style.categoryItem),
|
|
618
|
+
name: _ctx.category,
|
|
619
|
+
disabled: _ctx.disabled,
|
|
620
|
+
active: activeItemId.value === _ctx.category,
|
|
621
|
+
count: actionCount.value,
|
|
622
|
+
expanded: expanded.value,
|
|
623
|
+
"is-trigger": _ctx.isTriggerCategory,
|
|
624
|
+
"data-keyboard-nav-type": "category",
|
|
625
|
+
"data-keyboard-nav-id": _ctx.category,
|
|
626
|
+
onClick: toggleExpanded
|
|
627
|
+
}, {
|
|
628
|
+
default: withCtx(() => [_ctx.mouseOverTooltip ? (openBlock(), createElementBlock("span", {
|
|
629
|
+
key: 0,
|
|
630
|
+
class: normalizeClass(_ctx.$style.mouseOverTooltip)
|
|
631
|
+
}, [createVNode(unref(N8nTooltip_default), {
|
|
632
|
+
placement: "top",
|
|
633
|
+
"popper-class": _ctx.$style.tooltipPopper
|
|
634
|
+
}, {
|
|
635
|
+
content: withCtx(() => [withDirectives(createBaseVNode("div", null, null, 512), [[_directive_n8n_html, _ctx.mouseOverTooltip]])]),
|
|
636
|
+
default: withCtx(() => [createVNode(unref(N8nIcon_default), {
|
|
637
|
+
icon: "circle-help",
|
|
638
|
+
size: "small"
|
|
639
|
+
})]),
|
|
640
|
+
_: 1
|
|
641
|
+
}, 8, ["popper-class"])], 2)) : createCommentVNode("", true)]),
|
|
642
|
+
_: 1
|
|
643
|
+
}, 8, [
|
|
644
|
+
"class",
|
|
645
|
+
"name",
|
|
646
|
+
"disabled",
|
|
647
|
+
"active",
|
|
648
|
+
"count",
|
|
649
|
+
"expanded",
|
|
650
|
+
"is-trigger",
|
|
651
|
+
"data-keyboard-nav-id"
|
|
652
|
+
]),
|
|
653
|
+
expanded.value && actionCount.value > 0 && _ctx.$slots.default ? (openBlock(), createElementBlock("div", {
|
|
654
|
+
key: 0,
|
|
655
|
+
class: normalizeClass(_ctx.$style.contentSlot)
|
|
656
|
+
}, [renderSlot(_ctx.$slots, "default")], 2)) : createCommentVNode("", true),
|
|
657
|
+
isPreview.value && expanded.value ? (openBlock(), createBlock(CommunityNodeInstallHint_default, {
|
|
658
|
+
key: 1,
|
|
659
|
+
hint: unref(i18n).baseText("communityNodeItem.actions.hint")
|
|
660
|
+
}, null, 8, ["hint"])) : createCommentVNode("", true),
|
|
661
|
+
expanded.value ? (openBlock(), createBlock(ItemsRenderer_default, mergeProps({ key: 2 }, _ctx.$attrs, {
|
|
662
|
+
elements: _ctx.elements,
|
|
663
|
+
"is-trigger": _ctx.isTriggerCategory,
|
|
664
|
+
class: [{ [_ctx.$style.preview]: isPreview.value }]
|
|
665
|
+
}), {
|
|
666
|
+
default: withCtx(() => _cache[0] || (_cache[0] = [])),
|
|
667
|
+
empty: withCtx(() => [renderSlot(_ctx.$slots, "empty", normalizeProps(guardReactiveProps({ elements: _ctx.elements })))]),
|
|
668
|
+
_: 3
|
|
669
|
+
}, 16, [
|
|
670
|
+
"elements",
|
|
671
|
+
"is-trigger",
|
|
672
|
+
"class"
|
|
673
|
+
])) : createCommentVNode("", true)
|
|
674
|
+
], 10, _hoisted_1$1);
|
|
675
|
+
};
|
|
676
|
+
}
|
|
677
|
+
});
|
|
678
|
+
var CategorizedItemsRenderer_vue_vue_type_style_index_0_lang_module_default = {
|
|
679
|
+
mouseOverTooltip: "_mouseOverTooltip_1c8sx_123",
|
|
680
|
+
categorizedItemsRenderer: "_categorizedItemsRenderer_1c8sx_131",
|
|
681
|
+
tooltipPopper: "_tooltipPopper_1c8sx_135",
|
|
682
|
+
contentSlot: "_contentSlot_1c8sx_139",
|
|
683
|
+
preview: "_preview_1c8sx_148"
|
|
684
|
+
};
|
|
685
|
+
var CategorizedItemsRenderer_default = /* @__PURE__ */ __plugin_vue_export_helper_default(CategorizedItemsRenderer_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": CategorizedItemsRenderer_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
686
|
+
var OpenTemplateItem_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
687
|
+
__name: "OpenTemplateItem",
|
|
688
|
+
props: { openTemplate: {} },
|
|
689
|
+
setup(__props) {
|
|
690
|
+
return (_ctx, _cache) => {
|
|
691
|
+
return openBlock(), createBlock(unref(N8nNodeCreatorNode_default), {
|
|
692
|
+
class: normalizeClass({
|
|
693
|
+
[_ctx.$style.creatorOpenTemplate]: true,
|
|
694
|
+
[_ctx.$style.compact]: _ctx.openTemplate.compact
|
|
695
|
+
}),
|
|
696
|
+
title: _ctx.openTemplate.title,
|
|
697
|
+
description: _ctx.openTemplate.description,
|
|
698
|
+
tag: _ctx.openTemplate.tag,
|
|
699
|
+
"show-action-arrow": true,
|
|
700
|
+
"is-trigger": false
|
|
701
|
+
}, createSlots({ _: 2 }, [_ctx.openTemplate.icon ? {
|
|
702
|
+
name: "icon",
|
|
703
|
+
fn: withCtx(() => [createVNode(unref(N8nNodeIcon_default), {
|
|
704
|
+
type: "icon",
|
|
705
|
+
name: _ctx.openTemplate.icon,
|
|
706
|
+
circle: false,
|
|
707
|
+
"show-tooltip": false
|
|
708
|
+
}, null, 8, ["name"])]),
|
|
709
|
+
key: "0"
|
|
710
|
+
} : void 0, _ctx.openTemplate.nodes ? {
|
|
711
|
+
name: "extraDetails",
|
|
712
|
+
fn: withCtx(() => [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.openTemplate.nodes, (node) => {
|
|
713
|
+
return openBlock(), createBlock(NodeIcon_default, {
|
|
714
|
+
key: node.name,
|
|
715
|
+
"node-type": node,
|
|
716
|
+
size: 16,
|
|
717
|
+
"show-tooltip": true
|
|
718
|
+
}, null, 8, ["node-type"]);
|
|
719
|
+
}), 128))]),
|
|
720
|
+
key: "1"
|
|
721
|
+
} : void 0]), 1032, [
|
|
722
|
+
"class",
|
|
723
|
+
"title",
|
|
724
|
+
"description",
|
|
725
|
+
"tag"
|
|
726
|
+
]);
|
|
727
|
+
};
|
|
728
|
+
}
|
|
729
|
+
});
|
|
730
|
+
var OpenTemplateItem_vue_vue_type_style_index_0_lang_module_default = {
|
|
731
|
+
creatorOpenTemplate: "_creatorOpenTemplate_tyk6y_123",
|
|
732
|
+
compact: "_compact_tyk6y_131"
|
|
733
|
+
};
|
|
734
|
+
var OpenTemplateItem_default = /* @__PURE__ */ __plugin_vue_export_helper_default(OpenTemplateItem_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": OpenTemplateItem_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
735
|
+
var _hoisted_1 = { key: 0 };
|
|
736
|
+
var _hoisted_2 = [
|
|
737
|
+
"data-keyboard-nav-type",
|
|
738
|
+
"data-keyboard-nav-id",
|
|
739
|
+
"onClick"
|
|
740
|
+
];
|
|
741
|
+
var LAZY_LOAD_THRESHOLD = 20;
|
|
742
|
+
var LAZY_LOAD_ITEMS_PER_TICK = 5;
|
|
743
|
+
var ItemsRenderer_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
744
|
+
__name: "ItemsRenderer",
|
|
745
|
+
props: {
|
|
746
|
+
elements: { default: () => [] },
|
|
747
|
+
activeIndex: {},
|
|
748
|
+
disabled: { type: Boolean },
|
|
749
|
+
lazyRender: {
|
|
750
|
+
type: Boolean,
|
|
751
|
+
default: true
|
|
752
|
+
}
|
|
753
|
+
},
|
|
754
|
+
emits: [
|
|
755
|
+
"selected",
|
|
756
|
+
"dragstart",
|
|
757
|
+
"dragend"
|
|
758
|
+
],
|
|
759
|
+
setup(__props, { emit: __emit }) {
|
|
760
|
+
const props = __props;
|
|
761
|
+
const emit = __emit;
|
|
762
|
+
const renderedItems = ref([]);
|
|
763
|
+
const renderAnimationRequest = ref(0);
|
|
764
|
+
const { activeViewStack } = useViewStacks();
|
|
765
|
+
const activeItemId = computed(() => useKeyboardNavigation()?.activeItemId);
|
|
766
|
+
const communityNode = computed(() => activeViewStack.mode === "community-node");
|
|
767
|
+
const isPreview = computed(() => {
|
|
768
|
+
return communityNode.value && !activeViewStack.communityNodeDetails?.installed;
|
|
769
|
+
});
|
|
770
|
+
const highlightActiveItem = computed(() => {
|
|
771
|
+
if (activeViewStack.communityNodeDetails && !activeViewStack.communityNodeDetails.installed) return false;
|
|
772
|
+
return true;
|
|
773
|
+
});
|
|
774
|
+
function renderItems() {
|
|
775
|
+
if (props.elements.length <= LAZY_LOAD_THRESHOLD || !props.lazyRender) {
|
|
776
|
+
renderedItems.value = props.elements;
|
|
777
|
+
return;
|
|
778
|
+
}
|
|
779
|
+
if (renderedItems.value.length < props.elements.length) {
|
|
780
|
+
renderedItems.value.push(...props.elements.slice(renderedItems.value.length, renderedItems.value.length + LAZY_LOAD_ITEMS_PER_TICK));
|
|
781
|
+
renderAnimationRequest.value = window.requestAnimationFrame(renderItems);
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
function wrappedEmit(event, element, $e) {
|
|
785
|
+
if (props.disabled) return;
|
|
786
|
+
switch (event) {
|
|
787
|
+
case "dragstart": if ($e) {
|
|
788
|
+
emit("dragstart", element, $e);
|
|
789
|
+
break;
|
|
790
|
+
}
|
|
791
|
+
case "dragend": if ($e) {
|
|
792
|
+
emit("dragend", element, $e);
|
|
793
|
+
break;
|
|
794
|
+
}
|
|
795
|
+
case "selected":
|
|
796
|
+
emit("selected", element, $e);
|
|
797
|
+
break;
|
|
798
|
+
default: emit(event, element, $e);
|
|
799
|
+
}
|
|
800
|
+
}
|
|
801
|
+
function beforeEnter(el) {
|
|
802
|
+
el.style.height = "0";
|
|
803
|
+
}
|
|
804
|
+
function enter(el) {
|
|
805
|
+
el.style.height = `${el.scrollHeight}px`;
|
|
806
|
+
}
|
|
807
|
+
function beforeLeave(el) {
|
|
808
|
+
el.style.height = `${el.scrollHeight}px`;
|
|
809
|
+
}
|
|
810
|
+
function leave(el) {
|
|
811
|
+
el.style.height = "0";
|
|
812
|
+
}
|
|
813
|
+
onMounted(() => {
|
|
814
|
+
renderItems();
|
|
815
|
+
});
|
|
816
|
+
onUnmounted(() => {
|
|
817
|
+
window.cancelAnimationFrame(renderAnimationRequest.value);
|
|
818
|
+
renderedItems.value = [];
|
|
819
|
+
});
|
|
820
|
+
watch(() => props.elements, () => {
|
|
821
|
+
window.cancelAnimationFrame(renderAnimationRequest.value);
|
|
822
|
+
renderedItems.value = [];
|
|
823
|
+
renderItems();
|
|
824
|
+
});
|
|
825
|
+
return (_ctx, _cache) => {
|
|
826
|
+
return _ctx.elements.length > 0 ? (openBlock(), createElementBlock("div", {
|
|
827
|
+
key: 0,
|
|
828
|
+
class: normalizeClass(_ctx.$style.itemsRenderer),
|
|
829
|
+
name: "accordion",
|
|
830
|
+
onBeforeEnter: beforeEnter,
|
|
831
|
+
onEnter: enter,
|
|
832
|
+
onBeforeLeave: beforeLeave,
|
|
833
|
+
onLeave: leave
|
|
834
|
+
}, [renderSlot(_ctx.$slots, "default"), (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.elements, (item) => {
|
|
835
|
+
return openBlock(), createElementBlock("div", { key: item.uuid }, [renderedItems.value.includes(item) ? (openBlock(), createElementBlock("div", _hoisted_1, [item.type === "section" ? (openBlock(), createBlock(CategorizedItemsRenderer_default, {
|
|
836
|
+
key: 0,
|
|
837
|
+
elements: item.children,
|
|
838
|
+
expanded: "",
|
|
839
|
+
category: item.title,
|
|
840
|
+
onSelected: _cache[0] || (_cache[0] = (child) => wrappedEmit("selected", child))
|
|
841
|
+
}, null, 8, ["elements", "category"])) : (openBlock(), createElementBlock("div", {
|
|
842
|
+
key: 1,
|
|
843
|
+
ref_for: true,
|
|
844
|
+
ref: "iteratorItems",
|
|
845
|
+
class: normalizeClass({
|
|
846
|
+
clickable: !_ctx.disabled,
|
|
847
|
+
[_ctx.$style.active]: activeItemId.value === item.uuid && highlightActiveItem.value,
|
|
848
|
+
[_ctx.$style.iteratorItem]: !communityNode.value,
|
|
849
|
+
[_ctx.$style[item.type]]: true,
|
|
850
|
+
[_ctx.$style.preview]: isPreview.value,
|
|
851
|
+
[_ctx.$style.borderless]: item.type === "view" && item.properties.borderless === true
|
|
852
|
+
}),
|
|
853
|
+
"data-test-id": "item-iterator-item",
|
|
854
|
+
"data-keyboard-nav-type": item.type !== "label" ? item.type : void 0,
|
|
855
|
+
"data-keyboard-nav-id": item.uuid,
|
|
856
|
+
onClick: ($event) => wrappedEmit("selected", item)
|
|
857
|
+
}, [
|
|
858
|
+
item.type === "label" ? (openBlock(), createBlock(LabelItem_default, {
|
|
859
|
+
key: 0,
|
|
860
|
+
item
|
|
861
|
+
}, null, 8, ["item"])) : createCommentVNode("", true),
|
|
862
|
+
item.type === "subcategory" ? (openBlock(), createBlock(SubcategoryItem_default, {
|
|
863
|
+
key: 1,
|
|
864
|
+
item: item.properties
|
|
865
|
+
}, null, 8, ["item"])) : createCommentVNode("", true),
|
|
866
|
+
communityNode.value ? (openBlock(), createBlock(CommunityNodeItem_default, {
|
|
867
|
+
key: 2,
|
|
868
|
+
"is-preview": isPreview.value
|
|
869
|
+
}, null, 8, ["is-preview"])) : createCommentVNode("", true),
|
|
870
|
+
item.type === "node" && !communityNode.value ? (openBlock(), createBlock(NodeItem_default, {
|
|
871
|
+
key: 3,
|
|
872
|
+
"node-type": item.properties,
|
|
873
|
+
active: true,
|
|
874
|
+
subcategory: item.subcategory
|
|
875
|
+
}, null, 8, ["node-type", "subcategory"])) : createCommentVNode("", true),
|
|
876
|
+
item.type === "action" ? (openBlock(), createBlock(ActionItem_default, {
|
|
877
|
+
key: 4,
|
|
878
|
+
"node-type": item.properties,
|
|
879
|
+
action: item.properties,
|
|
880
|
+
active: true
|
|
881
|
+
}, null, 8, ["node-type", "action"])) : item.type === "view" ? (openBlock(), createBlock(ViewItem_default, {
|
|
882
|
+
key: 5,
|
|
883
|
+
view: item.properties,
|
|
884
|
+
class: normalizeClass(_ctx.$style.viewItem)
|
|
885
|
+
}, null, 8, ["view", "class"])) : item.type === "link" ? (openBlock(), createBlock(LinkItem_default, {
|
|
886
|
+
key: 6,
|
|
887
|
+
link: item.properties,
|
|
888
|
+
class: normalizeClass(_ctx.$style.linkItem)
|
|
889
|
+
}, null, 8, ["link", "class"])) : item.type === "openTemplate" ? (openBlock(), createBlock(OpenTemplateItem_default, {
|
|
890
|
+
key: 7,
|
|
891
|
+
"open-template": item.properties,
|
|
892
|
+
class: normalizeClass(_ctx.$style.linkItem)
|
|
893
|
+
}, null, 8, ["open-template", "class"])) : createCommentVNode("", true)
|
|
894
|
+
], 10, _hoisted_2))])) : (openBlock(), createBlock(unref(N8nLoading_default), {
|
|
895
|
+
key: 1,
|
|
896
|
+
loading: true,
|
|
897
|
+
rows: 1,
|
|
898
|
+
variant: "p",
|
|
899
|
+
class: normalizeClass(_ctx.$style.itemSkeleton)
|
|
900
|
+
}, null, 8, ["class"]))]);
|
|
901
|
+
}), 128))], 34)) : (openBlock(), createElementBlock("div", {
|
|
902
|
+
key: 1,
|
|
903
|
+
class: normalizeClass(_ctx.$style.empty)
|
|
904
|
+
}, [renderSlot(_ctx.$slots, "empty")], 2));
|
|
905
|
+
};
|
|
906
|
+
}
|
|
907
|
+
});
|
|
908
|
+
var ItemsRenderer_vue_vue_type_style_index_0_lang_module_default = {
|
|
909
|
+
itemSkeleton: "_itemSkeleton_1ehs8_123",
|
|
910
|
+
iteratorItem: "_iteratorItem_1ehs8_127",
|
|
911
|
+
label: "_label_1ehs8_139",
|
|
912
|
+
category: "_category_1ehs8_139",
|
|
913
|
+
active: "_active_1ehs8_142",
|
|
914
|
+
empty: "_empty_1ehs8_146",
|
|
915
|
+
itemsRenderer: "_itemsRenderer_1ehs8_150",
|
|
916
|
+
view: "_view_1ehs8_159",
|
|
917
|
+
link: "_link_1ehs8_177",
|
|
918
|
+
borderless: "_borderless_1ehs8_195",
|
|
919
|
+
preview: "_preview_1ehs8_205"
|
|
920
|
+
};
|
|
921
|
+
var ItemsRenderer_default = /* @__PURE__ */ __plugin_vue_export_helper_default(ItemsRenderer_vue_vue_type_script_setup_true_lang_default, [["__cssModules", { "$style": ItemsRenderer_vue_vue_type_style_index_0_lang_module_default }]]);
|
|
922
|
+
export { SlideTransition_default as i, CategorizedItemsRenderer_default as n, verified_default as r, ItemsRenderer_default as t };
|