mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
feat(editor): Add RAG starter template callouts experiment (#16282)
Co-authored-by: Charlie Kolb <charlie@n8n.io>
This commit is contained in:
31
cypress/composables/nodeCreator.ts
Normal file
31
cypress/composables/nodeCreator.ts
Normal file
@@ -0,0 +1,31 @@
|
||||
// Getters
|
||||
export const nodeCreatorPlusButton = () => cy.getByTestId('node-creator-plus-button');
|
||||
export const canvasAddButton = () => cy.getByTestId('canvas-add-button');
|
||||
export const searchBar = () => cy.getByTestId('search-bar');
|
||||
export const getCategoryItem = (label: string) => cy.get(`[data-keyboard-nav-id="${label}"]`);
|
||||
export const getCreatorItem = (label: string) =>
|
||||
getCreatorItems().contains(label).parents('[data-test-id="item-iterator-item"]');
|
||||
export const getNthCreatorItem = (n: number) => getCreatorItems().eq(n);
|
||||
export const nodeCreator = () => cy.getByTestId('node-creator');
|
||||
export const nodeCreatorTabs = () => cy.getByTestId('node-creator-type-selector');
|
||||
export const selectedTab = () => nodeCreatorTabs().find('.is-active');
|
||||
export const categorizedItems = () => cy.getByTestId('categorized-items');
|
||||
export const getCreatorItems = () => cy.getByTestId('item-iterator-item');
|
||||
export const categoryItem = () => cy.getByTestId('node-creator-category-item');
|
||||
export const communityNodeTooltip = () => cy.getByTestId('node-item-community-tooltip');
|
||||
export const noResults = () => cy.getByTestId('node-creator-no-results');
|
||||
export const nodeItemName = () => cy.getByTestId('node-creator-item-name');
|
||||
export const nodeItemDescription = () => cy.getByTestId('node-creator-item-description');
|
||||
export const activeSubcategory = () => cy.getByTestId('nodes-list-header');
|
||||
export const expandedCategories = () =>
|
||||
getCreatorItems().find('>div').filter('.active').invoke('text');
|
||||
|
||||
// Actions
|
||||
export const openNodeCreator = () => {
|
||||
nodeCreatorPlusButton().click();
|
||||
nodeCreator().should('be.visible');
|
||||
};
|
||||
|
||||
export const selectNode = (displayName: string) => {
|
||||
getCreatorItem(displayName).click();
|
||||
};
|
||||
Reference in New Issue
Block a user