@secondts/bark-react-native 0.3.2 → 0.3.3
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/README.md +1 -1
- package/cpp/generated/bark.cpp +36 -0
- package/cpp/generated/bark.hpp +2 -0
- package/lib/commonjs/generated/bark-ffi.js.map +1 -1
- package/lib/commonjs/generated/bark.js +24 -0
- package/lib/commonjs/generated/bark.js.map +1 -1
- package/lib/module/generated/bark-ffi.js.map +1 -1
- package/lib/module/generated/bark.js +24 -0
- package/lib/module/generated/bark.js.map +1 -1
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts +2 -0
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/bark.d.ts +20 -0
- package/lib/typescript/commonjs/src/generated/bark.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/bark-ffi.d.ts +2 -0
- package/lib/typescript/module/src/generated/bark-ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/bark.d.ts +20 -0
- package/lib/typescript/module/src/generated/bark.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/generated/bark-ffi.ts +5 -0
- package/src/generated/bark.ts +65 -0
package/README.md
CHANGED
|
@@ -60,7 +60,7 @@ npx expo install @secondts/bark-react-native@beta
|
|
|
60
60
|
|
|
61
61
|
```bash
|
|
62
62
|
# Or install a specific beta version
|
|
63
|
-
npx expo install @secondts/bark-react-native@0.3.
|
|
63
|
+
npx expo install @secondts/bark-react-native@0.3.3
|
|
64
64
|
```
|
|
65
65
|
|
|
66
66
|
For bare React Native projects, use:
|
package/cpp/generated/bark.cpp
CHANGED
|
@@ -328,6 +328,10 @@ extern "C" {
|
|
|
328
328
|
RustBuffer address,
|
|
329
329
|
RustBuffer fee_rate_sat_per_vb
|
|
330
330
|
);
|
|
331
|
+
/*handle*/ uint64_t uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(
|
|
332
|
+
/*handle*/ uint64_t ptr,
|
|
333
|
+
uint64_t amount_sats
|
|
334
|
+
);
|
|
331
335
|
/*handle*/ uint64_t uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(
|
|
332
336
|
/*handle*/ uint64_t ptr,
|
|
333
337
|
uint64_t amount_sats
|
|
@@ -845,6 +849,8 @@ extern "C" {
|
|
|
845
849
|
);
|
|
846
850
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_drain_exits(
|
|
847
851
|
);
|
|
852
|
+
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(
|
|
853
|
+
);
|
|
848
854
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(
|
|
849
855
|
);
|
|
850
856
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee(
|
|
@@ -4248,6 +4254,14 @@ NativeBark::NativeBark(
|
|
|
4248
4254
|
return this->cpp_uniffi_bark_ffi_fn_method_wallet_drain_exits(rt, thisVal, args, count);
|
|
4249
4255
|
}
|
|
4250
4256
|
);
|
|
4257
|
+
props["ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee"] = jsi::Function::createFromHostFunction(
|
|
4258
|
+
rt,
|
|
4259
|
+
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee"),
|
|
4260
|
+
2,
|
|
4261
|
+
[this](jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args, size_t count) -> jsi::Value {
|
|
4262
|
+
return this->cpp_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(rt, thisVal, args, count);
|
|
4263
|
+
}
|
|
4264
|
+
);
|
|
4251
4265
|
props["ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee"] = jsi::Function::createFromHostFunction(
|
|
4252
4266
|
rt,
|
|
4253
4267
|
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee"),
|
|
@@ -5408,6 +5422,14 @@ NativeBark::NativeBark(
|
|
|
5408
5422
|
return this->cpp_uniffi_bark_ffi_checksum_method_wallet_drain_exits(rt, thisVal, args, count);
|
|
5409
5423
|
}
|
|
5410
5424
|
);
|
|
5425
|
+
props["ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee"] = jsi::Function::createFromHostFunction(
|
|
5426
|
+
rt,
|
|
5427
|
+
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee"),
|
|
5428
|
+
0,
|
|
5429
|
+
[this](jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args, size_t count) -> jsi::Value {
|
|
5430
|
+
return this->cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(rt, thisVal, args, count);
|
|
5431
|
+
}
|
|
5432
|
+
);
|
|
5411
5433
|
props["ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee"] = jsi::Function::createFromHostFunction(
|
|
5412
5434
|
rt,
|
|
5413
5435
|
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee"),
|
|
@@ -6444,6 +6466,13 @@ jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_drain_exits(jsi::Run
|
|
|
6444
6466
|
);
|
|
6445
6467
|
|
|
6446
6468
|
|
|
6469
|
+
return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker, value);
|
|
6470
|
+
}
|
|
6471
|
+
jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
6472
|
+
auto value = uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker, args[0]), uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[1])
|
|
6473
|
+
);
|
|
6474
|
+
|
|
6475
|
+
|
|
6447
6476
|
return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker, value);
|
|
6448
6477
|
}
|
|
6449
6478
|
jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
@@ -7528,6 +7557,13 @@ jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_drain_exits(js
|
|
|
7528
7557
|
);
|
|
7529
7558
|
|
|
7530
7559
|
|
|
7560
|
+
return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
|
|
7561
|
+
}
|
|
7562
|
+
jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
7563
|
+
auto value = uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(
|
|
7564
|
+
);
|
|
7565
|
+
|
|
7566
|
+
|
|
7531
7567
|
return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
|
|
7532
7568
|
}
|
|
7533
7569
|
jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
package/cpp/generated/bark.hpp
CHANGED
|
@@ -53,6 +53,7 @@ class NativeBark : public jsi::HostObject {
|
|
|
53
53
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_claimable_lightning_receive_balance_sats(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
54
54
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_config(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
55
55
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_drain_exits(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
56
|
+
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
56
57
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
57
58
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
58
59
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_send_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
@@ -198,6 +199,7 @@ class NativeBark : public jsi::HostObject {
|
|
|
198
199
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_claimable_lightning_receive_balance_sats(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
199
200
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_config(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
200
201
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_drain_exits(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
202
|
+
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
201
203
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
202
204
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
203
205
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_send_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["getter","globalThis","NativeBark","_default","exports","default","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;;;;;AAAA;AACA;;AAEA;AACA;AACA;;
|
|
1
|
+
{"version":3,"names":["getter","globalThis","NativeBark","_default","exports","default","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;;;;;AAAA;AACA;;AAEA;AACA;AACA;;AA0oBA;AACA;AACA;AACA;AACA;AACA,MAAMA,MAAmC,GAAGA,CAAA,KACzCC,UAAU,CAASC,UAAU;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAClBL,MAAM,EAErB;AA8JA;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,MAAMM,8CAGL,GAAG,IAAI;AACR,MAAMC,mCAGL,GAAG,IAAI","ignoreList":[]}
|
|
@@ -2959,6 +2959,27 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
2959
2959
|
}
|
|
2960
2960
|
}
|
|
2961
2961
|
|
|
2962
|
+
/**
|
|
2963
|
+
* Estimate the fee for an arkoor payment
|
|
2964
|
+
*
|
|
2965
|
+
* # Arguments
|
|
2966
|
+
*
|
|
2967
|
+
* * `amount_sats` - Amount to send in sats
|
|
2968
|
+
*/
|
|
2969
|
+
async estimateArkoorPaymentFee(amountSats, asyncOpts_) /*throws*/{
|
|
2970
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
2971
|
+
try {
|
|
2972
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
2973
|
+
return (0, _barkFfi.default)().ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(uniffiTypeWalletObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt64.lower(amountSats));
|
|
2974
|
+
}, /*pollFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterTypeFeeEstimate.lift.bind(FfiConverterTypeFeeEstimate), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBarkError.lift.bind(FfiConverterTypeBarkError));
|
|
2975
|
+
} catch (__error) {
|
|
2976
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
2977
|
+
__error.stack = __stack;
|
|
2978
|
+
}
|
|
2979
|
+
throw __error;
|
|
2980
|
+
}
|
|
2981
|
+
}
|
|
2982
|
+
|
|
2962
2983
|
/**
|
|
2963
2984
|
* Estimate the fee for a board operation
|
|
2964
2985
|
*
|
|
@@ -4379,6 +4400,9 @@ function uniffiEnsureInitialized() {
|
|
|
4379
4400
|
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_drain_exits() !== 50942) {
|
|
4380
4401
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_drain_exits");
|
|
4381
4402
|
}
|
|
4403
|
+
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee() !== 26310) {
|
|
4404
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee");
|
|
4405
|
+
}
|
|
4382
4406
|
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee() !== 21849) {
|
|
4383
4407
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee");
|
|
4384
4408
|
}
|