sfc-utils 1.4.90 → 1.4.92
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/footer.js +0 -13
- package/package.json +1 -1
- package/personalize.js +28 -13
package/footer.js
CHANGED
|
@@ -730,19 +730,6 @@ let getFooter = function(meta, forceColor){
|
|
|
730
730
|
.pageFooter--right-links .large-footer-link{
|
|
731
731
|
margin: 7px 0 7px;}
|
|
732
732
|
}
|
|
733
|
-
@media (max-width: 640px) {
|
|
734
|
-
.hed {font-size: calc(3rem - 2px);}
|
|
735
|
-
.deck {font-size: calc(1.25rem + 1px); text-align: left;}
|
|
736
|
-
.subhead {font-size: 2rem;}
|
|
737
|
-
.hed-lg {font-size: calc(3rem - 2px);}
|
|
738
|
-
.hed-sm {font-size: calc(2.5rem - 2px);}
|
|
739
|
-
.subhead-sm {font-size: calc(1.5rem - 2px);}
|
|
740
|
-
.subhead-sans {font-size: calc(1.25rem + 1px);}
|
|
741
|
-
.serif-copy {font-size: 1rem;}
|
|
742
|
-
.sans-copy {font-size: calc(1rem + 1px);}
|
|
743
|
-
.lead-in {font-size: calc(1rem + 1px);}
|
|
744
|
-
.dropcap:first-letter {font-size: 6rem;}
|
|
745
|
-
}
|
|
746
733
|
</style>
|
|
747
734
|
<div class="large-footer-link">
|
|
748
735
|
<a href="https://www.sfchronicle.com/mydata/" target="_blank" role="listitem">Your Privacy Choices (Opt Out of Sale/Targeted Ads)</a>
|
package/package.json
CHANGED
package/personalize.js
CHANGED
|
@@ -2,19 +2,34 @@
|
|
|
2
2
|
const getProfileProperty = (property) => {
|
|
3
3
|
return new Promise((resolve, reject) => {
|
|
4
4
|
if (window) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
5
|
+
let attempts = 0;
|
|
6
|
+
const checkForBlueConic = (innerResolve) => {
|
|
7
|
+
if (window.blueConicClient) {
|
|
8
|
+
const profile = window.blueConicClient.profile.getProfile();
|
|
9
|
+
const properties = [property];
|
|
10
|
+
profile.loadValues(properties, this, function () {
|
|
11
|
+
var value = profile.getValue(property);
|
|
12
|
+
// Return a valid result or null
|
|
13
|
+
value = value || null;
|
|
14
|
+
console.log("getProfileProperty VAL", value);
|
|
15
|
+
innerResolve(value);
|
|
16
|
+
});
|
|
17
|
+
} else {
|
|
18
|
+
attempts++;
|
|
19
|
+
if (attempts < 20) {
|
|
20
|
+
// Check for BlueConic every second
|
|
21
|
+
setTimeout(() => {
|
|
22
|
+
checkForBlueConic(innerResolve);
|
|
23
|
+
}, 1000);
|
|
24
|
+
} else {
|
|
25
|
+
innerResolve(
|
|
26
|
+
"Personalize: No BlueConic client found after many attempts"
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
// Kick off check
|
|
32
|
+
checkForBlueConic(resolve);
|
|
18
33
|
} else {
|
|
19
34
|
resolve("Personalize: No window found");
|
|
20
35
|
}
|