mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-09 22:24:05 -08:00
refactor(editor): Delete some barrel files and reduce circular dependencies (no-changelog) (#7838)
This commit is contained in:
parent
3ab3ec9da8
commit
753cbc1e96
|
@ -3,7 +3,7 @@ import type { PropType } from 'vue';
|
|||
import { computed, defineComponent, ref, useCssModule } from 'vue';
|
||||
import type { DatatableColumn, DatatableRow, DatatableRowDataType } from '../../types';
|
||||
import { getValueByPath } from '../../utils';
|
||||
import { useI18n } from '../../composables';
|
||||
import { useI18n } from '../../composables/useI18n';
|
||||
import N8nSelect from '../N8nSelect';
|
||||
import N8nOption from '../N8nOption';
|
||||
import N8nPagination from '../N8nPagination';
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<script setup lang="ts">
|
||||
import { computed } from 'vue';
|
||||
import { useDeviceSupport } from '../../composables';
|
||||
import { useDeviceSupport } from '../../composables/useDeviceSupport';
|
||||
import type { KeyboardShortcut } from '../../types/keyboardshortcut';
|
||||
|
||||
const props = defineProps<KeyboardShortcut>();
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<script setup lang="ts">
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
|
||||
import N8nTooltip from '../N8nTooltip';
|
||||
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
export * from './useI18n';
|
||||
export { useDeviceSupport } from './useDeviceSupport';
|
|
@ -1,6 +1,6 @@
|
|||
import * as locale from './locale';
|
||||
|
||||
export { useDeviceSupport } from './composables';
|
||||
export { useDeviceSupport } from './composables/useDeviceSupport';
|
||||
export * from './components';
|
||||
export * from './plugin';
|
||||
export * from './types';
|
||||
|
|
|
@ -6,6 +6,7 @@ import { defineConfig as defineVitestConfig } from 'vitest/config';
|
|||
|
||||
export const vitestConfig = defineVitestConfig({
|
||||
test: {
|
||||
silent: true,
|
||||
globals: true,
|
||||
environment: 'jsdom',
|
||||
setupFiles: ['./src/__tests__/setup.ts'],
|
||||
|
|
|
@ -45,21 +45,21 @@ import { HIRING_BANNER, VIEWS } from '@/constants';
|
|||
|
||||
import { userHelpers } from '@/mixins/userHelpers';
|
||||
import { loadLanguage } from '@/plugins/i18n';
|
||||
import { useGlobalLinkActions, useToast, useExternalHooks } from '@/composables';
|
||||
import {
|
||||
useUIStore,
|
||||
useSettingsStore,
|
||||
useUsersStore,
|
||||
useRootStore,
|
||||
useTemplatesStore,
|
||||
useNodeTypesStore,
|
||||
useCloudPlanStore,
|
||||
useSourceControlStore,
|
||||
useUsageStore,
|
||||
} from '@/stores';
|
||||
import useGlobalLinkActions from '@/composables/useGlobalLinkActions';
|
||||
import { useExternalHooks } from '@/composables/useExternalHooks';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useCloudPlanStore } from '@/stores/cloudPlan.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||
import { useTemplatesStore } from '@/stores/templates.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useUsageStore } from '@/stores/usage.store';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { useHistoryHelper } from '@/composables/useHistoryHelper';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { runExternalHook } from '@/utils';
|
||||
import { runExternalHook } from '@/utils/externalHooks';
|
||||
import { initializeAuthenticatedFeatures } from '@/init';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -51,7 +51,7 @@ import type { BulkCommand, Undoable } from '@/models/history';
|
|||
import type { PartialBy, TupleToUnion } from '@/utils/typeHelpers';
|
||||
import type { Component } from 'vue';
|
||||
import type { Scope } from '@n8n/permissions';
|
||||
import type { runExternalHook } from '@/utils';
|
||||
import type { runExternalHook } from '@/utils/externalHooks';
|
||||
|
||||
export * from 'n8n-design-system/types';
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ import { createComponentRenderer } from '@/__tests__/render';
|
|||
import router from '@/router';
|
||||
import { VIEWS } from '@/constants';
|
||||
import { setupServer } from '@/__tests__/server';
|
||||
import { useSettingsStore } from '@/stores';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
|
||||
const App = {
|
||||
template: '<div />',
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { Cloud, IRestApiContext, InstanceUsage } from '@/Interface';
|
||||
import { get, post } from '@/utils';
|
||||
import { get, post } from '@/utils/apiUtils';
|
||||
|
||||
export async function getCurrentPlan(context: IRestApiContext): Promise<Cloud.PlanData> {
|
||||
return get(context.baseUrl, '/admin/cloud-plan');
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import type { IRestApiContext } from '@/Interface';
|
||||
import type { PublicInstalledPackage } from 'n8n-workflow';
|
||||
import { get, post, makeRestApiRequest } from '@/utils';
|
||||
import { get, post, makeRestApiRequest } from '@/utils/apiUtils';
|
||||
|
||||
export async function getInstalledCommunityNodes(
|
||||
context: IRestApiContext,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { EnvironmentVariable, IRestApiContext } from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
import type { IDataObject } from 'n8n-workflow';
|
||||
|
||||
export async function getVariables(context: IRestApiContext): Promise<EnvironmentVariable[]> {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { IRestApiContext } from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
import type { IDataObject, MessageEventBusDestinationOptions } from 'n8n-workflow';
|
||||
|
||||
export async function saveDestinationToDb(
|
||||
|
|
|
@ -3,7 +3,7 @@ import type {
|
|||
ExternalSecretsProvider,
|
||||
ExternalSecretsProviderWithProperties,
|
||||
} from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
|
||||
export const getExternalSecrets = async (
|
||||
context: IRestApiContext,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { IRestApiContext } from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
|
||||
const GET_STATUS_ENDPOINT = '/orchestration/worker/status';
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
import type { IDataObject } from 'n8n-workflow';
|
||||
import type {
|
||||
IRestApiContext,
|
||||
SourceControlAggregatedFile,
|
||||
|
@ -5,8 +6,7 @@ import type {
|
|||
SourceControlStatus,
|
||||
SshKeyTypes,
|
||||
} from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import type { IDataObject } from 'n8n-workflow';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
import type { TupleToUnion } from '@/utils/typeHelpers';
|
||||
|
||||
const sourceControlApiRoot = '/source-control';
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
import type {
|
||||
IRestApiContext,
|
||||
SamlPreferencesLoginEnabled,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { IRestApiContext, ITag } from '@/Interface';
|
||||
import { makeRestApiRequest } from '@/utils';
|
||||
import { makeRestApiRequest } from '@/utils/apiUtils';
|
||||
|
||||
export async function getTags(context: IRestApiContext, withUsageCount = false): Promise<ITag[]> {
|
||||
return makeRestApiRequest(context, 'GET', '/tags', { withUsageCount });
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import type { IRestApiContext } from '@/Interface';
|
||||
import { get } from '@/utils';
|
||||
import { get } from '@/utils/apiUtils';
|
||||
import type {
|
||||
WorkflowHistory,
|
||||
WorkflowVersion,
|
||||
|
|
|
@ -46,7 +46,7 @@ import {
|
|||
LOCAL_STORAGE_ACTIVATION_FLAG,
|
||||
VIEWS,
|
||||
} from '../constants';
|
||||
import { getActivatableTriggerNodes, getTriggerNodeServiceName } from '@/utils';
|
||||
import { getActivatableTriggerNodes, getTriggerNodeServiceName } from '@/utils/nodeTypesUtils';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
|
|
|
@ -30,7 +30,7 @@ import type { IBinaryData } from 'n8n-workflow';
|
|||
import { jsonParse } from 'n8n-workflow';
|
||||
import type { PropType } from 'vue';
|
||||
import VueJsonPretty from 'vue-json-pretty';
|
||||
import { useWorkflowsStore } from '@/stores';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import RunDataHtml from '@/components/RunDataHtml.vue';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -19,8 +19,8 @@ import { BREAKPOINT_SM, BREAKPOINT_MD, BREAKPOINT_LG, BREAKPOINT_XL } from '@/co
|
|||
|
||||
import { genericHelpers } from '@/mixins/genericHelpers';
|
||||
import { debounceHelper } from '@/mixins/debounce';
|
||||
import { useUIStore } from '@/stores';
|
||||
import { getBannerRowHeight } from '@/utils';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { getBannerRowHeight } from '@/utils/htmlUtils';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'BreakpointsObserver',
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
import { defineComponent } from 'vue';
|
||||
|
||||
import { CHANGE_PASSWORD_MODAL_KEY } from '../constants';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
import type { IFormInputs } from '@/Interface';
|
||||
import { mapStores } from 'pinia';
|
||||
|
|
|
@ -7,10 +7,10 @@ import Modal from './Modal.vue';
|
|||
import { CHAT_EMBED_MODAL_KEY, WEBHOOK_NODE_TYPE } from '../constants';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useWorkflowsStore } from '@/stores';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import HtmlEditor from '@/components/HtmlEditor/HtmlEditor.vue';
|
||||
import CodeNodeEditor from '@/components/CodeNodeEditor/CodeNodeEditor.vue';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
const props = defineProps({
|
||||
modalBus: {
|
||||
|
|
|
@ -9,9 +9,16 @@ import type { CodeExecutionMode, INodeExecutionData } from 'n8n-workflow';
|
|||
import type { BaseTextKey } from '@/plugins/i18n';
|
||||
import type { INodeUi, Schema } from '@/Interface';
|
||||
import { generateCodeForPrompt } from '@/api/ai';
|
||||
import { useDataSchema, useI18n, useMessage, useTelemetry, useToast } from '@/composables';
|
||||
import { useNDVStore, usePostHog, useRootStore, useWorkflowsStore } from '@/stores';
|
||||
import { executionDataToJson } from '@/utils';
|
||||
import { useTelemetry } from '@/composables/useTelemetry';
|
||||
import { useDataSchema } from '@/composables/useDataSchema';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { usePostHog } from '@/stores/posthog.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { executionDataToJson } from '@/utils/nodeTypesUtils';
|
||||
import {
|
||||
ASK_AI_EXPERIMENT,
|
||||
ASK_AI_MAX_PROMPT_LENGTH,
|
||||
|
|
|
@ -60,7 +60,8 @@ import { CODE_EXECUTION_MODES, CODE_LANGUAGES } from 'n8n-workflow';
|
|||
import { workflowHelpers } from '@/mixins/workflowHelpers'; // for json field completions
|
||||
import { ASK_AI_EXPERIMENT, CODE_NODE_TYPE } from '@/constants';
|
||||
import { codeNodeEditorEventBus } from '@/event-bus';
|
||||
import { useRootStore, usePostHog } from '@/stores';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { usePostHog } from '@/stores/posthog.store';
|
||||
|
||||
import { readOnlyEditorExtensions, writableEditorExtensions } from './baseExtensions';
|
||||
import { CODE_PLACEHOLDERS } from './constants';
|
||||
|
@ -68,7 +69,7 @@ import { linterExtension } from './linter';
|
|||
import { completerExtension } from './completer';
|
||||
import { codeNodeEditorTheme } from './theme';
|
||||
import AskAI from './AskAI/AskAI.vue';
|
||||
import { useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'code-node-editor',
|
||||
|
|
|
@ -2,7 +2,7 @@ import Vue from 'vue';
|
|||
import { addVarType } from '../utils';
|
||||
import type { Completion, CompletionContext, CompletionResult } from '@codemirror/autocomplete';
|
||||
import type { CodeNodeEditorMixin } from '../types';
|
||||
import { useExternalSecretsStore } from '@/stores';
|
||||
import { useExternalSecretsStore } from '@/stores/externalSecrets.ee.store';
|
||||
|
||||
const escape = (str: string) => str.replace('$', '\\$');
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { addVarType } from '../utils';
|
||||
import type { Completion, CompletionContext, CompletionResult } from '@codemirror/autocomplete';
|
||||
import { useEnvironmentsStore } from '@/stores';
|
||||
import { useEnvironmentsStore } from '@/stores/environments.ee.store';
|
||||
import { defineComponent } from 'vue';
|
||||
|
||||
const escape = (str: string) => str.replace('$', '\\$');
|
||||
|
|
|
@ -101,7 +101,7 @@ import {
|
|||
COMMUNITY_NODES_INSTALLATION_DOCS_URL,
|
||||
COMMUNITY_NODES_RISKS_DOCS_URL,
|
||||
} from '@/constants';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useCommunityNodesStore } from '@/stores/communityNodes.store';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
import { defineComponent } from 'vue';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
import { COMMUNITY_PACKAGE_CONFIRM_MODAL_KEY, COMMUNITY_PACKAGE_MANAGE_ACTIONS } from '@/constants';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useCommunityNodesStore } from '@/stores/communityNodes.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -42,7 +42,7 @@ import Modal from '@/components/Modal.vue';
|
|||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'ContactPromptModal',
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<script lang="ts" setup>
|
||||
import { type ContextMenuAction, useContextMenu } from '@/composables';
|
||||
import { type ContextMenuAction, useContextMenu } from '@/composables/useContextMenu';
|
||||
import { N8nActionDropdown } from 'n8n-design-system';
|
||||
import type { INode } from 'n8n-workflow';
|
||||
import { watch, ref } from 'vue';
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { copyPaste } from '@/mixins/copyPaste';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { i18n } from '@/plugins/i18n';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -37,7 +37,7 @@ import { defineComponent } from 'vue';
|
|||
import type { ICredentialsResponse, IUser } from '@/Interface';
|
||||
import type { ICredentialType } from 'n8n-workflow';
|
||||
import { EnterpriseEditionFeature, MODAL_CONFIRM } from '@/constants';
|
||||
import { useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import CredentialIcon from '@/components/CredentialIcon.vue';
|
||||
import type { IPermissions } from '@/permissions';
|
||||
import { getCredentialPermissions } from '@/permissions';
|
||||
|
|
|
@ -8,7 +8,7 @@ import {
|
|||
getNodeAuthFields,
|
||||
getNodeAuthOptions,
|
||||
isAuthRelatedParameter,
|
||||
} from '@/utils';
|
||||
} from '@/utils/nodeTypesUtils';
|
||||
import type { INodeProperties, INodeTypeDescription, NodeParameterValue } from 'n8n-workflow';
|
||||
import { computed, onMounted, ref } from 'vue';
|
||||
|
||||
|
|
|
@ -145,7 +145,7 @@ import { defineComponent } from 'vue';
|
|||
import { mapStores } from 'pinia';
|
||||
|
||||
import type { ICredentialType, INodeTypeDescription } from 'n8n-workflow';
|
||||
import { getAppNameFromCredType, isCommunityPackageName } from '@/utils';
|
||||
import { getAppNameFromCredType, isCommunityPackageName } from '@/utils/nodeTypesUtils';
|
||||
|
||||
import Banner from '../Banner.vue';
|
||||
import CopyInput from '../CopyInput.vue';
|
||||
|
|
|
@ -136,7 +136,8 @@ import { NodeHelpers } from 'n8n-workflow';
|
|||
import CredentialIcon from '@/components/CredentialIcon.vue';
|
||||
|
||||
import { nodeHelpers } from '@/mixins/nodeHelpers';
|
||||
import { useToast, useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
import CredentialConfig from '@/components/CredentialEdit/CredentialConfig.vue';
|
||||
import CredentialInfo from '@/components/CredentialEdit/CredentialInfo.vue';
|
||||
|
@ -157,14 +158,12 @@ import { useWorkflowsStore } from '@/stores/workflows.store';
|
|||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useCredentialsStore } from '@/stores/credentials.store';
|
||||
import {
|
||||
isValidCredentialResponse,
|
||||
getNodeAuthOptions,
|
||||
getNodeCredentialForSelectedAuthType,
|
||||
updateNodeAuthType,
|
||||
isCredentialModalState,
|
||||
isExpression,
|
||||
isTestableExpression,
|
||||
} from '@/utils';
|
||||
} from '@/utils/nodeTypesUtils';
|
||||
import { isValidCredentialResponse, isCredentialModalState } from '@/utils/typeGuards';
|
||||
import { isExpression, isTestableExpression } from '@/utils/expressions';
|
||||
import { externalHooks } from '@/mixins/externalHooks';
|
||||
|
||||
interface NodeAccessMap {
|
||||
|
|
|
@ -72,7 +72,7 @@
|
|||
<script lang="ts">
|
||||
import type { IUser, IUserListAction } from '@/Interface';
|
||||
import { defineComponent } from 'vue';
|
||||
import { useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { useUIStore } from '@/stores';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
|
||||
const { baseUrl } = useRootStore();
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<script setup lang="ts">
|
||||
import { computed } from 'vue';
|
||||
import { useUIStore } from '@/stores';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { listenForCredentialChanges, useCredentialsStore } from '@/stores/credentials.store';
|
||||
import { assert } from '@/utils/assert';
|
||||
import CredentialsDropdown from './CredentialsDropdown.vue';
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<script setup lang="ts">
|
||||
import type { PropType } from 'vue';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
export type CredentialOption = {
|
||||
id: string;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<script lang="ts" setup>
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
|
||||
const props = defineProps<{
|
||||
|
|
|
@ -79,7 +79,7 @@
|
|||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
import type { IUser } from '@/Interface';
|
||||
import { mapStores } from 'pinia';
|
||||
|
|
|
@ -52,7 +52,7 @@ import { defineComponent } from 'vue';
|
|||
import { mapStores } from 'pinia';
|
||||
import { MAX_WORKFLOW_NAME_LENGTH, PLACEHOLDER_EMPTY_WORKFLOW_ID } from '@/constants';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import TagsDropdown from '@/components/TagsDropdown.vue';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
|
@ -62,7 +62,7 @@ import type { IPermissions } from '@/permissions';
|
|||
import { getWorkflowPermissions } from '@/permissions';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
import { useCredentialsStore } from '@/stores';
|
||||
import { useCredentialsStore } from '@/stores/credentials.store';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'DuplicateWorkflow',
|
||||
|
|
|
@ -122,11 +122,11 @@ import { defineComponent } from 'vue';
|
|||
import { mapStores } from 'pinia';
|
||||
import VueJsonPretty from 'vue-json-pretty';
|
||||
import { copyPaste } from '@/mixins/copyPaste';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { MAX_DISPLAY_DATA_SIZE } from '@/constants';
|
||||
|
||||
import type { INodeProperties, INodePropertyCollection, INodePropertyOptions } from 'n8n-workflow';
|
||||
import { sanitizeHtml } from '@/utils';
|
||||
import { sanitizeHtml } from '@/utils/htmlUtils';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
|
||||
|
|
|
@ -8,12 +8,12 @@ import type {
|
|||
} from '@/Interface';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import TagsDropdown from '@/components/TagsDropdown.vue';
|
||||
import { getObjectKeys, isEmpty } from '@/utils';
|
||||
import { getObjectKeys, isEmpty } from '@/utils/typesUtils';
|
||||
import { EnterpriseEditionFeature } from '@/constants';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useUsageStore } from '@/stores/usage.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useTelemetry } from '@/composables';
|
||||
import { useTelemetry } from '@/composables/useTelemetry';
|
||||
import type { Placement } from '@floating-ui/core';
|
||||
|
||||
export type ExecutionFilterProps = {
|
||||
|
|
|
@ -291,7 +291,10 @@ import { externalHooks } from '@/mixins/externalHooks';
|
|||
import { MODAL_CONFIRM, VIEWS, WAIT_TIME_UNLIMITED } from '@/constants';
|
||||
import { genericHelpers } from '@/mixins/genericHelpers';
|
||||
import { executionHelpers } from '@/mixins/executionsHelpers';
|
||||
import { useToast, useMessage, useI18n, useTelemetry } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useTelemetry } from '@/composables/useTelemetry';
|
||||
import type {
|
||||
IExecutionsCurrentSummaryExtended,
|
||||
IExecutionDeleteFilter,
|
||||
|
@ -304,7 +307,8 @@ import type { IExecutionsSummary, ExecutionStatus } from 'n8n-workflow';
|
|||
import { range as _range } from 'lodash-es';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { isEmpty, setPageTitle } from '@/utils';
|
||||
import { isEmpty } from '@/utils/typesUtils';
|
||||
import { setPageTitle } from '@/utils/htmlUtils';
|
||||
import { executionFilterToQueryFilter } from '@/utils/executionUtils';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -67,7 +67,7 @@ import { i18n as locale } from '@/plugins/i18n';
|
|||
import { DateTime } from 'luxon';
|
||||
import type { CloudPlanAndUsageData } from '@/Interface';
|
||||
import { computed } from 'vue';
|
||||
import { useUIStore } from '@/stores';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
||||
const PROGRESS_BAR_MINIMUM_THRESHOLD = 8;
|
||||
|
||||
|
|
|
@ -152,7 +152,8 @@
|
|||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElDropdown } from 'element-plus';
|
||||
import { useExecutionDebugging, useMessage } from '@/composables';
|
||||
import { useExecutionDebugging } from '@/composables/useExecutionDebugging';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import WorkflowPreview from '@/components/WorkflowPreview.vue';
|
||||
import type { IExecutionUIData } from '@/mixins/executionsHelpers';
|
||||
import { executionHelpers } from '@/mixins/executionsHelpers';
|
||||
|
|
|
@ -52,13 +52,15 @@ import type {
|
|||
INodeTypeNameVersion,
|
||||
} from 'n8n-workflow';
|
||||
import { NodeHelpers } from 'n8n-workflow';
|
||||
import { useToast, useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
import type { Route } from 'vue-router';
|
||||
import { executionHelpers } from '@/mixins/executionsHelpers';
|
||||
import { range as _range } from 'lodash-es';
|
||||
import { debounceHelper } from '@/mixins/debounce';
|
||||
import { getNodeViewTab, NO_NETWORK_ERROR_CODE } from '@/utils';
|
||||
import { NO_NETWORK_ERROR_CODE } from '@/utils/apiUtils';
|
||||
import { getNodeViewTab } from '@/utils/canvasUtils';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
|
|
@ -5,7 +5,8 @@ import { faker } from '@faker-js/faker';
|
|||
import { createRouter, createWebHistory } from 'vue-router';
|
||||
import { createPinia, PiniaVuePlugin, setActivePinia } from 'pinia';
|
||||
import type { IExecutionsSummary } from 'n8n-workflow';
|
||||
import { useSettingsStore, useWorkflowsStore } from '@/stores';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import ExecutionPreview from '@/components/ExecutionsView/ExecutionPreview.vue';
|
||||
import { VIEWS } from '@/constants';
|
||||
import { i18nInstance, I18nPlugin } from '@/plugins/i18n';
|
||||
|
|
|
@ -3,8 +3,11 @@ import type { PropType, Ref } from 'vue';
|
|||
import type { ExternalSecretsProvider } from '@/Interface';
|
||||
import ExternalSecretsProviderImage from '@/components/ExternalSecretsProviderImage.ee.vue';
|
||||
import ExternalSecretsProviderConnectionSwitch from '@/components/ExternalSecretsProviderConnectionSwitch.ee.vue';
|
||||
import { useExternalSecretsStore, useUIStore } from '@/stores';
|
||||
import { useExternalSecretsProvider, useI18n, useToast } from '@/composables';
|
||||
import { useExternalSecretsStore } from '@/stores/externalSecrets.ee.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useExternalSecretsProvider } from '@/composables/useExternalSecretsProvider';
|
||||
import { EXTERNAL_SECRETS_PROVIDER_MODAL_KEY } from '@/constants';
|
||||
import { DateTime } from 'luxon';
|
||||
import { computed, nextTick, onMounted, toRefs } from 'vue';
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
<script lang="ts" setup>
|
||||
import type { PropType } from 'vue';
|
||||
import type { ExternalSecretsProvider } from '@/Interface';
|
||||
import { useExternalSecretsStore } from '@/stores';
|
||||
import { useI18n, useLoadingService, useToast } from '@/composables';
|
||||
import { useExternalSecretsStore } from '@/stores/externalSecrets.ee.store';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useLoadingService } from '@/composables/useLoadingService';
|
||||
import { computed, onMounted, ref } from 'vue';
|
||||
import type { EventBus } from 'n8n-design-system/utils';
|
||||
|
||||
|
|
|
@ -4,9 +4,12 @@ import { EXTERNAL_SECRETS_PROVIDER_MODAL_KEY, MODAL_CONFIRM } from '@/constants'
|
|||
import { computed, onMounted, ref } from 'vue';
|
||||
import type { PropType, Ref } from 'vue';
|
||||
import type { EventBus } from 'n8n-design-system/utils';
|
||||
import { useExternalSecretsProvider, useI18n, useMessage, useToast } from '@/composables';
|
||||
import { useExternalSecretsProvider } from '@/composables/useExternalSecretsProvider';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useExternalSecretsStore } from '@/stores/externalSecrets.ee.store';
|
||||
import { useUIStore } from '@/stores';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useRoute } from 'vue-router';
|
||||
import ParameterInputExpanded from '@/components/ParameterInputExpanded.vue';
|
||||
import type {
|
||||
|
|
|
@ -46,7 +46,7 @@ import {
|
|||
CURL_IMPORT_NOT_SUPPORTED_PROTOCOLS,
|
||||
CURL_IMPORT_NODES_PROTOCOLS,
|
||||
} from '@/constants';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { defineComponent } from 'vue';
|
||||
import type { INodeUi } from '@/Interface';
|
||||
import { mapStores } from 'pinia';
|
||||
|
|
|
@ -40,7 +40,7 @@ import { outputTheme } from './theme';
|
|||
|
||||
import type { Plaintext, Resolved, Segment } from '@/types/expressions';
|
||||
import { EXPRESSIONS_DOCS_URL } from '@/constants';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'InlineExpressionEditorOutput',
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'InlineNameEdit',
|
||||
|
|
|
@ -54,12 +54,12 @@
|
|||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { copyPaste } from '@/mixins/copyPaste';
|
||||
import Modal from './Modal.vue';
|
||||
import type { IFormInputs, IInviteResponse, IUser } from '@/Interface';
|
||||
import { VALID_EMAIL_REGEX, INVITE_USER_MODAL_KEY } from '@/constants';
|
||||
import { ROLE } from '@/utils';
|
||||
import { ROLE } from '@/utils/userUtils';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -5,7 +5,8 @@
|
|||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useRootStore, useUIStore } from '@/stores';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
||||
export default defineComponent({
|
||||
computed: {
|
||||
|
|
|
@ -30,7 +30,9 @@ import {
|
|||
} from '@/constants';
|
||||
import type { INodeUi, ITabBarItem } from '@/Interface';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { useUIStore, useNDVStore, useSourceControlStore } from '@/stores';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'MainHeader',
|
||||
|
|
|
@ -167,18 +167,18 @@ import CollaborationPane from '@/components/MainHeader/CollaborationPane.vue';
|
|||
import type { IUser, IWorkflowDataUpdate, IWorkflowDb, IWorkflowToShare } from '@/Interface';
|
||||
|
||||
import { saveAs } from 'file-saver';
|
||||
import { useTitleChange, useToast, useMessage } from '@/composables';
|
||||
import { useTitleChange } from '@/composables/useTitleChange';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import type { MessageBoxInputData } from 'element-plus';
|
||||
import {
|
||||
useUIStore,
|
||||
useSettingsStore,
|
||||
useWorkflowsStore,
|
||||
useRootStore,
|
||||
useTagsStore,
|
||||
useUsersStore,
|
||||
useUsageStore,
|
||||
useSourceControlStore,
|
||||
} from '@/stores';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||
import { useTagsStore } from '@/stores/tags.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useUsageStore } from '@/stores/usage.store';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import type { IPermissions } from '@/permissions';
|
||||
import { getWorkflowPermissions } from '@/permissions';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -100,7 +100,7 @@ import type { CloudPlanAndUsageData, IExecutionResponse, IMenuItem, IVersion } f
|
|||
import GiftNotificationIcon from './GiftNotificationIcon.vue';
|
||||
|
||||
import { genericHelpers } from '@/mixins/genericHelpers';
|
||||
import { useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { workflowRun } from '@/mixins/workflowRun';
|
||||
|
||||
|
@ -109,20 +109,18 @@ import { userHelpers } from '@/mixins/userHelpers';
|
|||
import { debounceHelper } from '@/mixins/debounce';
|
||||
import { defineComponent } from 'vue';
|
||||
import { mapStores } from 'pinia';
|
||||
import {
|
||||
useUIStore,
|
||||
useSettingsStore,
|
||||
useUsersStore,
|
||||
useWorkflowsStore,
|
||||
useRootStore,
|
||||
useVersionsStore,
|
||||
useCloudPlanStore,
|
||||
useSourceControlStore,
|
||||
} from '@/stores/';
|
||||
import { useCloudPlanStore } from '@/stores/cloudPlan.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { useVersionsStore } from '@/stores/versions.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { isNavigationFailure } from 'vue-router';
|
||||
import ExecutionsUsage from '@/components/ExecutionsUsage.vue';
|
||||
import MainSidebarSourceControl from '@/components/MainSidebarSourceControl.vue';
|
||||
import { ROLE } from '@/utils';
|
||||
import { ROLE } from '@/utils/userUtils';
|
||||
import { hasPermission } from '@/rbac/permissions';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -2,7 +2,10 @@
|
|||
import { computed, nextTick, ref } from 'vue';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
import { useI18n, useLoadingService, useMessage, useToast } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { useLoadingService } from '@/composables/useLoadingService';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
|
|
|
@ -142,7 +142,7 @@ import { useNDVStore } from '@/stores/ndv.store';
|
|||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { copyPaste } from '@/mixins/copyPaste';
|
||||
import { mfaEventBus } from '@/event-bus';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
//@ts-ignore
|
||||
import QrcodeVue from 'qrcode.vue';
|
||||
export default defineComponent({
|
||||
|
|
|
@ -176,7 +176,7 @@ import NodeIcon from '@/components/NodeIcon.vue';
|
|||
import TitledList from '@/components/TitledList.vue';
|
||||
|
||||
import { get } from 'lodash-es';
|
||||
import { getTriggerNodeServiceName } from '@/utils';
|
||||
import { getTriggerNodeServiceName } from '@/utils/nodeTypesUtils';
|
||||
import type { INodeUi, XYPosition } from '@/Interface';
|
||||
import { debounceHelper } from '@/mixins/debounce';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
@ -185,7 +185,7 @@ import { useNDVStore } from '@/stores/ndv.store';
|
|||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { EnableNodeToggleCommand } from '@/models/history';
|
||||
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
|
||||
import { type ContextMenuTarget, useContextMenu } from '@/composables';
|
||||
import { type ContextMenuTarget, useContextMenu } from '@/composables/useContextMenu';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'Node',
|
||||
|
|
|
@ -49,13 +49,14 @@ import {
|
|||
DRAG_EVENT_DATA_KEY,
|
||||
} from '@/constants';
|
||||
|
||||
import { isCommunityPackageName } from '@/utils';
|
||||
import { isCommunityPackageName } from '@/utils/nodeTypesUtils';
|
||||
import { getNewNodePosition, NODE_SIZE } from '@/utils/nodeViewUtils';
|
||||
import { useNodeCreatorStore } from '@/stores/nodeCreator.store';
|
||||
import NodeIcon from '@/components/NodeIcon.vue';
|
||||
|
||||
import { useActions } from '../composables/useActions';
|
||||
import { useI18n, useTelemetry } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useTelemetry } from '@/composables/useTelemetry';
|
||||
import { NodeHelpers, NodeConnectionType } from 'n8n-workflow';
|
||||
|
||||
export interface Props {
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
import type { SubcategoryItemProps } from '@/Interface';
|
||||
import { camelCase } from 'lodash-es';
|
||||
import { computed } from 'vue';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
export interface Props {
|
||||
item: SubcategoryItemProps;
|
||||
|
|
|
@ -16,7 +16,7 @@ import {
|
|||
} from '@/constants';
|
||||
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { runExternalHook } from '@/utils';
|
||||
import { runExternalHook } from '@/utils/externalHooks';
|
||||
|
||||
import { useActions } from '../composables/useActions';
|
||||
import { useKeyboardNavigation } from '../composables/useKeyboardNavigation';
|
||||
|
|
|
@ -22,7 +22,8 @@ import { useKeyboardNavigation } from '../composables/useKeyboardNavigation';
|
|||
import ItemsRenderer from '../Renderers/ItemsRenderer.vue';
|
||||
import CategorizedItemsRenderer from '../Renderers/CategorizedItemsRenderer.vue';
|
||||
import NoResults from '../Panel/NoResults.vue';
|
||||
import { useI18n, useTelemetry } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useTelemetry } from '@/composables/useTelemetry';
|
||||
|
||||
export interface Props {
|
||||
rootView: 'trigger' | 'action';
|
||||
|
|
|
@ -30,7 +30,8 @@ import { useViewStacks } from './composables/useViewStacks';
|
|||
import { useKeyboardNavigation } from './composables/useKeyboardNavigation';
|
||||
import { useActionsGenerator } from './composables/useActionsGeneration';
|
||||
import NodesListPanel from './Panel/NodesListPanel.vue';
|
||||
import { useCredentialsStore, useUIStore } from '@/stores';
|
||||
import { useCredentialsStore } from '@/stores/credentials.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { DRAG_EVENT_DATA_KEY } from '@/constants';
|
||||
|
||||
export interface Props {
|
||||
|
|
|
@ -16,7 +16,7 @@ import { useKeyboardNavigation } from '../composables/useKeyboardNavigation';
|
|||
import SearchBar from './SearchBar.vue';
|
||||
import ActionsRenderer from '../Modes/ActionsMode.vue';
|
||||
import NodesRenderer from '../Modes/NodesMode.vue';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
const i18n = useI18n();
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
<script setup lang="ts">
|
||||
import { onMounted, reactive, toRefs, onBeforeUnmount } from 'vue';
|
||||
import { useExternalHooks } from '@/composables';
|
||||
import { useExternalHooks } from '@/composables/useExternalHooks';
|
||||
|
||||
export interface Props {
|
||||
placeholder: string;
|
||||
|
|
|
@ -26,7 +26,7 @@ import type { Telemetry } from '@/plugins/telemetry';
|
|||
import { useNodeCreatorStore } from '@/stores/nodeCreator.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { runExternalHook } from '@/utils';
|
||||
import { runExternalHook } from '@/utils/externalHooks';
|
||||
|
||||
import { sortNodeCreateElements, transformNodeType } from '../utils';
|
||||
|
||||
|
|
|
@ -22,10 +22,10 @@ import {
|
|||
sortNodeCreateElements,
|
||||
searchNodes,
|
||||
} from '../utils';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
|
||||
import type { INodeInputFilter } from 'n8n-workflow';
|
||||
import { useNodeTypesStore } from '@/stores';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { AINodesView, type NodeViewItem } from '@/components/Node/NodeCreator/viewsData';
|
||||
|
||||
interface ViewStack {
|
||||
|
|
|
@ -7,7 +7,7 @@ import type {
|
|||
} from '@/Interface';
|
||||
import { AI_SUBCATEGORY, CORE_NODES_CATEGORY, DEFAULT_SUBCATEGORY } from '@/constants';
|
||||
import { v4 as uuidv4 } from 'uuid';
|
||||
import { sublimeSearch } from '@/utils';
|
||||
import { sublimeSearch } from '@/utils/sortUtils';
|
||||
|
||||
export function transformNodeType(
|
||||
node: SimplifiedNodeType,
|
||||
|
|
|
@ -30,8 +30,8 @@ import {
|
|||
AI_OTHERS_NODE_CREATOR_VIEW,
|
||||
AI_UNCATEGORIZED_CATEGORY,
|
||||
} from '@/constants';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useNodeTypesStore } from '@/stores';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import type { SimplifiedNodeType } from '@/Interface';
|
||||
import type { INodeTypeDescription } from 'n8n-workflow';
|
||||
import { NodeConnectionType } from 'n8n-workflow';
|
||||
|
|
|
@ -119,7 +119,7 @@ import type {
|
|||
|
||||
import { genericHelpers } from '@/mixins/genericHelpers';
|
||||
import { nodeHelpers } from '@/mixins/nodeHelpers';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
import TitledList from '@/components/TitledList.vue';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
|
@ -136,7 +136,7 @@ import {
|
|||
getAllNodeCredentialForAuthType,
|
||||
updateNodeAuthType,
|
||||
isRequiredCredential,
|
||||
} from '@/utils';
|
||||
} from '@/utils/nodeTypesUtils';
|
||||
|
||||
interface CredentialDropdownOption extends ICredentialsResponse {
|
||||
typeDisplayName: string;
|
||||
|
|
|
@ -170,8 +170,8 @@ import { useNDVStore } from '@/stores/ndv.store';
|
|||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useDeviceSupport } from 'n8n-design-system';
|
||||
import { useMessage } from '@/composables';
|
||||
import { useDeviceSupport } from 'n8n-design-system/composables/useDeviceSupport';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'NodeDetailsView',
|
||||
|
|
|
@ -37,7 +37,8 @@ import { pinData } from '@/mixins/pinData';
|
|||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { useToast, useMessage } from '@/composables';
|
||||
import { useMessage } from '@/composables/useMessage';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
export default defineComponent({
|
||||
inheritAttrs: false,
|
||||
|
|
|
@ -17,7 +17,7 @@ import { defineComponent } from 'vue';
|
|||
import NodeIcon from '@/components/NodeIcon.vue';
|
||||
import { genericHelpers } from '@/mixins/genericHelpers';
|
||||
import type { ITemplatesNode } from '@/Interface';
|
||||
import { filterTemplateNodes } from '@/utils';
|
||||
import { filterTemplateNodes } from '@/utils/nodeTypesUtils';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'NodeList',
|
||||
|
|
|
@ -205,7 +205,7 @@ import { externalHooks } from '@/mixins/externalHooks';
|
|||
import { nodeHelpers } from '@/mixins/nodeHelpers';
|
||||
|
||||
import NodeExecuteButton from './NodeExecuteButton.vue';
|
||||
import { isCommunityPackageName } from '@/utils';
|
||||
import { isCommunityPackageName } from '@/utils/nodeTypesUtils';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
|
|
|
@ -22,7 +22,7 @@ import { useWorkflowsStore } from '@/stores/workflows.store';
|
|||
import type { INodeTypeDescription } from 'n8n-workflow';
|
||||
import { NodeConnectionType } from 'n8n-workflow';
|
||||
|
||||
import { isCommunityPackageName } from '@/utils';
|
||||
import { isCommunityPackageName } from '@/utils/nodeTypesUtils';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'NodeSettingsTabs',
|
||||
|
|
|
@ -64,7 +64,7 @@
|
|||
import type { INodeTypeDescription, IWebhookDescription } from 'n8n-workflow';
|
||||
import { defineComponent } from 'vue';
|
||||
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { FORM_TRIGGER_NODE_TYPE, OPEN_URL_PANEL_TRIGGER_NODE_TYPES } from '@/constants';
|
||||
import { copyPaste } from '@/mixins/copyPaste';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
|
|
|
@ -50,7 +50,7 @@ import { ONBOARDING_CALL_SIGNUP_MODAL_KEY, VALID_EMAIL_REGEX } from '@/constants
|
|||
import Modal from './Modal.vue';
|
||||
|
||||
import { defineComponent } from 'vue';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -5,8 +5,8 @@
|
|||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import type { NotificationInstance } from 'element-plus';
|
||||
import { sanitizeHtml } from '@/utils';
|
||||
import { useToast } from '@/composables';
|
||||
import { sanitizeHtml } from '@/utils/htmlUtils';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'PageAlert',
|
||||
|
|
|
@ -398,7 +398,8 @@ import SqlEditor from '@/components/SqlEditor/SqlEditor.vue';
|
|||
import { externalHooks } from '@/mixins/externalHooks';
|
||||
import { nodeHelpers } from '@/mixins/nodeHelpers';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { hasExpressionMapping, isValueExpression, isResourceLocatorValue } from '@/utils';
|
||||
import { hasExpressionMapping, isValueExpression } from '@/utils/nodeTypesUtils';
|
||||
import { isResourceLocatorValue } from '@/utils/typeGuards';
|
||||
|
||||
import {
|
||||
CUSTOM_API_CALL_KEY,
|
||||
|
@ -417,7 +418,7 @@ import { useSettingsStore } from '@/stores/settings.store';
|
|||
import { htmlEditorEventBus } from '@/event-bus';
|
||||
import type { EventBus } from 'n8n-design-system/utils';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
import { useI18n } from '@/composables';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import type { N8nInput } from 'n8n-design-system';
|
||||
import { isCredentialOnlyNodeType } from '@/utils/credentialOnlyNodes';
|
||||
|
||||
|
|
|
@ -60,7 +60,7 @@ import ParameterOptions from './ParameterOptions.vue';
|
|||
import { defineComponent } from 'vue';
|
||||
import type { PropType } from 'vue';
|
||||
import ParameterInputWrapper from './ParameterInputWrapper.vue';
|
||||
import { isValueExpression } from '@/utils';
|
||||
import { isValueExpression } from '@/utils/nodeTypesUtils';
|
||||
import type { INodeParameterResourceLocator, INodeProperties, IParameterLabel } from 'n8n-workflow';
|
||||
import { mapStores } from 'pinia';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
|
|
|
@ -77,13 +77,10 @@ import type { IN8nButton, INodeUi, IRunDataDisplayMode, IUpdateInformation } fro
|
|||
|
||||
import ParameterOptions from '@/components/ParameterOptions.vue';
|
||||
import DraggableTarget from '@/components/DraggableTarget.vue';
|
||||
import { useI18n, useToast } from '@/composables';
|
||||
import {
|
||||
hasExpressionMapping,
|
||||
isResourceLocatorValue,
|
||||
hasOnlyListMode,
|
||||
isValueExpression,
|
||||
} from '@/utils';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { hasExpressionMapping, hasOnlyListMode, isValueExpression } from '@/utils/nodeTypesUtils';
|
||||
import { isResourceLocatorValue } from '@/utils/typeGuards';
|
||||
import ParameterInputWrapper from '@/components/ParameterInputWrapper.vue';
|
||||
import type {
|
||||
INodeParameters,
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { sanitizeHtml } from '@/utils';
|
||||
import { sanitizeHtml } from '@/utils/htmlUtils';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'InputHint',
|
||||
|
|
|
@ -157,7 +157,11 @@ import { KEEP_AUTH_IN_NDV_FOR_NODES } from '@/constants';
|
|||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { getMainAuthField, getNodeAuthFields, isAuthRelatedParameter } from '@/utils';
|
||||
import {
|
||||
getMainAuthField,
|
||||
getNodeAuthFields,
|
||||
isAuthRelatedParameter,
|
||||
} from '@/utils/nodeTypesUtils';
|
||||
import { get, set } from 'lodash-es';
|
||||
import { nodeViewEventBus } from '@/event-bus';
|
||||
|
||||
|
|
|
@ -61,9 +61,10 @@ import type {
|
|||
import { isResourceLocatorValue } from 'n8n-workflow';
|
||||
import type { INodeUi, IUpdateInformation, TargetItem } from '@/Interface';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { isValueExpression, parseResourceMapperFieldName } from '@/utils';
|
||||
import { isValueExpression, parseResourceMapperFieldName } from '@/utils/nodeTypesUtils';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useEnvironmentsStore, useExternalSecretsStore } from '@/stores';
|
||||
import { useEnvironmentsStore } from '@/stores/environments.ee.store';
|
||||
import { useExternalSecretsStore } from '@/stores/externalSecrets.ee.store';
|
||||
|
||||
import type { EventBus } from 'n8n-design-system/utils';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -43,7 +43,8 @@
|
|||
import type { NodeParameterValueType } from 'n8n-workflow';
|
||||
import { defineComponent } from 'vue';
|
||||
import type { PropType } from 'vue';
|
||||
import { isValueExpression, isResourceLocatorValue } from '@/utils';
|
||||
import { isResourceLocatorValue } from '@/utils/typeGuards';
|
||||
import { isValueExpression } from '@/utils/nodeTypesUtils';
|
||||
import { i18n } from '@/plugins/i18n';
|
||||
|
||||
export default defineComponent({
|
||||
|
|
|
@ -128,17 +128,17 @@ import {
|
|||
VIEWS,
|
||||
} from '@/constants';
|
||||
import { workflowHelpers } from '@/mixins/workflowHelpers';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import Modal from '@/components/Modal.vue';
|
||||
import type { IFormInputs, IPersonalizationLatestVersion, IUser } from '@/Interface';
|
||||
import { getAccountAge } from '@/utils';
|
||||
import { getAccountAge } from '@/utils/userUtils';
|
||||
import type { GenericValue } from 'n8n-workflow';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useSettingsStore } from '@/stores/settings.store';
|
||||
import { useRootStore } from '@/stores/n8nRoot.store';
|
||||
import { useUsersStore } from '@/stores/users.store';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
import { usePostHog } from '@/stores';
|
||||
import { usePostHog } from '@/stores/posthog.store';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'PersonalizationModal',
|
||||
|
|
|
@ -156,12 +156,8 @@ import { useNDVStore } from '@/stores/ndv.store';
|
|||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { useUIStore } from '@/stores/ui.store';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import {
|
||||
getAppNameFromNodeName,
|
||||
getMainAuthField,
|
||||
hasOnlyListMode,
|
||||
isResourceLocatorValue,
|
||||
} from '@/utils';
|
||||
import { getAppNameFromNodeName, getMainAuthField, hasOnlyListMode } from '@/utils/nodeTypesUtils';
|
||||
import { isResourceLocatorValue } from '@/utils/typeGuards';
|
||||
import stringify from 'fast-json-stable-stringify';
|
||||
import type { EventBus } from 'n8n-design-system/utils';
|
||||
import { createEventBus } from 'n8n-design-system/utils';
|
||||
|
|
|
@ -14,9 +14,13 @@ import ParameterIssues from '@/components//ParameterIssues.vue';
|
|||
import ParameterOptions from '@/components//ParameterOptions.vue';
|
||||
import { computed } from 'vue';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import { useNDVStore } from '@/stores';
|
||||
import { fieldCannotBeDeleted, isMatchingField, parseResourceMapperFieldName } from '@/utils';
|
||||
import { useNodeSpecificationValues } from '@/composables';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import {
|
||||
fieldCannotBeDeleted,
|
||||
isMatchingField,
|
||||
parseResourceMapperFieldName,
|
||||
} from '@/utils/nodeTypesUtils';
|
||||
import { useNodeSpecificationValues } from '@/composables/useNodeSpecificationValues';
|
||||
|
||||
interface Props {
|
||||
parameter: INodeProperties;
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
import type { INodePropertyTypeOptions, ResourceMapperFields } from 'n8n-workflow';
|
||||
import { computed, ref, watch } from 'vue';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import { useNodeSpecificationValues } from '@/composables';
|
||||
import { useNodeSpecificationValues } from '@/composables/useNodeSpecificationValues';
|
||||
|
||||
interface Props {
|
||||
initialValue: string;
|
||||
|
|
|
@ -7,7 +7,7 @@ import type {
|
|||
} from 'n8n-workflow';
|
||||
import { computed, reactive, watch } from 'vue';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import { useNodeSpecificationValues } from '@/composables';
|
||||
import { useNodeSpecificationValues } from '@/composables/useNodeSpecificationValues';
|
||||
import ParameterOptions from '@/components/ParameterOptions.vue';
|
||||
|
||||
interface Props {
|
||||
|
|
|
@ -15,7 +15,8 @@ import { computed, onMounted, reactive, watch } from 'vue';
|
|||
import MappingModeSelect from './MappingModeSelect.vue';
|
||||
import MatchingColumnsSelect from './MatchingColumnsSelect.vue';
|
||||
import MappingFields from './MappingFields.vue';
|
||||
import { fieldCannotBeDeleted, isResourceMapperValue, parseResourceMapperFieldName } from '@/utils';
|
||||
import { fieldCannotBeDeleted, parseResourceMapperFieldName } from '@/utils/nodeTypesUtils';
|
||||
import { isResourceMapperValue } from '@/utils/typeGuards';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
|
||||
|
|
|
@ -612,11 +612,13 @@ import { pinData } from '@/mixins/pinData';
|
|||
import type { PinDataSource } from '@/mixins/pinData';
|
||||
import CodeNodeEditor from '@/components/CodeNodeEditor/CodeNodeEditor.vue';
|
||||
import { dataPinningEventBus } from '@/event-bus';
|
||||
import { clearJsonKey, executionDataToJson, isEmpty, searchInObject } from '@/utils';
|
||||
import { clearJsonKey, isEmpty } from '@/utils/typesUtils';
|
||||
import { executionDataToJson } from '@/utils/nodeTypesUtils';
|
||||
import { searchInObject } from '@/utils/objectUtils';
|
||||
import { useWorkflowsStore } from '@/stores/workflows.store';
|
||||
import { useNDVStore } from '@/stores/ndv.store';
|
||||
import { useNodeTypesStore } from '@/stores/nodeTypes.store';
|
||||
import { useToast } from '@/composables';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { isObject } from 'lodash-es';
|
||||
|
||||
const RunDataTable = defineAsyncComponent(async () => import('@/components/RunDataTable.vue'));
|
||||
|
|
|
@ -68,7 +68,9 @@ import { ref, onMounted } from 'vue';
|
|||
import type { ParsedAiContent } from './useAiContentParsers';
|
||||
import { useAiContentParsers } from './useAiContentParsers';
|
||||
import VueMarkdown from 'vue-markdown-render';
|
||||
import { useCopyToClipboard, useI18n, useToast } from '@/composables';
|
||||
import { useCopyToClipboard } from '@/composables/useCopyToClipboard';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useToast } from '@/composables/useToast';
|
||||
import { NodeConnectionType, type IDataObject } from 'n8n-workflow';
|
||||
|
||||
const props = defineProps<{
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue