-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2082 from oasisprotocol/lw/discourage-cipher
Discourage mistaken ParaTime deposits into Cipher
- Loading branch information
Showing
7 changed files
with
32 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Discourage mistaken ParaTime deposits into Cipher |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { TFunction } from 'i18next' | ||
import { ExhaustedTypeError } from 'types/errors' | ||
import { ParaTime } from '../../../config' | ||
|
||
export const getParaTimeName = (t: TFunction, paraTime: ParaTime) => { | ||
switch (paraTime) { | ||
case ParaTime.Cipher: | ||
return `${t('paraTimes.common.cipher', 'Cipher')} ${t( | ||
'paraTimes.common.discouragedType', | ||
// Discourage mistaken ParaTime deposits into Cipher accounts controlled | ||
// by Binance. That requires contacting support to recover it. | ||
'(experimental)', | ||
)}` | ||
case ParaTime.Emerald: | ||
return t('paraTimes.common.emerald', 'Emerald') | ||
case ParaTime.Sapphire: | ||
return t('paraTimes.common.sapphire', 'Sapphire') | ||
default: | ||
throw new ExhaustedTypeError( | ||
t('paraTimes.validation.unsupportedParaTime', 'Unsupported ParaTime'), | ||
paraTime, | ||
) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters