@secondts/bark-react-native 0.20.1 → 0.21.0

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.
@@ -1 +1 @@
1
- {"version":3,"names":["getter","globalThis","NativeBark","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;AAAA;AACA;;AAEA;AACA;AACA;;AA6yBA;AACA;AACA;AACA;AACA;AACA,MAAMA,MAAmC,GAAGA,CAAA,KACzCC,UAAU,CAASC,UAAU;AAChC,eAAeF,MAAM;;AAErB;;AAwKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMG,8CAGL,GAAG,IAAI;AACR,MAAMC,mCAGL,GAAG,IAAI","ignoreList":[]}
1
+ {"version":3,"names":["getter","globalThis","NativeBark","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;AAAA;AACA;;AAEA;AACA;AACA;;AAwzBA;AACA;AACA;AACA;AACA;AACA,MAAMA,MAAmC,GAAGA,CAAA,KACzCC,UAAU,CAASC,UAAU;AAChC,eAAeF,MAAM;;AAErB;;AAwKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMG,8CAGL,GAAG,IAAI;AACR,MAAMC,mCAGL,GAAG,IAAI","ignoreList":[]}
@@ -304,6 +304,50 @@ const FfiConverterTypeBoardFees = (() => {
304
304
  }
305
305
  return new FFIConverter();
306
306
  })();
307
+
308
+ /**
309
+ * Destination for an externally funded board (e.g. a payjoin receive).
310
+ *
311
+ * The funding script commits to the derived keypair and expiry height, so
312
+ * `keypair_index` and `expiry_height` must be passed back unchanged to
313
+ * `board_psbt` once the funding PSBT is available — including on retries
314
+ * after the sender changes the transaction.
315
+ */
316
+
317
+ /**
318
+ * Generated factory for {@link BoardFundingInfo} record objects.
319
+ */
320
+ export const BoardFundingInfo = (() => {
321
+ const defaults = () => ({});
322
+ const create = (() => {
323
+ return uniffiCreateRecord(defaults);
324
+ })();
325
+ return Object.freeze({
326
+ create,
327
+ new: create,
328
+ defaults: () => Object.freeze(defaults())
329
+ });
330
+ })();
331
+ const FfiConverterTypeBoardFundingInfo = (() => {
332
+ class FFIConverter extends AbstractFfiConverterByteArray {
333
+ read(from) {
334
+ return {
335
+ address: FfiConverterString.read(from),
336
+ expiryHeight: FfiConverterUInt32.read(from),
337
+ keypairIndex: FfiConverterUInt32.read(from)
338
+ };
339
+ }
340
+ write(value, into) {
341
+ FfiConverterString.write(value.address, into);
342
+ FfiConverterUInt32.write(value.expiryHeight, into);
343
+ FfiConverterUInt32.write(value.keypairIndex, into);
344
+ }
345
+ allocationSize(value) {
346
+ return FfiConverterString.allocationSize(value.address) + FfiConverterUInt32.allocationSize(value.expiryHeight) + FfiConverterUInt32.allocationSize(value.keypairIndex);
347
+ }
348
+ }
349
+ return new FFIConverter();
350
+ })();
307
351
  /**
308
352
  * Generated factory for {@link Config} record objects.
309
353
  */
@@ -4677,6 +4721,32 @@ export class Wallet extends UniffiAbstractObject {
4677
4721
  throw __error;
4678
4722
  }
4679
4723
  }
4724
+ async boardFundingAddress(asyncOpts_) /*throws*/{
4725
+ const __stack = uniffiIsDebug ? new Error().stack : undefined;
4726
+ try {
4727
+ return await uniffiRustCallAsync(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
4728
+ return nativeModule().ubrn_uniffi_bark_ffi_fn_method_wallet_board_funding_address(uniffiTypeWalletObjectFactory.clonePointer(this));
4729
+ }, /*pollFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterTypeBoardFundingInfo.lift.bind(FfiConverterTypeBoardFundingInfo), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeError.lift.bind(FfiConverterTypeError));
4730
+ } catch (__error) {
4731
+ if (uniffiIsDebug && __error instanceof Error) {
4732
+ __error.stack = __stack;
4733
+ }
4734
+ throw __error;
4735
+ }
4736
+ }
4737
+ async boardPsbt(psbtBase64, keypairIndex, expiryHeight, asyncOpts_) /*throws*/{
4738
+ const __stack = uniffiIsDebug ? new Error().stack : undefined;
4739
+ try {
4740
+ return await uniffiRustCallAsync(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
4741
+ return nativeModule().ubrn_uniffi_bark_ffi_fn_method_wallet_board_psbt(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(psbtBase64), FfiConverterUInt32.lower(keypairIndex), FfiConverterUInt32.lower(expiryHeight));
4742
+ }, /*pollFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/nativeModule().ubrn_ffi_bark_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterTypePendingBoard.lift.bind(FfiConverterTypePendingBoard), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeError.lift.bind(FfiConverterTypeError));
4743
+ } catch (__error) {
4744
+ if (uniffiIsDebug && __error instanceof Error) {
4745
+ __error.stack = __stack;
4746
+ }
4747
+ throw __error;
4748
+ }
4749
+ }
4680
4750
  async bolt11Invoice(amountSats, description, token = undefined, asyncOpts_) /*throws*/{
4681
4751
  const __stack = uniffiIsDebug ? new Error().stack : undefined;
4682
4752
  try {
@@ -6164,6 +6234,12 @@ function uniffiEnsureInitialized() {
6164
6234
  if (nativeModule().ubrn_uniffi_bark_ffi_checksum_method_wallet_board_amount() !== 54692) {
6165
6235
  throw new UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_board_amount");
6166
6236
  }
6237
+ if (nativeModule().ubrn_uniffi_bark_ffi_checksum_method_wallet_board_funding_address() !== 8961) {
6238
+ throw new UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_board_funding_address");
6239
+ }
6240
+ if (nativeModule().ubrn_uniffi_bark_ffi_checksum_method_wallet_board_psbt() !== 28300) {
6241
+ throw new UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_board_psbt");
6242
+ }
6167
6243
  if (nativeModule().ubrn_uniffi_bark_ffi_checksum_method_wallet_bolt11_invoice() !== 54959) {
6168
6244
  throw new UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_bolt11_invoice");
6169
6245
  }
@@ -6455,6 +6531,7 @@ export default Object.freeze({
6455
6531
  FfiConverterTypeBarkLogger,
6456
6532
  FfiConverterTypeBlockRef,
6457
6533
  FfiConverterTypeBoardFees,
6534
+ FfiConverterTypeBoardFundingInfo,
6458
6535
  FfiConverterTypeConfig,
6459
6536
  FfiConverterTypeCpfpParams,
6460
6537
  FfiConverterTypeCustomOnchainWalletCallbacks,