Crowdfund: Add theme switch to footer

This commit is contained in:
Dennis Reimann
2021-09-27 14:49:54 +02:00
committed by Andrew Camilleri
parent faed5349fb
commit 8948475cad

View File

@@ -21,14 +21,6 @@
{
@Safe.Raw($"<style>{Model.EmbeddedCSS}</style>")
}
@if (!Model.SimpleDisplay)
{
<script>var srvModel = @Safe.Json(Model);</script>
<bundle name="wwwroot/bundles/crowdfund-bundle-1.min.js" asp-append-version="true"></bundle>
<bundle name="wwwroot/bundles/crowdfund-bundle-2.min.js" asp-append-version="true"></bundle>
@*We need to make sure btcpay.js is not bundled, else it will not work if there is a RootPath*@
<script src="~/modal/btcpay.js" asp-append-version="true"></script>
}
</head>
<body>
@if (!Model.Enabled)
@@ -264,13 +256,14 @@
</div>
</noscript>
</div>
<div class="card-footer text-muted d-flex" v-if="srvModel.animationsEnabled || srvModel.soundsEnabled">
<div class="align-self-end pe-4" v-text="`Updated ${lastUpdated}`">Updated @Model.Info.LastUpdated</div>
<div class="form-check mx-1 only-for-js" v-if="srvModel.animationsEnabled || animation">
<div class="card-footer text-muted d-flex flex-wrap align-items-center">
<div class="me-3" v-text="`Updated ${lastUpdated}`">Updated @Model.Info.LastUpdated</div>
<vc:theme-switch css-class="text-muted me-3" responsive="none" />
<div class="form-check me-3 my-0 only-for-js" v-if="srvModel.animationsEnabled || animation">
<input class="form-check-input" type="checkbox" id="cbAnime" v-model="animation">
<label class="form-check-label" for="cbAnime">Animations</label>
</div>
<div class="form-check mx-1 only-for-js" v-if="srvModel.soundsEnabled|| sound">
<div class="form-check me-3 my-0 only-for-js" v-if="srvModel.soundsEnabled|| sound">
<input class="form-check-input" type="checkbox" id="cbSounds" v-model="sound">
<label class="form-check-label" for="cbSounds">Sounds</label>
</div>
@@ -389,5 +382,15 @@
</perks>
</div>
</template>
@if (!Model.SimpleDisplay)
{
<script>var srvModel = @Safe.Json(Model);</script>
<bundle name="wwwroot/bundles/crowdfund-bundle-1.min.js" asp-append-version="true"></bundle>
<bundle name="wwwroot/bundles/crowdfund-bundle-2.min.js" asp-append-version="true"></bundle>
@*We need to make sure btcpay.js is not bundled, else it will not work if there is a RootPath*@
<script src="~/modal/btcpay.js" asp-append-version="true"></script>
}
<partial name="LayoutFoot" />
</body>
</html>