Disable "enter" hotkeys only on tag input element

We are still able to use enter to submit the form on anyother input.The
tag input creates a new tag when enter is pressed
This commit is contained in:
Gaetan Craig-Riou
2025-04-15 15:10:32 +10:00
parent 6ff47eab3b
commit 31afdfd8c4
4 changed files with 16 additions and 13 deletions

View File

@@ -9,14 +9,6 @@ describe("BulkFormController", () => {
beforeAll(() => {
const application = Application.start();
application.register("bulk-form", bulk_form_controller);
// Mock hotkeys.js
const mockedHotkeys = jest.fn();
global.hotkeys = mockedHotkeys;
});
afterAll(() => {
delete global.hotkeys;
});
describe("Modifying input values", () => {

View File

@@ -9,6 +9,14 @@ describe("TagListInputController", () => {
beforeAll(() => {
const application = Application.start();
application.register("tag-list-input-component--tag-list-input", tag_list_input_controller);
// Mock hotkeys.js
const mockedHotkeys = jest.fn();
global.hotkeys = mockedHotkeys;
});
afterAll(() => {
delete global.hotkeys;
});
beforeEach(() => {