Skip to content

Commit

Permalink
Merge pull request #181 from openeuropa/OEL-1160
Browse files Browse the repository at this point in the history
OEL-1160: Header refactor. Add logos from BCL and disable collapse in navbar
  • Loading branch information
escuriola authored Feb 22, 2022
2 parents 12b4565 + e023e00 commit c1b7a32
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 1 deletion.
1 change: 1 addition & 0 deletions assets/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
/css/
/icons/
/js/
/logos/
15 changes: 15 additions & 0 deletions bcl-builder.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,21 @@ module.exports = {
to: path.resolve(outputFolder, "assets/bcl"),
options: { up: 4 },
},
{
from: ["node_modules/@openeuropa/bcl-theme-default/logos/ec/*.svg"],
to: path.resolve(outputFolder, "assets/logos/ec"),
options: { up: true },
},
{
from: ["node_modules/@openeuropa/bcl-theme-default/logos/eu/standard-version/**"],
to: path.resolve(outputFolder, "assets/logos/eu"),
options: { up: true },
},
{
from: ["node_modules/@openeuropa/bcl-theme-default/logos/eu/condensed-version/**"],
to: path.resolve(outputFolder, "assets/logos/eu/mobile"),
options: { up: true },
},
],
"rename": [
{
Expand Down
3 changes: 2 additions & 1 deletion templates/patterns/navbar/navbar.ui_patterns.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ navbar:
expanded_breakpoint:
type: string
label: 'Expanded breakpoint'
description: 'The breakpoint at which the menu will be shown as expanded. For earlier breakpoints, it will be shown after clicking a toggle button. Must be a valid breakpoint class (sm, md, lg). Defaults to lg.'
description: 'The breakpoint at which the menu will be shown as expanded. For earlier breakpoints, it will be shown after clicking a toggle button. Must be a valid breakpoint class (sm, md, lg). Defaults to lg. If not present, then will not collapse.'
preview: 'lg'
color_scheme:
type: string
label: 'Color scheme'
Expand Down
3 changes: 3 additions & 0 deletions templates/patterns/navbar/pattern-navbar.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
{% if background ?? true %}
{% set background = color_set %}
{% endif %}
{% if not expanded_breakpoint %}
{% set disable_collapse = true %}
{% endif %}
{% set expand = expanded_breakpoint|default('lg') %}

{% block branding %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ navbar_pattern_large_light_scheme_default_breakpoint:
'#type': pattern
'#id': navbar
'#fields':
expanded_breakpoint: 'lg'
color_scheme: light
branding:
- '#type': pattern
Expand Down Expand Up @@ -90,6 +91,7 @@ navbar_pattern_medium_dark_scheme_md_breakpoint:
- '#type': pattern
'#id': link
'#fields':
expanded_breakpoint: 'lg'
label: 'OpenEuropa Site'
path: 'https://europa.eu/'
attributes:
Expand Down Expand Up @@ -165,6 +167,7 @@ navbar_pattern_medium_default_scheme_only_navigation:
'#type': pattern
'#id': navbar
'#fields':
expanded_breakpoint: 'lg'
navigation:
- '#type': pattern
'#id': link
Expand Down

0 comments on commit c1b7a32

Please sign in to comment.