fix: use native validation for duplicate file names - #62767
Conversation
susnux
left a comment
There was a problem hiding this comment.
Blocking for a design decision on the issue first.
|
@susnux holding until the design call lands. This PR currently does option 1: keep the NcTextField helper and drop the proactive On the issue, @kra-mo leaned native if the tooltip is aligned correctly. That's the opposite of this patch. Happy to invert it (native reporting, drop the custom helper) or leave this as-is once you pick a lane. |
Show the name validity through the platform validation popup instead of the NcTextField helper text, so a duplicate name is only reported once. This matches the existing native validation of the rename input and the federated share dialog. Fixes nextcloud#62686 Co-authored-by: Matt Van Horn <mvanhorn@users.noreply.github.com>
|
@susnux inverted this to option 2 after @kra-mo's lean on the issue.
Happy to flip back if designers land on the helper instead. |
|
Hello there, 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.) |
Summary
Show the duplicate-name (and other filename) error through the platform validation popup instead of the NcTextField helper.
setCustomValiditystill blocks Create and Enter-key submit. The helper/error bindings are dropped so the same string is not shown twice.Same pattern as
FileEntryNameandPublicPageMenuExternalDialog.Fixes #62686