Skip to content

fix(chore): save new event even with empty title - #8556

Open
max65482 wants to merge 1 commit into
nextcloud:mainfrom
max65482:fix/create-event-without-title
Open

fix(chore): save new event even with empty title#8556
max65482 wants to merge 1 commit into
nextcloud:mainfrom
max65482:fix/create-event-without-title

Conversation

@max65482

Copy link
Copy Markdown
Contributor

Fixes #8543

Signed-off-by: Maximilian Martin <maximilian_martin@gmx.de>
@SebastianKrupinski

Copy link
Copy Markdown
Contributor

Thank for the PR @max65482

@odzhychko What do you think?

The fix is correct. But I am wondering if that is the correct behavior, should we allow someone to save an event with a empty title? I mean there is a minimum amount of in formation required to have a use full event displayed in the calendar. Would any one ever want a event with no title?

@codecov

codecov Bot commented Jun 29, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/mixins/EditorMixin.js 0.00% 1 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@odzhychko

Copy link
Copy Markdown
Contributor

Thank for the PR @max65482

@odzhychko What do you think?

The fix is correct. But I am wondering if that is the correct behavior, should we allow someone to save an event with a empty title? I mean there is a minimum amount of in formation required to have a use full event displayed in the calendar. Would any one ever want a event with no title?

Hm, I still think it is (the more) correct behavior, because an event created like this still has a date and a time.
Hypothetically, It could be useful if one wants to create unnamed blockers 🤷

The next best behavior, I can think of, would be to disable the save button until something has changed.
Still a user could type in some title, then remove the title, save the event and have the same result.
That would be just inconsistent 😄

@SebastianKrupinski

Copy link
Copy Markdown
Contributor

Hm, I still think it is (the more) correct behavior, because an event created like this still has a date and a time. Hypothetically, It could be useful if one wants to create unnamed blockers 🤷

Okay, if we let people create events with out a title we should force a generic time at creation time (In my option)

The next best behavior, I can think of, would be to disable the save button until something has changed. Still a user could type in some title, then remove the title, save the event and have the same result. That would be just inconsistent 😄

That might the best solution, the only problem is the mark dirty trigger (this.calendarObjectInstance.eventComponent.markDirty()) is not reactive, I believe. I believe all the components and properties in eventComponent are not reactive.Would need to double check

@odzhychko

Copy link
Copy Markdown
Contributor

Okay, if we let people create events with out a title we should force a generic time at creation time (In my option)

I found no way to create an event without a date. A time is automatically set, when

  • using the "+ Event" button
  • clicking (or dragging) inside the calendar view
@max65482

max65482 commented Jul 5, 2026

Copy link
Copy Markdown
Contributor Author

I'd go with the principle of least surprise. Thunderbird, Outlook (old) and Outlook (new) let you create events with empty title. Outlook (new) asks you whether you want to save an event with empty title.

@odzhychko

Copy link
Copy Markdown
Contributor

I'd go with the principle of least surprise. Thunderbird, Outlook (old) and Outlook (new) let you create events with empty title. Outlook (new) asks you whether you want to save an event with empty title.

Sounds good. Thanks for checking and summarizing it.

@max65482

Copy link
Copy Markdown
Contributor Author

Not sure I got the essence from discussion. Should we allow unnamed events or prevent them?
I would personally vote for allowing them (people may be used to creating unnamed blockers in other calendar tools).

@odzhychko

Copy link
Copy Markdown
Contributor

I'd go with the principle of least surprise. Thunderbird, Outlook (old) and Outlook (new) let you create events with empty title. Outlook (new) asks you whether you want to save an event with empty title.

Google Calendar (web) also just allows creation with an empty title.

@odzhychko

Copy link
Copy Markdown
Contributor

Not sure I got the essence from discussion. Should we allow unnamed events or prevent them? I would personally vote for allowing them (people may be used to creating unnamed blockers in other calendar tools).

There was no explicit conclusion yet...

In summary these two options seem equally good in general:

  • just allow to save with an empty title
  • warn user when saving with an empty title (using a dialog with a button to confirm and abort)

@nimishavijay Could you please help us choose which is the most appropriate here for Nextcloud Calendar? 😄

Comment thread src/mixins/EditorMixin.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants