Fixed some front-end visuals

This commit is contained in:
teras 2018-01-31 17:52:23 +02:00 committed by Lauri Võsandi
parent dbaeb3205e
commit 84fba4961f
6 changed files with 50 additions and 27 deletions

View File

@ -23,16 +23,15 @@ footer, .map {
margin-top: 30px; margin-top: 30px;
} }
a:link, a:visited { .lightlink:link, .lightlink:visited {
color: white; color: white;
} }
a:hover { .lightlink:hover {
color: #34495e; color: #34495e;
} }
.lightlink:active {
a:active {
color: black; color: black;
} }
@ -45,10 +44,34 @@ ul {
width:300px; width:300px;
} }
.card-image.img {
display: block;
max-height: 300px;
max-width: 300px;
height: auto;
width: auto;
}
.card .inventory .card-content {
max-height: 100px;
}
.card.small { .card.small {
height: auto; height: auto;
} }
a:link, a:visited {
color: #3498db;
}
a:hover {
color: #34495e;
}
a:active, a.highlight:hover {
color: black;
}
.darklink:link, .darklink:visited { .darklink:link, .darklink:visited {
color: black; color: black;
} }
@ -57,10 +80,6 @@ ul {
color: #34495e; color: #34495e;
} }
.darklink:active { .darklink:active, .darklink.highlight:hover {
color: #3498db; color: #3498db;
} }
a.highlight:hover{
color: #3498db;
}

View File

@ -4,7 +4,7 @@
{% extends 'base_footer.html' %} {% extends 'base_footer.html' %}
{% block base_footer %} {% block base_footer %}
<div class="header section center-align"> <div class="header section center-align">
<h1 class="section darken-2 z-depth-1 white-text"><a href="/">k-space.ee</a></h1> <h1 class="section darken-2 z-depth-1 white-text"><a href="/" class="lightlink">k-space.ee</a></h1>
</div> </div>
{% block content %} {% block content %}

View File

@ -23,9 +23,8 @@
</div> </div>
</div> </div>
<div class="card-action"> <div class="card-action">
<a href="/challenge/{{ challenge.id }}" class="btn-large">I can do it</a> <a href="/challenge/{{ challenge.id }}" class="btn-large lightlink">I can do it</a>
</div> </div>
</div> </div>

View File

@ -8,6 +8,7 @@
<div class="row container section"> <div class="row container section">
{% for user in users %} {% for user in users %}
{% if user.first_name or user.last_name %}
<div class="col s12 m4"> <div class="col s12 m4">
<div class="section center-align"> <div class="section center-align">
<div class="card"> <div class="card">
@ -15,8 +16,8 @@
<div class="card-image"> <div class="card-image">
<a href="/profile/{{ user.username }}"><img src='/media/{{ user.profile.icon }}'></a> <a href="/profile/{{ user.username }}"><img src='/media/{{ user.profile.icon }}'></a>
</div> </div>
<h5 class="card-title" style="padding-top: 10px;color:black;"><a class='darklink' <h5 class="card-title" style="padding-top: 10px;color:black;">
href="/profile/{{ user.username }}"><b>{{ user.first_name }} {{ user.last_name }}</b></a> <a class='darklink' href="/profile/{{ user.username }}"><b>{{ user.first_name }} {{ user.last_name }}</b></a>
</h5> </h5>
<div class="row"> <div class="row">
<div class="col s12 m1"> <div class="col s12 m1">
@ -43,6 +44,7 @@
</div> </div>
</div> </div>
</div> </div>
{% endif %}
{% endfor %} {% endfor %}
</div> </div>
{% endblock %} {% endblock %}

View File

@ -13,18 +13,17 @@
<div class="col s12 m3"> <div class="col s12 m3">
<div class="card"> <div class="card">
<div class="card-content"> <div class="card-content">
<div class="card-image"> <div class="card-image">
{% if item.photo %} {% if item.photo %}
<img src='/media/{{ item.photo }}'> <img src='/media/{{ item.photo }}'>
{% else %} {% else %}
<img src='/media/missing_photo.png'> <img src='/media/missing_photo.png'>
{% endif %} {% endif %}
</div> </div>
<div class="card-title"><b>{{ item.item_name }}</b></div>
<p>Serial: {{ item.serial_nr }}</p>
<p style="text-align: justify; max-height: 120px; overflow: auto;">{{ item.description }}</p>
<div class="card-title"><b>{{ item.item_name }}</b></div>
<p>Serial: {{ item.serial_nr }}</p>
<p style="text-align: justify; max-height: 120px; overflow: auto;">{{ item.description }}</p>
</div> </div>
</div> </div>
</div> </div>

View File

@ -2,7 +2,11 @@
{% block content %} {% block content %}
<div class="row container section"> <div class="row container section">
<div class="col s12 m12 l12"> <div class="col s12 m12 l12">
<h2 class="header center-align">{{ user.username }}</h2> {% if user.first_name or user.last_name %}
<h2 class="header center-align">{{ user.first_name }} {{ user.last_name }}</h2>
{% else %}
<h2 class="header center-align">{{ user.username }}</h2>
{% endif %}
<div class="card horizontal" style="width:100%;"> <div class="card horizontal" style="width:100%;">
<div class="card-image"> <div class="card-image">
<img src="/media/{{ user.profile.icon }}"> <img src="/media/{{ user.profile.icon }}">