Add upload and share functionality and minor improvements

This commit is contained in:
Yeicor
2025-08-02 12:50:20 +02:00
parent 56fc556c0f
commit 06a95d4875
8 changed files with 483 additions and 323 deletions

View File

@@ -1,5 +1,6 @@
import {Buffer, Document, Scene, type Transform, WebIO} from "@gltf-transform/core";
import {mergeDocuments, unpartition} from "@gltf-transform/functions";
import {retrieveFile} from "../tools/upload-file.ts";
let io = new WebIO();
export let extrasNameKey = "__yacv_name";
@@ -140,7 +141,7 @@ async function fetchOrRead(url: string | Blob) {
});
} else {
// Fetch the URL
return fetch(url);
return retrieveFile(url);
}
}