From 9ab3d5bf9e866d92455b552c85cf4aff224d4fda Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Thu, 27 Nov 2025 16:49:08 +0000 Subject: [PATCH] fix(mobile): pass format to SaveAs With direct access, used in the mobile app, `args.format` was typoed as `args.Format`, leading to format always being undefined. This meant that the save as popup would use the extension of the current file rather than the extension you were trying to save as. You could workaround by editing this manually, but it was annoying and not working as intended. The browser version wasn't broken, as it uses a different code path to save documents (see src/mixins/saveAs.js) Signed-off-by: Skyler Grey --- cypress/e2e/direct.spec.js | 7 +------ src/document.js | 2 +- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/cypress/e2e/direct.spec.js b/cypress/e2e/direct.spec.js index 87541e845..902eb7451 100644 --- a/cypress/e2e/direct.spec.js +++ b/cypress/e2e/direct.spec.js @@ -183,12 +183,7 @@ describe('Direct editing (legacy)', function() { .should('be.visible') cy.get('.saveas-dialog input[type=text]') .should('be.visible') - .should('have.value', 'document.odt') - - cy.get('.saveas-dialog input[type=text]') - .clear() - cy.get('.saveas-dialog input[type=text]') - .type('/document.rtf') + .should('have.value', 'document.rtf') cy.get('.saveas-dialog button.button-vue--vue-primary').click() diff --git a/src/document.js b/src/document.js index 60f923496..b12110730 100644 --- a/src/document.js +++ b/src/document.js @@ -474,7 +474,7 @@ const documentsMain = { SaveAs, { path: documentsMain.fileName, - format: args.Format, + format: args.format, }, (value) => value && PostMessages.sendWOPIPostMessage('loolframe', 'Action_SaveAs', { Filename: value, Notify: true }), )