1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Use palette search when selecting nodes

This commit is contained in:
Kazuhito Yokoi 2020-01-14 18:02:27 +09:00
parent ccc98370eb
commit 530bf22bd5

View File

@ -44,6 +44,9 @@ function addNode(type, x, y) {
previousY = previousY + flowLayout.heightInterval; previousY = previousY + flowLayout.heightInterval;
} }
} }
browser.waitForVisible('#red-ui-palette-search');
browser.setValue('//*[@id="red-ui-palette-search"]/div/input', type.replace(/([A-Z])/g,' $1').toLowerCase());
browser.pause(300);
browser.waitForVisible(palette.getId(type)); browser.waitForVisible(palette.getId(type));
browser.moveToObject(palette.getId(type)); browser.moveToObject(palette.getId(type));
browser.buttonDown(); browser.buttonDown();