core/utils/Constants.ts
Junseo Park ae47f741b8
v2 Release (#154)
* chore(deps): update dependency typescript to v4.2.4 (#314)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency core-js to v3.10.1 (#315)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* feat: camo images in bot desc

* chore: added bot delete api

* feat: delete button working

* feat: added bot remove method

* chore: added csrfCaptchaSchema

* deps: update

* fix: some error at callback

* fix(deps): pin dependency abort-controller to 3.0.0 (#313)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/node-fetch to v2.5.10 (#316)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint-plugin-react to v7.23.2 (#317)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* style: fixed for deepscan

* chore: improved user login interaction

* fix(deps): update dependency @sentry/webpack-plugin to v1.15.0 (#318)

* chore(deps): update dependency eslint to v7.24.0 (#320)

* fix(deps): update dependency postcss to v8.2.10 (#321)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* ci: updated ci stuff

* style: removed unnecessary script

* fix: not using SENTRY_RELEASE env

* chore: defaulting mysql password

* chore: added sentry_dsn env and only uploading for master

* ci: updated trigger

* ci: passing source branch env only at push

* chore(deps): update typescript-eslint monorepo to v4.22.0 (#322)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint-config-prettier to v8.2.0 (#323)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/react-select to v4.0.15 (#325)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint-plugin-prettier to v3.4.0 (#326)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/sanitize-html to v2 (#328)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/node to v14.14.41 (#324)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency ts-jest to v26.5.5 (#327)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* ci: debugging

* Update components/DeveloperLayout.tsx

Co-authored-by: zero734kr <zero734kr@gmail.com>

* Update components/Loader.tsx

Co-authored-by: zero734kr <zero734kr@gmail.com>

* Update components/ColorCard.tsx

Co-authored-by: zero734kr <zero734kr@gmail.com>

* Update components/ColorCard.tsx

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(deps): update dependency core-js to v3.11.0 (#329)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/sanitize-html to v2.3.1 (#330)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency postcss to v8.2.13 (#333)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency tailwindcss to v2.1.2 (#334)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint to v7.25.0 (#335)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency @sentry/webpack-plugin to v1.15.1 (#332)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/node to v14.14.43 (#339)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/jest to v26.0.23 (#337)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint-config-prettier to v8.3.0 (#336)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/react to v17.0.4 (#338)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* Update utils/ShowdownExtensions.ts

Co-authored-by: zero734kr <zero734kr@gmail.com>

* style: fixed some styles

* chore: updated api-docs git

* refactor: made change on sentry

* style: removed debug code

* deps: removed node-mock

* ci: removed env

* style: code style

* test: module names

* chore: docker using python

* chore: docker using build-base

* ci: fixed syntax error

* chore: changed sql type

* feat: added vote

* fix: version for v1

* feat: added v1 bot vote check

* feat: clearing cache for deleted bot

* chore: delete bot real working

IMPORTANT: NOW DELETE BOT REAL WORKS!

* fix: router called at non-client

* style: removed space

* feat: added vote check endpoint

* fix: router called at non-client

* fix(deps): update sentry monorepo to v6.3.5 (#331)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency core-js to v3.11.2 (#340)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency @types/react to v17.0.5 (#345)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update typescript-eslint monorepo to v4.22.1 (#343)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix: BotCard button component rendered as Tag

* feat: update docs

* feat: using koreanbots cdn for og image

* fix: missing querystring label

* docs: some text change

https://github.com/koreanbots/v2-testing/issues/72#issuecomment-807929228

* fix: removed unexpected char

close: https://github.com/koreanbots/v2-testing/issues/76

* fix: redirecting at serverside

* fix(deps): pin dependencies (#342)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency ts-jest to v26.5.6 (#347)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency postcss to v8.2.14 (#349)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency core-js to v3.11.3 (#348)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix: router instance called at serverside while rendering

* Merge branch 'master' of https://github.com/koreanbots/koreanbots

* feat: Sentry enabled only at production

* fix: menu not closing

close: https://github.com/koreanbots/v2-testing/issues/50

* chore: improved mobile design

* fix: tooltip overflows screen

close: https://github.com/koreanbots/v2-testing/issues/28

* fix: router called at server-side

close: https://github.com/koreanbots/v2-testing/issues/77

* typo: fixed typo issue

* typo: improved typo

* fix: router called at serverside

* chore: removed custom scrollbar style

* style: fixed null checks

* feat: added owner transfer and edit

* chore: clearing cache for updates

* chore: redirecting on update

* chore: added button margin

* feat: disabled webhook

* chore: added some spaces

* feat: added padding for ad

* feat: remove wave

* feat: added security page

* chore: some margin

* feat: added bug reporters

* style: fixed eslint

* fix(developers): https://github.com/koreanbots/v2-testing/issues/74

* chore: improved ad

* feat: migrated to @sentry/nextjs

* fix: card invite button fixed

* chore: not releasing

* chore: debugging

* chore: skiping sentry auto release

* feat: added docker hub build hook

* fix: docker hook

* fix: docker hook geting sentry dsn as build-arg

* chore: added sentry envs

* chore(docker): cleanup

* fix: bugs at card

* typo: fixed

* chore: margin top at message

* fix: card building weird

* fix: sentry disabled

* fix: query string invalid

fix: https://github.com/koreanbots/v2-testing/issues/92

* fix: https://github.com/koreanbots/v2-testing/issues/94

* chore: improved style

close: https://github.com/koreanbots/v2-testing/issues/83

* fix: scrollbar shown even its not overflowed

fix: https://github.com/koreanbots/v2-testing/issues/86

* fix: home not displayed at dev portal

fix: https://github.com/koreanbots/v2-testing/issues/84

* types: searchParams is optional prop

* feat: added required field notice

close: https://github.com/koreanbots/v2-testing/issues/90

* typo: fixed typo issues

For https://github.com/koreanbots/v2-testing/issues/79

* fix: causing error on other git url

ISSUE: https://sentry.io/share/issue/a13341dc1aab4e5aa994fee8857afff7/

* fix: handle AbortError

* chore(deps): update dependency eslint to v7.26.0 (#353)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency core-js to v3.12.1 (#350)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore: reordered bot section

* typo: fixed typo issue

from https://github.com/koreanbots/v2-testing/issues/79

* feat: opening new tab for discord link

close: https://github.com/koreanbots/v2-testing/issues/99

* feat: added opensearch

* Update renovate.json

* chore: prevent clickjacking

* chore: added moz SearchForm for opensearch xml

* fix(deps): update dependency rc-tooltip to v5 (#351)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update sentry monorepo to v6.3.6 (#354)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency prettier to v2.3.0 (#355)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update typescript-eslint monorepo to v4.23.0 (#356)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency postcss to v8.2.15 (#357)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency react-select to v4.3.1 (#358)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* fix(deps): update dependency knex to v0.95.5 (#359)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* style: added space

* feat: added get botSubmits list api

* chore: updated endpoint

* typo: fixed and improved typo issues

* chore: improved message for empty category

close: https://github.com/koreanbots/v2-testing/issues/100

* feat: support pwa

* types: added missing typing

* chore: changed manifest

* fix: catching error for ga blocked

* fix: added missing argument

* chore: made some changes

* style: could be null

* chore: improved pwa

* fix: https://github.com/koreanbots/v2-testing/issues/105

* feat: added staff missing permission

* fix: https://github.com/koreanbots/v2-testing/issues/104

* feat: added width style

* Update pages/_app.tsx

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* style: suggestions at review

* feat: updated api-docs

* chore: added dest option

* chore: changed icon path

* feat: just commiting service worker

* feat: added bug bounty group

* ci: removed reviewdog

* feat: added google optimize

* chore: added maskable icon and changed short_name

* ci: made some changes on renovate

* Create SECURITY.md

* feat: fetching docs from github

* feat: added tos at footer

* feat(iOS): added pwa splash screen

* types: improved component typing

* feat: discord rebranded

* ci: configured renovate ignore

* [TYPO] 기여 규칙 링크 수정 (#367)

* fix(deps): update sentry monorepo to v6.4.0 (#364)

* feat: added logging

* style: reordered import

* feat: improved logging

* feat: private api changes

* feat: added OG

* chore: updated migrate.sql

* ci: updated renovate

* fix: seo

* feat: added approve api

* chore: some changes at deny

* feat: added approve

* refactor: using next-seo for seo

* ci(renovate): removed unused option

* chore: not passing pwa at navbar

* style: removed line break

* fix: https://github.com/koreanbots/v2-testing/issues/89

* feat: directly fetching from discord

* feat: support searching with index

* style: fix deepscan

* fix: invalid avatar url

* fix: https://github.com/koreanbots/v2-testing/issues/110

reopen: https://github.com/koreanbots/v2-testing/issues/89

* feat: added error message at submit button

* fix: https://github.com/koreanbots/v2-testing/issues/89

* feat: added deny presets article

* feat: added query aliases

* chore: update docs

* chore: remvoed empty file

* feat: increased ratelimit

* feat: added bot lists

* style: removed unused variable

* fix(deps): update dependency knex to v0.95.6 (#365)

* chore(deps): update typescript-eslint monorepo to v4.24.0 (#366)

* chore(deps): update dependency @types/react to v17.0.6 (#368)

* fix(deps): update dependency formik to v2.2.8 (#369)

* fix(deps): update dependency next to v10.2.2 (#370)

* fix(deps): update sentry monorepo to v6.4.1 (#371)

* fix(deps): update dependency sanitize-html to v2.4.0 (#372)

* fix(deps): update dependency postcss to v8.3.0 (#373)

* docs: updated license

* feat: added refresh data

* feat: better image size

close: https://github.com/koreanbots/v2-testing/issues/81

* chore: changed slogan

* fix: invalid v1 api

* fix: forbidden error

* feat: added char count at textarea

close: https://github.com/koreanbots/v2-testing/issues/112

* feat: changed edit page route

* fix(deps): update dependency next to v10.2.3 (#376)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency typescript to v4.3.2 (#383)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* chore(deps): update dependency eslint to v7.27.0 (#374)

Co-authored-by: Renovate Bot <bot@renovateapp.com>

* deps: removed core-js

* deps: lock updated

* feat: added stable docker compose file

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: zero734kr <zero734kr@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: MintyU <deathcat@outlook.kr>
2021-05-27 22:25:29 +09:00

446 lines
11 KiB
TypeScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { Bot, ImageOptions, KoreanbotsImageOptions } from '@types'
import { KeyMap } from 'react-hotkeys'
import { formatNumber, makeImageURL } from './Tools'
// Website META DATA
export const TITLE = '한국 디스코드봇 리스트'
export const DESCRIPTION = '다양한 국내 디스코드 봇들을 확인하고, 초대해보세요!'
export const THEME_COLOR = '#3366FF'
export const VOTE_COOLDOWN = 12 * 60 * 60 * 1000
export const BUG_REPORTERS = ['260303569591205888']
export const BUG_REPORT_GROUPS = ['경북소프트웨어고등학교 해킹방어 그룹']
export const Status = {
online: {
text: '온라인',
color: 'green-400',
},
idle: {
text: '자리 비움',
color: 'yellow-300',
},
dnd: {
text: '다른 용무중',
color: 'red-500',
},
offline: {
text: '오프라인',
color: 'gray-500',
},
streaming: {
text: '방송중',
color: 'purple-500'
},
null: {
text: '알 수 없음',
color: 'gray-500',
},
'???': {
text: '알 수 없음',
color: 'gray-500',
},
}
export const library = [
'discord.js',
'Eris',
'discord.py',
'discordcr',
'Nyxx',
'Discord.Net',
'DSharpPlus',
'Nostrum',
'coxir',
'DiscordGo',
'Discord4J',
'Javacord',
'JDA',
'Discordia',
'RestCord',
'Yasmin',
'disco',
'discordrb',
'serenity',
'SwiftDiscord',
'Sword',
'기타',
'비공개',
]
export const categories = [
// 상위 카테고리
'관리',
'뮤직',
'전적',
'게임',
'도박',
'로깅',
'빗금 명령어',
'웹 대시보드',
'밈',
'레벨링',
'유틸리티',
'대화',
'NSFW',
'검색',
// 검색
'학교',
'코로나19',
// 유틸리티
'번역',
// 전적
'오버워치',
'리그 오브 레전드',
'배틀그라운드',
'마인크래프트'
]
export const categoryIcon = {
'관리': 'fas fa-cogs',
'뮤직': 'fas fa-music',
'전적': 'fas fa-puzzle-piece',
'웹 대시보드': 'fas fa-sliders-h',
'로깅': 'fas fa-pencil-alt',
'빗금 명령어': null,
'도박': 'fas fa-money-bill-alt',
'게임': 'fas fa-gamepad',
'밈': 'fas fa-image',
'레벨링': 'fas fa-angle-double-up',
'유틸리티': 'fas fa-tools',
'번역': 'fas fa-language',
'대화': 'fas fa-comments',
'NSFW': 'fas fa-exclamation-triangle',
'검색': 'fas fa-search',
'학교': 'fas fa-school',
'코로나19': 'fas fa-viruses',
'오버워치': 'fas fa-mask',
'리그 오브 레전드': 'fas fa-chess',
'배틀그라운드': 'fas fa-meteor',
'마인크래프트': 'fas fa-cubes'
}
export const reportCats = [
'불법',
'괴롭힘, 모욕, 명예훼손',
'스팸, 도배, 의미없는 텍스트',
'폭력, 자해, 테러 옹호하거나 조장하는 컨텐츠',
'라이선스혹은 권리 침해',
'Discord ToS 위반',
'Koreanbots 가이드라인 위반',
'기타',
]
export const imageSafeHost = [
'koreanbots.dev',
'githubusercontent.com',
'cdn.discordapp.com'
]
export const MessageColor = {
success: 'bg-green-200 text-green-800',
error: 'bg-red-200 text-red-800',
warning: 'bg-yellow-50 text-yellow-700',
info: 'bg-blue-200 text-blue-800'
}
export const BASE_URLs = {
api: 'https://discord.com/api',
cdn: 'https://cdn.discordapp.com',
camo: 'https://camo.koreanbots.dev'
}
export const BotBadgeType = (data: Bot) => {
return {
servers: {
label: '서버수',
status: data.servers === 0 ? 'N/A' : formatNumber(data.servers),
color: '7289DA'
},
votes: {
label: '하트',
status: `${formatNumber(data.votes)}`,
color: 'ef4444'
},
status: {
label: '상태',
status: Status[data.status]?.text || '알 수 없음',
color: {
online: '34d399',
idle: 'fcd34d',
dnd: 'ef4444',
streaming: '8b5cf6'
}[data.status] || '6b7280'
}
}
}
export const DiscordEnpoints = {
Token: BASE_URLs.api + '/oauth2/token',
Me: BASE_URLs.api + '/v8/users/@me',
InviteApplication: (id: string, perms: { [perm: string]: boolean }, scope: string, redirect?: string): string => `${BASE_URLs.api}/oauth2/authorize?client_id=${id ? id.split(' ')[0] : 'CLIENT_ID'}&permissions=${Object.keys(perms).filter(el => perms[el]).map(el => Number(el)).reduce((prev, curr) => prev | curr, 0)}&scope=${scope ? encodeURI(scope) : 'bot'}${redirect ? `&redirect_uri=${encodeURIComponent(redirect)}` : ''}`,
CDN: class CDN {
static root = BASE_URLs.cdn
static emoji (id: string, options:ImageOptions={}) { return makeImageURL(`${this.root}/emojis/${id}`, options) }
static guild (id: string, hash: string, options:ImageOptions={}) { return makeImageURL(`${this.root}/icons/${id}/${hash}`, options) }
static default (tag: string|number, options:ImageOptions={}) { return makeImageURL(`${this.root}/embed/avatars/${!isNaN(Number(tag)) ? Number(tag) % 5 : 0}`, options) }
static user (id: string, hash: string, options:ImageOptions={}) { return makeImageURL(`${this.root}/avatars/${id}/${hash}`, options) }
}
}
export const KoreanbotsEndPoints = {
OG: class {
static root = 'https://og.kbots.link'
static origin = 'https://beta.koreanbots.dev'
static bot(id: string, name: string, bio: string, tags: string[], stats: string[]) {
const u = new URL(this.root)
u.pathname = name
u.searchParams.append('image', this.origin + KoreanbotsEndPoints.CDN.avatar(id, { format: 'webp', size: 256 }))
u.searchParams.append('bio', bio)
tags.map(t => u.searchParams.append('tags', t))
stats.map(s => u.searchParams.append('stats', s))
return u.href
}
},
CDN: class {
static root = '/api/image'
static avatar (id: string, options: KoreanbotsImageOptions) { return makeImageURL(`${this.root}/discord/avatars/${id}`, options) }
},
URL: class {
static root = process.env.KOREANBOTS_URL || 'https://koreanbots.dev'
static bot (id: string) { return `${this.root}/bots/${id}` }
static user (id: string) { return `${this.root}/users/${id}` }
static submittedBot(id: string, date: number) { return `${this.root}/pendingBots/${id}/${date}` }
},
baseAPI: '/api/v2',
login: '/api/auth/discord',
logout: '/api/auth/discord/logout'
}
export const SpecialEndPoints = {
Github: {
Content: (owner: string, repo: string, path: string) => `https://api.github.com/repos/${owner}/${repo}/contents/${path}`,
Token: (clientID: string, clientSecret: string, code: string) => `https://github.com/login/oauth/access_token?client_id=${clientID}&client_secret=${clientSecret}&code=${code}`,
Me: 'https://api.github.com/user'
},
HCaptcha: {
Verify: 'https://hcaptcha.com/siteverify'
}
}
export const GlobalRatelimitIgnore = [
'/api/image/discord/avatars/'
]
export const Oauth = {
discord: (clientID: string, scope: string) => `https://discord.com/oauth2/authorize?client_id=${clientID}&scope=${scope}&permissions=0&response_type=code&redirect_uri=${process.env.KOREANBOTS_URL}/api/auth/discord/callback&prompt=none`,
github: (clientID: string) => `https://github.com/login/oauth/authorize?client_id=${clientID}&redirect_uri=${process.env.KOREANBOTS_URL}/api/auth/github/callback`
}
export const git = { 'github.com': { icon: 'github', text: 'GitHub' }, 'gitlab.com': { icon: 'gitlab', text: 'GitLab' }}
export const KoreanbotsDiscord = 'https://discord.gg/JEh53MQ'
export const ThemeColors = [{ name: '파랑', rgb: 'rgb(51, 102, 255)', hex: '#3366FF', color: 'koreanbots-blue' }, { name: '하양', rgb: 'rgb(251, 251, 251)', hex: '#FBFBFB', color: 'little-white' }, { name: '검정', rgb: 'rgb(27, 30, 35)', hex: '#1B1E23', color: 'very-black' }, { name: '보라', rgb: 'rgb(114, 137, 218)', hex: '#7289DA', color: 'discord-blurple' } ]
export const KoreanbotsEmoji = [{
name: '한국 디스코드봇 리스트',
short_names: ['koreanbots', 'kbots', 'dbkr'],
emoticons: [],
keywords: ['koreanbots', '한국 디스코드봇 리스트', '한디리', 'kbots'],
imageUrl: '/logo.png'
},
{
name: 'Discord',
short_names: ['discord'],
emoticons: [],
keywords: ['discord', '디스코드', '디코'],
imageUrl: '/emojis/discord.svg'
},
{
name: 'Javascript',
short_names: ['javascript', 'js'],
emoticons: [],
keywords: ['javascript', 'js', '자바스크립트'],
imageUrl: '/emojis/javascript.png'
},
{
name: 'Python',
short_names: ['python', 'py'],
emoticons: [],
keywords: ['python', 'py', '파이썬'],
imageUrl: '/emojis/python.png'
}]
export const shortcutKeyMap: KeyMap = {
SHORTCUT_HELP: ['command+/', 'ctrl+/'],
CHANGE_THEME: ['command+shift+d', 'ctrl+shift+d']
}
export const ErrorText = {
DEFAULT: '예상치 못한 에러가 발생하였습니다.',
400: '올바르지 않은 요청입니다.',
401: '로그인이 필요합니다.',
402: '결제가 필요합니다.',
403: '권한이 없습니다.',
404: '페이지가 존재하지 않습니다.',
405: '해당 요청 방법은 허용되지 않습니다.',
406: '연결을 받아드릴 수 없습니다.',
429: '지정된 시간에 너무 많은 요청을 보내셨습니다. 잠시 후 다시 시도해주세요.',
500: '서버 내부 오류가 발생하였습니다.',
502: '올바르지 않은 게이트웨이입니다.'
}
export const ErrorMessage = ['지나가던 고양이가 선을 밟았어요..', '무언가 잘못되었어요..!', '이게 아닌데...', '어쩜 이렇게 오류가 또 나는건지?']
export const BotSubmissionDenyReasonPresetsName = {
MISSING_VERIFY: '개발자 확인 불가',
OFFLINE: '봇 오프라인',
INVALID_CATEGORY: '올바르지 않은 카테고리',
PRIVATE: '프라이빗 봇',
LICENSE_VIOLATION: '오픈소스 라이선스 위반',
ABSENT_AT_DISCORD: '공식 디스코드 서버 미참여'
}
export const GuildPermissions = {
general: [
{
name: '채널 보기',
flag: 0x00000400
},
{
name: '채널 관리하기',
flag: 0x00000010,
twofactor: true
},
{
name: '역할 관리하기',
flag: 0x10000000,
twofactor: true
},
{
name: '이모티콘 관리하기',
flag: 0x40000000,
twofactor: true
},
{
name: '감사 로그 보기',
flag: 0x00000080
},
{
name: '웹후크 관리하기',
flag: 0x20000000,
twofactor: true
},
{
name: '서버 관리하기',
flag: 0x00000020,
twofactor: true
}
],
membership: [
{
name: '초대 코드 만들기',
flag: 0x00000001
},
{
name: '별명 변경하기',
flag: 0x04000000
},
{
name: '별명 관리하기',
flag: 0x08000000
},
{
name: '멤버 추방하기',
flag: 0x00000002,
twofactor: true
},
{
name: '멤버 차단하기',
flag: 0x00000004,
twofactor: true
}
],
channel: [
{
name: '메세지 보내기',
flag: 0x00000800
},
{
name: '링크 첨부',
flag: 0x00004000
},
{
name: '파일 첨부',
flag: 0x00008000
},
{
name: '반응 추가하기',
flag: 0x00000040
},
{
name: '외부 이모티콘 사용',
flag: 0x00040000
},
{
name: '@everyone, @here 모든 역할 멘션하기',
flag: 0x00020000
},
{
name: '메세지 관리',
flag: 0x00002000,
twofactor: true
},
{
name: '메세지 기록 보기',
flag: 0x00010000
},
{
name: '텍스트 음성 변환 메세지 전송',
flag: 0x00001000
},
{
name: '빗금 명령어 사용',
flag: 0x80000000
}
],
voice: [
{
name: '연결',
flag: 0x00100000
},
{
name: '말하기',
flag: 0x00200000
},
{
name: '동영상',
flag: 0x00000200
},
{
name: '음성 감지 사용',
flag: 0x02000000
},
{
name: '우선 발언권',
flag: 0x00000100
},
{
name: '멤버들의 마이크 음소거하기',
flag: 0x00400000
},
{
name: '멤버의 헤드셋 음소거하기',
flag: 0x00800000
},
{
name: '멤버 이동',
flag: 0x01000000
}
],
advanced: [
{
name: '관리자',
flag: 0x8,
twofactor: true
}
]
}