forms icon indicating copy to clipboard operation
forms copied to clipboard

fix: transfer ownership confirmation string formatting

Open AIlkiv opened this issue 1 month ago • 7 comments

Before:

https://github.com/user-attachments/assets/19fcddf9-1d82-4cb9-a364-f20cd0832f49

After:

https://github.com/user-attachments/assets/16f951c7-b932-40ab-afbe-fa88f509508e

AIlkiv avatar Nov 23 '25 14:11 AIlkiv

@AIlkiv nice catch. But I'm wondering if we shouldn't disallow line breaks in the title in the first place (they should then be cleaned up in the backend, too)

@susnux what do you think?

Chartman123 avatar Nov 23 '25 14:11 Chartman123

But I'm wondering if we shouldn't disallow line breaks in the title in the first place (they should then be cleaned up in the backend, too)

Agree!

susnux avatar Nov 24 '25 18:11 susnux

@AIlkiv could you please add the changes to disallow line breaks (and possibly tabs) in the title to the front and backend?

What about existing titles in the database? should we add a migration, too?

Chartman123 avatar Nov 24 '25 18:11 Chartman123

@Chartman123 If I do this on the backend when saving, will it be okay?

AIlkiv avatar Nov 25 '25 05:11 AIlkiv

@AIlkiv I've added an event handler to the title to prevent adding new lines, but I think that we should also adjust onTitleChange to handle copy/paste actions that already include line breaks.

If we just sanitize the string on saving in the backend the user might wonder why the title looks different after saving the form. Instead the API could throw an error if the title contains unwanted characters.

Chartman123 avatar Nov 25 '25 08:11 Chartman123

@Chartman123 Thank you, I understand. I will try to finish it according to your comment.

AIlkiv avatar Dec 05 '25 06:12 AIlkiv

Hello there, Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

github-actions[bot] avatar Dec 08 '25 02:12 github-actions[bot]