Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UI/icons consistent #99

Merged
merged 19 commits into from
Feb 12, 2025
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 21 additions & 12 deletions home/templates/components/search_bar.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,24 @@
<!DOCTYPE html>
<html lang="en">
<form method="get" action="{{ search_url }}" class="d-flex gap-2">
{% for key, value in current_params.items %}
{% if key != 'q' and key != 'page' %}
<input type="hidden" name="{{ key }}" value="{{ value }}">
{% endif %}
{% endfor %}
{{ search_form.q }}
<button type="submit" class="btn btn-primary">Search</button>
{% if current_search %}
<a href="{{ search_url }}" class="btn btn-outline-secondary">Clear</a>
{% endif %}
</form>
<form method="get" action="{{ search_url }}" class="d-flex gap-2">
{% for key, value in current_params.items %}
{% if key != 'q' and key != 'page' %}
<input type="hidden" name="{{ key }}" value="{{ value }}">
{% endif %}
{% endfor %}
{{ search_form.q }}
<!-- <div class="w-100"> -->
<button type="submit" class="btn btn-primary">
<!-- <i class="bx bxs-search" alt=""></i> -->
Search
</button>

{% if current_search %}
<a href="{{ search_url }}" class="btn btn-outline-secondary">
<!-- <i class="bx bxs-undo" alt=""></i> -->
Clear</a>
{% endif %}
<!-- </div> -->
</form>

</html>
2 changes: 1 addition & 1 deletion home/templates/home/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ <h1>Profile</h1>

<div class="text-center">
<button type="submit" class="btn btn-primary" style="background-color: #6933AD; border: none;">
Update Profile
<i class="bx bxs-user-check" alt=""></i> Update Profile
</button>
<!-- <a href="{% url 'home' %}" class="btn btn-primary" style="background-color: #6933AD; border: none; margin-left: 10px;">
Cancel
Expand Down
8 changes: 4 additions & 4 deletions home/templates/organisation/organisation.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<nav aria-label="breadcrumb">
<ol class="breadcrumb mb-0">
<li class="breadcrumb-item active" aria-current="page">
<i class="bx bxs-buildings"></i> My Organisation
<i class="bx bxs-buildings" alt=""></i> My Organisation
</li>
</ol>
</nav>
Expand All @@ -26,7 +26,7 @@ <h2 class="text-2xl font-bold d-inline-block">Projects</h2>
{% if can_create %}
<a href="{% url 'project_create' organisation.id %}">
<button type="button" class="btn btn-primary">
<i class="bx bxs-folder-plus align-middle"></i> Create project
<i class="bx bxs-folder-plus" alt=""></i> Create project
</button>
</a>
{% endif %}
Expand All @@ -46,13 +46,13 @@ <h2 class="text-2xl font-bold d-inline-block">Projects</h2>
{% if can_edit|get_item:project.id %}
<a href="{% url 'project-edit' project.id %}">
<button type="button" class="btn btn-light">
<i class="bx bxs-edit"></i> Edit
<i class="bx bxs-edit" alt=""></i> Edit
</button>
</a>
{% endif %}
<a href="{% url 'project' project.id %}">
<button type="button" class="btn btn-dark">
<i class="bx bxs-folder-open"></i> View
<i class="bx bxs-folder-open" alt=""></i> View
</button>
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion home/templates/projects/create.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ <h1>Create Project</h1>
{% endfor %}
<div class="text-center">
<button type="submit" class="btn btn-primary" style="background-color: #6933AD; border: none;">
Create Project
<i class="bx bxs-folder-plus" alt=""></i> Create Project
</button>
</div>
</form>
Expand Down
10 changes: 5 additions & 5 deletions home/templates/projects/project.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
<nav aria-label="breadcrumb">
<ol class="breadcrumb mb-0">
<li class="breadcrumb-item" aria-current="page">
<i class="bx bxs-buildings"></i> <a href="{% url 'myorganisation' %}">My Organisation</a>
<i class="bx bxs-buildings" alt=""></i> <a href="{% url 'myorganisation' %}">My Organisation</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
<i class="bx bxs-folder-open"></i> Project: {{ project.name }}
<i class="bx bxs-folder-open" alt=""></i> Project: {{ project.name }}
</li>
</ol>
</nav>
Expand All @@ -24,9 +24,9 @@ <h1>{{ project.name }}</h1>
<div class="w-100 d-flex justify-content-between align-items-center mt-3 mb-6">
<h2 class="text-2xl font-bold d-inline-block">Surveys</h2>
{% if can_create %}
<a href="{% url "survey_create" project.id %}">
<a href="{% url 'survey_create' project.id %}">
<button type="button" class="btn btn-primary">
<i class="bx bx-chart align-middle"></i> Create survey
<i class="bx bx-chart" alt=""></i> Create survey
</button>
</a>
{% endif %}
Expand All @@ -42,7 +42,7 @@ <h3 class="card-title">{{ survey.name }}</h3>
<div class="mt-2 w-100 d-flex flex-wrap justify-content-end gap-2">
<a href="{% url 'survey' survey.id %}">
<button type="button" class="btn btn-dark">
<i class="bx bxs-chart align-middle"></i> View
<i class="bx bxs-chart" alt=""></i> View
</button>
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion static/css/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -112,4 +112,4 @@ h1, h2, h3, h4, h5, h6 {

.form-control {
padding: 0.375rem 0.75rem;
}
}
10 changes: 5 additions & 5 deletions static/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
<li class="nav-item">
<a class="nav-link {% if request.path == invite_url %}active{% endif %}" href="{{ home_url }}">Home</a>
<a class="nav-link {% if request.path == '/' %}active{% endif %}" href="{{ home_url }}"><i class="bx bxs-home" alt=""></i>Home</a>
</li>
<li class="nav-item">
<a class="nav-link {% if '/invite' in request.path %}active{% endif %}" href="{% url 'invite' %}">Manage</a>
<a class="nav-link {% if '/invite' in request.path %}active{% endif %}" href="{% url 'invite' %}"><i class="bx bxs-cog" alt=""></i>Manage</a>
</li>
<li class="nav-item">
<a class="nav-link {% if '/profile' in request.path %}active{% endif %}" href="{% url 'profile' %}">Profile</a>
<a class="nav-link {% if '/profile' in request.path %}active{% endif %}" href="{% url 'profile' %}"><i class="bx bxs-user" alt=""></i>Profile</a>
</li>
<li class="nav-item">
{% url 'organisation_create' as organisation_create_url %}
Expand All @@ -48,7 +48,7 @@
{% if '/projects' in request.path %}active{% endif %}
{% if '/survey' in request.path %}active{% endif %}
{% if '/completion' in request.path %}active{% endif %}"
href="{% url 'myorganisation' %}">My Organisation</a>
href="{% url 'myorganisation' %}"><i class="bx bxs-buildings" alt=""></i>My Organisation</a>
</li>
{% if user.is_authenticated %}
<li class="nav-item">
Expand All @@ -57,7 +57,7 @@
method="POST"
style="display: inline">
{% csrf_token %}
<button type="submit" class="nav-link btn btn-link">Logout</button>
<button type="submit" class="nav-link btn btn-link btn-primary">Logout</button>
</form>
</li>
{% endif %}
Expand Down
2 changes: 1 addition & 1 deletion survey/templates/invitations/send_invitation.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ <h1>Invitations</h1>
</div>

