mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
refactor: Migrate NodeConnectionType to const object type (no-changelog) (#14078)
Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
This commit is contained in:
@@ -1,22 +1,26 @@
|
||||
<script setup lang="ts">
|
||||
import { useStorage } from '@/composables/useStorage';
|
||||
import { saveAs } from 'file-saver';
|
||||
import {
|
||||
type IBinaryData,
|
||||
type IConnectedNode,
|
||||
type IDataObject,
|
||||
type INodeExecutionData,
|
||||
type INodeOutputConfiguration,
|
||||
type IRunData,
|
||||
type IRunExecutionData,
|
||||
type ITaskMetadata,
|
||||
type NodeError,
|
||||
type NodeHint,
|
||||
TRIMMED_TASK_DATA_CONNECTIONS_KEY,
|
||||
type Workflow,
|
||||
parseErrorMetadata,
|
||||
import type {
|
||||
IBinaryData,
|
||||
IConnectedNode,
|
||||
IDataObject,
|
||||
INodeExecutionData,
|
||||
INodeOutputConfiguration,
|
||||
IRunData,
|
||||
IRunExecutionData,
|
||||
ITaskMetadata,
|
||||
NodeError,
|
||||
NodeHint,
|
||||
Workflow,
|
||||
NodeConnectionType,
|
||||
} from 'n8n-workflow';
|
||||
import {
|
||||
parseErrorMetadata,
|
||||
NodeConnectionTypes,
|
||||
NodeHelpers,
|
||||
TRIMMED_TASK_DATA_CONNECTIONS_KEY,
|
||||
} from 'n8n-workflow';
|
||||
import { NodeConnectionType, NodeHelpers } from 'n8n-workflow';
|
||||
import { computed, defineAsyncComponent, onBeforeUnmount, onMounted, ref, toRef, watch } from 'vue';
|
||||
|
||||
import type {
|
||||
@@ -164,7 +168,7 @@ const emit = defineEmits<{
|
||||
];
|
||||
}>();
|
||||
|
||||
const connectionType = ref<NodeConnectionType>(NodeConnectionType.Main);
|
||||
const connectionType = ref<NodeConnectionType>(NodeConnectionTypes.Main);
|
||||
const dataSize = ref(0);
|
||||
const showData = ref(false);
|
||||
const userEnabledShowData = ref(false);
|
||||
@@ -1082,7 +1086,7 @@ function getRunLabel(option: number) {
|
||||
function getRawInputData(
|
||||
runIndex: number,
|
||||
outputIndex: number,
|
||||
connectionType: NodeConnectionType = NodeConnectionType.Main,
|
||||
connectionType: NodeConnectionType = NodeConnectionTypes.Main,
|
||||
): INodeExecutionData[] {
|
||||
let inputData: INodeExecutionData[] = [];
|
||||
|
||||
@@ -1130,7 +1134,7 @@ function getFilteredData(data: INodeExecutionData[]): INodeExecutionData[] {
|
||||
function getDataCount(
|
||||
runIndex: number,
|
||||
outputIndex: number,
|
||||
connectionType: NodeConnectionType = NodeConnectionType.Main,
|
||||
connectionType: NodeConnectionType = NodeConnectionTypes.Main,
|
||||
) {
|
||||
if (!node.value) {
|
||||
return 0;
|
||||
@@ -1165,7 +1169,7 @@ function init() {
|
||||
const outputs = getResolvedNodeOutputs();
|
||||
outputTypes = NodeHelpers.getConnectionTypes(outputs);
|
||||
}
|
||||
connectionType.value = outputTypes.length === 0 ? NodeConnectionType.Main : outputTypes[0];
|
||||
connectionType.value = outputTypes.length === 0 ? NodeConnectionTypes.Main : outputTypes[0];
|
||||
if (binaryData.value.length > 0) {
|
||||
ndvStore.setPanelDisplayMode({
|
||||
pane: props.paneType,
|
||||
|
||||
Reference in New Issue
Block a user