- closes #129
- closes #130
- minor cleanup
This commit is contained in:
Shiny Nematoda 2023-06-13 12:26:48 +00:00
parent 8945c11f02
commit faef667189
11 changed files with 1020 additions and 885 deletions

View file

@ -142,3 +142,19 @@ export const useI18n = defineStore('i18n', () => {
return { locale, map, t, setupLocale };
});
export const useAlert = defineStore('alert', () => {
const msg = ref('');
function add(m) {
if (!m) return;
msg.value = m;
setTimeout(() => {
if (msg.value == m) msg.value = '';
}, 3000);
}
return { msg, add };
});