mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
feat(editor): Enable NodeView version switcher by default on internal (no-changelog) (#10356)
This commit is contained in:
@@ -96,9 +96,17 @@ const importFileRef = ref<HTMLInputElement | undefined>();
|
||||
const tagsEventBus = createEventBus();
|
||||
const sourceControlModalEventBus = createEventBus();
|
||||
|
||||
const nodeViewSwitcher = useLocalStorage('NodeView.switcher', import.meta.env.DEV ? 'true' : '');
|
||||
const nodeViewSwitcher = useLocalStorage('NodeView.switcher', '');
|
||||
const nodeViewVersion = useLocalStorage('NodeView.version', '1');
|
||||
|
||||
const isNodeViewSwitcherEnabled = computed(() => {
|
||||
return (
|
||||
import.meta.env.DEV ||
|
||||
nodeViewSwitcher.value === 'true' ||
|
||||
settingsStore.deploymentType === 'n8n-internal'
|
||||
);
|
||||
});
|
||||
|
||||
const hasChanged = (prev: string[], curr: string[]) => {
|
||||
if (prev.length !== curr.length) {
|
||||
return true;
|
||||
@@ -184,7 +192,7 @@ const workflowMenuItems = computed<ActionDropdownItem[]>(() => {
|
||||
disabled: !onWorkflowPage.value || isNewWorkflow.value,
|
||||
});
|
||||
|
||||
if (nodeViewSwitcher.value === 'true') {
|
||||
if (isNodeViewSwitcherEnabled.value) {
|
||||
actions.push({
|
||||
id: WORKFLOW_MENU_ACTIONS.SWITCH_NODE_VIEW_VERSION,
|
||||
label:
|
||||
|
||||
Reference in New Issue
Block a user