mirror of
https://github.com/lifegpc/eh_downloader_flutter.git
synced 2026-07-08 01:30:28 +08:00
Support download zip on web
This commit is contained in:
@@ -4,3 +4,7 @@ void saveFileWeb(
|
||||
Uint8List data, String mimeType, String filenameWithoutExtension) {
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
void saveUriWeb(String uri) {
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@@ -26,3 +26,9 @@ void saveFileWeb(
|
||||
a.click();
|
||||
Url.revokeObjectUrl(url);
|
||||
}
|
||||
|
||||
void saveUriWeb(String uri) {
|
||||
final a = document.createElement("a") as AnchorElement;
|
||||
a.href = uri;
|
||||
a.click();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user