mirror of
https://codeberg.org/yeentown/barkey
synced 2024-12-02 11:07:27 +00:00
becc4d2e54
* wip * fix * create migration * oops * fix front const * changelog * fix type * fix * wip * Revert "wip" This reverts commit 6cdb3600e280be3550b8b6353b2c7930f7b31438. * enumのこす * fix --------- Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
48 lines
1.2 KiB
TypeScript
48 lines
1.2 KiB
TypeScript
// ブラウザで直接表示することを許可するファイルの種類のリスト
|
|
// ここに含まれないものは application/octet-stream としてレスポンスされる
|
|
// SVGはXSSを生むので許可しない
|
|
export const FILE_TYPE_BROWSERSAFE = [
|
|
// Images
|
|
'image/png',
|
|
'image/gif',
|
|
'image/jpeg',
|
|
'image/webp',
|
|
'image/avif',
|
|
'image/apng',
|
|
'image/bmp',
|
|
'image/tiff',
|
|
'image/x-icon',
|
|
|
|
// OggS
|
|
'audio/opus',
|
|
'video/ogg',
|
|
'audio/ogg',
|
|
'application/ogg',
|
|
|
|
// ISO/IEC base media file format
|
|
'video/quicktime',
|
|
'video/mp4',
|
|
'audio/mp4',
|
|
'video/x-m4v',
|
|
'audio/x-m4a',
|
|
'video/3gpp',
|
|
'video/3gpp2',
|
|
|
|
'video/mpeg',
|
|
'audio/mpeg',
|
|
|
|
'video/webm',
|
|
'audio/webm',
|
|
|
|
'audio/aac',
|
|
'audio/x-flac',
|
|
'audio/vnd.wave',
|
|
];
|
|
/*
|
|
https://github.com/sindresorhus/file-type/blob/main/supported.js
|
|
https://github.com/sindresorhus/file-type/blob/main/core.js
|
|
https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Containers
|
|
*/
|
|
|
|
export const notificationTypes = ['follow', 'mention', 'reply', 'renote', 'quote', 'reaction', 'pollEnded', 'receiveFollowRequest', 'followRequestAccepted', 'achievementEarned', 'app'] as const;
|
|
export const obsoleteNotificationTypes = ['pollVote', 'groupInvited'] as const;
|