-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(editor): Open template credential setup from collection (#7882)
Open the template credential setup when using a template from the collection view. NOTE! This feature is still behind a feature flag. To test, set: ```js localStorage.setItem('template-credentials-setup', 'true') ``` https://github.com/n8n-io/n8n/assets/10324676/46ccec7c-5a44-429e-99ad-1c10640e99e5
- Loading branch information
Showing
8 changed files
with
133 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
cypress/fixtures/Ecommerce_starter_pack_template_collection.json
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
export function visitTemplateCollectionPage(withFixture: Fixture) { | ||
cy.intercept( | ||
'GET', | ||
`https://api.n8n.io/api/templates/collections/${testData.ecommerceStarterPack.id}`, | ||
{ | ||
fixture: withFixture.fixture, | ||
}, | ||
).as('getTemplateCollection'); | ||
|
||
cy.visit(`/collections/${withFixture.id}`); | ||
|
||
cy.wait('@getTemplateCollection'); | ||
} | ||
|
||
export function clickUseWorkflowButtonByTitle(workflowTitle: string) { | ||
cy.getByTestId('template-card') | ||
.contains('[data-test-id=template-card]', workflowTitle) | ||
.realHover({ position: 'center' }) | ||
.findChildByTestId('use-workflow-button') | ||
.click({ force: true }); | ||
} | ||
|
||
export type Fixture = { | ||
id: number; | ||
fixture: string; | ||
}; | ||
|
||
export const testData = { | ||
ecommerceStarterPack: { | ||
id: 1, | ||
fixture: 'Ecommerce_starter_pack_template_collection.json', | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters