Improved theming

This commit is contained in:
Mia Rose Winter 2024-01-21 23:27:56 +01:00
parent 08664bf1ea
commit fc635567ba
Signed by: miawinter
GPG key ID: 4B6F6A83178F595E
11 changed files with 37 additions and 27 deletions

View file

@ -47,16 +47,16 @@
</div>
if (IsMachineRemembered) {
<form style="display: inline-block" @formname="forget-browser" @onsubmit="OnSubmitForgetBrowserAsync" method="post">
<form style="display: inline-block" @formname="forget-browser" @onsubmit="OnSubmitForgetBrowserAsync" method="post" class="w-full">
<AntiforgeryToken/>
<button type="submit" class="btn btn-primary w-full my-3">
<button type="submit" class="btn btn-error w-full my-3">
@Localizer["ForgetBrowser_Submit"]
</button>
</form>
}
<div class="flex flex-col gap-2 mt-3">
<a href="Account/Manage/Disable2fa" class="btn btn-primary w-full">
<a href="Account/Manage/Disable2fa" class="btn btn-error w-full">
@Localizer["Disable_Label"]
</a>
<a href="Account/Manage/GenerateRecoveryCodes" class="btn btn-primary w-full">
@ -76,7 +76,7 @@
<a href="Account/Manage/EnableAuthenticator" class="btn btn-primary w-full" data-enhance-nav="false">
@Localizer["AuthenticatorEnable_Label"]
</a>
<a href="Account/Manage/ResetAuthenticator" class="btn btn-primary w-full">
<a href="Account/Manage/ResetAuthenticator" class="btn btn-error w-full">
@Localizer["AuthenticatorReset_Label"]
</a>
}

View file

@ -10,7 +10,7 @@
</div>
</div>
<div class="max-w-full">
<h1 class="text-3xl lg:text-5xl mb-6">@Localizer["Title"]</h1>
<h1 class="text-3xl lg:text-5xl mb-6 text-primary">@Localizer["Title"]</h1>
@Body
</div>

View file

