@asd20/ui 3.2.746 → 3.2.747

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
@@ -5,7 +5,7 @@
5
5
  "*.scss",
6
6
  "*.vue"
7
7
  ],
8
- "version": "3.2.746",
8
+ "version": "3.2.747",
9
9
  "private": false,
10
10
  "license": "MIT",
11
11
  "repository": {
@@ -38,9 +38,11 @@ export default {
38
38
  // background-image: var(--website-homepage-header__secondary-background-style);
39
39
  // background-position: bottom right !important;
40
40
  // background-size: cover !important;
41
- padding: space(1) 0 space(1) 0;
41
+ padding: space(1) 0 0 0;
42
42
  .asd20-messaging {
43
43
  padding: 0;
44
+ display: flex;
45
+ flex-direction: column;
44
46
  }
45
47
 
46
48
  &::v-deep .message-image {
@@ -72,7 +74,7 @@ export default {
72
74
  order: 1;
73
75
  max-width: 100%;
74
76
  text-shadow: 1px 1px 4px black !important;
75
- padding: space(1);
77
+ padding: space(2) space(1) space(1) space(1);
76
78
  }
77
79
  &::v-deep .asd20-button {
78
80
  @include asd20-font(
@@ -131,6 +133,9 @@ export default {
131
133
  .asd20-secondary-header {
132
134
  // background: var(--website-homepage-header__secondary-background-color)
133
135
  // var(--website-homepage-header__secondary-background-style);
136
+ &::v-deep .asd20-messaging__content {
137
+ padding: space(1);
138
+ }
134
139
  &::v-deep .lead {
135
140
  width: 100%;
136
141
  }
@@ -143,6 +148,9 @@ export default {
143
148
 
144
149
  @media (min-width: 768px) {
145
150
  .asd20-secondary-header {
151
+ &::v-deep .message-image {
152
+ order: 0;
153
+ }
146
154
  &::v-deep .asd20-messaging__content {
147
155
  padding: space(1);
148
156
  }
@@ -156,8 +164,12 @@ export default {
156
164
  padding: space(3) space(3) space(2) space(3);
157
165
  background: var(--website-homepage-header__secondary-background-color)
158
166
  var(--website-homepage-header__secondary-background-style);
167
+ .asd20-messaging {
168
+ flex-direction: row;
169
+ }
159
170
  &::v-deep .message-image {
160
171
  margin-top: 0;
172
+ order: 2;
161
173
  img {
162
174
  height: auto;
163
175
  margin-left: space(1);
@@ -89,6 +89,9 @@ export default {
89
89
  .background-video {
90
90
  display: none;
91
91
  }
92
+ .hide-background-image {
93
+ order: 2;
94
+ }
92
95
  .background-image {
93
96
  display: block;
94
97
  // position: absolute;
@@ -125,7 +128,6 @@ export default {
125
128
  }
126
129
 
127
130
  & ::v-deep .notification-group--floating {
128
- margin-left: 0.5rem;
129
131
  margin-right: 0;
130
132
  }
131
133
  }
@@ -194,6 +196,14 @@ export default {
194
196
  }
195
197
  }
196
198
 
199
+ @media (min-width: 600px) {
200
+ .asd20-video-header {
201
+ .hide-background-image {
202
+ order: 0;
203
+ }
204
+ }
205
+ }
206
+
197
207
  @media (min-width: 768px) {
198
208
  .asd20-video-header {
199
209
  &__top {
@@ -36,6 +36,42 @@ export default {
36
36
  tag: { type: String, default: 'main' },
37
37
  forceDisplay: { type: Boolean, default: false },
38
38
  },
39
+ methods: {
40
+ removeAlpha(colorString) {
41
+ if (colorString.startsWith('var(')) {
42
+ // Extract CSS variable value
43
+ const variableName = colorString.split('(')[1].split(')')[0]
44
+ const cssVariable = getComputedStyle(document.documentElement)
45
+ .getPropertyValue(variableName)
46
+ .trim()
47
+ if (cssVariable.startsWith('#') && cssVariable.length === 9) {
48
+ // Extract RGB values from hex color with alpha
49
+ const hexValue = cssVariable.slice(0, 7) // Remove the alpha part
50
+ return hexValue
51
+ // Check if the CSS variable value has an alpha value
52
+ } else if (cssVariable.startsWith('rgba(')) {
53
+ // Extract RGB values from RGBA color string
54
+ const rgbValues = cssVariable.match(/\d+/g)
55
+ if (rgbValues && rgbValues.length === 4) {
56
+ return `rgb(${rgbValues[0]}, ${rgbValues[1]}, ${rgbValues[2]})`
57
+ }
58
+ }
59
+ // Invalid color format, return original color
60
+ return cssVariable
61
+ }
62
+ // Not a CSS variable, return original color
63
+ return colorString
64
+ },
65
+ },
66
+ mounted() {
67
+ const colorMinusAlpha = this.removeAlpha(
68
+ 'var(--website-homepage-header__background-color)'
69
+ )
70
+ // Get the root element (usually the :root element in your CSS)
71
+ const root = document.documentElement
72
+ // Update the value of a new CSS variable
73
+ root.style.setProperty('--color-minus-alpha', colorMinusAlpha)
74
+ },
39
75
  }
40
76
  </script>
41
77
 
@@ -59,9 +95,9 @@ export default {
59
95
  // rgba(8, 24, 43, 0) 100%
60
96
  // );
61
97
  // background: rgba(51, 92, 155, 0.7);
62
- background: var(--website-homepage-header__background-color)
98
+ background: var(--color-minus-alpha)
63
99
  var(--website-homepage-header__background-style);
64
- padding: space(1);
100
+ padding: space(3) space(1) space(1) space(1);
65
101
  height: auto;
66
102
  }
67
103
 
@@ -106,7 +142,7 @@ export default {
106
142
  // border-bottom: 10px solid var(--color__accent);
107
143
  text-shadow: 1px 1px 4px black !important;
108
144
  &::v-deep .asd20-messaging__content {
109
- margin: space(1) 0;
145
+ margin: space(1) 0 0 0;
110
146
  }
111
147
  }
112
148
  }
@@ -126,13 +162,14 @@ export default {
126
162
  width: 100%;
127
163
  .asd20-messaging {
128
164
  height: inherit;
129
- background: var(--website-homepage-header__background-color)
165
+ padding: space(1);
166
+ background: var(--color-minus-alpha)
130
167
  var(--website-homepage-header__background-style);
131
168
  }
132
169
  &::v-deep .header-messaging-section {
133
170
  .asd20-messaging__content {
134
171
  width: 100%;
135
- margin-top: 0;
172
+ margin: 0 0 space(1) 0;
136
173
  }
137
174
  }
138
175
  &::v-deep .asd20-button {
@@ -145,6 +182,10 @@ export default {
145
182
  @media (min-width: 1024px) {
146
183
  .asd20-video-header-content {
147
184
  width: 80%;
185
+ .asd20-messaging {
186
+ background: var(--website-homepage-header__background-color)
187
+ var(--website-homepage-header__background-style);
188
+ }
148
189
  .header-messaging-section {
149
190
  border-bottom: none;
150
191
  // width: 80%;
@@ -132,7 +132,7 @@
132
132
  --website-header__overlay-background-color: transparent;
133
133
  --website-header__title-color: #fff;
134
134
  --website-homepage-header__accent: var(--color__accent);
135
- --website-homepage-header__background-color: var(--color__secondary);
135
+ --website-homepage-header__background-color: #3f507bcc;
136
136
  --website-homepage-header__background-style: var(--website-texture__reverse) var(--website-texture__position)/var(--website-texture__size-m) var(--website-texture__repeat);
137
137
  --website-homepage-header__button-background-color: var(--color__accent);
138
138
  --website-homepage-header__button-foreground-color: var(--color__on-accent);