diff options
| author | Cj-bc <cj.bc-sd@outlook.jp> | 2021-02-13 17:50:51 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-13 17:50:51 +0900 |
| commit | 6477ad2cfc2198aa9e974a1879412b46366e1e94 (patch) | |
| tree | fcc7ea349e6c2646297ac557b52a639a98249a6a /src/models | |
| parent | fix #7189 (diff) | |
| download | sharkey-6477ad2cfc2198aa9e974a1879412b46366e1e94.tar.gz sharkey-6477ad2cfc2198aa9e974a1879412b46366e1e94.tar.bz2 sharkey-6477ad2cfc2198aa9e974a1879412b46366e1e94.zip | |
packedNoteSchemaの更新漏れを修正 (#7174) (#7190)
Add 'localOnly' to packedNoteSchema
Related: #7174
Add 'emojis' to packedNoteSchema
Add 'reactions' to packedNoteSchema
Related: #7174
Add 'renoteCount' to packedNoteSchema
Related: #7174
Add 'repliesCount' to packedNoteSchema
Add 'uri' to packedNoteSchema
Add 'url' to packedNoteSchema
Add: _featuredId_ to packedNoteSchema
Add '_prId_' to packedNoteSchema
Add 'myReaction' to packedNoteSchema
Diffstat (limited to 'src/models')
| -rw-r--r-- | src/models/repositories/note.ts | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/src/models/repositories/note.ts b/src/models/repositories/note.ts index 87ca5eb9ec..32552db2fe 100644 --- a/src/models/repositories/note.ts +++ b/src/models/repositories/note.ts @@ -412,5 +412,63 @@ export const packedNoteSchema = { optional: true as const, nullable: true as const, ref: 'Channel' }, + localOnly: { + type: 'boolean' as const, + optional: false as const, nullable: true as const, + }, + emojis: { + type: 'array' as const, + optional: false as const, nullable: false as const, + items: { + type: 'object' as const, + optional: false as const, nullable: false as const, + properties: { + name: { + type: 'string' as const, + optional: false as const, nullable: false as const, + }, + url: { + type: 'string' as const, + optional: false as const, nullable: false as const, + }, + }, + }, + }, + reactions: { + type: 'object' as const, + optional: false as const, nullable: false as const, + description: 'Key is either Unicode emoji or custom emoji, value is count of that emoji reaction.', + }, + renoteCount: { + type: 'number' as const, + optional: false as const, nullable: false as const, + }, + repliesCount: { + type: 'number' as const, + optional: false as const, nullable: false as const, + }, + uri: { + type: 'string' as const, + optional: false as const, nullable: true as const, + description: 'The URI of a note. it will be null when the note is local.', + }, + url: { + type: 'string' as const, + optional: false as const, nullable: true as const, + description: 'The human readable url of a note. it will be null when the note is local.', + }, + _featuredId_: { + type: 'string' as const, + optional: false as const, nullable: true as const, + }, + _prId_: { + type: 'string' as const, + optional: false as const, nullable: true as const, + }, + myReaction: { + type: 'object' as const, + optional: true as const, nullable: true as const, + description: 'Key is either Unicode emoji or custom emoji, value is count of that emoji reaction.', + }, }, }; |