@meddleware/walrus-ui 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +7 -7
- package/src/components/MyBlobs.vue +3 -3
- package/src/config.ts +4 -4
- package/tsconfig.json +1 -1
- package/vite.config.ts +7 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@meddleware/walrus-ui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"description": "Standalone Vue 3 SPA for uploading blobs to Walrus decentralised storage and managing owned blobs — wallet-connected, NFT-gated relay support.",
|
|
5
5
|
"author": "Meddleware <dev@meddleware.co.uk>",
|
|
6
6
|
"license": "0BSD",
|
|
@@ -41,13 +41,13 @@
|
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@meddleware/design-tokens": "^0.1.2",
|
|
44
|
-
"@meddleware/nft-gate-client": "^0.0.
|
|
44
|
+
"@meddleware/nft-gate-client": "^0.0.6",
|
|
45
45
|
"@meddleware/ui": "^0.1.6",
|
|
46
|
-
"@meddleware/wallet-adapter": "^0.0.
|
|
47
|
-
"@meddleware/walrus-client": "^0.0.
|
|
48
|
-
"@meddleware/walrus-relay": "^0.1.
|
|
49
|
-
"@mysten/sui": "
|
|
50
|
-
"@mysten/wallet-standard": "
|
|
46
|
+
"@meddleware/wallet-adapter": "^0.0.2",
|
|
47
|
+
"@meddleware/walrus-client": "^0.0.5",
|
|
48
|
+
"@meddleware/walrus-relay": "^0.1.3",
|
|
49
|
+
"@mysten/sui": "^2.28.0",
|
|
50
|
+
"@mysten/wallet-standard": "^0.20.0",
|
|
51
51
|
"@mysten/walrus": "~1.1.7",
|
|
52
52
|
"@mysten/walrus-wasm": "~0.2.2",
|
|
53
53
|
"vue": "^3.5.40"
|
|
@@ -40,11 +40,11 @@ async function loadBlobs(): Promise<void> {
|
|
|
40
40
|
const suiClient = getSuiClient(NETWORK)
|
|
41
41
|
const walrusClient = createWalrusClient({ network: NETWORK, wasmUrl: walrusWasmUrl })
|
|
42
42
|
const [sys, fetched] = await Promise.all([
|
|
43
|
-
suiClient.
|
|
43
|
+
suiClient.getCurrentSystemState(),
|
|
44
44
|
fetchOwnedWalrusBlobs(suiClient, walrusClient, props.address),
|
|
45
45
|
])
|
|
46
|
-
currentEpoch.value = Number(sys.epoch)
|
|
47
|
-
blobs.value = fetched.sort((a, b) => a.endEpoch - b.endEpoch)
|
|
46
|
+
currentEpoch.value = Number(sys.systemState.epoch)
|
|
47
|
+
blobs.value = fetched.sort((a: OwnedBlob, b: OwnedBlob) => a.endEpoch - b.endEpoch)
|
|
48
48
|
} catch (e) {
|
|
49
49
|
error.value = e instanceof Error ? e.message : String(e)
|
|
50
50
|
} finally {
|
package/src/config.ts
CHANGED
|
@@ -48,12 +48,12 @@ export function uploadRelayMaxTipMist(envSource: EnvSource = env): number {
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
/**
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
51
|
+
* gRPC-web endpoint used to build + execute the register/certify transactions and read owned
|
|
52
|
+
* blobs. The Sui SDK's JSON-RPC client is deprecated, so this must be a gRPC-web-capable endpoint
|
|
53
|
+
* (the Mysten public fullnodes serve gRPC-web at :443 via the browser Fetch transport).
|
|
54
54
|
*/
|
|
55
55
|
export const RPC_URLS: Record<WalrusNetwork, string> = {
|
|
56
|
-
testnet: env.VITE_RPC_TESTNET || 'https://
|
|
56
|
+
testnet: env.VITE_RPC_TESTNET || 'https://fullnode.testnet.sui.io:443',
|
|
57
57
|
mainnet: env.VITE_RPC_MAINNET || 'https://fullnode.mainnet.sui.io:443',
|
|
58
58
|
}
|
|
59
59
|
|
package/tsconfig.json
CHANGED
package/vite.config.ts
CHANGED
|
@@ -3,9 +3,16 @@ import vue from '@vitejs/plugin-vue'
|
|
|
3
3
|
|
|
4
4
|
// design-tokens and ui resolve from node_modules (published packages).
|
|
5
5
|
// @mysten/walrus is excluded from dep-optimization so its wasm `?url` import resolves.
|
|
6
|
+
// node:fs/promises is declared external so rolldown doesn't warn about the Node-only
|
|
7
|
+
// uploadLocalFile helper in @meddleware/walrus-client (never called from browser code).
|
|
6
8
|
export default defineConfig({
|
|
7
9
|
plugins: [vue()],
|
|
8
10
|
optimizeDeps: {
|
|
9
11
|
exclude: ['@mysten/walrus', '@mysten/walrus-wasm'],
|
|
10
12
|
},
|
|
13
|
+
build: {
|
|
14
|
+
rollupOptions: {
|
|
15
|
+
external: ['node:fs/promises'],
|
|
16
|
+
},
|
|
17
|
+
},
|
|
11
18
|
})
|