desy-html 10.1.1 → 10.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/config/tailwind.config.js +2 -2
- package/docs/ds/_ds.section.layout.njk +2 -2
- package/docs/index.html +9 -0
- package/package.json +1 -1
- package/src/templates/components/card/_examples.card.njk +8 -0
- package/src/templates/components/collapsible/_examples.collapsible.njk +19 -0
- package/src/templates/components/collapsible/_template.collapsible.njk +4 -4
- package/src/templates/components/collapsible/params.collapsible.yaml +16 -0
- package/src/templates/components/header-advanced/_template.header-advanced.njk +2 -2
- package/src/templates/components/header-advanced/params.header-advanced.yaml +8 -0
- package/src/templates/components/header-mini/_examples.header-mini.njk +283 -8
- package/src/templates/components/header-mini/_template.header-mini.njk +26 -0
- package/src/templates/components/header-mini/params.header-mini.yaml +56 -0
- package/src/templates/components/links-list/_examples.links-list.njk +97 -4
- package/src/templates/components/links-list/_template.links-list.njk +37 -3
- package/src/templates/components/links-list/params.links-list.yaml +21 -1
- package/src/templates/components/menu-horizontal/_examples.menu-horizontal.njk +187 -12
- package/src/templates/components/menu-horizontal/_styles.menu-horizontal.css +72 -5
- package/src/templates/components/menu-horizontal/_template.menu-horizontal.njk +3 -3
- package/src/templates/components/menu-vertical/_template.menu-vertical.njk +1 -1
- package/src/templates/components/table/_examples.table.njk +118 -118
- package/src/templates/components/table/_template.table.njk +10 -6
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
</ul>
|
|
26
26
|
<p class="c-paragraph-base">Puedes añadir breakpoints extra para aprovechar más la anchura del viewport. Esto es útil para aplicaciones web basadas en tablas donde se necesite más anchura para que quepan más columnas en las tablas. Basta con añadir al archivo tailwind.config.js de tu proyecto alguna de estas líneas de código:</p>
|
|
27
27
|
<ul class="c-ul">
|
|
28
|
-
<li><code>2xl: '
|
|
29
|
-
<li><code>3xl: '
|
|
28
|
+
<li><code>2xl: '1536px',</code></li>
|
|
29
|
+
<li><code>3xl: '1900px',</code></li>
|
|
30
30
|
</ul>
|
|
31
31
|
<div class="pb-lg"></div>
|
|
32
32
|
{% from "ds/_ds.macro.subsection-title.njk" import DSSubsectionTitle %}
|
package/docs/index.html
CHANGED
|
@@ -38,6 +38,15 @@
|
|
|
38
38
|
|
|
39
39
|
<h2>Changelog (English)</h2>
|
|
40
40
|
<p>What's new in the latest version of desy-html</p>
|
|
41
|
+
<h3>v.10.2.0</h3>
|
|
42
|
+
<ul class="text-sm">
|
|
43
|
+
<li>Menu horizontal improvements and modifiers.</li>
|
|
44
|
+
<li>Links list improvements and icon customizations.</li>
|
|
45
|
+
<li>Added new params to style collapsible elements.</li>
|
|
46
|
+
<li>Table now is stacked in mobile.</li>
|
|
47
|
+
<li>Improvements in additional breakpoints.</li>
|
|
48
|
+
<li>Footer columns fixes.</li>
|
|
49
|
+
</ul>
|
|
41
50
|
<h3>v.10.1.1</h3>
|
|
42
51
|
<ul class="text-sm">
|
|
43
52
|
<li>Fixed columns in Footer navigation items.</li>
|
package/package.json
CHANGED
|
@@ -126,6 +126,14 @@
|
|
|
126
126
|
"caller": withIconContent("1").val | indent(4)
|
|
127
127
|
}
|
|
128
128
|
},
|
|
129
|
+
{
|
|
130
|
+
"name": "sin bordes ni padding y con todo el card clicable",
|
|
131
|
+
"data": {
|
|
132
|
+
"classes": "lg:w-1/3",
|
|
133
|
+
"containerClasses": "relative",
|
|
134
|
+
"caller": fullContent | indent(4)
|
|
135
|
+
}
|
|
136
|
+
},
|
|
129
137
|
{
|
|
130
138
|
"name": "barra lateral simple",
|
|
131
139
|
"data": {
|
|
@@ -54,5 +54,24 @@
|
|
|
54
54
|
cillum dolore eu fugiat nulla <em>pariatur</em>. Excepteur sint occaecat cupidatat non
|
|
55
55
|
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>'
|
|
56
56
|
}
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"name": "con clases aplicadas",
|
|
60
|
+
"description": "Puedes añadir clases a todos los elementos para cambiar su apariencia",
|
|
61
|
+
"data": {
|
|
62
|
+
"id": "collapsible-default",
|
|
63
|
+
"headerText": "Cabecera del collapsible",
|
|
64
|
+
"text": "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
|
65
|
+
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
|
66
|
+
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
|
|
67
|
+
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
|
|
68
|
+
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
|
|
69
|
+
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",
|
|
70
|
+
"classes": "p-base bg-primary-light flex flex-wrap gap-base",
|
|
71
|
+
"buttonClasses": "c-button self-start",
|
|
72
|
+
"showClasses": "!hidden",
|
|
73
|
+
"hideClasses": "!hidden",
|
|
74
|
+
"contentClasses": "flex-1 border border-neutral-base p-base bg-white rounded"
|
|
75
|
+
}
|
|
57
76
|
}
|
|
58
77
|
] %}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<!-- collapsible -->
|
|
2
2
|
<div class="{%- if params.classes %} {{ params.classes }}{% else -%} -my-px py-sm border-t border-b border-neutral-base{% endif %} c-collapsible" {%- for attribute, value in params.attributes %} {{attribute}}="{{value}}"{% endfor %} {% if params.open %} data-expanded="false" {% else %} data-expanded="true" {% endif %} data-module="c-collapsible">
|
|
3
|
-
<button aria-expanded="false" {%- if params.id %} id="{{params.id}}-title"{% endif %} class="group relative w-full py-sm font-semibold text-left cursor-pointer focus:bg-warning-base focus:outline-none focus:shadow-outline-focus focus:text-black" {%- if params.id %} aria-controls="{{params.id}}"{% endif %}>{{ params.headerHtml | safe if params.headerHtml else params.headerText }}
|
|
4
|
-
<span class="c-collapsible__show absolute inset-y-0 right-0 py-sm font-normal text-sm text-neutral-dark underline group-focus:text-black pointer-events-none" aria-hidden="false">Mostrar</span>
|
|
5
|
-
<span class="c-collapsible__hide absolute inset-y-0 right-0 py-sm font-normal text-sm text-neutral-dark underline group-focus:text-black pointer-events-none" aria-hidden="true">Ocultar</span>
|
|
3
|
+
<button aria-expanded="false" {%- if params.id %} id="{{params.id}}-title"{% endif %} class="{%- if params.buttonClasses %} {{ params.buttonClasses }}{% else -%} group relative w-full py-sm font-semibold text-left cursor-pointer focus:bg-warning-base focus:outline-none focus:shadow-outline-focus focus:text-black{% endif %}" {%- if params.id %} aria-controls="{{params.id}}"{% endif %}>{{ params.headerHtml | safe if params.headerHtml else params.headerText }}
|
|
4
|
+
<span class="c-collapsible__show {% if params.showClasses %} {{ params.showClasses }}{% else -%} absolute inset-y-0 right-0 py-sm font-normal text-sm text-neutral-dark underline group-focus:text-black pointer-events-none{% endif %}" aria-hidden="false">Mostrar</span>
|
|
5
|
+
<span class="c-collapsible__hide {% if params.hideClasses %} {{ params.hideClasses }}{% else -%} absolute inset-y-0 right-0 py-sm font-normal text-sm text-neutral-dark underline group-focus:text-black pointer-events-none{% endif %}" aria-hidden="true">Ocultar</span>
|
|
6
6
|
</button>
|
|
7
|
-
<div aria-hidden="true" class="c-collapsible__content py-sm" {%- if params.id %} id="{{params.id}}"{% endif %}>
|
|
7
|
+
<div aria-hidden="true" class="c-collapsible__content {% if params.contentClasses %} {{ params.contentClasses }}{% else -%} py-sm{% endif %}" {%- if params.id %} id="{{params.id}}"{% endif %}>
|
|
8
8
|
{% if params.html %}
|
|
9
9
|
{{ params.html | safe }}
|
|
10
10
|
{% else %}
|
|
@@ -23,6 +23,22 @@ params:
|
|
|
23
23
|
type: boolean
|
|
24
24
|
required: false
|
|
25
25
|
description: If true, collapsible element will be expanded.
|
|
26
|
+
- name: buttonClasses
|
|
27
|
+
type: string
|
|
28
|
+
required: false
|
|
29
|
+
description: Classes to add to the button element.
|
|
30
|
+
- name: showClasses
|
|
31
|
+
type: string
|
|
32
|
+
required: false
|
|
33
|
+
description: Classes to add to the show element.
|
|
34
|
+
- name: hideClasses
|
|
35
|
+
type: string
|
|
36
|
+
required: false
|
|
37
|
+
description: Classes to add to the hide element.
|
|
38
|
+
- name: contentClasses
|
|
39
|
+
type: string
|
|
40
|
+
required: false
|
|
41
|
+
description: Classes to add to the content element.
|
|
26
42
|
- name: classes
|
|
27
43
|
type: string
|
|
28
44
|
required: false
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
{% endif %}
|
|
26
26
|
{% if params.super %}
|
|
27
27
|
{% if params.super.customHtml %}
|
|
28
|
-
{{ params.super.customHtml }}
|
|
28
|
+
{{ params.super.customHtml | safe }}
|
|
29
29
|
{% else %}
|
|
30
30
|
<div class="{% if params.super.classes %}{{ params.super.classes }}{% else-%} h-32 bg-cover bg-center bg-no-repeat overflow-hidden{% endif %}" {%- if params.super.backgroundFullColor or params.super.backgroundFullUrl %} style="{% if params.super.backgroundFullColor %}background-color: {{ params.super.backgroundFullColor }};{% endif %} {%- if params.super.backgroundFullUrl %} background-image: url('{{ params.super.backgroundFullUrl }}'){% endif %}"{% endif %}>
|
|
31
31
|
<div class="container h-full mx-auto px-base">
|
|
@@ -148,7 +148,7 @@
|
|
|
148
148
|
</div>
|
|
149
149
|
{% if params.sub %}
|
|
150
150
|
{% if params.sub.customHtml %}
|
|
151
|
-
{{ params.sub.customHtml }}
|
|
151
|
+
{{ params.sub.customHtml | safe }}
|
|
152
152
|
{% else %}
|
|
153
153
|
<div class="{% if params.sub.classes %}{{ params.sub.classes }}{% else-%} h-32 bg-cover bg-no-repeat overflow-hidden{% endif %}" {%- if params.sub.backgroundFullColor or params.sub.backgroundFullUrl %} style="{% if params.sub.backgroundFullColor %}background-color: {{ params.sub.backgroundFullColor }};{% endif %} {%- if params.sub.backgroundFullUrl %} background-image: url('{{ params.sub.backgroundFullUrl }}'){% endif %}"{% endif %}>
|
|
154
154
|
<div class="container h-full mx-auto px-base">
|
|
@@ -51,6 +51,10 @@ params:
|
|
|
51
51
|
type: string
|
|
52
52
|
required: false
|
|
53
53
|
description: If provided, the default super content will be replaced with this.
|
|
54
|
+
- name: classes
|
|
55
|
+
type: string
|
|
56
|
+
required: false
|
|
57
|
+
description: Classes to add to the super.
|
|
54
58
|
- name: noTitle
|
|
55
59
|
type: boolean
|
|
56
60
|
required: false
|
|
@@ -303,6 +307,10 @@ params:
|
|
|
303
307
|
type: string
|
|
304
308
|
required: false
|
|
305
309
|
description: If provided, the default super content will be replaced with this.
|
|
310
|
+
- name: classes
|
|
311
|
+
type: string
|
|
312
|
+
required: false
|
|
313
|
+
description: Classes to add to the sub.
|
|
306
314
|
- name: offcanvas
|
|
307
315
|
type: object
|
|
308
316
|
required: false
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
{% set exampleComponent = "header-mini" %}
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
{% set logoUE %}
|
|
5
|
-
<svg xmlns="http://www.w3.org/2000/svg" width="44" height="36" viewBox="0 0 148 121" class="relative top-0.5 inline-block fill-current" aria-label="Unión Europea" role="img"><title>Logo de la Unión Europea</title><defs><clipPath id="a-logo-UE"><path d="M0 0h148v121H0z"/></clipPath></defs><g clip-path="url(#a-logo-UE)"><path d="M11.737 107.263H13.9v5.815a12.063 12.063 0 0 0 .081 1.794 1.739 1.739 0 0 0 .663 1.058 2.309 2.309 0 0 0 1.432.4 2.185 2.185 0 0 0 1.392-.377 1.49 1.49 0 0 0 .564-.927 12.08 12.08 0 0 0 .1-1.824v-5.94H20.3v5.638a14.491 14.491 0 0 1-.176 2.732 3.024 3.024 0 0 1-.648 1.348 3.275 3.275 0 0 1-1.263.875 5.5 5.5 0 0 1-2.065.326 5.947 5.947 0 0 1-2.333-.355 3.336 3.336 0 0 1-1.256-.923 2.958 2.958 0 0 1-.608-1.19 13.04 13.04 0 0 1-.212-2.725ZM22.606 118v-10.737h2.109l4.395 7.17v-7.17h2.014V118h-2.175l-4.329-7v7Zm10.745 0v-10.737h2.168V118Zm3.794-5.3a6.829 6.829 0 0 1 .491-2.754 5.053 5.053 0 0 1 1-1.472 4.18 4.18 0 0 1 1.388-.967 5.9 5.9 0 0 1 2.314-.425 5.041 5.041 0 0 1 3.8 1.472 5.642 5.642 0 0 1 1.422 4.092 5.624 5.624 0 0 1-1.414 4.069 5 5 0 0 1-3.779 1.468 5.053 5.053 0 0 1-3.809-1.461 5.545 5.545 0 0 1-1.413-4.022Zm2.234-.073a4.023 4.023 0 0 0 .842 2.765 2.744 2.744 0 0 0 2.139.941 2.721 2.721 0 0 0 2.127-.933 4.1 4.1 0 0 0 .831-2.8 4.037 4.037 0 0 0-.809-2.754 2.738 2.738 0 0 0-2.15-.908 2.757 2.757 0 0 0-2.161.919 4.057 4.057 0 0 0-.82 2.767Zm1.641-5.977 1.011-2.19h2.307l-2.014 2.19ZM49.273 118v-10.737h2.109l4.395 7.17v-7.17h2.014V118h-2.175l-4.329-7v7Zm14.978 0v-10.737h7.961v1.816h-5.793v2.38h5.391v1.809h-5.391v2.922h6V118Zm9.991-10.737h2.168v5.815a12.063 12.063 0 0 0 .08 1.795 1.739 1.739 0 0 0 .663 1.058 2.309 2.309 0 0 0 1.432.4 2.185 2.185 0 0 0 1.392-.377 1.49 1.49 0 0 0 .564-.927 12.08 12.08 0 0 0 .1-1.824v-5.94H82.8v5.637a14.491 14.491 0 0 1-.176 2.732 3.024 3.024 0 0 1-.644 1.35 3.275 3.275 0 0 1-1.263.875 5.5 5.5 0 0 1-2.066.326 5.947 5.947 0 0 1-2.333-.355 3.336 3.336 0 0 1-1.256-.923 2.958 2.958 0 0 1-.608-1.19 13.04 13.04 0 0 1-.212-2.725ZM85.1 118v-10.737h4.563a7.81 7.81 0 0 1 2.5.289 2.467 2.467 0 0 1 1.249 1.029 3.093 3.093 0 0 1 .469 1.692 2.866 2.866 0 0 1-.71 2 3.412 3.412 0 0 1-2.124.992 5.058 5.058 0 0 1 1.161.9 12.237 12.237 0 0 1 1.234 1.743L94.75 118h-2.593l-1.568-2.336a15.156 15.156 0 0 0-1.143-1.578 1.664 1.664 0 0 0-.652-.447 3.573 3.573 0 0 0-1.094-.121h-.439V118Zm2.168-6.2h1.6a8.283 8.283 0 0 0 1.948-.132 1.168 1.168 0 0 0 .608-.454 1.4 1.4 0 0 0 .22-.806 1.287 1.287 0 0 0-.289-.875 1.328 1.328 0 0 0-.817-.421q-.264-.037-1.582-.037h-1.692Zm8.218.894a6.829 6.829 0 0 1 .491-2.754 5.053 5.053 0 0 1 1-1.472 4.18 4.18 0 0 1 1.383-.968 5.9 5.9 0 0 1 2.314-.425 5.041 5.041 0 0 1 3.8 1.472 5.642 5.642 0 0 1 1.426 4.099 5.624 5.624 0 0 1-1.414 4.069 5 5 0 0 1-3.786 1.468 5.053 5.053 0 0 1-3.8-1.461 5.545 5.545 0 0 1-1.418-4.022Zm2.234-.073a4.023 4.023 0 0 0 .842 2.765 2.744 2.744 0 0 0 2.138.944 2.721 2.721 0 0 0 2.124-.93 4.1 4.1 0 0 0 .831-2.8 4.037 4.037 0 0 0-.809-2.754 2.738 2.738 0 0 0-2.15-.908 2.757 2.757 0 0 0-2.161.919 4.057 4.057 0 0 0-.819 2.767Zm9.869 5.379v-10.737h3.479a12.616 12.616 0 0 1 2.578.161 2.815 2.815 0 0 1 1.545 1.051 3.333 3.333 0 0 1 .623 2.091 3.5 3.5 0 0 1-.359 1.663 2.944 2.944 0 0 1-.912 1.058 3.142 3.142 0 0 1-1.124.509 12.375 12.375 0 0 1-2.249.154h-1.413V118Zm2.168-8.921v3.047h1.187a5.606 5.606 0 0 0 1.714-.168 1.423 1.423 0 0 0 .677-.527 1.443 1.443 0 0 0 .245-.831 1.387 1.387 0 0 0-.344-.967 1.5 1.5 0 0 0-.872-.476 10.42 10.42 0 0 0-1.56-.073Zm7.837 8.921v-10.737h7.961v1.816h-5.793v2.38h5.391v1.809h-5.391v2.922h6V118Zm19.687 0h-2.358l-.937-2.439h-4.293l-.886 2.439h-2.3l4.182-10.737h2.292Zm-3.991-4.248-1.48-3.984-1.45 3.984ZM2.83 2.741h141.523v94.35H2.83z" fill="#039"/><g fill="#fc0"><path d="m70.576 23.298 2.986-2.179 2.987 2.179-1.136-3.524 3.033-2.179h-3.739l-1.144-3.567-1.144 3.571h-3.737l3.031 2.179ZM55.121 27.45l2.986-2.179 2.984 2.179-1.134-3.524 3.031-2.179h-3.739l-1.144-3.571-1.144 3.575h-3.737l3.031 2.179ZM46.8 29.508l-1.144 3.575h-3.737l3.031 2.179-1.136 3.524 2.986-2.179 2.986 2.179-1.136-3.524 3.031-2.179h-3.737ZM42.652 52.039l2.984 2.179-1.134-3.524 3.031-2.179h-3.737l-1.144-3.571-1.144 3.579-3.739-.008 3.033 2.179-1.136 3.524ZM47.945 63.997l-1.144-3.571-1.144 3.575H41.92l3.031 2.179-1.136 3.524 2.986-2.183 2.986 2.183-1.136-3.524 3.031-2.179ZM59.274 75.324l-1.144-3.567-1.142 3.571h-3.739l3.031 2.179-1.135 3.524 2.986-2.179 2.984 2.179-1.134-3.524 3.031-2.179ZM74.709 79.43l-1.144-3.571-1.142 3.575h-3.739l3.031 2.179-1.134 3.524 2.986-2.179 2.985 2.179-1.137-3.524 3.033-2.179ZM90.142 75.324 89 71.757l-1.146 3.571h-3.735l3.029 2.179-1.134 3.524L89 78.852l2.986 2.179-1.138-3.524 3.033-2.179ZM101.475 63.997l-1.146-3.571-1.146 3.575h-3.735l3.033 2.179-1.138 3.524 2.986-2.183 2.986 2.183-1.138-3.524 3.033-2.179ZM109.316 48.471h-3.739l-1.146-3.571-1.142 3.575H99.55l3.033 2.179-1.134 3.524 2.982-2.183 2.986 2.183-1.134-3.524ZM97.343 38.736l2.986-2.179 2.986 2.179-1.138-3.524 3.033-2.175h-3.735l-1.146-3.571-1.146 3.575h-3.735l3.033 2.175ZM89.043 18.179l-1.142 3.575-3.739-.008 3.029 2.183-1.134 3.524 2.99-2.183 2.982 2.183-1.135-3.524 3.033-2.183h-3.743Z"/></g></g></svg>
|
|
6
|
-
{% endset %}
|
|
7
|
-
|
|
8
|
-
|
|
9
4
|
{% set examples = [
|
|
10
5
|
{
|
|
11
6
|
"name": "por defecto",
|
|
@@ -19,12 +14,292 @@
|
|
|
19
14
|
"data": {
|
|
20
15
|
"hasContainer": false
|
|
21
16
|
}
|
|
17
|
+
}
|
|
18
|
+
] %}
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
{% from "components/searchbar/_macro.searchbar.njk" import componentSearchbar %}
|
|
24
|
+
{% from "components/toggle/_macro.toggle.njk" import componentToggle %}
|
|
25
|
+
|
|
26
|
+
{% set customNavigation %}
|
|
27
|
+
<div class="flex flex-1 justify-end items-stretch">
|
|
28
|
+
<div class="flex justify-center items-center">
|
|
29
|
+
{{ componentToggle({
|
|
30
|
+
"id": "megamenu-mini-button-is-open",
|
|
31
|
+
"classes": "c-button c-button--sm c-button--transparent",
|
|
32
|
+
"offState": {
|
|
33
|
+
"classes": "",
|
|
34
|
+
"html": '<span class="inline-flex">Menu<svg class="inline-block -mr-2 align-middle -my-px pointer-events-none" viewBox="0 0 96 96" aria-hidden="true" fill="currentColor" focusable="false" width="1.5em" height="1.5em"><g><path d="M46.71 58.037a1.823 1.823 0 002.581 0L62.048 45.28a1.823 1.823 0 00-1.29-3.113H35.243a1.823 1.823 0 00-1.291 3.113z"></path></g></svg></span>'
|
|
35
|
+
},
|
|
36
|
+
"onState": {
|
|
37
|
+
"classes": "",
|
|
38
|
+
"html": '<span class="inline-flex">Menu<svg class="inline-block -mr-2 align-middle -my-px pointer-events-none rotate-180" viewBox="0 0 96 96" aria-hidden="true" fill="currentColor" focusable="false" width="1.5em" height="1.5em"><g><path d="M46.71 58.037a1.823 1.823 0 002.581 0L62.048 45.28a1.823 1.823 0 00-1.29-3.113H35.243a1.823 1.823 0 00-1.291 3.113z"></path></g></svg></span>'
|
|
39
|
+
},
|
|
40
|
+
"attributes": {
|
|
41
|
+
"aria-controls": "megamenu-mini",
|
|
42
|
+
"role": "button",
|
|
43
|
+
"aria-controls": "megamenu-mini",
|
|
44
|
+
"onClick": "getElementById('megamenu-mini').classList.toggle('hidden')"
|
|
45
|
+
}
|
|
46
|
+
}) }}
|
|
47
|
+
</div>
|
|
48
|
+
</div>
|
|
49
|
+
{% endset %}
|
|
50
|
+
|
|
51
|
+
{% set megamenu %}
|
|
52
|
+
<div id="megamenu-mini" class="hidden">
|
|
53
|
+
<div class="py-base text-xs lg:text-sm
|
|
54
|
+
text-neutral-dark ">
|
|
55
|
+
<div class="container mx-auto px-base ">
|
|
56
|
+
<nav class="flex flex-col lg:flex-row flex-wrap gap-base" aria-label="Menú principal">
|
|
57
|
+
<div class=" flex-1 mb-sm">
|
|
58
|
+
<h3 class="c-h4 mb-base text-black">Temas</h3>
|
|
59
|
+
<ul class="relative space-y-base lg:columns-1 gap-base">
|
|
60
|
+
<li class="mb-xs">
|
|
61
|
+
<a class="c-link font-semibold" href="#1">
|
|
62
|
+
Administración pública y transparencia
|
|
63
|
+
</a>
|
|
64
|
+
</li>
|
|
65
|
+
<li class="mb-xs">
|
|
66
|
+
<a class="c-link font-semibold" href="#2">
|
|
67
|
+
Agricultura, ganadería y medio rural
|
|
68
|
+
</a>
|
|
69
|
+
</li>
|
|
70
|
+
<li class="mb-xs">
|
|
71
|
+
<a class="c-link font-semibold" href="#3">
|
|
72
|
+
Ciencia y tecnología
|
|
73
|
+
</a>
|
|
74
|
+
</li>
|
|
75
|
+
<li class="mb-xs">
|
|
76
|
+
<a class="c-link font-semibold" href="#4">
|
|
77
|
+
Comercio y consumo
|
|
78
|
+
</a>
|
|
79
|
+
</li>
|
|
80
|
+
<li class="mb-xs">
|
|
81
|
+
<a class="c-link font-semibold" href="#5">
|
|
82
|
+
Cultura, turismo, deportes y ocio
|
|
83
|
+
</a>
|
|
84
|
+
</li>
|
|
85
|
+
<li class="mb-xs">
|
|
86
|
+
<a class="c-link font-semibold" href="#6">
|
|
87
|
+
Educación y formación
|
|
88
|
+
</a>
|
|
89
|
+
</li>
|
|
90
|
+
<li class="mb-xs">
|
|
91
|
+
<a class="c-link font-semibold" href="#">
|
|
92
|
+
Empleo, empresa y otras entidades
|
|
93
|
+
</a>
|
|
94
|
+
</li>
|
|
95
|
+
<li class="mb-xs">
|
|
96
|
+
<a class="c-link font-semibold" href="#">
|
|
97
|
+
Impuestos y tasas
|
|
98
|
+
</a>
|
|
99
|
+
</li>
|
|
100
|
+
<li class="mb-xs">
|
|
101
|
+
<a class="c-link font-semibold" href="#">
|
|
102
|
+
Industria, energía y minería
|
|
103
|
+
</a>
|
|
104
|
+
</li>
|
|
105
|
+
<li class="mb-xs">
|
|
106
|
+
<a class="c-link font-semibold" href="#">
|
|
107
|
+
Medio ambiente
|
|
108
|
+
</a>
|
|
109
|
+
</li>
|
|
110
|
+
<li class="mb-xs">
|
|
111
|
+
<a class="c-link font-semibold" href="#">
|
|
112
|
+
Salud
|
|
113
|
+
</a>
|
|
114
|
+
</li>
|
|
115
|
+
<li class="mb-xs">
|
|
116
|
+
<a class="c-link font-semibold" href="#">
|
|
117
|
+
Seguridad y justicia
|
|
118
|
+
</a>
|
|
119
|
+
</li>
|
|
120
|
+
<li class="mb-xs">
|
|
121
|
+
<a class="c-link font-semibold" href="#">
|
|
122
|
+
Servicios sociales
|
|
123
|
+
</a>
|
|
124
|
+
</li>
|
|
125
|
+
<li class="mb-xs">
|
|
126
|
+
<a class="c-link font-semibold" href="#">
|
|
127
|
+
Transporte, territorio e infraestructuras
|
|
128
|
+
</a>
|
|
129
|
+
</li>
|
|
130
|
+
<li class="mb-xs">
|
|
131
|
+
<a class="c-link font-semibold" href="#">
|
|
132
|
+
Vivienda y urbanismo
|
|
133
|
+
</a>
|
|
134
|
+
</li>
|
|
135
|
+
</ul>
|
|
136
|
+
</div>
|
|
137
|
+
<div class=" flex-1 mb-sm">
|
|
138
|
+
<h3 class="c-h4 mb-base text-black">Momentos vitales</h3>
|
|
139
|
+
<ul class="relative space-y-base lg:columns-1 gap-base">
|
|
140
|
+
<li class="mb-xs">
|
|
141
|
+
<a class="c-link font-semibold" href="#">
|
|
142
|
+
Independizarse o mudarse por primera vez
|
|
143
|
+
</a>
|
|
144
|
+
</li>
|
|
145
|
+
<li class="mb-xs">
|
|
146
|
+
<a class="c-link font-semibold" href="#">
|
|
147
|
+
Buscar o mejorar el empleo
|
|
148
|
+
</a>
|
|
149
|
+
</li>
|
|
150
|
+
<li class="mb-xs">
|
|
151
|
+
<a class="c-link font-semibold" href="#">
|
|
152
|
+
Ser mayor de edad
|
|
153
|
+
</a>
|
|
154
|
+
</li>
|
|
155
|
+
<li class="mb-xs">
|
|
156
|
+
<a class="c-link font-semibold" href="#">
|
|
157
|
+
Emprender un negocio y trabajo autónomo
|
|
158
|
+
</a>
|
|
159
|
+
</li>
|
|
160
|
+
<li class="mb-xs">
|
|
161
|
+
<a class="c-link font-semibold" href="#">
|
|
162
|
+
Formalizar una relación
|
|
163
|
+
</a>
|
|
164
|
+
</li>
|
|
165
|
+
<li class="mb-xs">
|
|
166
|
+
<a class="c-link font-semibold" href="#">
|
|
167
|
+
Tener un bebé
|
|
168
|
+
</a>
|
|
169
|
+
</li>
|
|
170
|
+
<li class="mb-xs">
|
|
171
|
+
<a class="c-link font-semibold" href="#">
|
|
172
|
+
Acompañar en la primera infancia
|
|
173
|
+
</a>
|
|
174
|
+
</li>
|
|
175
|
+
<li class="mb-xs">
|
|
176
|
+
<a class="c-link font-semibold" href="#">
|
|
177
|
+
Jubilarse
|
|
178
|
+
</a>
|
|
179
|
+
</li>
|
|
180
|
+
<li class="mb-xs">
|
|
181
|
+
<a class="c-link font-semibold" href="#">
|
|
182
|
+
Cuidar de una persona en situación de dependencia y/o discapacidad
|
|
183
|
+
</a>
|
|
184
|
+
</li>
|
|
185
|
+
<li class="mb-xs">
|
|
186
|
+
<a class="c-link font-semibold" href="#">
|
|
187
|
+
Final de la vida
|
|
188
|
+
</a>
|
|
189
|
+
</li>
|
|
190
|
+
</ul>
|
|
191
|
+
</div>
|
|
192
|
+
<div class=" flex-1 mb-sm">
|
|
193
|
+
<h3 class="c-h4 mb-base text-black">Sede electrónica - Trámites</h3>
|
|
194
|
+
<ul class="relative space-y-base lg:columns-1 gap-base">
|
|
195
|
+
<li class="mb-xs">
|
|
196
|
+
<a class="c-link font-semibold" href="#1">
|
|
197
|
+
Inicio Sede electrónica - Trámites
|
|
198
|
+
</a>
|
|
199
|
+
</li>
|
|
200
|
+
<li class="mb-xs">
|
|
201
|
+
<a class="c-link font-semibold" href="#2">
|
|
202
|
+
Trámites por tema
|
|
203
|
+
</a>
|
|
204
|
+
</li>
|
|
205
|
+
<li class="mb-xs">
|
|
206
|
+
<a class="c-link font-semibold" href="#3">
|
|
207
|
+
Trámites por tipo
|
|
208
|
+
</a>
|
|
209
|
+
</li>
|
|
210
|
+
<li class="mb-xs">
|
|
211
|
+
<a class="c-link font-semibold" href="#4">
|
|
212
|
+
Servicios de la Sede electrónica
|
|
213
|
+
</a>
|
|
214
|
+
</li>
|
|
215
|
+
<li class="mb-xs">
|
|
216
|
+
<a class="c-link font-semibold" href="#5">
|
|
217
|
+
Información y ayuda
|
|
218
|
+
</a>
|
|
219
|
+
</li>
|
|
220
|
+
<li class="mb-xs">
|
|
221
|
+
<a class="c-link font-semibold" href="#6">
|
|
222
|
+
Accede a MiA, tu espacio digital<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" height="0.8em" width="0.8em" class="inline-block mx-xs no-underline align-baseline" aria-hidden="true" focusable="false" role="img"><g><path fill="currentcolor" fill-rule="evenodd" d="M7.428571428571428 0.5714285714285714c-0.6311885714285713 0 -1.1428571428571428 0.5116742857142856 -1.1428571428571428 1.1428571428571428 0 0.6311771428571428 0.5116685714285714 1.1428571428571428 1.1428571428571428 1.1428571428571428h4.098057142857143L0.9061634285714285 13.477599999999999c-0.4463131428571428 0.4462857142857143 -0.4463131428571428 1.1699428571428572 0 1.6162285714285711 0.4463165714285714 0.4462857142857143 1.1699279999999999 0.4462857142857143 1.616248 0L13.142857142857142 4.473382857142857V8.571428571428571c0 0.6311771428571428 0.5116571428571428 1.1428571428571428 1.1428571428571428 1.1428571428571428s1.1428571428571428 -0.51168 1.1428571428571428 -1.1428571428571428v-6.857142857142857c0 -0.6311828571428572 -0.5116571428571428 -1.1428571428571428 -1.1428571428571428 -1.1428571428571428h-6.857142857142857Z" clip-rule="evenodd" stroke-width="1"></path></g></svg>
|
|
223
|
+
</a>
|
|
224
|
+
</li>
|
|
225
|
+
<li class="mb-xs">
|
|
226
|
+
<a class="c-link font-semibold" href="#7">
|
|
227
|
+
Sistema Interno de Información
|
|
228
|
+
</a>
|
|
229
|
+
</li>
|
|
230
|
+
</ul>
|
|
231
|
+
</div>
|
|
232
|
+
<div class=" flex-1 mb-sm">
|
|
233
|
+
<h3 class="c-h4 mb-base text-black">Institución</h3>
|
|
234
|
+
<ul class="relative space-y-base lg:columns-1 gap-base">
|
|
235
|
+
<li class="mb-xs">
|
|
236
|
+
<a class="c-link font-semibold" href="#1">
|
|
237
|
+
Gobierno de Aragón
|
|
238
|
+
</a>
|
|
239
|
+
</li>
|
|
240
|
+
<li class="mb-xs">
|
|
241
|
+
<a class="c-link font-semibold" href="#2">
|
|
242
|
+
Estatuto de Aragón
|
|
243
|
+
</a>
|
|
244
|
+
</li>
|
|
245
|
+
<li class="mb-xs">
|
|
246
|
+
<a class="c-link font-semibold" href="#3">
|
|
247
|
+
Organismos
|
|
248
|
+
</a>
|
|
249
|
+
</li>
|
|
250
|
+
<li class="mb-xs">
|
|
251
|
+
<a class="c-link font-semibold" href="#4">
|
|
252
|
+
Municipios
|
|
253
|
+
</a>
|
|
254
|
+
</li>
|
|
255
|
+
<li class="mb-xs">
|
|
256
|
+
<a class="c-link font-semibold" href="#5">
|
|
257
|
+
Identidad comunicación corporativa
|
|
258
|
+
</a>
|
|
259
|
+
</li>
|
|
260
|
+
<li class="mb-xs">
|
|
261
|
+
<a class="c-link font-semibold" href="#6">
|
|
262
|
+
Presupuestos
|
|
263
|
+
</a>
|
|
264
|
+
</li>
|
|
265
|
+
<li class="mb-xs">
|
|
266
|
+
<a class="c-link font-semibold" href="#">
|
|
267
|
+
Cooperación transfronteriza. Acción exterior
|
|
268
|
+
</a>
|
|
269
|
+
</li>
|
|
270
|
+
</ul>
|
|
271
|
+
</div>
|
|
272
|
+
</nav>
|
|
273
|
+
|
|
274
|
+
</div>
|
|
275
|
+
</div>
|
|
276
|
+
</div>
|
|
277
|
+
{% endset %}
|
|
278
|
+
|
|
279
|
+
|
|
280
|
+
{% set examples2 = [
|
|
281
|
+
{
|
|
282
|
+
"name": "por defecto",
|
|
283
|
+
"description": "Este es el mini header por defecto. Una barra con logo del Gobierno de Aragón que enlaza al portal de la administración. Deberían usarse en todos los sitios web que tengan subdominio aragon.es.",
|
|
284
|
+
"data": {
|
|
285
|
+
}
|
|
22
286
|
},
|
|
23
287
|
{
|
|
24
|
-
"name": "con
|
|
25
|
-
"description":
|
|
288
|
+
"name": "con megamenu",
|
|
289
|
+
"description": "Usando los parámetros <code>customNavigationHtml</code> y <code>sub</code>, podemos construir un megamenú.",
|
|
26
290
|
"data": {
|
|
27
|
-
"customNavigationHtml":
|
|
291
|
+
"customNavigationHtml": customNavigation | safe,
|
|
292
|
+
"sub": {
|
|
293
|
+
"backgroundFullColor": "white",
|
|
294
|
+
"customNavigationHtml": megamenu | safe
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"name": "Sin clase contenedora",
|
|
300
|
+
"description": 'Usa el parámetro <code>"hasContainer": false</code> para que el componente no tenga container y se expanda ocupando todo el ancho posible, de forma que el logotipo quede a la derecha de la ventana y no con respecto al contenedor centrado.',
|
|
301
|
+
"data": {
|
|
302
|
+
"hasContainer": false
|
|
28
303
|
}
|
|
29
304
|
}
|
|
30
305
|
] %}
|
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
<!-- header-mini -->
|
|
2
2
|
<div {%- if params.classes %} class="{{ params.classes }}"{% endif %} {%- for attribute, value in params.attributes %} {{attribute}}="{{value}}"{% endfor %}>
|
|
3
|
+
{% if params.super %}
|
|
4
|
+
{% if params.super.customHtml %}
|
|
5
|
+
{{ params.super.customHtml | safe }}
|
|
6
|
+
{% else %}
|
|
7
|
+
<div class="{% if params.super.classes %}{{ params.super.classes }}{% else-%} bg-cover bg-center bg-no-repeat overflow-hidden{% endif %}" {%- if params.super.backgroundFullColor or params.super.backgroundFullUrl %} style="{% if params.super.backgroundFullColor %}background-color: {{ params.super.backgroundFullColor }};{% endif %} {%- if params.super.backgroundFullUrl %} background-image: url('{{ params.super.backgroundFullUrl }}'){% endif %}"{% endif %}>
|
|
8
|
+
<div class="container h-full mx-auto px-base">
|
|
9
|
+
<div class="relative h-full bg-cover bg-no-repeat" {% if params.super.backgroundContainerUrl %} style="background-image: url('{{ params.super.backgroundContainerUrl }}')"{% endif %}>
|
|
10
|
+
{{ params.super.customNavigationHtml | safe if params.super.customNavigationHtml }}
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
{% endif %}
|
|
15
|
+
{% endif %}
|
|
3
16
|
<div {%- if params.containerClasses %} class="{{ params.containerClasses }}"{% endif %}>
|
|
4
17
|
<div class="bg-white border-b border-neutral-base">
|
|
5
18
|
<div class="flex items-center px-base {% if params.hasContainer != false %}container mx-auto{% endif %}">
|
|
@@ -10,5 +23,18 @@
|
|
|
10
23
|
</div>
|
|
11
24
|
</div>
|
|
12
25
|
</div>
|
|
26
|
+
{% if params.sub %}
|
|
27
|
+
{% if params.sub.customHtml %}
|
|
28
|
+
{{ params.sub.customHtml | safe }}
|
|
29
|
+
{% else %}
|
|
30
|
+
<div class="{% if params.sub.classes %}{{ params.sub.classes }}{% else-%} bg-cover bg-center bg-no-repeat overflow-hidden{% endif %}" {%- if params.sub.backgroundFullColor or params.sub.backgroundFullUrl %} style="{% if params.sub.backgroundFullColor %}background-color: {{ params.sub.backgroundFullColor }};{% endif %} {%- if params.sub.backgroundFullUrl %} background-image: url('{{ params.sub.backgroundFullUrl }}'){% endif %}"{% endif %}>
|
|
31
|
+
<div class="container h-full mx-auto px-base">
|
|
32
|
+
<div class="relative h-full bg-cover bg-no-repeat" {% if params.sub.backgroundContainerUrl %} style="background-image: url('{{ params.sub.backgroundContainerUrl }}')"{% endif %}>
|
|
33
|
+
{{ params.sub.customNavigationHtml | safe if params.sub.customNavigationHtml }}
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
{% endif %}
|
|
38
|
+
{% endif %}
|
|
13
39
|
</div>
|
|
14
40
|
<!-- /header-mini -->
|
|
@@ -15,6 +15,62 @@ params:
|
|
|
15
15
|
type: string
|
|
16
16
|
required: false
|
|
17
17
|
description: Classes for the container, useful if you want to make the header fixed width.
|
|
18
|
+
- name: super
|
|
19
|
+
type: object
|
|
20
|
+
required: false
|
|
21
|
+
description: This is an area over the container
|
|
22
|
+
- name: customNavigationHtml
|
|
23
|
+
type: string
|
|
24
|
+
required: false
|
|
25
|
+
description: HTML for the custom navigation area. If provided there will appear an embed area where you can nest custom navigation under the logo area.
|
|
26
|
+
- name: backgroundFullColor
|
|
27
|
+
type: string
|
|
28
|
+
required: true
|
|
29
|
+
description: The css color used in the background image that fills all the super area.
|
|
30
|
+
- name: backgroundFullUrl
|
|
31
|
+
type: string
|
|
32
|
+
required: false
|
|
33
|
+
description: Url used in the background image that fills all the super area.
|
|
34
|
+
- name: backgroundContainerUrl
|
|
35
|
+
type: string
|
|
36
|
+
required: false
|
|
37
|
+
description: Url used in the background image in the container of the super area and over the backgroundFull.
|
|
38
|
+
- name: customHtml
|
|
39
|
+
type: string
|
|
40
|
+
required: false
|
|
41
|
+
description: If provided, the default super content will be replaced with this.
|
|
42
|
+
- name: classes
|
|
43
|
+
type: string
|
|
44
|
+
required: false
|
|
45
|
+
description: Classes to add to the super.
|
|
46
|
+
- name: sub
|
|
47
|
+
type: object
|
|
48
|
+
required: false
|
|
49
|
+
description: This is an area under the container
|
|
50
|
+
- name: customNavigationHtml
|
|
51
|
+
type: string
|
|
52
|
+
required: false
|
|
53
|
+
description: HTML for the custom navigation area. If provided there will appear an embed area where you can nest custom navigation under the logo area.
|
|
54
|
+
- name: backgroundFullColor
|
|
55
|
+
type: string
|
|
56
|
+
required: true
|
|
57
|
+
description: The css color used in the background image that fills all the sub area.
|
|
58
|
+
- name: backgroundFullUrl
|
|
59
|
+
type: string
|
|
60
|
+
required: false
|
|
61
|
+
description: Url used in the background image that fills all the sub area.
|
|
62
|
+
- name: backgroundContainerUrl
|
|
63
|
+
type: string
|
|
64
|
+
required: false
|
|
65
|
+
description: Url used in the background image in the container of the sub area and over the backgroundFull.
|
|
66
|
+
- name: customHtml
|
|
67
|
+
type: string
|
|
68
|
+
required: false
|
|
69
|
+
description: If provided, the default sub content will be replaced with this.
|
|
70
|
+
- name: classes
|
|
71
|
+
type: string
|
|
72
|
+
required: false
|
|
73
|
+
description: Classes to add to the sub.
|
|
18
74
|
- name: classes
|
|
19
75
|
type: string
|
|
20
76
|
required: false
|