Skip to content

feat: add confirmation dialog for file extension changes#49308

Merged
nfebe merged 2 commits into
masterfrom
feat/46528/ask-confirm-extension-change
Nov 19, 2024
Merged

feat: add confirmation dialog for file extension changes#49308
nfebe merged 2 commits into
masterfrom
feat/46528/ask-confirm-extension-change

Conversation

@nfebe

@nfebe nfebe commented Nov 15, 2024

Copy link
Copy Markdown
Contributor
  • 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 skjnldsv and susnux 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
Comment thread apps/files/src/store/renaming.ts Outdated
Comment thread apps/files/src/store/renaming.ts Outdated

@marcoambrosini marcoambrosini left a comment

Copy link
Copy Markdown
Member

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

Comment thread apps/files/src/store/renaming.ts Outdated
Comment thread apps/files/src/store/renaming.ts Outdated
Comment thread apps/files/src/store/renaming.ts Outdated
@susnux

susnux commented Nov 15, 2024

Copy link
Copy Markdown
Contributor

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.

Comment thread apps/files/src/store/renaming.ts
@marcoambrosini

marcoambrosini commented Nov 18, 2024

Copy link
Copy Markdown
Member

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

@nfebe nfebe left a comment

Copy link
Copy Markdown
Contributor Author

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

Comment thread apps/files/src/store/renaming.ts
@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 <fenn25.fn@gmail.com>
@nfebe nfebe force-pushed the feat/46528/ask-confirm-extension-change branch from a8a934f to 383d98c Compare November 19, 2024 15:49
@nfebe

nfebe commented Nov 19, 2024

Copy link
Copy Markdown
Contributor Author

/compile

Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
@nfebe nfebe merged commit af14ff0 into master Nov 19, 2024
@nfebe nfebe deleted the feat/46528/ask-confirm-extension-change branch November 19, 2024 20:15
@nfebe

nfebe commented Nov 19, 2024

Copy link
Copy Markdown
Contributor Author

/backport to stable30

@nfebe

nfebe commented Nov 19, 2024

Copy link
Copy Markdown
Contributor Author

/backport to stable29

@susnux

susnux commented Nov 19, 2024

Copy link
Copy Markdown
Contributor

backport to stable29
backport to stable30

We do not backport features, no?

@nfebe

nfebe commented Nov 19, 2024

Copy link
Copy Markdown
Contributor Author

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.

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

6 participants