Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add confirmation dialog for file extension changes #49308

Merged
merged 2 commits into from
Nov 19, 2024

Conversation

nfebe
Copy link
Contributor

@nfebe nfebe commented Nov 15, 2024

  • Introduced a dialog to confirm if users want to proceed with changing the file extension.
  • Added handling for dialog visibility to prevent recursion. (Since it looks like use must press escape to stop rename???)

Resolves : #46528

Screenshot

Screenshot from 2024-11-15 13-14-35

Checklist

  • Tests

@nfebe nfebe requested review from susnux and skjnldsv November 15, 2024 12:16
@nfebe nfebe force-pushed the feat/46528/ask-confirm-extension-change branch from 04da216 to 9502ffd Compare November 15, 2024 12:20
Copy link
Member

@marcoambrosini marcoambrosini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would then maybe make the keep action primary instead of the renaming one

apps/files/src/store/renaming.ts Outdated Show resolved Hide resolved
apps/files/src/store/renaming.ts Outdated Show resolved Hide resolved
apps/files/src/store/renaming.ts Outdated Show resolved Hide resolved
@susnux
Copy link
Contributor

susnux commented Nov 15, 2024

I would then maybe make the keep action primary instead of the renaming one

It is not destructive (you can revert it) and initialized by the user so as a user I would expect my initiated action to be the primary one.

@marcoambrosini
Copy link
Member

marcoambrosini commented Nov 18, 2024

It is not destructive (you can revert it) and initialized by the user so as a user I would expect my initiated action to be the primary one.

It's not destructive for everyone, but for many users that are not very literate it could still be "sort of" destructive if they don't manage to revert it. So I think we should copy macos in this. People who really know what they're doing will follow through the action anyway.

Screenshot 2024-11-18 at 14 03 07

@nfebe nfebe force-pushed the feat/46528/ask-confirm-extension-change branch 2 times, most recently from fe99148 to d706aee Compare November 18, 2024 13:32
Copy link
Contributor Author

@nfebe nfebe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So handled 3 possibilities:

  • Adding file extension
  • Removing file extension
  • Changing file extension

@nfebe nfebe force-pushed the feat/46528/ask-confirm-extension-change branch from d706aee to a8a934f Compare November 18, 2024 16:00
@nfebe nfebe requested a review from marcoambrosini November 18, 2024 16:00
- Introduced a dialog to confirm if users want to proceed with changing the file extension.
- Added handling for dialog visibility to prevent recursion. (Since it looks like use must press escape to stop rename???)

Signed-off-by: nfebe <[email protected]>
@nfebe nfebe force-pushed the feat/46528/ask-confirm-extension-change branch from a8a934f to 383d98c Compare November 19, 2024 15:49
@nfebe
Copy link
Contributor Author

nfebe commented Nov 19, 2024

/compile

Signed-off-by: nextcloud-command <[email protected]>
@nfebe nfebe merged commit af14ff0 into master Nov 19, 2024
119 checks passed
@nfebe nfebe deleted the feat/46528/ask-confirm-extension-change branch November 19, 2024 20:15
@nfebe
Copy link
Contributor Author

nfebe commented Nov 19, 2024

/backport to stable30

@nfebe
Copy link
Contributor Author

nfebe commented Nov 19, 2024

/backport to stable29

@susnux
Copy link
Contributor

susnux commented Nov 19, 2024

backport to stable29
backport to stable30

We do not backport features, no?

@nfebe
Copy link
Contributor Author

nfebe commented Nov 19, 2024

We do not backport features, no?

I don't know about that but the reason I back-porting this is because it addressing something that is already experienced in previous versions as we have a github ticket reported.

@skjnldsv skjnldsv mentioned this pull request Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When changing file extension ask for confirmation
5 participants