Skip to content

Commit f250287

Browse files
committed
Merge branch 'main' into 429-pr
2 parents 61137ad + 19635e3 commit f250287

19 files changed

Lines changed: 122 additions & 33 deletions

File tree

apps/about/static/about/css/allies.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
.ally-block {
22
margin-bottom: 3rem;
3+
padding-top: 2rem;
34
img.logo {
45
width: 5rem;
56
vertical-align: middle;

apps/about/templates/about/allies.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,11 @@ <h1>Aliados</h1>
1414
Canarias es un territorio muy prolífico en el campo de las nuevas tecnologías. Las organizaciones y asociaciones de este sector constituyen un punto de entrada para muchos usuarios y usuarias. Aquello de que la unión hace la fuerza es un principio que seguimos desde Python Canarias. Si bien apostamos, como era de esperar, por nuestro lenguaje de programación favorito, somos una comunidad abierta y nos encanta construir sinergias con otros grupos. Aquí les dejamos un listado de nuestros <b>aliados</b>:
1515
</p>
1616

17+
1718
{% for ally in allies %}
18-
<div class="ally-block" id="{{ ally.name|slugify }}">
19+
<div class="ally-block anchor" id="{{ ally.name|slugify }}">
1920
<h2 class="dyn-anchor-heading">
20-
<img class="logo" src="{{ ally.logo.url }}"> {{ ally.name }}
21+
<img class="logo" src="{{ ally.logo.url }}"> {{ ally.name }}
2122
<a class="dyn-anchor-link" href="#{{ ally.name|slugify }}"><i class="fas fa-link"></i></a>
2223
</h2>
2324
<p class="description"><i class="fas fa-quote-left quote"></i> {{ ally.description }} <i class="fas fa-quote-right quote"></i></p>

apps/about/templates/about/join.html

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
{% block content %}
88

99
<div class="content box">
10+
<div id="join" class="section anchor">
1011

11-
<a id="join"></a>
12-
<h1 class="dyn-anchor-heading">
12+
<h1 class="dyn-anchor-heading" >
1313
No nos mires, ¡únete! <i class="fas fa-people-carry"></i>
1414
<a class="dyn-anchor-link" href="#join"><i class="fas fa-link"></i></a>
1515
</h1>
@@ -31,8 +31,9 @@ <h1 class="dyn-anchor-heading">
3131
<p>Si ya eres socio/a, pulsa en el siguiente botón para aceder:</p>
3232
<a class="button is-link" href="{% url 'members:login' %}">Acceso para socios/as</a>
3333

34-
<a id="fee"></a>
35-
<h2 class="dyn-anchor-heading">
34+
</div>
35+
<div id="fee" class="section anchor">
36+
<h2 class="dyn-anchor-heading ">
3637
Cuota
3738
<a class="dyn-anchor-link" href="#fee"><i class="fas fa-link"></i></a>
3839
</h2>
@@ -42,9 +43,9 @@ <h2 class="dyn-anchor-heading">
4243
<li><span class="tag is-info is-medium">20€</span> Importe general.</li>
4344
<li><span class="tag is-primary is-medium">10€</span> Estudiantes y/o personas desempleadas.</li>
4445
</ul>
45-
46-
<a id="method"></a>
47-
<h2 class="dyn-anchor-heading">
46+
</div>
47+
<div id="method" class="section anchor">
48+
<h2 class="dyn-anchor-heading ">
4849
Procedimiento para convertirse/renovar como socio/socia
4950
<a class="dyn-anchor-link" href="#method"><i class="fas fa-link"></i></a>
5051
</h2>
@@ -84,7 +85,7 @@ <h2 class="dyn-anchor-heading">
8485
<br>
8586
<i class="fas fa-bell"></i> En caso de renovar, no es necesario indicar nickname, teléfono y dirección, salvo para actualizar datos.
8687
</p>
87-
88+
</div>
8889
</div>
8990

9091
{% endblock content %}

apps/api/urls.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,6 @@
2424
path('v1/events/<slug>/', views.detail_event, name='detail_event'),
2525
path('v1/events/all/', views.all_events, name='all_events'),
2626
path('v1/events/', views.active_events, name='active_events'),
27+
# Quotes
28+
path('v1/quotes/', views.random_quote, name='random_quote'),
2729
]

apps/api/views.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
from apps.events.models import Event
1212
from apps.locations.models import Venue
1313
from apps.members.models import Position
14+
from apps.quotes.models import Quote
1415

1516
# API decorator
1617

@@ -139,6 +140,12 @@ def serializer_staff(position):
139140
}
140141

141142

