mod-build 3.6.56 → 3.6.58-beta.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/CHANGELOG.md +4 -0
- package/gulp-tasks/grab-shared-scripts.js +3 -31
- package/gulp-tasks/templates.js +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 3.6.58
|
|
4
|
+
|
|
5
|
+
- removing the copying of mod-form & qs-form JS files out of `grab-shared-scripts` gulp task, now that all S3 sites have been migrated over to use homeowner.min.js
|
|
6
|
+
|
|
3
7
|
## 3.6.56
|
|
4
8
|
|
|
5
9
|
- `noheap` + `nogtm` conditionals no longer needed (those variables will & have been set to "true" for all sites in our shared components / configs)
|
|
@@ -13,8 +13,6 @@ const fileNames = {
|
|
|
13
13
|
footerComponentJsFileName: '',
|
|
14
14
|
modFooterStylesFileName: '',
|
|
15
15
|
qsFooterStylesFileName: '',
|
|
16
|
-
modFormFileName: '',
|
|
17
|
-
qsFormFileName: '',
|
|
18
16
|
homeownerFormFileName: ''
|
|
19
17
|
};
|
|
20
18
|
var isQuotePageOrUseRelativePath = false;
|
|
@@ -31,15 +29,9 @@ function replaceFootAssetScripts(gulp, gulpPlugins, siteSettings, siteData) {
|
|
|
31
29
|
console.log('>> STARTING Replacing Foot Asset Scripts');
|
|
32
30
|
const resourcePath = isQuotePageOrUseRelativePath ? `${pathSubdirectory}{{#if this.nodeModulesPath}}{{this.nodeModulesPath}}{{/if}}resources/scripts` : '/resources/scripts';
|
|
33
31
|
return gulp.src(siteSettings.srcFolder + '/shared-components/foot-assets/foot-assets.html')
|
|
34
|
-
.pipe(replace(/"(?:(?!"|js")[\s\S])+(modutils|mod-utils.*?)js"|"(?:(?!"|")[\s\S])+(footer\/footer-component.*?)js"|"(?:(?!"|")[\s\S])+(mod-form\/
|
|
35
|
-
if (match.includes('mod-form')) {
|
|
36
|
-
|
|
37
|
-
return `"${resourcePath}/mod-form/form/${fileNames.homeownerFormFileName}"`;
|
|
38
|
-
} else if (match.includes('qs-form')) {
|
|
39
|
-
return `"${resourcePath}/mod-form/${fileNames.qsFormFileName}"`;
|
|
40
|
-
} else {
|
|
41
|
-
return `"${resourcePath}/mod-form/${fileNames.modFormFileName}"`;
|
|
42
|
-
}
|
|
32
|
+
.pipe(replace(/"(?:(?!"|js")[\s\S])+(modutils|mod-utils.*?)js"|"(?:(?!"|")[\s\S])+(footer\/footer-component.*?)js"|"(?:(?!"|")[\s\S])+(mod-form\/form.*?)js"/g, function(match) {
|
|
33
|
+
if (match.includes('mod-form/form')) {
|
|
34
|
+
return `"${resourcePath}/mod-form/form/${fileNames.homeownerFormFileName}"`;
|
|
43
35
|
} else if (match.includes('modutils') || match.includes('mod-utils')) {
|
|
44
36
|
return `"${resourcePath}/mod-utils/${fileNames.modUtilsFileName}"`;
|
|
45
37
|
} else if (match.includes('footer-component')) {
|
|
@@ -167,26 +159,6 @@ const TASKS = {
|
|
|
167
159
|
srcReplaceFn: null,
|
|
168
160
|
additionalSrcReplaceFns: []
|
|
169
161
|
},
|
|
170
|
-
copyModForm: {
|
|
171
|
-
url: 'mod-form/mod-form.min.js',
|
|
172
|
-
config: {
|
|
173
|
-
fileName: 'modFormFileName',
|
|
174
|
-
dest: 'scripts/mod-form',
|
|
175
|
-
mapUrl: 'mod-form/mod-form.min.js.map',
|
|
176
|
-
},
|
|
177
|
-
srcReplaceFn: null,
|
|
178
|
-
additionalSrcReplaceFns: []
|
|
179
|
-
},
|
|
180
|
-
copyQsForm: {
|
|
181
|
-
url: 'mod-form/qs-form.min.js',
|
|
182
|
-
config: {
|
|
183
|
-
fileName: 'qsFormFileName',
|
|
184
|
-
dest: 'scripts/mod-form',
|
|
185
|
-
mapUrl: 'mod-form/qs-form.min.js.map',
|
|
186
|
-
},
|
|
187
|
-
srcReplaceFn: null,
|
|
188
|
-
additionalSrcReplaceFns: []
|
|
189
|
-
},
|
|
190
162
|
copyHomeownerForm: {
|
|
191
163
|
url: 'mod-form/form/homeowner.min.js',
|
|
192
164
|
config: {
|
package/gulp-tasks/templates.js
CHANGED
|
@@ -231,7 +231,7 @@ module.exports = function(gulp, gulpPlugins, siteSettings, siteData) {
|
|
|
231
231
|
throw new Error(`${xhr.statusCode}: Error while fetching TCPA`);
|
|
232
232
|
}
|
|
233
233
|
const responseJson = await JSON.parse(response);
|
|
234
|
-
const finalTCPA = await company === 'Modernize' ? responseJson.tcpa.replace(/QuinStreet/g, 'Modernize') : responseJson.tcpa;
|
|
234
|
+
const finalTCPA = await (company === 'Modernize' || templatesData.useModernizeInTCPA) ? responseJson.tcpa.replace(/QuinStreet/g, 'Modernize') : responseJson.tcpa;
|
|
235
235
|
|
|
236
236
|
templatesData.tcpaText = await finalTCPA;
|
|
237
237
|
|
|
@@ -246,7 +246,7 @@ module.exports = function(gulp, gulpPlugins, siteSettings, siteData) {
|
|
|
246
246
|
if (!templatesData.doNotUseDefaultFieldConfig && !templatesData.defaultConfigCompleted) {
|
|
247
247
|
await getDefaultFormFieldConfig();
|
|
248
248
|
}
|
|
249
|
-
|
|
249
|
+
|
|
250
250
|
if (!templatesData.tcpaText && templatesData.primary_trade) {
|
|
251
251
|
await fetchTcpaFromSitegenie();
|
|
252
252
|
}
|