feat: double tab edit side panel #5000
Conversation
|
@Omegaviv I suggest supporting renaming only through a double-tap when the view is selected. This is because there's a minimum waiting time for the double-click gesture, which could cause a delay when opening another view with a single click. |
|
@LucasXu0 If we just let them use double click edit option only to select views, it won't be of much use as a user will have to do three clicks to edit other than the selected view. How about a long press? |
|
@Omegaviv The long press action for renaming is not user-friendly. You can refer to the implementation of the gesture conflict handler for a solution. This widget triggers the onTap event immediately, without waiting for the doubleTap timeout. |
| onDoubleTap: isSelected ? (){ | ||
| NavigatorTextFieldDialog( | ||
| title: LocaleKeys.disclosureAction_rename.tr(), | ||
| autoSelectAllText: true, | ||
| value: widget.view.name, | ||
| maxLength: 256, | ||
| onConfirm: (newValue, _) { | ||
| context.read<ViewBloc>().add(ViewEvent.rename(newValue)); | ||
| }, | ||
| ).show(context); | ||
| } : null, |
There was a problem hiding this comment.
Seems like you didn't run the formatter.
|
@LucasXu0 can you close this, if there are no issues? |
Why do we close it? I think we can support temporarily editing the current view name by double-clicking it. |
This PR is for issue #4968, to edit side panel title with double click.
I directly used GestureDetector of SingleInnerViewItem, I could have also passed it as function call back but it will require having MultiBlocProvider.
I am new here, any feedback @annieappflowy ?
Feature Preview
PR Checklist