mirror of
https://github.com/aljazceru/btcpayserver-breez-nodeless-spark.git
synced 2025-12-17 09:24:19 +01:00
hopefully final renaming fixes
This commit is contained in:
@@ -28,11 +28,11 @@
|
|||||||
<script>
|
<script>
|
||||||
document.addEventListener("DOMContentLoaded", function () {
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
const customNodeAccordian = document.getElementById("CustomNodeSupport");
|
const customNodeAccordian = document.getElementById("CustomNodeSupport");
|
||||||
const template = document.getElementById("breez");
|
const template = document.getElementById("breezspark");
|
||||||
customNodeAccordian.appendChild(template.content.cloneNode(true));
|
customNodeAccordian.appendChild(template.content.cloneNode(true));
|
||||||
|
|
||||||
// Auto-fill the connection string when Breez is selected
|
// Auto-fill the connection string when BreezSpark is selected
|
||||||
const breezRadio = document.getElementById("LightningNodeType-Breez");
|
const breezRadio = document.getElementById("LightningNodeType-BreezSpark");
|
||||||
const connStringEl = document.getElementById('ConnectionString');
|
const connStringEl = document.getElementById('ConnectionString');
|
||||||
|
|
||||||
if (breezRadio && connStringEl) {
|
if (breezRadio && connStringEl) {
|
||||||
@@ -48,15 +48,15 @@
|
|||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template id="breez">
|
<template id="breezspark">
|
||||||
<div class="accordion-item">
|
<div class="accordion-item">
|
||||||
<h2 class="accordion-header" id="CustomBreezHeader">
|
<h2 class="accordion-header" id="CustomBreezSparkHeader">
|
||||||
<button type="button" class="accordion-button collapsed" data-bs-toggle="collapse" data-bs-target="#CustomBreezContent" aria-controls="CustomBreezContent" aria-expanded="false">
|
<button type="button" class="accordion-button collapsed" data-bs-toggle="collapse" data-bs-target="#CustomBreezSparkContent" aria-controls="CustomBreezSparkContent" aria-expanded="false">
|
||||||
<span><strong>BreezSpark</strong> non-custodial Lightning wallet</span>
|
<span><strong>BreezSpark</strong> non-custodial Lightning wallet</span>
|
||||||
<vc:icon symbol="caret-down"/>
|
<vc:icon symbol="caret-down"/>
|
||||||
</button>
|
</button>
|
||||||
</h2>
|
</h2>
|
||||||
<div id="CustomBreezContent" class="accordion-collapse collapse" aria-labelledby="CustomBreezHeader" data-bs-parent="#CustomNodeSupport">
|
<div id="CustomBreezSparkContent" class="accordion-collapse collapse" aria-labelledby="CustomBreezSparkHeader" data-bs-parent="#CustomNodeSupport">
|
||||||
<div class="accordion-body">
|
<div class="accordion-body">
|
||||||
@if (!string.IsNullOrEmpty(paymentKey))
|
@if (!string.IsNullOrEmpty(paymentKey))
|
||||||
{
|
{
|
||||||
@@ -66,16 +66,16 @@
|
|||||||
<code>type=breezspark;key=@paymentKey;storeId=@Model.StoreId</code>
|
<code>type=breezspark;key=@paymentKey;storeId=@Model.StoreId</code>
|
||||||
</div>
|
</div>
|
||||||
<p class="my-2">
|
<p class="my-2">
|
||||||
The connection string above will be automatically filled when you select Breez.
|
The connection string above will be automatically filled when you select BreezSpark.
|
||||||
Connects to your <a href="https://breez.technology" target="_blank" rel="noreferrer noopener">Breez</a> mobile wallet.
|
Connects to your <a href="https://breez.technology" target="_blank" rel="noreferrer noopener">Breez</a> mobile wallet.
|
||||||
</p>
|
</p>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<div class="alert alert-warning">
|
<div class="alert alert-warning">
|
||||||
<strong>Breez not configured</strong>
|
<strong>BreezSpark not configured</strong>
|
||||||
<br/>
|
<br/>
|
||||||
Please <a href="/Breez/Index?storeId=@Model.StoreId">configure Breez first</a> to set up your payment key.
|
Please <a href="/BreezSpark/Index?storeId=@Model.StoreId">configure BreezSpark first</a> to set up your payment key.
|
||||||
</div>
|
</div>
|
||||||
<p class="my-2">Connects to a <a href="https://breez.technology" target="_blank" rel="noreferrer noopener">Breez</a> mobile wallet, using the Breez SDK to handle Lightning payments through swaps.</p>
|
<p class="my-2">Connects to a <a href="https://breez.technology" target="_blank" rel="noreferrer noopener">Breez</a> mobile wallet, using the Breez SDK to handle Lightning payments through swaps.</p>
|
||||||
}
|
}
|
||||||
@@ -84,7 +84,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<div id="BreezSetup" class="pt-3 tab-pane fade" role="tabpanel" aria-labelledby="LightningNodeType-Breez">
|
<div id="BreezSparkSetup" class="pt-3 tab-pane fade" role="tabpanel" aria-labelledby="LightningNodeType-BreezSpark">
|
||||||
<p>You can use Breez to accept lightning payments without running a traditional Lightning node.</p>
|
<p>You can use BreezSpark to accept lightning payments without running a traditional Lightning node.</p>
|
||||||
<p>Breez is a mobile-first Lightning Network client that provides a non-custodial solution for Lightning payments.</p>
|
<p>BreezSpark is a mobile-first Lightning Network client that provides a non-custodial solution for Lightning payments.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -15,24 +15,24 @@
|
|||||||
|
|
||||||
@if (breezClient == null)
|
@if (breezClient == null)
|
||||||
{
|
{
|
||||||
<a asp-action="Index" asp-controller="BreezSpark" permission="@Policies.CanModifyStoreSettings" asp-route-storeId="@Model.StoreId" type="radio" role="tab" aria-controls="BreezSetup" aria-selected="false" name="LightningNodeType">
|
<a asp-action="Index" asp-controller="BreezSpark" permission="@Policies.CanModifyStoreSettings" asp-route-storeId="@Model.StoreId" type="radio" role="tab" aria-controls="BreezSparkSetup" aria-selected="false" name="LightningNodeType">
|
||||||
<label for="LightningNodeType-Breez">Configure Breez</label>
|
<label for="LightningNodeType-BreezSpark">Configure BreezSpark</label>
|
||||||
</a>
|
</a>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<input value="Custom" type="radio" id="LightningNodeType-Breez" data-bs-toggle="pill" data-bs-target="#BreezSetup" role="tab" aria-controls="BreezSetup" aria-selected="false" name="LightningNodeType">
|
<input value="Custom" type="radio" id="LightningNodeType-BreezSpark" data-bs-toggle="pill" data-bs-target="#BreezSparkSetup" role="tab" aria-controls="BreezSparkSetup" aria-selected="false" name="LightningNodeType">
|
||||||
<label for="LightningNodeType-Breez">Use Breez</label>
|
<label for="LightningNodeType-BreezSpark">Use BreezSpark</label>
|
||||||
<script>
|
<script>
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
const typePrefix = '@breezClient.ToString()';
|
const typePrefix = '@breezClient.ToString()';
|
||||||
const connStringEl = document.getElementById('ConnectionString')
|
const connStringEl = document.getElementById('ConnectionString')
|
||||||
delegate('change', 'input[name="LightningNodeType"]', e => {
|
delegate('change', 'input[name="LightningNodeType"]', e => {
|
||||||
const activeEl = document.querySelector('input[name="LightningNodeType"]:checked')
|
const activeEl = document.querySelector('input[name="LightningNodeType"]:checked')
|
||||||
if (activeEl.id === "LightningNodeType-Breez"){
|
if (activeEl.id === "LightningNodeType-BreezSpark"){
|
||||||
connStringEl.value = typePrefix;
|
connStringEl.value = typePrefix;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user