Replace component includes with new custom elements for consistency

Replaces Django template includes with custom HTML elements like `<c-button>` and `<c-auth_modal>` across various templates, ensuring consistent component usage and improving maintainability. This change also includes updates to URL routing for component testing compatibility and a visual regression report confirming no design changes.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: dcfff319-6e91-4220-98a9-8295b87755b7
Replit-Commit-Checkpoint-Type: intermediate_checkpoint
This commit is contained in:
pac7
2025-09-21 17:37:11 +00:00
committed by pacnpal
parent 3f0588f947
commit ac1ec18bb8
12 changed files with 384 additions and 55 deletions

View File

@@ -149,7 +149,7 @@ Includes: Browse menu, advanced search, theme toggle, user dropdown, mobile menu
hx-include="this"
name="q"
/>
{% include 'components/ui/button.html' with variant='default' size='sm' text='Search' class='absolute right-1 top-1/2 transform -translate-y-1/2' %}
<c-button variant="default" size="sm" class="absolute right-1 top-1/2 transform -translate-y-1/2">Search</c-button>
</div>
<!-- Search Results Dropdown -->
@@ -315,7 +315,7 @@ Includes: Browse menu, advanced search, theme toggle, user dropdown, mobile menu
hx-swap="beforeend"
class="cursor-pointer"
>
{% include 'components/ui/button.html' with variant='outline' size='default' text='Login' %}
<c-button variant="outline" size="default">Login</c-button>
</div>
<div
hx-get="{% url 'account_signup' %}"
@@ -323,7 +323,7 @@ Includes: Browse menu, advanced search, theme toggle, user dropdown, mobile menu
hx-swap="beforeend"
class="cursor-pointer"
>
{% include 'components/ui/button.html' with variant='default' size='default' text='Join' %}
<c-button variant="default" size="default">Join</c-button>
</div>
</div>
{% endif %}

View File

@@ -1,6 +1,6 @@
{% comment %}
Button Component - Django Template Version of shadcn/ui Button
Usage: {% include 'components/ui/button.html' with variant='default' size='default' text='Click me' %}
Usage: <c-button variant="default" size="default">Click me</c-button>
{% endcomment %}
{% load static %}

View File

@@ -1,6 +1,6 @@
{% comment %}
Card Component - Django Template Version of shadcn/ui Card
Usage: {% include 'components/ui/card.html' with title='Card Title' content='Card content' %}
Usage: <c-card title="Card Title" content="Card content" />
{% endcomment %}
<div class="rounded-lg border bg-card text-card-foreground shadow-sm {{ class|default:'' }}">

View File

@@ -1,6 +1,6 @@
{% comment %}
Input Component - Django Template Version of shadcn/ui Input
Usage: {% include 'components/ui/input.html' with type='text' placeholder='Enter text...' name='field_name' %}
Usage: <c-input type="text" placeholder="Enter text..." name="field_name" />
{% endcomment %}
<input