@openeuropa/bcl-theme-joinup 1.8.0 → 1.9.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.
Files changed (107) hide show
  1. package/bcl-builder.config.js +8 -3
  2. package/css/oe-bcl-joinup.css +416 -356
  3. package/css/oe-bcl-joinup.css.map +1 -1
  4. package/css/oe-bcl-joinup.min.css +1 -1
  5. package/css/oe-bcl-joinup.min.css.map +1 -1
  6. package/fonts/cyrillic-400-italic.css +3 -4
  7. package/fonts/cyrillic-400.css +3 -4
  8. package/fonts/cyrillic-500-italic.css +3 -4
  9. package/fonts/cyrillic-500.css +3 -4
  10. package/fonts/cyrillic-700-italic.css +3 -4
  11. package/fonts/cyrillic-700.css +3 -4
  12. package/fonts/cyrillic-ext-400-italic.css +3 -4
  13. package/fonts/cyrillic-ext-400.css +3 -4
  14. package/fonts/cyrillic-ext-500-italic.css +3 -4
  15. package/fonts/cyrillic-ext-500.css +3 -4
  16. package/fonts/cyrillic-ext-700-italic.css +3 -4
  17. package/fonts/cyrillic-ext-700.css +3 -4
  18. package/fonts/files/roboto-cyrillic-400-italic.woff +0 -0
  19. package/fonts/files/roboto-cyrillic-400-italic.woff2 +0 -0
  20. package/fonts/files/roboto-cyrillic-400-normal.woff +0 -0
  21. package/fonts/files/roboto-cyrillic-400-normal.woff2 +0 -0
  22. package/fonts/files/roboto-cyrillic-500-italic.woff +0 -0
  23. package/fonts/files/roboto-cyrillic-500-italic.woff2 +0 -0
  24. package/fonts/files/roboto-cyrillic-500-normal.woff +0 -0
  25. package/fonts/files/roboto-cyrillic-500-normal.woff2 +0 -0
  26. package/fonts/files/roboto-cyrillic-700-italic.woff +0 -0
  27. package/fonts/files/roboto-cyrillic-700-italic.woff2 +0 -0
  28. package/fonts/files/roboto-cyrillic-700-normal.woff +0 -0
  29. package/fonts/files/roboto-cyrillic-700-normal.woff2 +0 -0
  30. package/fonts/files/roboto-greek-400-italic.woff +0 -0
  31. package/fonts/files/roboto-greek-400-italic.woff2 +0 -0
  32. package/fonts/files/roboto-greek-400-normal.woff +0 -0
  33. package/fonts/files/roboto-greek-400-normal.woff2 +0 -0
  34. package/fonts/files/roboto-greek-500-italic.woff +0 -0
  35. package/fonts/files/roboto-greek-500-italic.woff2 +0 -0
  36. package/fonts/files/roboto-greek-500-normal.woff +0 -0
  37. package/fonts/files/roboto-greek-500-normal.woff2 +0 -0
  38. package/fonts/files/roboto-greek-700-italic.woff +0 -0
  39. package/fonts/files/roboto-greek-700-italic.woff2 +0 -0
  40. package/fonts/files/roboto-greek-700-normal.woff +0 -0
  41. package/fonts/files/roboto-greek-700-normal.woff2 +0 -0
  42. package/fonts/files/roboto-latin-400-italic.woff +0 -0
  43. package/fonts/files/roboto-latin-400-italic.woff2 +0 -0
  44. package/fonts/files/roboto-latin-400-normal.woff +0 -0
  45. package/fonts/files/roboto-latin-400-normal.woff2 +0 -0
  46. package/fonts/files/roboto-latin-500-italic.woff +0 -0
  47. package/fonts/files/roboto-latin-500-italic.woff2 +0 -0
  48. package/fonts/files/roboto-latin-500-normal.woff +0 -0
  49. package/fonts/files/roboto-latin-500-normal.woff2 +0 -0
  50. package/fonts/files/roboto-latin-700-italic.woff +0 -0
  51. package/fonts/files/roboto-latin-700-italic.woff2 +0 -0
  52. package/fonts/files/roboto-latin-700-normal.woff +0 -0
  53. package/fonts/files/roboto-latin-700-normal.woff2 +0 -0
  54. package/fonts/files/roboto-latin-ext-400-italic.woff +0 -0
  55. package/fonts/files/roboto-latin-ext-400-italic.woff2 +0 -0
  56. package/fonts/files/roboto-latin-ext-400-normal.woff +0 -0
  57. package/fonts/files/roboto-latin-ext-400-normal.woff2 +0 -0
  58. package/fonts/files/roboto-latin-ext-500-italic.woff +0 -0
  59. package/fonts/files/roboto-latin-ext-500-italic.woff2 +0 -0
  60. package/fonts/files/roboto-latin-ext-500-normal.woff +0 -0
  61. package/fonts/files/roboto-latin-ext-500-normal.woff2 +0 -0
  62. package/fonts/files/roboto-latin-ext-700-italic.woff +0 -0
  63. package/fonts/files/roboto-latin-ext-700-italic.woff2 +0 -0
  64. package/fonts/files/roboto-latin-ext-700-normal.woff +0 -0
  65. package/fonts/files/roboto-latin-ext-700-normal.woff2 +0 -0
  66. package/fonts/greek-400-italic.css +3 -4
  67. package/fonts/greek-400.css +3 -4
  68. package/fonts/greek-500-italic.css +3 -4
  69. package/fonts/greek-500.css +3 -4
  70. package/fonts/greek-700-italic.css +3 -4
  71. package/fonts/greek-700.css +3 -4
  72. package/fonts/greek-ext-400-italic.css +3 -4
  73. package/fonts/greek-ext-400.css +3 -4
  74. package/fonts/greek-ext-500-italic.css +3 -4
  75. package/fonts/greek-ext-500.css +3 -4
  76. package/fonts/greek-ext-700-italic.css +3 -4
  77. package/fonts/greek-ext-700.css +3 -4
  78. package/fonts/latin-400-italic.css +3 -4
  79. package/fonts/latin-400.css +3 -4
  80. package/fonts/latin-500-italic.css +3 -4
  81. package/fonts/latin-500.css +3 -4
  82. package/fonts/latin-700-italic.css +3 -4
  83. package/fonts/latin-700.css +3 -4
  84. package/fonts/latin-ext-400-italic.css +3 -4
  85. package/fonts/latin-ext-400.css +3 -4
  86. package/fonts/latin-ext-500-italic.css +3 -4
  87. package/fonts/latin-ext-500.css +3 -4
  88. package/fonts/latin-ext-700-italic.css +3 -4
  89. package/fonts/latin-ext-700.css +3 -4
  90. package/js/oe-bcl-joinup.bundle.js +0 -5
  91. package/js/oe-bcl-joinup.bundle.js.map +1 -1
  92. package/js/oe-bcl-joinup.bundle.min.js +1 -1
  93. package/js/oe-bcl-joinup.bundle.min.js.map +1 -1
  94. package/js/oe-bcl-joinup.esm.js +0 -3
  95. package/js/oe-bcl-joinup.esm.js.map +1 -1
  96. package/js/oe-bcl-joinup.esm.min.js.map +1 -1
  97. package/js/oe-bcl-joinup.umd.js +0 -5
  98. package/js/oe-bcl-joinup.umd.js.map +1 -1
  99. package/js/oe-bcl-joinup.umd.min.js +1 -1
  100. package/js/oe-bcl-joinup.umd.min.js.map +1 -1
  101. package/js/slim-select-2/slimselect.min.js +1 -1
  102. package/js/slimselect.min.js +1 -1
  103. package/package.json +18 -17
  104. package/src/scss/base/_utilities.scss +4 -8
  105. package/templates/bcl-carousel/carousel.html.twig +2 -2
  106. package/templates/bcl-header/header.html.twig +1 -0
  107. package/templates/bcl-mega-menu/mega-menu.html.twig +116 -0
