mirror of
https://github.com/ae-utbm/sith.git
synced 2025-01-10 09:01:14 +00:00
Merge pull request #993 from ae-utbm/elections
Quick fix for election display
This commit is contained in:
commit
4226ba88ae
@ -15,8 +15,8 @@ $min_col_width: 100px;
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
gap: $gap;
|
gap: $gap;
|
||||||
|
|
||||||
> input,
|
>input,
|
||||||
> label {
|
>label {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -25,12 +25,12 @@ $min_col_width: 100px;
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.election_vote {
|
#page #content {
|
||||||
overflow-x: scroll !important;
|
overflow-x: clip;
|
||||||
}
|
}
|
||||||
|
|
||||||
.election_table {
|
.election_table {
|
||||||
width: 100%;
|
width: inherit;
|
||||||
|
|
||||||
>.lists {
|
>.lists {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -93,16 +93,24 @@ $min_col_width: 100px;
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
row-gap: 10px;
|
||||||
padding: $padding;
|
padding: $padding;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
||||||
|
|
||||||
>.role_text {
|
>.role_text {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
|
||||||
>h4 {
|
>h4 {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
>p {
|
>p {
|
||||||
|
flex-grow: 1;
|
||||||
margin-top: .5em;
|
margin-top: .5em;
|
||||||
|
text-wrap: auto;
|
||||||
|
text-align: left;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -112,9 +120,9 @@ $min_col_width: 100px;
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
gap: $gap;
|
gap: $gap;
|
||||||
|
|
||||||
> button,
|
>button,
|
||||||
> button > i,
|
>button>i,
|
||||||
> a {
|
>a {
|
||||||
width: 20px;
|
width: 20px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
background-color: #e9e9e9;
|
background-color: #e9e9e9;
|
||||||
@ -127,23 +135,23 @@ $min_col_width: 100px;
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
||||||
&:hover,
|
&:hover,
|
||||||
&:hover > i {
|
&:hover>i {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
> button {
|
>button {
|
||||||
width: 30px;
|
width: 30px;
|
||||||
height: 30px;
|
height: 30px;
|
||||||
}
|
}
|
||||||
|
|
||||||
> button[disabled] {
|
>button[disabled] {
|
||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
cursor: not-allowed;
|
cursor: not-allowed;
|
||||||
|
|
||||||
>i,
|
>i,
|
||||||
&:hover,
|
&:hover,
|
||||||
&:hover > i {
|
&:hover>i {
|
||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -178,12 +186,12 @@ $min_col_width: 100px;
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
gap: $gap;
|
gap: $gap;
|
||||||
|
|
||||||
>input[type="radio"]:checked + label,
|
>input[type="radio"]:checked+label,
|
||||||
>input[type="checkbox"]:checked + label {
|
>input[type="checkbox"]:checked+label {
|
||||||
background-color: lightgray;
|
background-color: lightgray;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
|
|
||||||
>figure>.edit_btns>a:hover{
|
>figure>.edit_btns>a:hover {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -215,7 +223,9 @@ $min_col_width: 100px;
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.candidate_program {
|
.candidate_program {
|
||||||
|
text-wrap: auto;
|
||||||
margin: 5px 0;
|
margin: 5px 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -228,7 +238,7 @@ $min_col_width: 100px;
|
|||||||
right: $gap;
|
right: $gap;
|
||||||
gap: $gap;
|
gap: $gap;
|
||||||
|
|
||||||
> a {
|
>a {
|
||||||
width: 20px;
|
width: 20px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
background-color: #e9e9e9;
|
background-color: #e9e9e9;
|
||||||
@ -253,20 +263,22 @@ $min_col_width: 100px;
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.election_details {
|
#content {
|
||||||
margin: .5em 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.buttons {
|
.election_details {
|
||||||
|
margin: .5em 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.buttons {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: $gap;
|
gap: $gap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button {
|
.button {
|
||||||
border: none;
|
border: none;
|
||||||
color: black;
|
color: black;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
@ -285,8 +297,10 @@ $min_col_width: 100px;
|
|||||||
|
|
||||||
&_send {
|
&_send {
|
||||||
background-color: #59aee2;
|
background-color: #59aee2;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: rgb(130, 186, 235);
|
background-color: rgb(130, 186, 235);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
@ -4,12 +4,11 @@
|
|||||||
{{ object.title }}
|
{{ object.title }}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block head %}
|
|
||||||
{{ super() -}}
|
|
||||||
<link rel="stylesheet" href="{{ static('election/css/election.scss') }}">
|
|
||||||
{%- endblock %}
|
|
||||||
|
|
||||||
{% block additional_css %}
|
{% block additional_css %}
|
||||||
|
<link rel="stylesheet" href="{{ static('election/css/election.scss') }}">
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
|
{% block additional_js %}
|
||||||
<script src="{{ static('bundled/vendored/jquery.shorten.min.js') }}"></script>
|
<script src="{{ static('bundled/vendored/jquery.shorten.min.js') }}"></script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
@ -47,7 +46,6 @@
|
|||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<table class="election_table">
|
<table class="election_table">
|
||||||
{%- set election_lists = election.election_lists.all() -%}
|
{%- set election_lists = election.election_lists.all() -%}
|
||||||
<caption></caption>
|
|
||||||
<thead class="lists">
|
<thead class="lists">
|
||||||
<tr>
|
<tr>
|
||||||
<th class="column" style="width: {{ 100 / (election_lists.count() + 1) }}%">{% trans %}Blank vote{% endtrans %}</th>
|
<th class="column" style="width: {{ 100 / (election_lists.count() + 1) }}%">{% trans %}Blank vote{% endtrans %}</th>
|
||||||
@ -204,7 +202,7 @@
|
|||||||
$('.role_description').shorten({
|
$('.role_description').shorten({
|
||||||
moreText: "{% trans %}Show more{% endtrans %}",
|
moreText: "{% trans %}Show more{% endtrans %}",
|
||||||
lessText: "{% trans %}Show less{% endtrans %}",
|
lessText: "{% trans %}Show less{% endtrans %}",
|
||||||
showChars: 50
|
showChars: 300
|
||||||
});
|
});
|
||||||
$('.candidate_program').shorten({
|
$('.candidate_program').shorten({
|
||||||
moreText: "{% trans %}Show more{% endtrans %}",
|
moreText: "{% trans %}Show more{% endtrans %}",
|
||||||
|
Loading…
Reference in New Issue
Block a user