card title: prevent space and no text
Signed-off-by: Jakob Röhrl <jakob.roehrl@web.de>
This commit is contained in:
committed by
Julius Härtl
parent
0d447fff01
commit
7bddcb877c
@@ -227,6 +227,7 @@ import {
|
||||
getMonthNamesShort,
|
||||
} from '@nextcloud/l10n'
|
||||
import moment from '@nextcloud/moment'
|
||||
import { showError } from '@nextcloud/dialogs'
|
||||
|
||||
const markdownIt = new MarkdownIt({
|
||||
linkify: true,
|
||||
@@ -464,6 +465,10 @@ export default {
|
||||
this.descriptionSaving = false
|
||||
},
|
||||
updateTitle(newTitle) {
|
||||
if (newTitle.trim === '') {
|
||||
showError('Could not update card title')
|
||||
return
|
||||
}
|
||||
this.$set(this.copiedCard, 'title', newTitle)
|
||||
this.$store.dispatch('updateCardTitle', this.copiedCard).then(() => {
|
||||
this.titleEditable = false
|
||||
|
||||
Reference in New Issue
Block a user