@@ -0,0 +1,116 @@
1
+ {% apply spaceless %}
2
+
3
+ {# Parameters:
4
+ - id (string) (default: dropdown-random(1000))
5
+ - link (boolean) (default: false) - sets trigger to link, default is button
6
+ - trigger (link or button)
7
+ - content_block (block) (default: '')
8
+ - min_height (string) (default: '300px')
9
+ ! set min-height of mega-menu
10
+ - items (object[])
11
+ format: [
12
+ {
13
+ - link or dropdown
14
+ ! dropdown extra property:
15
+ collapse (render) - to showcase on the last column
16
+ }
17
+ ]
18
+ - back_button_label (string) (default: 'Back')
19
+ - icon_path (string) (default: '')
20
+ #}
21
+
22
+ {% set _id = id|default('dropdown-' ~ random(1000)) %}
23
+ {% set _link = link ?? false %}
24
+ {% set _trigger = trigger|default({}) %}
25
+ {% set _content_block = content_block|default('') %}
26
+ {% set _min_height = min_height|default('300px') %}
27
+ {% set _items = items|default([]) %}
28
+ {% set _back_button_label = back_button_label|default('Back') %}
29
+ {% set _icon_path = icon_path|default('') %}
30
+
31
+ {% if attributes is empty %}
32
+ {% set attributes = create_attribute() %}
33
+ {% endif %}
34
+
35
+ {% set _classes = ['bcl-mega-menu'] %}
36
+
37
+ {% set attributes = attributes.setAttribute('aria-labelledby', _id).addClass(_classes) %}
38
+
39
+ {% if _trigger.attributes is empty %}
40
+ {% set _trigger = _trigger|merge({
41
+ attributes: create_attribute()
42
+ }) %}
43
+ {% endif %}
44
+ {% set _trigger = _trigger|merge({
45
+ attributes: _trigger.attributes.addClass(['dropdown-toggle'])
46
+ .setAttribute('aria-expanded', 'false')
47
+ .setAttribute('data-bs-toggle', 'dropdown')
48
+ .setAttribute('data-bs-auto-close', 'outside')
49
+ .setAttribute('id', _id)
50
+ }) %}
51
+ {% if _link %}
52
+ {% set _trigger = _trigger|merge({
53
+ attributes: _trigger.attributes.setAttribute('role', 'button')
54
+ }) %}
55
+ {% else %}
56
+ {% set _trigger = _trigger|merge({
57
+ attributes: _trigger.attributes.setAttribute('autocomplete', 'off')
58
+ }) %}
59
+ {% endif %}
60
+
61
+ <div {{ attributes }} style="--bcl-mm-min-height: {{ _min_height }};">
62
+ {% if _link %}
63
+ {% include '@oe-bcl/bcl-link/link.html.twig' with _trigger only %}
64
+ {% else %}
65
+ {% include '@oe-bcl/bcl-button/button.html.twig' with _trigger only %}
66
+ {% endif %}
67
+ <div class="mega-menu-container dropdown-menu" aria-labelledby="{{ _id }}">
68
+ <div class="container">
69
+ <div class="d-lg-none back-button-block">
70
+ {% include '@oe-bcl/bcl-button/button.html.twig' with {
71
+ label: _back_button_label,
72
+ icon_position: "before",
73
+ variant: 'link',
74
+ icon: {
75
+ path: _icon_path,
76
+ name: "arrow-left",
77
+ },
78
+ attributes: create_attribute().addClass(['back-button'])
79
+ } only %}
80
+ </div>
81
+ <div class="row position-relative">
82
+ {% if content_block is defined %}
83
+ <div class="col-12 col-xxl-3">
84
+ <div class="content-block p-3">
85
+ {%- block content_block -%}
86
+ {{ _content_block }}
87
+ {%- endblock -%}
88
+ </div>
89
+ </div>
90
+ {% endif %}
91
+ <div class="col-12 col-xxl-9">
92
+ <div class="navigation-items">
93
+ {% for _item in _items %}
94
+ {% if _item.items is defined %}
95
+ {% set _trigger_attributes = _item.trigger.attributes is defined ? _item.trigger.attributes : create_attribute() %}
96
+ {% include '@oe-bcl/bcl-dropdown/dropdown.html.twig' with _item|merge({
97
+ direction: 'dropend',
98
+ link: true,
99
+ }) only %}
100
+ {% if _item.collapse is defined %}
101
+ <div class="collapse">
102
+ {{ _item.collapse|raw }}
103
+ </div>
104
+ {% endif %}
105
+ {% else %}
106
+ {% include '@oe-bcl/bcl-link/link.html.twig' with _item only %}
107
+ {% endif %}
108
+ {% endfor %}
109
+ </div>
110
+ </div>
111
+ </div>
112
+ </div>
113
+ </div>
114
+ </div>
115
+
116
+ {% endapply %}