enhance(frontend): improve usability

This commit is contained in:
syuilo 2024-08-15 20:02:53 +09:00
parent b68b2ee8c6
commit 45d88574c3
1 changed files with 12 additions and 11 deletions

View File

@ -231,17 +231,18 @@ export async function mainBoot() {
claimAchievement('client60min'); claimAchievement('client60min');
}, 1000 * 60 * 60); }, 1000 * 60 * 60);
const lastUsed = miLocalStorage.getItem('lastUsed'); // 邪魔
if (lastUsed) { //const lastUsed = miLocalStorage.getItem('lastUsed');
const lastUsedDate = parseInt(lastUsed, 10); //if (lastUsed) {
// 二時間以上前なら // const lastUsedDate = parseInt(lastUsed, 10);
if (Date.now() - lastUsedDate > 1000 * 60 * 60 * 2) { // // 二時間以上前なら
toast(i18n.tsx.welcomeBackWithName({ // if (Date.now() - lastUsedDate > 1000 * 60 * 60 * 2) {
name: $i.name || $i.username, // toast(i18n.tsx.welcomeBackWithName({
})); // name: $i.name || $i.username,
} // }));
} // }
miLocalStorage.setItem('lastUsed', Date.now().toString()); //}
//miLocalStorage.setItem('lastUsed', Date.now().toString());
const latestDonationInfoShownAt = miLocalStorage.getItem('latestDonationInfoShownAt'); const latestDonationInfoShownAt = miLocalStorage.getItem('latestDonationInfoShownAt');
const neverShowDonationInfo = miLocalStorage.getItem('neverShowDonationInfo'); const neverShowDonationInfo = miLocalStorage.getItem('neverShowDonationInfo');