@openeuropa/bcl-theme-default 0.4298.202511051800 → 0.4360.202601141610

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.
Files changed (114) hide show
  1. package/css/oe-bcl-ckeditor5.min.css +1 -1
  2. package/css/oe-bcl-ckeditor5.min.css.map +1 -1
  3. package/css/oe-bcl-default.css +167 -85
  4. package/css/oe-bcl-default.css.map +1 -1
  5. package/css/oe-bcl-default.min.css +1 -1
  6. package/css/oe-bcl-default.min.css.map +1 -1
  7. package/js/oe-bcl-default.bundle.js +112 -1
  8. package/js/oe-bcl-default.bundle.js.map +1 -1
  9. package/js/oe-bcl-default.bundle.min.js +1 -1
  10. package/js/oe-bcl-default.bundle.min.js.map +1 -1
  11. package/js/oe-bcl-default.esm.js +111 -1
  12. package/js/oe-bcl-default.esm.js.map +1 -1
  13. package/js/oe-bcl-default.esm.min.js +1 -1
  14. package/js/oe-bcl-default.esm.min.js.map +1 -1
  15. package/js/oe-bcl-default.umd.js +112 -1
  16. package/js/oe-bcl-default.umd.js.map +1 -1
  17. package/js/oe-bcl-default.umd.min.js +1 -1
  18. package/js/oe-bcl-default.umd.min.js.map +1 -1
  19. package/package.json +5 -5
  20. package/src/js/header/header.js +91 -0
  21. package/src/js/index.esm.js +2 -0
  22. package/src/js/index.umd.js +2 -0
  23. package/src/js/mega-menu/mega-menu.js +57 -0
  24. package/src/scss/_header.scss +6 -2
  25. package/src/scss/_input.scss +72 -31
  26. package/src/scss/_mega-menu.scss +57 -58
  27. package/src/scss/_multiselect-2.scss +21 -11
  28. package/src/scss/_pagination.scss +1 -0
  29. package/src/scss/_search-form.scss +4 -0
  30. package/src/scss/base/_colors.scss +1 -0
  31. package/src/scss/base/_mixins.scss +12 -0
  32. package/templates/bcl-accordion/accordion.html.twig +42 -46
  33. package/templates/bcl-alert/alert.html.twig +18 -21
  34. package/templates/bcl-badge/badge.html.twig +11 -15
  35. package/templates/bcl-banner/banner.html.twig +34 -37
  36. package/templates/bcl-base-templates/content-type.html.twig +63 -67
  37. package/templates/bcl-base-templates/listing-page.html.twig +31 -31
  38. package/templates/bcl-base-templates/sidebar-search.html.twig +10 -10
  39. package/templates/bcl-blockquote/blockquote.html.twig +17 -20
  40. package/templates/bcl-breadcrumb/breadcrumb.html.twig +24 -28
  41. package/templates/bcl-button/button.html.twig +24 -27
  42. package/templates/bcl-button-group/button-group.html.twig +25 -29
  43. package/templates/bcl-card/card.html.twig +98 -101
  44. package/templates/bcl-card-layout/card-layout.html.twig +34 -37
  45. package/templates/bcl-carousel/carousel.html.twig +64 -67
  46. package/templates/bcl-contact-form/contact-form.html.twig +1 -1
  47. package/templates/bcl-content-banner/content-banner.html.twig +37 -40
  48. package/templates/bcl-date-block/date-block.html.twig +26 -29
  49. package/templates/bcl-description-list/description-list-details.html.twig +6 -9
  50. package/templates/bcl-description-list/description-list-title.html.twig +11 -14
  51. package/templates/bcl-description-list/description-list.html.twig +44 -48
  52. package/templates/bcl-dropdown/dropdown.html.twig +48 -52
  53. package/templates/bcl-event/event.html.twig +7 -7
  54. package/templates/bcl-fact-figures/fact-figures.html.twig +34 -37
  55. package/templates/bcl-featured-media/featured-media.html.twig +42 -46
  56. package/templates/bcl-file/file-translations.html.twig +29 -32
  57. package/templates/bcl-file/file.html.twig +47 -50
  58. package/templates/bcl-footer/footer.html.twig +31 -34
  59. package/templates/bcl-form/form.html.twig +70 -73
  60. package/templates/bcl-form-input/form-input.html.twig +57 -61
  61. package/templates/bcl-gallery/gallery-item.html.twig +20 -23
  62. package/templates/bcl-gallery/gallery.html.twig +62 -66
  63. package/templates/bcl-glossary/glossary-detail.html.twig +19 -19
  64. package/templates/bcl-glossary/glossary-listing.html.twig +6 -6
  65. package/templates/bcl-group/group-landing.html.twig +69 -69
  66. package/templates/bcl-group/group.html.twig +19 -19
  67. package/templates/bcl-header/header.html.twig +71 -82
  68. package/templates/bcl-heading/heading.html.twig +13 -17
  69. package/templates/bcl-icon/icon.html.twig +10 -13
  70. package/templates/bcl-inpage-navigation/inpage-navigation.html.twig +20 -23
  71. package/templates/bcl-landing-page/landing-page.html.twig +33 -33
  72. package/templates/bcl-language-list/language-list-grid.html.twig +25 -28
  73. package/templates/bcl-language-list/language-list-modal.html.twig +52 -52
  74. package/templates/bcl-language-list/language-list.html.twig +33 -37
  75. package/templates/bcl-language-switcher/language-switcher.html.twig +12 -15
  76. package/templates/bcl-link/link.html.twig +24 -27
  77. package/templates/bcl-links-block/links-block.html.twig +30 -34
  78. package/templates/bcl-list-group/list-group.html.twig +43 -47
  79. package/templates/bcl-listing/listing.html.twig +88 -91
  80. package/templates/bcl-mega-menu/mega-menu-items.html.twig +18 -21
  81. package/templates/bcl-mega-menu/mega-menu-submenu.html.twig +28 -26
  82. package/templates/bcl-mega-menu/mega-menu.html.twig +37 -38
  83. package/templates/bcl-modal/modal.html.twig +21 -23
  84. package/templates/bcl-navbar/navbar.html.twig +35 -38
  85. package/templates/bcl-navigation/navigation.html.twig +105 -110
  86. package/templates/bcl-offcanvas/offcanvas.html.twig +33 -36
  87. package/templates/bcl-page/page.html.twig +27 -27
  88. package/templates/bcl-pagination/pagination-item.html.twig +22 -26
  89. package/templates/bcl-pagination/pagination.html.twig +59 -62
  90. package/templates/bcl-pagination-v2/pagination-item.html.twig +31 -35
  91. package/templates/bcl-pagination-v2/pagination.html.twig +79 -82
  92. package/templates/bcl-person/person.html.twig +12 -12
  93. package/templates/bcl-placeholder/placeholder.html.twig +14 -18
  94. package/templates/bcl-progress/progress.html.twig +16 -20
  95. package/templates/bcl-project/project-lists.html.twig +25 -29
  96. package/templates/bcl-project/project.html.twig +35 -35
  97. package/templates/bcl-project-status/project-contributions.html.twig +25 -28
  98. package/templates/bcl-project-status/project-status.html.twig +32 -37
  99. package/templates/bcl-recent-activities/recent-activities.html.twig +13 -16
  100. package/templates/bcl-search/search.html.twig +12 -12
  101. package/templates/bcl-search-form/search-form.html.twig +21 -24
  102. package/templates/bcl-select/select.html.twig +52 -56
  103. package/templates/bcl-spinner/spinner.html.twig +10 -13
  104. package/templates/bcl-subscription/subscription-modal.html.twig +7 -7
  105. package/templates/bcl-subscription/subscription.html.twig +3 -3
  106. package/templates/bcl-subscription-block/subscription-block.html.twig +14 -17
  107. package/templates/bcl-table/table.html.twig +61 -65
  108. package/templates/bcl-textarea/textarea.html.twig +44 -47
  109. package/templates/bcl-timeline/timeline-item.html.twig +12 -15
  110. package/templates/bcl-timeline/timeline.html.twig +42 -45
  111. package/templates/bcl-toasts/toasts.html.twig +56 -60
  112. package/templates/bcl-user/user-compact.html.twig +24 -27
  113. package/templates/bcl-user/user-terms.html.twig +6 -6
  114. package/templates/bcl-user/user.html.twig +117 -117
@@ -1,111 +1,111 @@
1
1
  {% extends "@oe-bcl/bcl-modal/modal.html.twig" %}
2
2
 
3
- {% if _title is not empty %}
4
- {% set header = true %}
3
+ {%- if _title is not empty %}
4
+ {%- set header = true %}
5
5
  {% endif %}
6
6
 
7
- {% if _variant == 'neutral' %}
8
- {% set size = "xl" %}
9
- {% set fullscreen_responsive = "md" %}
7
+ {%- if _variant == 'neutral' %}
8
+ {%- set size = "xl" %}
9
+ {%- set fullscreen_responsive = "md" %}
10
10
  {% else %}
11
- {% set size = "fullscreen" %}
11
+ {%- set size = "fullscreen" %}
12
12
  {% endif %}
13
13
 
14
- {% set overlay = false %}
14
+ {%- set overlay = false %}
15
15
  {% set inside_container = true %}
16
16
 
17
- {% set attributes = attributes.addClass(['bcl-language-list-modal', 'bcl-language-list-modal--' ~ _variant]) %}
17
+ {%- set attributes = attributes.addClass(['bcl-language-list-modal', 'bcl-language-list-modal--' ~ _variant]) %}
18
18
 
19
- {% block header %}
20
- {% if size == 'fullscreen' %}
19
+ {%- block header %}
20
+ {%- if size == 'fullscreen' -%}
21
21
  <div class="container">
22
- {% if _variant == 'eu' or _variant == 'ec' %}
23
- <div class="border-bottom mx-n3 px-3 px-md-0 pt-md-4-5">
22
+ {%- if _variant == 'eu' or _variant == 'ec' -%}
23
+ <div class="border-bottom mx-n3 px-3 px-md-0 pt-md-4-5">{# -#}
24
24
  <div class="py-3-5 px-3 px-sm-0 px-md-3">
25
- {% endif %}
25
+ {%- endif -%}
26
26
  <div class="d-flex justify-content-between align-items-center">
27
- {% endif %}
27
+ {%- endif -%}
28
28
  <div class="d-flex align-items-center">
29
- {% set _title_classes = 'modal-title mb-0' %}
30
- {% if _icon_path is not empty %}
31
- {% set _title_classes = _title_classes ~ ' ms-2' %}
32
- {% include '@oe-bcl/bcl-icon/icon.html.twig' with {
29
+ {%- set _title_classes = 'modal-title mb-0' %}
30
+ {%- if _icon_path is not empty %}
31
+ {%- set _title_classes = _title_classes ~ ' ms-2' %}
32
+ {%- include '@oe-bcl/bcl-icon/icon.html.twig' with {
33
33
  name: 'globe2',
34
34
  path: _icon_path
35
35
  } only %}
36
- {% endif %}
37
- <div class="{{ _title_classes }}">{{ _title }}</div>
38
- </div>
36
+ {%- endif -%}
37
+ <div class="{{ _title_classes }}">{{ _title }}</div>{# -#}
38
+ </div>{# -#}
39
39
  <button type="button" class="btn-close" data-bs-dismiss="modal"
40
40
  {% if _close_label is not empty %}
41
41
  aria-label="{{ _close_label }}"
42
42
  {% endif %}
43
43
  ></button>
44
- {% if size == 'fullscreen' %}
44
+ {%- if size == 'fullscreen' -%}
45
45
  </div>
46
- {% if _variant == 'eu' or _variant == 'ec' %}
47
- </div>
46
+ {%- if _variant == 'eu' or _variant == 'ec' -%}
47
+ </div>{# -#}
48
48
  </div>
49
- {% endif %}
49
+ {%- endif -%}
50
50
  </div>
51
- {% endif %}
51
+ {%- endif %}
52
52
  {% endblock %}
53
53
 
54
- {% block body %}
55
- {% set attributes = create_attribute().addClass(['bcl-language-list', 'bcl-language-list--' ~ _variant]) %}
54
+ {%- block body %}
55
+ {%- set attributes = create_attribute().addClass(['bcl-language-list', 'bcl-language-list--' ~ _variant]) -%}
56
56
  <div
57
57
  {{ attributes }}
58
58
  >
59
- {% if _logo is not empty %}
59
+ {%- if _logo is not empty -%}
60
60
  <div class="container">
61
- {% if _title is empty %}
61
+ {%- if _title is empty -%}
62
62
  <div class="text-center">
63
- {% endif %}
64
- <div class="d-inline-flex align-items-center">
63
+ {%- endif -%}
64
+ <div class="d-inline-flex align-items-center">{# -#}
65
65
  <img
66
66
  {% if _logo.path is not empty %}
67
67
  src="{{ _logo.path }}"
68
68
  {% endif %}
69
- {% if _logo.alt is not empty %}
69
+ {%- if _logo.alt is not empty %}
70
70
  alt="{{ _logo.alt }}"
71
71
  {% endif %}
72
- {% if _logo.class is not empty %}
72
+ {%- if _logo.class is not empty %}
73
73
  class="{{ _logo.class }}"
74
74
  {% endif %}
75
75
  />
76
- {% if _title is not empty %}
76
+ {%- if _title is not empty -%}
77
77
  <h5 class="h5 ms-4">{{ _title }}</h5>
78
- {% endif %}
78
+ {%- endif -%}
79
79
  </div>
80
- {% if _title is empty %}
80
+ {%- if _title is empty -%}
81
81
  </div>
82
- {% endif %}
82
+ {%- endif -%}
83
83
  </div>
84
- {% endif %}
84
+ {%- endif %}
85
85
 
86
- {% if _items is not empty or _non_eu_items is not empty %}
86
+ {%- if _items is not empty or _non_eu_items is not empty -%}
87
87
  <div class="main pt-4">
88
- {% if not (_variant == 'neutral' and _inside_container) %}
88
+ {%- if not (_variant == 'neutral' and _inside_container) -%}
89
89
  <div class="container">
90
- {% endif %}
91
- {% if _items is not empty and _items is iterable %}
92
- {% include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
90
+ {%- endif %}
91
+ {%- if _items is not empty and _items is iterable %}
92
+ {%- include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
93
93
  items: _items,
94
94
  icon_path: _icon_path,
95
95
  category: eu_category,
96
96
  } only %}
97
- {% endif %}
98
- {% if _non_eu_items is not empty and _non_eu_items is iterable %}
99
- {% include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
97
+ {%- endif %}
98
+ {%- if _non_eu_items is not empty and _non_eu_items is iterable %}
99
+ {%- include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
100
100
  items: _non_eu_items,
101
101
  icon_path: _icon_path,
102
102
  category: non_eu_category,
103
103
  } only %}
104
- {% endif %}
105
- {% if not (_variant == 'neutral' and _inside_container) %}
104
+ {%- endif %}
105
+ {%- if not (_variant == 'neutral' and _inside_container) -%}
106
106
  </div>
107
- {% endif %}
107
+ {%- endif -%}
108
108
  </div>
109
- {% endif %}
109
+ {%- endif -%}
110
110
  </div>
111
- {% endblock %}
111
+ {%- endblock %}
@@ -1,5 +1,3 @@
1
- {% apply spaceless %}
2
-
3
1
  {# Parameters:
4
2
  - overlay (boolean) (default: false)
5
3
  - inside_container (boolean) (default: false)
@@ -26,7 +24,7 @@
26
24
  - close_label (string) (default: '')
27
25
  #}
28
26
 
29
- {% set _overlay = overlay ?? false %}
27
+ {%- set _overlay = overlay ?? false %}
30
28
  {% set _inside_container = inside_container ?? false %}
31
29
  {% set _variant = variant|default('neutral') %}
32
30
  {% set _title = title|default('') %}
@@ -38,74 +36,72 @@
38
36
  {% set _non_eu_items = non_eu_items|default([]) %}
39
37
  {% set _close_label = close_label|default('') %}
40
38
 
41
- {% if attributes is empty %}
42
- {% set attributes = create_attribute() %}
39
+ {%- if attributes is empty %}
40
+ {%- set attributes = create_attribute() %}
43
41
  {% endif %}
44
42
 
45
- {% if _overlay %}
46
- {% include '@oe-bcl/bcl-language-list/language-list-modal.html.twig' %}
43
+ {%- if _overlay %}
44
+ {%- include '@oe-bcl/bcl-language-list/language-list-modal.html.twig' %}
47
45
  {% else %}
48
- {% set attributes = attributes.addClass(['bcl-language-list', 'bcl-language-list--' ~ _variant]) %}
46
+ {%- set attributes = attributes.addClass(['bcl-language-list', 'bcl-language-list--' ~ _variant]) %}
49
47
 
50
- {% if not _inside_container %}
51
- {% set attributes = attributes.addClass(['pt-5']) %}
52
- {% endif %}
48
+ {%- if not _inside_container %}
49
+ {%- set attributes = attributes.addClass(['pt-5']) %}
50
+ {%- endif -%}
53
51
 
54
52
  <div
55
53
  {{ attributes }}
56
54
  >
57
- {% if _logo is not empty %}
55
+ {%- if _logo is not empty -%}
58
56
  <div class="container">
59
- {% if _title is empty %}
57
+ {%- if _title is empty -%}
60
58
  <div class="text-center">
61
- {% endif %}
62
- <div class="d-inline-flex align-items-center">
59
+ {%- endif -%}
60
+ <div class="d-inline-flex align-items-center">{# -#}
63
61
  <img
64
62
  {% if _logo.path is not empty %}
65
63
  src="{{ _logo.path }}"
66
64
  {% endif %}
67
- {% if _logo.alt is not empty %}
65
+ {%- if _logo.alt is not empty %}
68
66
  alt="{{ _logo.alt }}"
69
67
  {% endif %}
70
- {% if _logo.class is not empty %}
68
+ {%- if _logo.class is not empty %}
71
69
  class="{{ _logo.class }}"
72
70
  {% endif %}
73
71
  />
74
- {% if _title is not empty %}
72
+ {%- if _title is not empty -%}
75
73
  <h5 class="h5 ms-4">{{ _title }}</h5>
76
- {% endif %}
74
+ {%- endif -%}
77
75
  </div>
78
- {% if _title is empty %}
76
+ {%- if _title is empty -%}
79
77
  </div>
80
- {% endif %}
78
+ {%- endif -%}
81
79
  </div>
82
- {% endif %}
80
+ {%- endif %}
83
81
 
84
- {% if _items is not empty or _non_eu_items is not empty %}
82
+ {%- if _items is not empty or _non_eu_items is not empty -%}
85
83
  <div class="main pt-4">
86
- {% if not (_variant == 'neutral' and _inside_container) %}
84
+ {%- if not (_variant == 'neutral' and _inside_container) -%}
87
85
  <div class="container">
88
- {% endif %}
89
- {% if _items is not empty and _items is iterable %}
90
- {% include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
86
+ {%- endif %}
87
+ {%- if _items is not empty and _items is iterable %}
88
+ {%- include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
91
89
  items: _items,
92
90
  icon_path: _icon_path,
93
91
  category: eu_category,
94
92
  } only %}
95
- {% endif %}
96
- {% if _non_eu_items is not empty and _non_eu_items is iterable %}
97
- {% include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
93
+ {%- endif %}
94
+ {%- if _non_eu_items is not empty and _non_eu_items is iterable %}
95
+ {%- include '@oe-bcl/bcl-language-list/language-list-grid.html.twig' with {
98
96
  items: _non_eu_items,
99
97
  icon_path: _icon_path,
100
98
  category: non_eu_category,
101
99
  } only %}
102
- {% endif %}
103
- {% if not (_variant == 'neutral' and _inside_container) %}
100
+ {%- endif %}
101
+ {%- if not (_variant == 'neutral' and _inside_container) -%}
104
102
  </div>
105
- {% endif %}
103
+ {%- endif -%}
106
104
  </div>
107
- {% endif %}
105
+ {%- endif -%}
108
106
  </div>
109
- {% endif %}
110
-
111
- {% endapply %}
107
+ {%- endif -%}
@@ -1,5 +1,3 @@
1
- {% apply spaceless %}
2
-
3
1
  {# Parameters:
4
2
  - id (string) (default: collapse-random(10000), optional)
5
3
  - message (alert object) (default: {})
@@ -7,14 +5,14 @@
7
5
  - languages (link[]) (default: [])
8
6
  #}
9
7
 
10
- {% set _id = id|default('collapse-' ~ random(10000)) %}
8
+ {%- set _id = id|default('collapse-' ~ random(10000)) %}
11
9
  {% set _message = message|default({}) %}
12
10
  {% set _expandable = expandable|default({}) %}
13
11
  {% set _languages = languages|default([]) %}
14
12
 
15
- {% set _expandable_attributes = _expandable.attributes ?: create_attribute() %}
13
+ {%- set _expandable_attributes = _expandable.attributes ?: create_attribute() %}
16
14
 
17
- {% set _expandable_attributes = _expandable_attributes
15
+ {%- set _expandable_attributes = _expandable_attributes
18
16
  .setAttribute('data-bs-toggle', 'collapse')
19
17
  .setAttribute('autocomplete', 'off')
20
18
  .setAttribute('aria-expanded', 'false')
@@ -22,19 +20,19 @@
22
20
  .setAttribute('data-bs-target', '#' ~ _id)
23
21
  %}
24
22
 
25
- {% include '@oe-bcl/bcl-alert/alert.html.twig' with _message only %}
23
+ {%- include '@oe-bcl/bcl-alert/alert.html.twig' with _message only %}
26
24
 
27
- {% include '@oe-bcl/bcl-button/button.html.twig' with _expandable|merge({
25
+ {%- include '@oe-bcl/bcl-button/button.html.twig' with _expandable|merge({
28
26
  attributes: _expandable_attributes
29
- }) only %}
27
+ }) only -%}
30
28
 
31
- <div class="collapse mt-3" id="{{ _id }}">
29
+ <div class="collapse mt-3" id="{{ _id }}">{# -#}
32
30
  <div
33
31
  class="d-grid"
34
32
  style="grid-auto-flow: row; grid-template-columns: repeat(auto-fit, minmax(4rem, 8rem))"
35
33
  >
36
- {% for language in languages %}
37
- {% include '@oe-bcl/bcl-link/link.html.twig' with language|merge({
34
+ {%- for language in languages %}
35
+ {%- include '@oe-bcl/bcl-link/link.html.twig' with language|merge({
38
36
  attributes: create_attribute().addClass(
39
37
  [ "btn",
40
38
  "btn-link",
@@ -43,8 +41,7 @@
43
41
  "text-start"
44
42
  ])
45
43
  }) only %}
46
- {% endfor %}
47
- </div>
44
+ {%- endfor -%}
45
+ </div>{# -#}
48
46
  </div>
49
-
50
- {% endapply %}
47
+ {#--#}
@@ -1,5 +1,3 @@
1
- {% apply spaceless %}
2
-
3
1
  {# Parameters:
4
2
  - label (string) (default: '')
5
3
  - path (string) (default: '#')
@@ -15,7 +13,7 @@
15
13
  - attributes (drupal attrs)
16
14
  #}
17
15
 
18
- {% set _label = label|default('') %}
16
+ {%- set _label = label|default('') %}
19
17
  {% set _path = path|default('#') %}
20
18
  {% set _variant = variant|default('') %}
21
19
  {% set _id = id|default('') %}
@@ -25,54 +23,54 @@
25
23
  {% set _icon_position = icon_position|default('after') %}
26
24
  {% set _remove_icon_spacers = remove_icon_spacers ?? false %}
27
25
 
28
- {% set _classes = [] %}
26
+ {%- set _classes = [] %}
29
27
 
30
- {% if _icon is not empty %}
31
- {% if _label is not empty and not _remove_icon_spacers %}
32
- {% if _icon.attributes is empty %}
33
- {% set _icon = _icon|merge({
28
+ {%- if _icon is not empty %}
29
+ {%- if _label is not empty and not _remove_icon_spacers %}
30
+ {%- if _icon.attributes is empty %}
31
+ {%- set _icon = _icon|merge({
34
32
  attributes: create_attribute()
35
33
  })
36
34
  %}
37
- {% endif %}
38
- {% if _icon_position == 'before' %}
39
- {% set _icon = _icon|merge({
35
+ {%- endif %}
36
+ {%- if _icon_position == 'before' %}
37
+ {%- set _icon = _icon|merge({
40
38
  attributes: _icon.attributes.addClass('me-2-5')
41
39
  })
42
40
  %}
43
- {% else %}
44
- {% set _icon = _icon|merge({
41
+ {%- else %}
42
+ {%- set _icon = _icon|merge({
45
43
  attributes: _icon.attributes.addClass('ms-2-5')
46
44
  })
47
45
  %}
48
- {% endif %}
49
- {% endif %}
46
+ {%- endif %}
47
+ {%- endif %}
50
48
  {%- set _icon_markup -%}
51
49
  {%- include '@oe-bcl/bcl-icon/icon.html.twig' with _icon only -%}
52
50
  {%- endset -%}
53
51
  {% endif %}
54
52
 
55
- {% if attributes is empty %}
56
- {% set attributes = create_attribute() %}
53
+ {%- if attributes is empty %}
54
+ {%- set attributes = create_attribute() %}
57
55
  {% endif %}
58
56
 
59
- {% if _disabled %}
60
- {% set _classes = _classes|merge(['disabled']) %}
61
- {% set attributes = attributes.setAttribute('aria-disabled', 'true').setAttribute('tabindex', '-1') %}
57
+ {%- if _disabled %}
58
+ {%- set _classes = _classes|merge(['disabled']) %}
59
+ {%- set attributes = attributes.setAttribute('aria-disabled', 'true').setAttribute('tabindex', '-1') %}
62
60
  {% endif %}
63
61
  {% if _variant is not empty %}
64
- {% set _classes = _classes|merge(['link-' ~ _variant]) %}
62
+ {%- set _classes = _classes|merge(['link-' ~ _variant]) %}
65
63
  {% endif %}
66
64
  {% if _id is not empty %}
67
- {% set attributes = attributes.setAttribute('id', _id) %}
65
+ {%- set attributes = attributes.setAttribute('id', _id) %}
68
66
  {% endif %}
69
67
  {% if _standalone %}
70
- {% set _classes = _classes|merge(['standalone']) %}
68
+ {%- set _classes = _classes|merge(['standalone']) %}
71
69
  {% endif %}
72
70
  {% if _classes is not empty %}
73
- {% set attributes = attributes.addClass(_classes) %}
71
+ {%- set attributes = attributes.addClass(_classes) %}
74
72
  {% endif %}
75
- {% set attributes = attributes.setAttribute('href', _path) %}
73
+ {% set attributes = attributes.setAttribute('href', _path) -%}
76
74
 
77
75
  <a
78
76
  {{ attributes }}
@@ -85,5 +83,4 @@
85
83
  {{ _icon_markup }}
86
84
  {%- endif -%}
87
85
  </a>
88
-
89
- {% endapply %}
86
+ {#--#}
@@ -1,5 +1,3 @@
1
- {% apply spaceless %}
2
-
3
1
  {# Parameters:
4
2
  - title: (string) (default: '')
5
3
  - title_tag: (string) (default: 'h2')
@@ -13,64 +11,62 @@
13
11
  - attributes (drupal attrs)
14
12
  #}
15
13
 
16
- {% set _title = title|default('') %}
14
+ {%- set _title = title|default('') %}
17
15
  {% set _title_tag = title_tag|default('h2') %}
18
16
  {% set _title_link = title_link|default({}) %}
19
17
  {% set _title_attributes = title_attributes ?: create_attribute() %}
20
18
  {% set _background = background|default('gray') %}
21
19
  {% set _variant = variant|default('vertical') %}
22
- {% set _links = links|default([])%}
20
+ {% set _links = links|default([]) %}
23
21
 
24
- {% set _classes = ['bcl-links-block'] %}
22
+ {%- set _classes = ['bcl-links-block'] %}
25
23
 
26
- {% set _title_classes = ['pb-3', 'mb-3', 'border-bottom'] %}
24
+ {%- set _title_classes = ['pb-3', 'mb-3', 'border-bottom'] %}
27
25
 
28
- {% if attributes is empty %}
29
- {% set attributes = create_attribute() %}
26
+ {%- if attributes is empty %}
27
+ {%- set attributes = create_attribute() %}
30
28
  {% endif %}
31
29
 
32
- {% if _background == 'gray' %}
33
- {% set attributes = attributes.addClass(['bg-light', 'px-4', 'py-3', 'rounded-2']) %}
30
+ {%- if _background == 'gray' %}
31
+ {%- set attributes = attributes.addClass(['bg-light', 'px-4', 'py-3', 'rounded-2']) %}
34
32
  {% endif %}
35
33
 
36
- {% set attributes = attributes.addClass(_classes) %}
34
+ {%- set attributes = attributes.addClass(_classes) %}
37
35
 
38
- {% if _links is not empty and _links is iterable %}
36
+ {%- if _links is not empty and _links is iterable -%}
39
37
  <div
40
38
  {{ attributes }}
41
39
  >
42
- {% if _title is not empty %}
43
- {% include '@oe-bcl/bcl-heading/heading.html.twig' with {
40
+ {%- if _title is not empty %}
41
+ {%- include '@oe-bcl/bcl-heading/heading.html.twig' with {
44
42
  title: _title,
45
43
  title_tag: _title_tag,
46
44
  title_link: _title_link,
47
45
  attributes: _title_attributes.addClass(_title_classes),
48
46
  } only %}
49
- {% endif %}
47
+ {%- endif -%}
50
48
  <ul class="ps-0 mb-0">
51
- {% for _link in _links %}
52
- {% if _link.attributes is empty %}
53
- {% set _link = _link|merge({
49
+ {%- for _link in _links %}
50
+ {%- if _link.attributes is empty %}
51
+ {%- set _link = _link|merge({
54
52
  attributes: create_attribute()
55
53
  }) %}
56
- {% endif %}
57
- {% set _link = _link|merge({
54
+ {%- endif %}
55
+ {%- set _link = _link|merge({
58
56
  clean_class: true,
59
- attributes: _link.attributes.addClass(['pb-3', 'd-inline-block', 'standalone'])
57
+ attributes: _link.attributes.addClass(['mb-3', 'd-inline-block', 'standalone'])
60
58
  }) %}
61
- {% set _list_item_classes = 'list-unstyled' %}
62
- {% if _variant == 'horizontal' %}
63
- {% set _list_item_classes = _list_item_classes ~ ' d-inline' %}
64
- {% endif %}
65
- {% if loop.last == false %}
66
- {% set _list_item_classes = _list_item_classes ~ ' me-4-5' %}
67
- {% endif %}
59
+ {%- set _list_item_classes = 'list-unstyled' %}
60
+ {%- if _variant == 'horizontal' %}
61
+ {%- set _list_item_classes = _list_item_classes ~ ' d-inline' %}
62
+ {%- endif %}
63
+ {%- if loop.last == false %}
64
+ {%- set _list_item_classes = _list_item_classes ~ ' me-4-5' %}
65
+ {%- endif -%}
68
66
  <li class="{{ _list_item_classes }}">
69
- {% include '@oe-bcl/bcl-link/link.html.twig' with _link only %}
67
+ {%- include '@oe-bcl/bcl-link/link.html.twig' with _link only -%}
70
68
  </li>
71
- {% endfor %}
72
- </ul>
69
+ {%- endfor -%}
70
+ </ul>{# -#}
73
71
  </div>
74
- {% endif %}
75
-
76
- {% endapply %}
72
+ {%- endif -%}