Skip to content

Commit

Permalink
Merge pull request #5 from consenlabs/feature/i18n_errorinfo
Browse files Browse the repository at this point in the history
i18n支持解析imkeycore返回的错误信息
  • Loading branch information
XuNeal authored Jun 24, 2020
2 parents 1dfe0fb + e8c00ef commit 98f096a
Show file tree
Hide file tree
Showing 3 changed files with 409 additions and 146 deletions.
309 changes: 187 additions & 122 deletions src/renderer/common/lang/en.js
Original file line number Diff line number Diff line change
@@ -1,126 +1,191 @@
// en-US
export const m = {
connectDevice: {
get_start_imKey: 'Get start with your imKey Pro device',
info_connect_imKey: 'Connect the imKey to your Computer',
info_click_button: 'Click the connect button',
info_enter_pin: 'Enter the PIN code on imKey ',
info_if_pin: 'If you have not set the pin code of the imKey, you don"t need to enter the pin code on imKey',
connect: 'Connect',
connect_success: 'connect success',
connecting: 'Connecting',
check_BL: 'Check BL',
upgrading_firmware: 'Upgrading firmware',
check_active: 'Check Active',
active_success: 'Active Success',
check_bind: 'Check Bind',
check_create_wallet: 'Check Create Wallet'
},
step: {
connect: 'Connect',
active_bind: 'Active&Bind',
set_pin_create_wallet: 'Set PIN&Create Wallet'
},
stepOne: {
connect_imKey: 'Connect your imKey'
},
stepTwo: {
active_bind: 'Active&Bind',
please_active_bind: 'Please active and bind your imKey',
active_imKey: 'Activate your imKey',
bind_imKey: 'Bind your imKey',
start_active_bind_imKey: 'Start active and bind your imKey',
start: 'Start',
activating_imKey: 'Activating your imKey',
binding_imKey: 'Binding your imKey',
bind: 'Bind',
bind_code_is_null: 'BindCode is Not Null',
bind_code_is_correct: 'BindCode is not in correct format',
enter_bind_code: 'enter bind code'
},
stepThree: {
set_pin_create_wallet: 'Set PIN&Create Wallet',
please_disconnect: 'Please disconnect the USB ,set PIN and create wallet',
set_modify_pin: 'Set and modify PIN code',
create_wallet: 'Create or restore wallets',
next: 'Next',
operation_guide: 'Operation Guide',
how_to_set_pin: 'How to set the PIN',
set_pin_1: "imKey's PIN code should be 6-8 digits long and should not be a combination of same or continuous numbers.",
set_pin_2: 'The imKey shows Set PIN , and you enter the setting procedure.',
set_pin_3: 'Set the number for every digit, use the up and down buttons to switch among digits, click on OK to confirm, and click on C to cancel.',
set_pin_4: 'Repeat the above process until all digits of the PIN code are selected. (If you want to set a 6-digit PIN code, you can complete the setting by clicking on OK when the 7th digit shows ✔️ . If you want to set a 7-digit or 8-digit PIN code, you can confirm by switching the ✔️ to numbers.)',
set_pin_5: 'Type in the PIN code again to confirm',
security_reminders: 'Security reminders',
security_info_1: 'The PIN code is used to unlock imKey and cannot be recovered if lost. Please keep it safe;',
security_info_2: 'The PIN shall not be a combination of same or continuous numbers;',
security_info_3: 'Please do not use a random PIN code or the PIN code provided by the third-party tools.',
how_to_change_PIN: 'How to change the PIN code',
change_pin: 'Type in the PIN, turn on imKey, click on OK and enter the setting interface of the wallet. Choose Setting -> Change the PIN , type in the original PIN to check the identity, and reset the PIN code.',
special_notes: 'To safeguard the assets in the wallet, if a wrong PIN is typed in five times in a row, imKey will be forced to be reset. Please do remember the PIN code you set, since the PIN code cannot reset or recovered once lost.',
create_a_wallet: 'Create a wallet',
create_a_wallet_1: 'According to the prompt message on the imKey screen, press the Previous/Next button to select Recover Wallet, and click OK.',
create_a_wallet_2: 'View the tips then click on OK to continue',
create_a_wallet_3: 'Accurately transcribe words in the correct order',
create_a_wallet_4: 'Repeat this process until 12 words of the Mnemonic phrase are all backed up. (The Mnemonic is the only way to recover your wallet. Please keep it offline and properly safe.)',
create_a_wallet_5: 'Next, imKey displays Please confirm your Mnemonic',
create_a_wallet_6: 'Enter the correct word with Previous and Next buttons, click on OK to confirm',
create_a_wallet_7: 'Repeat this process until 12 words of the Mnemonic phrase are all verified',
create_a_wallet_8: 'After the verification is completed, imKey will display Creating wallet, estimated 2 min. ',
recover_wallet: 'Recover wallet',
recover_wallet_1: 'According to the prompt message on the imKey screen, press the Previous/Next button to select Recover Wallet, and click OK.',
recover_wallet_2: 'Input the Mnemonic words. At present, imKey supports the import of 12-, 18-, or 24-word Mnemonics.',
recover_wallet_3: 'Press the Up/Down button to switch letters. Press OK to confirm letter selection and C to cancel letter selection.',
recover_wallet_4: 'Repeat this operation until imKey displays all available words. Press the Up/Down button to move the cursor. Press OK to select the desired word. (The BIP39 word base contains 2,048 different words. As long as you enter several beginning letters, all candidate words can be displayed and available for selection.)',
recover_wallet_5: 'After the Mnemonic import is completed, click OK. imKey will display Recovering wallet, estimated 2 min',
recover_wallet_6: 'It can be used after the import is completed.'
},
home: {
buy_now: 'Get your own imKey',
use_imToken_to_buy: 'Please use the imToken scan code to buy',
use_WeChat_AliPay_to_buy: 'Please use the WeChat / Alipay scan code to buy',
WeChat_AliPay: 'WeChat/AliPay'
},
connect: {
connect_imKey: 'Connect your imKey',
follow_steps: 'Follow the steps below to the Manager',
connect_imKey_to_computer: 'Connect the imKey to your Computer',
click_connect: 'Click the connect button',
enter_pin_imKey: 'Enter the PIN code on your imKey',
connect: 'Connect'
},
manager: {
manager: 'Manager',
install_uninstall_apps: 'Install or unstall apps on your device',
firmware_version: 'firmware version',
firmware_is: 'firmware is ',
available: 'available',
update: 'update',
app_catalog: 'App catalog',
search_app: 'search app',
install: 'install'
},
setting: {
info: 'info',
is_update: 'Do you want to update ?',
cancel: 'Cancel',
ok: 'Ok',
is_quit_update: 'Exit update now ?',
setting: 'Setting',
setting_imKey_manager: 'Setting imKey-manager',
need_help: 'Need Help?',
imKey_manager_version: 'imKey-manager version',
imKey_manager_version_is: 'imKey-manager version is ',
available: 'available'

},
menu: {
home: 'Home',
manager: 'Manager',
setting: 'Setting'
},
noticeDialog: {
info: 'info'
}
connectDevice: {
get_start_imKey: 'Get start with your Pro device',
info_connect_imKey: 'Connect the to your Computer',
info_click_button: 'Click the connect button',
info_enter_pin: 'Enter the PIN code on ',
info_if_pin: 'If you have not set the pin code of the imKey, you don"t need to enter the pin code on imKey',
connect: 'Connect',
connect_success: 'connect success',
connecting: 'Connecting',
check_BL: 'Check BL',
upgrading_firmware: 'Upgrading firmware',
check_active: 'Check Active',
active_success: 'Active Success',
check_bind: 'Check Bind',
check_create_wallet: 'Check Create Wallet'
},
step: {
connect: 'Connect',
active_bind: 'Active&Bind',
set_pin_create_wallet: 'Set PIN&Create Wallet'
},
stepOne: {
connect_imKey: 'Connect your imKey'
},
stepTwo: {
active_bind: 'Active&Bind',
please_active_bind: 'Please active and bind your imKey',
active_imKey: 'Activate your imKey',
bind_imKey: 'Bind your imKey',
start_active_bind_imKey: 'Start active and bind your imKey',
start: 'Start',
activating_imKey: 'Activating your imKey',
binding_imKey: 'Binding your imKey',
bind: 'Bind',
bind_code_is_null: 'BindCode is Not Null',
bind_code_is_correct: 'BindCode is not in correct format',
enter_bind_code: 'enter bind code'
},
stepThree: {
set_pin_create_wallet: 'Set PIN&Create Wallet',
please_disconnect: 'Please disconnect the USB ,set PIN and create wallet',
set_modify_pin: 'Set and modify PIN code',
create_wallet: 'Create or restore wallets',
next: 'Next',
operation_guide: 'Operation Guide',
how_to_set_pin: 'How to set the PIN',
set_pin_1: "imKey's PIN code should be 6-8 digits long and should not be a combination of same or continuous numbers.",
set_pin_2: 'The shows Set PIN , and you enter the setting procedure.',
set_pin_3: 'Set the number for every digit, use the up and down buttons to switch among digits, click on OK to confirm, and click on C to cancel.',
set_pin_4: 'Repeat the above process until all digits of the PIN code are selected. (If you want to set a 6-digit PIN code, you can complete the setting by clicking on OK when the 7th digit shows ✔️ . If you want to set a 7-digit or 8-digit PIN code, you can confirm by switching the ✔️ to numbers.)',
set_pin_5: 'Type in the PIN code again to confirm',
security_reminders: 'Security reminders',
security_info_1: 'The PIN code is used to unlock and cannot be recovered if lost. Please keep it safe;',
security_info_2: 'The PIN shall not be a combination of same or continuous numbers;',
security_info_3: 'Please do not use a random PIN code or the PIN code provided by the third-party tools.',
how_to_change_PIN: 'How to change the PIN code',
change_pin: 'Type in the PIN, turn on imKey, click on OK and enter the setting interface of the wallet. Choose Setting -> Change the PIN , type in the original PIN to check the identity, and reset the PIN code.',
special_notes: 'To safeguard the assets in the wallet, if a wrong PIN is typed in five times in a row, will be forced to be reset. Please do remember the PIN code you set, since the PIN code cannot reset or recovered once lost.',
create_a_wallet: 'Create a wallet',
create_a_wallet_1: 'According to the prompt message on the screen, press the Previous/Next button to select Recover Wallet, and click OK.',
create_a_wallet_2: 'View the tips then click on OK to continue',
create_a_wallet_3: 'Accurately transcribe words in the correct order',
create_a_wallet_4: 'Repeat this process until 12 words of the Mnemonic phrase are all backed up. (The Mnemonic is the only way to recover your wallet. Please keep it offline and properly safe.)',
create_a_wallet_5: 'Next, displays Please confirm your Mnemonic',
create_a_wallet_6: 'Enter the correct word with Previous and Next buttons, click on OK to confirm',
create_a_wallet_7: 'Repeat this process until 12 words of the Mnemonic phrase are all verified',
create_a_wallet_8: 'After the verification is completed, will display Creating wallet, estimated 2 min. ',
recover_wallet: 'Recover wallet',
recover_wallet_1: 'According to the prompt message on the screen, press the Previous/Next button to select Recover Wallet, and click OK.',
recover_wallet_2: 'Input the Mnemonic words. At present, supports the import of 12-, 18-, or 24-word Mnemonics.',
recover_wallet_3: 'Press the Up/Down button to switch letters. Press OK to confirm letter selection and C to cancel letter selection.',
recover_wallet_4: 'Repeat this operation until displays all available words. Press the Up/Down button to move the cursor. Press OK to select the desired word. (The BIP39 word base contains 2,048 different words. As long as you enter several beginning letters, all candidate words can be displayed and available for selection.)',
recover_wallet_5: 'After the Mnemonic import is completed, click OK. will display Recovering wallet, estimated 2 min',
recover_wallet_6: 'It can be used after the import is completed.'
},
home: {
buy_now: 'Get your own imKey',
use_imToken_to_buy: 'Please use the imToken scan code to buy',
use_WeChat_AliPay_to_buy: 'Please use the WeChat / Alipay scan code to buy',
WeChat_AliPay: 'WeChat/AliPay'
},
connect: {
connect_imKey: 'Connect your imKey',
follow_steps: 'Follow the steps below to the Manager',
connect_imKey_to_computer: 'Connect the to your Computer',
click_connect: 'Click the connect button',
enter_pin_imKey: 'Enter the PIN code on your imKey',
connect: 'Connect'
},
manager: {
manager: 'Manager',
install_uninstall_apps: 'Install or unstall apps on your device',
firmware_version: 'firmware version',
firmware_is: 'firmware is ',
available: 'available',
update: 'update',
app_catalog: 'App catalog',
search_app: 'search app',
install: 'install'
},
setting: {
info: 'info',
is_update: 'Do you want to update ?',
cancel: 'Cancel',
ok: 'Ok',
is_quit_update: 'Exit update now ?',
setting: 'Setting',
setting_imKey_manager: 'Setting imKey-manager',
need_help: 'Need Help?',
imKey_manager_version: 'imKey-manager version',
imKey_manager_version_is: 'imKey-manager version is ',
available: 'available'

},
menu: {
home: 'Home',
manager: 'Manager',
setting: 'Setting'
},
noticeDialog: {
info: 'info'
},
imKeyCoreErrorInfo: {
decoding_failed: "Decoding failed",
imkey_publickey_mismatch_with_path: "publickey mismatch with path",
imkey_illegal_param: "illegal param",
get_seid_error: "get seid error",
get_sn_error: "get sn error",
get_ram_size_error: "get ram size error",
get_firmware_version_error: "get firmware version error",
get_battery_power_error: "get battery power error",
get_life_time_error: "get life time error",
get_ble_name_error: "get ble name error",
get_ble_version_error: "get ble version error",
parse_arguments_to_str: "parse arguments to str",
decode_imkey_api: "decode api",
encode_error: "encode error",
device_connect_interface_not_called: "device connect interface not called",
device_data_read_time_out: "device data read time out",
imkey_device_not_connect: "device not connect,please connect",
Failed_opening_hid_device: "Failed opening hid device.If imKey is connected, please disconnect and reconnect",
hidapi_error_hid_error_is_not_implemented_yet: "hidapi error: hid error is not implemented yet.please disconnect and reconnect",
imkey_device_reconnect_fail: "device reconnect fail.please disconnect and reconnect",
imkey_path_illegal: "path illegal",
imkey_user_not_confirmed: "user not confirmed",
imkey_conditions_not_satisfied: "conditions not satisfied",
imkey_command_format_error: "command format error",
imkey_command_data_error: "command data error",
imkey_applet_not_exist: "applet not exist",
imkey_apdu_wrong_length: "apdu wrong length",
imkey_signature_verify_fail: "signature verify fail",
imkey_bluetooth_channel_error: "bluetooth channel error",
imkey_applet_function_not_supported: "applet function not supported",
imkey_exceeded_max_utxo_number: "exceeded max utxo number",
imkey_command_execute_fail: "command execute fail",
imkey_wallet_not_created: "wallet not created",
imkey_in_menu_page: "in menu page",
imkey_pin_not_verified: "pin not verified",
imkey_address_mismatch_with_path: "address mismatch with path",
imkey_insufficient_funds: "insufficient funds",
imkey_sdk_illegal_argument: "sdk illegal argument",
imkey_amount_less_than_minimum: "amount less than minimum",
get_xpub_error: "get xpub error",
address_type_mismatch: "address type mismatch",
imkey_tsm_device_authenticity_check_fail: "device authenticity check fail",
imkey_tsm_device_not_activated: "device not activated",
imkey_tsm_device_illegal: "device illegal",
imkey_tsm_device_stop_using: "device stop using",
imkey_tsm_server_error: "server error",
imkey_se_cert_invalid: "se cert invalid",
imkey_tsm_device_update_check_fail: "device update check fail",
imkey_tsm_device_active_fail: "device active fail",
imkey_tsm_receipt_check_fail: "receipt check fail",
imkey_tsm_app_download_fail: "app download fail",
imkey_tsm_app_update_fail: "app update fail",
imkey_tsm_app_delete_fail: "app delete fail",
imkey_tsm_oce_cert_check_fail: "oce cert check fail",
imkey_tsm_cos_info_no_conf: "cos info no conf",
imkey_tsm_cos_upgrade_fail: "cos upgrade fail",
imkey_tsm_upload_cos_version_is_null: "upload cos version is null",
imkey_tsm_switch_bl_status_fail: "switch bl status fail",
imkey_tsm_write_wallet_address_fail: "write wallet address fail",
imkey_tsm_check_update_fail: "check update fail",
imkey_auth_code_ciphertext_storage_fail: "auth code ciphertext storage fail",
imkey_keyfile_io_error: "keyfile io error",
imkey_encrypt_authcode_fail: "encrypt authcode fail",
imkey_save_key_file_fail: "save key file fail"
}
}
Loading

0 comments on commit 98f096a

Please sign in to comment.