-
-
Notifications
You must be signed in to change notification settings - Fork 74
Conversation
- additional test
|
||
if (active && this.refs.textInput) { | ||
(this.refs.textInput as HTMLElement).focus(); | ||
if (active && document.activeElement !== input) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only force selection when the cell/input is first selected by the user
@@ -1,6 +1,6 @@ | |||
{ | |||
"name": "dash-table", | |||
"version": "3.0.0rc12", | |||
"version": "3.0.0rc13", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bump version
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This implements @Marc-Andre-Rivet's expected behaviour well.
However, I still think a dblclick
event should still be handled the same as the "click, click again" behaviour mentioned above, in order to fully resolve #77 (thoughts @cldougl ?). It might be tricky as a dblclick
will trigger two click
events and one dblclick
, for three events total.
best I've got so far
suggests this is a WIP. So approval from me pending my (nit) comment below about the CHANGELOG
.
CHANGELOG.md
Outdated
@@ -100,3 +100,7 @@ | |||
Issue: https://github.com/plotly/dash-table/issues/68 | |||
Issue: https://github.com/plotly/dash-table/issues/73 | |||
Issue: https://github.com/plotly/dash-table/issues/76 | |||
|
|||
## RC13 - Modify click & dblclick behavior |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's misleading to state that dblclick
event handling has been modified in this PR, as dblclick
is a technical term for the event and its behaviour remains the same. I would prefer "double click", "x2 click", "sequential click" etc. just to be crystal clear.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updating the changelog. You are right, this is not a definitive answer, just the simplest implementation that goes one step towards the desired one.
@wbrgss Update changelog.md as per your comments, let me know if good enough |
agreed on:
as this is a semi-WIP I think this is great so far as it brings the behaviour closer to what excel users will expect. We should still be open about further developing the click/dblclick events as more people continue to use the table |
lgtm 💃 |
This brings the overall behavior closer to Excel's and reduces expectation gap for the end-user.
-> single click: focuses on the input and selects all content
-> click a second time to insert at a specific position