btcpayserver/BTCPayServer/Views/UIServer/LndSeedBackup.cshtml
d11n 77fba4aee3
Add more translations (#6302)
* Newlines

* Dashboard

* Add more translations

* Moar

* Remove   from translated texts

* Dictionary controller translations

* Batch 1 of controller updates

* Batch 2 of controller updates

* Component translations

* Batch 3 of controller updates

* Fixes
2024-10-17 22:51:40 +09:00

84 lines
4.2 KiB
Text

@using BTCPayServer.Abstractions.Models
@model LndSeedBackupViewModel
@{
ViewData.SetActivePage(ServerNavPages.Services, "LND Seed Backup");
}
<div class="sticky-header">
<nav aria-label="breadcrumb">
<ol class="breadcrumb">
<li class="breadcrumb-item">
<a asp-action="Services" text-translate="true">Services</a>
</li>
<li class="breadcrumb-item active" aria-current="page" text-translate="true">@ViewData["Title"]</li>
</ol>
<h2 text-translate="true">@ViewData["Title"]</h2>
</nav>
</div>
<partial name="_StatusMessage" />
@if (Model.IsWalletUnlockPresent)
{
<div class="row">
<div class="col-lg-8">
<div class="form-group">
<p text-translate="true">The LND seed backup is useful to recover on-chain funds of your LND wallet in case of a corruption of your server.</p>
<p>The recovering process is documented by LND on <a href="https://github.com/lightningnetwork/lnd/blob/master/docs/recovery.md" rel="noreferrer noopener">this page</a>.</p>
</div>
<button class="btn btn-primary @(Model.Removed ? "collapse" : "")" id="details" type="button">See confidential seed information</button>
@if (Model.Removed)
{
<div class="alert alert-light d-flex align-items-center" role="alert">
<vc:icon symbol="warning" />
<span class="ms-3" id="Seed">@Model.Seed</span>
</div>
}
else
{
<div class="form-group @(Model.Removed ? "" : "collapse")">
<div class="form-group">
<label asp-for="Seed" class="form-label"></label>
<div class="input-group">
<input asp-for="Seed" type="password" class="form-control" value="@Model.Seed">
<button type="button" class="btn btn-secondary px-3 only-for-js" title="Toggle seed visibility" data-toggle-password="#Seed">
<vc:icon symbol="actions-show" />
</button>
</div>
</div>
<div class="form-group">
<label asp-for="WalletPassword" class="form-label" text-translate="true">Password</label>
<div class="input-group">
<input asp-for="WalletPassword" type="password" class="form-control" value="@Model.WalletPassword">
<button type="button" class="btn btn-secondary px-3 only-for-js" title="Toggle password visibility" data-toggle-password="#WalletPassword">
<vc:icon symbol="actions-show" />
</button>
</div>
</div>
</div>
<div class="form-group collapse">
<form method="get" asp-action="RemoveLndSeed" asp-route-serviceName="@Context.GetRouteValue("serviceName")" asp-route-cryptoCode="@Context.GetRouteValue("cryptoCode")">
<button id="delete" class="btn btn-primary" type="submit" data-bs-toggle="modal" data-bs-target="#ConfirmModal" data-confirm-input="DELETE" text-translate="true">Delete LND seed from server</button>
</form>
</div>
}
</div>
</div>
}
@if (!Model.Removed)
{
<partial name="_Confirm" model="@(new ConfirmModel("Delete LND seed", "This action will permanently delete your LND seed and password. You will not be able to recover them if you don't have a backup.", "Delete"))"/>
}
@section PageFootContent {
<script>
delegate('click', '#Seed', event => { event.target.select() })
delegate('click', '#WalletPassword', event => { event.target.select() })
delegate('click', '#delete', event => { event.preventDefault() })
delegate('click', '#details', event => {
document.querySelectorAll('.form-group.collapse').forEach(el => el.classList.remove('collapse'))
event.target.classList.add('collapse')
})
</script>
}