style: Light theme finished

This commit is contained in:
2025-06-10 20:44:09 +00:00
parent 38c840251f
commit c433316742
7 changed files with 63 additions and 53 deletions
+9 -9
View File
@@ -14,25 +14,25 @@
<div class="container py-8 max-w-6xl pt-20">
<h1 class="text-3xl font-bold mb-6 text-center">Audit Log</h1>
<form method="GET" class="flex flex-wrap gap-4 mb-6 justify-center">
<select name="user_id" class="border p-2 rounded-lg bg-gray-800 text-gray-100 border-gray-600">
<select name="user_id" class="border p-2 rounded-lg bg-gray-300 dark:bg-gray-900 border-gray-600">
<option value="">All Users</option>
{% for user in users %}
<option value="{{ user[0] }}" {% if request.args.get('user_id') == user[0]|string %}selected{% endif %}>{{ user[1] }}</option>
{% endfor %}
</select>
<select name="subnet_id" class="border p-2 rounded-lg bg-gray-800 text-gray-100 border-gray-600">
<select name="subnet_id" class="border p-2 rounded-lg bg-gray-300 dark:bg-gray-900 border-gray-600">
<option value="">All Subnets</option>
{% for subnet in subnets %}
<option value="{{ subnet[0] }}" {% if request.args.get('subnet_id') == subnet[0]|string %}selected{% endif %}>{{ subnet[1] }}</option>
{% endfor %}
</select>
<select name="action" class="border p-2 rounded-lg bg-gray-800 text-gray-100 border-gray-600">
<select name="action" class="border p-2 rounded-lg bg-gray-300 dark:bg-gray-900 border-gray-600">
<option value="">All Actions</option>
{% for a in actions %}
<option value="{{ a }}" {% if request.args.get('action') == a %}selected{% endif %}>{{ a }}</option>
{% endfor %}
</select>
<select name="device_name" class="border p-2 rounded-lg bg-gray-800 text-gray-100 border-gray-600">
<select name="device_name" class="border p-2 rounded-lg bg-gray-300 dark:bg-gray-900 border-gray-600">
<option value="">All Devices</option>
{% for device in devices %}
<option value="{{ device[0] }}" {% if request.args.get('device_name') == device[0] %}selected{% endif %}>{{ device[0] }}</option>
@@ -40,9 +40,9 @@
</select>
<button type="submit" class="bg-gradient-to-r from-gray-200 to-gray-200 dark:from-gray-500 dark:to-gray-700 px-4 py-2 rounded-lg">Filter</button>
</form>
<table class="w-full table-auto bg-gray-800 rounded-lg overflow-hidden">
<table class="w-full table-auto bg-gray-200 dark:bg-gray-800 rounded-lg overflow-hidden">
<thead>
<tr class="bg-gray-700">
<tr class="bg-gray-400 dark:bg-gray-700">
<th class="px-4 py-2 text-center">User</th>
<th class="px-4 py-2 text-center">Action</th>
<th class="px-4 py-2 text-center">Details</th>
@@ -67,7 +67,7 @@
{% if page > 1 %}
{% set prev_args = query_args.copy() %}
{% set _ = prev_args.update({'page': page-1}) %}
<a href="{{ url_for('audit', **prev_args) }}" class="px-3 py-1 rounded bg-gray-700 hover:bg-gray-600 flex items-center gap-2">
<a href="{{ url_for('audit', **prev_args) }}" class="px-3 py-1 rounded bg-gray-400 dark:bg-gray-700 flex items-center gap-2">
<i class="fa fa-angle-left"></i>
<span class="hidden sm:inline">Prev</span>
</a>
@@ -75,12 +75,12 @@
{% for p in range(1, total_pages+1) %}
{% set page_args = query_args.copy() %}
{% set _ = page_args.update({'page': p}) %}
<a href="{{ url_for('audit', **page_args) }}" class="px-3 py-1 rounded {{ 'bg-gray-500 text-white' if p == page else 'bg-gray-700 hover:bg-gray-600' }}">{{ p }}</a>
<a href="{{ url_for('audit', **page_args) }}" class="px-3 py-1 rounded {{ 'bg-gray-200 dark:bg-gray-500' if p == page else 'bg-gray-400 dark:bg-gray-700' }}">{{ p }}</a>
{% endfor %}
{% if page < total_pages %}
{% set next_args = query_args.copy() %}
{% set _ = next_args.update({'page': page+1}) %}
<a href="{{ url_for('audit', **next_args) }}" class="px-3 py-1 rounded bg-gray-700 hover:bg-gray-600 flex items-center gap-2">
<a href="{{ url_for('audit', **next_args) }}" class="px-3 py-1 rounded bg-gray-400 dark:bg-gray-700 flex items-center gap-2">
<span class="hidden sm:inline">Next</span>
<i class="fa fa-angle-right"></i>
</a>