fix: use .widget class for search and custom-html sidebar widgets

The search and custom-html widget types were using a non-existent
sidebar-widget class instead of the standard .widget class, causing
them to lack the spacing, border, and background styling that all
other widgets get. Updated all 4 sidebar containers.
This commit is contained in:
Ricardo
2026-02-22 00:10:26 +01:00
parent adccb1602b
commit 557d9f18a0
4 changed files with 16 additions and 16 deletions

View File

@@ -35,16 +35,16 @@
{% elif widget.type == "recent-comments" %}
{% include "components/widgets/recent-comments.njk" %}
{% elif widget.type == "search" %}
<div class="sidebar-widget">
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">Search</h3>
<div class="widget">
<h3 class="widget-title">Search</h3>
<div id="blog-sidebar-search"></div>
<script>initPagefind("#blog-sidebar-search");</script>
</div>
{% elif widget.type == "custom-html" %}
{% set wConfig = widget.config or {} %}
<div class="sidebar-widget">
<div class="widget">
{% if wConfig.title %}
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">{{ wConfig.title }}</h3>
<h3 class="widget-title">{{ wConfig.title }}</h3>
{% endif %}
{% if wConfig.content %}
<div class="prose dark:prose-invert prose-sm max-w-none">

View File

@@ -18,8 +18,8 @@
{% elif widget.type == "categories" %}
{% include "components/widgets/categories.njk" %}
{% elif widget.type == "search" %}
<div class="sidebar-widget">
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">Search</h3>
<div class="widget">
<h3 class="widget-title">Search</h3>
<div id="sidebar-search"></div>
<script>initPagefind("#sidebar-search");</script>
</div>
@@ -28,9 +28,9 @@
{% elif widget.type == "custom-html" %}
{# Custom content widget #}
{% set wConfig = widget.config or {} %}
<div class="sidebar-widget">
<div class="widget">
{% if wConfig.title %}
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">{{ wConfig.title }}</h3>
<h3 class="widget-title">{{ wConfig.title }}</h3>
{% endif %}
{% if wConfig.content %}
<div class="prose dark:prose-invert prose-sm max-w-none">

View File

@@ -18,8 +18,8 @@
{% elif widget.type == "categories" %}
{% include "components/widgets/categories.njk" %}
{% elif widget.type == "search" %}
<div class="sidebar-widget">
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">Search</h3>
<div class="widget">
<h3 class="widget-title">Search</h3>
<div id="sidebar-search"></div>
<script>initPagefind("#sidebar-search");</script>
</div>
@@ -30,9 +30,9 @@
{% elif widget.type == "custom-html" %}
{# Custom content widget #}
{% set wConfig = widget.config or {} %}
<div class="sidebar-widget">
<div class="widget">
{% if wConfig.title %}
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">{{ wConfig.title }}</h3>
<h3 class="widget-title">{{ wConfig.title }}</h3>
{% endif %}
{% if wConfig.content %}
<div class="prose dark:prose-invert prose-sm max-w-none">

View File

@@ -29,8 +29,8 @@
{% elif widget.type == "recent-comments" %}
{% include "components/widgets/recent-comments.njk" %}
{% elif widget.type == "search" %}
<div class="sidebar-widget">
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">Search</h3>
<div class="widget">
<h3 class="widget-title">Search</h3>
<div id="listing-sidebar-search"></div>
<script>initPagefind("#listing-sidebar-search");</script>
</div>
@@ -38,9 +38,9 @@
{% include "components/widgets/webmentions.njk" %}
{% elif widget.type == "custom-html" %}
{% set wConfig = widget.config or {} %}
<div class="sidebar-widget">
<div class="widget">
{% if wConfig.title %}
<h3 class="text-sm font-semibold text-surface-600 dark:text-surface-400 uppercase tracking-wide mb-3">{{ wConfig.title }}</h3>
<h3 class="widget-title">{{ wConfig.title }}</h3>
{% endif %}
{% if wConfig.content %}
<div class="prose dark:prose-invert prose-sm max-w-none">