143+
def serialize_quote(quote):
144+
return {
145+
'text': quote.text,
146+
'author': quote.author.name + ' ' + quote.author.surname,
147+
}
148+
142149
@api
143150
def status(request):
144151
return {
@@ -242,6 +249,13 @@ def list_sponsors(request, slug):
242249
sponsors = event.memberships.all().order_by('category__role__order')
243250
return [serializer_sponsor(sponsor) for sponsor in sponsors]
244251

252+
@api
253+
def random_quote(request):
254+
"""Return random quote
255+
"""
256+
quote = Quote.get_random_quote()
257+
return serialize_quote(quote)
258+
245259
# TODO
246260
@api
247261
def list_tags(request, slug):

apps/commons/static/commons/css/base.scss

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,24 @@ body {
2626
.header-page {
2727
box-shadow: 0 1px 6px rgba(0, 0, 0, 0.04);
2828
background-color: $header-bg;
29+
z-index: 99;
2930
}
3031

3132
.content-page {
3233
max-width: 59rem;
3334
min-height: calc(100vh - #{$navbar-height} - #{$footer-height} + 1px);
34-
padding: 2rem 0rem 5rem 0rem;
35+
padding: 2rem 1.2rem 5rem 1.2rem;
3536

3637
@include from($custom-mobile) {
3738
& > .box {
3839
padding: 2rem;
3940
}
4041
}
4142

43+
@include from($desktop){
44+
padding: 2rem 0rem 5rem 0rem;
45+
}
46+
4247
&.is-wide {
4348
max-width: 80rem;
4449
}
@@ -48,9 +53,12 @@ body {
4853
}
4954
}
5055

56+
5157
.footer-page {
5258
background-color: $footer-bg;
5359
position: relative;
60+
margin-top: 2em;
61+
padding: 1.5em 1.5em 2.2em 1.5em;
5462

5563
a {
5664
color: $footer-fg;
@@ -63,22 +71,14 @@ body {
6371
.footer-column {
6472
color: #ebebeb;
6573
padding-top: 2rem;
66-
padding-bottom: 0.5rem;
67-
68-
@include from($desktop) {
69-
padding-top: 2rem;
70-
padding-bottom: 3rem;
71-
}
74+
7275
}
7376

7477
h1,
7578
h2 {
7679
color: whitesmoke;
7780
}
7881

79-
i {
80-
padding-right: 0.2rem;
81-
}
8282
}
8383

8484
/* Error class for Django Forms https://bit.ly/3vidyK2 */
@@ -96,6 +96,7 @@ body {
9696
width: 100%;
9797
z-index: 1;
9898

99+
99100
& .notification {
100101
width: $notification-width;
101102
margin-left: auto;
@@ -104,6 +105,9 @@ body {
104105
margin-bottom: 0;
105106
}
106107
}
108+
.message {
109+
scroll-margin-top: $header-height + 1rem;
110+
}
107111

108112
.container {
109113
padding-top: 2rem;

apps/commons/static/commons/css/dyn-anchors.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,6 @@
1313
}
1414
}
1515
}
16+
.anchor {
17+
scroll-margin-top: $header-height + 1rem;
18+
}

apps/commons/static/commons/css/variables.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ $content-heading-weight: 500;
3838
$radius: 0.15rem;
3939
$navbar-height: 4.3rem;
4040

41+
$section-title-margin-bottom: 2.1rem;
42+
4143
$box-radius: $radius;
4244
$box-padding: 1.5rem;
4345
$box-shadow: $default-box-shadow;

apps/commons/templates/footer.html

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{% load utils %}
2-
<footer class="footer-page has-text-centered" style="margin-top: 4em;">
2+
<footer class="footer-page has-text-centered">
33
<a class="footer-button" id="scrollToTopBtn" href=""
44
><img
55
class="footer__button--image"
@@ -8,7 +8,7 @@
88
titile="scroll button up"
99
/></a>
1010
<div class="columns">
11-
<div class="column has-text-weight-light">
11+
<div class="column has-text-weight-light is-one-third-desktop">
1212
<div class="footer-column">
1313
<h2 class="subtitle"><i class="fas fa-award"></i> Créditos</h2>
1414
<ul class="footer-column-items">
@@ -23,7 +23,11 @@ <h2 class="subtitle"><i class="fas fa-award"></i> Créditos</h2>
2323
<div class="footer-column">
2424
<h2 class="subtitle"><i class="fas fa-copyright"></i> {{ organization.name }}</h2>
2525
<ul class="footer-column-items">
26-
<li>{{ organization.full_address }}</li>
26+
<li>{{ organization.address }}</li>
27+
{% if organization.rest_address %}
28+
<li>{{ organization.rest_address }}</li>
29+
{% endif %}
30+
<li>{{ organization.postal_code }}, {{ organization.city }}</li>
2731
<li><a href="mailto:{{ organization.email }}">{{ organization.email }}</a></li>
2832
<li><a href="{% url 'about:index' %}">Sobre la asociación</a></li>
2933
</ul>

apps/dev/fixtures/adalovedev.jpg

38.8 KB
Loading

0 commit comments

Comments
 (0)