refactor: deprecate i18n.t (#13039)

* refactor: deprecate i18n.t

* revert: deprecate i18n.t

This reverts commit 7dbf873a2f745040ee723df5db659acacff84e12.

* chore: reimpl
This commit is contained in:
Acid Chicken (硫酸鶏) 2024-01-20 08:11:59 +09:00 committed by GitHub
parent a637b4e282
commit 7881f06be0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
84 changed files with 7311 additions and 222 deletions

View file

@ -189,7 +189,7 @@ const addColumn = async (ev) => {
const { canceled, result: column } = await os.select({
title: i18n.ts._deck.addColumn,
items: columns.map(column => ({
value: column, text: i18n.t('_deck._columns.' + column),
value: column, text: i18n.ts._deck._columns[column],
})),
});
if (canceled) return;
@ -197,7 +197,7 @@ const addColumn = async (ev) => {
addColumnToStore({
type: column,
id: uuid(),
name: i18n.t('_deck._columns.' + column),
name: i18n.ts._deck._columns[column],
width: 330,
});
};
@ -256,7 +256,7 @@ function changeProfile(ev: MouseEvent) {
async function deleteProfile() {
const { canceled } = await os.confirm({
type: 'warning',
text: i18n.t('deleteAreYouSure', { x: deckStore.state.profile }),
text: i18n.tsx.deleteAreYouSure({ x: deckStore.state.profile }),
});
if (canceled) return;