radios-comunitarias-jekyll-theme 0.2.0 → 0.3.0rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +69 -18
- data/_config.yml +85 -0
- data/_data/actions.yml +9 -0
- data/_data/activity_pub.yml +8 -0
- data/_data/components.yml +10 -0
- data/_data/en.yml +159 -22
- data/_data/es.yml +159 -21
- data/_data/full_width_components.yml +2 -0
- data/_data/layouts/menu.yml +72 -0
- data/_data/layouts/post.yml +48 -25
- data/_data/layouts/radio.yml +80 -0
- data/_data/layouts/theme.yml +291 -0
- data/_data/manifest.json +1340 -0
- data/_data/theme.yml +142 -0
- data/_includes/activity_pub/actor.html +11 -0
- data/_includes/activity_pub/actor_mention.html +28 -0
- data/_includes/activity_pub/button.html +22 -0
- data/_includes/activity_pub/button_bar.html +16 -0
- data/_includes/activity_pub/cards.html +28 -0
- data/_includes/activity_pub/fediverse_interactions.html +2 -0
- data/_includes/activity_pub/generic_modal.html +55 -0
- data/_includes/activity_pub/image_modal.html +27 -0
- data/_includes/activity_pub/interactions.html +78 -0
- data/_includes/activity_pub/login_modal.html +70 -0
- data/_includes/activity_pub/reaction.html +45 -0
- data/_includes/activity_pub/reactions.html +17 -0
- data/_includes/activity_pub/replying_to.html +23 -0
- data/_includes/activity_pub/text_modal.html +16 -0
- data/_includes/activity_pub/toot_card.html +95 -0
- data/_includes/activity_pub/url.html +8 -0
- data/_includes/activity_pub/video_modal.html +20 -0
- data/_includes/boolean.html +9 -1
- data/_includes/bootstrap/custom_select.html +18 -0
- data/_includes/buttons/button.html +9 -0
- data/_includes/buttons/copy.html +28 -0
- data/_includes/buttons/generic.html +15 -0
- data/_includes/buttons/link.html +14 -0
- data/_includes/contact.html +6 -8
- data/_includes/content.html +9 -1
- data/_includes/device_detector.html +30 -0
- data/_includes/email.html +9 -1
- data/_includes/embed_responsive.html +16 -0
- data/_includes/external_link.html +15 -0
- data/_includes/fa.html +11 -0
- data/_includes/file.html +9 -1
- data/_includes/floating_alert.html +6 -0
- data/_includes/footer.html +1 -1
- data/_includes/headings/generic.html +14 -0
- data/_includes/headings/h1.html +9 -0
- data/_includes/headings/h2.html +9 -0
- data/_includes/headings/h3.html +9 -0
- data/_includes/headings/with_link.html +15 -0
- data/_includes/image.html +9 -1
- data/_includes/input.html +34 -7
- data/_includes/item.html +38 -0
- data/_includes/logo.html +1 -0
- data/_includes/markdown_content.html +9 -1
- data/_includes/menu.html +27 -0
- data/_includes/navbar.html +5 -1
- data/_includes/notification.html +5 -0
- data/_includes/number.html +9 -1
- data/_includes/pack.html +10 -0
- data/_includes/password.html +10 -0
- data/_includes/picture.html +25 -0
- data/_includes/post.html +18 -7
- data/_includes/predefined_array.html +10 -2
- data/_includes/preload_font.html +1 -0
- data/_includes/reproductor.html +29 -12
- data/_includes/script.html +5 -0
- data/_includes/search.html +25 -0
- data/_includes/share.html +8 -8
- data/_includes/share_box.html +41 -12
- data/_includes/social_networks.html +6 -0
- data/_includes/stretched_link.html +15 -0
- data/_includes/string.html +10 -1
- data/_includes/submit.html +13 -1
- data/_includes/svg/copy-icon.svg +1 -0
- data/_includes/svg/done-icon.svg +1 -0
- data/_includes/svg/menu.svg +9 -0
- data/_includes/svg/x.svg +3 -0
- data/_includes/tel.html +9 -1
- data/_includes/text.html +9 -1
- data/_includes/theme/button_with_copy.html +1 -0
- data/_includes/theme/button_with_link.html +5 -0
- data/_includes/theme/buttons.html +33 -0
- data/_includes/theme/colors.html +14 -0
- data/_includes/theme/content.html +41 -0
- data/_includes/theme/embed_responsive.html +10 -0
- data/_includes/theme/font_sizes.html +18 -0
- data/_includes/theme/footer.html +1 -0
- data/_includes/theme/letter_spacing.html +3 -0
- data/_includes/theme/picture.html +5 -0
- data/_includes/toggler/toggler.html +21 -0
- data/_includes/toggler/toggler_label.html +21 -0
- data/_includes/toggler/toggler_related.html +23 -0
- data/_includes/url.html +9 -1
- data/_layouts/default.html +56 -16
- data/_layouts/home.html +7 -5
- data/_layouts/page.html +5 -0
- data/_layouts/theme.html +60 -0
- data/_sass/accessibility.scss +40 -7
- data/_sass/content.scss +28 -0
- data/_sass/editor.scss +17 -0
- data/_sass/embed.scss +8 -0
- data/_sass/floating_alert.scss +48 -0
- data/_sass/fonts.scss +29 -0
- data/_sass/menu.scss +36 -0
- data/_sass/snap.scss +60 -0
- data/_sass/toggler.scss +15 -34
- data/_sass/utilities.scss +527 -0
- data/assets/css/styles.scss +16 -13
- data/assets/data/site.json +10 -0
- data/assets/fonts/forkawesome-webfont.woff2 +0 -0
- data/assets/fonts/roboto/v27/KFOjCnqEu92Fr1Mu51TzBhc9-subset.woff2 +0 -0
- data/assets/fonts/roboto/v27/KFOkCnqEu92Fr1MmgWxP-subset.woff2 +0 -0
- data/assets/fonts/roboto/v27/KFOkCnqEu92Fr1Mu52xP-subset.woff2 +0 -0
- data/assets/fonts/roboto/v27/KFOlCnqEu92Fr1MmWUlvAw-subset.woff2 +0 -0
- data/assets/fonts/roboto/v27/KFOmCnqEu92Fr1Me5Q-subset.woff2 +0 -0
- data/assets/js/env.js +8 -0
- data/assets/js/pack.L3BFF2IJ.js +40 -0
- data/assets/js/pack.L3BFF2IJ.js.map +7 -0
- metadata +287 -23
- data/_data/forms/contacto.yml +0 -40
- data/_sass/helpers.scss +0 -54
- data/_sass/share.html +0 -12
- data/_sass/share_box.html +0 -16
- data/assets/js/script.js +0 -82
@@ -0,0 +1,95 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Toot card
|
3
|
+
|
4
|
+
@param :component_class [String] Las clases del componente
|
5
|
+
@param :profile [String]
|
6
|
+
@param :activity [String]
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
{% assign extra_class = include.activity.attachment | size | equals: 1 | ternary: 'col', 'col-6' %}
|
10
|
+
|
11
|
+
<div class="d-flex flex-column media {{ include.component_class }}">
|
12
|
+
<div class="d-flex">
|
13
|
+
{%
|
14
|
+
include embed_responsive.html
|
15
|
+
x=1
|
16
|
+
y=1
|
17
|
+
src=include.profile.icon.url
|
18
|
+
alt=include.profile.icon.name
|
19
|
+
width=40
|
20
|
+
embed_class="mr-2 align-self-center w-49px"
|
21
|
+
img_class="h-100 object-fit-cover"
|
22
|
+
%}
|
23
|
+
|
24
|
+
<div class="">
|
25
|
+
<p>{% include_cached activity_pub/actor.html actor=include.profile %}</p>
|
26
|
+
<p>{% include_cached activity_pub/actor_mention.html actor=include.profile %}</p>
|
27
|
+
</div>
|
28
|
+
</div>
|
29
|
+
|
30
|
+
<div class="media-body w-100">
|
31
|
+
{% capture content %}
|
32
|
+
<div class="content mt-2">
|
33
|
+
{{ include.activity.content | sanitize_html }}
|
34
|
+
</div>
|
35
|
+
|
36
|
+
{% unless include.activity.attachment == empty %}
|
37
|
+
<div class="row no-gutters mt-2">
|
38
|
+
{% for attachment in include.activity.attachment %}
|
39
|
+
{% if attachment.mediaType == "video/mp4" %}
|
40
|
+
{% include activity_pub/video_modal.html video=attachment extra=extra_class %}
|
41
|
+
{% else %}
|
42
|
+
{% include activity_pub/image_modal.html image=attachment extra=extra_class %}
|
43
|
+
{% endif %}
|
44
|
+
{% endfor %}
|
45
|
+
</div>
|
46
|
+
{% endunless %}
|
47
|
+
{% endcapture %}
|
48
|
+
|
49
|
+
{% if include.activity.sensitive %}
|
50
|
+
{% capture summary_title %}
|
51
|
+
<strong>{{ site.i18n.sensitive }}:</strong> {{ include.activity.summary }}
|
52
|
+
{% endcapture %}
|
53
|
+
|
54
|
+
{%
|
55
|
+
include details.html
|
56
|
+
element_title=summary_title
|
57
|
+
element_text=content
|
58
|
+
summary_class="align-items-center btn-lg btn-secondary p-2 text-left f-16"
|
59
|
+
component_class="my-3"
|
60
|
+
font_size="ml-3 lead"
|
61
|
+
%}
|
62
|
+
{% else %}
|
63
|
+
{{ content }}
|
64
|
+
{% endif %}
|
65
|
+
|
66
|
+
<div class="d-flex gray justify-content-between my-2 align-items-center">
|
67
|
+
{%- assign timestamp_field = include.activity.updated | ternary: 'updated', 'published' -%}
|
68
|
+
{%- assign timestamp = include.activity[timestamp_field] -%}
|
69
|
+
|
70
|
+
{%- capture timestamp -%}
|
71
|
+
{% include date.html date=timestamp format=site.i18n.date_time.format %}
|
72
|
+
{%- endcapture -%}
|
73
|
+
|
74
|
+
{%- capture uri -%}
|
75
|
+
{%- include_cached activity_pub/url.html activity=include.activity -%}
|
76
|
+
{%- endcapture -%}
|
77
|
+
|
78
|
+
{% include external_link.html href=uri text=timestamp %}
|
79
|
+
|
80
|
+
<div>
|
81
|
+
{% if include.activity.shares.totalItems %}
|
82
|
+
{%- include fa.html icon="retweet" class="px-1" description=site.i18n.total_shares content=include.activity.shares.totalItems -%}
|
83
|
+
{% endif %}
|
84
|
+
|
85
|
+
{% if include.activity.likes.totalItems %}
|
86
|
+
{%- include fa.html icon="star-o" class="px-1" description=site.i18n.total_likes content=include.activity.likes.totalItems -%}
|
87
|
+
{% endif %}
|
88
|
+
</div>
|
89
|
+
|
90
|
+
{%- include fa.html icon="globe" description=site.i18n.globe -%}
|
91
|
+
</div>
|
92
|
+
|
93
|
+
{% include activity_pub/button_bar.html uri=include.activity.id profile=include.profile %}
|
94
|
+
</div>
|
95
|
+
</div>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Modal con imagen
|
3
|
+
|
4
|
+
@param :image [Image] la imagen que queremos en el modal, contiene url y alt text
|
5
|
+
{%- endcomment -%}
|
6
|
+
|
7
|
+
{% capture body %}
|
8
|
+
<video src="{{include.video.url}}" controls></video>
|
9
|
+
{% endcapture %}
|
10
|
+
|
11
|
+
<div class="{{ include.extra }} px-1" data-controller="modal">
|
12
|
+
<div class="embed-responsive embed-responsive-16by9">
|
13
|
+
<video
|
14
|
+
class="cursor-pointer min-w-100px w-100 embed-responsive-item object-fit-cover"
|
15
|
+
src="{{include.video.url}}"
|
16
|
+
data-action="click->modal#show"
|
17
|
+
></video>
|
18
|
+
</div>
|
19
|
+
{% include activity_pub/generic_modal.html header_class="text-white" body=body body_class="d-flex justify-content-center" footer_class="d-none" content_class="background-transparent border-0" %}
|
20
|
+
</div>
|
data/_includes/boolean.html
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type boolean
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :boolean_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
1
9
|
{%- assign name = include.field[0] -%}
|
2
10
|
{%- assign id = include.field[1].id | default: name -%}
|
3
11
|
{%- assign label = include.field[1].label[site.locale] -%}
|
@@ -18,7 +26,7 @@
|
|
18
26
|
{% if autocomplete %}
|
19
27
|
autocomplete="{{ autocomplete }}"
|
20
28
|
{% endif %}
|
21
|
-
class="form-check-input" />
|
29
|
+
class="form-check-input {{ include.boolean_class }}" />
|
22
30
|
|
23
31
|
<label class="form-check-label" for="{{ id }}">{{ label }}</label>
|
24
32
|
|
@@ -0,0 +1,18 @@
|
|
1
|
+
{% comment %}
|
2
|
+
|
3
|
+
@param class [String] Extra classes
|
4
|
+
@param extra [String] Extra attributes
|
5
|
+
@param options [Array<Hash>] Options
|
6
|
+
@param selected [Boolean] Default option
|
7
|
+
@param extra [String] Extra attributes
|
8
|
+
@param value [String] Value
|
9
|
+
@param title [String] Title
|
10
|
+
{% endcomment %}
|
11
|
+
|
12
|
+
<select class="custom-select {{ include.class }}" {{ include.extra }}>
|
13
|
+
{% for options in include.options %}
|
14
|
+
<option {{ options.selected }} {{ options.extra }} value="{{ options.value | default: options.title | escape }}">
|
15
|
+
{{- options.title -}}
|
16
|
+
</option>
|
17
|
+
{% endfor %}
|
18
|
+
</select>
|
@@ -0,0 +1,9 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Un botón interactivo. Utiliza la etiqueta `<button>`
|
3
|
+
|
4
|
+
@param :class [String] Las clases del componente aparte de btn (colores, tipografía, etc)
|
5
|
+
@param :content [String,HTML] El contenido del botón
|
6
|
+
@param :extra [HTML] Atributos extra
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
{%- include buttons/generic.html element="button" class=include.class content=include.content extra=include.extra -%}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Un botón con contenido copiable. Si el
|
4
|
+
link es externo, agregar el parámetro de seguridad noopener.
|
5
|
+
|
6
|
+
@param :copy [String] El texto copiable
|
7
|
+
@param :text [String] El contenido
|
8
|
+
|
9
|
+
{%- endcomment -%}
|
10
|
+
|
11
|
+
{% capture content %}
|
12
|
+
<span data-button-copy-target="text">{{- include.text -}}</span>
|
13
|
+
<span data-button-copy-target="icon" class="pl-2">
|
14
|
+
{%- include svg/copy-icon.svg -%}
|
15
|
+
</span>
|
16
|
+
<span data-button-copy-target="confirmationIcon" class="d-none pl-2">
|
17
|
+
{%- include svg/done-icon.svg -%}
|
18
|
+
</span>
|
19
|
+
{% endcapture %}
|
20
|
+
|
21
|
+
{% capture extra %}
|
22
|
+
data-controller="button-copy"
|
23
|
+
data-button-copy-text-value="{{ include.copy | escape_once }}"
|
24
|
+
data-button-copy-confirmation-value="{{ site.i18n.button_copy.confirmation | replace: "%s", include.copy | escape_once }}"
|
25
|
+
data-action="button-copy#copy"
|
26
|
+
{% endcapture %}
|
27
|
+
|
28
|
+
{% include buttons/button.html class="btn btn-primary" content=content extra=extra %}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Un botón genérico. Se usa como base para crear los demás
|
3
|
+
botones con distintas funcionalidades.
|
4
|
+
|
5
|
+
@param :element [String] El elemento (p.e. `a` `button`)
|
6
|
+
@param :class [String] Las clases del componente aparte de btn (colores, tipografía, etc)
|
7
|
+
@param :content [String,HTML] El contenido del botón
|
8
|
+
@param :extra [HTML] Atributos extra
|
9
|
+
{%- endcomment -%}
|
10
|
+
|
11
|
+
{%- assign element = include.element | default: "button" -%}
|
12
|
+
|
13
|
+
<{{ element }} {{ include.extra }} class="btn {{ include.class }}">
|
14
|
+
{{- include.content -}}
|
15
|
+
</{{ element }}>
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Un botón con link. Utiliza la etiqueta `<a>`
|
3
|
+
|
4
|
+
@param :href [String] La URL destino
|
5
|
+
@param :class [String] Las clases del componente aparte de btn (colores, tipografía, etc)
|
6
|
+
@param :content [String,HTML] El contenido del botón
|
7
|
+
@param :extra [HTML] Atributos extra
|
8
|
+
{%- endcomment -%}
|
9
|
+
|
10
|
+
{%- assign extra = include.href | start_with: "http://" | value_if: 'rel="noopener" target="_blank"' -%}
|
11
|
+
{%- assign extra = include.href | start_with: "https://" | value_if: 'rel="noopener" target="_blank"' -%}
|
12
|
+
{%- assign extra = include.href | uri_escape | prepend: 'href="' | append: '" ' | append: extra | append: " " | append: include.extra -%}
|
13
|
+
|
14
|
+
{%- include buttons/generic.html element="a" class=include.class content=include.content extra=extra -%}
|
data/_includes/contact.html
CHANGED
@@ -1,15 +1,13 @@
|
|
1
|
-
{% comment %}
|
2
|
-
Esta imagen obtiene una cookie desde la API de Sutty para autorizar el
|
3
|
-
envío del formulario.
|
4
|
-
{% endcomment %}
|
5
|
-
<img class="d-none" src="https://api.sutty.nl/v1/sites/{{ site.hostname }}/contact/cookie.png" />
|
6
|
-
|
7
1
|
{% comment %}
|
8
2
|
El formulario se envía a la API. La definición del formulario se
|
9
3
|
encuentra en _data/forms/contacto.yml
|
10
4
|
{% endcomment %}
|
11
|
-
<form
|
12
|
-
|
5
|
+
<form
|
6
|
+
data-turbo="false"
|
7
|
+
data-controller="contact"
|
8
|
+
data-delay="60"
|
9
|
+
action="https://api.{{ site.hostname }}/v1/sites/{{ site.hostname }}/contact/{{ include.name }}"
|
10
|
+
method="post">
|
13
11
|
{%- for field in include.form -%}
|
14
12
|
{% assign template = field[1].type | append: '.html' %}
|
15
13
|
<div class="col{{ field[1].col | default: 12 | prepend: '-' }}">
|
data/_includes/content.html
CHANGED
@@ -1 +1,9 @@
|
|
1
|
-
{
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type content
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :text_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
{% include text.html field=field text_class=include.text_class %}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
<div
|
2
|
+
data-controller="device-detector"
|
3
|
+
data-action="resize@window->device-detector#resized"
|
4
|
+
class="position-fixed top-0 right-0 background-pink-t3 z-index-2050 pointer-event-none">
|
5
|
+
<div>
|
6
|
+
<button class="pointer-event-auto btn btn-sm" data-action="device-detector#toggleHelp">
|
7
|
+
{{ site.i18n.device_detector.get_help }}
|
8
|
+
</button>
|
9
|
+
<button class="pointer-event-auto btn btn-sm" data-action="device-detector#outline">
|
10
|
+
{{ site.i18n.device_detector.outline }}
|
11
|
+
</button>
|
12
|
+
<span data-device-detector-target="clientName"></span>
|
13
|
+
|
14
|
+
<span data-device-detector-target="clientVersion"></span>
|
15
|
+
|
16
|
+
(<span data-device-detector-target="deviceType"></span>)
|
17
|
+
|
18
|
+
<span data-device-detector-target="osName"></span>
|
19
|
+
|
20
|
+
<span data-device-detector-target="osVersion"></span>
|
21
|
+
|
22
|
+
<span data-device-detector-target="viewportWidth"></span>
|
23
|
+
x <span data-device-detector-target="viewportHeight"></span>
|
24
|
+
x <span data-device-detector-target="devicePixelRatio"></span>
|
25
|
+
</div>
|
26
|
+
|
27
|
+
<div data-device-detector-target="help" hidden class="background-pink">
|
28
|
+
{{ site.i18n.device_detector.help | allow_inclusive_language_in_markdown | markdownify }}
|
29
|
+
</div>
|
30
|
+
</div>
|
data/_includes/email.html
CHANGED
@@ -1 +1,9 @@
|
|
1
|
-
{
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type email
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :input_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
{% include input.html field=field input_class=include.input_class %}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Embed responsive. Para imágenes con relación de aspecto.
|
4
|
+
Se suele usar para las imágenes de grillas.
|
5
|
+
|
6
|
+
@param :x [Integer] El ancho
|
7
|
+
@param :y [Integer] El alto
|
8
|
+
@param :src [String] La url de la imagen
|
9
|
+
@param :alt [String] La descripción de la imagen
|
10
|
+
@param :width [Integer] El ancho
|
11
|
+
@param :component_class [String] Las clases del componente embed_responsive
|
12
|
+
{%- endcomment -%}
|
13
|
+
|
14
|
+
<div class="embed-responsive embed-responsive-{{ include.x }}by{{ include.y }} {{ include.component_class }}">
|
15
|
+
{%- include picture.html class="embed-responsive-item" img_class="w-100 h-100 fit-cover" src=include.src alt=include.alt width=include.width -%}
|
16
|
+
</div>
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Link externo.
|
4
|
+
|
5
|
+
@param :href [String] La URL
|
6
|
+
@param :class [String] Las clases del link
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
<a
|
10
|
+
class="text-decoration-none {{ include.class }}"
|
11
|
+
href="{{ include.href | uri_escape }}"
|
12
|
+
{{ include.href | start_with: "https://" | value_if: 'rel="noopener" target="_blank"' }}
|
13
|
+
{{ include.href | start_with: "http://" | value_if: 'rel="noopener" target="_blank"' }}>
|
14
|
+
{{ include.text }}
|
15
|
+
</a>
|
data/_includes/fa.html
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Un ícono
|
4
|
+
|
5
|
+
@param :icon [String] El ícono
|
6
|
+
@param :class [String] Las clases
|
7
|
+
@param :description [String] La descripción
|
8
|
+
{%- endcomment -%}
|
9
|
+
|
10
|
+
<i title="{{ include.description | escape_once }}" aria-hidden="true" class="fa fa-{{ include.icon }} {{ include.class }}">{{ include.content }}</i>
|
11
|
+
<span class="sr-only">{{ include.description }}</span>
|
data/_includes/file.html
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type file
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :file_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
1
9
|
{%- assign name = include.field[0] -%}
|
2
10
|
{%- assign id = include.field[1].id | default: name -%}
|
3
11
|
{%- assign label = include.field[1]['path'].label[site.locale] -%}
|
@@ -20,7 +28,7 @@
|
|
20
28
|
{% if accept %}
|
21
29
|
accept="{{ accept }}"
|
22
30
|
{% endif %}
|
23
|
-
class="custom-file-input" />
|
31
|
+
class="custom-file-input {{ include.file_class }}" />
|
24
32
|
|
25
33
|
<label for="{{ id }}_path" class="custom-file-label">
|
26
34
|
{{ label }}
|
@@ -0,0 +1,6 @@
|
|
1
|
+
<div
|
2
|
+
data-controller="floating-alert"
|
3
|
+
class="floating-alert floating-alert-bottom floating-alert-default hide"
|
4
|
+
role="status" aria-live="polite" aria-atomic="true">
|
5
|
+
<div data-floating-alert-target="content" class="floating-alert-content white background-black-t4"></div>
|
6
|
+
</div>
|
data/_includes/footer.html
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
{%- assign radio = site.
|
1
|
+
{%- assign radio = site.about -%}
|
2
2
|
{%- assign license = site.posts | find: "layout", "license" -%}
|
3
3
|
{%- assign code_of_conduct = site.posts | find: "layout", "code_of_conduct" -%}
|
4
4
|
{%- assign privacy_policy = site.posts | find: "layout", "privacy_policy" -%}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
La base para un encabezado
|
4
|
+
|
5
|
+
@param :level [Integer] El nivel
|
6
|
+
@param :text [String] El contenido
|
7
|
+
@param :class [String] Clases para aplicar a títulos
|
8
|
+
{%- endcomment -%}
|
9
|
+
|
10
|
+
{%- assign slug = include.text | slugify -%}
|
11
|
+
|
12
|
+
<h{{ include.level }} id="{{ slug }}" class="{{ include.class }}">
|
13
|
+
{{- include.text -}}
|
14
|
+
</h{{ include.level }}>
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
La base para un encabezado con enlace
|
4
|
+
|
5
|
+
@param :level [Integer] El nivel
|
6
|
+
@param :text [String] El contenido
|
7
|
+
@param :class [String] Clases para aplicar a títulos
|
8
|
+
{%- endcomment -%}
|
9
|
+
|
10
|
+
{%- assign slug = include.text | slugify -%}
|
11
|
+
<h{{ include.level }} id="{{ slug }}">
|
12
|
+
<a class="{{ include.class }}" href="#{{ slug }}" data-turbo="false">
|
13
|
+
{{- include.text -}}
|
14
|
+
</a>
|
15
|
+
</h{{ include.level }}>
|
data/_includes/image.html
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type image
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :image_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
1
9
|
{%- assign name = include.field[0] -%}
|
2
10
|
{%- assign id = include.field[1].id | default: name -%}
|
3
11
|
{%- assign label = include.field[1]['path'].label[site.locale] -%}
|
@@ -17,7 +25,7 @@
|
|
17
25
|
name="{{ name }}[path]"
|
18
26
|
id="{{ id }}_path"
|
19
27
|
accept="image/*"
|
20
|
-
class="custom-file-input" />
|
28
|
+
class="custom-file-input {{ include.image_class }}" />
|
21
29
|
|
22
30
|
<label for="{{ id }}_path" class="custom-file-label">
|
23
31
|
{{ label }}
|
data/_includes/input.html
CHANGED
@@ -1,16 +1,39 @@
|
|
1
|
-
{%-
|
2
|
-
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type input
|
4
|
+
|
5
|
+
@param :form [String] El formulario
|
6
|
+
@param :field [Integer] El campo del formulario
|
7
|
+
@param :input_class [String] Las clases del componente
|
8
|
+
{%- endcomment -%}
|
9
|
+
|
10
|
+
{% if include.form %}
|
11
|
+
{%- assign name = include.field[0] | append: ']' | prepend: '[' | prepend: include.form -%}
|
12
|
+
{%- assign id = include.field[1].id | default: name | replace: '[', '_' | remove: ']' -%}
|
13
|
+
{% else %}
|
14
|
+
{%- assign name = include.field[0] -%}
|
15
|
+
{%- assign id = include.field[1].id | default: name %}
|
16
|
+
{% endif %}
|
17
|
+
|
3
18
|
{%- assign label = include.field[1].label[site.locale] -%}
|
4
19
|
{%- assign help = include.field[1].help[site.locale] -%}
|
20
|
+
{%- assign error = include.field[1].error[site.locale] -%}
|
5
21
|
{%- assign autocomplete = include.field[1].autocomplete -%}
|
22
|
+
{%- assign placeholder = include.field[1].placeholder[site.locale] -%}
|
6
23
|
|
7
24
|
<div class="form-group">
|
8
|
-
|
9
|
-
{{
|
10
|
-
|
11
|
-
|
25
|
+
{% if include.field[1].label %}
|
26
|
+
<label for="{{ id }}">
|
27
|
+
{{ label }}
|
28
|
+
{% if include.field[1].required %}*{% endif %}
|
29
|
+
</label>
|
30
|
+
{% endif %}
|
12
31
|
|
13
32
|
<input
|
33
|
+
{% if include.field[1].placeholder %}
|
34
|
+
placeholder="{{ placeholder }}"
|
35
|
+
{% endif %}
|
36
|
+
{{ include.field[1].extra.input }}
|
14
37
|
{% if help %}
|
15
38
|
aria-describedby="help-{{ id }}"
|
16
39
|
{% endif %}
|
@@ -23,7 +46,11 @@
|
|
23
46
|
{% if autocomplete %}
|
24
47
|
autocomplete="{{ autocomplete }}"
|
25
48
|
{% endif %}
|
26
|
-
class="form-control" />
|
49
|
+
class="form-control {{ include.input_class }}" />
|
50
|
+
|
51
|
+
{%- if error -%}
|
52
|
+
<div class="invalid-feedback">{{ error }}</div>
|
53
|
+
{%- endif -%}
|
27
54
|
|
28
55
|
{%- if help -%}
|
29
56
|
<small id="help-{{ id }}" class="form-text">
|
data/_includes/item.html
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
El ítem tiene un dropdown si tiene sub ítems o si tiene categorías.
|
3
|
+
{%- endcomment -%}
|
4
|
+
{%- assign dropdown = include.item.items | present -%}
|
5
|
+
{%- unless dropdown -%}
|
6
|
+
{%- assign dropdown = include.item.categories | present -%}
|
7
|
+
{%- endunless -%}
|
8
|
+
|
9
|
+
<div class="nav-item w-100 w-lg-auto {{ dropdown | value_if: 'dropdown d-flex flex-wrap' }}">
|
10
|
+
{%- comment -%}
|
11
|
+
La URL del item puede ser:
|
12
|
+
* El artículo vinculado
|
13
|
+
* El vínculo escrito manualmente
|
14
|
+
* La primera categoría de la lista
|
15
|
+
* La dirección propia (en el caso de categorías)
|
16
|
+
{%- endcomment -%}
|
17
|
+
<a
|
18
|
+
href="{{ include.item.post.url | default: include.item.link | default: include.item.categories[0].url | default: include.item.url }}"
|
19
|
+
class="nav-link flex-grow-1 flex-grow-lg-0">
|
20
|
+
{{ include.item.title }}
|
21
|
+
</a>
|
22
|
+
|
23
|
+
{%- if dropdown -%}
|
24
|
+
<button class="dropdown-toggle border-0 background-white w-5 w-lg-auto pl-lg-3"></button>
|
25
|
+
<div class="dropdown-menu w-100 w-lg-auto flex-grow-1 flex-grow-lg-0">
|
26
|
+
{% for item in include.item.items %}
|
27
|
+
{%- include_cached item.html item=item -%}
|
28
|
+
{% endfor %}
|
29
|
+
|
30
|
+
{%- comment -%}
|
31
|
+
Esto necesita `replace` en sutty-archives
|
32
|
+
{%- endcomment -%}
|
33
|
+
{%- for item in include.item.categories offset: 1 -%}
|
34
|
+
{%- include_cached item.html item=item -%}
|
35
|
+
{%- endfor -%}
|
36
|
+
</div>
|
37
|
+
{%- endif -%}
|
38
|
+
</div>
|
data/_includes/logo.html
CHANGED
@@ -1 +1,9 @@
|
|
1
|
-
{
|
1
|
+
{%- comment -%}
|
2
|
+
|
3
|
+
Form: type markdown_content
|
4
|
+
|
5
|
+
@param :field [Integer] El campo del formulario
|
6
|
+
@param :text_class [String] Las clases del componente
|
7
|
+
{%- endcomment -%}
|
8
|
+
|
9
|
+
{% include text.html field=field text_class=include.text_class %}
|
data/_includes/menu.html
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
{%- comment -%}
|
2
|
+
Empezamos con los ítems que no dependen de otros e implementamos
|
3
|
+
recursivamente.
|
4
|
+
{%- endcomment -%}
|
5
|
+
{%- assign items = site.posts | where: 'layout', 'menu' | where: 'item', nil -%}
|
6
|
+
|
7
|
+
<nav class="navbar navbar-expand-lg navbar-light">
|
8
|
+
<button class="navbar-toggler"
|
9
|
+
type="button"
|
10
|
+
data-toggle="collapse"
|
11
|
+
data-target="#menu"
|
12
|
+
aria-label="{{ site.i18n.menu.title }}">
|
13
|
+
<span class="navbar-toggler-icon"></span>
|
14
|
+
</button>
|
15
|
+
|
16
|
+
<div class="collapse navbar-collapse" id="menu">
|
17
|
+
<div class="navbar-nav w-100 d-flex align-items-start justify-content-center">
|
18
|
+
{% for item in items %}
|
19
|
+
{%- include_cached item.html item=item -%}
|
20
|
+
{% endfor %}
|
21
|
+
|
22
|
+
<div class="nav-item w-100 w-lg-auto">
|
23
|
+
{%- include_cached search.html -%}
|
24
|
+
</div>
|
25
|
+
</div>
|
26
|
+
</div>
|
27
|
+
</nav>
|
data/_includes/navbar.html
CHANGED
@@ -17,12 +17,16 @@
|
|
17
17
|
entre navegaciones internas. Necesita un ID para funcionar.
|
18
18
|
{% endcomment %}
|
19
19
|
<nav
|
20
|
-
data-
|
20
|
+
data-turbo-permanent
|
21
21
|
id="navbar"
|
22
22
|
class="navbar sticky-top navbar-expand-lg navbar-theme d-print-block row no-gutters justify-content-center pl-0 pr-0"
|
23
23
|
role="navigation"
|
24
24
|
aria-label="{{ site.i18n.menu.title }}">
|
25
25
|
|
26
|
+
<a href="#content" data-turbo="false" class="sr-only sr-only-focusable">
|
27
|
+
{{ site.i18n.accessibility.skip_to_content }}
|
28
|
+
</a>
|
29
|
+
|
26
30
|
{% comment %}
|
27
31
|
Para que la barra se alinee con el contenido, tenemos que darle el
|
28
32
|
mismo ancho.
|