@zerohash-sdk/fiat-account-link-js 1.5.0 → 1.6.1
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/dist/index.d.ts +34 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -309,6 +309,40 @@ declare type CommonCallbacks<TEvent = AppEvent> = {
|
|
|
309
309
|
onEvent?: (event: TEvent) => void;
|
|
310
310
|
/** Called when the widget has loaded and is ready */
|
|
311
311
|
onLoaded?: () => void;
|
|
312
|
+
/**
|
|
313
|
+
* Called when a deposit reaches a terminal state (success/failure/verifying).
|
|
314
|
+
* Optional — only SDKs that drive the integrations deposit flow emit it.
|
|
315
|
+
*/
|
|
316
|
+
onDeposit?: (deposit: DepositCompletedPayload) => void;
|
|
317
|
+
};
|
|
318
|
+
|
|
319
|
+
/**
|
|
320
|
+
* Deposit completed payload — emitted by SDKs that drive a deposit through
|
|
321
|
+
* the integrations flow. Lives on `CommonCallbacks` because both Auth and
|
|
322
|
+
* any SDK embedding `@zerohash/integrations-flow` (e.g. fund with `useAuth`)
|
|
323
|
+
* resolve through the same deposit-status hook.
|
|
324
|
+
*/
|
|
325
|
+
declare type DepositCompletedPayload = {
|
|
326
|
+
data: {
|
|
327
|
+
depositId: string;
|
|
328
|
+
status: DepositStatus;
|
|
329
|
+
assetId: string;
|
|
330
|
+
networkId: string;
|
|
331
|
+
amount?: string;
|
|
332
|
+
accountMatchingValidation?: {
|
|
333
|
+
status: 'PENDING' | 'VALID' | 'INVALID' | 'ERROR';
|
|
334
|
+
reason?: string;
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
};
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* Deposit status object — shared across SDKs that surface deposit completion.
|
|
341
|
+
*/
|
|
342
|
+
declare type DepositStatus = {
|
|
343
|
+
value: string;
|
|
344
|
+
details: string;
|
|
345
|
+
occurredAt: string;
|
|
312
346
|
};
|
|
313
347
|
|
|
314
348
|
/**
|