mirror of
https://github.com/btcpayserver/btcpayserver.git
synced 2025-02-21 22:11:48 +01:00
Add copy tor url button to login and register
This commit is contained in:
parent
e9870a4455
commit
a122c38666
4 changed files with 28 additions and 4 deletions
|
@ -31,8 +31,9 @@
|
||||||
<h4 class="modal-title">Sign In</h4>
|
<h4 class="modal-title">Sign In</h4>
|
||||||
@if (env.OnionUrl != null)
|
@if (env.OnionUrl != null)
|
||||||
{
|
{
|
||||||
<a href="@env.OnionUrl">
|
<a href="@env.OnionUrl" target="_onion" class="btn btn-onion d-inline-flex align-items-center" data-clipboard="@env.OnionUrl">
|
||||||
<img src="~/img/icons/Onion.svg" height="24" asp-append-version="true" />
|
<img src="~/img/icons/Onion_Color.svg" height="24" class="mr-2" asp-append-version="true" />
|
||||||
|
Copy Tor URL
|
||||||
</a>
|
</a>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -31,8 +31,9 @@
|
||||||
<h4 class="modal-title">Create account</h4>
|
<h4 class="modal-title">Create account</h4>
|
||||||
@if (env.OnionUrl != null)
|
@if (env.OnionUrl != null)
|
||||||
{
|
{
|
||||||
<a href="@env.OnionUrl">
|
<a href="@env.OnionUrl" target="_onion" class="btn btn-onion d-inline-flex align-items-center" data-clipboard="@env.OnionUrl">
|
||||||
<img src="~/img/icons/Onion.svg" height="24" asp-append-version="true" />
|
<img src="~/img/icons/Onion_Color.svg" height="24" class="mr-2" asp-append-version="true" />
|
||||||
|
Copy Tor URL
|
||||||
</a>
|
</a>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -195,6 +195,17 @@ pre {
|
||||||
background: none;
|
background: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.btn-onion {
|
||||||
|
color: #fff;
|
||||||
|
background-color: #59316B;
|
||||||
|
border-color: #59316B;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-onion:focus,
|
||||||
|
.btn-onion.focus {
|
||||||
|
box-shadow: 0 0 0 0.2rem #9065a1;
|
||||||
|
}
|
||||||
|
|
||||||
[class*="field-validation"]:not(:empty) {
|
[class*="field-validation"]:not(:empty) {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
margin-top: .5rem;
|
margin-top: .5rem;
|
||||||
|
|
|
@ -74,6 +74,17 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$('[data-clipboard]').on('click', function (e) {
|
||||||
|
if (navigator.clipboard) {
|
||||||
|
e.preventDefault();
|
||||||
|
var item = e.currentTarget;
|
||||||
|
var text = item.getAttribute('data-clipboard');
|
||||||
|
navigator.clipboard.writeText(text);
|
||||||
|
item.blur();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
function switchTimeFormat() {
|
function switchTimeFormat() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue