n8n-editor-ui 1.104.1 → 1.105.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/dist/assets/{AnimatedSpinner-D6j3zAN7.js → AnimatedSpinner-CiVjnVTs.js} +1 -1
- package/dist/assets/{AnnotationTagsDropdown.ee.vue_vue_type_script_setup_true_lang-CeptN1qB.js → AnnotationTagsDropdown.ee.vue_vue_type_script_setup_true_lang-Duv062St.js} +1 -1
- package/dist/assets/{AuthView-DdzGr3if.js → AuthView-Dpa-SRT8.js} +2 -2
- package/dist/assets/{ChangePasswordView-CLbLuldY.js → ChangePasswordView-CB9uaGfm.js} +3 -3
- package/dist/assets/CollectionParameter-oBzQ1Hh-.js +4 -0
- package/dist/assets/{ConsumedTokensDetails.vue_vue_type_script_setup_true_lang-DwQ0BmLY.js → ConsumedTokensDetails.vue_vue_type_script_setup_true_lang-DIcGPKiM.js} +1 -1
- package/dist/assets/{CredentialsView-Cbm8N2D-.js → CredentialsView-AW9gSm0C.js} +8 -8
- package/dist/assets/{DemoFooter-DlHqx3Wb.js → DemoFooter-DybJBgCY.js} +6 -9
- package/dist/assets/{EmptySharedSectionActionBox.vue_vue_type_script_setup_true_lang-Dymz7mm-.js → EmptySharedSectionActionBox.vue_vue_type_script_setup_true_lang-GcMQ_YdZ.js} +1 -1
- package/dist/assets/{EntityNotFound-CmBDOsai.js → EntityNotFound-Bi2pl54e.js} +1 -1
- package/dist/assets/{EntityUnAuthorised-CNPmvmZu.js → EntityUnAuthorised-HDf2HNt2.js} +1 -1
- package/dist/assets/{ErrorView-BqgIhqko.js → ErrorView-BPodDJdx.js} +1 -1
- package/dist/assets/{EvaluationsRootView-B6RDbMu9.js → EvaluationsRootView-pO4cP-Fb.js} +1 -1
- package/dist/assets/{EvaluationsView-nr07_JFX.js → EvaluationsView-CI108a8E.js} +3 -3
- package/dist/assets/{ExecutionsTime-Bo7IOE5K.css → ExecutionsTime-etWexlXm.css} +6 -6
- package/dist/assets/{ExecutionsTime.vue_vue_type_script_setup_true_lang-Ci1SWv1r.js → ExecutionsTime.vue_vue_type_script_setup_true_lang-CGxPzqoO.js} +23 -30
- package/dist/assets/{ExecutionsView-L8QB4qb-.js → ExecutionsView-BaQKVP7R.js} +8 -9
- package/dist/assets/{FixedCollectionParameter-BMsoLNRT.js → FixedCollectionParameter-BpCwKUsj.js} +1 -1
- package/dist/assets/{ForgotMyPasswordView-BYKQXHHe.js → ForgotMyPasswordView-CPC4cOzo.js} +3 -3
- package/dist/assets/{InfoAccordion-DN17_QNh.js → InfoAccordion-M_n3OwQC.js} +1 -1
- package/dist/assets/{InsightsChartAverageRuntime-DX6MWomC.js → InsightsChartAverageRuntime-CECRGvo9.js} +4 -4
- package/dist/assets/{InsightsChartFailed-D1ITW7ip.js → InsightsChartFailed-CTysIk94.js} +4 -4
- package/dist/assets/{InsightsChartFailureRate-DsoCFhrx.js → InsightsChartFailureRate-LYCt3dgO.js} +4 -4
- package/dist/assets/{InsightsChartTimeSaved-Cwb0-EZ1.js → InsightsChartTimeSaved-msRVtM_g.js} +4 -4
- package/dist/assets/{InsightsChartTotal-B-SjjDG4.js → InsightsChartTotal-B_SUDPoP.js} +4 -4
- package/dist/assets/{InsightsDashboard-DEaMMGfn.js → InsightsDashboard-CEgagMwD.js} +10 -10
- package/dist/assets/{InsightsPaywall-BsiLaxNd.js → InsightsPaywall-EnxDs7BF.js} +1 -1
- package/dist/assets/{InsightsSummary-hBcY77J_.js → InsightsSummary-DWzNYCfc.js} +1 -1
- package/dist/assets/{InsightsTableWorkflows-D9vFPmUm.js → InsightsTableWorkflows-Dl55NtXk.js} +5 -5
- package/dist/assets/{Logo-D-nqGbZ-.js → Logo-MNn4rP0b.js} +1 -1
- package/dist/assets/{LogsPanel-D0xdq4fV.css → LogsPanel-B-Tmod-K.css} +25 -22
- package/dist/assets/{LogsPanel-D0QGW50a.js → LogsPanel-DN3BXSh7.js} +209 -51
- package/dist/assets/{MainHeader-QpSmh7DV.js → MainHeader-F9ONi2FH.js} +8 -10
- package/dist/assets/{MainSidebar-Dndr9Vcx.js → MainSidebar-Bf58ZTkX.js} +2 -3
- package/dist/assets/{N8nDataTableServer-B4Gq_Urn.js → N8nDataTableServer-PFDwZhpw.js} +1 -1
- package/dist/assets/{NodeCreation-CRGHu2mV.js → NodeCreation-B9FRFHG0.js} +16 -13
- package/dist/assets/{NodeCreator-BvleRmX-.js → NodeCreator-nBzvpVJI.js} +11 -20
- package/dist/assets/{NodeDetailsView-xvbRzTfv.js → NodeDetailsView-CQQOZQXq.js} +13 -17
- package/dist/assets/{NodeDetailsViewV2-CBY4UJcE.js → NodeDetailsViewV2-DKnduvJH.js} +27 -31
- package/dist/assets/{NodeDetailsViewV2-BxNx4ZUM.css → NodeDetailsViewV2-LLVofUjw.css} +21 -19
- package/dist/assets/NodeView-B2097MY0.css +852 -0
- package/dist/assets/NodeView-rsVaGRIZ.js +2684 -0
- package/dist/assets/{ProjectHeader-0NxiEwQl.js → ProjectHeader-B8m2WaGw.js} +2 -2
- package/dist/assets/{ProjectSettings-ClM6Y9uS.js → ProjectSettings-CKIJ3B4S.js} +3 -3
- package/dist/assets/{PushConnectionTracker.vue_vue_type_script_setup_true_lang-D5JeFl_d.js → PushConnectionTracker.vue_vue_type_script_setup_true_lang-D5oQ44UZ.js} +1 -1
- package/dist/assets/{ResourcesListLayout-BRro9C-1.js → ResourcesListLayout-G2r5AxKI.js} +3 -3
- package/dist/assets/{RunDataJson-12Py20Rs.js → RunDataJson-CAcnDJHh.js} +3 -6
- package/dist/assets/{RunDataJsonActions-BGl8YYU0.js → RunDataJsonActions-jhh18-uN.js} +13 -13
- package/dist/assets/{RunDataParsedAiContent-DYz5OPxJ.js → RunDataParsedAiContent-B8wa1hGI.js} +25 -11
- package/dist/assets/{RunDataSearch-NmwtxOjZ.js → RunDataSearch-CFmNTJ3I.js} +1 -1
- package/dist/assets/{RunDataTable-DJu8Ut0r.js → RunDataTable-91h3y7DT.js} +1 -2
- package/dist/assets/{SamlOnboarding-B5vqtns9.js → SamlOnboarding-8Gb7hf0c.js} +3 -3
- package/dist/assets/{SettingsApiView-DmOvPlm6.js → SettingsApiView-BozlwAdS.js} +1 -1
- package/dist/assets/{SettingsCommunityNodesView-DEgzWHlF.js → SettingsCommunityNodesView-RlNbis18.js} +4 -4
- package/dist/assets/{SettingsExternalSecrets-4VNCsQKo.js → SettingsExternalSecrets-Blou_9Mh.js} +1 -1
- package/dist/assets/{SettingsLdapView-BSQe5yy-.js → SettingsLdapView-wf-fX_Jl.js} +1 -1
- package/dist/assets/{SettingsLogStreamingView-Y-ve-MUB.js → SettingsLogStreamingView-DNaMOOjb.js} +1 -1
- package/dist/assets/{SettingsPersonalView-DTWO2GIc.js → SettingsPersonalView-DzYhwUgL.js} +1 -1
- package/dist/assets/{SettingsSourceControl-D14mBzgS.js → SettingsSourceControl-D5eiGsMG.js} +1 -1
- package/dist/assets/{SettingsSso-Beon1K6u.js → SettingsSso-BF8vNEd4.js} +7 -12
- package/dist/assets/{SettingsUsageAndPlan-hc6EFbHM.js → SettingsUsageAndPlan-Di_gUxTt.js} +1 -1
- package/dist/assets/{SettingsUsersView-CIzwxl6-.js → SettingsUsersView-BDNxV1rM.js} +2 -3
- package/dist/assets/{SettingsView-Bv-AL-MH.js → SettingsView-CAaXgrDd.js} +1 -1
- package/dist/assets/{SetupView-BCKg0AbF.js → SetupView-DIO89PJN.js} +3 -3
- package/dist/assets/{SetupWorkflowCredentialsButton-djsoNbvZ.js → SetupWorkflowCredentialsButton-y92onTNS.js} +1 -1
- package/dist/assets/{SetupWorkflowFromTemplateView-CZhYUSco.js → SetupWorkflowFromTemplateView-Hnqry6sO.js} +3 -3
- package/dist/assets/{SigninView-BPl0jjB0.js → SigninView-t0q2CjNU.js} +3 -3
- package/dist/assets/{SignoutView-BHPz3HFX.js → SignoutView-DjCS-jDi.js} +1 -1
- package/dist/assets/{SignupView-Cel8_b46.js → SignupView-BoEH4AVN.js} +3 -3
- package/dist/assets/{TableBase-BIT7ArUw.js → TableBase-D-1VfIgb.js} +1 -1
- package/dist/assets/{Tags-CQIEP_IZ.js → Tags-CnT3a0bf.js} +1 -1
- package/dist/assets/{TemplateDetails-B8u34j2l.js → TemplateDetails-B-tHb3Wq.js} +4 -4
- package/dist/assets/{TemplateList-BJSJYiHs.js → TemplateList-j7v4XLCo.js} +3 -3
- package/dist/assets/{TemplatesCollectionView-BCAAV1n9.js → TemplatesCollectionView-BPxSoEA5.js} +6 -6
- package/dist/assets/{TemplatesSearchView-CXOrNnyk.js → TemplatesSearchView-kZfygKcP.js} +3 -3
- package/dist/assets/{TemplatesView-1HunP4nN.js → TemplatesView-KQ5r6RZF.js} +2 -2
- package/dist/assets/{TemplatesWorkflowView-0enp4pR7.js → TemplatesWorkflowView-Pdm_DUrH.js} +6 -6
- package/dist/assets/{TriggerPanel-B-Jt4r3F.js → TriggerPanel-WYRtg2P1.js} +39 -29
- package/dist/assets/{TriggerPanel-DJv04feX.css → TriggerPanel-gMtmEr6n.css} +16 -13
- package/dist/assets/{VariablesView-mSWZzDyf.js → VariablesView-CdihBrCp.js} +5 -5
- package/dist/assets/{VueMarkdown-Dxf59_T_.js → VueMarkdown-CLlUve9b.js} +1 -1
- package/dist/assets/{WorkerView-DbqNyqok.js → WorkerView-C_q2Cgtl.js} +6 -6
- package/dist/assets/{WorkflowActivator-C33REd8m.js → WorkflowActivator-CDlyaU2W.js} +2 -2
- package/dist/assets/{WorkflowExecutionsInfoAccordion-CCe9jbiT.js → WorkflowExecutionsInfoAccordion-1aoYaoWj.js} +2 -2
- package/dist/assets/{WorkflowExecutionsLandingPage-DMXVsIHS.js → WorkflowExecutionsLandingPage-Cuz4EdsV.js} +3 -3
- package/dist/assets/{WorkflowExecutionsPreview-Dit3_l9q.js → WorkflowExecutionsPreview-BmDk9pdW.js} +7 -6
- package/dist/assets/{WorkflowExecutionsView-BwLTPvQ7.js → WorkflowExecutionsView-ClPpGdce.js} +6 -8
- package/dist/assets/{WorkflowHistory-BgNzJgze.js → WorkflowHistory-EoRsFrnu.js} +2 -3
- package/dist/assets/{WorkflowOnboardingView-Bnvmd6lJ.js → WorkflowOnboardingView-B4DUomvQ.js} +1 -1
- package/dist/assets/{WorkflowPreview-DIDMhnNP.js → WorkflowPreview-dQweS-xu.js} +1 -1
- package/dist/assets/{WorkflowsView-DxtULRby.js → WorkflowsView-DQJRBDtq.js} +275 -30
- package/dist/assets/{WorkflowsView-CyJbJBc8.css → WorkflowsView-DsJIOJ7h.css} +263 -0
- package/dist/assets/{aiTemplatesStarterCollection.store-DrHWcqtc.js → aiTemplatesStarterCollection.store-CTW_MDA8.js} +1 -1
- package/dist/assets/canvas-CMXo2Bja.js +5 -0
- package/dist/assets/{chartjs.utils-DQHNgzzp.js → chartjs.utils-CHvsojzm.js} +2 -2
- package/dist/assets/{en-BX7CKkqE.js → en-D7cJPQEa.js} +22 -2
- package/dist/assets/{global-link-actions-DzXrk-LO.js → global-link-actions-BxO50hoE.js} +1 -1
- package/dist/assets/{index-BWpYwmXd.css → index-BwGKZdwg.css} +15180 -4281
- package/dist/assets/{index-BmZCxv8-.js → index-DycvFkIw.js} +62280 -30323
- package/dist/assets/{index-x7t8iCsI.js → index-T1FYm0tg.js} +1 -1
- package/dist/assets/{pickBy-oHD63WOf.js → pickBy-DMiUcEKW.js} +1 -1
- package/dist/assets/{polyfills-B8p9DdqU.js → polyfills-eMEFRc79.js} +0 -32
- package/dist/assets/{templateActions-_QLqrCsm.js → templateActions-DrHAzjmQ.js} +1 -1
- package/dist/assets/{useBeforeUnload-CBmJdmlS.js → useBeforeUnload-uDmDsya_.js} +1 -1
- package/dist/assets/{useExecutionDebugging-B22Oj62X.js → useExecutionDebugging-wqUkD23F.js} +1 -1
- package/dist/assets/{useImportCurlCommand-CCUM_iVn.js → useImportCurlCommand-CBZG4Lbx.js} +1 -2
- package/dist/assets/{useProjectPages-CrI3xlbd.js → useProjectPages-CW2fEpJH.js} +1 -1
- package/dist/assets/{usePushConnection-EYkv1Xyg.js → usePushConnection-BM5QyJob.js} +3 -3
- package/dist/assets/{useWorkflowActivate-BiorS_mB.js → useWorkflowActivate-Dw_VspVF.js} +1 -1
- package/dist/index.html +5 -5
- package/dist/static/posthog.init.js +41 -0
- package/dist/static/prefers-color-scheme.css +5 -0
- package/index.html +2 -2
- package/package.json +1 -1
- package/tsconfig.json +1 -0
- package/dist/assets/ActionDropdown-BmC0wfMx.css +0 -172
- package/dist/assets/ActionDropdown-DkHCqhLi.js +0 -172
- package/dist/assets/CollectionParameter-C3JIvBsy.js +0 -4
- package/dist/assets/FileSaver.min-CiFUM_59.js +0 -81
- package/dist/assets/NodeView-Dm74W6kN.js +0 -18815
- package/dist/assets/NodeView-G2qfXaOy.css +0 -7402
- package/dist/assets/import-curl-BrVSOGQW.js +0 -5
- package/dist/assets/useExecutionHelpers-C6meisqx.js +0 -94
- package/dist/assets/useKeybindings-2A271Jke.css +0 -2007
- package/dist/assets/useKeybindings-CcHEvN6i.js +0 -3627
|
@@ -1,3627 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/RunDataTable-DJu8Ut0r.js","assets/index-BmZCxv8-.js","assets/index-BWpYwmXd.css","assets/useExecutionHelpers-C6meisqx.js","assets/RunDataTable-n918b-Qv.css","assets/RunDataJson-12Py20Rs.js","assets/FileSaver.min-CiFUM_59.js","assets/RunDataJson-BH9HLoGC.css","assets/RunDataParsedAiContent-DYz5OPxJ.js","assets/VueMarkdown-Dxf59_T_.js","assets/RunDataParsedAiContent-wfIiKsq7.css","assets/RunDataSearch-NmwtxOjZ.js","assets/RunDataSearch-2eEalFoi.css"])))=>i.map(i=>d[i]);
|
|
2
|
-
import { d as defineComponent, e as createBlock, g as openBlock, dK as Transition, w as withCtx, aT as withDirectives, aU as vShow, j as createBaseVNode, n as normalizeClass, _ as _export_sfc, f4 as hasKey, f5 as requireVue, bK as getDefaultExportFromCjs, f6 as sanitizeHtml, f7 as sanitizeHtmlExports, h as createElementBlock, r as ref, a5 as useWorkflowsStore, x as computed, o as onMounted, eQ as jsonParse, f8 as base64DecodeUTF8, k as createTextVNode, t as toDisplayString, l as unref, c as useI18n, bC as useNodeHelpers, f as createCommentVNode, i as createVNode, q as N8nButton, bP as withModifiers, b as useRouter, c2 as useClipboard, a as useToast, f9 as useAIAssistantHelpers, bH as useNodeTypesStore, aN as useNDVStore, ad as useRootStore, fa as useAssistantStore, T as useUIStore, fb as MAX_DISPLAY_DATA_SIZE, dd as isCommunityPackageName, c4 as resolveDirective, fc as InlineAskAssistantButton, $ as N8nTooltip, a0 as _sfc_main$b, N as N8nIcon, F as Fragment, y as renderList, V as VIEWS, fd as NEW_ASSISTANT_SESSION_MODAL, ea as sanitizeHtml$1, p as N8nText, a2 as N8nLink, ab as watch, H as N8nRadioButtons, bg as createSlots, O as resolveComponent, cW as N8nSelect, cX as _sfc_main$c, af as useSourceControlStore, fe as useSchemaPreviewStore, c_ as usePostHog, a6 as useRoute, bT as toRef, bA as usePinnedData, ff as useNodeType, fg as storeToRefs, fh as TRIMMED_TASK_DATA_CONNECTIONS_KEY, bp as NodeConnectionTypes, fi as executionDataToJson, fj as NODE_TYPES_EXCLUDED_FROM_OUTPUT_NAME_APPEND, fk as CORE_NODES_CATEGORY, d5 as NDV_UI_OVERHAUL_EXPERIMENT, fl as computedAsync, fm as parseAiContent, cm as ndvEventBus, az as useTelemetry, I as onBeforeUnmount, b5 as useStorage, fn as LOCAL_STORAGE_PIN_DATA_DISCOVERY_NDV_FLAG, fo as dataPinningEventBus, fp as LOCAL_STORAGE_PIN_DATA_DISCOVERY_CANVAS_FLAG, fq as searchInObject, fr as getConnectionTypes, fs as RUN_DATA_DEFAULT_PAGE_SIZE, ft as isObject, fu as MAX_DISPLAY_DATA_SIZE_SCHEMA_VIEW, fv as HTML_NODE_TYPE, J as renderSlot, dw as N8nCallout, fw as DATA_PINNING_DOCS_URL, e4 as Suspense, eW as defineAsyncComponent, bW as normalizeProps, D as mergeProps, dh as N8nTabs, bX as guardReactiveProps, fx as _sfc_main$d, ez as __unplugin_components_9, er as InfoTip, fy as DATA_EDITING_DOCS_URL, a1 as I18nT, aJ as __vitePreload, d3 as getNodeOutputs, fz as getGenericHints, fA as clearJsonKey, fB as TEST_PIN_DATA, be as useExternalHooks, cy as isPresent, fC as isEmpty, d$ as isEqual, Q as createEventBus, a3 as defineStore, v as useSettingsStore, cd as shallowRef, co as useVueFlow, dM as calculateNodeSize, bU as inject, c3 as PiPWindowSymbol, cl as useActiveElement, e0 as useDeviceSupport, dc as toValue, fD as useEventListener } from "./index-BmZCxv8-.js";
|
|
3
|
-
import { F as FileSaver_minExports } from "./FileSaver.min-CiFUM_59.js";
|
|
4
|
-
import { u as useExecutionHelpers } from "./useExecutionHelpers-C6meisqx.js";
|
|
5
|
-
const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
6
|
-
__name: "BlockUi",
|
|
7
|
-
props: {
|
|
8
|
-
show: { type: Boolean, default: false }
|
|
9
|
-
},
|
|
10
|
-
setup(__props) {
|
|
11
|
-
return (_ctx, _cache) => {
|
|
12
|
-
return openBlock(), createBlock(Transition, {
|
|
13
|
-
name: "fade",
|
|
14
|
-
mode: "out-in"
|
|
15
|
-
}, {
|
|
16
|
-
default: withCtx(() => [
|
|
17
|
-
withDirectives(createBaseVNode("div", {
|
|
18
|
-
class: normalizeClass(["n8n-block-ui", _ctx.$style.uiBlocker]),
|
|
19
|
-
role: "dialog",
|
|
20
|
-
"aria-hidden": true
|
|
21
|
-
}, null, 2), [
|
|
22
|
-
[vShow, _ctx.show]
|
|
23
|
-
])
|
|
24
|
-
]),
|
|
25
|
-
_: 1
|
|
26
|
-
});
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
const uiBlocker$1 = "_uiBlocker_j0zl4_123";
|
|
31
|
-
const style0$5 = {
|
|
32
|
-
uiBlocker: uiBlocker$1
|
|
33
|
-
};
|
|
34
|
-
const cssModules$5 = {
|
|
35
|
-
"$style": style0$5
|
|
36
|
-
};
|
|
37
|
-
const N8nBlockUi = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__cssModules", cssModules$5], ["__scopeId", "data-v-76a59b58"]]);
|
|
38
|
-
function responseHasSubworkflowData(response) {
|
|
39
|
-
return ["executionId", "workflowId"].every((x) => hasKey(response, x) && typeof response[x] === "string");
|
|
40
|
-
}
|
|
41
|
-
function parseErrorResponseWorkflowMetadata(response) {
|
|
42
|
-
if (!responseHasSubworkflowData(response))
|
|
43
|
-
return void 0;
|
|
44
|
-
return {
|
|
45
|
-
subExecution: {
|
|
46
|
-
executionId: response.executionId,
|
|
47
|
-
workflowId: response.workflowId
|
|
48
|
-
},
|
|
49
|
-
subExecutionsCount: 1
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
function parseErrorMetadata(error) {
|
|
53
|
-
if (hasKey(error, "errorResponse")) {
|
|
54
|
-
return parseErrorResponseWorkflowMetadata(error.errorResponse);
|
|
55
|
-
}
|
|
56
|
-
return parseErrorResponseWorkflowMetadata(error);
|
|
57
|
-
}
|
|
58
|
-
const ViewableMimeTypes = [
|
|
59
|
-
"application/json",
|
|
60
|
-
"audio/mpeg",
|
|
61
|
-
"audio/ogg",
|
|
62
|
-
"audio/wav",
|
|
63
|
-
"image/bmp",
|
|
64
|
-
"image/gif",
|
|
65
|
-
"image/jpeg",
|
|
66
|
-
"image/jpg",
|
|
67
|
-
"image/png",
|
|
68
|
-
"image/tiff",
|
|
69
|
-
"image/webp",
|
|
70
|
-
"text/css",
|
|
71
|
-
"text/csv",
|
|
72
|
-
"text/markdown",
|
|
73
|
-
"text/plain",
|
|
74
|
-
"video/mp4",
|
|
75
|
-
"video/ogg",
|
|
76
|
-
"video/webm"
|
|
77
|
-
];
|
|
78
|
-
var vueJsonPretty$1 = { exports: {} };
|
|
79
|
-
var vueJsonPretty = vueJsonPretty$1.exports;
|
|
80
|
-
var hasRequiredVueJsonPretty;
|
|
81
|
-
function requireVueJsonPretty() {
|
|
82
|
-
if (hasRequiredVueJsonPretty) return vueJsonPretty$1.exports;
|
|
83
|
-
hasRequiredVueJsonPretty = 1;
|
|
84
|
-
(function(module, exports) {
|
|
85
|
-
!function(e, t) {
|
|
86
|
-
module.exports = t(requireVue());
|
|
87
|
-
}(vueJsonPretty, function(e) {
|
|
88
|
-
return function() {
|
|
89
|
-
var t = { 789: function(t2) {
|
|
90
|
-
t2.exports = e;
|
|
91
|
-
} }, n = {};
|
|
92
|
-
function o(e2) {
|
|
93
|
-
var r2 = n[e2];
|
|
94
|
-
if (void 0 !== r2) return r2.exports;
|
|
95
|
-
var l = n[e2] = { exports: {} };
|
|
96
|
-
return t[e2](l, l.exports, o), l.exports;
|
|
97
|
-
}
|
|
98
|
-
o.d = function(e2, t2) {
|
|
99
|
-
for (var n2 in t2) o.o(t2, n2) && !o.o(e2, n2) && Object.defineProperty(e2, n2, { enumerable: true, get: t2[n2] });
|
|
100
|
-
}, o.o = function(e2, t2) {
|
|
101
|
-
return Object.prototype.hasOwnProperty.call(e2, t2);
|
|
102
|
-
}, o.r = function(e2) {
|
|
103
|
-
"undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e2, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(e2, "__esModule", { value: true });
|
|
104
|
-
};
|
|
105
|
-
var r = {};
|
|
106
|
-
return function() {
|
|
107
|
-
function e2(e3, t3) {
|
|
108
|
-
(null == t3 || t3 > e3.length) && (t3 = e3.length);
|
|
109
|
-
for (var n3 = 0, o2 = new Array(t3); n3 < t3; n3++) o2[n3] = e3[n3];
|
|
110
|
-
return o2;
|
|
111
|
-
}
|
|
112
|
-
function t2(t3, n3) {
|
|
113
|
-
if (t3) {
|
|
114
|
-
if ("string" == typeof t3) return e2(t3, n3);
|
|
115
|
-
var o2 = Object.prototype.toString.call(t3).slice(8, -1);
|
|
116
|
-
return "Object" === o2 && t3.constructor && (o2 = t3.constructor.name), "Map" === o2 || "Set" === o2 ? Array.from(t3) : "Arguments" === o2 || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o2) ? e2(t3, n3) : void 0;
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
function n2(n3) {
|
|
120
|
-
return function(t3) {
|
|
121
|
-
if (Array.isArray(t3)) return e2(t3);
|
|
122
|
-
}(n3) || function(e3) {
|
|
123
|
-
if ("undefined" != typeof Symbol && null != e3[Symbol.iterator] || null != e3["@@iterator"]) return Array.from(e3);
|
|
124
|
-
}(n3) || t2(n3) || function() {
|
|
125
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
126
|
-
}();
|
|
127
|
-
}
|
|
128
|
-
function l(e3, t3, n3) {
|
|
129
|
-
return t3 in e3 ? Object.defineProperty(e3, t3, { value: n3, enumerable: true, configurable: true, writable: true }) : e3[t3] = n3, e3;
|
|
130
|
-
}
|
|
131
|
-
o.r(r), o.d(r, { default: function() {
|
|
132
|
-
return k;
|
|
133
|
-
} });
|
|
134
|
-
var a = o(789), c = (0, a.defineComponent)({ props: { data: { required: true, type: String }, onClick: Function }, render: function() {
|
|
135
|
-
var e3 = this.data, t3 = this.onClick;
|
|
136
|
-
return (0, a.createVNode)("span", { class: "vjs-tree-brackets", onClick: t3 }, [e3]);
|
|
137
|
-
} }), i = (0, a.defineComponent)({ emits: ["change", "update:modelValue"], props: { checked: { type: Boolean, default: false }, isMultiple: Boolean, onChange: Function }, setup: function(e3, t3) {
|
|
138
|
-
var n3 = t3.emit;
|
|
139
|
-
return { uiType: (0, a.computed)(function() {
|
|
140
|
-
return e3.isMultiple ? "checkbox" : "radio";
|
|
141
|
-
}), model: (0, a.computed)({ get: function() {
|
|
142
|
-
return e3.checked;
|
|
143
|
-
}, set: function(e4) {
|
|
144
|
-
return n3("update:modelValue", e4);
|
|
145
|
-
} }) };
|
|
146
|
-
}, render: function() {
|
|
147
|
-
var e3 = this.uiType, t3 = this.model, n3 = this.$emit;
|
|
148
|
-
return (0, a.createVNode)("label", { class: ["vjs-check-controller", t3 ? "is-checked" : ""], onClick: function(e4) {
|
|
149
|
-
return e4.stopPropagation();
|
|
150
|
-
} }, [(0, a.createVNode)("span", { class: "vjs-check-controller-inner is-".concat(e3) }, null), (0, a.createVNode)("input", { checked: t3, class: "vjs-check-controller-original is-".concat(e3), type: e3, onChange: function() {
|
|
151
|
-
return n3("change", t3);
|
|
152
|
-
} }, null)]);
|
|
153
|
-
} }), u = (0, a.defineComponent)({ props: { nodeType: { required: true, type: String }, onClick: Function }, render: function() {
|
|
154
|
-
var e3 = this.nodeType, t3 = this.onClick, n3 = "objectStart" === e3 || "arrayStart" === e3;
|
|
155
|
-
return n3 || "objectCollapsed" === e3 || "arrayCollapsed" === e3 ? (0, a.createVNode)("span", { class: "vjs-carets vjs-carets-".concat(n3 ? "open" : "close"), onClick: t3 }, [(0, a.createVNode)("svg", { viewBox: "0 0 1024 1024", focusable: "false", "data-icon": "caret-down", width: "1em", height: "1em", fill: "currentColor", "aria-hidden": "true" }, [(0, a.createVNode)("path", { d: "M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z" }, null)])]) : null;
|
|
156
|
-
} });
|
|
157
|
-
function d(e3) {
|
|
158
|
-
return d = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e4) {
|
|
159
|
-
return typeof e4;
|
|
160
|
-
} : function(e4) {
|
|
161
|
-
return e4 && "function" == typeof Symbol && e4.constructor === Symbol && e4 !== Symbol.prototype ? "symbol" : typeof e4;
|
|
162
|
-
}, d(e3);
|
|
163
|
-
}
|
|
164
|
-
function s(e3) {
|
|
165
|
-
return Object.prototype.toString.call(e3).slice(8, -1).toLowerCase();
|
|
166
|
-
}
|
|
167
|
-
function p(e3) {
|
|
168
|
-
var t3 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "root", n3 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : 0, o2 = arguments.length > 3 ? arguments[3] : void 0, r2 = o2 || {}, l2 = r2.key, a2 = r2.index, c2 = r2.type, i2 = void 0 === c2 ? "content" : c2, u2 = r2.showComma, d2 = void 0 !== u2 && u2, f2 = r2.length, y2 = void 0 === f2 ? 1 : f2, v2 = s(e3);
|
|
169
|
-
if ("array" === v2) {
|
|
170
|
-
var b2 = h(e3.map(function(e4, o3, r3) {
|
|
171
|
-
return p(e4, "".concat(t3, "[").concat(o3, "]"), n3 + 1, { index: o3, showComma: o3 !== r3.length - 1, length: y2, type: i2 });
|
|
172
|
-
}));
|
|
173
|
-
return [p("[", t3, n3, { showComma: false, key: l2, length: e3.length, type: "arrayStart" })[0]].concat(b2, p("]", t3, n3, { showComma: d2, length: e3.length, type: "arrayEnd" })[0]);
|
|
174
|
-
}
|
|
175
|
-
if ("object" === v2) {
|
|
176
|
-
var g2 = Object.keys(e3), m2 = h(g2.map(function(o3, r3, l3) {
|
|
177
|
-
return p(e3[o3], /^[a-zA-Z_]\w*$/.test(o3) ? "".concat(t3, ".").concat(o3) : "".concat(t3, '["').concat(o3, '"]'), n3 + 1, { key: o3, showComma: r3 !== l3.length - 1, length: y2, type: i2 });
|
|
178
|
-
}));
|
|
179
|
-
return [p("{", t3, n3, { showComma: false, key: l2, index: a2, length: g2.length, type: "objectStart" })[0]].concat(m2, p("}", t3, n3, { showComma: d2, length: g2.length, type: "objectEnd" })[0]);
|
|
180
|
-
}
|
|
181
|
-
return [{ content: e3, level: n3, key: l2, index: a2, path: t3, showComma: d2, length: y2, type: i2 }];
|
|
182
|
-
}
|
|
183
|
-
function h(e3) {
|
|
184
|
-
if ("function" == typeof Array.prototype.flat) return e3.flat();
|
|
185
|
-
for (var t3 = n2(e3), o2 = []; t3.length; ) {
|
|
186
|
-
var r2 = t3.shift();
|
|
187
|
-
Array.isArray(r2) ? t3.unshift.apply(t3, n2(r2)) : o2.push(r2);
|
|
188
|
-
}
|
|
189
|
-
return o2;
|
|
190
|
-
}
|
|
191
|
-
function f(e3) {
|
|
192
|
-
var t3 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : /* @__PURE__ */ new WeakMap();
|
|
193
|
-
if (null == e3) return e3;
|
|
194
|
-
if (e3 instanceof Date) return new Date(e3);
|
|
195
|
-
if (e3 instanceof RegExp) return new RegExp(e3);
|
|
196
|
-
if ("object" !== d(e3)) return e3;
|
|
197
|
-
if (t3.get(e3)) return t3.get(e3);
|
|
198
|
-
if (Array.isArray(e3)) {
|
|
199
|
-
var n3 = e3.map(function(e4) {
|
|
200
|
-
return f(e4, t3);
|
|
201
|
-
});
|
|
202
|
-
return t3.set(e3, n3), n3;
|
|
203
|
-
}
|
|
204
|
-
var o2 = {};
|
|
205
|
-
for (var r2 in e3) o2[r2] = f(e3[r2], t3);
|
|
206
|
-
return t3.set(e3, o2), o2;
|
|
207
|
-
}
|
|
208
|
-
function y(e3, t3) {
|
|
209
|
-
var n3 = Object.keys(e3);
|
|
210
|
-
if (Object.getOwnPropertySymbols) {
|
|
211
|
-
var o2 = Object.getOwnPropertySymbols(e3);
|
|
212
|
-
t3 && (o2 = o2.filter(function(t4) {
|
|
213
|
-
return Object.getOwnPropertyDescriptor(e3, t4).enumerable;
|
|
214
|
-
})), n3.push.apply(n3, o2);
|
|
215
|
-
}
|
|
216
|
-
return n3;
|
|
217
|
-
}
|
|
218
|
-
function v(e3) {
|
|
219
|
-
for (var t3 = 1; t3 < arguments.length; t3++) {
|
|
220
|
-
var n3 = null != arguments[t3] ? arguments[t3] : {};
|
|
221
|
-
t3 % 2 ? y(Object(n3), true).forEach(function(t4) {
|
|
222
|
-
l(e3, t4, n3[t4]);
|
|
223
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e3, Object.getOwnPropertyDescriptors(n3)) : y(Object(n3)).forEach(function(t4) {
|
|
224
|
-
Object.defineProperty(e3, t4, Object.getOwnPropertyDescriptor(n3, t4));
|
|
225
|
-
});
|
|
226
|
-
}
|
|
227
|
-
return e3;
|
|
228
|
-
}
|
|
229
|
-
var b = { showLength: { type: Boolean, default: false }, showDoubleQuotes: { type: Boolean, default: true }, renderNodeKey: Function, renderNodeValue: Function, selectableType: String, showSelectController: { type: Boolean, default: false }, showLine: { type: Boolean, default: true }, showLineNumber: { type: Boolean, default: false }, selectOnClickNode: { type: Boolean, default: true }, nodeSelectable: { type: Function, default: function() {
|
|
230
|
-
return true;
|
|
231
|
-
} }, highlightSelectedNode: { type: Boolean, default: true }, showIcon: { type: Boolean, default: false }, showKeyValueSpace: { type: Boolean, default: true }, editable: { type: Boolean, default: false }, editableTrigger: { type: String, default: "click" }, onNodeClick: { type: Function }, onBracketsClick: { type: Function }, onIconClick: { type: Function }, onValueChange: { type: Function } }, g = (0, a.defineComponent)({ name: "TreeNode", props: v(v({}, b), {}, { node: { type: Object, required: true }, collapsed: Boolean, checked: Boolean, style: Object, onSelectedChange: { type: Function } }), emits: ["nodeClick", "bracketsClick", "iconClick", "selectedChange", "valueChange"], setup: function(e3, t3) {
|
|
232
|
-
var n3 = t3.emit, o2 = (0, a.computed)(function() {
|
|
233
|
-
return s(e3.node.content);
|
|
234
|
-
}), r2 = (0, a.computed)(function() {
|
|
235
|
-
return "vjs-value vjs-value-".concat(o2.value);
|
|
236
|
-
}), l2 = (0, a.computed)(function() {
|
|
237
|
-
return e3.showDoubleQuotes ? '"'.concat(e3.node.key, '"') : e3.node.key;
|
|
238
|
-
}), d2 = (0, a.computed)(function() {
|
|
239
|
-
return "multiple" === e3.selectableType;
|
|
240
|
-
}), p2 = (0, a.computed)(function() {
|
|
241
|
-
return "single" === e3.selectableType;
|
|
242
|
-
}), h2 = (0, a.computed)(function() {
|
|
243
|
-
return e3.nodeSelectable(e3.node) && (d2.value || p2.value);
|
|
244
|
-
}), f2 = (0, a.reactive)({ editing: false }), y2 = function(t4) {
|
|
245
|
-
var o3, r3, l3 = "null" === (r3 = null === (o3 = t4.target) || void 0 === o3 ? void 0 : o3.value) ? null : "undefined" === r3 ? void 0 : "true" === r3 || "false" !== r3 && (r3[0] + r3[r3.length - 1] === '""' || r3[0] + r3[r3.length - 1] === "''" ? r3.slice(1, -1) : "number" == typeof Number(r3) && !isNaN(Number(r3)) || "NaN" === r3 ? Number(r3) : r3);
|
|
246
|
-
n3("valueChange", l3, e3.node.path);
|
|
247
|
-
}, v2 = (0, a.computed)(function() {
|
|
248
|
-
var t4, n4 = null === (t4 = e3.node) || void 0 === t4 ? void 0 : t4.content;
|
|
249
|
-
return null === n4 ? n4 = "null" : void 0 === n4 && (n4 = "undefined"), "string" === o2.value ? '"'.concat(n4, '"') : n4 + "";
|
|
250
|
-
}), b2 = function() {
|
|
251
|
-
var t4 = e3.renderNodeValue;
|
|
252
|
-
return t4 ? t4({ node: e3.node, defaultValue: v2.value }) : v2.value;
|
|
253
|
-
}, g2 = function() {
|
|
254
|
-
n3("bracketsClick", !e3.collapsed, e3.node.path);
|
|
255
|
-
}, m2 = function() {
|
|
256
|
-
n3("iconClick", !e3.collapsed, e3.node.path);
|
|
257
|
-
}, C2 = function() {
|
|
258
|
-
n3("selectedChange", e3.node);
|
|
259
|
-
}, k2 = function() {
|
|
260
|
-
n3("nodeClick", e3.node), h2.value && e3.selectOnClickNode && n3("selectedChange", e3.node);
|
|
261
|
-
}, w = function(t4) {
|
|
262
|
-
if (e3.editable && !f2.editing) {
|
|
263
|
-
f2.editing = true;
|
|
264
|
-
var n4 = function e4(n5) {
|
|
265
|
-
var o3;
|
|
266
|
-
n5.target !== t4.target && (null === (o3 = n5.target) || void 0 === o3 ? void 0 : o3.parentElement) !== t4.target && (f2.editing = false, document.removeEventListener("click", e4));
|
|
267
|
-
};
|
|
268
|
-
document.removeEventListener("click", n4), document.addEventListener("click", n4);
|
|
269
|
-
}
|
|
270
|
-
};
|
|
271
|
-
return function() {
|
|
272
|
-
var t4, n4 = e3.node;
|
|
273
|
-
return (0, a.createVNode)("div", { class: { "vjs-tree-node": true, "has-selector": e3.showSelectController, "has-carets": e3.showIcon, "is-highlight": e3.highlightSelectedNode && e3.checked }, onClick: k2, style: e3.style }, [e3.showLineNumber && (0, a.createVNode)("span", { class: "vjs-node-index" }, [n4.id + 1]), e3.showSelectController && h2.value && "objectEnd" !== n4.type && "arrayEnd" !== n4.type && (0, a.createVNode)(i, { isMultiple: d2.value, checked: e3.checked, onChange: C2 }, null), (0, a.createVNode)("div", { class: "vjs-indent" }, [Array.from(Array(n4.level)).map(function(t5, n5) {
|
|
274
|
-
return (0, a.createVNode)("div", { key: n5, class: { "vjs-indent-unit": true, "has-line": e3.showLine } }, null);
|
|
275
|
-
}), e3.showIcon && (0, a.createVNode)(u, { nodeType: n4.type, onClick: m2 }, null)]), n4.key && (0, a.createVNode)("span", { class: "vjs-key" }, [(t4 = e3.renderNodeKey, t4 ? t4({ node: e3.node, defaultKey: l2.value || "" }) : l2.value), (0, a.createVNode)("span", { class: "vjs-colon" }, [":".concat(e3.showKeyValueSpace ? " " : "")])]), (0, a.createVNode)("span", null, ["content" !== n4.type && n4.content ? (0, a.createVNode)(c, { data: n4.content.toString(), onClick: g2 }, null) : (0, a.createVNode)("span", { class: r2.value, onClick: !e3.editable || e3.editableTrigger && "click" !== e3.editableTrigger ? void 0 : w, onDblclick: e3.editable && "dblclick" === e3.editableTrigger ? w : void 0 }, [e3.editable && f2.editing ? (0, a.createVNode)("input", { value: v2.value, onChange: y2, style: { padding: "3px 8px", border: "1px solid #eee", boxShadow: "none", boxSizing: "border-box", borderRadius: 5, fontFamily: "inherit" } }, null) : b2()]), n4.showComma && (0, a.createVNode)("span", null, [","]), e3.showLength && e3.collapsed && (0, a.createVNode)("span", { class: "vjs-comment" }, [(0, a.createTextVNode)(" // "), n4.length, (0, a.createTextVNode)(" items ")])])]);
|
|
276
|
-
};
|
|
277
|
-
} });
|
|
278
|
-
function m(e3, t3) {
|
|
279
|
-
var n3 = Object.keys(e3);
|
|
280
|
-
if (Object.getOwnPropertySymbols) {
|
|
281
|
-
var o2 = Object.getOwnPropertySymbols(e3);
|
|
282
|
-
t3 && (o2 = o2.filter(function(t4) {
|
|
283
|
-
return Object.getOwnPropertyDescriptor(e3, t4).enumerable;
|
|
284
|
-
})), n3.push.apply(n3, o2);
|
|
285
|
-
}
|
|
286
|
-
return n3;
|
|
287
|
-
}
|
|
288
|
-
function C(e3) {
|
|
289
|
-
for (var t3 = 1; t3 < arguments.length; t3++) {
|
|
290
|
-
var n3 = null != arguments[t3] ? arguments[t3] : {};
|
|
291
|
-
t3 % 2 ? m(Object(n3), true).forEach(function(t4) {
|
|
292
|
-
l(e3, t4, n3[t4]);
|
|
293
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e3, Object.getOwnPropertyDescriptors(n3)) : m(Object(n3)).forEach(function(t4) {
|
|
294
|
-
Object.defineProperty(e3, t4, Object.getOwnPropertyDescriptor(n3, t4));
|
|
295
|
-
});
|
|
296
|
-
}
|
|
297
|
-
return e3;
|
|
298
|
-
}
|
|
299
|
-
var k = (0, a.defineComponent)({ name: "Tree", props: C(C({}, b), {}, { data: { type: [String, Number, Boolean, Array, Object], default: null }, deep: { type: Number, default: 1 / 0 }, pathCollapsible: { type: Function, default: function() {
|
|
300
|
-
return false;
|
|
301
|
-
} }, rootPath: { type: String, default: "root" }, virtual: { type: Boolean, default: false }, height: { type: Number, default: 400 }, itemHeight: { type: Number, default: 20 }, selectedValue: { type: [String, Array], default: function() {
|
|
302
|
-
return "";
|
|
303
|
-
} }, collapsedOnClickBrackets: { type: Boolean, default: true }, style: Object, onSelectedChange: { type: Function } }), slots: ["renderNodeKey", "renderNodeValue"], emits: ["nodeClick", "bracketsClick", "iconClick", "selectedChange", "update:selectedValue", "update:data"], setup: function(e3, o2) {
|
|
304
|
-
var r2 = o2.emit, c2 = o2.slots, i2 = (0, a.ref)(), u2 = (0, a.computed)(function() {
|
|
305
|
-
return p(e3.data, e3.rootPath);
|
|
306
|
-
}), d2 = function(t3) {
|
|
307
|
-
return u2.value.reduce(function(n3, o3) {
|
|
308
|
-
var r3, a2 = o3.level >= t3, c3 = null === (r3 = e3.pathCollapsible) || void 0 === r3 ? void 0 : r3.call(e3, o3);
|
|
309
|
-
return "objectStart" !== o3.type && "arrayStart" !== o3.type || !a2 && !c3 ? n3 : C(C({}, n3), {}, l({}, o3.path, 1));
|
|
310
|
-
}, {});
|
|
311
|
-
}, s2 = (0, a.reactive)({ translateY: 0, visibleData: null, hiddenPaths: d2(e3.deep) }), h2 = (0, a.computed)(function() {
|
|
312
|
-
for (var e4 = null, t3 = [], n3 = u2.value.length, o3 = 0; o3 < n3; o3++) {
|
|
313
|
-
var r3 = C(C({}, u2.value[o3]), {}, { id: o3 }), l2 = s2.hiddenPaths[r3.path];
|
|
314
|
-
if (e4 && e4.path === r3.path) {
|
|
315
|
-
var a2 = "objectStart" === e4.type, c3 = C(C(C({}, r3), e4), {}, { showComma: r3.showComma, content: a2 ? "{...}" : "[...]", type: a2 ? "objectCollapsed" : "arrayCollapsed" });
|
|
316
|
-
e4 = null, t3.push(c3);
|
|
317
|
-
} else {
|
|
318
|
-
if (l2 && !e4) {
|
|
319
|
-
e4 = r3;
|
|
320
|
-
continue;
|
|
321
|
-
}
|
|
322
|
-
if (e4) continue;
|
|
323
|
-
t3.push(r3);
|
|
324
|
-
}
|
|
325
|
-
}
|
|
326
|
-
return t3;
|
|
327
|
-
}), y2 = (0, a.computed)(function() {
|
|
328
|
-
var t3 = e3.selectedValue;
|
|
329
|
-
return t3 && "multiple" === e3.selectableType && Array.isArray(t3) ? t3 : [t3];
|
|
330
|
-
}), v2 = (0, a.computed)(function() {
|
|
331
|
-
return !e3.selectableType || e3.selectOnClickNode || e3.showSelectController ? "" : "When selectableType is not null, selectOnClickNode and showSelectController cannot be false at the same time, because this will cause the selection to fail.";
|
|
332
|
-
}), b2 = function() {
|
|
333
|
-
var t3 = h2.value;
|
|
334
|
-
if (e3.virtual) {
|
|
335
|
-
var n3, o3 = e3.height / e3.itemHeight, r3 = (null === (n3 = i2.value) || void 0 === n3 ? void 0 : n3.scrollTop) || 0, l2 = Math.floor(r3 / e3.itemHeight), a2 = l2 < 0 ? 0 : l2 + o3 > t3.length ? t3.length - o3 : l2;
|
|
336
|
-
a2 < 0 && (a2 = 0);
|
|
337
|
-
var c3 = a2 + o3;
|
|
338
|
-
s2.translateY = a2 * e3.itemHeight, s2.visibleData = t3.filter(function(e4, t4) {
|
|
339
|
-
return t4 >= a2 && t4 < c3;
|
|
340
|
-
});
|
|
341
|
-
} else s2.visibleData = t3;
|
|
342
|
-
}, m2 = function() {
|
|
343
|
-
b2();
|
|
344
|
-
}, k2 = function(o3) {
|
|
345
|
-
var l2, a2, c3 = o3.path, i3 = e3.selectableType;
|
|
346
|
-
if ("multiple" === i3) {
|
|
347
|
-
var u3 = y2.value.findIndex(function(e4) {
|
|
348
|
-
return e4 === c3;
|
|
349
|
-
}), d3 = n2(y2.value);
|
|
350
|
-
-1 !== u3 ? d3.splice(u3, 1) : d3.push(c3), r2("update:selectedValue", d3), r2("selectedChange", d3, n2(y2.value));
|
|
351
|
-
} else if ("single" === i3 && y2.value[0] !== c3) {
|
|
352
|
-
var s3 = (l2 = y2.value, a2 = 1, function(e4) {
|
|
353
|
-
if (Array.isArray(e4)) return e4;
|
|
354
|
-
}(l2) || function(e4, t3) {
|
|
355
|
-
var n3 = null == e4 ? null : "undefined" != typeof Symbol && e4[Symbol.iterator] || e4["@@iterator"];
|
|
356
|
-
if (null != n3) {
|
|
357
|
-
var o4, r3, l3 = [], a3 = true, c4 = false;
|
|
358
|
-
try {
|
|
359
|
-
for (n3 = n3.call(e4); !(a3 = (o4 = n3.next()).done) && (l3.push(o4.value), !t3 || l3.length !== t3); a3 = true) ;
|
|
360
|
-
} catch (e5) {
|
|
361
|
-
c4 = true, r3 = e5;
|
|
362
|
-
} finally {
|
|
363
|
-
try {
|
|
364
|
-
a3 || null == n3.return || n3.return();
|
|
365
|
-
} finally {
|
|
366
|
-
if (c4) throw r3;
|
|
367
|
-
}
|
|
368
|
-
}
|
|
369
|
-
return l3;
|
|
370
|
-
}
|
|
371
|
-
}(l2, a2) || t2(l2, a2) || function() {
|
|
372
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
373
|
-
}())[0], p2 = c3;
|
|
374
|
-
r2("update:selectedValue", p2), r2("selectedChange", p2, s3);
|
|
375
|
-
}
|
|
376
|
-
}, w = function(e4) {
|
|
377
|
-
r2("nodeClick", e4);
|
|
378
|
-
}, N = function(e4, t3) {
|
|
379
|
-
if (e4) s2.hiddenPaths = C(C({}, s2.hiddenPaths), {}, l({}, t3, 1));
|
|
380
|
-
else {
|
|
381
|
-
var n3 = C({}, s2.hiddenPaths);
|
|
382
|
-
delete n3[t3], s2.hiddenPaths = n3;
|
|
383
|
-
}
|
|
384
|
-
}, j = function(t3, n3) {
|
|
385
|
-
e3.collapsedOnClickBrackets && N(t3, n3), r2("bracketsClick", t3);
|
|
386
|
-
}, S = function(e4, t3) {
|
|
387
|
-
N(e4, t3), r2("iconClick", e4);
|
|
388
|
-
}, O = function(t3, n3) {
|
|
389
|
-
var o3 = f(e3.data), l2 = e3.rootPath;
|
|
390
|
-
new Function("data", "val", "data".concat(n3.slice(l2.length), "=val"))(o3, t3), r2("update:data", o3);
|
|
391
|
-
};
|
|
392
|
-
return (0, a.watchEffect)(function() {
|
|
393
|
-
v2.value && function(e4) {
|
|
394
|
-
throw new Error("[VueJSONPretty] ".concat(e4));
|
|
395
|
-
}(v2.value);
|
|
396
|
-
}), (0, a.watchEffect)(function() {
|
|
397
|
-
h2.value && b2();
|
|
398
|
-
}), (0, a.watch)(function() {
|
|
399
|
-
return e3.deep;
|
|
400
|
-
}, function(e4) {
|
|
401
|
-
e4 && (s2.hiddenPaths = d2(e4));
|
|
402
|
-
}), function() {
|
|
403
|
-
var t3, n3, o3 = null !== (t3 = e3.renderNodeKey) && void 0 !== t3 ? t3 : c2.renderNodeKey, r3 = null !== (n3 = e3.renderNodeValue) && void 0 !== n3 ? n3 : c2.renderNodeValue, l2 = s2.visibleData && s2.visibleData.map(function(t4) {
|
|
404
|
-
return (0, a.createVNode)(g, { key: t4.id, node: t4, collapsed: !!s2.hiddenPaths[t4.path], showDoubleQuotes: e3.showDoubleQuotes, showLength: e3.showLength, checked: y2.value.includes(t4.path), selectableType: e3.selectableType, showLine: e3.showLine, showLineNumber: e3.showLineNumber, showSelectController: e3.showSelectController, selectOnClickNode: e3.selectOnClickNode, nodeSelectable: e3.nodeSelectable, highlightSelectedNode: e3.highlightSelectedNode, editable: e3.editable, editableTrigger: e3.editableTrigger, showIcon: e3.showIcon, showKeyValueSpace: e3.showKeyValueSpace, renderNodeKey: o3, renderNodeValue: r3, onNodeClick: w, onBracketsClick: j, onIconClick: S, onSelectedChange: k2, onValueChange: O, style: e3.itemHeight && 20 !== e3.itemHeight ? { lineHeight: "".concat(e3.itemHeight, "px") } : {} }, null);
|
|
405
|
-
});
|
|
406
|
-
return (0, a.createVNode)("div", { ref: i2, class: { "vjs-tree": true, "is-virtual": e3.virtual }, onScroll: e3.virtual ? m2 : void 0, style: e3.showLineNumber ? C({ paddingLeft: "".concat(12 * Number(u2.value.length.toString().length), "px") }, e3.style) : e3.style }, [e3.virtual ? (0, a.createVNode)("div", { class: "vjs-tree-list", style: { height: "".concat(e3.height, "px") } }, [(0, a.createVNode)("div", { class: "vjs-tree-list-holder", style: { height: "".concat(h2.value.length * e3.itemHeight, "px") } }, [(0, a.createVNode)("div", { class: "vjs-tree-list-holder-inner", style: { transform: "translateY(".concat(s2.translateY, "px)") } }, [l2])])]) : l2]);
|
|
407
|
-
};
|
|
408
|
-
} });
|
|
409
|
-
}(), r;
|
|
410
|
-
}();
|
|
411
|
-
});
|
|
412
|
-
})(vueJsonPretty$1);
|
|
413
|
-
return vueJsonPretty$1.exports;
|
|
414
|
-
}
|
|
415
|
-
var vueJsonPrettyExports = requireVueJsonPretty();
|
|
416
|
-
const VueJsonPretty = /* @__PURE__ */ getDefaultExportFromCjs(vueJsonPrettyExports);
|
|
417
|
-
const sanitizeOptions = {
|
|
418
|
-
allowVulnerableTags: false,
|
|
419
|
-
enforceHtmlBoundary: false,
|
|
420
|
-
disallowedTagsMode: "discard",
|
|
421
|
-
allowedTags: [...sanitizeHtmlExports.defaults.allowedTags, "style", "img", "title"],
|
|
422
|
-
allowedAttributes: {
|
|
423
|
-
...sanitizeHtmlExports.defaults.allowedAttributes,
|
|
424
|
-
"*": ["class", "style"]
|
|
425
|
-
},
|
|
426
|
-
transformTags: {
|
|
427
|
-
head: ""
|
|
428
|
-
}
|
|
429
|
-
};
|
|
430
|
-
const _sfc_main$9 = {
|
|
431
|
-
name: "RunDataHtml",
|
|
432
|
-
props: {
|
|
433
|
-
inputHtml: {
|
|
434
|
-
type: String,
|
|
435
|
-
required: true
|
|
436
|
-
}
|
|
437
|
-
},
|
|
438
|
-
computed: {
|
|
439
|
-
sanitizedHtml() {
|
|
440
|
-
return sanitizeHtml(this.inputHtml, sanitizeOptions);
|
|
441
|
-
}
|
|
442
|
-
}
|
|
443
|
-
};
|
|
444
|
-
const _hoisted_1$8 = ["srcdoc"];
|
|
445
|
-
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
446
|
-
return openBlock(), createElementBlock("iframe", {
|
|
447
|
-
class: "__html-display",
|
|
448
|
-
srcdoc: $options.sanitizedHtml
|
|
449
|
-
}, null, 8, _hoisted_1$8);
|
|
450
|
-
}
|
|
451
|
-
const RunDataHtml = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render]]);
|
|
452
|
-
const RunDataHtml$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
453
|
-
__proto__: null,
|
|
454
|
-
default: RunDataHtml
|
|
455
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
|
456
|
-
const _hoisted_1$7 = { key: 0 };
|
|
457
|
-
const _hoisted_2$4 = { key: 1 };
|
|
458
|
-
const _hoisted_3$3 = { key: 2 };
|
|
459
|
-
const _hoisted_4$3 = {
|
|
460
|
-
key: 0,
|
|
461
|
-
controls: "",
|
|
462
|
-
autoplay: ""
|
|
463
|
-
};
|
|
464
|
-
const _hoisted_5$3 = ["src", "type"];
|
|
465
|
-
const _hoisted_6$2 = {
|
|
466
|
-
key: 1,
|
|
467
|
-
controls: "",
|
|
468
|
-
autoplay: ""
|
|
469
|
-
};
|
|
470
|
-
const _hoisted_7$2 = ["src", "type"];
|
|
471
|
-
const _hoisted_8$2 = ["src"];
|
|
472
|
-
const _hoisted_9$2 = ["src"];
|
|
473
|
-
const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
474
|
-
__name: "BinaryDataDisplayEmbed",
|
|
475
|
-
props: {
|
|
476
|
-
binaryData: {}
|
|
477
|
-
},
|
|
478
|
-
setup(__props) {
|
|
479
|
-
const props = __props;
|
|
480
|
-
const isLoading = ref(true);
|
|
481
|
-
const embedSource = ref("");
|
|
482
|
-
const error = ref(false);
|
|
483
|
-
const data = ref("");
|
|
484
|
-
const workflowsStore = useWorkflowsStore();
|
|
485
|
-
const i18n = useI18n();
|
|
486
|
-
const embedClass = computed(() => {
|
|
487
|
-
return [props.binaryData.fileType ?? "other"];
|
|
488
|
-
});
|
|
489
|
-
onMounted(async () => {
|
|
490
|
-
const { id, data: binaryData, fileName, fileType, mimeType } = props.binaryData;
|
|
491
|
-
const isJSONData = fileType === "json";
|
|
492
|
-
const isHTMLData = fileType === "html";
|
|
493
|
-
if (!id) {
|
|
494
|
-
if (isJSONData || isHTMLData) {
|
|
495
|
-
data.value = isJSONData ? jsonParse(base64DecodeUTF8(binaryData)) : base64DecodeUTF8(binaryData);
|
|
496
|
-
} else {
|
|
497
|
-
embedSource.value = `data:${mimeType};charset=utf-8;base64,${binaryData}`;
|
|
498
|
-
}
|
|
499
|
-
} else {
|
|
500
|
-
try {
|
|
501
|
-
const binaryUrl = workflowsStore.getBinaryUrl(id, "view", fileName ?? "", mimeType);
|
|
502
|
-
if (isJSONData || isHTMLData) {
|
|
503
|
-
const fetchedData = await fetch(binaryUrl, { credentials: "include" });
|
|
504
|
-
data.value = await (isJSONData ? fetchedData.json() : fetchedData.text());
|
|
505
|
-
} else {
|
|
506
|
-
embedSource.value = binaryUrl;
|
|
507
|
-
}
|
|
508
|
-
} catch (e) {
|
|
509
|
-
error.value = true;
|
|
510
|
-
}
|
|
511
|
-
}
|
|
512
|
-
isLoading.value = false;
|
|
513
|
-
});
|
|
514
|
-
return (_ctx, _cache) => {
|
|
515
|
-
return openBlock(), createElementBlock("span", null, [
|
|
516
|
-
isLoading.value ? (openBlock(), createElementBlock("div", _hoisted_1$7, "Loading binary data...")) : error.value ? (openBlock(), createElementBlock("div", _hoisted_2$4, "Error loading binary data")) : (openBlock(), createElementBlock("span", _hoisted_3$3, [
|
|
517
|
-
_ctx.binaryData.fileType === "video" ? (openBlock(), createElementBlock("video", _hoisted_4$3, [
|
|
518
|
-
createBaseVNode("source", {
|
|
519
|
-
src: embedSource.value,
|
|
520
|
-
type: _ctx.binaryData.mimeType
|
|
521
|
-
}, null, 8, _hoisted_5$3),
|
|
522
|
-
createTextVNode(" " + toDisplayString(unref(i18n).baseText("binaryDataDisplay.yourBrowserDoesNotSupport")), 1)
|
|
523
|
-
])) : _ctx.binaryData.fileType === "audio" ? (openBlock(), createElementBlock("audio", _hoisted_6$2, [
|
|
524
|
-
createBaseVNode("source", {
|
|
525
|
-
src: embedSource.value,
|
|
526
|
-
type: _ctx.binaryData.mimeType
|
|
527
|
-
}, null, 8, _hoisted_7$2),
|
|
528
|
-
createTextVNode(" " + toDisplayString(unref(i18n).baseText("binaryDataDisplay.yourBrowserDoesNotSupport")), 1)
|
|
529
|
-
])) : _ctx.binaryData.fileType === "image" ? (openBlock(), createElementBlock("img", {
|
|
530
|
-
key: 2,
|
|
531
|
-
src: embedSource.value
|
|
532
|
-
}, null, 8, _hoisted_8$2)) : _ctx.binaryData.fileType === "json" ? (openBlock(), createBlock(unref(VueJsonPretty), {
|
|
533
|
-
key: 3,
|
|
534
|
-
data: data.value,
|
|
535
|
-
deep: 3,
|
|
536
|
-
"show-length": true
|
|
537
|
-
}, null, 8, ["data"])) : _ctx.binaryData.fileType === "html" ? (openBlock(), createBlock(RunDataHtml, {
|
|
538
|
-
key: 4,
|
|
539
|
-
"input-html": data.value
|
|
540
|
-
}, null, 8, ["input-html"])) : (openBlock(), createElementBlock("embed", {
|
|
541
|
-
key: 5,
|
|
542
|
-
src: embedSource.value,
|
|
543
|
-
class: normalizeClass(["binary-data", embedClass.value])
|
|
544
|
-
}, null, 10, _hoisted_9$2))
|
|
545
|
-
]))
|
|
546
|
-
]);
|
|
547
|
-
};
|
|
548
|
-
}
|
|
549
|
-
});
|
|
550
|
-
const _hoisted_1$6 = { class: "binary-data-window-wrapper" };
|
|
551
|
-
const _hoisted_2$3 = { key: 0 };
|
|
552
|
-
const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
553
|
-
__name: "BinaryDataDisplay",
|
|
554
|
-
props: {
|
|
555
|
-
displayData: {},
|
|
556
|
-
windowVisible: { type: Boolean }
|
|
557
|
-
},
|
|
558
|
-
emits: ["close"],
|
|
559
|
-
setup(__props, { emit: __emit }) {
|
|
560
|
-
const props = __props;
|
|
561
|
-
const emit = __emit;
|
|
562
|
-
const nodeHelpers = useNodeHelpers();
|
|
563
|
-
const workflowsStore = useWorkflowsStore();
|
|
564
|
-
const i18n = useI18n();
|
|
565
|
-
const workflowRunData = computed(() => {
|
|
566
|
-
const workflowExecution = workflowsStore.getWorkflowExecution;
|
|
567
|
-
if (workflowExecution === null) {
|
|
568
|
-
return null;
|
|
569
|
-
}
|
|
570
|
-
const executionData = workflowExecution.data;
|
|
571
|
-
return executionData ? executionData.resultData.runData : null;
|
|
572
|
-
});
|
|
573
|
-
const binaryData = computed(() => {
|
|
574
|
-
if (typeof props.displayData.node !== "string" || typeof props.displayData.key !== "string" || typeof props.displayData.runIndex !== "number" || typeof props.displayData.index !== "number" || typeof props.displayData.outputIndex !== "number") {
|
|
575
|
-
return null;
|
|
576
|
-
}
|
|
577
|
-
const binaryDataLocal = nodeHelpers.getBinaryData(
|
|
578
|
-
workflowRunData.value,
|
|
579
|
-
props.displayData.node,
|
|
580
|
-
props.displayData.runIndex,
|
|
581
|
-
props.displayData.outputIndex
|
|
582
|
-
);
|
|
583
|
-
if (binaryDataLocal.length === 0) {
|
|
584
|
-
return null;
|
|
585
|
-
}
|
|
586
|
-
if (props.displayData.index >= binaryDataLocal.length || binaryDataLocal[props.displayData.index][props.displayData.key] === void 0) {
|
|
587
|
-
return null;
|
|
588
|
-
}
|
|
589
|
-
const binaryDataItem = binaryDataLocal[props.displayData.index][props.displayData.key];
|
|
590
|
-
return binaryDataItem;
|
|
591
|
-
});
|
|
592
|
-
function closeWindow() {
|
|
593
|
-
emit("close");
|
|
594
|
-
return false;
|
|
595
|
-
}
|
|
596
|
-
return (_ctx, _cache) => {
|
|
597
|
-
const _component_n8n_button = N8nButton;
|
|
598
|
-
return _ctx.windowVisible ? (openBlock(), createElementBlock("div", {
|
|
599
|
-
key: 0,
|
|
600
|
-
class: normalizeClass(["binary-data-window", binaryData.value?.fileType])
|
|
601
|
-
}, [
|
|
602
|
-
createVNode(_component_n8n_button, {
|
|
603
|
-
size: "small",
|
|
604
|
-
class: "binary-data-window-back",
|
|
605
|
-
title: unref(i18n).baseText("binaryDataDisplay.backToOverviewPage"),
|
|
606
|
-
icon: "arrow-left",
|
|
607
|
-
label: unref(i18n).baseText("binaryDataDisplay.backToList"),
|
|
608
|
-
onClick: withModifiers(closeWindow, ["stop"])
|
|
609
|
-
}, null, 8, ["title", "label"]),
|
|
610
|
-
createBaseVNode("div", _hoisted_1$6, [
|
|
611
|
-
!binaryData.value ? (openBlock(), createElementBlock("div", _hoisted_2$3, toDisplayString(unref(i18n).baseText("binaryDataDisplay.noDataFoundToDisplay")), 1)) : (openBlock(), createBlock(_sfc_main$8, {
|
|
612
|
-
key: 1,
|
|
613
|
-
"binary-data": binaryData.value
|
|
614
|
-
}, null, 8, ["binary-data"]))
|
|
615
|
-
])
|
|
616
|
-
], 2)) : createCommentVNode("", true);
|
|
617
|
-
};
|
|
618
|
-
}
|
|
619
|
-
});
|
|
620
|
-
const _hoisted_1$5 = { class: "node-error-view__header" };
|
|
621
|
-
const _hoisted_2$2 = {
|
|
622
|
-
class: "node-error-view__header-message",
|
|
623
|
-
"data-test-id": "node-error-message"
|
|
624
|
-
};
|
|
625
|
-
const _hoisted_3$2 = {
|
|
626
|
-
key: 0,
|
|
627
|
-
"data-test-id": "node-error-description",
|
|
628
|
-
class: "node-error-view__header-description"
|
|
629
|
-
};
|
|
630
|
-
const _hoisted_4$2 = { key: 1 };
|
|
631
|
-
const _hoisted_5$2 = {
|
|
632
|
-
key: 2,
|
|
633
|
-
class: "node-error-view__button",
|
|
634
|
-
"data-test-id": "node-error-view-ask-assistant-button"
|
|
635
|
-
};
|
|
636
|
-
const _hoisted_6$1 = {
|
|
637
|
-
key: 0,
|
|
638
|
-
class: "node-error-view__info"
|
|
639
|
-
};
|
|
640
|
-
const _hoisted_7$1 = { class: "node-error-view__info-header" };
|
|
641
|
-
const _hoisted_8$1 = { class: "node-error-view__info-title" };
|
|
642
|
-
const _hoisted_9$1 = { class: "copy-button" };
|
|
643
|
-
const _hoisted_10 = { class: "node-error-view__info-content" };
|
|
644
|
-
const _hoisted_11 = {
|
|
645
|
-
key: 0,
|
|
646
|
-
class: "node-error-view__details"
|
|
647
|
-
};
|
|
648
|
-
const _hoisted_12 = { class: "node-error-view__details-summary" };
|
|
649
|
-
const _hoisted_13 = { class: "node-error-view__details-content" };
|
|
650
|
-
const _hoisted_14 = {
|
|
651
|
-
key: 0,
|
|
652
|
-
class: "node-error-view__details-row"
|
|
653
|
-
};
|
|
654
|
-
const _hoisted_15 = { class: "node-error-view__details-label" };
|
|
655
|
-
const _hoisted_16 = { class: "node-error-view__details-value" };
|
|
656
|
-
const _hoisted_17 = {
|
|
657
|
-
key: 1,
|
|
658
|
-
class: "node-error-view__details-row"
|
|
659
|
-
};
|
|
660
|
-
const _hoisted_18 = { class: "node-error-view__details-label" };
|
|
661
|
-
const _hoisted_19 = { class: "node-error-view__details-value" };
|
|
662
|
-
const _hoisted_20 = {
|
|
663
|
-
key: 2,
|
|
664
|
-
class: "node-error-view__details-row"
|
|
665
|
-
};
|
|
666
|
-
const _hoisted_21 = { class: "node-error-view__details-label" };
|
|
667
|
-
const _hoisted_22 = { class: "node-error-view__details-value" };
|
|
668
|
-
const _hoisted_23 = {
|
|
669
|
-
key: 3,
|
|
670
|
-
class: "node-error-view__details-row"
|
|
671
|
-
};
|
|
672
|
-
const _hoisted_24 = { class: "node-error-view__details-label" };
|
|
673
|
-
const _hoisted_25 = { class: "node-error-view__details-value" };
|
|
674
|
-
const _hoisted_26 = {
|
|
675
|
-
key: 4,
|
|
676
|
-
class: "node-error-view__details-row"
|
|
677
|
-
};
|
|
678
|
-
const _hoisted_27 = { class: "node-error-view__details-label" };
|
|
679
|
-
const _hoisted_28 = { class: "node-error-view__details-value" };
|
|
680
|
-
const _hoisted_29 = { class: "node-error-view__details" };
|
|
681
|
-
const _hoisted_30 = { class: "node-error-view__details-summary" };
|
|
682
|
-
const _hoisted_31 = { class: "node-error-view__details-content" };
|
|
683
|
-
const _hoisted_32 = {
|
|
684
|
-
key: 0,
|
|
685
|
-
class: "node-error-view__details-row"
|
|
686
|
-
};
|
|
687
|
-
const _hoisted_33 = { class: "node-error-view__details-label" };
|
|
688
|
-
const _hoisted_34 = { class: "node-error-view__details-value" };
|
|
689
|
-
const _hoisted_35 = {
|
|
690
|
-
key: 1,
|
|
691
|
-
class: "node-error-view__details-row"
|
|
692
|
-
};
|
|
693
|
-
const _hoisted_36 = { class: "node-error-view__details-label" };
|
|
694
|
-
const _hoisted_37 = { class: "node-error-view__details-value" };
|
|
695
|
-
const _hoisted_38 = {
|
|
696
|
-
key: 2,
|
|
697
|
-
class: "node-error-view__details-row"
|
|
698
|
-
};
|
|
699
|
-
const _hoisted_39 = { class: "node-error-view__details-label" };
|
|
700
|
-
const _hoisted_40 = { class: "node-error-view__details-value" };
|
|
701
|
-
const _hoisted_41 = {
|
|
702
|
-
key: 3,
|
|
703
|
-
class: "node-error-view__details-row"
|
|
704
|
-
};
|
|
705
|
-
const _hoisted_42 = { class: "node-error-view__details-label" };
|
|
706
|
-
const _hoisted_43 = { class: "node-error-view__details-value" };
|
|
707
|
-
const _hoisted_44 = {
|
|
708
|
-
key: 4,
|
|
709
|
-
class: "node-error-view__details-row"
|
|
710
|
-
};
|
|
711
|
-
const _hoisted_45 = { class: "node-error-view__details-label" };
|
|
712
|
-
const _hoisted_46 = { class: "node-error-view__details-value" };
|
|
713
|
-
const _hoisted_47 = { class: "node-error-view__details-row" };
|
|
714
|
-
const _hoisted_48 = { class: "node-error-view__details-label" };
|
|
715
|
-
const _hoisted_49 = { class: "node-error-view__details-value" };
|
|
716
|
-
const _hoisted_50 = {
|
|
717
|
-
key: 5,
|
|
718
|
-
class: "node-error-view__details-row"
|
|
719
|
-
};
|
|
720
|
-
const _hoisted_51 = { class: "node-error-view__details-label" };
|
|
721
|
-
const _hoisted_52 = { class: "node-error-view__details-value" };
|
|
722
|
-
const _hoisted_53 = {
|
|
723
|
-
key: 6,
|
|
724
|
-
class: "node-error-view__details-row"
|
|
725
|
-
};
|
|
726
|
-
const _hoisted_54 = { class: "node-error-view__details-label" };
|
|
727
|
-
const _hoisted_55 = { class: "node-error-view__details-value" };
|
|
728
|
-
const _hoisted_56 = {
|
|
729
|
-
key: 7,
|
|
730
|
-
class: "node-error-view__details-row"
|
|
731
|
-
};
|
|
732
|
-
const _hoisted_57 = { class: "node-error-view__details-label" };
|
|
733
|
-
const _hoisted_58 = { class: "node-error-view__details-value" };
|
|
734
|
-
const _hoisted_59 = {
|
|
735
|
-
key: 8,
|
|
736
|
-
class: "node-error-view__details-row"
|
|
737
|
-
};
|
|
738
|
-
const _hoisted_60 = { class: "node-error-view__details-label" };
|
|
739
|
-
const _hoisted_61 = { class: "node-error-view__details-value" };
|
|
740
|
-
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
741
|
-
__name: "NodeErrorView",
|
|
742
|
-
props: {
|
|
743
|
-
error: {},
|
|
744
|
-
showDetails: { type: Boolean },
|
|
745
|
-
compact: { type: Boolean }
|
|
746
|
-
},
|
|
747
|
-
setup(__props) {
|
|
748
|
-
const props = __props;
|
|
749
|
-
const router = useRouter();
|
|
750
|
-
const clipboard = useClipboard();
|
|
751
|
-
const toast = useToast();
|
|
752
|
-
const i18n = useI18n();
|
|
753
|
-
const assistantHelpers = useAIAssistantHelpers();
|
|
754
|
-
const nodeTypesStore = useNodeTypesStore();
|
|
755
|
-
const ndvStore = useNDVStore();
|
|
756
|
-
const workflowsStore = useWorkflowsStore();
|
|
757
|
-
const rootStore = useRootStore();
|
|
758
|
-
const assistantStore = useAssistantStore();
|
|
759
|
-
const uiStore = useUIStore();
|
|
760
|
-
const workflowId = computed(() => workflowsStore.workflowId);
|
|
761
|
-
const executionId = computed(() => workflowsStore.getWorkflowExecution?.id);
|
|
762
|
-
const displayCause = computed(() => {
|
|
763
|
-
return JSON.stringify(props.error.cause ?? "").length < MAX_DISPLAY_DATA_SIZE;
|
|
764
|
-
});
|
|
765
|
-
const node = computed(() => {
|
|
766
|
-
return props.error.node || ndvStore.activeNode;
|
|
767
|
-
});
|
|
768
|
-
const parameters = computed(() => {
|
|
769
|
-
if (!node.value) {
|
|
770
|
-
return [];
|
|
771
|
-
}
|
|
772
|
-
const nodeType = nodeTypesStore.getNodeType(node.value.type, node.value.typeVersion);
|
|
773
|
-
if (nodeType === null) {
|
|
774
|
-
return [];
|
|
775
|
-
}
|
|
776
|
-
return nodeType.properties;
|
|
777
|
-
});
|
|
778
|
-
const n8nVersion = computed(() => {
|
|
779
|
-
const baseUrl = rootStore.urlBaseEditor;
|
|
780
|
-
let instanceType = "Self Hosted";
|
|
781
|
-
if (baseUrl.includes("n8n.cloud")) {
|
|
782
|
-
instanceType = "Cloud";
|
|
783
|
-
}
|
|
784
|
-
return rootStore.versionCli + ` (${instanceType})`;
|
|
785
|
-
});
|
|
786
|
-
const hasManyInputItems = computed(() => {
|
|
787
|
-
return ndvStore.ndvInputData.length > 1;
|
|
788
|
-
});
|
|
789
|
-
const nodeDefaultName = computed(() => {
|
|
790
|
-
if (!node.value) {
|
|
791
|
-
return "Node";
|
|
792
|
-
}
|
|
793
|
-
const nodeType = nodeTypesStore.getNodeType(node.value.type, node.value.typeVersion);
|
|
794
|
-
return nodeType?.defaults?.name || node.value.name;
|
|
795
|
-
});
|
|
796
|
-
const prepareRawMessages = computed(() => {
|
|
797
|
-
const returnData = [];
|
|
798
|
-
if (!props.error.messages?.length) {
|
|
799
|
-
return [];
|
|
800
|
-
}
|
|
801
|
-
const errorMessage = getErrorMessage();
|
|
802
|
-
Array.from(new Set(props.error.messages)).forEach((message) => {
|
|
803
|
-
const isParsable = /^\d{3} - \{/.test(message);
|
|
804
|
-
const parts = isParsable ? message.split(" - ").map((part) => part.trim()) : [];
|
|
805
|
-
for (const part of parts) {
|
|
806
|
-
try {
|
|
807
|
-
const parsed = JSON.parse(part);
|
|
808
|
-
if (typeof parsed === "object") {
|
|
809
|
-
returnData.push(parsed);
|
|
810
|
-
return;
|
|
811
|
-
}
|
|
812
|
-
} catch (error) {
|
|
813
|
-
}
|
|
814
|
-
}
|
|
815
|
-
if (message === errorMessage) return;
|
|
816
|
-
returnData.push(message);
|
|
817
|
-
});
|
|
818
|
-
return returnData;
|
|
819
|
-
});
|
|
820
|
-
const isAskAssistantAvailable = computed(() => {
|
|
821
|
-
if (!node.value || isSubNodeError.value) {
|
|
822
|
-
return false;
|
|
823
|
-
}
|
|
824
|
-
const isCustomNode = node.value.type === void 0 || isCommunityPackageName(node.value.type);
|
|
825
|
-
return assistantStore.canShowAssistantButtonsOnCanvas && !isCustomNode && !nodeIsHidden();
|
|
826
|
-
});
|
|
827
|
-
const assistantAlreadyAsked = computed(() => {
|
|
828
|
-
return assistantStore.isNodeErrorActive({
|
|
829
|
-
error: assistantHelpers.simplifyErrorForAssistant(props.error),
|
|
830
|
-
node: props.error.node || ndvStore.activeNode
|
|
831
|
-
});
|
|
832
|
-
});
|
|
833
|
-
const isSubNodeError = computed(() => {
|
|
834
|
-
return props.error.name === "NodeOperationError" && props.error.functionality === "configuration-node";
|
|
835
|
-
});
|
|
836
|
-
function nodeVersionTag(nodeType) {
|
|
837
|
-
if (!nodeType || "hidden" in nodeType && nodeType.hidden) {
|
|
838
|
-
return i18n.baseText("nodeSettings.deprecated");
|
|
839
|
-
}
|
|
840
|
-
const latestNodeVersion = Math.max(...nodeTypesStore.getNodeVersions(nodeType.type));
|
|
841
|
-
if (latestNodeVersion === nodeType.typeVersion) {
|
|
842
|
-
return i18n.baseText("nodeSettings.latest");
|
|
843
|
-
}
|
|
844
|
-
return i18n.baseText("nodeSettings.latestVersion", {
|
|
845
|
-
interpolate: { version: latestNodeVersion.toString() }
|
|
846
|
-
});
|
|
847
|
-
}
|
|
848
|
-
function prepareDescription(description) {
|
|
849
|
-
return sanitizeHtml$1(description.replace(/`(.*?)`/g, "<code>$1</code>"));
|
|
850
|
-
}
|
|
851
|
-
function getErrorDescription() {
|
|
852
|
-
if (props.error.context?.descriptionKey) {
|
|
853
|
-
const interpolate = {
|
|
854
|
-
nodeCause: props.error.context.nodeCause,
|
|
855
|
-
runIndex: props.error.context.runIndex ?? "0",
|
|
856
|
-
itemIndex: props.error.context.itemIndex ?? "0"
|
|
857
|
-
};
|
|
858
|
-
return prepareDescription(
|
|
859
|
-
i18n.baseText(
|
|
860
|
-
`nodeErrorView.description.${props.error.context.descriptionKey}`,
|
|
861
|
-
{ interpolate }
|
|
862
|
-
)
|
|
863
|
-
);
|
|
864
|
-
}
|
|
865
|
-
if (!props.error.context?.descriptionTemplate) {
|
|
866
|
-
return prepareDescription(props.error.description ?? "");
|
|
867
|
-
}
|
|
868
|
-
const parameterName = parameterDisplayName(props.error.context.parameter);
|
|
869
|
-
return prepareDescription(
|
|
870
|
-
props.error.context.descriptionTemplate.replace(/%%PARAMETER%%/g, parameterName)
|
|
871
|
-
);
|
|
872
|
-
}
|
|
873
|
-
function addItemIndexSuffix(message) {
|
|
874
|
-
let itemIndexSuffix = "";
|
|
875
|
-
if (hasManyInputItems.value && props.error?.context?.itemIndex !== void 0) {
|
|
876
|
-
itemIndexSuffix = `item ${props.error.context.itemIndex}`;
|
|
877
|
-
}
|
|
878
|
-
if (message.includes(itemIndexSuffix)) return message;
|
|
879
|
-
return `${message} [${itemIndexSuffix}]`;
|
|
880
|
-
}
|
|
881
|
-
function getErrorMessage() {
|
|
882
|
-
let message = "";
|
|
883
|
-
const isNonEmptyString = (value) => !!value && typeof value === "string";
|
|
884
|
-
if (isSubNodeError.value) {
|
|
885
|
-
message = i18n.baseText("nodeErrorView.errorSubNode", {
|
|
886
|
-
interpolate: { node: props.error.node?.name ?? "" }
|
|
887
|
-
});
|
|
888
|
-
} else if (isNonEmptyString(props.error.message) && (props.error.message === props.error.description || !props.error.context?.messageTemplate)) {
|
|
889
|
-
message = props.error.message;
|
|
890
|
-
} else if (isNonEmptyString(props.error.context?.messageTemplate) && isNonEmptyString(props.error.context?.parameter)) {
|
|
891
|
-
const parameterName = parameterDisplayName(props.error.context.parameter);
|
|
892
|
-
message = props.error.context.messageTemplate.replace(/%%PARAMETER%%/g, parameterName);
|
|
893
|
-
} else if (Array.isArray(props.error.messages) && props.error.messages.length > 0) {
|
|
894
|
-
message = props.error.messages[0];
|
|
895
|
-
}
|
|
896
|
-
return addItemIndexSuffix(message);
|
|
897
|
-
}
|
|
898
|
-
function parameterDisplayName(path, fullPath = true) {
|
|
899
|
-
try {
|
|
900
|
-
const params = getParameterName(parameters.value, path.split("."));
|
|
901
|
-
if (!params.length) {
|
|
902
|
-
throw new Error();
|
|
903
|
-
}
|
|
904
|
-
if (!fullPath) {
|
|
905
|
-
return params.pop().displayName;
|
|
906
|
-
}
|
|
907
|
-
return params.map((parameter) => parameter.displayName).join(" > ");
|
|
908
|
-
} catch (error) {
|
|
909
|
-
return `Could not find parameter "${path}"`;
|
|
910
|
-
}
|
|
911
|
-
}
|
|
912
|
-
function getParameterName(params, pathParts) {
|
|
913
|
-
let currentParameterName = pathParts.shift();
|
|
914
|
-
if (currentParameterName === void 0) {
|
|
915
|
-
return [];
|
|
916
|
-
}
|
|
917
|
-
const arrayMatch = currentParameterName.match(/(.*)\[([\d])\]$/);
|
|
918
|
-
if (arrayMatch !== null && arrayMatch.length > 0) {
|
|
919
|
-
currentParameterName = arrayMatch[1];
|
|
920
|
-
}
|
|
921
|
-
const currentParameter = params.find(
|
|
922
|
-
(parameter) => parameter.name === currentParameterName
|
|
923
|
-
);
|
|
924
|
-
if (currentParameter === void 0) {
|
|
925
|
-
throw new Error(`Could not find parameter "${currentParameterName}"`);
|
|
926
|
-
}
|
|
927
|
-
if (pathParts.length === 0) {
|
|
928
|
-
return [currentParameter];
|
|
929
|
-
}
|
|
930
|
-
if (currentParameter.hasOwnProperty("options")) {
|
|
931
|
-
return [
|
|
932
|
-
currentParameter,
|
|
933
|
-
...getParameterName(currentParameter.options, pathParts)
|
|
934
|
-
];
|
|
935
|
-
}
|
|
936
|
-
if (currentParameter.hasOwnProperty("values")) {
|
|
937
|
-
return [
|
|
938
|
-
currentParameter,
|
|
939
|
-
...getParameterName(currentParameter.values, pathParts)
|
|
940
|
-
];
|
|
941
|
-
}
|
|
942
|
-
return [currentParameter];
|
|
943
|
-
}
|
|
944
|
-
function copyErrorDetails() {
|
|
945
|
-
const error = props.error;
|
|
946
|
-
const errorInfo = {
|
|
947
|
-
errorMessage: getErrorMessage()
|
|
948
|
-
};
|
|
949
|
-
if (error.description) {
|
|
950
|
-
errorInfo.errorDescription = error.description;
|
|
951
|
-
}
|
|
952
|
-
const errorDetails = {};
|
|
953
|
-
if (error?.messages?.length) {
|
|
954
|
-
errorDetails.rawErrorMessage = error.messages;
|
|
955
|
-
}
|
|
956
|
-
if ("httpCode" in error && error.httpCode) {
|
|
957
|
-
errorDetails.httpCode = error.httpCode;
|
|
958
|
-
}
|
|
959
|
-
if (error.context && error.context.data) {
|
|
960
|
-
errorDetails.errorData = error.context.data;
|
|
961
|
-
}
|
|
962
|
-
if (error.extra) {
|
|
963
|
-
errorDetails.errorExtra = error.extra;
|
|
964
|
-
}
|
|
965
|
-
errorInfo.errorDetails = errorDetails;
|
|
966
|
-
const n8nDetails = {};
|
|
967
|
-
if (error.node) {
|
|
968
|
-
n8nDetails.nodeName = error.node.name;
|
|
969
|
-
n8nDetails.nodeType = error.node.type;
|
|
970
|
-
n8nDetails.nodeVersion = error.node.typeVersion;
|
|
971
|
-
if (error.node?.parameters?.resource) {
|
|
972
|
-
n8nDetails.resource = error.node.parameters.resource;
|
|
973
|
-
}
|
|
974
|
-
if (error?.node?.parameters?.operation) {
|
|
975
|
-
n8nDetails.operation = error.node.parameters.operation;
|
|
976
|
-
}
|
|
977
|
-
}
|
|
978
|
-
if (error.context) {
|
|
979
|
-
if (error.context.itemIndex !== void 0) {
|
|
980
|
-
n8nDetails.itemIndex = error.context.itemIndex;
|
|
981
|
-
}
|
|
982
|
-
if (error.context.runIndex !== void 0) {
|
|
983
|
-
n8nDetails.runIndex = error.context.runIndex;
|
|
984
|
-
}
|
|
985
|
-
if (error.context.parameter !== void 0) {
|
|
986
|
-
n8nDetails.parameter = error.context.parameter;
|
|
987
|
-
}
|
|
988
|
-
if (error.context.causeDetailed) {
|
|
989
|
-
n8nDetails.causeDetailed = error.context.causeDetailed;
|
|
990
|
-
}
|
|
991
|
-
}
|
|
992
|
-
if (error.timestamp) {
|
|
993
|
-
n8nDetails.time = new Date(error.timestamp).toLocaleString();
|
|
994
|
-
}
|
|
995
|
-
n8nDetails.n8nVersion = n8nVersion.value;
|
|
996
|
-
n8nDetails.binaryDataMode = rootStore.binaryDataMode;
|
|
997
|
-
if (error.cause) {
|
|
998
|
-
n8nDetails.cause = error.cause;
|
|
999
|
-
}
|
|
1000
|
-
n8nDetails.stackTrace = error.stack?.split("\n");
|
|
1001
|
-
errorInfo.n8nDetails = n8nDetails;
|
|
1002
|
-
void clipboard.copy(JSON.stringify(errorInfo, null, 2));
|
|
1003
|
-
copySuccess();
|
|
1004
|
-
}
|
|
1005
|
-
function copySuccess() {
|
|
1006
|
-
toast.showMessage({
|
|
1007
|
-
title: i18n.baseText("nodeErrorView.showMessage.title"),
|
|
1008
|
-
type: "info"
|
|
1009
|
-
});
|
|
1010
|
-
}
|
|
1011
|
-
function nodeIsHidden() {
|
|
1012
|
-
const nodeType = nodeTypesStore.getNodeType(node?.value.type);
|
|
1013
|
-
return nodeType?.hidden ?? false;
|
|
1014
|
-
}
|
|
1015
|
-
const onOpenErrorNodeDetailClick = () => {
|
|
1016
|
-
if (!props.error.node) {
|
|
1017
|
-
return;
|
|
1018
|
-
}
|
|
1019
|
-
if ("workflowId" in props.error && workflowId.value && typeof props.error.workflowId === "string" && workflowId.value !== props.error.workflowId && "executionId" in props.error && executionId.value && typeof props.error.executionId === "string" && executionId.value !== props.error.executionId) {
|
|
1020
|
-
const link = router.resolve({
|
|
1021
|
-
name: VIEWS.EXECUTION_PREVIEW,
|
|
1022
|
-
params: {
|
|
1023
|
-
name: props.error.workflowId,
|
|
1024
|
-
executionId: props.error.executionId,
|
|
1025
|
-
nodeId: props.error.node.id
|
|
1026
|
-
}
|
|
1027
|
-
});
|
|
1028
|
-
window.open(link.href, "_blank");
|
|
1029
|
-
} else {
|
|
1030
|
-
ndvStore.activeNodeName = props.error.node.name;
|
|
1031
|
-
}
|
|
1032
|
-
};
|
|
1033
|
-
async function onAskAssistantClick() {
|
|
1034
|
-
const { message, lineNumber, description } = props.error;
|
|
1035
|
-
const sessionInProgress = !assistantStore.isSessionEnded;
|
|
1036
|
-
const errorHelp = {
|
|
1037
|
-
error: {
|
|
1038
|
-
name: props.error.name,
|
|
1039
|
-
message,
|
|
1040
|
-
lineNumber,
|
|
1041
|
-
description: description ?? getErrorDescription(),
|
|
1042
|
-
type: "type" in props.error ? props.error.type : void 0
|
|
1043
|
-
},
|
|
1044
|
-
node: node.value
|
|
1045
|
-
};
|
|
1046
|
-
if (sessionInProgress) {
|
|
1047
|
-
uiStore.openModalWithData({
|
|
1048
|
-
name: NEW_ASSISTANT_SESSION_MODAL,
|
|
1049
|
-
data: { context: { errorHelp } }
|
|
1050
|
-
});
|
|
1051
|
-
return;
|
|
1052
|
-
}
|
|
1053
|
-
await assistantStore.initErrorHelper(errorHelp);
|
|
1054
|
-
assistantStore.trackUserOpenedAssistant({
|
|
1055
|
-
source: "error",
|
|
1056
|
-
task: "error",
|
|
1057
|
-
has_existing_session: false
|
|
1058
|
-
});
|
|
1059
|
-
}
|
|
1060
|
-
return (_ctx, _cache) => {
|
|
1061
|
-
const _component_n8n_button = N8nButton;
|
|
1062
|
-
const _component_n8n_tooltip = N8nTooltip;
|
|
1063
|
-
const _component_n8n_icon = N8nIcon;
|
|
1064
|
-
const _directive_n8n_html = resolveDirective("n8n-html");
|
|
1065
|
-
return openBlock(), createElementBlock("div", {
|
|
1066
|
-
class: normalizeClass(["node-error-view", props.compact ? "node-error-view_compact" : ""])
|
|
1067
|
-
}, [
|
|
1068
|
-
createBaseVNode("div", _hoisted_1$5, [
|
|
1069
|
-
createBaseVNode("div", _hoisted_2$2, [
|
|
1070
|
-
createBaseVNode("div", null, toDisplayString(getErrorMessage()), 1)
|
|
1071
|
-
]),
|
|
1072
|
-
(_ctx.error.description || _ctx.error.context?.descriptionKey) && !isSubNodeError.value ? withDirectives((openBlock(), createElementBlock("div", _hoisted_3$2, null, 512)), [
|
|
1073
|
-
[_directive_n8n_html, getErrorDescription()]
|
|
1074
|
-
]) : createCommentVNode("", true),
|
|
1075
|
-
isSubNodeError.value ? (openBlock(), createElementBlock("div", _hoisted_4$2, [
|
|
1076
|
-
createVNode(_component_n8n_button, {
|
|
1077
|
-
icon: "arrow-right",
|
|
1078
|
-
type: "secondary",
|
|
1079
|
-
label: unref(i18n).baseText("pushConnection.executionError.openNode"),
|
|
1080
|
-
class: "node-error-view__button",
|
|
1081
|
-
"data-test-id": "node-error-view-open-node-button",
|
|
1082
|
-
onClick: onOpenErrorNodeDetailClick
|
|
1083
|
-
}, null, 8, ["label"])
|
|
1084
|
-
])) : createCommentVNode("", true),
|
|
1085
|
-
isAskAssistantAvailable.value ? (openBlock(), createElementBlock("div", _hoisted_5$2, [
|
|
1086
|
-
createVNode(InlineAskAssistantButton, {
|
|
1087
|
-
asked: assistantAlreadyAsked.value,
|
|
1088
|
-
onClick: onAskAssistantClick
|
|
1089
|
-
}, null, 8, ["asked"])
|
|
1090
|
-
])) : createCommentVNode("", true)
|
|
1091
|
-
]),
|
|
1092
|
-
_ctx.showDetails ? (openBlock(), createElementBlock("div", _hoisted_6$1, [
|
|
1093
|
-
createBaseVNode("div", _hoisted_7$1, [
|
|
1094
|
-
createBaseVNode("p", _hoisted_8$1, toDisplayString(unref(i18n).baseText("nodeErrorView.details.title")), 1),
|
|
1095
|
-
createVNode(_component_n8n_tooltip, {
|
|
1096
|
-
class: "item",
|
|
1097
|
-
content: unref(i18n).baseText("nodeErrorView.copyToClipboard.tooltip"),
|
|
1098
|
-
placement: "left"
|
|
1099
|
-
}, {
|
|
1100
|
-
default: withCtx(() => [
|
|
1101
|
-
createBaseVNode("div", _hoisted_9$1, [
|
|
1102
|
-
createVNode(unref(_sfc_main$b), {
|
|
1103
|
-
icon: "files",
|
|
1104
|
-
type: "secondary",
|
|
1105
|
-
size: "small",
|
|
1106
|
-
text: true,
|
|
1107
|
-
"transparent-background": "transparent",
|
|
1108
|
-
onClick: copyErrorDetails
|
|
1109
|
-
})
|
|
1110
|
-
])
|
|
1111
|
-
]),
|
|
1112
|
-
_: 1
|
|
1113
|
-
}, 8, ["content"])
|
|
1114
|
-
]),
|
|
1115
|
-
createBaseVNode("div", _hoisted_10, [
|
|
1116
|
-
"httpCode" in _ctx.error && _ctx.error.httpCode || prepareRawMessages.value.length || _ctx.error?.context?.data || _ctx.error.extra ? (openBlock(), createElementBlock("details", _hoisted_11, [
|
|
1117
|
-
createBaseVNode("summary", _hoisted_12, [
|
|
1118
|
-
createVNode(_component_n8n_icon, {
|
|
1119
|
-
class: "node-error-view__details-icon",
|
|
1120
|
-
icon: "chevron-right"
|
|
1121
|
-
}),
|
|
1122
|
-
createTextVNode(" " + toDisplayString(unref(i18n).baseText("nodeErrorView.details.from", {
|
|
1123
|
-
interpolate: { node: `${nodeDefaultName.value}` }
|
|
1124
|
-
})), 1)
|
|
1125
|
-
]),
|
|
1126
|
-
createBaseVNode("div", _hoisted_13, [
|
|
1127
|
-
"httpCode" in _ctx.error && _ctx.error.httpCode ? (openBlock(), createElementBlock("div", _hoisted_14, [
|
|
1128
|
-
createBaseVNode("p", _hoisted_15, toDisplayString(unref(i18n).baseText("nodeErrorView.errorCode")), 1),
|
|
1129
|
-
createBaseVNode("p", _hoisted_16, [
|
|
1130
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.httpCode), 1)
|
|
1131
|
-
])
|
|
1132
|
-
])) : createCommentVNode("", true),
|
|
1133
|
-
prepareRawMessages.value.length ? (openBlock(), createElementBlock("div", _hoisted_17, [
|
|
1134
|
-
createBaseVNode("p", _hoisted_18, toDisplayString(unref(i18n).baseText("nodeErrorView.details.rawMessages")), 1),
|
|
1135
|
-
createBaseVNode("div", _hoisted_19, [
|
|
1136
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(prepareRawMessages.value, (msg, index) => {
|
|
1137
|
-
return openBlock(), createElementBlock("div", { key: index }, [
|
|
1138
|
-
createBaseVNode("pre", null, [
|
|
1139
|
-
createBaseVNode("code", null, toDisplayString(msg), 1)
|
|
1140
|
-
])
|
|
1141
|
-
]);
|
|
1142
|
-
}), 128))
|
|
1143
|
-
])
|
|
1144
|
-
])) : createCommentVNode("", true),
|
|
1145
|
-
_ctx.error?.context?.data ? (openBlock(), createElementBlock("div", _hoisted_20, [
|
|
1146
|
-
createBaseVNode("p", _hoisted_21, toDisplayString(unref(i18n).baseText("nodeErrorView.details.errorData")), 1),
|
|
1147
|
-
createBaseVNode("div", _hoisted_22, [
|
|
1148
|
-
createBaseVNode("pre", null, [
|
|
1149
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.context.data), 1)
|
|
1150
|
-
])
|
|
1151
|
-
])
|
|
1152
|
-
])) : createCommentVNode("", true),
|
|
1153
|
-
_ctx.error.extra ? (openBlock(), createElementBlock("div", _hoisted_23, [
|
|
1154
|
-
createBaseVNode("p", _hoisted_24, toDisplayString(unref(i18n).baseText("nodeErrorView.details.errorExtra")), 1),
|
|
1155
|
-
createBaseVNode("div", _hoisted_25, [
|
|
1156
|
-
createBaseVNode("pre", null, [
|
|
1157
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.extra), 1)
|
|
1158
|
-
])
|
|
1159
|
-
])
|
|
1160
|
-
])) : createCommentVNode("", true),
|
|
1161
|
-
_ctx.error.context && _ctx.error.context.request ? (openBlock(), createElementBlock("div", _hoisted_26, [
|
|
1162
|
-
createBaseVNode("p", _hoisted_27, toDisplayString(unref(i18n).baseText("nodeErrorView.details.request")), 1),
|
|
1163
|
-
createBaseVNode("div", _hoisted_28, [
|
|
1164
|
-
createBaseVNode("pre", null, [
|
|
1165
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.context.request), 1)
|
|
1166
|
-
])
|
|
1167
|
-
])
|
|
1168
|
-
])) : createCommentVNode("", true)
|
|
1169
|
-
])
|
|
1170
|
-
])) : createCommentVNode("", true),
|
|
1171
|
-
createBaseVNode("details", _hoisted_29, [
|
|
1172
|
-
createBaseVNode("summary", _hoisted_30, [
|
|
1173
|
-
createVNode(_component_n8n_icon, {
|
|
1174
|
-
class: "node-error-view__details-icon",
|
|
1175
|
-
icon: "chevron-right"
|
|
1176
|
-
}),
|
|
1177
|
-
createTextVNode(" " + toDisplayString(unref(i18n).baseText("nodeErrorView.details.info")), 1)
|
|
1178
|
-
]),
|
|
1179
|
-
createBaseVNode("div", _hoisted_31, [
|
|
1180
|
-
_ctx.error.context && _ctx.error.context.itemIndex !== void 0 ? (openBlock(), createElementBlock("div", _hoisted_32, [
|
|
1181
|
-
createBaseVNode("p", _hoisted_33, toDisplayString(unref(i18n).baseText("nodeErrorView.itemIndex")), 1),
|
|
1182
|
-
createBaseVNode("p", _hoisted_34, [
|
|
1183
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.context.itemIndex), 1)
|
|
1184
|
-
])
|
|
1185
|
-
])) : createCommentVNode("", true),
|
|
1186
|
-
_ctx.error.context && _ctx.error.context.runIndex !== void 0 ? (openBlock(), createElementBlock("div", _hoisted_35, [
|
|
1187
|
-
createBaseVNode("p", _hoisted_36, toDisplayString(unref(i18n).baseText("nodeErrorView.runIndex")), 1),
|
|
1188
|
-
createBaseVNode("p", _hoisted_37, [
|
|
1189
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.context.runIndex), 1)
|
|
1190
|
-
])
|
|
1191
|
-
])) : createCommentVNode("", true),
|
|
1192
|
-
_ctx.error.context && _ctx.error.context.parameter !== void 0 ? (openBlock(), createElementBlock("div", _hoisted_38, [
|
|
1193
|
-
createBaseVNode("p", _hoisted_39, toDisplayString(unref(i18n).baseText("nodeErrorView.inParameter")), 1),
|
|
1194
|
-
createBaseVNode("p", _hoisted_40, [
|
|
1195
|
-
createBaseVNode("code", null, toDisplayString(parameterDisplayName(`${_ctx.error.context.parameter}`)), 1)
|
|
1196
|
-
])
|
|
1197
|
-
])) : createCommentVNode("", true),
|
|
1198
|
-
_ctx.error.node && _ctx.error.node.type ? (openBlock(), createElementBlock("div", _hoisted_41, [
|
|
1199
|
-
createBaseVNode("p", _hoisted_42, toDisplayString(unref(i18n).baseText("nodeErrorView.details.nodeType")), 1),
|
|
1200
|
-
createBaseVNode("p", _hoisted_43, [
|
|
1201
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.node.type), 1)
|
|
1202
|
-
])
|
|
1203
|
-
])) : createCommentVNode("", true),
|
|
1204
|
-
_ctx.error.node && _ctx.error.node.typeVersion ? (openBlock(), createElementBlock("div", _hoisted_44, [
|
|
1205
|
-
createBaseVNode("p", _hoisted_45, toDisplayString(unref(i18n).baseText("nodeErrorView.details.nodeVersion")), 1),
|
|
1206
|
-
createBaseVNode("p", _hoisted_46, [
|
|
1207
|
-
createBaseVNode("code", null, [
|
|
1208
|
-
createBaseVNode("span", null, toDisplayString(_ctx.error.node.typeVersion + " "), 1),
|
|
1209
|
-
createBaseVNode("span", null, "(" + toDisplayString(nodeVersionTag(_ctx.error.node)) + ")", 1)
|
|
1210
|
-
])
|
|
1211
|
-
])
|
|
1212
|
-
])) : createCommentVNode("", true),
|
|
1213
|
-
createBaseVNode("div", _hoisted_47, [
|
|
1214
|
-
createBaseVNode("p", _hoisted_48, toDisplayString(unref(i18n).baseText("nodeErrorView.details.n8nVersion")), 1),
|
|
1215
|
-
createBaseVNode("p", _hoisted_49, [
|
|
1216
|
-
createBaseVNode("code", null, toDisplayString(n8nVersion.value), 1)
|
|
1217
|
-
])
|
|
1218
|
-
]),
|
|
1219
|
-
_ctx.error.timestamp ? (openBlock(), createElementBlock("div", _hoisted_50, [
|
|
1220
|
-
createBaseVNode("p", _hoisted_51, toDisplayString(unref(i18n).baseText("nodeErrorView.time")), 1),
|
|
1221
|
-
createBaseVNode("p", _hoisted_52, [
|
|
1222
|
-
createBaseVNode("code", null, toDisplayString(new Date(_ctx.error.timestamp).toLocaleString()), 1)
|
|
1223
|
-
])
|
|
1224
|
-
])) : createCommentVNode("", true),
|
|
1225
|
-
_ctx.error.cause && displayCause.value ? (openBlock(), createElementBlock("div", _hoisted_53, [
|
|
1226
|
-
createBaseVNode("p", _hoisted_54, toDisplayString(unref(i18n).baseText("nodeErrorView.details.errorCause")), 1),
|
|
1227
|
-
createBaseVNode("pre", _hoisted_55, [
|
|
1228
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.cause), 1)
|
|
1229
|
-
])
|
|
1230
|
-
])) : createCommentVNode("", true),
|
|
1231
|
-
_ctx.error.context && _ctx.error.context.causeDetailed ? (openBlock(), createElementBlock("div", _hoisted_56, [
|
|
1232
|
-
createBaseVNode("p", _hoisted_57, toDisplayString(unref(i18n).baseText("nodeErrorView.details.causeDetailed")), 1),
|
|
1233
|
-
createBaseVNode("pre", _hoisted_58, [
|
|
1234
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.context.causeDetailed), 1)
|
|
1235
|
-
])
|
|
1236
|
-
])) : createCommentVNode("", true),
|
|
1237
|
-
_ctx.error.stack ? (openBlock(), createElementBlock("div", _hoisted_59, [
|
|
1238
|
-
createBaseVNode("p", _hoisted_60, toDisplayString(unref(i18n).baseText("nodeErrorView.details.stackTrace")), 1),
|
|
1239
|
-
createBaseVNode("pre", _hoisted_61, [
|
|
1240
|
-
createBaseVNode("code", null, toDisplayString(_ctx.error.stack), 1)
|
|
1241
|
-
])
|
|
1242
|
-
])) : createCommentVNode("", true)
|
|
1243
|
-
])
|
|
1244
|
-
])
|
|
1245
|
-
])
|
|
1246
|
-
])) : createCommentVNode("", true)
|
|
1247
|
-
], 2);
|
|
1248
|
-
};
|
|
1249
|
-
}
|
|
1250
|
-
});
|
|
1251
|
-
const _hoisted_1$4 = { key: 0 };
|
|
1252
|
-
const _hoisted_2$1 = { key: 1 };
|
|
1253
|
-
const _hoisted_3$1 = { key: 2 };
|
|
1254
|
-
const _hoisted_4$1 = { key: 0 };
|
|
1255
|
-
const _hoisted_5$1 = { key: 1 };
|
|
1256
|
-
const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
1257
|
-
__name: "RunDataPinButton",
|
|
1258
|
-
props: {
|
|
1259
|
-
tooltipContentsVisibility: {},
|
|
1260
|
-
dataPinningDocsUrl: {},
|
|
1261
|
-
pinnedData: {},
|
|
1262
|
-
disabled: { type: Boolean }
|
|
1263
|
-
},
|
|
1264
|
-
emits: ["togglePinData"],
|
|
1265
|
-
setup(__props, { emit: __emit }) {
|
|
1266
|
-
const locale = useI18n();
|
|
1267
|
-
const props = __props;
|
|
1268
|
-
const emit = __emit;
|
|
1269
|
-
const visible = computed(
|
|
1270
|
-
() => props.tooltipContentsVisibility.pinDataDiscoveryTooltipContent ? true : void 0
|
|
1271
|
-
);
|
|
1272
|
-
return (_ctx, _cache) => {
|
|
1273
|
-
return openBlock(), createBlock(unref(N8nTooltip), {
|
|
1274
|
-
placement: "bottom-end",
|
|
1275
|
-
visible: visible.value
|
|
1276
|
-
}, {
|
|
1277
|
-
content: withCtx(() => [
|
|
1278
|
-
props.tooltipContentsVisibility.binaryDataTooltipContent ? (openBlock(), createElementBlock("div", _hoisted_1$4, toDisplayString(unref(locale).baseText("ndv.pinData.pin.binary")), 1)) : props.tooltipContentsVisibility.pinDataDiscoveryTooltipContent ? (openBlock(), createElementBlock("div", _hoisted_2$1, toDisplayString(unref(locale).baseText("node.discovery.pinData.ndv")), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$1, [
|
|
1279
|
-
_ctx.pinnedData.hasData.value ? (openBlock(), createElementBlock("div", _hoisted_4$1, [
|
|
1280
|
-
createBaseVNode("strong", null, toDisplayString(unref(locale).baseText("ndv.pinData.unpin.title")), 1)
|
|
1281
|
-
])) : (openBlock(), createElementBlock("div", _hoisted_5$1, [
|
|
1282
|
-
createBaseVNode("strong", null, toDisplayString(unref(locale).baseText("ndv.pinData.pin.title")), 1),
|
|
1283
|
-
createVNode(unref(N8nText), {
|
|
1284
|
-
size: "small",
|
|
1285
|
-
tag: "p"
|
|
1286
|
-
}, {
|
|
1287
|
-
default: withCtx(() => [
|
|
1288
|
-
createTextVNode(toDisplayString(unref(locale).baseText("ndv.pinData.pin.description")) + " ", 1),
|
|
1289
|
-
createVNode(unref(N8nLink), {
|
|
1290
|
-
to: props.dataPinningDocsUrl,
|
|
1291
|
-
size: "small"
|
|
1292
|
-
}, {
|
|
1293
|
-
default: withCtx(() => [
|
|
1294
|
-
createTextVNode(toDisplayString(unref(locale).baseText("ndv.pinData.pin.link")), 1)
|
|
1295
|
-
]),
|
|
1296
|
-
_: 1
|
|
1297
|
-
}, 8, ["to"])
|
|
1298
|
-
]),
|
|
1299
|
-
_: 1
|
|
1300
|
-
})
|
|
1301
|
-
]))
|
|
1302
|
-
]))
|
|
1303
|
-
]),
|
|
1304
|
-
default: withCtx(() => [
|
|
1305
|
-
createVNode(unref(_sfc_main$b), {
|
|
1306
|
-
class: normalizeClass(_ctx.$style.pinDataButton),
|
|
1307
|
-
type: "tertiary",
|
|
1308
|
-
active: props.pinnedData.hasData.value,
|
|
1309
|
-
icon: "pin",
|
|
1310
|
-
disabled: props.disabled,
|
|
1311
|
-
"data-test-id": "ndv-pin-data",
|
|
1312
|
-
onClick: _cache[0] || (_cache[0] = ($event) => emit("togglePinData"))
|
|
1313
|
-
}, null, 8, ["class", "active", "disabled"])
|
|
1314
|
-
]),
|
|
1315
|
-
_: 1
|
|
1316
|
-
}, 8, ["visible"]);
|
|
1317
|
-
};
|
|
1318
|
-
}
|
|
1319
|
-
});
|
|
1320
|
-
const pinDataButton = "_pinDataButton_12tk2_123";
|
|
1321
|
-
const style0$4 = {
|
|
1322
|
-
pinDataButton
|
|
1323
|
-
};
|
|
1324
|
-
const cssModules$4 = {
|
|
1325
|
-
"$style": style0$4
|
|
1326
|
-
};
|
|
1327
|
-
const RunDataPinButton = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__cssModules", cssModules$4]]);
|
|
1328
|
-
const _hoisted_1$3 = ["href"];
|
|
1329
|
-
const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
1330
|
-
__name: "ViewSubExecution",
|
|
1331
|
-
props: {
|
|
1332
|
-
taskMetadata: {},
|
|
1333
|
-
displayMode: {},
|
|
1334
|
-
inline: { type: Boolean, default: false }
|
|
1335
|
-
},
|
|
1336
|
-
setup(__props) {
|
|
1337
|
-
const { trackOpeningRelatedExecution, resolveRelatedExecutionUrl } = useExecutionHelpers();
|
|
1338
|
-
const i18n = useI18n();
|
|
1339
|
-
const props = __props;
|
|
1340
|
-
const hasRelatedExecution = computed(() => {
|
|
1341
|
-
return Boolean(props.taskMetadata.subExecution ?? props.taskMetadata.parentExecution);
|
|
1342
|
-
});
|
|
1343
|
-
function getExecutionLinkLabel(task) {
|
|
1344
|
-
if (task.parentExecution) {
|
|
1345
|
-
return i18n.baseText("runData.openParentExecution", {
|
|
1346
|
-
interpolate: { id: task.parentExecution.executionId }
|
|
1347
|
-
});
|
|
1348
|
-
}
|
|
1349
|
-
if (task.subExecution) {
|
|
1350
|
-
if (props.taskMetadata.subExecutionsCount === 1) {
|
|
1351
|
-
return i18n.baseText("runData.openSubExecutionSingle");
|
|
1352
|
-
} else {
|
|
1353
|
-
return i18n.baseText("runData.openSubExecutionWithId", {
|
|
1354
|
-
interpolate: { id: task.subExecution.executionId }
|
|
1355
|
-
});
|
|
1356
|
-
}
|
|
1357
|
-
}
|
|
1358
|
-
return;
|
|
1359
|
-
}
|
|
1360
|
-
return (_ctx, _cache) => {
|
|
1361
|
-
const _component_N8nIcon = N8nIcon;
|
|
1362
|
-
return hasRelatedExecution.value ? (openBlock(), createElementBlock("a", {
|
|
1363
|
-
key: 0,
|
|
1364
|
-
class: normalizeClass({ [_ctx.$style.relatedExecutionInfo]: !_ctx.inline }),
|
|
1365
|
-
"data-test-id": "related-execution-link",
|
|
1366
|
-
href: unref(resolveRelatedExecutionUrl)(_ctx.taskMetadata),
|
|
1367
|
-
target: "_blank",
|
|
1368
|
-
onClick: _cache[0] || (_cache[0] = withModifiers(($event) => unref(trackOpeningRelatedExecution)(_ctx.taskMetadata, _ctx.displayMode), ["stop"]))
|
|
1369
|
-
}, [
|
|
1370
|
-
createVNode(_component_N8nIcon, {
|
|
1371
|
-
icon: "external-link",
|
|
1372
|
-
size: "xsmall"
|
|
1373
|
-
}),
|
|
1374
|
-
createTextVNode(" " + toDisplayString(getExecutionLinkLabel(_ctx.taskMetadata)), 1)
|
|
1375
|
-
], 10, _hoisted_1$3)) : createCommentVNode("", true);
|
|
1376
|
-
};
|
|
1377
|
-
}
|
|
1378
|
-
});
|
|
1379
|
-
const relatedExecutionInfo = "_relatedExecutionInfo_saqms_123";
|
|
1380
|
-
const style0$3 = {
|
|
1381
|
-
relatedExecutionInfo
|
|
1382
|
-
};
|
|
1383
|
-
const cssModules$3 = {
|
|
1384
|
-
"$style": style0$3
|
|
1385
|
-
};
|
|
1386
|
-
const ViewSubExecution = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__cssModules", cssModules$3]]);
|
|
1387
|
-
const _hoisted_1$2 = { key: 0 };
|
|
1388
|
-
const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
1389
|
-
__name: "RunDataItemCount",
|
|
1390
|
-
props: {
|
|
1391
|
-
dataCount: {},
|
|
1392
|
-
unfilteredDataCount: {},
|
|
1393
|
-
subExecutionsCount: { default: 0 },
|
|
1394
|
-
search: {}
|
|
1395
|
-
},
|
|
1396
|
-
setup(__props) {
|
|
1397
|
-
const i18n = useI18n();
|
|
1398
|
-
return (_ctx, _cache) => {
|
|
1399
|
-
return _ctx.search ? (openBlock(), createBlock(unref(N8nText), {
|
|
1400
|
-
key: 0,
|
|
1401
|
-
class: normalizeClass(_ctx.$style.itemsText)
|
|
1402
|
-
}, {
|
|
1403
|
-
default: withCtx(() => [
|
|
1404
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.search.items", {
|
|
1405
|
-
adjustToNumber: _ctx.unfilteredDataCount,
|
|
1406
|
-
interpolate: { matched: _ctx.dataCount, count: _ctx.unfilteredDataCount }
|
|
1407
|
-
})), 1)
|
|
1408
|
-
]),
|
|
1409
|
-
_: 1
|
|
1410
|
-
}, 8, ["class"])) : (openBlock(), createBlock(unref(N8nText), {
|
|
1411
|
-
key: 1,
|
|
1412
|
-
class: normalizeClass(_ctx.$style.itemsText)
|
|
1413
|
-
}, {
|
|
1414
|
-
default: withCtx(() => [
|
|
1415
|
-
createBaseVNode("span", null, toDisplayString(unref(i18n).baseText("ndv.output.items", {
|
|
1416
|
-
adjustToNumber: _ctx.dataCount,
|
|
1417
|
-
interpolate: { count: _ctx.dataCount }
|
|
1418
|
-
})), 1),
|
|
1419
|
-
_ctx.subExecutionsCount > 0 ? (openBlock(), createElementBlock("span", _hoisted_1$2, toDisplayString(unref(i18n).baseText("ndv.output.andSubExecutions", {
|
|
1420
|
-
adjustToNumber: _ctx.subExecutionsCount,
|
|
1421
|
-
interpolate: { count: _ctx.subExecutionsCount }
|
|
1422
|
-
})), 1)) : createCommentVNode("", true)
|
|
1423
|
-
]),
|
|
1424
|
-
_: 1
|
|
1425
|
-
}, 8, ["class"]));
|
|
1426
|
-
};
|
|
1427
|
-
}
|
|
1428
|
-
});
|
|
1429
|
-
const itemsText = "_itemsText_1e7yn_123";
|
|
1430
|
-
const style0$2 = {
|
|
1431
|
-
itemsText
|
|
1432
|
-
};
|
|
1433
|
-
const cssModules$2 = {
|
|
1434
|
-
"$style": style0$2
|
|
1435
|
-
};
|
|
1436
|
-
const RunDataItemCount = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__cssModules", cssModules$2]]);
|
|
1437
|
-
const _hoisted_1$1 = { key: 6 };
|
|
1438
|
-
const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
1439
|
-
__name: "RunDataDisplayModeSelect",
|
|
1440
|
-
props: {
|
|
1441
|
-
compact: { type: Boolean },
|
|
1442
|
-
value: {},
|
|
1443
|
-
hasBinaryData: { type: Boolean },
|
|
1444
|
-
paneType: {},
|
|
1445
|
-
nodeGeneratesHtml: { type: Boolean },
|
|
1446
|
-
hasRenderableData: { type: Boolean }
|
|
1447
|
-
},
|
|
1448
|
-
emits: ["change"],
|
|
1449
|
-
setup(__props, { emit: __emit }) {
|
|
1450
|
-
const emit = __emit;
|
|
1451
|
-
const i18n = useI18n();
|
|
1452
|
-
const options = computed(() => {
|
|
1453
|
-
const defaults = [
|
|
1454
|
-
{ label: i18n.baseText("runData.schema"), value: "schema" },
|
|
1455
|
-
{ label: i18n.baseText("runData.table"), value: "table" },
|
|
1456
|
-
{ label: i18n.baseText("runData.json"), value: "json" }
|
|
1457
|
-
];
|
|
1458
|
-
if (__props.hasBinaryData) {
|
|
1459
|
-
defaults.push({ label: i18n.baseText("runData.binary"), value: "binary" });
|
|
1460
|
-
}
|
|
1461
|
-
if (__props.paneType === "output" && __props.nodeGeneratesHtml) {
|
|
1462
|
-
defaults.unshift({ label: "HTML", value: "html" });
|
|
1463
|
-
}
|
|
1464
|
-
if (__props.hasRenderableData) {
|
|
1465
|
-
defaults.unshift({ label: i18n.baseText("runData.rendered"), value: "ai" });
|
|
1466
|
-
}
|
|
1467
|
-
return defaults;
|
|
1468
|
-
});
|
|
1469
|
-
watch(
|
|
1470
|
-
[() => __props.value, options],
|
|
1471
|
-
([val, opts]) => {
|
|
1472
|
-
if (opts.length > 0 && opts.every((opt) => opt.value !== val)) {
|
|
1473
|
-
emit("change", opts[0].value);
|
|
1474
|
-
}
|
|
1475
|
-
},
|
|
1476
|
-
{ immediate: true }
|
|
1477
|
-
);
|
|
1478
|
-
return (_ctx, _cache) => {
|
|
1479
|
-
return openBlock(), createBlock(unref(N8nRadioButtons), {
|
|
1480
|
-
"model-value": _ctx.value,
|
|
1481
|
-
options: options.value,
|
|
1482
|
-
"data-test-id": "ndv-run-data-display-mode",
|
|
1483
|
-
size: _ctx.compact ? "small-medium" : "medium",
|
|
1484
|
-
"square-buttons": _ctx.compact,
|
|
1485
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = (selected) => emit("change", selected))
|
|
1486
|
-
}, createSlots({ _: 2 }, [
|
|
1487
|
-
_ctx.compact ? {
|
|
1488
|
-
name: "option",
|
|
1489
|
-
fn: withCtx((option) => [
|
|
1490
|
-
option.value === "table" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1491
|
-
key: 0,
|
|
1492
|
-
icon: "table",
|
|
1493
|
-
size: "small"
|
|
1494
|
-
})) : option.value === "json" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1495
|
-
key: 1,
|
|
1496
|
-
icon: "json",
|
|
1497
|
-
size: "small"
|
|
1498
|
-
})) : option.value === "binary" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1499
|
-
key: 2,
|
|
1500
|
-
icon: "binary",
|
|
1501
|
-
size: "small"
|
|
1502
|
-
})) : option.value === "schema" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1503
|
-
key: 3,
|
|
1504
|
-
icon: "schema",
|
|
1505
|
-
size: "small"
|
|
1506
|
-
})) : option.value === "html" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1507
|
-
key: 4,
|
|
1508
|
-
icon: "file-code",
|
|
1509
|
-
size: "small"
|
|
1510
|
-
})) : option.value === "ai" ? (openBlock(), createBlock(unref(N8nIcon), {
|
|
1511
|
-
key: 5,
|
|
1512
|
-
icon: "text",
|
|
1513
|
-
size: "small"
|
|
1514
|
-
})) : (openBlock(), createElementBlock("span", _hoisted_1$1, toDisplayString(option.label), 1))
|
|
1515
|
-
]),
|
|
1516
|
-
key: "0"
|
|
1517
|
-
} : void 0
|
|
1518
|
-
]), 1032, ["model-value", "options", "size", "square-buttons"]);
|
|
1519
|
-
};
|
|
1520
|
-
}
|
|
1521
|
-
});
|
|
1522
|
-
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
1523
|
-
__name: "RunDataPaginationBar",
|
|
1524
|
-
props: {
|
|
1525
|
-
pageSize: {},
|
|
1526
|
-
total: {},
|
|
1527
|
-
currentPage: {}
|
|
1528
|
-
},
|
|
1529
|
-
emits: ["update:current-page", "update:page-size"],
|
|
1530
|
-
setup(__props, { emit: __emit }) {
|
|
1531
|
-
const emit = __emit;
|
|
1532
|
-
const i18n = useI18n();
|
|
1533
|
-
const pageSizes = [1, 10, 25, 50, 100];
|
|
1534
|
-
return (_ctx, _cache) => {
|
|
1535
|
-
const _component_el_pagination = resolveComponent("el-pagination");
|
|
1536
|
-
const _component_N8nOption = _sfc_main$c;
|
|
1537
|
-
const _component_N8nSelect = N8nSelect;
|
|
1538
|
-
return openBlock(), createElementBlock("div", {
|
|
1539
|
-
class: normalizeClass(_ctx.$style.pagination),
|
|
1540
|
-
"data-test-id": "ndv-data-pagination"
|
|
1541
|
-
}, [
|
|
1542
|
-
createVNode(_component_el_pagination, {
|
|
1543
|
-
background: "",
|
|
1544
|
-
"hide-on-single-page": true,
|
|
1545
|
-
"current-page": _ctx.currentPage,
|
|
1546
|
-
"pager-count": 5,
|
|
1547
|
-
"page-size": _ctx.pageSize,
|
|
1548
|
-
layout: "prev, pager, next",
|
|
1549
|
-
total: _ctx.total,
|
|
1550
|
-
"onUpdate:currentPage": _cache[0] || (_cache[0] = (value) => emit("update:current-page", value))
|
|
1551
|
-
}, null, 8, ["current-page", "page-size", "total"]),
|
|
1552
|
-
createBaseVNode("div", {
|
|
1553
|
-
class: normalizeClass(_ctx.$style.pageSizeSelector)
|
|
1554
|
-
}, [
|
|
1555
|
-
createVNode(_component_N8nSelect, {
|
|
1556
|
-
size: "mini",
|
|
1557
|
-
"model-value": _ctx.pageSize,
|
|
1558
|
-
teleported: "",
|
|
1559
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = (value) => emit("update:page-size", value))
|
|
1560
|
-
}, {
|
|
1561
|
-
prepend: withCtx(() => [
|
|
1562
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.output.pageSize")), 1)
|
|
1563
|
-
]),
|
|
1564
|
-
default: withCtx(() => [
|
|
1565
|
-
(openBlock(), createElementBlock(Fragment, null, renderList(pageSizes, (size) => {
|
|
1566
|
-
return createVNode(_component_N8nOption, {
|
|
1567
|
-
key: size,
|
|
1568
|
-
label: size,
|
|
1569
|
-
value: size
|
|
1570
|
-
}, null, 8, ["label", "value"]);
|
|
1571
|
-
}), 64)),
|
|
1572
|
-
createVNode(_component_N8nOption, {
|
|
1573
|
-
label: unref(i18n).baseText("ndv.output.all"),
|
|
1574
|
-
value: _ctx.total
|
|
1575
|
-
}, null, 8, ["label", "value"])
|
|
1576
|
-
]),
|
|
1577
|
-
_: 1
|
|
1578
|
-
}, 8, ["model-value"])
|
|
1579
|
-
], 2)
|
|
1580
|
-
], 2);
|
|
1581
|
-
};
|
|
1582
|
-
}
|
|
1583
|
-
});
|
|
1584
|
-
const pagination = "_pagination_1hlvz_123";
|
|
1585
|
-
const pageSizeSelector = "_pageSizeSelector_1hlvz_134";
|
|
1586
|
-
const style0$1 = {
|
|
1587
|
-
pagination,
|
|
1588
|
-
pageSizeSelector
|
|
1589
|
-
};
|
|
1590
|
-
const cssModules$1 = {
|
|
1591
|
-
"$style": style0$1
|
|
1592
|
-
};
|
|
1593
|
-
const RunDataPaginationBar = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__cssModules", cssModules$1]]);
|
|
1594
|
-
const _hoisted_1 = {
|
|
1595
|
-
key: 0,
|
|
1596
|
-
class: "ml-4xs"
|
|
1597
|
-
};
|
|
1598
|
-
const _hoisted_2 = { key: 1 };
|
|
1599
|
-
const _hoisted_3 = { key: 0 };
|
|
1600
|
-
const _hoisted_4 = ["data-test-id"];
|
|
1601
|
-
const _hoisted_5 = { key: 0 };
|
|
1602
|
-
const _hoisted_6 = { key: 1 };
|
|
1603
|
-
const _hoisted_7 = { key: 2 };
|
|
1604
|
-
const _hoisted_8 = { key: 3 };
|
|
1605
|
-
const _hoisted_9 = { key: 4 };
|
|
1606
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
1607
|
-
__name: "RunData",
|
|
1608
|
-
props: {
|
|
1609
|
-
workflow: {},
|
|
1610
|
-
workflowExecution: { default: void 0 },
|
|
1611
|
-
runIndex: {},
|
|
1612
|
-
tooMuchDataTitle: {},
|
|
1613
|
-
executingMessage: {},
|
|
1614
|
-
pushRef: {},
|
|
1615
|
-
paneType: {},
|
|
1616
|
-
displayMode: {},
|
|
1617
|
-
noDataInBranchMessage: {},
|
|
1618
|
-
node: { default: null },
|
|
1619
|
-
nodes: { default: () => [] },
|
|
1620
|
-
linkedRuns: { type: Boolean },
|
|
1621
|
-
canLinkRuns: { type: Boolean },
|
|
1622
|
-
isExecuting: { type: Boolean, default: false },
|
|
1623
|
-
overrideOutputs: { default: void 0 },
|
|
1624
|
-
mappingEnabled: { type: Boolean, default: false },
|
|
1625
|
-
distanceFromActive: { default: 0 },
|
|
1626
|
-
blockUI: { type: Boolean, default: false },
|
|
1627
|
-
isProductionExecutionPreview: { type: Boolean, default: false },
|
|
1628
|
-
isPaneActive: { type: Boolean, default: false },
|
|
1629
|
-
hidePagination: { type: Boolean, default: false },
|
|
1630
|
-
calloutMessage: { default: void 0 },
|
|
1631
|
-
disableRunIndexSelection: { type: Boolean, default: false },
|
|
1632
|
-
disableDisplayModeSelection: { type: Boolean, default: false },
|
|
1633
|
-
disableEdit: { type: Boolean, default: false },
|
|
1634
|
-
disablePin: { type: Boolean, default: false },
|
|
1635
|
-
compact: { type: Boolean, default: false },
|
|
1636
|
-
tableHeaderBgColor: { default: "base" },
|
|
1637
|
-
disableHoverHighlight: { type: Boolean, default: false },
|
|
1638
|
-
disableAiContent: { type: Boolean, default: false },
|
|
1639
|
-
collapsingTableColumnName: {}
|
|
1640
|
-
},
|
|
1641
|
-
emits: ["search", "runChange", "itemHover", "linkRun", "unlinkRun", "activatePane", "tableMounted", "displayModeChange", "collapsingTableColumnChanged"],
|
|
1642
|
-
setup(__props, { expose: __expose, emit: __emit }) {
|
|
1643
|
-
const LazyRunDataTable = defineAsyncComponent(
|
|
1644
|
-
async () => await __vitePreload(() => import("./RunDataTable-DJu8Ut0r.js"), true ? __vite__mapDeps([0,1,2,3,4]) : void 0)
|
|
1645
|
-
);
|
|
1646
|
-
const LazyRunDataJson = defineAsyncComponent(
|
|
1647
|
-
async () => await __vitePreload(() => import("./RunDataJson-12Py20Rs.js"), true ? __vite__mapDeps([5,1,2,6,3,7]) : void 0)
|
|
1648
|
-
);
|
|
1649
|
-
const LazyRunDataSchema = defineAsyncComponent(
|
|
1650
|
-
async () => await __vitePreload(() => import("./index-BmZCxv8-.js").then((n) => n.jr), true ? __vite__mapDeps([1,2]) : void 0)
|
|
1651
|
-
);
|
|
1652
|
-
const LazyRunDataHtml = defineAsyncComponent(
|
|
1653
|
-
async () => await __vitePreload(() => Promise.resolve().then(() => RunDataHtml$1), true ? void 0 : void 0)
|
|
1654
|
-
);
|
|
1655
|
-
const LazyRunDataAi = defineAsyncComponent(
|
|
1656
|
-
async () => await __vitePreload(() => import("./RunDataParsedAiContent-DYz5OPxJ.js").then((n) => n.d), true ? __vite__mapDeps([8,1,2,9,10]) : void 0)
|
|
1657
|
-
);
|
|
1658
|
-
const LazyRunDataSearch = defineAsyncComponent(
|
|
1659
|
-
async () => await __vitePreload(() => import("./RunDataSearch-NmwtxOjZ.js"), true ? __vite__mapDeps([11,1,2,12]) : void 0)
|
|
1660
|
-
);
|
|
1661
|
-
const props = __props;
|
|
1662
|
-
const emit = __emit;
|
|
1663
|
-
const connectionType = ref(NodeConnectionTypes.Main);
|
|
1664
|
-
const dataSize = ref(0);
|
|
1665
|
-
const showData = ref(false);
|
|
1666
|
-
const userEnabledShowData = ref(false);
|
|
1667
|
-
const outputIndex = ref(0);
|
|
1668
|
-
const binaryDataDisplayVisible = ref(false);
|
|
1669
|
-
const binaryDataDisplayData = ref(null);
|
|
1670
|
-
const currentPage = ref(1);
|
|
1671
|
-
const pageSize = ref(10);
|
|
1672
|
-
const pinDataDiscoveryTooltipVisible = ref(false);
|
|
1673
|
-
const isControlledPinDataTooltip = ref(false);
|
|
1674
|
-
const search2 = ref("");
|
|
1675
|
-
const dataContainerRef = ref();
|
|
1676
|
-
const nodeTypesStore = useNodeTypesStore();
|
|
1677
|
-
const ndvStore = useNDVStore();
|
|
1678
|
-
const workflowsStore = useWorkflowsStore();
|
|
1679
|
-
const sourceControlStore = useSourceControlStore();
|
|
1680
|
-
const rootStore = useRootStore();
|
|
1681
|
-
const uiStore = useUIStore();
|
|
1682
|
-
const schemaPreviewStore = useSchemaPreviewStore();
|
|
1683
|
-
const posthogStore = usePostHog();
|
|
1684
|
-
const toast = useToast();
|
|
1685
|
-
const route = useRoute();
|
|
1686
|
-
const nodeHelpers = useNodeHelpers();
|
|
1687
|
-
const externalHooks = useExternalHooks();
|
|
1688
|
-
const telemetry = useTelemetry();
|
|
1689
|
-
const i18n = useI18n();
|
|
1690
|
-
const node = toRef(props, "node");
|
|
1691
|
-
const pinnedData = usePinnedData(node, {
|
|
1692
|
-
runIndex: props.runIndex,
|
|
1693
|
-
displayMode: props.displayMode
|
|
1694
|
-
});
|
|
1695
|
-
const { isSubNodeType } = useNodeType({
|
|
1696
|
-
node
|
|
1697
|
-
});
|
|
1698
|
-
const isArchivedWorkflow = computed(() => workflowsStore.workflow.isArchived);
|
|
1699
|
-
const isReadOnlyRoute = computed(() => route.meta.readOnlyCanvas === true);
|
|
1700
|
-
const isWaitNodeWaiting = computed(() => {
|
|
1701
|
-
return node.value?.name && workflowExecution.value?.resultData?.runData?.[node.value?.name]?.[props.runIndex]?.executionStatus === "waiting";
|
|
1702
|
-
});
|
|
1703
|
-
const { activeNode } = storeToRefs(ndvStore);
|
|
1704
|
-
const nodeType = computed(() => {
|
|
1705
|
-
if (!node.value) return null;
|
|
1706
|
-
return nodeTypesStore.getNodeType(node.value.type, node.value.typeVersion);
|
|
1707
|
-
});
|
|
1708
|
-
const isSchemaView = computed(() => props.displayMode === "schema");
|
|
1709
|
-
const isSearchInSchemaView = computed(() => isSchemaView.value && !!search2.value);
|
|
1710
|
-
const hasMultipleInputNodes = computed(() => props.paneType === "input" && props.nodes.length > 0);
|
|
1711
|
-
const displaysMultipleNodes = computed(() => isSchemaView.value && hasMultipleInputNodes.value);
|
|
1712
|
-
const isTriggerNode = computed(() => !!node.value && nodeTypesStore.isTriggerNode(node.value.type));
|
|
1713
|
-
const canPinData = computed(
|
|
1714
|
-
() => !!node.value && pinnedData.canPinNode(false, currentOutputIndex.value) && !isPaneTypeInput.value && pinnedData.isValidNodeType.value && !(binaryData.value && binaryData.value.length > 0)
|
|
1715
|
-
);
|
|
1716
|
-
const hasNodeRun = computed(
|
|
1717
|
-
() => Boolean(
|
|
1718
|
-
!props.isExecuting && node.value && (workflowRunData.value && workflowRunData.value.hasOwnProperty(node.value.name) || pinnedData.hasData.value)
|
|
1719
|
-
)
|
|
1720
|
-
);
|
|
1721
|
-
const isArtificialRecoveredEventItem = computed(
|
|
1722
|
-
() => rawInputData.value?.[0]?.json?.isArtificialRecoveredEventItem
|
|
1723
|
-
);
|
|
1724
|
-
const isTrimmedManualExecutionDataItem = computed(
|
|
1725
|
-
() => rawInputData.value?.[0]?.json?.[TRIMMED_TASK_DATA_CONNECTIONS_KEY]
|
|
1726
|
-
);
|
|
1727
|
-
const subworkflowExecutionError = computed(() => {
|
|
1728
|
-
if (!node.value) return null;
|
|
1729
|
-
return {
|
|
1730
|
-
node: node.value,
|
|
1731
|
-
messages: [workflowsStore.subWorkflowExecutionError?.message ?? ""]
|
|
1732
|
-
};
|
|
1733
|
-
});
|
|
1734
|
-
const hasSubworkflowExecutionError = computed(() => !!workflowsStore.subWorkflowExecutionError);
|
|
1735
|
-
const parentNodeError = computed(() => {
|
|
1736
|
-
const parentNode = props.workflow.getChildNodes(node.value?.name ?? "", "ALL_NON_MAIN")[0];
|
|
1737
|
-
return workflowRunData.value?.[parentNode]?.[props.runIndex]?.error;
|
|
1738
|
-
});
|
|
1739
|
-
const workflowRunErrorAsNodeError = computed(() => {
|
|
1740
|
-
if (!node.value) {
|
|
1741
|
-
return null;
|
|
1742
|
-
}
|
|
1743
|
-
if (isSubNodeType.value && props.paneType === "input") {
|
|
1744
|
-
return parentNodeError.value;
|
|
1745
|
-
}
|
|
1746
|
-
return workflowRunData.value?.[node.value?.name]?.[props.runIndex]?.error;
|
|
1747
|
-
});
|
|
1748
|
-
const hasRunError = computed(() => Boolean(node.value && workflowRunErrorAsNodeError.value));
|
|
1749
|
-
const executionHints = computed(() => {
|
|
1750
|
-
if (hasNodeRun.value) {
|
|
1751
|
-
const hints = node.value && workflowRunData.value?.[node.value.name]?.[props.runIndex]?.hints;
|
|
1752
|
-
if (hints) return hints;
|
|
1753
|
-
}
|
|
1754
|
-
return [];
|
|
1755
|
-
});
|
|
1756
|
-
const workflowExecution = computed(
|
|
1757
|
-
() => props.workflowExecution ?? workflowsStore.getWorkflowExecution?.data ?? void 0
|
|
1758
|
-
);
|
|
1759
|
-
const workflowRunData = computed(() => {
|
|
1760
|
-
if (workflowExecution.value === void 0) {
|
|
1761
|
-
return null;
|
|
1762
|
-
}
|
|
1763
|
-
const executionData = workflowExecution.value;
|
|
1764
|
-
if (executionData?.resultData) {
|
|
1765
|
-
return executionData.resultData.runData;
|
|
1766
|
-
}
|
|
1767
|
-
return null;
|
|
1768
|
-
});
|
|
1769
|
-
const dataCount = computed(
|
|
1770
|
-
() => getDataCount(props.runIndex, currentOutputIndex.value, connectionType.value)
|
|
1771
|
-
);
|
|
1772
|
-
const unfilteredDataCount = computed(
|
|
1773
|
-
() => pinnedData.data.value ? pinnedData.data.value.length : rawInputData.value.length
|
|
1774
|
-
);
|
|
1775
|
-
const dataSizeInMB = computed(() => (dataSize.value / (1024 * 1024)).toFixed(1));
|
|
1776
|
-
const maxOutputIndex = computed(() => {
|
|
1777
|
-
if (node.value === null || props.runIndex === void 0) {
|
|
1778
|
-
return 0;
|
|
1779
|
-
}
|
|
1780
|
-
const runData = workflowRunData.value;
|
|
1781
|
-
if (!runData?.hasOwnProperty(node.value.name)) {
|
|
1782
|
-
return 0;
|
|
1783
|
-
}
|
|
1784
|
-
if (runData[node.value.name].length < props.runIndex) {
|
|
1785
|
-
return 0;
|
|
1786
|
-
}
|
|
1787
|
-
if (runData[node.value.name][props.runIndex]) {
|
|
1788
|
-
const taskData = runData[node.value.name][props.runIndex].data;
|
|
1789
|
-
if (taskData?.main) {
|
|
1790
|
-
return taskData.main.length - 1;
|
|
1791
|
-
}
|
|
1792
|
-
}
|
|
1793
|
-
return 0;
|
|
1794
|
-
});
|
|
1795
|
-
const currentPageOffset = computed(() => pageSize.value * (currentPage.value - 1));
|
|
1796
|
-
const maxRunIndex = computed(() => {
|
|
1797
|
-
if (!node.value) {
|
|
1798
|
-
return 0;
|
|
1799
|
-
}
|
|
1800
|
-
const runData = workflowRunData.value;
|
|
1801
|
-
if (!runData?.hasOwnProperty(node.value.name)) {
|
|
1802
|
-
return 0;
|
|
1803
|
-
}
|
|
1804
|
-
if (runData[node.value.name].length) {
|
|
1805
|
-
return runData[node.value.name].length - 1;
|
|
1806
|
-
}
|
|
1807
|
-
return 0;
|
|
1808
|
-
});
|
|
1809
|
-
const rawInputData = computed(
|
|
1810
|
-
() => getRawInputData(props.runIndex, currentOutputIndex.value, connectionType.value)
|
|
1811
|
-
);
|
|
1812
|
-
const unfilteredInputData = computed(() => getPinDataOrLiveData(rawInputData.value));
|
|
1813
|
-
const inputData = computed(() => getFilteredData(unfilteredInputData.value));
|
|
1814
|
-
const inputDataPage = computed(() => {
|
|
1815
|
-
const offset = pageSize.value * (currentPage.value - 1);
|
|
1816
|
-
return inputData.value.slice(offset, offset + pageSize.value);
|
|
1817
|
-
});
|
|
1818
|
-
const jsonData = computed(() => executionDataToJson(inputData.value));
|
|
1819
|
-
const binaryData = computed(() => {
|
|
1820
|
-
if (!node.value) {
|
|
1821
|
-
return [];
|
|
1822
|
-
}
|
|
1823
|
-
return nodeHelpers.getBinaryData(workflowRunData.value, node.value.name, props.runIndex, currentOutputIndex.value).filter((data) => Boolean(data && Object.keys(data).length));
|
|
1824
|
-
});
|
|
1825
|
-
const inputHtml = computed(() => String(inputData.value[0]?.json?.html ?? ""));
|
|
1826
|
-
const currentOutputIndex = computed(() => {
|
|
1827
|
-
if (props.overrideOutputs?.length && !props.overrideOutputs.includes(outputIndex.value)) {
|
|
1828
|
-
return props.overrideOutputs[0];
|
|
1829
|
-
}
|
|
1830
|
-
return Math.min(outputIndex.value, maxOutputIndex.value);
|
|
1831
|
-
});
|
|
1832
|
-
const branches = computed(() => {
|
|
1833
|
-
const capitalize = (name) => name.charAt(0).toLocaleUpperCase() + name.slice(1);
|
|
1834
|
-
const result = [];
|
|
1835
|
-
for (let i = 0; i <= maxOutputIndex.value; i++) {
|
|
1836
|
-
if (props.overrideOutputs && !props.overrideOutputs.includes(i)) {
|
|
1837
|
-
continue;
|
|
1838
|
-
}
|
|
1839
|
-
const totalItemsCount = getRawInputData(props.runIndex, i).length;
|
|
1840
|
-
const itemsCount2 = getDataCount(props.runIndex, i);
|
|
1841
|
-
const items = search2.value ? i18n.baseText("ndv.search.items", {
|
|
1842
|
-
adjustToNumber: totalItemsCount,
|
|
1843
|
-
interpolate: { matched: itemsCount2, total: totalItemsCount }
|
|
1844
|
-
}) : i18n.baseText("ndv.output.items", {
|
|
1845
|
-
adjustToNumber: itemsCount2,
|
|
1846
|
-
interpolate: { count: itemsCount2 }
|
|
1847
|
-
});
|
|
1848
|
-
let outputName = getOutputName(i);
|
|
1849
|
-
if (`${outputName}` === `${i}`) {
|
|
1850
|
-
outputName = `${i18n.baseText("ndv.output")} ${outputName}`;
|
|
1851
|
-
} else {
|
|
1852
|
-
const appendBranchWord = NODE_TYPES_EXCLUDED_FROM_OUTPUT_NAME_APPEND.includes(
|
|
1853
|
-
node.value?.type ?? ""
|
|
1854
|
-
) ? "" : ` ${i18n.baseText("ndv.output.branch")}`;
|
|
1855
|
-
outputName = capitalize(`${getOutputName(i)}${appendBranchWord}`);
|
|
1856
|
-
}
|
|
1857
|
-
result.push({
|
|
1858
|
-
label: search2.value && itemsCount2 || totalItemsCount ? `${outputName} (${items})` : outputName,
|
|
1859
|
-
value: i
|
|
1860
|
-
});
|
|
1861
|
-
}
|
|
1862
|
-
return result;
|
|
1863
|
-
});
|
|
1864
|
-
const editMode2 = computed(() => {
|
|
1865
|
-
return isPaneTypeInput.value ? { enabled: false, value: "" } : ndvStore.outputPanelEditMode;
|
|
1866
|
-
});
|
|
1867
|
-
const isPaneTypeInput = computed(() => props.paneType === "input");
|
|
1868
|
-
const isPaneTypeOutput = computed(() => props.paneType === "output");
|
|
1869
|
-
const readOnlyEnv = computed(() => sourceControlStore.preferences.branchReadOnly);
|
|
1870
|
-
const showIOSearch = computed(
|
|
1871
|
-
() => hasNodeRun.value && !hasRunError.value && (unfilteredInputData.value.length > 0 || displaysMultipleNodes.value)
|
|
1872
|
-
);
|
|
1873
|
-
const inputSelectLocation = computed(() => {
|
|
1874
|
-
if (isSchemaView.value) return "none";
|
|
1875
|
-
if (!hasNodeRun.value) return "header";
|
|
1876
|
-
if (maxRunIndex.value > 0) return "runs";
|
|
1877
|
-
if (maxOutputIndex.value > 0 && branches.value.length > 1) {
|
|
1878
|
-
return "outputs";
|
|
1879
|
-
}
|
|
1880
|
-
return "items";
|
|
1881
|
-
});
|
|
1882
|
-
const showIoSearchNoMatchContent = computed(
|
|
1883
|
-
() => hasNodeRun.value && !inputData.value.length && !!search2.value && !displaysMultipleNodes.value
|
|
1884
|
-
);
|
|
1885
|
-
const parentNodeOutputData = computed(() => {
|
|
1886
|
-
const parentNode = props.workflow.getParentNodesByDepth(node.value?.name ?? "")[0];
|
|
1887
|
-
let parentNodeData = [];
|
|
1888
|
-
if (parentNode?.name) {
|
|
1889
|
-
parentNodeData = nodeHelpers.getNodeInputData(
|
|
1890
|
-
props.workflow.getNode(parentNode?.name),
|
|
1891
|
-
props.runIndex,
|
|
1892
|
-
outputIndex.value,
|
|
1893
|
-
"input",
|
|
1894
|
-
connectionType.value
|
|
1895
|
-
);
|
|
1896
|
-
}
|
|
1897
|
-
return parentNodeData;
|
|
1898
|
-
});
|
|
1899
|
-
const parentNodePinnedData = computed(() => {
|
|
1900
|
-
const parentNode = props.workflow.getParentNodesByDepth(node.value?.name ?? "")[0];
|
|
1901
|
-
return props.workflow.pinData?.[parentNode?.name || ""] ?? [];
|
|
1902
|
-
});
|
|
1903
|
-
const showPinButton = computed(() => {
|
|
1904
|
-
if (props.disablePin) {
|
|
1905
|
-
return false;
|
|
1906
|
-
}
|
|
1907
|
-
if (!rawInputData.value.length && !pinnedData.hasData.value) {
|
|
1908
|
-
return false;
|
|
1909
|
-
}
|
|
1910
|
-
if (editMode2.value.enabled) {
|
|
1911
|
-
return false;
|
|
1912
|
-
}
|
|
1913
|
-
if (binaryData.value?.length) {
|
|
1914
|
-
return isPaneTypeOutput.value;
|
|
1915
|
-
}
|
|
1916
|
-
return canPinData.value;
|
|
1917
|
-
});
|
|
1918
|
-
const pinButtonDisabled = computed(
|
|
1919
|
-
() => !rawInputData.value.length && !pinnedData.hasData.value || !!binaryData.value?.length || isReadOnlyRoute.value || readOnlyEnv.value || isArchivedWorkflow.value
|
|
1920
|
-
);
|
|
1921
|
-
const activeTaskMetadata = computed(() => {
|
|
1922
|
-
if (!node.value) {
|
|
1923
|
-
return null;
|
|
1924
|
-
}
|
|
1925
|
-
const errorMetadata = parseErrorMetadata(workflowRunErrorAsNodeError.value);
|
|
1926
|
-
if (errorMetadata !== void 0) {
|
|
1927
|
-
return errorMetadata;
|
|
1928
|
-
}
|
|
1929
|
-
if (parentNodeError.value) {
|
|
1930
|
-
const subNodeMetadata = parseErrorMetadata(parentNodeError.value);
|
|
1931
|
-
if (subNodeMetadata !== void 0) {
|
|
1932
|
-
return subNodeMetadata;
|
|
1933
|
-
}
|
|
1934
|
-
}
|
|
1935
|
-
return workflowRunData.value?.[node.value.name]?.[props.runIndex]?.metadata ?? null;
|
|
1936
|
-
});
|
|
1937
|
-
const hasInputOverwrite = computed(() => {
|
|
1938
|
-
if (!node.value) {
|
|
1939
|
-
return false;
|
|
1940
|
-
}
|
|
1941
|
-
const taskData = nodeHelpers.getNodeTaskData(node.value.name, props.runIndex);
|
|
1942
|
-
return Boolean(taskData?.inputOverride);
|
|
1943
|
-
});
|
|
1944
|
-
const isSchemaPreviewEnabled = computed(
|
|
1945
|
-
() => props.paneType === "input" && !(nodeType.value?.codex?.categories ?? []).some((category) => category === CORE_NODES_CATEGORY)
|
|
1946
|
-
);
|
|
1947
|
-
const isNDVV2 = computed(
|
|
1948
|
-
() => posthogStore.isVariantEnabled(
|
|
1949
|
-
NDV_UI_OVERHAUL_EXPERIMENT.name,
|
|
1950
|
-
NDV_UI_OVERHAUL_EXPERIMENT.variant
|
|
1951
|
-
)
|
|
1952
|
-
);
|
|
1953
|
-
const hasPreviewSchema = computedAsync(async () => {
|
|
1954
|
-
if (!isSchemaPreviewEnabled.value || props.nodes.length === 0) return false;
|
|
1955
|
-
const nodes = props.nodes.filter((n) => n.depth === 1).map((n) => workflowsStore.getNodeByName(n.name)).filter(isPresent);
|
|
1956
|
-
for (const connectedNode of nodes) {
|
|
1957
|
-
const { type, typeVersion, parameters } = connectedNode;
|
|
1958
|
-
const hasPreview = await schemaPreviewStore.getSchemaPreview({
|
|
1959
|
-
nodeType: type,
|
|
1960
|
-
version: typeVersion,
|
|
1961
|
-
resource: parameters.resource,
|
|
1962
|
-
operation: parameters.operation
|
|
1963
|
-
});
|
|
1964
|
-
if (hasPreview.ok) return true;
|
|
1965
|
-
}
|
|
1966
|
-
return false;
|
|
1967
|
-
}, false);
|
|
1968
|
-
const itemsCountProps = computed(() => ({
|
|
1969
|
-
search: search2.value,
|
|
1970
|
-
dataCount: dataCount.value,
|
|
1971
|
-
unfilteredDataCount: unfilteredDataCount.value,
|
|
1972
|
-
subExecutionsCount: activeTaskMetadata.value?.subExecutionsCount
|
|
1973
|
-
}));
|
|
1974
|
-
const parsedAiContent = computed(
|
|
1975
|
-
() => props.disableAiContent ? [] : parseAiContent(rawInputData.value, connectionType.value)
|
|
1976
|
-
);
|
|
1977
|
-
const hasParsedAiContent = computed(
|
|
1978
|
-
() => parsedAiContent.value.some((prr) => prr.parsedContent?.parsed)
|
|
1979
|
-
);
|
|
1980
|
-
function setInputBranchIndex(value) {
|
|
1981
|
-
if (props.paneType === "input") {
|
|
1982
|
-
outputIndex.value = value;
|
|
1983
|
-
}
|
|
1984
|
-
}
|
|
1985
|
-
watch(node, (newNode, prevNode) => {
|
|
1986
|
-
if (newNode?.id === prevNode?.id) return;
|
|
1987
|
-
init();
|
|
1988
|
-
});
|
|
1989
|
-
watch(hasNodeRun, () => {
|
|
1990
|
-
if (props.paneType === "output") setDisplayMode();
|
|
1991
|
-
else {
|
|
1992
|
-
outputIndex.value = determineInitialOutputIndex();
|
|
1993
|
-
}
|
|
1994
|
-
});
|
|
1995
|
-
watch(
|
|
1996
|
-
inputDataPage,
|
|
1997
|
-
(data) => {
|
|
1998
|
-
if (props.paneType && data) {
|
|
1999
|
-
ndvStore.setNDVPanelDataIsEmpty({
|
|
2000
|
-
panel: props.paneType,
|
|
2001
|
-
isEmpty: data.every((item) => isEmpty(item.json))
|
|
2002
|
-
});
|
|
2003
|
-
}
|
|
2004
|
-
},
|
|
2005
|
-
{ immediate: true, deep: true }
|
|
2006
|
-
);
|
|
2007
|
-
watch(jsonData, (data, prevData) => {
|
|
2008
|
-
if (isEqual(data, prevData)) return;
|
|
2009
|
-
refreshDataSize();
|
|
2010
|
-
if (dataCount.value) {
|
|
2011
|
-
resetCurrentPageIfTooFar();
|
|
2012
|
-
}
|
|
2013
|
-
showPinDataDiscoveryTooltip(data);
|
|
2014
|
-
});
|
|
2015
|
-
watch(binaryData, (newData, prevData) => {
|
|
2016
|
-
if (newData.length && !prevData.length && props.displayMode !== "binary") {
|
|
2017
|
-
switchToBinary();
|
|
2018
|
-
} else if (!newData.length && props.displayMode === "binary") {
|
|
2019
|
-
onDisplayModeChange("table");
|
|
2020
|
-
}
|
|
2021
|
-
});
|
|
2022
|
-
watch(currentOutputIndex, (branchIndex) => {
|
|
2023
|
-
ndvStore.setNDVBranchIndex({
|
|
2024
|
-
pane: props.paneType,
|
|
2025
|
-
branchIndex
|
|
2026
|
-
});
|
|
2027
|
-
});
|
|
2028
|
-
watch(search2, (newSearch) => {
|
|
2029
|
-
emit("search", newSearch);
|
|
2030
|
-
});
|
|
2031
|
-
watch(
|
|
2032
|
-
hasParsedAiContent,
|
|
2033
|
-
(hasAiContent) => {
|
|
2034
|
-
if (hasAiContent && props.displayMode !== "ai") {
|
|
2035
|
-
emit("displayModeChange", "ai");
|
|
2036
|
-
}
|
|
2037
|
-
},
|
|
2038
|
-
{ immediate: true }
|
|
2039
|
-
);
|
|
2040
|
-
onMounted(() => {
|
|
2041
|
-
init();
|
|
2042
|
-
ndvEventBus.on("setInputBranchIndex", setInputBranchIndex);
|
|
2043
|
-
if (!isPaneTypeInput.value) {
|
|
2044
|
-
showPinDataDiscoveryTooltip(jsonData.value);
|
|
2045
|
-
}
|
|
2046
|
-
ndvStore.setNDVBranchIndex({
|
|
2047
|
-
pane: props.paneType,
|
|
2048
|
-
branchIndex: currentOutputIndex.value
|
|
2049
|
-
});
|
|
2050
|
-
if (props.paneType === "output") {
|
|
2051
|
-
setDisplayMode();
|
|
2052
|
-
activatePane();
|
|
2053
|
-
}
|
|
2054
|
-
if (hasRunError.value && node.value) {
|
|
2055
|
-
const error = workflowRunData.value?.[node.value.name]?.[props.runIndex]?.error;
|
|
2056
|
-
const errorsToTrack = ["unknown error"];
|
|
2057
|
-
if (error && errorsToTrack.some((e) => error.message?.toLowerCase().includes(e))) {
|
|
2058
|
-
telemetry.track("User encountered an error", {
|
|
2059
|
-
node: node.value.type,
|
|
2060
|
-
errorMessage: error.message,
|
|
2061
|
-
nodeVersion: node.value.typeVersion,
|
|
2062
|
-
n8nVersion: rootStore.versionCli
|
|
2063
|
-
});
|
|
2064
|
-
}
|
|
2065
|
-
}
|
|
2066
|
-
});
|
|
2067
|
-
onBeforeUnmount(() => {
|
|
2068
|
-
hidePinDataDiscoveryTooltip();
|
|
2069
|
-
ndvEventBus.off("setInputBranchIndex", setInputBranchIndex);
|
|
2070
|
-
});
|
|
2071
|
-
function getResolvedNodeOutputs() {
|
|
2072
|
-
if (node.value && nodeType.value) {
|
|
2073
|
-
const workflowNode = props.workflow.getNode(node.value.name);
|
|
2074
|
-
if (workflowNode) {
|
|
2075
|
-
const outputs2 = getNodeOutputs(props.workflow, workflowNode, nodeType.value);
|
|
2076
|
-
return outputs2;
|
|
2077
|
-
}
|
|
2078
|
-
}
|
|
2079
|
-
return [];
|
|
2080
|
-
}
|
|
2081
|
-
function shouldHintBeDisplayed(hint) {
|
|
2082
|
-
const { location, whenToDisplay } = hint;
|
|
2083
|
-
if (location) {
|
|
2084
|
-
if (location === "ndv" && !["input", "output"].includes(props.paneType)) {
|
|
2085
|
-
return false;
|
|
2086
|
-
}
|
|
2087
|
-
if (location === "inputPane" && props.paneType !== "input") {
|
|
2088
|
-
return false;
|
|
2089
|
-
}
|
|
2090
|
-
if (location === "outputPane" && props.paneType !== "output") {
|
|
2091
|
-
return false;
|
|
2092
|
-
}
|
|
2093
|
-
}
|
|
2094
|
-
if (whenToDisplay === "afterExecution" && !hasNodeRun.value) {
|
|
2095
|
-
return false;
|
|
2096
|
-
}
|
|
2097
|
-
if (whenToDisplay === "beforeExecution" && hasNodeRun.value) {
|
|
2098
|
-
return false;
|
|
2099
|
-
}
|
|
2100
|
-
return true;
|
|
2101
|
-
}
|
|
2102
|
-
function getNodeHints() {
|
|
2103
|
-
try {
|
|
2104
|
-
if (node.value && nodeType.value) {
|
|
2105
|
-
const workflowNode = props.workflow.getNode(node.value.name);
|
|
2106
|
-
if (workflowNode) {
|
|
2107
|
-
const nodeHints = nodeHelpers.getNodeHints(props.workflow, workflowNode, nodeType.value, {
|
|
2108
|
-
runExecutionData: workflowExecution.value ?? null,
|
|
2109
|
-
runIndex: props.runIndex,
|
|
2110
|
-
connectionInputData: parentNodeOutputData.value
|
|
2111
|
-
});
|
|
2112
|
-
const hasMultipleInputItems = parentNodeOutputData.value.length > 1 || parentNodePinnedData.value.length > 1;
|
|
2113
|
-
const nodeOutputData = workflowRunData.value?.[node.value.name]?.[props.runIndex]?.data?.main?.[0] ?? [];
|
|
2114
|
-
const genericHints = getGenericHints({
|
|
2115
|
-
workflowNode,
|
|
2116
|
-
node: node.value,
|
|
2117
|
-
nodeType: nodeType.value,
|
|
2118
|
-
nodeOutputData,
|
|
2119
|
-
workflow: props.workflow,
|
|
2120
|
-
hasNodeRun: hasNodeRun.value,
|
|
2121
|
-
hasMultipleInputItems
|
|
2122
|
-
});
|
|
2123
|
-
return executionHints.value.concat(nodeHints, genericHints).filter(shouldHintBeDisplayed);
|
|
2124
|
-
}
|
|
2125
|
-
}
|
|
2126
|
-
} catch (error) {
|
|
2127
|
-
console.error("Error while getting node hints", error);
|
|
2128
|
-
}
|
|
2129
|
-
return [];
|
|
2130
|
-
}
|
|
2131
|
-
function onItemHover(itemIndex) {
|
|
2132
|
-
if (itemIndex === null) {
|
|
2133
|
-
emit("itemHover", null);
|
|
2134
|
-
return;
|
|
2135
|
-
}
|
|
2136
|
-
emit("itemHover", {
|
|
2137
|
-
outputIndex: currentOutputIndex.value,
|
|
2138
|
-
itemIndex
|
|
2139
|
-
});
|
|
2140
|
-
}
|
|
2141
|
-
function onClickDataPinningDocsLink() {
|
|
2142
|
-
telemetry.track("User clicked ndv link", {
|
|
2143
|
-
workflow_id: workflowsStore.workflowId,
|
|
2144
|
-
push_ref: props.pushRef,
|
|
2145
|
-
node_type: activeNode.value?.type,
|
|
2146
|
-
pane: "output",
|
|
2147
|
-
type: "data-pinning-docs"
|
|
2148
|
-
});
|
|
2149
|
-
}
|
|
2150
|
-
function showPinDataDiscoveryTooltip(value) {
|
|
2151
|
-
if (!isTriggerNode.value) {
|
|
2152
|
-
return;
|
|
2153
|
-
}
|
|
2154
|
-
const pinDataDiscoveryFlag = useStorage(LOCAL_STORAGE_PIN_DATA_DISCOVERY_NDV_FLAG).value;
|
|
2155
|
-
if (value && value.length > 0 && !isReadOnlyRoute.value && !isArchivedWorkflow.value && !pinDataDiscoveryFlag) {
|
|
2156
|
-
pinDataDiscoveryComplete();
|
|
2157
|
-
setTimeout(() => {
|
|
2158
|
-
isControlledPinDataTooltip.value = true;
|
|
2159
|
-
pinDataDiscoveryTooltipVisible.value = true;
|
|
2160
|
-
dataPinningEventBus.emit("data-pinning-discovery", { isTooltipVisible: true });
|
|
2161
|
-
}, 500);
|
|
2162
|
-
}
|
|
2163
|
-
}
|
|
2164
|
-
function hidePinDataDiscoveryTooltip() {
|
|
2165
|
-
if (pinDataDiscoveryTooltipVisible.value) {
|
|
2166
|
-
isControlledPinDataTooltip.value = false;
|
|
2167
|
-
pinDataDiscoveryTooltipVisible.value = false;
|
|
2168
|
-
dataPinningEventBus.emit("data-pinning-discovery", { isTooltipVisible: false });
|
|
2169
|
-
}
|
|
2170
|
-
}
|
|
2171
|
-
function pinDataDiscoveryComplete() {
|
|
2172
|
-
useStorage(LOCAL_STORAGE_PIN_DATA_DISCOVERY_NDV_FLAG).value = "true";
|
|
2173
|
-
useStorage(LOCAL_STORAGE_PIN_DATA_DISCOVERY_CANVAS_FLAG).value = "true";
|
|
2174
|
-
}
|
|
2175
|
-
function enterEditMode({ origin }) {
|
|
2176
|
-
const inputData2 = pinnedData.data.value ? clearJsonKey(pinnedData.data.value) : executionDataToJson(rawInputData.value);
|
|
2177
|
-
const inputDataLength = Array.isArray(inputData2) ? inputData2.length : Object.keys(inputData2 ?? {}).length;
|
|
2178
|
-
const data = inputDataLength > 0 ? inputData2 : TEST_PIN_DATA;
|
|
2179
|
-
ndvStore.setOutputPanelEditModeEnabled(true);
|
|
2180
|
-
ndvStore.setOutputPanelEditModeValue(JSON.stringify(data, null, 2));
|
|
2181
|
-
telemetry.track("User opened ndv edit state", {
|
|
2182
|
-
node_type: activeNode.value?.type,
|
|
2183
|
-
click_type: origin === "editIconButton" ? "button" : "link",
|
|
2184
|
-
push_ref: props.pushRef,
|
|
2185
|
-
run_index: props.runIndex,
|
|
2186
|
-
is_output_present: hasNodeRun.value || pinnedData.hasData.value,
|
|
2187
|
-
view: !hasNodeRun.value && !pinnedData.hasData.value ? "undefined" : props.displayMode,
|
|
2188
|
-
is_data_pinned: pinnedData.hasData.value
|
|
2189
|
-
});
|
|
2190
|
-
}
|
|
2191
|
-
function onClickCancelEdit() {
|
|
2192
|
-
ndvStore.setOutputPanelEditModeEnabled(false);
|
|
2193
|
-
ndvStore.setOutputPanelEditModeValue("");
|
|
2194
|
-
onExitEditMode({ type: "cancel" });
|
|
2195
|
-
}
|
|
2196
|
-
function onClickSaveEdit() {
|
|
2197
|
-
if (!node.value) {
|
|
2198
|
-
return;
|
|
2199
|
-
}
|
|
2200
|
-
const { value } = editMode2.value;
|
|
2201
|
-
toast.clearAllStickyNotifications();
|
|
2202
|
-
try {
|
|
2203
|
-
const clearedValue = clearJsonKey(value);
|
|
2204
|
-
try {
|
|
2205
|
-
pinnedData.setData(clearedValue, "save-edit");
|
|
2206
|
-
} catch (error) {
|
|
2207
|
-
return;
|
|
2208
|
-
}
|
|
2209
|
-
} catch (error) {
|
|
2210
|
-
toast.showError(error, i18n.baseText("ndv.pinData.error.syntaxError.title"));
|
|
2211
|
-
return;
|
|
2212
|
-
}
|
|
2213
|
-
ndvStore.setOutputPanelEditModeEnabled(false);
|
|
2214
|
-
onExitEditMode({ type: "save" });
|
|
2215
|
-
}
|
|
2216
|
-
function onExitEditMode({ type }) {
|
|
2217
|
-
telemetry.track("User closed ndv edit state", {
|
|
2218
|
-
node_type: activeNode.value?.type,
|
|
2219
|
-
push_ref: props.pushRef,
|
|
2220
|
-
run_index: props.runIndex,
|
|
2221
|
-
view: props.displayMode,
|
|
2222
|
-
type
|
|
2223
|
-
});
|
|
2224
|
-
}
|
|
2225
|
-
async function onTogglePinData({ source }) {
|
|
2226
|
-
if (!node.value) {
|
|
2227
|
-
return;
|
|
2228
|
-
}
|
|
2229
|
-
if (source === "pin-icon-click") {
|
|
2230
|
-
const telemetryPayload = {
|
|
2231
|
-
node_type: activeNode.value?.type,
|
|
2232
|
-
push_ref: props.pushRef,
|
|
2233
|
-
run_index: props.runIndex,
|
|
2234
|
-
view: !hasNodeRun.value && !pinnedData.hasData.value ? "none" : props.displayMode
|
|
2235
|
-
};
|
|
2236
|
-
void externalHooks.run("runData.onTogglePinData", telemetryPayload);
|
|
2237
|
-
telemetry.track("User clicked pin data icon", telemetryPayload);
|
|
2238
|
-
}
|
|
2239
|
-
nodeHelpers.updateNodeParameterIssues(node.value);
|
|
2240
|
-
if (pinnedData.hasData.value) {
|
|
2241
|
-
pinnedData.unsetData(source);
|
|
2242
|
-
return;
|
|
2243
|
-
}
|
|
2244
|
-
try {
|
|
2245
|
-
pinnedData.setData(rawInputData.value, "pin-icon-click");
|
|
2246
|
-
} catch (error) {
|
|
2247
|
-
console.error(error);
|
|
2248
|
-
return;
|
|
2249
|
-
}
|
|
2250
|
-
if (maxRunIndex.value > 0) {
|
|
2251
|
-
toast.showToast({
|
|
2252
|
-
title: i18n.baseText("ndv.pinData.pin.multipleRuns.title", {
|
|
2253
|
-
interpolate: {
|
|
2254
|
-
index: `${props.runIndex}`
|
|
2255
|
-
}
|
|
2256
|
-
}),
|
|
2257
|
-
message: i18n.baseText("ndv.pinData.pin.multipleRuns.description"),
|
|
2258
|
-
type: "success",
|
|
2259
|
-
duration: 2e3
|
|
2260
|
-
});
|
|
2261
|
-
}
|
|
2262
|
-
hidePinDataDiscoveryTooltip();
|
|
2263
|
-
pinDataDiscoveryComplete();
|
|
2264
|
-
}
|
|
2265
|
-
function switchToBinary() {
|
|
2266
|
-
onDisplayModeChange("binary");
|
|
2267
|
-
}
|
|
2268
|
-
function onBranchChange(value) {
|
|
2269
|
-
outputIndex.value = value;
|
|
2270
|
-
telemetry.track("User changed ndv branch", {
|
|
2271
|
-
push_ref: props.pushRef,
|
|
2272
|
-
branch_index: value,
|
|
2273
|
-
node_type: activeNode.value?.type,
|
|
2274
|
-
node_type_input_selection: nodeType.value ? nodeType.value.name : "",
|
|
2275
|
-
pane: props.paneType
|
|
2276
|
-
});
|
|
2277
|
-
}
|
|
2278
|
-
function showTooMuchData() {
|
|
2279
|
-
showData.value = true;
|
|
2280
|
-
userEnabledShowData.value = true;
|
|
2281
|
-
telemetry.track("User clicked ndv button", {
|
|
2282
|
-
node_type: activeNode.value?.type,
|
|
2283
|
-
workflow_id: workflowsStore.workflowId,
|
|
2284
|
-
push_ref: props.pushRef,
|
|
2285
|
-
pane: props.paneType,
|
|
2286
|
-
type: "showTooMuchData"
|
|
2287
|
-
});
|
|
2288
|
-
}
|
|
2289
|
-
function toggleLinkRuns() {
|
|
2290
|
-
if (props.linkedRuns) {
|
|
2291
|
-
unlinkRun();
|
|
2292
|
-
} else {
|
|
2293
|
-
linkRun();
|
|
2294
|
-
}
|
|
2295
|
-
}
|
|
2296
|
-
function linkRun() {
|
|
2297
|
-
emit("linkRun");
|
|
2298
|
-
}
|
|
2299
|
-
function unlinkRun() {
|
|
2300
|
-
emit("unlinkRun");
|
|
2301
|
-
}
|
|
2302
|
-
function onCurrentPageChange(value) {
|
|
2303
|
-
currentPage.value = value;
|
|
2304
|
-
telemetry.track("User changed ndv page", {
|
|
2305
|
-
node_type: activeNode.value?.type,
|
|
2306
|
-
workflow_id: workflowsStore.workflowId,
|
|
2307
|
-
push_ref: props.pushRef,
|
|
2308
|
-
pane: props.paneType,
|
|
2309
|
-
page_selected: currentPage.value,
|
|
2310
|
-
page_size: pageSize.value,
|
|
2311
|
-
items_total: dataCount.value
|
|
2312
|
-
});
|
|
2313
|
-
}
|
|
2314
|
-
function resetCurrentPageIfTooFar() {
|
|
2315
|
-
const maxPage = Math.ceil(dataCount.value / pageSize.value);
|
|
2316
|
-
if (maxPage < currentPage.value) {
|
|
2317
|
-
currentPage.value = maxPage;
|
|
2318
|
-
}
|
|
2319
|
-
}
|
|
2320
|
-
function onPageSizeChange(newPageSize) {
|
|
2321
|
-
pageSize.value = newPageSize;
|
|
2322
|
-
resetCurrentPageIfTooFar();
|
|
2323
|
-
telemetry.track("User changed ndv page size", {
|
|
2324
|
-
node_type: activeNode.value?.type,
|
|
2325
|
-
workflow_id: workflowsStore.workflowId,
|
|
2326
|
-
push_ref: props.pushRef,
|
|
2327
|
-
pane: props.paneType,
|
|
2328
|
-
page_selected: currentPage.value,
|
|
2329
|
-
page_size: pageSize.value,
|
|
2330
|
-
items_total: dataCount.value
|
|
2331
|
-
});
|
|
2332
|
-
}
|
|
2333
|
-
function onDisplayModeChange(newDisplayMode) {
|
|
2334
|
-
const previous = props.displayMode;
|
|
2335
|
-
emit("displayModeChange", newDisplayMode);
|
|
2336
|
-
if (!userEnabledShowData.value) updateShowData();
|
|
2337
|
-
if (dataContainerRef.value) {
|
|
2338
|
-
const dataDisplay2 = dataContainerRef.value.children[0];
|
|
2339
|
-
if (dataDisplay2) {
|
|
2340
|
-
dataDisplay2.scrollTo(0, 0);
|
|
2341
|
-
}
|
|
2342
|
-
}
|
|
2343
|
-
closeBinaryDataDisplay();
|
|
2344
|
-
void externalHooks.run("runData.displayModeChanged", {
|
|
2345
|
-
newValue: newDisplayMode,
|
|
2346
|
-
oldValue: previous
|
|
2347
|
-
});
|
|
2348
|
-
if (activeNode.value) {
|
|
2349
|
-
telemetry.track("User changed ndv item view", {
|
|
2350
|
-
previous_view: previous,
|
|
2351
|
-
new_view: newDisplayMode,
|
|
2352
|
-
node_type: activeNode.value.type,
|
|
2353
|
-
workflow_id: workflowsStore.workflowId,
|
|
2354
|
-
push_ref: props.pushRef,
|
|
2355
|
-
pane: props.paneType
|
|
2356
|
-
});
|
|
2357
|
-
}
|
|
2358
|
-
}
|
|
2359
|
-
function getRunLabel(option) {
|
|
2360
|
-
if (!node.value) {
|
|
2361
|
-
return;
|
|
2362
|
-
}
|
|
2363
|
-
let itemsCount2 = 0;
|
|
2364
|
-
for (let i = 0; i <= maxOutputIndex.value; i++) {
|
|
2365
|
-
itemsCount2 += getPinDataOrLiveData(getRawInputData(option - 1, i)).length;
|
|
2366
|
-
}
|
|
2367
|
-
const items = i18n.baseText("ndv.output.items", {
|
|
2368
|
-
adjustToNumber: itemsCount2,
|
|
2369
|
-
interpolate: { count: itemsCount2 }
|
|
2370
|
-
});
|
|
2371
|
-
const metadata = workflowRunData.value?.[node.value.name]?.[option - 1]?.metadata ?? null;
|
|
2372
|
-
const subexecutions = metadata?.subExecutionsCount ? i18n.baseText("ndv.output.andSubExecutions", {
|
|
2373
|
-
adjustToNumber: metadata.subExecutionsCount,
|
|
2374
|
-
interpolate: {
|
|
2375
|
-
count: metadata.subExecutionsCount
|
|
2376
|
-
}
|
|
2377
|
-
}) : "";
|
|
2378
|
-
const itemsLabel = itemsCount2 > 0 ? ` (${items}${subexecutions})` : "";
|
|
2379
|
-
return option + i18n.baseText("ndv.output.of") + (maxRunIndex.value + 1) + itemsLabel;
|
|
2380
|
-
}
|
|
2381
|
-
function getRawInputData(runIndex, outputIndex2, connectionType2 = NodeConnectionTypes.Main) {
|
|
2382
|
-
let inputData2 = [];
|
|
2383
|
-
if (node.value) {
|
|
2384
|
-
inputData2 = nodeHelpers.getNodeInputData(
|
|
2385
|
-
node.value,
|
|
2386
|
-
runIndex,
|
|
2387
|
-
outputIndex2,
|
|
2388
|
-
props.paneType,
|
|
2389
|
-
connectionType2,
|
|
2390
|
-
workflowExecution.value
|
|
2391
|
-
);
|
|
2392
|
-
}
|
|
2393
|
-
if (inputData2.length === 0 || !Array.isArray(inputData2)) {
|
|
2394
|
-
return [];
|
|
2395
|
-
}
|
|
2396
|
-
return inputData2;
|
|
2397
|
-
}
|
|
2398
|
-
function getPinDataOrLiveData(data) {
|
|
2399
|
-
if (pinnedData.data.value && !props.isProductionExecutionPreview) {
|
|
2400
|
-
return Array.isArray(pinnedData.data.value) ? pinnedData.data.value.map((value) => ({
|
|
2401
|
-
json: value
|
|
2402
|
-
})) : [
|
|
2403
|
-
{
|
|
2404
|
-
json: pinnedData.data.value
|
|
2405
|
-
}
|
|
2406
|
-
];
|
|
2407
|
-
}
|
|
2408
|
-
return data;
|
|
2409
|
-
}
|
|
2410
|
-
function getFilteredData(data) {
|
|
2411
|
-
if (!search2.value || isSchemaView.value) {
|
|
2412
|
-
return data;
|
|
2413
|
-
}
|
|
2414
|
-
currentPage.value = 1;
|
|
2415
|
-
return data.filter(({ json }) => searchInObject(json, search2.value));
|
|
2416
|
-
}
|
|
2417
|
-
function getDataCount(runIndex, outputIndex2, connectionType2 = NodeConnectionTypes.Main) {
|
|
2418
|
-
if (!node.value) {
|
|
2419
|
-
return 0;
|
|
2420
|
-
}
|
|
2421
|
-
if (workflowRunData.value?.[node.value.name]?.[runIndex]?.hasOwnProperty("error")) {
|
|
2422
|
-
return 1;
|
|
2423
|
-
}
|
|
2424
|
-
const rawInputData2 = getRawInputData(runIndex, outputIndex2, connectionType2);
|
|
2425
|
-
const pinOrLiveData = getPinDataOrLiveData(rawInputData2);
|
|
2426
|
-
return getFilteredData(pinOrLiveData).length;
|
|
2427
|
-
}
|
|
2428
|
-
function determineInitialOutputIndex() {
|
|
2429
|
-
for (let i = 0; i <= maxOutputIndex.value; i++) {
|
|
2430
|
-
if (getRawInputData(props.runIndex, i).length) {
|
|
2431
|
-
return i;
|
|
2432
|
-
}
|
|
2433
|
-
}
|
|
2434
|
-
return 0;
|
|
2435
|
-
}
|
|
2436
|
-
function init() {
|
|
2437
|
-
outputIndex.value = determineInitialOutputIndex();
|
|
2438
|
-
refreshDataSize();
|
|
2439
|
-
closeBinaryDataDisplay();
|
|
2440
|
-
let outputTypes = [];
|
|
2441
|
-
if (node.value && nodeType.value) {
|
|
2442
|
-
const outputs2 = getResolvedNodeOutputs();
|
|
2443
|
-
outputTypes = getConnectionTypes(outputs2);
|
|
2444
|
-
}
|
|
2445
|
-
connectionType.value = outputTypes.length === 0 ? NodeConnectionTypes.Main : outputTypes[0];
|
|
2446
|
-
if (binaryData.value.length > 0) {
|
|
2447
|
-
emit("displayModeChange", "binary");
|
|
2448
|
-
} else if (props.displayMode === "binary") {
|
|
2449
|
-
emit("displayModeChange", "schema");
|
|
2450
|
-
}
|
|
2451
|
-
if (isNDVV2.value) {
|
|
2452
|
-
pageSize.value = RUN_DATA_DEFAULT_PAGE_SIZE;
|
|
2453
|
-
}
|
|
2454
|
-
}
|
|
2455
|
-
function closeBinaryDataDisplay() {
|
|
2456
|
-
binaryDataDisplayVisible.value = false;
|
|
2457
|
-
binaryDataDisplayData.value = null;
|
|
2458
|
-
}
|
|
2459
|
-
function isViewable(index, key) {
|
|
2460
|
-
const { mimeType } = binaryData.value[index][key];
|
|
2461
|
-
return ViewableMimeTypes.includes(mimeType);
|
|
2462
|
-
}
|
|
2463
|
-
function isDownloadable(index, key) {
|
|
2464
|
-
const { mimeType, fileName } = binaryData.value[index][key];
|
|
2465
|
-
return !!(mimeType && fileName);
|
|
2466
|
-
}
|
|
2467
|
-
async function downloadBinaryData(index, key) {
|
|
2468
|
-
const { id, data, fileName, fileExtension, mimeType } = binaryData.value[index][key];
|
|
2469
|
-
if (id) {
|
|
2470
|
-
const url = workflowsStore.getBinaryUrl(id, "download", fileName ?? "", mimeType);
|
|
2471
|
-
FileSaver_minExports.saveAs(url, [fileName, fileExtension].join("."));
|
|
2472
|
-
return;
|
|
2473
|
-
} else {
|
|
2474
|
-
const bufferString = "data:" + mimeType + ";base64," + data;
|
|
2475
|
-
const blob = await fetch(bufferString).then(async (d) => await d.blob());
|
|
2476
|
-
FileSaver_minExports.saveAs(blob, fileName);
|
|
2477
|
-
}
|
|
2478
|
-
}
|
|
2479
|
-
async function downloadJsonData() {
|
|
2480
|
-
const fileName = (node.value?.name ?? "").replace(/[^\w\d]/g, "_");
|
|
2481
|
-
const blob = new Blob([JSON.stringify(rawInputData.value, null, 2)], {
|
|
2482
|
-
type: "application/json"
|
|
2483
|
-
});
|
|
2484
|
-
FileSaver_minExports.saveAs(blob, `${fileName}.json`);
|
|
2485
|
-
}
|
|
2486
|
-
function displayBinaryData(index, key) {
|
|
2487
|
-
const { data, mimeType } = binaryData.value[index][key];
|
|
2488
|
-
binaryDataDisplayVisible.value = true;
|
|
2489
|
-
binaryDataDisplayData.value = {
|
|
2490
|
-
node: node.value?.name,
|
|
2491
|
-
runIndex: props.runIndex,
|
|
2492
|
-
outputIndex: currentOutputIndex.value,
|
|
2493
|
-
index,
|
|
2494
|
-
key,
|
|
2495
|
-
data,
|
|
2496
|
-
mimeType
|
|
2497
|
-
};
|
|
2498
|
-
}
|
|
2499
|
-
function getOutputName(outputIndex2) {
|
|
2500
|
-
if (node.value === null) {
|
|
2501
|
-
return outputIndex2 + 1;
|
|
2502
|
-
}
|
|
2503
|
-
const outputs2 = getResolvedNodeOutputs();
|
|
2504
|
-
const outputConfiguration = outputs2?.[outputIndex2];
|
|
2505
|
-
if (outputConfiguration && isObject(outputConfiguration)) {
|
|
2506
|
-
return outputConfiguration?.displayName;
|
|
2507
|
-
}
|
|
2508
|
-
if (!nodeType.value?.outputNames || nodeType.value.outputNames.length <= outputIndex2) {
|
|
2509
|
-
return outputIndex2 + 1;
|
|
2510
|
-
}
|
|
2511
|
-
return nodeType.value.outputNames[outputIndex2];
|
|
2512
|
-
}
|
|
2513
|
-
function refreshDataSize() {
|
|
2514
|
-
showData.value = false;
|
|
2515
|
-
const jsonItems = inputDataPage.value.map((item) => item.json);
|
|
2516
|
-
const byteSize = new Blob([JSON.stringify(jsonItems)]).size;
|
|
2517
|
-
dataSize.value = byteSize;
|
|
2518
|
-
updateShowData();
|
|
2519
|
-
}
|
|
2520
|
-
function updateShowData() {
|
|
2521
|
-
showData.value = isSchemaView.value && dataSize.value < MAX_DISPLAY_DATA_SIZE_SCHEMA_VIEW || dataSize.value < MAX_DISPLAY_DATA_SIZE;
|
|
2522
|
-
}
|
|
2523
|
-
function onRunIndexChange(run) {
|
|
2524
|
-
emit("runChange", run);
|
|
2525
|
-
}
|
|
2526
|
-
function enableNode() {
|
|
2527
|
-
if (node.value) {
|
|
2528
|
-
const updateInformation = {
|
|
2529
|
-
name: node.value.name,
|
|
2530
|
-
properties: {
|
|
2531
|
-
disabled: !node.value.disabled
|
|
2532
|
-
}
|
|
2533
|
-
};
|
|
2534
|
-
workflowsStore.updateNodeProperties(updateInformation);
|
|
2535
|
-
}
|
|
2536
|
-
}
|
|
2537
|
-
function setDisplayMode() {
|
|
2538
|
-
if (!activeNode.value) return;
|
|
2539
|
-
const shouldDisplayHtml = activeNode.value.type === HTML_NODE_TYPE && activeNode.value.parameters.operation === "generateHtmlTemplate";
|
|
2540
|
-
if (shouldDisplayHtml) {
|
|
2541
|
-
emit("displayModeChange", "html");
|
|
2542
|
-
}
|
|
2543
|
-
}
|
|
2544
|
-
function activatePane() {
|
|
2545
|
-
emit("activatePane");
|
|
2546
|
-
}
|
|
2547
|
-
function onSearchClear() {
|
|
2548
|
-
search2.value = "";
|
|
2549
|
-
document.dispatchEvent(new KeyboardEvent("keyup", { key: "/" }));
|
|
2550
|
-
}
|
|
2551
|
-
__expose({ enterEditMode });
|
|
2552
|
-
return (_ctx, _cache) => {
|
|
2553
|
-
const _directive_n8n_html = resolveDirective("n8n-html");
|
|
2554
|
-
return openBlock(), createElementBlock("div", {
|
|
2555
|
-
class: normalizeClass([
|
|
2556
|
-
"run-data",
|
|
2557
|
-
_ctx.$style.container,
|
|
2558
|
-
{ [_ctx.$style["ndv-v2"]]: isNDVV2.value, [_ctx.$style.compact]: _ctx.compact }
|
|
2559
|
-
]),
|
|
2560
|
-
onMouseover: activatePane
|
|
2561
|
-
}, [
|
|
2562
|
-
!isPaneTypeInput.value && unref(pinnedData).hasData.value && !editMode2.value.enabled && !_ctx.isProductionExecutionPreview ? (openBlock(), createBlock(unref(N8nCallout), {
|
|
2563
|
-
key: 0,
|
|
2564
|
-
theme: "secondary",
|
|
2565
|
-
icon: "pin",
|
|
2566
|
-
class: normalizeClass(_ctx.$style.pinnedDataCallout),
|
|
2567
|
-
"data-test-id": "ndv-pinned-data-callout"
|
|
2568
|
-
}, {
|
|
2569
|
-
trailingContent: withCtx(() => [
|
|
2570
|
-
createVNode(unref(N8nLink), {
|
|
2571
|
-
to: unref(DATA_PINNING_DOCS_URL),
|
|
2572
|
-
size: "small",
|
|
2573
|
-
theme: "secondary",
|
|
2574
|
-
bold: "",
|
|
2575
|
-
underline: "",
|
|
2576
|
-
onClick: onClickDataPinningDocsLink
|
|
2577
|
-
}, {
|
|
2578
|
-
default: withCtx(() => [
|
|
2579
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.pindata.learnMore")), 1)
|
|
2580
|
-
]),
|
|
2581
|
-
_: 1
|
|
2582
|
-
}, 8, ["to"])
|
|
2583
|
-
]),
|
|
2584
|
-
default: withCtx(() => [
|
|
2585
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.pindata.thisDataIsPinned")) + " ", 1),
|
|
2586
|
-
!isReadOnlyRoute.value && !isArchivedWorkflow.value && !readOnlyEnv.value ? (openBlock(), createElementBlock("span", _hoisted_1, [
|
|
2587
|
-
createVNode(unref(N8nLink), {
|
|
2588
|
-
theme: "secondary",
|
|
2589
|
-
size: "small",
|
|
2590
|
-
underline: "",
|
|
2591
|
-
bold: "",
|
|
2592
|
-
"data-test-id": "ndv-unpin-data",
|
|
2593
|
-
onClick: _cache[0] || (_cache[0] = withModifiers(($event) => onTogglePinData({ source: "banner-link" }), ["stop"]))
|
|
2594
|
-
}, {
|
|
2595
|
-
default: withCtx(() => [
|
|
2596
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.pindata.unpin")), 1)
|
|
2597
|
-
]),
|
|
2598
|
-
_: 1
|
|
2599
|
-
})
|
|
2600
|
-
])) : createCommentVNode("", true)
|
|
2601
|
-
]),
|
|
2602
|
-
_: 1
|
|
2603
|
-
}, 8, ["class"])) : createCommentVNode("", true),
|
|
2604
|
-
binaryDataDisplayData.value ? (openBlock(), createBlock(_sfc_main$7, {
|
|
2605
|
-
key: 1,
|
|
2606
|
-
"window-visible": binaryDataDisplayVisible.value,
|
|
2607
|
-
"display-data": binaryDataDisplayData.value,
|
|
2608
|
-
onClose: closeBinaryDataDisplay
|
|
2609
|
-
}, null, 8, ["window-visible", "display-data"])) : createCommentVNode("", true),
|
|
2610
|
-
createBaseVNode("div", {
|
|
2611
|
-
class: normalizeClass(_ctx.$style.header)
|
|
2612
|
-
}, [
|
|
2613
|
-
createBaseVNode("div", {
|
|
2614
|
-
class: normalizeClass(_ctx.$style.title)
|
|
2615
|
-
}, [
|
|
2616
|
-
renderSlot(_ctx.$slots, "header", {}, void 0, true)
|
|
2617
|
-
], 2),
|
|
2618
|
-
withDirectives(createBaseVNode("div", {
|
|
2619
|
-
class: normalizeClass(_ctx.$style.displayModes),
|
|
2620
|
-
"data-test-id": "run-data-pane-header",
|
|
2621
|
-
onClick: _cache[5] || (_cache[5] = withModifiers(() => {
|
|
2622
|
-
}, ["stop"]))
|
|
2623
|
-
}, [
|
|
2624
|
-
(openBlock(), createBlock(Suspense, null, {
|
|
2625
|
-
default: withCtx(() => [
|
|
2626
|
-
showIOSearch.value ? (openBlock(), createBlock(unref(LazyRunDataSearch), {
|
|
2627
|
-
key: 0,
|
|
2628
|
-
modelValue: search2.value,
|
|
2629
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => search2.value = $event),
|
|
2630
|
-
class: normalizeClass(_ctx.$style.search),
|
|
2631
|
-
"pane-type": _ctx.paneType,
|
|
2632
|
-
"display-mode": _ctx.displayMode,
|
|
2633
|
-
"is-area-active": _ctx.isPaneActive,
|
|
2634
|
-
onFocus: activatePane
|
|
2635
|
-
}, null, 8, ["modelValue", "class", "pane-type", "display-mode", "is-area-active"])) : createCommentVNode("", true)
|
|
2636
|
-
]),
|
|
2637
|
-
_: 1
|
|
2638
|
-
})),
|
|
2639
|
-
_ctx.displayMode === "table" && _ctx.collapsingTableColumnName !== null ? (openBlock(), createBlock(unref(_sfc_main$b), {
|
|
2640
|
-
key: 0,
|
|
2641
|
-
class: normalizeClass(_ctx.$style.resetCollapseButton),
|
|
2642
|
-
text: "",
|
|
2643
|
-
icon: "chevrons-up-down",
|
|
2644
|
-
size: "xmini",
|
|
2645
|
-
type: "tertiary",
|
|
2646
|
-
onClick: _cache[2] || (_cache[2] = ($event) => emit("collapsingTableColumnChanged", null))
|
|
2647
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
2648
|
-
!_ctx.disableDisplayModeSelection ? withDirectives((openBlock(), createBlock(_sfc_main$2, {
|
|
2649
|
-
key: 1,
|
|
2650
|
-
compact: props.compact,
|
|
2651
|
-
value: _ctx.displayMode,
|
|
2652
|
-
"has-binary-data": binaryData.value.length > 0,
|
|
2653
|
-
"pane-type": _ctx.paneType,
|
|
2654
|
-
"node-generates-html": unref(activeNode)?.type === unref(HTML_NODE_TYPE) && unref(activeNode).parameters.operation === "generateHtmlTemplate",
|
|
2655
|
-
"has-renderable-data": hasParsedAiContent.value,
|
|
2656
|
-
onChange: onDisplayModeChange
|
|
2657
|
-
}, null, 8, ["compact", "value", "has-binary-data", "pane-type", "node-generates-html", "has-renderable-data"])), [
|
|
2658
|
-
[
|
|
2659
|
-
vShow,
|
|
2660
|
-
unref(hasPreviewSchema) || hasNodeRun.value && (inputData.value.length || binaryData.value.length || search2.value || hasMultipleInputNodes.value) && !editMode2.value.enabled
|
|
2661
|
-
]
|
|
2662
|
-
]) : createCommentVNode("", true),
|
|
2663
|
-
!props.disableEdit && canPinData.value && !isReadOnlyRoute.value && !readOnlyEnv.value ? withDirectives((openBlock(), createBlock(unref(_sfc_main$b), {
|
|
2664
|
-
key: 2,
|
|
2665
|
-
title: unref(i18n).baseText("runData.editOutput"),
|
|
2666
|
-
circle: false,
|
|
2667
|
-
disabled: node.value?.disabled,
|
|
2668
|
-
icon: "pencil",
|
|
2669
|
-
type: "tertiary",
|
|
2670
|
-
"data-test-id": "ndv-edit-pinned-data",
|
|
2671
|
-
onClick: _cache[3] || (_cache[3] = ($event) => enterEditMode({ origin: "editIconButton" }))
|
|
2672
|
-
}, null, 8, ["title", "disabled"])), [
|
|
2673
|
-
[vShow, !editMode2.value.enabled]
|
|
2674
|
-
]) : createCommentVNode("", true),
|
|
2675
|
-
showPinButton.value ? (openBlock(), createBlock(RunDataPinButton, {
|
|
2676
|
-
key: 3,
|
|
2677
|
-
disabled: pinButtonDisabled.value,
|
|
2678
|
-
"tooltip-contents-visibility": {
|
|
2679
|
-
binaryDataTooltipContent: !!binaryData.value?.length,
|
|
2680
|
-
pinDataDiscoveryTooltipContent: isControlledPinDataTooltip.value && pinDataDiscoveryTooltipVisible.value
|
|
2681
|
-
},
|
|
2682
|
-
"data-pinning-docs-url": unref(DATA_PINNING_DOCS_URL),
|
|
2683
|
-
"pinned-data": unref(pinnedData),
|
|
2684
|
-
onTogglePinData: _cache[4] || (_cache[4] = ($event) => onTogglePinData({ source: "pin-icon-click" }))
|
|
2685
|
-
}, null, 8, ["disabled", "tooltip-contents-visibility", "data-pinning-docs-url", "pinned-data"])) : createCommentVNode("", true),
|
|
2686
|
-
!props.disableEdit ? withDirectives((openBlock(), createElementBlock("div", {
|
|
2687
|
-
key: 4,
|
|
2688
|
-
class: normalizeClass(_ctx.$style.editModeActions)
|
|
2689
|
-
}, [
|
|
2690
|
-
createVNode(unref(N8nButton), {
|
|
2691
|
-
type: "tertiary",
|
|
2692
|
-
label: unref(i18n).baseText("runData.editor.cancel"),
|
|
2693
|
-
onClick: onClickCancelEdit
|
|
2694
|
-
}, null, 8, ["label"]),
|
|
2695
|
-
createVNode(unref(N8nButton), {
|
|
2696
|
-
class: "ml-2xs",
|
|
2697
|
-
type: "primary",
|
|
2698
|
-
label: unref(i18n).baseText("runData.editor.save"),
|
|
2699
|
-
onClick: onClickSaveEdit
|
|
2700
|
-
}, null, 8, ["label"])
|
|
2701
|
-
], 2)), [
|
|
2702
|
-
[vShow, editMode2.value.enabled]
|
|
2703
|
-
]) : createCommentVNode("", true)
|
|
2704
|
-
], 2), [
|
|
2705
|
-
[vShow, !hasRunError.value && !isTrimmedManualExecutionDataItem.value]
|
|
2706
|
-
]),
|
|
2707
|
-
props.compact ? (openBlock(), createBlock(RunDataItemCount, normalizeProps(mergeProps({ key: 0 }, itemsCountProps.value)), null, 16)) : createCommentVNode("", true)
|
|
2708
|
-
], 2),
|
|
2709
|
-
inputSelectLocation.value === "header" ? (openBlock(), createElementBlock("div", {
|
|
2710
|
-
key: 2,
|
|
2711
|
-
class: normalizeClass(_ctx.$style.inputSelect)
|
|
2712
|
-
}, [
|
|
2713
|
-
renderSlot(_ctx.$slots, "input-select", {}, void 0, true)
|
|
2714
|
-
], 2)) : createCommentVNode("", true),
|
|
2715
|
-
maxRunIndex.value > 0 && !displaysMultipleNodes.value && !props.disableRunIndexSelection ? withDirectives((openBlock(), createElementBlock("div", {
|
|
2716
|
-
key: 3,
|
|
2717
|
-
class: normalizeClass(_ctx.$style.runSelector)
|
|
2718
|
-
}, [
|
|
2719
|
-
createBaseVNode("div", {
|
|
2720
|
-
class: normalizeClass(_ctx.$style.runSelectorInner)
|
|
2721
|
-
}, [
|
|
2722
|
-
inputSelectLocation.value === "runs" ? renderSlot(_ctx.$slots, "input-select", { key: 0 }, void 0, true) : createCommentVNode("", true),
|
|
2723
|
-
createVNode(unref(N8nSelect), {
|
|
2724
|
-
"model-value": _ctx.runIndex,
|
|
2725
|
-
class: normalizeClass(_ctx.$style.runSelectorSelect),
|
|
2726
|
-
size: "small",
|
|
2727
|
-
teleported: "",
|
|
2728
|
-
"data-test-id": "run-selector",
|
|
2729
|
-
"onUpdate:modelValue": onRunIndexChange,
|
|
2730
|
-
onClick: _cache[6] || (_cache[6] = withModifiers(() => {
|
|
2731
|
-
}, ["stop"]))
|
|
2732
|
-
}, {
|
|
2733
|
-
prepend: withCtx(() => [
|
|
2734
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.output.run")), 1)
|
|
2735
|
-
]),
|
|
2736
|
-
default: withCtx(() => [
|
|
2737
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(maxRunIndex.value + 1, (option) => {
|
|
2738
|
-
return openBlock(), createBlock(unref(_sfc_main$c), {
|
|
2739
|
-
key: option,
|
|
2740
|
-
label: getRunLabel(option),
|
|
2741
|
-
value: option - 1
|
|
2742
|
-
}, null, 8, ["label", "value"]);
|
|
2743
|
-
}), 128))
|
|
2744
|
-
]),
|
|
2745
|
-
_: 1
|
|
2746
|
-
}, 8, ["model-value", "class"]),
|
|
2747
|
-
_ctx.canLinkRuns ? (openBlock(), createBlock(unref(N8nTooltip), {
|
|
2748
|
-
key: 1,
|
|
2749
|
-
placement: "right"
|
|
2750
|
-
}, {
|
|
2751
|
-
content: withCtx(() => [
|
|
2752
|
-
createTextVNode(toDisplayString(unref(i18n).baseText(_ctx.linkedRuns ? "runData.unlinking.hint" : "runData.linking.hint")), 1)
|
|
2753
|
-
]),
|
|
2754
|
-
default: withCtx(() => [
|
|
2755
|
-
createVNode(unref(_sfc_main$b), {
|
|
2756
|
-
icon: _ctx.linkedRuns ? "unlink" : "link",
|
|
2757
|
-
class: normalizeClass(["linkRun", _ctx.linkedRuns ? "linked" : ""]),
|
|
2758
|
-
text: "",
|
|
2759
|
-
type: "tertiary",
|
|
2760
|
-
size: "small",
|
|
2761
|
-
"data-test-id": "link-run",
|
|
2762
|
-
onClick: toggleLinkRuns
|
|
2763
|
-
}, null, 8, ["icon", "class"])
|
|
2764
|
-
]),
|
|
2765
|
-
_: 1
|
|
2766
|
-
})) : createCommentVNode("", true),
|
|
2767
|
-
renderSlot(_ctx.$slots, "run-info", {}, void 0, true)
|
|
2768
|
-
], 2),
|
|
2769
|
-
activeTaskMetadata.value && !(_ctx.paneType === "input" && hasInputOverwrite.value) ? (openBlock(), createBlock(ViewSubExecution, {
|
|
2770
|
-
key: 0,
|
|
2771
|
-
"task-metadata": activeTaskMetadata.value,
|
|
2772
|
-
"display-mode": _ctx.displayMode
|
|
2773
|
-
}, null, 8, ["task-metadata", "display-mode"])) : createCommentVNode("", true)
|
|
2774
|
-
], 2)), [
|
|
2775
|
-
[vShow, !editMode2.value.enabled]
|
|
2776
|
-
]) : createCommentVNode("", true),
|
|
2777
|
-
!displaysMultipleNodes.value ? renderSlot(_ctx.$slots, "before-data", { key: 4 }, void 0, true) : createCommentVNode("", true),
|
|
2778
|
-
props.calloutMessage || _ctx.$slots["callout-message"] ? (openBlock(), createElementBlock("div", {
|
|
2779
|
-
key: 5,
|
|
2780
|
-
class: normalizeClass(_ctx.$style.hintCallout)
|
|
2781
|
-
}, [
|
|
2782
|
-
createVNode(unref(N8nCallout), {
|
|
2783
|
-
theme: "info",
|
|
2784
|
-
"data-test-id": "run-data-callout"
|
|
2785
|
-
}, {
|
|
2786
|
-
default: withCtx(() => [
|
|
2787
|
-
renderSlot(_ctx.$slots, "callout-message", {}, () => [
|
|
2788
|
-
withDirectives(createVNode(unref(N8nText), { size: "small" }, null, 512), [
|
|
2789
|
-
[_directive_n8n_html, props.calloutMessage]
|
|
2790
|
-
])
|
|
2791
|
-
], true)
|
|
2792
|
-
]),
|
|
2793
|
-
_: 3
|
|
2794
|
-
})
|
|
2795
|
-
], 2)) : createCommentVNode("", true),
|
|
2796
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(getNodeHints(), (hint) => {
|
|
2797
|
-
return openBlock(), createBlock(unref(N8nCallout), {
|
|
2798
|
-
key: hint.message,
|
|
2799
|
-
class: normalizeClass(_ctx.$style.hintCallout),
|
|
2800
|
-
theme: hint.type || "info",
|
|
2801
|
-
"data-test-id": "node-hint"
|
|
2802
|
-
}, {
|
|
2803
|
-
default: withCtx(() => [
|
|
2804
|
-
withDirectives(createVNode(unref(N8nText), { size: "small" }, null, 512), [
|
|
2805
|
-
[_directive_n8n_html, hint.message]
|
|
2806
|
-
])
|
|
2807
|
-
]),
|
|
2808
|
-
_: 2
|
|
2809
|
-
}, 1032, ["class", "theme"]);
|
|
2810
|
-
}), 128)),
|
|
2811
|
-
maxOutputIndex.value > 0 && branches.value.length > 1 && !displaysMultipleNodes.value ? (openBlock(), createElementBlock("div", {
|
|
2812
|
-
key: 6,
|
|
2813
|
-
class: normalizeClass(_ctx.$style.outputs),
|
|
2814
|
-
"data-test-id": "branches"
|
|
2815
|
-
}, [
|
|
2816
|
-
inputSelectLocation.value === "outputs" ? renderSlot(_ctx.$slots, "input-select", { key: 0 }, void 0, true) : createCommentVNode("", true),
|
|
2817
|
-
activeTaskMetadata.value && !(_ctx.paneType === "input" && hasInputOverwrite.value) ? (openBlock(), createBlock(ViewSubExecution, {
|
|
2818
|
-
key: 1,
|
|
2819
|
-
"task-metadata": activeTaskMetadata.value,
|
|
2820
|
-
"display-mode": _ctx.displayMode
|
|
2821
|
-
}, null, 8, ["task-metadata", "display-mode"])) : createCommentVNode("", true),
|
|
2822
|
-
createBaseVNode("div", {
|
|
2823
|
-
class: normalizeClass(_ctx.$style.tabs)
|
|
2824
|
-
}, [
|
|
2825
|
-
createVNode(unref(N8nTabs), {
|
|
2826
|
-
size: "small",
|
|
2827
|
-
"model-value": currentOutputIndex.value,
|
|
2828
|
-
options: branches.value,
|
|
2829
|
-
"onUpdate:modelValue": onBranchChange
|
|
2830
|
-
}, null, 8, ["model-value", "options"])
|
|
2831
|
-
], 2)
|
|
2832
|
-
], 2)) : !props.compact && hasNodeRun.value && !isSearchInSchemaView.value && (dataCount.value > 0 && maxRunIndex.value === 0 || search2.value) && !isArtificialRecoveredEventItem.value && !displaysMultipleNodes.value ? withDirectives((openBlock(), createElementBlock("div", {
|
|
2833
|
-
key: 7,
|
|
2834
|
-
class: normalizeClass(_ctx.$style.itemsCount),
|
|
2835
|
-
"data-test-id": "ndv-items-count"
|
|
2836
|
-
}, [
|
|
2837
|
-
inputSelectLocation.value === "items" ? renderSlot(_ctx.$slots, "input-select", { key: 0 }, void 0, true) : createCommentVNode("", true),
|
|
2838
|
-
createVNode(RunDataItemCount, normalizeProps(guardReactiveProps(itemsCountProps.value)), null, 16),
|
|
2839
|
-
activeTaskMetadata.value && !(_ctx.paneType === "input" && hasInputOverwrite.value) ? (openBlock(), createBlock(ViewSubExecution, {
|
|
2840
|
-
key: 1,
|
|
2841
|
-
"task-metadata": activeTaskMetadata.value,
|
|
2842
|
-
"display-mode": _ctx.displayMode
|
|
2843
|
-
}, null, 8, ["task-metadata", "display-mode"])) : createCommentVNode("", true)
|
|
2844
|
-
], 2)), [
|
|
2845
|
-
[vShow, !editMode2.value.enabled]
|
|
2846
|
-
]) : createCommentVNode("", true),
|
|
2847
|
-
createBaseVNode("div", {
|
|
2848
|
-
ref_key: "dataContainerRef",
|
|
2849
|
-
ref: dataContainerRef,
|
|
2850
|
-
class: normalizeClass(_ctx.$style.dataContainer),
|
|
2851
|
-
"data-test-id": "ndv-data-container"
|
|
2852
|
-
}, [
|
|
2853
|
-
_ctx.isExecuting && !isWaitNodeWaiting.value ? (openBlock(), createElementBlock("div", {
|
|
2854
|
-
key: 0,
|
|
2855
|
-
class: normalizeClass([_ctx.$style.center, _ctx.$style.executingMessage]),
|
|
2856
|
-
"data-test-id": "ndv-executing"
|
|
2857
|
-
}, [
|
|
2858
|
-
!props.compact ? (openBlock(), createElementBlock("div", {
|
|
2859
|
-
key: 0,
|
|
2860
|
-
class: normalizeClass(_ctx.$style.spinner)
|
|
2861
|
-
}, [
|
|
2862
|
-
createVNode(unref(_sfc_main$d), { type: "ring" })
|
|
2863
|
-
], 2)) : createCommentVNode("", true),
|
|
2864
|
-
createVNode(unref(N8nText), null, {
|
|
2865
|
-
default: withCtx(() => [
|
|
2866
|
-
createTextVNode(toDisplayString(_ctx.executingMessage), 1)
|
|
2867
|
-
]),
|
|
2868
|
-
_: 1
|
|
2869
|
-
})
|
|
2870
|
-
], 2)) : editMode2.value.enabled ? (openBlock(), createElementBlock("div", {
|
|
2871
|
-
key: 1,
|
|
2872
|
-
class: normalizeClass(_ctx.$style.editMode)
|
|
2873
|
-
}, [
|
|
2874
|
-
createBaseVNode("div", {
|
|
2875
|
-
class: normalizeClass([_ctx.$style.editModeBody, "ignore-key-press-canvas"])
|
|
2876
|
-
}, [
|
|
2877
|
-
createVNode(__unplugin_components_9, {
|
|
2878
|
-
"model-value": editMode2.value.value,
|
|
2879
|
-
"fill-parent": true,
|
|
2880
|
-
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => unref(ndvStore).setOutputPanelEditModeValue($event))
|
|
2881
|
-
}, null, 8, ["model-value"])
|
|
2882
|
-
], 2),
|
|
2883
|
-
createBaseVNode("div", {
|
|
2884
|
-
class: normalizeClass(_ctx.$style.editModeFooter)
|
|
2885
|
-
}, [
|
|
2886
|
-
createVNode(unref(InfoTip), {
|
|
2887
|
-
bold: false,
|
|
2888
|
-
class: normalizeClass(_ctx.$style.editModeFooterInfotip)
|
|
2889
|
-
}, {
|
|
2890
|
-
default: withCtx(() => [
|
|
2891
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.editor.copyDataInfo")) + " ", 1),
|
|
2892
|
-
createVNode(unref(N8nLink), {
|
|
2893
|
-
to: unref(DATA_EDITING_DOCS_URL),
|
|
2894
|
-
size: "small"
|
|
2895
|
-
}, {
|
|
2896
|
-
default: withCtx(() => [
|
|
2897
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("generic.learnMore")), 1)
|
|
2898
|
-
]),
|
|
2899
|
-
_: 1
|
|
2900
|
-
}, 8, ["to"])
|
|
2901
|
-
]),
|
|
2902
|
-
_: 1
|
|
2903
|
-
}, 8, ["class"])
|
|
2904
|
-
], 2)
|
|
2905
|
-
], 2)) : _ctx.paneType === "output" && hasSubworkflowExecutionError.value && subworkflowExecutionError.value ? (openBlock(), createElementBlock("div", {
|
|
2906
|
-
key: 2,
|
|
2907
|
-
class: normalizeClass(_ctx.$style.stretchVertically)
|
|
2908
|
-
}, [
|
|
2909
|
-
createVNode(_sfc_main$6, {
|
|
2910
|
-
compact: _ctx.compact,
|
|
2911
|
-
error: subworkflowExecutionError.value,
|
|
2912
|
-
class: normalizeClass(_ctx.$style.errorDisplay),
|
|
2913
|
-
"show-details": ""
|
|
2914
|
-
}, null, 8, ["compact", "error", "class"])
|
|
2915
|
-
], 2)) : isWaitNodeWaiting.value ? (openBlock(), createElementBlock("div", {
|
|
2916
|
-
key: 3,
|
|
2917
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2918
|
-
}, [
|
|
2919
|
-
renderSlot(_ctx.$slots, "node-waiting", {}, () => [
|
|
2920
|
-
_cache[11] || (_cache[11] = createTextVNode("xxx"))
|
|
2921
|
-
], true)
|
|
2922
|
-
], 2)) : !hasNodeRun.value && !(displaysMultipleNodes.value && (node.value?.disabled || unref(hasPreviewSchema))) ? (openBlock(), createElementBlock("div", {
|
|
2923
|
-
key: 4,
|
|
2924
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2925
|
-
}, [
|
|
2926
|
-
renderSlot(_ctx.$slots, "node-not-run", {}, void 0, true)
|
|
2927
|
-
], 2)) : _ctx.paneType === "input" && !displaysMultipleNodes.value && node.value?.disabled ? (openBlock(), createElementBlock("div", {
|
|
2928
|
-
key: 5,
|
|
2929
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2930
|
-
}, [
|
|
2931
|
-
createVNode(unref(N8nText), null, {
|
|
2932
|
-
default: withCtx(() => [
|
|
2933
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.input.disabled", { interpolate: { nodeName: node.value.name } })) + " ", 1),
|
|
2934
|
-
createVNode(unref(N8nLink), { onClick: enableNode }, {
|
|
2935
|
-
default: withCtx(() => [
|
|
2936
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.input.disabled.cta")), 1)
|
|
2937
|
-
]),
|
|
2938
|
-
_: 1
|
|
2939
|
-
})
|
|
2940
|
-
]),
|
|
2941
|
-
_: 1
|
|
2942
|
-
})
|
|
2943
|
-
], 2)) : isTrimmedManualExecutionDataItem.value && unref(uiStore).isProcessingExecutionResults ? (openBlock(), createElementBlock("div", {
|
|
2944
|
-
key: 6,
|
|
2945
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2946
|
-
}, [
|
|
2947
|
-
createBaseVNode("div", {
|
|
2948
|
-
class: normalizeClass(_ctx.$style.spinner)
|
|
2949
|
-
}, [
|
|
2950
|
-
createVNode(unref(_sfc_main$d), { type: "ring" })
|
|
2951
|
-
], 2),
|
|
2952
|
-
createVNode(unref(N8nText), {
|
|
2953
|
-
color: "text-dark",
|
|
2954
|
-
size: "large"
|
|
2955
|
-
}, {
|
|
2956
|
-
default: withCtx(() => [
|
|
2957
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.trimmedData.loading")), 1)
|
|
2958
|
-
]),
|
|
2959
|
-
_: 1
|
|
2960
|
-
})
|
|
2961
|
-
], 2)) : isTrimmedManualExecutionDataItem.value ? (openBlock(), createElementBlock("div", {
|
|
2962
|
-
key: 7,
|
|
2963
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2964
|
-
}, [
|
|
2965
|
-
createVNode(unref(N8nText), {
|
|
2966
|
-
bold: "",
|
|
2967
|
-
color: "text-dark",
|
|
2968
|
-
size: "large"
|
|
2969
|
-
}, {
|
|
2970
|
-
default: withCtx(() => [
|
|
2971
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.trimmedData.title")), 1)
|
|
2972
|
-
]),
|
|
2973
|
-
_: 1
|
|
2974
|
-
}),
|
|
2975
|
-
createVNode(unref(N8nText), null, {
|
|
2976
|
-
default: withCtx(() => [
|
|
2977
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.trimmedData.message")), 1)
|
|
2978
|
-
]),
|
|
2979
|
-
_: 1
|
|
2980
|
-
})
|
|
2981
|
-
], 2)) : hasNodeRun.value && isArtificialRecoveredEventItem.value ? (openBlock(), createElementBlock("div", {
|
|
2982
|
-
key: 8,
|
|
2983
|
-
class: normalizeClass(_ctx.$style.center)
|
|
2984
|
-
}, [
|
|
2985
|
-
renderSlot(_ctx.$slots, "recovered-artificial-output-data", {}, void 0, true)
|
|
2986
|
-
], 2)) : hasNodeRun.value && hasRunError.value ? (openBlock(), createElementBlock("div", {
|
|
2987
|
-
key: 9,
|
|
2988
|
-
class: normalizeClass(_ctx.$style.stretchVertically)
|
|
2989
|
-
}, [
|
|
2990
|
-
isPaneTypeInput.value ? (openBlock(), createBlock(unref(N8nText), {
|
|
2991
|
-
key: 0,
|
|
2992
|
-
class: normalizeClass(_ctx.$style.center),
|
|
2993
|
-
size: "large",
|
|
2994
|
-
tag: "p",
|
|
2995
|
-
bold: ""
|
|
2996
|
-
}, {
|
|
2997
|
-
default: withCtx(() => [
|
|
2998
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("nodeErrorView.inputPanel.previousNodeError.title", {
|
|
2999
|
-
interpolate: { nodeName: node.value?.name ?? "" }
|
|
3000
|
-
})), 1)
|
|
3001
|
-
]),
|
|
3002
|
-
_: 1
|
|
3003
|
-
}, 8, ["class"])) : _ctx.$slots["content"] ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
3004
|
-
workflowRunErrorAsNodeError.value ? (openBlock(), createBlock(_sfc_main$6, {
|
|
3005
|
-
key: 0,
|
|
3006
|
-
error: workflowRunErrorAsNodeError.value,
|
|
3007
|
-
class: normalizeClass(_ctx.$style.inlineError),
|
|
3008
|
-
compact: _ctx.compact
|
|
3009
|
-
}, null, 8, ["error", "class", "compact"])) : createCommentVNode("", true),
|
|
3010
|
-
renderSlot(_ctx.$slots, "content", {}, void 0, true)
|
|
3011
|
-
])) : workflowRunErrorAsNodeError.value ? (openBlock(), createBlock(_sfc_main$6, {
|
|
3012
|
-
key: 2,
|
|
3013
|
-
error: workflowRunErrorAsNodeError.value,
|
|
3014
|
-
class: normalizeClass(_ctx.$style.dataDisplay),
|
|
3015
|
-
compact: _ctx.compact,
|
|
3016
|
-
"show-details": ""
|
|
3017
|
-
}, null, 8, ["error", "class", "compact"])) : createCommentVNode("", true)
|
|
3018
|
-
], 2)) : hasNodeRun.value && (!unfilteredDataCount.value || search2.value && !dataCount.value) && !displaysMultipleNodes.value && branches.value.length > 1 ? (openBlock(), createElementBlock("div", {
|
|
3019
|
-
key: 10,
|
|
3020
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3021
|
-
}, [
|
|
3022
|
-
search2.value ? (openBlock(), createElementBlock("div", _hoisted_3, [
|
|
3023
|
-
createVNode(unref(N8nText), {
|
|
3024
|
-
tag: "h3",
|
|
3025
|
-
size: "large"
|
|
3026
|
-
}, {
|
|
3027
|
-
default: withCtx(() => [
|
|
3028
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.search.noMatch.title")), 1)
|
|
3029
|
-
]),
|
|
3030
|
-
_: 1
|
|
3031
|
-
}),
|
|
3032
|
-
createVNode(unref(N8nText), null, {
|
|
3033
|
-
default: withCtx(() => [
|
|
3034
|
-
createVNode(unref(I18nT), {
|
|
3035
|
-
keypath: "ndv.search.noMatch.description",
|
|
3036
|
-
tag: "span",
|
|
3037
|
-
scope: "global"
|
|
3038
|
-
}, {
|
|
3039
|
-
link: withCtx(() => [
|
|
3040
|
-
createBaseVNode("a", {
|
|
3041
|
-
href: "#",
|
|
3042
|
-
onClick: onSearchClear
|
|
3043
|
-
}, toDisplayString(unref(i18n).baseText("ndv.search.noMatch.description.link")), 1)
|
|
3044
|
-
]),
|
|
3045
|
-
_: 1
|
|
3046
|
-
})
|
|
3047
|
-
]),
|
|
3048
|
-
_: 1
|
|
3049
|
-
})
|
|
3050
|
-
])) : (openBlock(), createBlock(unref(N8nText), { key: 1 }, {
|
|
3051
|
-
default: withCtx(() => [
|
|
3052
|
-
createTextVNode(toDisplayString(_ctx.noDataInBranchMessage), 1)
|
|
3053
|
-
]),
|
|
3054
|
-
_: 1
|
|
3055
|
-
}))
|
|
3056
|
-
], 2)) : hasNodeRun.value && !inputData.value.length && !displaysMultipleNodes.value && !search2.value ? (openBlock(), createElementBlock("div", {
|
|
3057
|
-
key: 11,
|
|
3058
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3059
|
-
}, [
|
|
3060
|
-
renderSlot(_ctx.$slots, "no-output-data", {}, void 0, true)
|
|
3061
|
-
], 2)) : hasNodeRun.value && !showData.value ? (openBlock(), createElementBlock("div", {
|
|
3062
|
-
key: 12,
|
|
3063
|
-
"data-test-id": "ndv-data-size-warning",
|
|
3064
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3065
|
-
}, [
|
|
3066
|
-
createVNode(unref(N8nText), {
|
|
3067
|
-
bold: true,
|
|
3068
|
-
color: "text-dark",
|
|
3069
|
-
size: "large"
|
|
3070
|
-
}, {
|
|
3071
|
-
default: withCtx(() => [
|
|
3072
|
-
createTextVNode(toDisplayString(_ctx.tooMuchDataTitle), 1)
|
|
3073
|
-
]),
|
|
3074
|
-
_: 1
|
|
3075
|
-
}),
|
|
3076
|
-
createVNode(unref(N8nText), {
|
|
3077
|
-
align: "center",
|
|
3078
|
-
tag: "div"
|
|
3079
|
-
}, {
|
|
3080
|
-
default: withCtx(() => [
|
|
3081
|
-
withDirectives(createBaseVNode("span", null, null, 512), [
|
|
3082
|
-
[
|
|
3083
|
-
_directive_n8n_html,
|
|
3084
|
-
unref(i18n).baseText("ndv.output.tooMuchData.message", {
|
|
3085
|
-
interpolate: { size: dataSizeInMB.value }
|
|
3086
|
-
})
|
|
3087
|
-
]
|
|
3088
|
-
])
|
|
3089
|
-
]),
|
|
3090
|
-
_: 1
|
|
3091
|
-
}),
|
|
3092
|
-
createVNode(unref(N8nButton), {
|
|
3093
|
-
outline: "",
|
|
3094
|
-
label: unref(i18n).baseText("ndv.output.tooMuchData.showDataAnyway"),
|
|
3095
|
-
onClick: showTooMuchData
|
|
3096
|
-
}, null, 8, ["label"]),
|
|
3097
|
-
createVNode(unref(N8nButton), {
|
|
3098
|
-
size: "small",
|
|
3099
|
-
label: unref(i18n).baseText("runData.downloadBinaryData"),
|
|
3100
|
-
onClick: _cache[8] || (_cache[8] = ($event) => downloadJsonData())
|
|
3101
|
-
}, null, 8, ["label"])
|
|
3102
|
-
], 2)) : hasNodeRun.value && _ctx.$slots["content"] ? renderSlot(_ctx.$slots, "content", { key: 13 }, void 0, true) : hasNodeRun.value && _ctx.displayMode === "table" && binaryData.value.length > 0 && inputData.value.length === 1 && Object.keys(jsonData.value[0] || {}).length === 0 ? (openBlock(), createElementBlock("div", {
|
|
3103
|
-
key: 14,
|
|
3104
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3105
|
-
}, [
|
|
3106
|
-
createVNode(unref(N8nText), null, {
|
|
3107
|
-
default: withCtx(() => [
|
|
3108
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.switchToBinary.info")) + " ", 1),
|
|
3109
|
-
createBaseVNode("a", { onClick: switchToBinary }, toDisplayString(unref(i18n).baseText("runData.switchToBinary.binary")), 1)
|
|
3110
|
-
]),
|
|
3111
|
-
_: 1
|
|
3112
|
-
})
|
|
3113
|
-
], 2)) : showIoSearchNoMatchContent.value ? (openBlock(), createElementBlock("div", {
|
|
3114
|
-
key: 15,
|
|
3115
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3116
|
-
}, [
|
|
3117
|
-
createVNode(unref(N8nText), {
|
|
3118
|
-
tag: "h3",
|
|
3119
|
-
size: "large"
|
|
3120
|
-
}, {
|
|
3121
|
-
default: withCtx(() => [
|
|
3122
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("ndv.search.noMatch.title")), 1)
|
|
3123
|
-
]),
|
|
3124
|
-
_: 1
|
|
3125
|
-
}),
|
|
3126
|
-
createVNode(unref(N8nText), null, {
|
|
3127
|
-
default: withCtx(() => [
|
|
3128
|
-
createVNode(unref(I18nT), {
|
|
3129
|
-
keypath: "ndv.search.noMatch.description",
|
|
3130
|
-
tag: "span",
|
|
3131
|
-
scope: "global"
|
|
3132
|
-
}, {
|
|
3133
|
-
link: withCtx(() => [
|
|
3134
|
-
createBaseVNode("a", {
|
|
3135
|
-
href: "#",
|
|
3136
|
-
onClick: onSearchClear
|
|
3137
|
-
}, toDisplayString(unref(i18n).baseText("ndv.search.noMatch.description.link")), 1)
|
|
3138
|
-
]),
|
|
3139
|
-
_: 1
|
|
3140
|
-
})
|
|
3141
|
-
]),
|
|
3142
|
-
_: 1
|
|
3143
|
-
})
|
|
3144
|
-
], 2)) : hasNodeRun.value && _ctx.displayMode === "table" && node.value ? (openBlock(), createBlock(Suspense, { key: 16 }, {
|
|
3145
|
-
default: withCtx(() => [
|
|
3146
|
-
createVNode(unref(LazyRunDataTable), {
|
|
3147
|
-
node: node.value,
|
|
3148
|
-
"input-data": inputDataPage.value,
|
|
3149
|
-
"mapping-enabled": _ctx.mappingEnabled,
|
|
3150
|
-
"distance-from-active": _ctx.distanceFromActive,
|
|
3151
|
-
"run-index": _ctx.runIndex,
|
|
3152
|
-
"page-offset": currentPageOffset.value,
|
|
3153
|
-
"total-runs": maxRunIndex.value,
|
|
3154
|
-
"has-default-hover-state": _ctx.paneType === "input" && !search2.value,
|
|
3155
|
-
search: search2.value,
|
|
3156
|
-
"header-bg-color": _ctx.tableHeaderBgColor,
|
|
3157
|
-
compact: props.compact,
|
|
3158
|
-
"disable-hover-highlight": props.disableHoverHighlight,
|
|
3159
|
-
"collapsing-column-name": _ctx.collapsingTableColumnName,
|
|
3160
|
-
onMounted: _cache[9] || (_cache[9] = ($event) => emit("tableMounted", $event)),
|
|
3161
|
-
onActiveRowChanged: onItemHover,
|
|
3162
|
-
onDisplayModeChange,
|
|
3163
|
-
onCollapsingColumnChanged: _cache[10] || (_cache[10] = ($event) => emit("collapsingTableColumnChanged", $event))
|
|
3164
|
-
}, null, 8, ["node", "input-data", "mapping-enabled", "distance-from-active", "run-index", "page-offset", "total-runs", "has-default-hover-state", "search", "header-bg-color", "compact", "disable-hover-highlight", "collapsing-column-name"])
|
|
3165
|
-
]),
|
|
3166
|
-
_: 1
|
|
3167
|
-
})) : hasNodeRun.value && _ctx.displayMode === "json" && node.value ? (openBlock(), createBlock(Suspense, { key: 17 }, {
|
|
3168
|
-
default: withCtx(() => [
|
|
3169
|
-
createVNode(unref(LazyRunDataJson), {
|
|
3170
|
-
"pane-type": _ctx.paneType,
|
|
3171
|
-
"edit-mode": editMode2.value,
|
|
3172
|
-
"push-ref": _ctx.pushRef,
|
|
3173
|
-
node: node.value,
|
|
3174
|
-
"input-data": inputDataPage.value,
|
|
3175
|
-
"mapping-enabled": _ctx.mappingEnabled,
|
|
3176
|
-
"distance-from-active": _ctx.distanceFromActive,
|
|
3177
|
-
"run-index": _ctx.runIndex,
|
|
3178
|
-
"output-index": currentOutputIndex.value,
|
|
3179
|
-
"total-runs": maxRunIndex.value,
|
|
3180
|
-
search: search2.value,
|
|
3181
|
-
compact: props.compact
|
|
3182
|
-
}, null, 8, ["pane-type", "edit-mode", "push-ref", "node", "input-data", "mapping-enabled", "distance-from-active", "run-index", "output-index", "total-runs", "search", "compact"])
|
|
3183
|
-
]),
|
|
3184
|
-
_: 1
|
|
3185
|
-
})) : hasNodeRun.value && isPaneTypeOutput.value && _ctx.displayMode === "html" ? (openBlock(), createBlock(Suspense, { key: 18 }, {
|
|
3186
|
-
default: withCtx(() => [
|
|
3187
|
-
createVNode(unref(LazyRunDataHtml), { "input-html": inputHtml.value }, null, 8, ["input-html"])
|
|
3188
|
-
]),
|
|
3189
|
-
_: 1
|
|
3190
|
-
})) : hasNodeRun.value && _ctx.displayMode === "ai" ? (openBlock(), createBlock(Suspense, { key: 19 }, {
|
|
3191
|
-
default: withCtx(() => [
|
|
3192
|
-
createVNode(unref(LazyRunDataAi), {
|
|
3193
|
-
"render-type": "rendered",
|
|
3194
|
-
compact: _ctx.compact,
|
|
3195
|
-
content: parsedAiContent.value,
|
|
3196
|
-
search: search2.value
|
|
3197
|
-
}, null, 8, ["compact", "content", "search"])
|
|
3198
|
-
]),
|
|
3199
|
-
_: 1
|
|
3200
|
-
})) : (hasNodeRun.value || unref(hasPreviewSchema)) && isSchemaView.value ? (openBlock(), createBlock(Suspense, { key: 20 }, {
|
|
3201
|
-
default: withCtx(() => [
|
|
3202
|
-
createVNode(unref(LazyRunDataSchema), {
|
|
3203
|
-
nodes: _ctx.nodes,
|
|
3204
|
-
"mapping-enabled": _ctx.mappingEnabled,
|
|
3205
|
-
node: node.value,
|
|
3206
|
-
data: jsonData.value,
|
|
3207
|
-
"pane-type": _ctx.paneType,
|
|
3208
|
-
"connection-type": connectionType.value,
|
|
3209
|
-
"output-index": currentOutputIndex.value,
|
|
3210
|
-
search: search2.value,
|
|
3211
|
-
class: normalizeClass(_ctx.$style.schema),
|
|
3212
|
-
compact: props.compact,
|
|
3213
|
-
"onClear:search": onSearchClear
|
|
3214
|
-
}, null, 8, ["nodes", "mapping-enabled", "node", "data", "pane-type", "connection-type", "output-index", "search", "class", "compact"])
|
|
3215
|
-
]),
|
|
3216
|
-
_: 1
|
|
3217
|
-
})) : _ctx.displayMode === "binary" && binaryData.value.length === 0 ? (openBlock(), createElementBlock("div", {
|
|
3218
|
-
key: 21,
|
|
3219
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3220
|
-
}, [
|
|
3221
|
-
createVNode(unref(N8nText), {
|
|
3222
|
-
align: "center",
|
|
3223
|
-
tag: "div"
|
|
3224
|
-
}, {
|
|
3225
|
-
default: withCtx(() => [
|
|
3226
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.noBinaryDataFound")), 1)
|
|
3227
|
-
]),
|
|
3228
|
-
_: 1
|
|
3229
|
-
})
|
|
3230
|
-
], 2)) : _ctx.displayMode === "binary" ? (openBlock(), createElementBlock("div", {
|
|
3231
|
-
key: 22,
|
|
3232
|
-
class: normalizeClass(_ctx.$style.dataDisplay)
|
|
3233
|
-
}, [
|
|
3234
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(binaryData.value, (binaryDataEntry, index) => {
|
|
3235
|
-
return openBlock(), createElementBlock("div", { key: index }, [
|
|
3236
|
-
binaryData.value.length > 1 ? (openBlock(), createElementBlock("div", {
|
|
3237
|
-
key: 0,
|
|
3238
|
-
class: normalizeClass(_ctx.$style.binaryIndex)
|
|
3239
|
-
}, [
|
|
3240
|
-
createBaseVNode("div", null, toDisplayString(index + 1), 1)
|
|
3241
|
-
], 2)) : createCommentVNode("", true),
|
|
3242
|
-
createBaseVNode("div", {
|
|
3243
|
-
class: normalizeClass(_ctx.$style.binaryRow)
|
|
3244
|
-
}, [
|
|
3245
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(binaryDataEntry, (binaryData2, key) => {
|
|
3246
|
-
return openBlock(), createElementBlock("div", {
|
|
3247
|
-
key: index + "_" + key,
|
|
3248
|
-
class: normalizeClass(_ctx.$style.binaryCell)
|
|
3249
|
-
}, [
|
|
3250
|
-
createBaseVNode("div", {
|
|
3251
|
-
"data-test-id": "ndv-binary-data_" + index
|
|
3252
|
-
}, [
|
|
3253
|
-
createBaseVNode("div", {
|
|
3254
|
-
class: normalizeClass(_ctx.$style.binaryHeader)
|
|
3255
|
-
}, toDisplayString(key), 3),
|
|
3256
|
-
binaryData2.fileName ? (openBlock(), createElementBlock("div", _hoisted_5, [
|
|
3257
|
-
createBaseVNode("div", null, [
|
|
3258
|
-
createVNode(unref(N8nText), {
|
|
3259
|
-
size: "small",
|
|
3260
|
-
bold: true
|
|
3261
|
-
}, {
|
|
3262
|
-
default: withCtx(() => [
|
|
3263
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.fileName")) + ": ", 1)
|
|
3264
|
-
]),
|
|
3265
|
-
_: 1
|
|
3266
|
-
})
|
|
3267
|
-
]),
|
|
3268
|
-
createBaseVNode("div", {
|
|
3269
|
-
class: normalizeClass(_ctx.$style.binaryValue)
|
|
3270
|
-
}, toDisplayString(binaryData2.fileName), 3)
|
|
3271
|
-
])) : createCommentVNode("", true),
|
|
3272
|
-
binaryData2.directory ? (openBlock(), createElementBlock("div", _hoisted_6, [
|
|
3273
|
-
createBaseVNode("div", null, [
|
|
3274
|
-
createVNode(unref(N8nText), {
|
|
3275
|
-
size: "small",
|
|
3276
|
-
bold: true
|
|
3277
|
-
}, {
|
|
3278
|
-
default: withCtx(() => [
|
|
3279
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.directory")) + ": ", 1)
|
|
3280
|
-
]),
|
|
3281
|
-
_: 1
|
|
3282
|
-
})
|
|
3283
|
-
]),
|
|
3284
|
-
createBaseVNode("div", {
|
|
3285
|
-
class: normalizeClass(_ctx.$style.binaryValue)
|
|
3286
|
-
}, toDisplayString(binaryData2.directory), 3)
|
|
3287
|
-
])) : createCommentVNode("", true),
|
|
3288
|
-
binaryData2.fileExtension ? (openBlock(), createElementBlock("div", _hoisted_7, [
|
|
3289
|
-
createBaseVNode("div", null, [
|
|
3290
|
-
createVNode(unref(N8nText), {
|
|
3291
|
-
size: "small",
|
|
3292
|
-
bold: true
|
|
3293
|
-
}, {
|
|
3294
|
-
default: withCtx(() => [
|
|
3295
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.fileExtension")) + ":", 1)
|
|
3296
|
-
]),
|
|
3297
|
-
_: 1
|
|
3298
|
-
})
|
|
3299
|
-
]),
|
|
3300
|
-
createBaseVNode("div", {
|
|
3301
|
-
class: normalizeClass(_ctx.$style.binaryValue)
|
|
3302
|
-
}, toDisplayString(binaryData2.fileExtension), 3)
|
|
3303
|
-
])) : createCommentVNode("", true),
|
|
3304
|
-
binaryData2.mimeType ? (openBlock(), createElementBlock("div", _hoisted_8, [
|
|
3305
|
-
createBaseVNode("div", null, [
|
|
3306
|
-
createVNode(unref(N8nText), {
|
|
3307
|
-
size: "small",
|
|
3308
|
-
bold: true
|
|
3309
|
-
}, {
|
|
3310
|
-
default: withCtx(() => [
|
|
3311
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.mimeType")) + ": ", 1)
|
|
3312
|
-
]),
|
|
3313
|
-
_: 1
|
|
3314
|
-
})
|
|
3315
|
-
]),
|
|
3316
|
-
createBaseVNode("div", {
|
|
3317
|
-
class: normalizeClass(_ctx.$style.binaryValue)
|
|
3318
|
-
}, toDisplayString(binaryData2.mimeType), 3)
|
|
3319
|
-
])) : createCommentVNode("", true),
|
|
3320
|
-
binaryData2.fileSize ? (openBlock(), createElementBlock("div", _hoisted_9, [
|
|
3321
|
-
createBaseVNode("div", null, [
|
|
3322
|
-
createVNode(unref(N8nText), {
|
|
3323
|
-
size: "small",
|
|
3324
|
-
bold: true
|
|
3325
|
-
}, {
|
|
3326
|
-
default: withCtx(() => [
|
|
3327
|
-
createTextVNode(toDisplayString(unref(i18n).baseText("runData.fileSize")) + ": ", 1)
|
|
3328
|
-
]),
|
|
3329
|
-
_: 1
|
|
3330
|
-
})
|
|
3331
|
-
]),
|
|
3332
|
-
createBaseVNode("div", {
|
|
3333
|
-
class: normalizeClass(_ctx.$style.binaryValue)
|
|
3334
|
-
}, toDisplayString(binaryData2.fileSize), 3)
|
|
3335
|
-
])) : createCommentVNode("", true),
|
|
3336
|
-
createBaseVNode("div", {
|
|
3337
|
-
class: normalizeClass(_ctx.$style.binaryButtonContainer)
|
|
3338
|
-
}, [
|
|
3339
|
-
isViewable(index, key) ? (openBlock(), createBlock(unref(N8nButton), {
|
|
3340
|
-
key: 0,
|
|
3341
|
-
size: "small",
|
|
3342
|
-
label: unref(i18n).baseText("runData.showBinaryData"),
|
|
3343
|
-
"data-test-id": "ndv-view-binary-data",
|
|
3344
|
-
onClick: ($event) => displayBinaryData(index, key)
|
|
3345
|
-
}, null, 8, ["label", "onClick"])) : createCommentVNode("", true),
|
|
3346
|
-
isDownloadable(index, key) ? (openBlock(), createBlock(unref(N8nButton), {
|
|
3347
|
-
key: 1,
|
|
3348
|
-
size: "small",
|
|
3349
|
-
type: "secondary",
|
|
3350
|
-
label: unref(i18n).baseText("runData.downloadBinaryData"),
|
|
3351
|
-
"data-test-id": "ndv-download-binary-data",
|
|
3352
|
-
onClick: ($event) => downloadBinaryData(index, key)
|
|
3353
|
-
}, null, 8, ["label", "onClick"])) : createCommentVNode("", true)
|
|
3354
|
-
], 2)
|
|
3355
|
-
], 8, _hoisted_4)
|
|
3356
|
-
], 2);
|
|
3357
|
-
}), 128))
|
|
3358
|
-
], 2)
|
|
3359
|
-
]);
|
|
3360
|
-
}), 128))
|
|
3361
|
-
], 2)) : !hasNodeRun.value ? (openBlock(), createElementBlock("div", {
|
|
3362
|
-
key: 23,
|
|
3363
|
-
class: normalizeClass(_ctx.$style.center)
|
|
3364
|
-
}, [
|
|
3365
|
-
renderSlot(_ctx.$slots, "node-not-run", {}, void 0, true)
|
|
3366
|
-
], 2)) : createCommentVNode("", true)
|
|
3367
|
-
], 2),
|
|
3368
|
-
_ctx.hidePagination === false && hasNodeRun.value && !hasRunError.value && _ctx.displayMode !== "binary" && dataCount.value > pageSize.value && !isSchemaView.value && !isArtificialRecoveredEventItem.value ? withDirectives((openBlock(), createBlock(RunDataPaginationBar, {
|
|
3369
|
-
key: 8,
|
|
3370
|
-
"current-page": currentPage.value,
|
|
3371
|
-
"page-size": pageSize.value,
|
|
3372
|
-
total: dataCount.value,
|
|
3373
|
-
"onUpdate:currentPage": onCurrentPageChange,
|
|
3374
|
-
"onUpdate:pageSize": onPageSizeChange
|
|
3375
|
-
}, null, 8, ["current-page", "page-size", "total"])), [
|
|
3376
|
-
[vShow, !editMode2.value.enabled]
|
|
3377
|
-
]) : createCommentVNode("", true),
|
|
3378
|
-
createVNode(unref(N8nBlockUi), {
|
|
3379
|
-
show: _ctx.blockUI,
|
|
3380
|
-
class: normalizeClass(_ctx.$style.uiBlocker)
|
|
3381
|
-
}, null, 8, ["show", "class"])
|
|
3382
|
-
], 34);
|
|
3383
|
-
};
|
|
3384
|
-
}
|
|
3385
|
-
});
|
|
3386
|
-
const infoIcon = "_infoIcon_1btpo_123";
|
|
3387
|
-
const center = "_center_1btpo_127";
|
|
3388
|
-
const container = "_container_1btpo_141";
|
|
3389
|
-
const pinnedDataCallout = "_pinnedDataCallout_1btpo_150";
|
|
3390
|
-
const header = "_header_1btpo_158";
|
|
3391
|
-
const compact = "_compact_1btpo_170";
|
|
3392
|
-
const dataContainer = "_dataContainer_1btpo_183";
|
|
3393
|
-
const dataDisplay = "_dataDisplay_1btpo_189";
|
|
3394
|
-
const inlineError = "_inlineError_1btpo_204";
|
|
3395
|
-
const outputs = "_outputs_1btpo_211";
|
|
3396
|
-
const tabs = "_tabs_1btpo_226";
|
|
3397
|
-
const itemsCount = "_itemsCount_1btpo_234";
|
|
3398
|
-
const inputSelect = "_inputSelect_1btpo_248";
|
|
3399
|
-
const runSelector = "_runSelector_1btpo_254";
|
|
3400
|
-
const runSelectorInner = "_runSelectorInner_1btpo_267";
|
|
3401
|
-
const runSelectorSelect = "_runSelectorSelect_1btpo_273";
|
|
3402
|
-
const search = "_search_1btpo_277";
|
|
3403
|
-
const binaryIndex = "_binaryIndex_1btpo_281";
|
|
3404
|
-
const binaryRow = "_binaryRow_1btpo_298";
|
|
3405
|
-
const binaryCell = "_binaryCell_1btpo_303";
|
|
3406
|
-
const binaryHeader = "_binaryHeader_1btpo_315";
|
|
3407
|
-
const binaryButtonContainer = "_binaryButtonContainer_1btpo_324";
|
|
3408
|
-
const binaryValue = "_binaryValue_1btpo_335";
|
|
3409
|
-
const displayModes = "_displayModes_1btpo_340";
|
|
3410
|
-
const tooltipContain = "_tooltipContain_1btpo_359";
|
|
3411
|
-
const spinner = "_spinner_1btpo_363";
|
|
3412
|
-
const editMode = "_editMode_1btpo_374";
|
|
3413
|
-
const editModeBody = "_editModeBody_1btpo_383";
|
|
3414
|
-
const editModeFooter = "_editModeFooter_1btpo_390";
|
|
3415
|
-
const editModeFooterInfotip = "_editModeFooterInfotip_1btpo_400";
|
|
3416
|
-
const editModeActions = "_editModeActions_1btpo_406";
|
|
3417
|
-
const stretchVertically = "_stretchVertically_1btpo_413";
|
|
3418
|
-
const uiBlocker = "_uiBlocker_1btpo_417";
|
|
3419
|
-
const hintCallout = "_hintCallout_1btpo_422";
|
|
3420
|
-
const schema = "_schema_1btpo_431";
|
|
3421
|
-
const executingMessage = "_executingMessage_1btpo_435";
|
|
3422
|
-
const resetCollapseButton = "_resetCollapseButton_1btpo_439";
|
|
3423
|
-
const title = "_title_1btpo_445";
|
|
3424
|
-
const style0 = {
|
|
3425
|
-
infoIcon,
|
|
3426
|
-
center,
|
|
3427
|
-
container,
|
|
3428
|
-
pinnedDataCallout,
|
|
3429
|
-
header,
|
|
3430
|
-
compact,
|
|
3431
|
-
dataContainer,
|
|
3432
|
-
dataDisplay,
|
|
3433
|
-
inlineError,
|
|
3434
|
-
outputs,
|
|
3435
|
-
tabs,
|
|
3436
|
-
itemsCount,
|
|
3437
|
-
"ndv-v2": "_ndv-v2_1btpo_244",
|
|
3438
|
-
inputSelect,
|
|
3439
|
-
runSelector,
|
|
3440
|
-
runSelectorInner,
|
|
3441
|
-
runSelectorSelect,
|
|
3442
|
-
search,
|
|
3443
|
-
binaryIndex,
|
|
3444
|
-
binaryRow,
|
|
3445
|
-
binaryCell,
|
|
3446
|
-
binaryHeader,
|
|
3447
|
-
binaryButtonContainer,
|
|
3448
|
-
binaryValue,
|
|
3449
|
-
displayModes,
|
|
3450
|
-
tooltipContain,
|
|
3451
|
-
spinner,
|
|
3452
|
-
editMode,
|
|
3453
|
-
editModeBody,
|
|
3454
|
-
editModeFooter,
|
|
3455
|
-
editModeFooterInfotip,
|
|
3456
|
-
editModeActions,
|
|
3457
|
-
stretchVertically,
|
|
3458
|
-
uiBlocker,
|
|
3459
|
-
hintCallout,
|
|
3460
|
-
schema,
|
|
3461
|
-
executingMessage,
|
|
3462
|
-
resetCollapseButton,
|
|
3463
|
-
title
|
|
3464
|
-
};
|
|
3465
|
-
const cssModules = {
|
|
3466
|
-
"$style": style0
|
|
3467
|
-
};
|
|
3468
|
-
const RunData = /* @__PURE__ */ _export_sfc(_sfc_main, [["__cssModules", cssModules], ["__scopeId", "data-v-d4a2273f"]]);
|
|
3469
|
-
const canvasEventBus = createEventBus();
|
|
3470
|
-
const useExperimentalNdvStore = defineStore("experimentalNdv", () => {
|
|
3471
|
-
const workflowStore = useWorkflowsStore();
|
|
3472
|
-
const settingsStore = useSettingsStore();
|
|
3473
|
-
const isEnabled = computed(
|
|
3474
|
-
() => !Number.isNaN(settingsStore.experimental__minZoomNodeSettingsInCanvas) && settingsStore.experimental__minZoomNodeSettingsInCanvas > 0
|
|
3475
|
-
);
|
|
3476
|
-
const maxCanvasZoom = computed(
|
|
3477
|
-
() => isEnabled.value ? settingsStore.experimental__minZoomNodeSettingsInCanvas : 4
|
|
3478
|
-
);
|
|
3479
|
-
const collapsedNodes = shallowRef({});
|
|
3480
|
-
function setNodeExpanded(nodeId, isExpanded) {
|
|
3481
|
-
collapsedNodes.value = {
|
|
3482
|
-
...collapsedNodes.value,
|
|
3483
|
-
[nodeId]: isExpanded === void 0 ? !collapsedNodes.value[nodeId] : !isExpanded
|
|
3484
|
-
};
|
|
3485
|
-
}
|
|
3486
|
-
function collapseAllNodes() {
|
|
3487
|
-
collapsedNodes.value = workflowStore.allNodes.reduce(
|
|
3488
|
-
(acc, node) => {
|
|
3489
|
-
acc[node.id] = true;
|
|
3490
|
-
return acc;
|
|
3491
|
-
},
|
|
3492
|
-
{}
|
|
3493
|
-
);
|
|
3494
|
-
}
|
|
3495
|
-
function expandAllNodes() {
|
|
3496
|
-
collapsedNodes.value = {};
|
|
3497
|
-
}
|
|
3498
|
-
function isActive(canvasZoom) {
|
|
3499
|
-
return isEnabled.value && canvasZoom === maxCanvasZoom.value;
|
|
3500
|
-
}
|
|
3501
|
-
function focusNode(nodeId) {
|
|
3502
|
-
const nodeToFocus = workflowStore.getNodeById(nodeId);
|
|
3503
|
-
if (!nodeToFocus) {
|
|
3504
|
-
return;
|
|
3505
|
-
}
|
|
3506
|
-
const vueFlow = useVueFlow(workflowStore.workflow.id);
|
|
3507
|
-
collapsedNodes.value = workflowStore.allNodes.reduce(
|
|
3508
|
-
(acc, node) => {
|
|
3509
|
-
acc[node.id] = node.id !== nodeId;
|
|
3510
|
-
return acc;
|
|
3511
|
-
},
|
|
3512
|
-
{}
|
|
3513
|
-
);
|
|
3514
|
-
const workflow = workflowStore.getCurrentWorkflow();
|
|
3515
|
-
const nodeSize = calculateNodeSize(
|
|
3516
|
-
workflow.getChildNodes(nodeToFocus.name, "ALL_NON_MAIN").length > 0,
|
|
3517
|
-
workflow.getParentNodes(nodeToFocus.name, "ALL_NON_MAIN").length > 0,
|
|
3518
|
-
workflow.getParentNodes(nodeToFocus.name, "main").length,
|
|
3519
|
-
workflow.getChildNodes(nodeToFocus.name, "main").length,
|
|
3520
|
-
workflow.getParentNodes(nodeToFocus.name, "ALL_NON_MAIN").length
|
|
3521
|
-
);
|
|
3522
|
-
void vueFlow.setCenter(
|
|
3523
|
-
nodeToFocus.position[0] + nodeSize.width * 1.5 / 2,
|
|
3524
|
-
nodeToFocus.position[1] + 80,
|
|
3525
|
-
{ duration: 200, zoom: maxCanvasZoom.value }
|
|
3526
|
-
);
|
|
3527
|
-
}
|
|
3528
|
-
return {
|
|
3529
|
-
isEnabled,
|
|
3530
|
-
maxCanvasZoom,
|
|
3531
|
-
collapsedNodes: computed(() => collapsedNodes.value),
|
|
3532
|
-
isActive,
|
|
3533
|
-
setNodeExpanded,
|
|
3534
|
-
expandAllNodes,
|
|
3535
|
-
collapseAllNodes,
|
|
3536
|
-
focusNode
|
|
3537
|
-
};
|
|
3538
|
-
});
|
|
3539
|
-
const useKeybindings = (keymap, options) => {
|
|
3540
|
-
const pipWindow = inject(PiPWindowSymbol, ref());
|
|
3541
|
-
const activeElement = useActiveElement({ window: pipWindow?.value });
|
|
3542
|
-
const { isCtrlKeyPressed } = useDeviceSupport();
|
|
3543
|
-
const isDisabled = computed(() => toValue(options?.disabled));
|
|
3544
|
-
const ignoreKeyPresses = computed(() => {
|
|
3545
|
-
if (!activeElement.value) return false;
|
|
3546
|
-
const active = activeElement.value;
|
|
3547
|
-
const isInput = ["INPUT", "TEXTAREA"].includes(active.tagName);
|
|
3548
|
-
const isContentEditable = active.closest("[contenteditable]") !== null;
|
|
3549
|
-
const isIgnoreClass = active.closest(".ignore-key-press-canvas") !== null;
|
|
3550
|
-
return isInput || isContentEditable || isIgnoreClass;
|
|
3551
|
-
});
|
|
3552
|
-
const normalizedKeymap = computed(
|
|
3553
|
-
() => Object.fromEntries(
|
|
3554
|
-
Object.entries(toValue(keymap)).flatMap(([shortcut, handler]) => {
|
|
3555
|
-
const shortcuts = shortcut.split("|");
|
|
3556
|
-
return shortcuts.map((s) => [normalizeShortcutString(s), handler]);
|
|
3557
|
-
})
|
|
3558
|
-
)
|
|
3559
|
-
);
|
|
3560
|
-
function shortcutPartsToString(parts) {
|
|
3561
|
-
return parts.map((key) => key.toLowerCase()).sort((a, b) => a.localeCompare(b)).join("+");
|
|
3562
|
-
}
|
|
3563
|
-
function normalizeShortcutString(shortcut) {
|
|
3564
|
-
if (shortcut.length === 1) {
|
|
3565
|
-
return shortcut.toLowerCase();
|
|
3566
|
-
}
|
|
3567
|
-
const splitChars = ["+", "_", "-"];
|
|
3568
|
-
const splitCharsRegEx = splitChars.reduce((acc, char) => {
|
|
3569
|
-
if (shortcut.startsWith(char) || shortcut.endsWith(char)) {
|
|
3570
|
-
return acc;
|
|
3571
|
-
}
|
|
3572
|
-
return char + acc;
|
|
3573
|
-
}, "");
|
|
3574
|
-
return shortcutPartsToString(shortcut.split(new RegExp(`[${splitCharsRegEx}]`)));
|
|
3575
|
-
}
|
|
3576
|
-
function keyboardEventCodeToKey(code) {
|
|
3577
|
-
if (code.startsWith("Digit")) {
|
|
3578
|
-
return code.replace("Digit", "").toLowerCase();
|
|
3579
|
-
} else if (code.startsWith("Key")) {
|
|
3580
|
-
return code.replace("Key", "").toLowerCase();
|
|
3581
|
-
}
|
|
3582
|
-
return code.toLowerCase();
|
|
3583
|
-
}
|
|
3584
|
-
function toShortcutString(event) {
|
|
3585
|
-
const { shiftKey, altKey } = event;
|
|
3586
|
-
const ctrlKey = isCtrlKeyPressed(event);
|
|
3587
|
-
const keys = "key" in event ? [event.key] : [];
|
|
3588
|
-
const codes = "code" in event ? [keyboardEventCodeToKey(event.code)] : [];
|
|
3589
|
-
const modifiers = [];
|
|
3590
|
-
if (shiftKey) {
|
|
3591
|
-
modifiers.push("shift");
|
|
3592
|
-
}
|
|
3593
|
-
if (ctrlKey) {
|
|
3594
|
-
modifiers.push("ctrl");
|
|
3595
|
-
}
|
|
3596
|
-
if (altKey) {
|
|
3597
|
-
modifiers.push("alt");
|
|
3598
|
-
}
|
|
3599
|
-
return {
|
|
3600
|
-
byKey: shortcutPartsToString([...modifiers, ...keys]),
|
|
3601
|
-
byCode: shortcutPartsToString([...modifiers, ...codes])
|
|
3602
|
-
};
|
|
3603
|
-
}
|
|
3604
|
-
function onKeyDown(event) {
|
|
3605
|
-
if (ignoreKeyPresses.value || isDisabled.value) return;
|
|
3606
|
-
const { byKey, byCode } = toShortcutString(event);
|
|
3607
|
-
const handler = normalizedKeymap.value[byKey] ?? normalizedKeymap.value[byCode];
|
|
3608
|
-
const run = typeof handler === "function" ? handler : handler?.disabled() ? void 0 : handler?.run;
|
|
3609
|
-
if (run) {
|
|
3610
|
-
event.preventDefault();
|
|
3611
|
-
event.stopPropagation();
|
|
3612
|
-
run(event);
|
|
3613
|
-
}
|
|
3614
|
-
}
|
|
3615
|
-
useEventListener(pipWindow?.value?.document ?? document, "keydown", onKeyDown);
|
|
3616
|
-
};
|
|
3617
|
-
export {
|
|
3618
|
-
N8nBlockUi as N,
|
|
3619
|
-
RunData as R,
|
|
3620
|
-
VueJsonPretty as V,
|
|
3621
|
-
_sfc_main$6 as _,
|
|
3622
|
-
useKeybindings as a,
|
|
3623
|
-
ViewSubExecution as b,
|
|
3624
|
-
canvasEventBus as c,
|
|
3625
|
-
parseErrorMetadata as p,
|
|
3626
|
-
useExperimentalNdvStore as u
|
|
3627
|
-
};
|