@ -3,11 +3,11 @@
@inject IStringLocalizer<Pages.ArticleView> Localizer
<h1 class="text-3xl lg:text-5xl font-light">
<h1 class="text-3xl lg:text-5xl font-light text-primary">
@Article.Title
</h1>
<p class="mb-3">
<small class="text-sm text-neutral-content">
<p class="mb-6">
<small class="text-sm text-secondary">
<time datetime="@Article.PublishDate.ToString("u")"
title="@Article.PublishDate.ToString("g")">
@Article.PublishDate.Humanize()
@ -37,7 +37,7 @@
@if (!string.IsNullOrWhiteSpace(Article.Author.AboutTheAuthor)) {
<section class="mb-2">
<h2 class="text-2xl lg:text-4xl mb-3">About The Author</h2>
<div class="card sm:card-side card-compact bg-neutral text-neutral-content rounded shadow">
<div class="card sm:card-side card-compact bg-secondary text-secondary-content rounded shadow">
<figure class="sm:max-w-32">
<img src="/api/user/pfp/@Article.Author.Id" alt="" width="800">
</figure>

View file

@ -1,7 +1,7 @@
@using System.Globalization
<section class="w-80 max-w-xs">
@if (!string.IsNullOrWhiteSpace(Heading)) {
<h2 class="text-2xl lg:text-4xl lg:hyphens-auto mb-3" lang="@CultureInfo.CurrentCulture">@Heading</h2>
<h2 class="text-2xl lg:hyphens-auto mb-3" lang="@CultureInfo.CurrentCulture">@Heading</h2>
}
@ChildContent
</section>

View file

@ -2,7 +2,7 @@
<summary class="btn btn-circle btn-ghost btn-xs text-info">
<svg tabindex="0" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" class="w-4 h-4 stroke-current"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>
</summary>
<div class="card compact dropdown-content z-[1] shadow bg-base-100 rounded-box w-64">
<div class="card compact dropdown-content z-[1] shadow bg-base-100 dark:bg-base-200 rounded-box w-64">
<div class="card-body">
@if (!string.IsNullOrWhiteSpace(Title)) {
<h2 class="card-title">@Title</h2>

View file

@ -25,13 +25,13 @@
} else {
<ErrorBoundary>
<ChildContent>
<h1 class="text-3xl lg:text-5xl font-light mb-6">@Localizer["EditorTitle"]</h1>
<h1 class="text-3xl lg:text-5xl font-light mb-6 text-primary">@Localizer["EditorTitle"]</h1>
<div class="w-full">
<ul class="steps w-full max-w-xs">
<li class="step @(Article?.Status >= ArticleStatus.Draft ? "step-primary": "")">@Localizer["Draft"]</li>
<li class="step @(Article?.Status >= ArticleStatus.InReview ? "step-primary": "")">@Localizer["InReview"]</li>
<li class="step @(Article?.Status >= ArticleStatus.Published ? "step-primary": "")">@Localizer["Published"]</li>
<li class="step @(Article?.Status >= ArticleStatus.Draft ? "step-secondary": "")">@Localizer["Draft"]</li>
<li class="step @(Article?.Status >= ArticleStatus.InReview ? "step-secondary": "")">@Localizer["InReview"]</li>
<li class="step @(Article?.Status >= ArticleStatus.Published ? "step-secondary": "")">@Localizer["Published"]</li>
</ul>
</div>

View file

@ -36,7 +36,7 @@
</AuthorizeView>
</ChildContent>
<ErrorContent>
<h1 class="text-3xl lg:text-5xl font-light mb-6">@Localizer["NotFound_Title"]</h1>
<h1 class="text-3xl lg:text-5xl font-light mb-6 text-primary">@Localizer["NotFound_Title"]</h1>
<p class="my-3">@Localizer["NotFound_Description"]</p>
<a class="btn btn-primary" href="/">@Localizer["NotFound_BackToHome_Label"]</a>
@if (Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT")?.ToLower() == "development") {

View file

@ -10,7 +10,7 @@
<PageTitle>@(TitlePrefix + Localizer["Title"])</PageTitle>
<h1 class="text-3xl lg:text-5xl font-light mb-3">@Localizer["Title"]</h1>
<h1 class="text-3xl lg:text-5xl font-light mb-6 text-primary">@Localizer["Title"]</h1>
<!-- TODO: somehow get status message -->
@ -22,10 +22,10 @@
@if (Articles.FirstOrDefault() is {} featured) {
<article class="mb-6">
<a href="/article/@featured.Id">
<div class="hero bg-neutral text-neutral-content">
<div class="hero bg-secondary text-secondary-content">
<div class="hero-content">
<div class="flex flex-col space-y-6">
<h2 class="text-2xl lg:text-4xl font-bold">
<div class="flex flex-col space-y-6 my-3">
<h2 class="text-2xl lg:text-4xl leading-8 font-bold">
@featured.Title<br />
<small class="text-sm">@featured.PublishDate.ToString("g")</small>
</h2>

View file

@ -14,7 +14,7 @@
<PageTitle>@(TitlePrefix + Localizer["Title"])</PageTitle>
<h1 class="text-3xl lg:text-5xl font-light mb-6">@Localizer["Title"]</h1>
<h1 class="text-3xl lg:text-5xl font-light mb-6 text-primary">@Localizer["Title"]</h1>
<ModalComponent Id="@ModalId">
<ChildContent>

View file

@ -30,16 +30,21 @@ module.exports = {
themes: [
{
"wave-light": {
"primary": "#fff133",
"primary": "#F2E530",
"secondary": "#ffb3c8",
"accent": "#75dfff",
"neutral": "#75dfff",
"accent": "#6FD4F2",
"neutral": "#A69D21",
"base-100": "#FAF8F2",
"base-200": "#CCC7B8",
"base-300": "#99917A",
"base-content": "#000000",
"info": "#2494F0",
"success": "#2CDB00",
"warning": "#FFF000",
"error": "#B3020E",
"--rounded-box": "0.5rem",
"--rounded-btn": "0.2rem",
"--rounded-badge": "0.2rem",
@ -48,15 +53,20 @@ module.exports = {
{
"wave-dark": {
"primary": "#fff133",
"secondary": "#ffb3c8",
"secondary": "#DB9AAC",
"accent": "#75dfff",
"neutral": "#75dfff",
"neutral": "#A69D21",
"base-100": "#29141A",
"base-200": "#140A0D",
"base-300": "#0D0A0B",
"base-content": "#eae9fc",
"info": "#007EE6",
"success": "#1C8A00",
"warning": "#E3D400",
"error": "#610107",
"--rounded-box": "0.5rem",
"--rounded-btn": "0.2rem",
"--rounded-badge": "0.2rem",

File diff suppressed because one or more lines are too long