Implement existing API types
This commit is contained in:
parent
e76490f637
commit
a6291fd098
14 changed files with 108 additions and 21 deletions
30
frontend-reactive/app/models/account.ts
Normal file
30
frontend-reactive/app/models/account.ts
Normal file
|
@ -0,0 +1,30 @@
|
|||
import Model, { attr, hasMany, type AsyncHasMany } from '@ember-data/model'
|
||||
import type RemoteServerModel from './remote-server'
|
||||
import type CustomAccountFieldModel from './custom-account-field'
|
||||
import type MediaMetadataModel from './media-metadata'
|
||||
|
||||
export default class AccountModel extends Model {
|
||||
@attr declare createdAt: Date
|
||||
@attr declare updatedAt: Date
|
||||
@attr declare username: string
|
||||
@attr declare originServer: RemoteServerModel
|
||||
@attr declare originServerId: number
|
||||
@attr declare displayName: string
|
||||
@hasMany('custom-account-field')
|
||||
declare customFields: AsyncHasMany<CustomAccountFieldModel>
|
||||
@attr declare customFieldIds: Array<number>
|
||||
@attr declare isBot: boolean
|
||||
@attr declare description: string
|
||||
@attr declare icon: MediaMetadataModel
|
||||
@attr declare iconId: string
|
||||
@attr declare banner: MediaMetadataModel
|
||||
@attr declare bannerId: string
|
||||
@attr declare background: MediaMetadataModel
|
||||
@attr declare backgroundId: string
|
||||
@attr declare relationIds: Array<number>
|
||||
@attr declare indexable: boolean
|
||||
@attr declare restrictedFollow: boolean
|
||||
@attr declare identifiesAs: Array<string>
|
||||
@attr declare pronouns: Array<string>
|
||||
@attr declare roles: Array<string>
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue