sfc-utils 1.4.17 → 1.4.19
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/components/topper2.mjs
CHANGED
|
@@ -48,8 +48,8 @@ const Topper2 = ({ settings, wcmData, mods }) => {
|
|
|
48
48
|
fullScreenVerticalCss(),
|
|
49
49
|
// Add style override for center-center position (if applicable)
|
|
50
50
|
fullScreenCenterCenterCss(),
|
|
51
|
-
// Add styling for header-deck container background
|
|
52
|
-
|
|
51
|
+
// Add styling for header-deck container text and background color
|
|
52
|
+
fullScreenHedDekContainerCss()
|
|
53
53
|
];
|
|
54
54
|
case "side-by-side":
|
|
55
55
|
return [
|
|
@@ -87,6 +87,7 @@ const Topper2 = ({ settings, wcmData, mods }) => {
|
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
|
|
90
|
+
/** get additional positioning css for full screen center-center header-deck container **/
|
|
90
91
|
const fullScreenCenterCenterCss = () => {
|
|
91
92
|
return (
|
|
92
93
|
HeaderDek_Horizontal_Position === "center" &&
|
|
@@ -94,6 +95,16 @@ const Topper2 = ({ settings, wcmData, mods }) => {
|
|
|
94
95
|
) ? topperStyles.headerDekCenterCenter : "";
|
|
95
96
|
}
|
|
96
97
|
|
|
98
|
+
/** get css for full screen header-deck container text and background color **/
|
|
99
|
+
const fullScreenHedDekContainerCss = () => {
|
|
100
|
+
switch (Inverted_Colors) {
|
|
101
|
+
case "black-text-white-bg": return topperStyles.blackTextWhiteBg;
|
|
102
|
+
case "white-text-black-bg": return topperStyles.whiteTextBlackBg;
|
|
103
|
+
case "black-text-no-bg": return topperStyles.blackTextNoBg;
|
|
104
|
+
case "white-text-no-bg": return topperStyles.whiteTextNoBg;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
|
|
97
108
|
const headerStyleList = () => {
|
|
98
109
|
let defaultStyles = [];
|
|
99
110
|
switch (Topper_Style) {
|
|
@@ -63,7 +63,7 @@ const TopperImage = ({ wcm, alt, ratio, wcmData, containerCssList = [], imageCss
|
|
|
63
63
|
let photoRatio = "56.25%"; // Default to 16/9
|
|
64
64
|
let photoFraction = 0.5625;
|
|
65
65
|
let photoViewport = "56.25vw";
|
|
66
|
-
let fullPath = `https://s.hdnux.com/photos/0/0/0/${wcm}/
|
|
66
|
+
let fullPath = `https://s.hdnux.com/photos/0/0/0/${wcm}/1/`;
|
|
67
67
|
if (!ratio) {
|
|
68
68
|
let matchedPhoto = wcmData.nodes.find((item) => {
|
|
69
69
|
return (item.photo.wcmid).toString() === (wcm).toString()
|
|
@@ -108,7 +108,9 @@ const TopperImage = ({ wcm, alt, ratio, wcmData, containerCssList = [], imageCss
|
|
|
108
108
|
|
|
109
109
|
return (
|
|
110
110
|
<div className={containerCssList.join(' ')} ref={picRef}>
|
|
111
|
-
|
|
111
|
+
{imageRez > 0 &&
|
|
112
|
+
<ImageHTML fullPath={fullPath} imageRez={imageRez} alt={alt} imageCssList={imageCssList} />
|
|
113
|
+
}
|
|
112
114
|
</div>
|
|
113
115
|
)
|
|
114
116
|
}
|
package/package.json
CHANGED
|
@@ -301,6 +301,18 @@
|
|
|
301
301
|
background-color: rgba(255, 255, 255, 0.54);
|
|
302
302
|
}
|
|
303
303
|
|
|
304
|
+
.blackTextNoBg {
|
|
305
|
+
color: @black;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.whiteTextNoBg {
|
|
309
|
+
color: @white;
|
|
310
|
+
|
|
311
|
+
@media @tablet {
|
|
312
|
+
color: @black;
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
|
|
304
316
|
.hideWhenTablet {
|
|
305
317
|
@media @tablet {
|
|
306
318
|
display: none;
|