[feat] better image saving

This commit is contained in:
kwaroran
2024-01-04 03:18:11 +09:00
parent a13fdced2e
commit 5f2275eb22
3 changed files with 180 additions and 35 deletions

View File

@@ -1172,12 +1172,12 @@ class MobileWriter{
export class LocalWriter{
writer: WritableStreamDefaultWriter|TauriWriter|MobileWriter
async init() {
async init(name = 'Binary', ext = ['bin']) {
if(isTauri){
const filePath = await save({
filters: [{
name: 'Binary',
extensions: ['bin']
name: name,
extensions: ext
}]
});
if(!filePath){