2024-09-24 11:06:27 +02:00
|
|
|
window.app.component('lnbits-funding-sources', {
|
2024-09-27 12:09:47 +02:00
|
|
|
template: '#lnbits-funding-sources',
|
2024-09-24 11:06:27 +02:00
|
|
|
mixins: [window.windowMixin],
|
2023-10-10 12:02:40 +02:00
|
|
|
props: ['form-data', 'allowed-funding-sources'],
|
2024-06-10 22:37:09 +01:00
|
|
|
methods: {
|
|
|
|
getFundingSourceLabel(item) {
|
|
|
|
const fundingSource = this.rawFundingSources.find(
|
|
|
|
fundingSource => fundingSource[0] === item
|
|
|
|
)
|
|
|
|
return fundingSource ? fundingSource[1] : item
|
|
|
|
}
|
|
|
|
},
|
2023-10-10 12:02:40 +02:00
|
|
|
computed: {
|
|
|
|
fundingSources() {
|
|
|
|
let tmp = []
|
|
|
|
for (const [key, _, obj] of this.rawFundingSources) {
|
|
|
|
const tmpObj = {}
|
|
|
|
if (obj !== null) {
|
|
|
|
for (let [k, v] of Object.entries(obj)) {
|
|
|
|
tmpObj[k] = {label: v, value: null}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
tmp.push([key, tmpObj])
|
|
|
|
}
|
|
|
|
return new Map(tmp)
|
2024-06-10 22:37:09 +01:00
|
|
|
},
|
|
|
|
sortedAllowedFundingSources() {
|
|
|
|
return this.allowedFundingSources.sort()
|
2023-10-10 12:02:40 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
rawFundingSources: [
|
|
|
|
['VoidWallet', 'Void Wallet', null],
|
|
|
|
[
|
|
|
|
'FakeWallet',
|
|
|
|
'Fake Wallet',
|
|
|
|
{
|
|
|
|
fake_wallet_secret: 'Secret'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'CoreLightningWallet',
|
|
|
|
'Core Lightning',
|
|
|
|
{
|
2024-04-25 12:54:00 +02:00
|
|
|
corelightning_rpc: 'Endpoint',
|
|
|
|
corelightning_pay_command: 'Custom Pay Command'
|
2023-10-10 12:02:40 +02:00
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'CoreLightningRestWallet',
|
|
|
|
'Core Lightning Rest',
|
|
|
|
{
|
|
|
|
corelightning_rest_url: 'Endpoint',
|
|
|
|
corelightning_rest_cert: 'Certificate',
|
|
|
|
corelightning_rest_macaroon: 'Macaroon'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'LndRestWallet',
|
|
|
|
'Lightning Network Daemon (LND Rest)',
|
|
|
|
{
|
|
|
|
lnd_rest_endpoint: 'Endpoint',
|
|
|
|
lnd_rest_cert: 'Certificate',
|
|
|
|
lnd_rest_macaroon: 'Macaroon',
|
2024-03-22 12:45:39 +01:00
|
|
|
lnd_rest_macaroon_encrypted: 'Encrypted Macaroon',
|
2024-11-26 09:32:44 -03:00
|
|
|
lnd_rest_route_hints: 'Enable Route Hints',
|
|
|
|
lnd_rest_allow_self_payment: 'Allow Self Payment'
|
2023-10-10 12:02:40 +02:00
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'LndWallet',
|
|
|
|
'Lightning Network Daemon (LND)',
|
|
|
|
{
|
|
|
|
lnd_grpc_endpoint: 'Endpoint',
|
|
|
|
lnd_grpc_cert: 'Certificate',
|
|
|
|
lnd_grpc_port: 'Port',
|
|
|
|
lnd_grpc_admin_macaroon: 'Admin Macaroon',
|
|
|
|
lnd_grpc_macaroon_encrypted: 'Encrypted Macaroon'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'LnTipsWallet',
|
|
|
|
'LN.Tips',
|
|
|
|
{
|
|
|
|
lntips_api_endpoint: 'Endpoint',
|
|
|
|
lntips_api_key: 'API Key'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'LNPayWallet',
|
|
|
|
'LN Pay',
|
|
|
|
{
|
|
|
|
lnpay_api_endpoint: 'Endpoint',
|
|
|
|
lnpay_api_key: 'API Key',
|
|
|
|
lnpay_wallet_key: 'Wallet Key'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'EclairWallet',
|
|
|
|
'Eclair (ACINQ)',
|
|
|
|
{
|
|
|
|
eclair_url: 'URL',
|
|
|
|
eclair_pass: 'Password'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'LNbitsWallet',
|
2024-06-17 08:08:22 +01:00
|
|
|
'LNbits',
|
2023-10-10 12:02:40 +02:00
|
|
|
{
|
|
|
|
lnbits_endpoint: 'Endpoint',
|
|
|
|
lnbits_key: 'Admin Key'
|
|
|
|
}
|
|
|
|
],
|
2024-07-19 22:32:02 +02:00
|
|
|
[
|
|
|
|
'BlinkWallet',
|
|
|
|
'Blink',
|
|
|
|
{
|
|
|
|
blink_api_endpoint: 'Endpoint',
|
|
|
|
blink_ws_endpoint: 'WebSocket',
|
|
|
|
blink_token: 'Key'
|
|
|
|
}
|
|
|
|
],
|
2023-11-14 11:28:25 -08:00
|
|
|
[
|
|
|
|
'AlbyWallet',
|
|
|
|
'Alby',
|
|
|
|
{
|
|
|
|
alby_api_endpoint: 'Endpoint',
|
|
|
|
alby_access_token: 'Key'
|
|
|
|
}
|
|
|
|
],
|
2024-08-20 11:38:30 +02:00
|
|
|
[
|
|
|
|
'BoltzWallet',
|
|
|
|
'Boltz',
|
|
|
|
{
|
|
|
|
boltz_client_endpoint: 'Endpoint',
|
|
|
|
boltz_client_macaroon: 'Admin Macaroon path or hex',
|
|
|
|
boltz_client_cert: 'Certificate path or hex',
|
|
|
|
boltz_client_wallet: 'Wallet Name'
|
|
|
|
}
|
|
|
|
],
|
2024-02-01 16:10:15 -08:00
|
|
|
[
|
|
|
|
'ZBDWallet',
|
|
|
|
'ZBD',
|
|
|
|
{
|
|
|
|
zbd_api_endpoint: 'Endpoint',
|
2024-02-01 18:36:17 -08:00
|
|
|
zbd_api_key: 'Key'
|
2024-02-01 16:10:15 -08:00
|
|
|
}
|
|
|
|
],
|
2024-04-26 01:18:38 -07:00
|
|
|
[
|
|
|
|
'PhoenixdWallet',
|
|
|
|
'Phoenixd',
|
|
|
|
{
|
|
|
|
phoenixd_api_endpoint: 'Endpoint',
|
|
|
|
phoenixd_api_password: 'Key'
|
|
|
|
}
|
|
|
|
],
|
2023-10-10 12:02:40 +02:00
|
|
|
[
|
|
|
|
'OpenNodeWallet',
|
|
|
|
'OpenNode',
|
|
|
|
{
|
|
|
|
opennode_api_endpoint: 'Endpoint',
|
|
|
|
opennode_key: 'Key'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'ClicheWallet',
|
|
|
|
'Cliche (NBD)',
|
|
|
|
{
|
|
|
|
cliche_endpoint: 'Endpoint'
|
|
|
|
}
|
|
|
|
],
|
|
|
|
[
|
|
|
|
'SparkWallet',
|
|
|
|
'Spark',
|
|
|
|
{
|
|
|
|
spark_url: 'Endpoint',
|
|
|
|
spark_token: 'Token'
|
|
|
|
}
|
2024-08-06 10:06:21 +02:00
|
|
|
],
|
2024-08-07 09:56:53 +02:00
|
|
|
[
|
|
|
|
'NWCWallet',
|
|
|
|
'Nostr Wallet Connect',
|
|
|
|
{
|
|
|
|
nwc_pairing_url: 'Pairing URL'
|
|
|
|
}
|
|
|
|
],
|
2024-08-06 10:06:21 +02:00
|
|
|
[
|
|
|
|
'BreezSdkWallet',
|
|
|
|
'Breez SDK',
|
|
|
|
{
|
|
|
|
breez_api_key: 'Breez API Key',
|
|
|
|
breez_greenlight_seed: 'Greenlight Seed',
|
|
|
|
breez_greenlight_device_key: 'Greenlight Device Key',
|
|
|
|
breez_greenlight_device_cert: 'Greenlight Device Cert',
|
|
|
|
breez_greenlight_invite_code: 'Greenlight Invite Code'
|
|
|
|
}
|
2023-10-10 12:02:40 +02:00
|
|
|
]
|
|
|
|
]
|
|
|
|
}
|
2024-09-27 12:09:47 +02:00
|
|
|
}
|
2023-10-10 12:02:40 +02:00
|
|
|
})
|