mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 18:41:14 +00:00
refactor(editor): Extract @n8n/i18n package for internationalization (no-changelog) (#15466)
This commit is contained in:
@@ -17,7 +17,7 @@ import ImportCurlParameter from '@/components/ImportCurlParameter.vue';
|
||||
import MultipleParameter from '@/components/MultipleParameter.vue';
|
||||
import ParameterInputFull from '@/components/ParameterInputFull.vue';
|
||||
import ResourceMapper from '@/components/ResourceMapper/ResourceMapper.vue';
|
||||
import { useI18n } from '@/composables/useI18n';
|
||||
import { useI18n } from '@n8n/i18n';
|
||||
import { useNodeHelpers } from '@/composables/useNodeHelpers';
|
||||
import { useWorkflowHelpers } from '@/composables/useWorkflowHelpers';
|
||||
import {
|
||||
@@ -39,6 +39,7 @@ import { computedWithControl } from '@vueuse/core';
|
||||
import { get, set } from 'lodash-es';
|
||||
import { N8nIcon, N8nIconButton, N8nInputLabel, N8nNotice, N8nText } from '@n8n/design-system';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { storeToRefs } from 'pinia';
|
||||
|
||||
const LazyFixedCollectionParameter = defineAsyncComponent(
|
||||
async () => await import('./FixedCollectionParameter.vue'),
|
||||
@@ -77,6 +78,8 @@ const router = useRouter();
|
||||
const workflowHelpers = useWorkflowHelpers({ router });
|
||||
const i18n = useI18n();
|
||||
|
||||
const { activeNode } = storeToRefs(ndvStore);
|
||||
|
||||
onErrorCaptured((e, component) => {
|
||||
if (
|
||||
!['LazyFixedCollectionParameter', 'LazyCollectionParameter'].includes(
|
||||
@@ -558,7 +561,7 @@ function getParameterValue<T extends NodeParameterValueType = NodeParameterValue
|
||||
<N8nNotice
|
||||
v-else-if="parameter.type === 'notice'"
|
||||
:class="['parameter-item', parameter.typeOptions?.containerClass ?? '']"
|
||||
:content="i18n.nodeText().inputLabelDisplayName(parameter, path)"
|
||||
:content="i18n.nodeText(activeNode?.type).inputLabelDisplayName(parameter, path)"
|
||||
@action="onNoticeAction"
|
||||
/>
|
||||
|
||||
@@ -577,8 +580,8 @@ function getParameterValue<T extends NodeParameterValueType = NodeParameterValue
|
||||
class="multi-parameter"
|
||||
>
|
||||
<N8nInputLabel
|
||||
:label="i18n.nodeText().inputLabelDisplayName(parameter, path)"
|
||||
:tooltip-text="i18n.nodeText().inputLabelDescription(parameter, path)"
|
||||
:label="i18n.nodeText(activeNode?.type).inputLabelDisplayName(parameter, path)"
|
||||
:tooltip-text="i18n.nodeText(activeNode?.type).inputLabelDescription(parameter, path)"
|
||||
size="small"
|
||||
:underline="true"
|
||||
:input-name="parameter.name"
|
||||
|
||||
Reference in New Issue
Block a user