Skip to content

Commit

Permalink
fix: set the fallback translations for copying codes
Browse files Browse the repository at this point in the history
  • Loading branch information
razonyang committed May 15, 2023
1 parent e873e62 commit ffdfa00
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions assets/mods/code-block-panel/js/panel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,9 @@ export default class Panel {
ln.remove();
});
navigator.clipboard.writeText(clone.innerText).then(() => {
snackbar.add(i18n.translate('copied'))
snackbar.add(i18n.translate('copied', null, 'Copied!'))
}).catch((err) => {
snackbar.add(i18n.translate('copy_failed'))
snackbar.add(i18n.translate('copy_failed', null, 'Copy failed.'))
console.error(err)
})
}
Expand Down

0 comments on commit ffdfa00

Please sign in to comment.