feat: navbar new css

This commit is contained in:
2025-05-29 00:02:09 +02:00
parent 9d6ef9f5ff
commit 68d717aab8

View File

@@ -1,73 +1,37 @@
{% load static %} {% load static %}
<!DOCTYPE html> <!DOCTYPE html>
<html lang="de"> <html lang="de">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<title>{% block title %}TicketSystem{% endblock %}</title> <title>
<link href="{% static 'css/tailwind.css' %}" rel="stylesheet"> {% block title %}TicketSystem{% endblock %}
<style> </title>
body { <link href="{% static 'css/tailwind.css' %}" rel="stylesheet">
margin: 0; </head>
font-family: sans-serif; <body class="bg-gray-100">
background-color: #f8f9fa; <nav class="bg-gray-700 text-white py-4">
} <div class="max-w-4xl mx-auto flex justify-between items-center px-4">
<div class="flex space-x-4">
.navbar { <a href="{% url 'home' %}" class="text-white hover:text-gray-300">🏠 Start</a>
background-color: #343a40; <a href="{% url 'ticket-list' %}" class="text-white hover:text-gray-300">📋 Tickets</a>
color: white; <a href="{% url 'assigned-tickets' %}"
padding: 1rem 0; class="text-white hover:text-gray-300">🧾 Meine Tickets</a>
} </div>
<div class="flex items-center space-x-4">
.navbar-container { {% if user.is_authenticated %}
max-width: 700px; <span class="text-white">👤 {{ user.username }}</span>
margin: 0 auto; <form method="post" action="{% url 'logout' %}" class="inline">
display: flex; {% csrf_token %}
justify-content: space-between; <button type="submit" class="text-white hover:text-gray-300">🚪 Logout</button>
align-items: flex-start; </form>
} {% endif %}
</div>
.navbar a { </div>
color: white; </nav>
text-decoration: none; <!-- Global Container -->
margin: 0 1rem; <div class="max-w-4xl mx-auto mt-8 px-4">
} {% block content %}
{% endblock %}
.navbar-right form { </div>
display: inline; </body>
}
.navbar-right button {
background: none;
border: none;
color: white;
cursor: pointer;
font-size: 1rem;
}
</style>
</head>
<body>
<div class="navbar">
<div class="navbar-container">
<div class="navbar-left">
<a href="{% url 'home' %}">🏠 Start</a>
<a href="{% url 'ticket-list' %}">📋 Tickets</a>
<a href="{% url 'assigned-tickets' %}">🧾 Meine Tickets</a>
</div>
<div class="navbar-right">
{% if user.is_authenticated %}
👤 {{ user.username }}
<form method="post" action="{% url 'logout' %}">
{% csrf_token %}
<button type="submit">🚪 Logout</button>
</form>
{% endif %}
</div>
</div>
</div>
<div class="container" style="max-width: 900px; margin: 2rem auto;">
{% block content %}
{% endblock %}
</div>
</body>
</html> </html>