Skip to content

Commit a8031e3

Browse files
committed
Build: (34d6339) cache invalidation added to inventory (#376)
1 parent 20d5fb0 commit a8031e3

File tree

10 files changed

+51
-27
lines changed

10 files changed

+51
-27
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { p as process$1, g as getDefaultExportFromCjs } from "./index-BjhSb8va.js";
1+
import { p as process$1, g as getDefaultExportFromCjs } from "./index-VuMGdJHn.js";
22
var browser = { exports: {} };
33
var ms;
44
var hasRequiredMs;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { q as BaseError, u as getUrl, x as stringify, y as decodeErrorResult, z as isAddressEqual, A as call, C as concat, D as encodeAbiParameters, H as HttpRequestError, F as isHex } from "./index-BjhSb8va.js";
1+
import { q as BaseError, u as getUrl, x as stringify, y as decodeErrorResult, z as isAddressEqual, A as call, C as concat, D as encodeAbiParameters, H as HttpRequestError, F as isHex } from "./index-VuMGdJHn.js";
22
class OffchainLookupError extends BaseError {
33
constructor({ callbackSelector, cause, data, extraData, sender, urls }) {
44
var _a;
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { c as commonjsGlobal, a as bnExports, B as Buffer$7, r as require$$2$1, i as inherits_browserExports, d as getAugmentedNamespace, e as eventsExports, f as require$$3, p as process$1, t as tslib_es6, h as eventemitter3Exports, g as getDefaultExportFromCjs } from "./index-BjhSb8va.js";
1+
import { c as commonjsGlobal, a as bnExports, B as Buffer$7, r as require$$2$1, i as inherits_browserExports, d as getAugmentedNamespace, e as eventsExports, f as require$$3, p as process$1, t as tslib_es6, h as eventemitter3Exports, g as getDefaultExportFromCjs } from "./index-VuMGdJHn.js";
22
import { p as preact_module, a as clsx_m, b as hooks_module } from "./hooks.module-B8FgZbnF.js";
3-
import { b as browserExports } from "./browser-B07ueiOg.js";
3+
import { b as browserExports } from "./browser-CelLZBdi.js";
44
var dist$5 = {};
55
var CoinbaseWalletSDK$1 = {};
66
var walletLogo$1 = {};
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-kDSYeeb7.js","./index-BjhSb8va.js","./index-BHwcnrtI.css"])))=>i.map(i=>d[i]);
2-
import { B as Buffer, _ as __vitePreload } from "./index-BjhSb8va.js";
1+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-nvmbRY9-.js","./index-VuMGdJHn.js","./index-BHwcnrtI.css"])))=>i.map(i=>d[i]);
2+
import { B as Buffer, _ as __vitePreload } from "./index-VuMGdJHn.js";
33
const t = Symbol();
44
const s = Object.getPrototypeOf, c = /* @__PURE__ */ new WeakMap(), l = (e) => e && (c.has(e) ? c.get(e) : s(e) === Object.prototype || s(e) === Array.prototype), y = (e) => l(e) && e[t] || null, h = (e, t2 = true) => {
55
c.set(e, t2);
@@ -776,7 +776,7 @@ class WalletConnectModal {
776776
}
777777
async initUi() {
778778
if (typeof window !== "undefined") {
779-
await __vitePreload(() => import("./index-kDSYeeb7.js"), true ? __vite__mapDeps([0,1,2]) : void 0, import.meta.url);
779+
await __vitePreload(() => import("./index-nvmbRY9-.js"), true ? __vite__mapDeps([0,1,2]) : void 0, import.meta.url);
780780
const modal = document.createElement("wcm-modal");
781781
document.body.insertAdjacentElement("beforeend", modal);
782782
OptionsCtrl.setIsUiLoaded(true);
Lines changed: 35 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-DAMMQNrJ.js","./hooks.module-B8FgZbnF.js","./index-CD56fPSg.js","./browser-B07ueiOg.js","./metamask-sdk-CBPkM48o.js"])))=>i.map(i=>d[i]);
1+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-g1zAAyIC.js","./hooks.module-B8FgZbnF.js","./index-BMJAHJRz.js","./browser-CelLZBdi.js","./metamask-sdk-B-ZW1FBT.js"])))=>i.map(i=>d[i]);
22
var __defProp = Object.defineProperty;
33
var __typeError = (msg) => {
44
throw TypeError(msg);
@@ -20450,7 +20450,7 @@ async function call(client2, args) {
2045020450
} catch (err2) {
2045120451
const data3 = getRevertErrorData(err2);
2045220452
const { offchainLookup, offchainLookupSignature } = await __vitePreload(async () => {
20453-
const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-D7AJRNlZ.js");
20453+
const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-BjDeLmXb.js");
2045420454
return { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 };
2045520455
}, true ? [] : void 0, import.meta.url);
2045620456
if (client2.ccipRead !== false && (data3 == null ? void 0 : data3.slice(0, 10)) === offchainLookupSignature && to)
@@ -133526,7 +133526,7 @@ function version4(parameters) {
133526133526
};
133527133527
})();
133528133528
const { createCoinbaseWalletSDK } = await __vitePreload(async () => {
133529-
const { createCoinbaseWalletSDK: createCoinbaseWalletSDK2 } = await import("./index-DAMMQNrJ.js");
133529+
const { createCoinbaseWalletSDK: createCoinbaseWalletSDK2 } = await import("./index-g1zAAyIC.js");
133530133530
return { createCoinbaseWalletSDK: createCoinbaseWalletSDK2 };
133531133531
}, true ? __vite__mapDeps([0,1]) : void 0, import.meta.url);
133532133532
const sdk = createCoinbaseWalletSDK({
@@ -133701,7 +133701,7 @@ function version3(parameters) {
133701133701
if (!walletProvider) {
133702133702
const CoinbaseWalletSDK = await (async () => {
133703133703
const { default: SDK } = await __vitePreload(async () => {
133704-
const { default: SDK2 } = await import("./index-CD56fPSg.js").then((n2) => n2.i);
133704+
const { default: SDK2 } = await import("./index-BMJAHJRz.js").then((n2) => n2.i);
133705133705
return { default: SDK2 };
133706133706
}, true ? __vite__mapDeps([2,1,3]) : void 0, import.meta.url);
133707133707
if (typeof SDK !== "function" && typeof SDK.default === "function")
@@ -133941,7 +133941,7 @@ function metaMask$1(parameters = {}) {
133941133941
var _a4, _b2, _c2, _d3, _e6;
133942133942
const MetaMaskSDK = await (async () => {
133943133943
const { default: SDK } = await __vitePreload(async () => {
133944-
const { default: SDK2 } = await import("./metamask-sdk-CBPkM48o.js");
133944+
const { default: SDK2 } = await import("./metamask-sdk-B-ZW1FBT.js");
133945133945
return { default: SDK2 };
133946133946
}, true ? __vite__mapDeps([4,3]) : void 0, import.meta.url);
133947133947
if (typeof SDK !== "function" && typeof SDK.default === "function")
@@ -134293,7 +134293,7 @@ function walletConnect$1(parameters) {
134293134293
if (!optionalChains.length)
134294134294
return;
134295134295
const { EthereumProvider } = await __vitePreload(async () => {
134296-
const { EthereumProvider: EthereumProvider2 } = await import("./index.es-CqtlYMYM.js");
134296+
const { EthereumProvider: EthereumProvider2 } = await import("./index.es-BAa8DaLZ.js");
134297134297
return { EthereumProvider: EthereumProvider2 };
134298134298
}, true ? [] : void 0, import.meta.url);
134299134299
return await EthereumProvider.init({
@@ -143998,6 +143998,9 @@ const TransactionConfirmation = ({ name: name2, symbol, imageUrl, amount, toAddr
143998143998
};
143999143999
const SendCoin = ({ chainId, contractAddress: contractAddress2 }) => {
144000144000
var _a4, _b2, _c2, _d3, _e6;
144001+
const { clearCachedBalances } = useClearCachedBalances();
144002+
const publicClient = usePublicClient({ chainId });
144003+
const indexerClient = useIndexerClient(chainId);
144001144004
const { setNavigation } = useNavigation();
144002144005
const { setIsBackButtonEnabled } = useNavigationContext();
144003144006
const { analytics } = useAnalyticsContext();
@@ -144128,14 +144131,23 @@ const SendCoin = ({ chainId, contractAddress: contractAddress2 }) => {
144128144131
setIsSendTxnPending(true);
144129144132
const sendAmount = parseUnits$5(amountToSendFormatted, decimals);
144130144133
const txOptions = {
144131-
onSettled: (result) => {
144134+
onSettled: async (hash3) => {
144132144135
setIsBackButtonEnabled(true);
144133-
if (result) {
144136+
if (hash3) {
144134144137
setNavigation({
144135144138
location: "home"
144136144139
});
144140+
setIsSendTxnPending(false);
144141+
if (publicClient) {
144142+
await waitForTransactionReceipt({
144143+
indexerClient,
144144+
txnHash: hash3,
144145+
publicClient,
144146+
confirmations: TRANSACTION_CONFIRMATIONS_DEFAULT
144147+
});
144148+
clearCachedBalances();
144149+
}
144137144150
}
144138-
setIsSendTxnPending(false);
144139144151
}
144140144152
};
144141144153
if (isNativeCoin) {
@@ -144175,10 +144187,13 @@ const SendCollectible = ({ chainId, contractAddress: contractAddress2, tokenId }
144175144187
const { chains: chains2 } = useConfig$1();
144176144188
const connectedChainId = useChainId();
144177144189
const { address: accountAddress = "", connector } = useAccount();
144190+
const indexerClient = useIndexerClient(chainId);
144191+
const publicClient = usePublicClient({ chainId });
144178144192
const isConnectorSequenceBased = !!((_a4 = connector == null ? void 0 : connector._wallet) == null ? void 0 : _a4.isSequenceBased);
144179144193
const isCorrectChainId = connectedChainId === chainId;
144180144194
const showSwitchNetwork = !isCorrectChainId && !isConnectorSequenceBased;
144181144195
const { switchChain: switchChain2 } = useSwitchChain();
144196+
const { clearCachedBalances } = useClearCachedBalances();
144182144197
const amountInputRef = reactExports.useRef(null);
144183144198
const [amount, setAmount] = reactExports.useState("0");
144184144199
const [toAddress, setToAddress] = reactExports.useState("");
@@ -144316,14 +144331,23 @@ const SendCollectible = ({ chainId, contractAddress: contractAddress2, tokenId }
144316144331
}
144317144332
const sendAmount = parseUnits$5(amountToSendFormatted, decimals);
144318144333
const txOptions = {
144319-
onSettled: (result) => {
144334+
onSettled: async (hash3) => {
144320144335
setIsBackButtonEnabled(true);
144321-
if (result) {
144336+
if (hash3) {
144322144337
setNavigation({
144323144338
location: "home"
144324144339
});
144325144340
}
144326144341
setIsSendTxnPending(false);
144342+
if (publicClient) {
144343+
await waitForTransactionReceipt({
144344+
indexerClient,
144345+
txnHash: hash3,
144346+
publicClient,
144347+
confirmations: TRANSACTION_CONFIRMATIONS_DEFAULT
144348+
});
144349+
clearCachedBalances();
144350+
}
144327144351
}
144328144352
};
144329144353
switch (contractType) {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { B as Buffer, g as getDefaultExportFromCjs, b as bytesToHex, s as sha256, E as EventEmitter } from "./index-BjhSb8va.js";
1+
import { B as Buffer, g as getDefaultExportFromCjs, b as bytesToHex, s as sha256, E as EventEmitter } from "./index-VuMGdJHn.js";
22
import { D, g, c as clsx, h, y } from "./hooks.module-B8FgZbnF.js";
33
class ScopedLocalStorage {
44
constructor(scope, module) {
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { T as ThemeCtrl, M as ModalCtrl, R as RouterCtrl, E as ExplorerCtrl, C as CoreUtil, a as ToastCtrl, b as EventsCtrl, O as OptionsCtrl, c as ConfigCtrl } from "./index-Cj5CUb3s.js";
2-
import "./index-BjhSb8va.js";
1+
import { T as ThemeCtrl, M as ModalCtrl, R as RouterCtrl, E as ExplorerCtrl, C as CoreUtil, a as ToastCtrl, b as EventsCtrl, O as OptionsCtrl, c as ConfigCtrl } from "./index-BtCR9w_g.js";
2+
import "./index-VuMGdJHn.js";
33
/**
44
* @license
55
* Copyright 2019 Google LLC
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-Cj5CUb3s.js","./index-BjhSb8va.js","./index-BHwcnrtI.css"])))=>i.map(i=>d[i]);
2-
import { p as process$1, d as getAugmentedNamespace, j as global, B as Buffer, m as recoverAddress, o as elliptic, e as eventsExports, g as getDefaultExportFromCjs, c as commonjsGlobal, w as wt$4, _ as __vitePreload } from "./index-BjhSb8va.js";
1+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-BtCR9w_g.js","./index-VuMGdJHn.js","./index-BHwcnrtI.css"])))=>i.map(i=>d[i]);
2+
import { p as process$1, d as getAugmentedNamespace, j as global, B as Buffer, m as recoverAddress, o as elliptic, e as eventsExports, g as getDefaultExportFromCjs, c as commonjsGlobal, w as wt$4, _ as __vitePreload } from "./index-VuMGdJHn.js";
33
var __spreadArray = function(to2, from2, pack) {
44
if (pack || arguments.length === 2) for (var i3 = 0, l2 = from2.length, ar2; i3 < l2; i3++) {
55
if (ar2 || !(i3 in from2)) {
@@ -11759,7 +11759,7 @@ class w {
1175911759
if (this.rpc = this.getRpcConfig(t), this.chainId = this.rpc.chains.length ? v(this.rpc.chains) : v(this.rpc.optionalChains), this.signer = await oh.init({ projectId: this.rpc.projectId, metadata: this.rpc.metadata, disableProviderPing: t.disableProviderPing, relayUrl: t.relayUrl, storage: t.storage, storageOptions: t.storageOptions, customStoragePrefix: t.customStoragePrefix, telemetryEnabled: t.telemetryEnabled, logger: t.logger }), this.registerEventListeners(), await this.loadPersistedSession(), this.rpc.showQrModal) {
1176011760
let s2;
1176111761
try {
11762-
const { WalletConnectModal: i3 } = await __vitePreload(() => import("./index-Cj5CUb3s.js").then((n3) => n3.i), true ? __vite__mapDeps([0,1,2]) : void 0, import.meta.url);
11762+
const { WalletConnectModal: i3 } = await __vitePreload(() => import("./index-BtCR9w_g.js").then((n3) => n3.i), true ? __vite__mapDeps([0,1,2]) : void 0, import.meta.url);
1176311763
s2 = i3;
1176411764
} catch {
1176511765
throw new Error("To use QR modal, please install @walletconnect/modal package");
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { c as commonjsGlobal, g as getDefaultExportFromCjs, n, j as global, v as v4, k as eventemitter2Exports, l as validate, _ as __vitePreload } from "./index-BjhSb8va.js";
2-
import { t } from "./browser-B07ueiOg.js";
1+
import { c as commonjsGlobal, g as getDefaultExportFromCjs, n, j as global, v as v4, k as eventemitter2Exports, l as validate, _ as __vitePreload } from "./index-VuMGdJHn.js";
2+
import { t } from "./browser-CelLZBdi.js";
33
var browserPonyfill = { exports: {} };
44
(function(module, exports) {
55
var __global__ = typeof globalThis !== "undefined" && globalThis || typeof self !== "undefined" && self || typeof commonjsGlobal !== "undefined" && commonjsGlobal;

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
Learn how to configure a non-root public URL by running `npm run build`.
2222
-->
2323
<title>Sequence Web SDK Demo</title>
24-
<script type="module" crossorigin src="./assets/index-BjhSb8va.js"></script>
24+
<script type="module" crossorigin src="./assets/index-VuMGdJHn.js"></script>
2525
<link rel="stylesheet" crossorigin href="./assets/index-BHwcnrtI.css">
2626
</head>
2727
<body>

0 commit comments

Comments
 (0)