Calendar New Event window should require a title ("null" events are saved)
Categories
(Calendar :: Dialogs, defect, P2)
Tracking
(thunderbird_esr78+ fixed)
People
(Reporter: mkmelin, Assigned: khushil324)
References
Details
Attachments
(2 files, 6 obsolete files)
15.23 KB,
patch
|
khushil324
:
review+
wsmwk
:
approval-comm-beta-
|
Details | Diff | Splinter Review |
15.33 KB,
patch
|
khushil324
:
review+
rjl
:
approval-comm-esr78+
|
Details | Diff | Splinter Review |
+++ This bug was initially created as a clone of Bug #1659380 +++
I notice it's also possible to save with no title at all entered which will create a "null" event.
Assignee | ||
Comment 1•4 years ago
|
||
Assignee | ||
Updated•4 years ago
|
Reporter | ||
Comment 2•4 years ago
|
||
Assignee | ||
Comment 3•4 years ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #2)
just .value is enough. But you already send the title, so you can let
updateTitle check the new title instead
It will be "New Event: event_name" or "New Task: task_name"(It appends prefix), so it's hard to check and "New Event" or "New Task" will be changed according to locale.
Assignee | ||
Comment 4•4 years ago
|
||
Comment 5•4 years ago
•
|
||
Assignee | ||
Comment 6•4 years ago
|
||
I have tried to cover all the test cases.
What I do here:
If a new event is created, all the buttons are disabled and menu items are hidden for both dialog and tab.
If user tried to create an event with drag and drop and then blurs it, dialog and tab will open up. If event name is still empty while he cancels it, we ask to delete that event.
Pressing enter in the dailog if event title is empty will no do anything.
Comment 7•4 years ago
|
||
Comment 8•4 years ago
|
||
Alex, when you get a chance, I'm curious about your UX take on this. When a user drags to create an event in the day or week view, it is no longer given a "New Event" title, instead the title starts out empty, and we want to prevent events from being saved with a missing/blank title. Currently if the user doesn't enter a title and blurs the new event by clicking somewhere else, the event dialog opens to allow adding a title. Then if the user closes the dialog without adding a title, what do we do? One option is ask if they want to delete the event. (The current patch does this.) Or we might want to do something instead of opening the dialog when an event without a title is blurred:
- delete the event
- give the event a placeholder title like "Untitled" (similar to previous behavior)
- prompt the user to enter a title or else delete the event
I think 2 or something like it makes sense to me. It doesn't disrupt the user's flow by opening a dialog and it avoids saving an event without a title value.
A new glitch: I just noticed that if I click an existing event to edit the title "inline" (no dialog) and leave the title empty/blank, and then click to blur, the dialog opens, but with the title intact, like I hadn't changed it.
Another glitch: if I open an existing event (that has a title) in the dialog and delete the title then close the dialog without saving, it asks if I want to save the changes. I save them, then the event in the week view shows "Untitled". So I was able to (re-)save an existing event without a title. Then if I then open the event again in the dialog, and close it again, it asks if I want to delete the item. (This is with Khushil's current patch.)
Assignee | ||
Comment 9•4 years ago
|
||
(In reply to Paul Morris [:pmorris] from comment #8)
Another glitch: if I open an existing event (that has a title) in the dialog and delete the title then close the dialog without saving, it asks if I want to save the changes. I save them, then the event in the week view shows "Untitled". So I was able to (re-)save an existing event without a title. Then if I then open the event again in the dialog, and close it again, it asks if I want to delete the item. (This is with Khushil's current patch.)
Ohh, I missed this case. I will disable the save button here then.
Assignee | ||
Comment 10•4 years ago
|
||
(In reply to Paul Morris [:pmorris] from comment #7)
The existing code here is already quite complex and I had trouble following
the logic around thegEventDelete
global variable. If possible it would
be good to avoid introducing a new global variable in this file, or if not
then document it some more?
gEventDelete is needed when we prompt the delete dialog box (we will open this delete dialog when the user tries to cancel the event with an empty title) and the user clicks on the delete button in the delete dialog box. Clicking on the delete button will again trigger the close window or tab event and the delete dialog will reappear because the event title will be still empty, it will end up in the loop. We want to avoid that.
Comment 11•4 years ago
|
||
Currently if the user doesn't enter a title and blurs the new event by clicking somewhere else, the event dialog opens to allow adding a title.
I think this shouldn't happen and we should always have a default title for events.
I think we have the solution right now since we have an already translated placeholder (New Event), so we should grab that and save it as title if the user saves the event without a written title.
Also on blur, we shouldn't open the dialog for edits, that's a bit jarring and unexpected.
Maybe the user wants to quickly reserve a slot in the calendar without writing anything, so we shouldn't force the user to edit an event if he/she doesn't want it.
My suggestion is to use the placeholder.
Assignee | ||
Comment 12•4 years ago
|
||
Comment 13•4 years ago
|
||
I was just discussing some of the details of this with Khushil on chat. I agree with Alex in comment 11, but I think "Untitled" would be a better placeholder to use, and we already have it as a translated string. (It is what is shown in an event in the calendar views when its title is null.)
Reason: "New Event" as a placeholder can be inaccurate and misleading because all events become old in the course of time. Also an event might already be an old already existing one that the user just deleted the title. So "Untitled" is better because it never becomes inaccurate/misleading.
Comment 14•4 years ago
|
||
Assignee | ||
Comment 15•4 years ago
|
||
Comment 16•4 years ago
|
||
Assignee | ||
Comment 17•4 years ago
|
||
Comment 18•4 years ago
|
||
Assignee | ||
Comment 19•4 years ago
|
||
Assignee | ||
Updated•4 years ago
|
Comment 20•4 years ago
|
||
Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/6d4b09b3b74e
Fix calendar new event window should require a title. r=pmorris DONTBUILD
Updated•4 years ago
|
Reporter | ||
Updated•4 years ago
|
Assignee | ||
Comment 21•4 years ago
|
||
Comment on attachment 9176563 [details] [diff] [review]
Bug-1663303_disable-save-close-no-title-event-5.patch
[Approval Request Comment]
Regression caused by (bug #): 1659380
User impact if declined: UX related to the event title needs to be improved.
Testing completed (on c-c, etc.):
Risk to taking this patch (and alternatives if risky): Low
Comment 22•4 years ago
|
||
Comment on attachment 9176563 [details] [diff] [review]
Bug-1663303_disable-save-close-no-title-event-5.patch
[Triage Comment]
This will be on 82 beta without uplift
[Triage Comment]
Comment 23•4 years ago
|
||
Comment on attachment 9176563 [details] [diff] [review]
Bug-1663303_disable-save-close-no-title-event-5.patch
[Triage Comment]
Approved for esr78
Comment 24•4 years ago
|
||
Uplifting failed. It looks like this bug depends on another one that renamed the test function from "invokeEventDialog" to "invokeNewEventDialog".
Khushil?
I will try look for it as well.
Comment 25•4 years ago
|
||
Bug 1575195 changed invokeEventDialog to invokeNewEventDialog as part of the work to split up to split the dialog into viewing and editing dialogs. That is not going to be uplifted. Khushil, could you make a version of this patch for 78?
Assignee | ||
Comment 26•4 years ago
|
||
Sure, will be uploading a patch for ESR 78 ASAP.
Updated•4 years ago
|
Comment 28•4 years ago
|
||
Comment on attachment 9179826 [details] [diff] [review]
Bug-1663303_disable-save-close-no-title-event_ESR78.patch
[Triage Comment]
Moved approval to ESR version of patch.
This will probably be held until 78.4.0 unless build2 of 78.3.2 becomes necessary.
Comment 29•4 years ago
|
||
bugherder uplift |
Thunderbird 78.3.3:
https://hg.mozilla.org/releases/comm-esr78/rev/fd10970ce284
Description
•