Merge pull request #839 from nextcloud/fix/838

Set primary color on default calendar creation
This commit is contained in:
Raimund Schlüßler 2020-01-28 20:52:28 +01:00 committed by GitHub
commit 43db153fed
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -533,7 +533,7 @@
.percentdone {
height: 3px;
border-radius: 2px 0 0 2px;
opacity: .75;
background-color: $color-primary;
}
}
}

View file

@ -62,7 +62,11 @@ export default {
.then((calendars) => {
// No calendars? Create a new one!
if (calendars.length === 0) {
this.$store.dispatch('appendCalendar', { displayName: this.$t('tasks', 'Tasks') })
let color = '#0082C9'
if (this.$OCA.Theming) {
color = this.$OCA.Theming.color
}
this.$store.dispatch('appendCalendar', { displayName: this.$t('tasks', 'Tasks'), color })
.then(() => {
this.fetchTasks()
})