mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
feat(editor): Add Alt+Meta+O keyboard shortcut for the About modal (#18530)
This commit is contained in:
@@ -448,4 +448,9 @@ describe('Canvas Node Manipulation and Navigation', () => {
|
|||||||
NDVDialog.actions.close();
|
NDVDialog.actions.close();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should open and close the about modal on keyboard shortcut', () => {
|
||||||
|
WorkflowPage.actions.hitOpenAbout();
|
||||||
|
cy.getByTestId('close-about-modal-button').click();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -390,6 +390,9 @@ export class WorkflowPage extends BasePage {
|
|||||||
hitDisableNodeShortcut: () => {
|
hitDisableNodeShortcut: () => {
|
||||||
cy.get('body').type('d');
|
cy.get('body').type('d');
|
||||||
},
|
},
|
||||||
|
hitOpenAbout: () => {
|
||||||
|
cy.get('body').type(`{alt}{${META_KEY}}o`);
|
||||||
|
},
|
||||||
hitCopy: () => {
|
hitCopy: () => {
|
||||||
this.actions.hitComboShortcut(`{${META_KEY}}`, 'c');
|
this.actions.hitComboShortcut(`{${META_KEY}}`, 'c');
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ import VersionUpdateCTA from '@/components/VersionUpdateCTA.vue';
|
|||||||
import { TemplateClickSource, trackTemplatesClick } from '@/utils/experiments';
|
import { TemplateClickSource, trackTemplatesClick } from '@/utils/experiments';
|
||||||
import { I18nT } from 'vue-i18n';
|
import { I18nT } from 'vue-i18n';
|
||||||
import { usePersonalizedTemplatesV2Store } from '@/experiments/templateRecoV2/stores/templateRecoV2.store';
|
import { usePersonalizedTemplatesV2Store } from '@/experiments/templateRecoV2/stores/templateRecoV2.store';
|
||||||
|
import { useKeybindings } from '@/composables/useKeybindings';
|
||||||
|
|
||||||
const becomeTemplateCreatorStore = useBecomeTemplateCreatorStore();
|
const becomeTemplateCreatorStore = useBecomeTemplateCreatorStore();
|
||||||
const cloudPlanStore = useCloudPlanStore();
|
const cloudPlanStore = useCloudPlanStore();
|
||||||
@@ -58,6 +59,9 @@ const telemetry = useTelemetry();
|
|||||||
const pageRedirectionHelper = usePageRedirectionHelper();
|
const pageRedirectionHelper = usePageRedirectionHelper();
|
||||||
const { getReportingURL } = useBugReporting();
|
const { getReportingURL } = useBugReporting();
|
||||||
|
|
||||||
|
useKeybindings({
|
||||||
|
ctrl_alt_o: () => handleSelect('about'),
|
||||||
|
});
|
||||||
useUserHelpers(router, route);
|
useUserHelpers(router, route);
|
||||||
|
|
||||||
// Template refs
|
// Template refs
|
||||||
|
|||||||
@@ -67,6 +67,7 @@ import {
|
|||||||
VIEWS,
|
VIEWS,
|
||||||
NDV_UI_OVERHAUL_EXPERIMENT,
|
NDV_UI_OVERHAUL_EXPERIMENT,
|
||||||
WORKFLOW_SETTINGS_MODAL_KEY,
|
WORKFLOW_SETTINGS_MODAL_KEY,
|
||||||
|
ABOUT_MODAL_KEY,
|
||||||
} from '@/constants';
|
} from '@/constants';
|
||||||
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
import { useSourceControlStore } from '@/stores/sourceControl.store';
|
||||||
import { useNodeCreatorStore } from '@/stores/nodeCreator.store';
|
import { useNodeCreatorStore } from '@/stores/nodeCreator.store';
|
||||||
@@ -139,6 +140,7 @@ import CanvasChatButton from '@/components/canvas/elements/buttons/CanvasChatBut
|
|||||||
import { useFocusPanelStore } from '@/stores/focusPanel.store';
|
import { useFocusPanelStore } from '@/stores/focusPanel.store';
|
||||||
import { useAITemplatesStarterCollectionStore } from '@/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store';
|
import { useAITemplatesStarterCollectionStore } from '@/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store';
|
||||||
import { useReadyToRunWorkflowsStore } from '@/experiments/readyToRunWorkflows/stores/readyToRunWorkflows.store';
|
import { useReadyToRunWorkflowsStore } from '@/experiments/readyToRunWorkflows/stores/readyToRunWorkflows.store';
|
||||||
|
import { useKeybindings } from '@/composables/useKeybindings';
|
||||||
|
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: 'NodeView',
|
name: 'NodeView',
|
||||||
@@ -254,6 +256,9 @@ const {
|
|||||||
const { extractWorkflow } = useWorkflowExtraction();
|
const { extractWorkflow } = useWorkflowExtraction();
|
||||||
const { applyExecutionData } = useExecutionDebugging();
|
const { applyExecutionData } = useExecutionDebugging();
|
||||||
useClipboard({ onPaste: onClipboardPaste });
|
useClipboard({ onPaste: onClipboardPaste });
|
||||||
|
useKeybindings({
|
||||||
|
ctrl_alt_o: () => uiStore.openModal(ABOUT_MODAL_KEY),
|
||||||
|
});
|
||||||
|
|
||||||
const isLoading = ref(true);
|
const isLoading = ref(true);
|
||||||
const isBlankRedirect = ref(false);
|
const isBlankRedirect = ref(false);
|
||||||
|
|||||||
Reference in New Issue
Block a user