@openeuropa/bcl-theme-default 1.2.0 → 1.2.1

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/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@openeuropa/bcl-theme-default",
3
3
  "author": "European Commission",
4
4
  "license": "EUPL-1.2",
5
- "version": "1.2.0",
5
+ "version": "1.2.1",
6
6
  "description": "OE - BCL theme default",
7
7
  "scripts": {
8
8
  "align-templates": "lerna --scope \"@openeuropa/bcl-twig-templates\" run prepublish",
@@ -21,9 +21,9 @@
21
21
  "@ecl/resources-ec-logo": "3.7.1",
22
22
  "@ecl/resources-eu-logo": "3.7.1",
23
23
  "@ecl/resources-flag-icons": "3.7.1",
24
- "@openeuropa/bcl-bootstrap": "^1.2.0",
25
- "@openeuropa/bcl-builder": "^1.2.0",
26
- "@openeuropa/bcl-twig-templates": "^1.2.0",
24
+ "@openeuropa/bcl-bootstrap": "^1.2.1",
25
+ "@openeuropa/bcl-builder": "^1.2.1",
26
+ "@openeuropa/bcl-twig-templates": "^1.2.1",
27
27
  "copyfiles": "2.4.1",
28
28
  "cross-env": "7.0.3",
29
29
  "flag-icons": "6.9.2",
@@ -48,5 +48,5 @@
48
48
  "design-system",
49
49
  "twig"
50
50
  ],
51
- "gitHead": "e8750bd56d83523370a6a1f32f3cc5c0b14bdfca"
51
+ "gitHead": "57c9a94fe7e7eb84afb69dcb10c1638b7d403483"
52
52
  }
@@ -3,6 +3,12 @@
3
3
  .bcl-banner {
4
4
  position: relative;
5
5
 
6
+ &.fixed-height {
7
+ .bcl-banner__image {
8
+ height: 150px;
9
+ }
10
+ }
11
+
6
12
  p {
7
13
  font-size: 1.125rem;
8
14
  font-weight: 500;
@@ -142,7 +148,7 @@
142
148
  z-index: 1;
143
149
  display: inline-block;
144
150
  padding: map-get($spacers, "4-5");
145
- margin: 2.75rem auto;
151
+ margin: 2rem auto;
146
152
  border-radius: 4px;
147
153
  min-width: 540px;
148
154
  }
@@ -180,25 +186,31 @@
180
186
  }
181
187
  }
182
188
  }
183
-
184
- // Banners ratio
185
- @include media-breakpoint-up(lg) {
189
+ @include media-breakpoint-up(md) {
186
190
  .bcl-banner {
187
191
  display: flex;
188
- flex-direction: column;
189
192
  align-items: center;
190
193
  justify-content: center;
191
- min-height: 300px;
192
-
193
- .container {
194
- position: absolute;
194
+ &.fixed-height {
195
+ height: 330px;
196
+ .bcl-banner__image {
197
+ height: 100%;
198
+ }
195
199
  }
200
+ }
201
+ }
202
+
203
+ @include media-breakpoint-up(lg) {
204
+ .bcl-banner {
205
+ min-height: 300px;
196
206
 
197
- &::before {
198
- display: block;
199
- width: 100%;
200
- padding-top: 20%;
201
- content: "";
207
+ &:not(.fixed-height) {
208
+ &::before {
209
+ display: block;
210
+ width: 1px;
211
+ padding-top: 20%;
212
+ content: "";
213
+ }
202
214
  }
203
215
 
204
216
  &.hero {
@@ -47,8 +47,8 @@ select.multi-select {
47
47
  font-weight: $badge-font-weight;
48
48
  line-height: 1;
49
49
  color: $badge-color;
50
- text-align: center;
51
- white-space: nowrap;
50
+ text-align: left;
51
+ white-space: normal;
52
52
  vertical-align: baseline;
53
53
  padding-right: map-get($spacers, "3-5");
54
54
  @include border-radius($badge-border-radius);
@@ -61,14 +61,14 @@ select.multi-select {
61
61
  content: "";
62
62
  display: inline-block;
63
63
  height: 1rem;
64
- transform: scale(0.8);
64
+ transform: scale(0.8) translateY(50%);
65
65
  width: 1rem;
66
66
  padding: 15px;
67
67
  background-position: 50%;
68
68
  border-radius: 50%;
69
69
  position: absolute;
70
70
  right: 0;
71
- bottom: -2px;
71
+ bottom: calc(50% - 3px);
72
72
  }
73
73
  }
74
74
  }
@@ -11,6 +11,7 @@
11
11
  - shade: (boolean) (default: false)
12
12
  - hero: (boolean) (default: false)
13
13
  - full_width: (boolean) (default: false)
14
+ - fixed_height: (boolean) (default: false)
14
15
  - content_classes: (string) (default: '')
15
16
  - attributes (drupal attrs)
16
17
  #}
@@ -25,6 +26,7 @@
25
26
  {% set _shade = shade ?? false %}
26
27
  {% set _hero = hero ?? false %}
27
28
  {% set _full_width = full_width ?? false %}
29
+ {% set _fixed_height = fixed_height ?? false %}
28
30
  {% set _content_classes = content_classes|default('') %}
29
31
 
30
32
  {% set _content_class = 'bcl-banner__content' %}
@@ -39,13 +41,27 @@
39
41
 
40
42
  {% set _title_attributes = _title_attributes.addClass(_title_classes) %}
41
43
 
42
- {% set _classes = [
43
- 'bcl-banner',
44
- _shade ? 'shade',
45
- _image and not _shade ? 'overlay',
46
- _hero ? 'hero',
47
- _full_width ? 'full-width'
48
- ] %}
44
+ {% set _classes = ['bcl-banner'] %}
45
+
46
+ {% if _shade %}
47
+ {% set _classes = _classes|merge(['shade']) %}
48
+ {% endif %}
49
+
50
+ {% if _image and not _shade %}
51
+ {% set _classes = _classes|merge(['overlay']) %}
52
+ {% endif %}
53
+
54
+ {% if _hero %}
55
+ {% set _classes = _classes|merge(['hero']) %}
56
+ {% endif %}
57
+
58
+ {% if _full_width %}
59
+ {% set _classes = _classes|merge(['full-width']) %}
60
+ {% endif %}
61
+
62
+ {% if _fixed_height %}
63
+ {% set _classes = _classes|merge(['fixed-height']) %}
64
+ {% endif %}
49
65
 
50
66
  {% if attributes is empty %}
51
67
  {% set attributes = create_attribute() %}