Skip to content

Commit

Permalink
fix: Move to @nextcloud/dialogs v5 for FilePicker
Browse files Browse the repository at this point in the history
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
  • Loading branch information
susnux authored and juliushaertl committed Oct 23, 2023
1 parent 4ab97f2 commit 32e1874
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 537 deletions.
7 changes: 4 additions & 3 deletions cypress/e2e/nodes/Links.spec.js
Expand Up @@ -142,9 +142,10 @@ describe('test link marks', function() {
// Helper to reduce duplicated code, checking inserting with and without selected text
const checkLinkFile = (filename, text) => {
cy.getSubmenuEntry('insert-link', 'insert-link-file').click()
const basename = filename.replace(/(.*)\.[^.]*/, '$1')
cy.get(`.file-picker__main .file-picker__file-name[title="${basename}"]`).click()
cy.get('.dialog__actions button.button-vue--vue-primary').click()
cy.get('.file-picker').within(() => {
cy.get(`[data-testid="file-list-row"][data-filename="${fileName}"]`).click()
cy.contains('button', `Choose ${fileName}`).click()
})

return cy.getContent()
.find(`a[href*="${encodeURIComponent(filename)}"]`)
Expand Down

0 comments on commit 32e1874

Please sign in to comment.