1
0

feat: convert navigation to script setup and ts

This commit is contained in:
Dominik Pschenitschni
2022-02-13 18:11:26 +01:00
committed by kolaente
parent b5f867cc66
commit 658ca4c955
8 changed files with 149 additions and 123 deletions

View File

@ -8,6 +8,9 @@ export default class AttachmentModel extends AbstractModel {
this.createdBy = new UserModel(this.createdBy)
this.file = new FileModel(this.file)
this.created = new Date(this.created)
/** @type {number} */
this.id
}
defaults() {

View File

@ -1,7 +1,7 @@
import AbstractModel from './abstractModel'
import UserModel from './user'
export default class ListModel extends AbstractModel {
export default class LinkShareModel extends AbstractModel {
constructor(data) {
// The constructor of AbstractModel handles all the default parsing.

View File

@ -24,6 +24,15 @@ export default class ListModel extends AbstractModel {
this.subscription = new SubscriptionModel(this.subscription)
}
/** @type {number} */
this.id
/** @type {boolean} */
this.isArchived
/** @type {number} */
this.position
this.created = new Date(this.created)
this.updated = new Date(this.updated)
}

View File

@ -11,6 +11,7 @@ export default class NamespaceModel extends AbstractModel {
this.hexColor = '#' + this.hexColor
}
/** @type {ListModel[]} */
this.lists = this.lists.map(l => {
return new ListModel(l)
})
@ -21,6 +22,15 @@ export default class NamespaceModel extends AbstractModel {
this.subscription = new SubscriptionModel(this.subscription)
}
/** @type {number} */
this.id
/** @type {string} */
this.title
/** @type {boolean} */
this.isArchived
this.created = new Date(this.created)
this.updated = new Date(this.updated)
}