mirror of
https://github.com/maelgangloff/domain-watchdog.git
synced 2025-12-17 09:45:29 +00:00
10 lines
374 B
TypeScript
10 lines
374 B
TypeScript
export const eppStatusCodeToColor = (s?: string) =>
|
|
s === undefined ? 'default' :
|
|
['active', 'ok'].includes(s)
|
|
? 'green'
|
|
: ['pending delete', 'redemption period'].includes(s)
|
|
? 'red'
|
|
: s.startsWith('client')
|
|
? 'purple'
|
|
: s.startsWith('server') ? 'geekblue' : 'blue'
|