btcpayserver/BTCPayServer/Views/UIServer/Theme.cshtml
2022-04-14 13:09:37 +09:00

39 lines
1.9 KiB
Text

@model BTCPayServer.Services.ThemeSettings
@{
ViewData.SetActivePage(ServerNavPages.Theme, "Theme");
}
@section PageFootContent {
<partial name="_ValidationScriptsPartial" />
}
<h3 class="mb-4">@ViewData["Title"]</h3>
<div class="row">
<div class="col-xl-8 col-xxl-constrain">
<form method="post">
<p>Use the default Light or Dark Themes, or provide a CSS theme file below.</p>
@if (!ViewContext.ModelState.IsValid)
{
<div asp-validation-summary="All" class="text-danger"></div>
}
<div class="form-group d-flex align-items-center">
<input asp-for="CustomTheme" type="checkbox" class="btcpay-toggle me-3" data-bs-toggle="collapse" data-bs-target="#CustomThemeSettings" aria-expanded="@Model.CustomTheme" aria-controls="CustomThemeSettings" />
<label asp-for="CustomTheme" class="form-label mb-0"></label>
<span asp-validation-for="CustomTheme" class="text-danger"></span>
</div>
<div class="collapse @(Model.CustomTheme ? "show" : "")" id="CustomThemeSettings">
<div class="form-group">
<label asp-for="CustomThemeCssUri" class="form-label"></label>
<a href="https://docs.btcpayserver.org/Development/Theme/#1-custom-themes" target="_blank" rel="noreferrer noopener">
<span class="fa fa-question-circle-o text-secondary" title="More information..."></span>
</a>
<input asp-for="CustomThemeCssUri" class="form-control" />
<span asp-validation-for="CustomThemeCssUri" class="text-danger"></span>
</div>
</div>
<button type="submit" class="btn btn-primary mt-2" name="command" value="Save">Save</button>
</form>
</div>
</div>