<div class="text-center">
<button type="submit" class="btn btn-primary" style="background-color: #6933AD; border: none;">Send</button>
<button type="submit" class="btn btn-primary" style="background-color: #6933AD; border: none;"><i class="bx bxs-send" alt=""></i> Send</button>
</div>
</form>
</div>
Expand Down
2 changes: 1 addition & 1 deletion survey/templates/survey/create.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ <h1>Create Survey</h1>
{% endfor %}
<div class="text-center">
<button type="submit" class="btn btn-primary" style="background-color: #6933AD; border: none;">
Create Survey
<i class="bx bx-chart" alt=""></i> Create Survey
</button>
</div>
</form>
Expand Down
10 changes: 5 additions & 5 deletions survey/templates/survey/survey.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
<nav aria-label="breadcrumb">
<ol class="breadcrumb">
<li class="breadcrumb-item" aria-current="page">
<i class="bx bxs-buildings"></i> <a href="{% url 'myorganisation' %}">My Organisation</a>
<i class="bx bxs-buildings" alt=""></i> <a href="{% url 'myorganisation' %}">My Organisation</a>
</li>
<li class="breadcrumb-item" aria-current="page">
<i class="bx bxs-folder-open"></i> <a
<i class="bx bxs-folder-open" alt=""></i> <a
href="{% url 'project' survey.project.id %}">Project: {{ survey.project.name }}</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
<i class="bx bxs-chart"></i> Survey: {{ survey.name }}
<i class="bx bxs-chart" alt=""></i> Survey: {{ survey.name }}
</li>
</ol>
</nav>
Expand All @@ -27,15 +27,15 @@ <h2>Configure your survey and invite participants</h2>
<div class="mb-3 mt-3">
<p>First, configure you survey here. You are able to add and customise demographic questions asked
in the survey.</p>
<a href="{% url "survey_configure" survey.id %}" class="btn btn-primary">Configure the survey</a>
<a href="{% url 'survey_configure' survey.id %}" class="btn btn-primary"><i class="bx bxs-cog" alt=""></i> Configure the survey</a>
</div>

<div class="mb-3 mt-3">
<h3>Invite your participants</h3>
<p>Invite your participants using the follow link</p>
<ul>
<li>
<a href="{% url "invite" %}">Send an invitation</a>
<a href="{% url 'invite' %}">Send an invitation</a>
</li>
<li>
Link to fill in survey <a
Expand Down
2 changes: 1 addition & 1 deletion survey/templates/survey/survey_configure.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<i class="bx bxs-chart"></i> <a href="{% url 'survey' survey.id %}"> Survey: {{ survey.name }}</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
<i class="bx bxs-chart"></i> Configuration
<i class="bx bxs-cog"></i> Configuration
</li>
</ol>
</nav>
Expand Down