sfc-utils 1.4.174 → 1.4.175

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/settings.js +34 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sfc-utils",
3
- "version": "1.4.174",
3
+ "version": "1.4.175",
4
4
  "author": "ewagstaff <evanjwagstaff@gmail.com>",
5
5
  "dependencies": {
6
6
  "archieml": "^0.4.2",
package/settings.js CHANGED
@@ -67,6 +67,37 @@ let getSettings = function () {
67
67
  if (fullAuthors.length === 0) {
68
68
  fullAuthors = null;
69
69
  }
70
+
71
+ // Default newsletter based by market
72
+ let defaultNewsletter, defaultNewsletterPromo, defaultNewsletterLegal;
73
+ switch (storySettings.Market_Key) {
74
+ case 'SFC':
75
+ defaultNewsletter = 'SFC_TheMustRead';
76
+ defaultNewsletterPromo = `The Chronicle’s most popular stories and best reads of the moment.`;
77
+ defaultNewsletterLegal = `By subscribing, you agree to our <a href="https://www.sfchronicle.com/terms_of_use/">Terms of Use</a> and acknowledge that your information will be used as described in our <a href="https://www.sfchronicle.com/privacy_policy/"> Privacy Notice</a>.`;
78
+ break
79
+ case 'Houston':
80
+ defaultNewsletter = 'HC_The713';
81
+ defaultNewsletterPromo = `A morning newsletter that keeps you connected to Houston in 5 minutes or less.`;
82
+ defaultNewsletterLegal = `By subscribing, you agree to our <a href="https://www.houstonchronicle.com/terms_of_use/">Terms of Use</a> and acknowledge that your information will be used as described in our <a href="https://www.houstonchronicle.com/privacy_policy/"> Privacy Notice</a>.`;
83
+ break
84
+ case 'SanAntonio':
85
+ defaultNewsletter = 'SAEN_OnOurRadar';
86
+ defaultNewsletterPromo = `Get the mid-morning scoop on developing news in San Antonio.`;
87
+ defaultNewsletterLegal = `By subscribing, you agree to our <a href="https://www.expressnews.com/terms_of_use/">Terms of Use</a> and acknowledge that your information will be used as described in our <a href="https://www.expressnews.com/privacy_policy/"> Privacy Notice</a>.`;
88
+ break
89
+ case 'Albany':
90
+ defaultNewsletter = 'ALB_SundayRead';
91
+ defaultNewsletterPromo = `Answering the week’s biggest questions and delivering them to your inbox.`;
92
+ defaultNewsletterLegal = `By subscribing, you agree to our <a href="https://www.timesunion.com/termsofservice/">Terms of Use</a> and acknowledge that your information will be used as described in our <a href="https://www.timesunion.com/privacypolicy/"> Privacy Notice</a>.`;
93
+ break
94
+ case 'CT':
95
+ defaultNewsletter = 'ct_ins_morning_briefing';
96
+ defaultNewsletterPromo = `Stay connected to Connecticut’s stories with a daily digest of top headlines.`;
97
+ defaultNewsletterLegal = `By subscribing, you agree to our <a href="https://www.ctinsider.com/tos/">Terms of Use</a> and acknowledge that your information will be used as described in our <a href="https://www.ctinsider.com/privacy/"> Privacy Notice</a>.`;
98
+ break
99
+ }
100
+
70
101
  // Populate with sheet settings
71
102
  settings = {
72
103
  PAYWALL_SETTING: storySettings.Paywall,
@@ -100,14 +131,17 @@ let getSettings = function () {
100
131
  NEWSLETTER_ID:
101
132
  storySettings.NewsletterID ||
102
133
  storySettings.Custom_Sailthru_ID ||
134
+ defaultNewsletter ||
103
135
  projectSettings.NEWSLETTER_ID,
104
136
  NEWSLETTER_PROMO:
105
137
  storySettings.NewsletterPromo ||
106
138
  storySettings.Custom_Signup_Text ||
139
+ defaultNewsletterPromo ||
107
140
  projectSettings.NEWSLETTER_PROMO,
108
141
  NEWSLETTER_LEGAL:
109
142
  storySettings.NewsletterLegal ||
110
143
  storySettings.TOS_Text ||
144
+ defaultNewsletterLegal ||
111
145
  projectSettings.NEWSLETTER_LEGAL,
112
146
  // Newer things
113
147
  RELATED_LINKS_HED: storySettings.Related_Links_Hed,