@mjhls/mjh-framework 1.0.596 → 1.0.598

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 (154) hide show
  1. package/README.md +172 -172
  2. package/dist/cjs/AD.js +1 -1
  3. package/dist/cjs/AD300x250.js +3 -3
  4. package/dist/cjs/AD300x250x600.js +3 -3
  5. package/dist/cjs/AD728x90.js +4 -4
  6. package/dist/cjs/ADFloatingFooter.js +5 -5
  7. package/dist/cjs/ADGutter.js +2 -2
  8. package/dist/cjs/ADSkyscraper.js +2 -2
  9. package/dist/cjs/ADSponsoredResources.js +2 -2
  10. package/dist/cjs/ADWebcast.js +2 -2
  11. package/dist/cjs/ADWelcome.js +2 -2
  12. package/dist/cjs/AdSlot.js +2 -2
  13. package/dist/cjs/AdSlotsProvider.js +1 -1
  14. package/dist/cjs/ArticleQueue.js +13 -13
  15. package/dist/cjs/Auth.js +256 -507
  16. package/dist/cjs/{BlockContent-f942392e.js → BlockContent-77f81ffc.js} +1 -1
  17. package/dist/cjs/CMEDeck.js +5 -5
  18. package/dist/cjs/Column3.js +4 -4
  19. package/dist/cjs/ConferenceArticleCard.js +17 -17
  20. package/dist/cjs/DeckContent.js +16 -16
  21. package/dist/cjs/DeckQueue.js +7 -7
  22. package/dist/cjs/{Dfp-fbe32b96.js → Dfp-fcdeabc4.js} +1 -1
  23. package/dist/cjs/EventsDeck.js +22 -22
  24. package/dist/cjs/ExternalResources.js +7 -7
  25. package/dist/cjs/Feature.js +3 -3
  26. package/dist/cjs/ForbesHero.js +2 -2
  27. package/dist/cjs/GridContent.js +11 -11
  28. package/dist/cjs/GridHero.js +2 -2
  29. package/dist/cjs/GroupDeck.js +5 -5
  30. package/dist/cjs/HamMagazine.js +11 -11
  31. package/dist/cjs/Hero.js +1 -1
  32. package/dist/cjs/HorizontalHero.js +2 -2
  33. package/dist/cjs/{InscreenSensor-e45e95e3.js → InscreenSensor-22a96661.js} +1 -1
  34. package/dist/cjs/IssueContentDeck.js +2 -2
  35. package/dist/cjs/IssueDeck.js +2 -2
  36. package/dist/cjs/IssueLanding.js +36 -36
  37. package/dist/cjs/KMTracker.js +15 -15
  38. package/dist/cjs/LeftNav.js +2 -2
  39. package/dist/cjs/MasterDeck.js +17 -17
  40. package/dist/cjs/NavMagazine.js +12 -12
  41. package/dist/cjs/NavNative.js +11 -11
  42. package/dist/cjs/OncliveHero.js +2 -2
  43. package/dist/cjs/OncliveLargeHero.js +2 -2
  44. package/dist/cjs/PartnerDetailListing.js +1306 -29
  45. package/dist/cjs/PublicationDeck.js +1 -1
  46. package/dist/cjs/PublicationLanding.js +33 -33
  47. package/dist/cjs/QueueDeckExpanded.js +9 -9
  48. package/dist/cjs/RecentNews.js +2 -2
  49. package/dist/cjs/RelatedContent.js +30 -30
  50. package/dist/cjs/RelatedTopicsDropdown.js +10 -10
  51. package/dist/cjs/SideFooter.js +2 -2
  52. package/dist/cjs/TaxonomyCard.js +2 -2
  53. package/dist/cjs/TemplateNormal.js +2 -2
  54. package/dist/cjs/ThumbnailCard.js +1 -1
  55. package/dist/cjs/Ustream.js +2 -2
  56. package/dist/cjs/VerticalHero.js +2 -2
  57. package/dist/cjs/VideoSeriesFilter.js +1 -1
  58. package/dist/cjs/VideoSeriesListing.js +5 -5
  59. package/dist/cjs/View.js +47 -47
  60. package/dist/cjs/YahooHero.js +2 -2
  61. package/dist/cjs/YoutubeGroup.js +5 -5
  62. package/dist/cjs/getRelatedArticle.js +354 -5
  63. package/dist/cjs/getSerializers.js +6 -6
  64. package/dist/cjs/{getTargeting-b15993cb.js → getTargeting-3d208b98.js} +11 -11
  65. package/dist/cjs/getTargeting.js +1 -1
  66. package/dist/cjs/{index-5be2866f.js → index-3294d3bc.js} +1 -1
  67. package/dist/cjs/index-bd6c9f56.js +211 -0
  68. package/dist/cjs/{index-b5eb3ff8.js → index-be0c82be.js} +19 -20
  69. package/dist/cjs/{index-e7f86168.js → index-c4972b44.js} +441 -453
  70. package/dist/cjs/{index-f7ee1612.js → index-fa3cec70.js} +6 -4
  71. package/dist/cjs/{index.es-ab3f2690.js → index.es-9110add6.js} +1 -3
  72. package/dist/cjs/index.js +16 -17
  73. package/dist/cjs/{inherits-93684212.js → inherits-14962339.js} +4 -4
  74. package/dist/cjs/{main-bc4db521.js → main-88348b15.js} +35 -66
  75. package/dist/cjs/{moment-66a6a284.js → moment-575fe24c.js} +1 -1
  76. package/dist/cjs/urlFor.js +2 -2
  77. package/dist/esm/AD.js +1 -1
  78. package/dist/esm/AD300x250.js +3 -3
  79. package/dist/esm/AD300x250x600.js +3 -3
  80. package/dist/esm/AD728x90.js +4 -4
  81. package/dist/esm/ADFloatingFooter.js +5 -5
  82. package/dist/esm/ADGutter.js +2 -2
  83. package/dist/esm/ADSkyscraper.js +2 -2
  84. package/dist/esm/ADSponsoredResources.js +2 -2
  85. package/dist/esm/ADWebcast.js +2 -2
  86. package/dist/esm/ADWelcome.js +2 -2
  87. package/dist/esm/AdSlot.js +2 -2
  88. package/dist/esm/AdSlotsProvider.js +1 -1
  89. package/dist/esm/ArticleQueue.js +11 -11
  90. package/dist/esm/Auth.js +248 -499
  91. package/dist/esm/{BlockContent-a614acdf.js → BlockContent-e9b4ddcf.js} +1 -1
  92. package/dist/esm/CMEDeck.js +5 -5
  93. package/dist/esm/Column3.js +4 -4
  94. package/dist/esm/ConferenceArticleCard.js +17 -17
  95. package/dist/esm/DeckContent.js +15 -15
  96. package/dist/esm/DeckQueue.js +6 -6
  97. package/dist/esm/{Dfp-56444b73.js → Dfp-a36ad202.js} +1 -1
  98. package/dist/esm/EventsDeck.js +22 -22
  99. package/dist/esm/ExternalResources.js +7 -7
  100. package/dist/esm/Feature.js +3 -3
  101. package/dist/esm/ForbesHero.js +2 -2
  102. package/dist/esm/GridContent.js +10 -10
  103. package/dist/esm/GridHero.js +2 -2
  104. package/dist/esm/GroupDeck.js +5 -5
  105. package/dist/esm/HamMagazine.js +11 -11
  106. package/dist/esm/Hero.js +1 -1
  107. package/dist/esm/HorizontalHero.js +2 -2
  108. package/dist/esm/IssueContentDeck.js +2 -2
  109. package/dist/esm/IssueDeck.js +2 -2
  110. package/dist/esm/IssueLanding.js +36 -36
  111. package/dist/esm/KMTracker.js +15 -15
  112. package/dist/esm/LeftNav.js +2 -2
  113. package/dist/esm/MasterDeck.js +16 -16
  114. package/dist/esm/NavMagazine.js +12 -12
  115. package/dist/esm/NavNative.js +11 -11
  116. package/dist/esm/OncliveHero.js +2 -2
  117. package/dist/esm/OncliveLargeHero.js +2 -2
  118. package/dist/esm/PartnerDetailListing.js +1304 -27
  119. package/dist/esm/PublicationDeck.js +1 -1
  120. package/dist/esm/PublicationLanding.js +33 -33
  121. package/dist/esm/QueueDeckExpanded.js +9 -9
  122. package/dist/esm/RecentNews.js +2 -2
  123. package/dist/esm/RelatedContent.js +30 -30
  124. package/dist/esm/RelatedTopicsDropdown.js +10 -10
  125. package/dist/esm/SideFooter.js +2 -2
  126. package/dist/esm/TaxonomyCard.js +2 -2
  127. package/dist/esm/TemplateNormal.js +2 -2
  128. package/dist/esm/ThumbnailCard.js +1 -1
  129. package/dist/esm/Ustream.js +2 -2
  130. package/dist/esm/VerticalHero.js +2 -2
  131. package/dist/esm/VideoSeriesFilter.js +1 -1
  132. package/dist/esm/VideoSeriesListing.js +4 -4
  133. package/dist/esm/View.js +21 -21
  134. package/dist/esm/YahooHero.js +2 -2
  135. package/dist/esm/YoutubeGroup.js +5 -5
  136. package/dist/esm/getRelatedArticle.js +354 -5
  137. package/dist/esm/getSerializers.js +6 -6
  138. package/dist/esm/{getTargeting-1a0bd08d.js → getTargeting-1f2c61e3.js} +9 -9
  139. package/dist/esm/getTargeting.js +1 -1
  140. package/dist/esm/{index-93ec3c59.js → index-3f4dd6f2.js} +6 -4
  141. package/dist/esm/{index-51a80699.js → index-73819142.js} +19 -20
  142. package/dist/esm/{index-91506c27.js → index-7ca90052.js} +441 -453
  143. package/dist/esm/index-db3bb315.js +207 -0
  144. package/dist/esm/{index-d2f90501.js → index-ef6d5dcf.js} +1 -1
  145. package/dist/esm/{index.es-938a3a58.js → index.es-29c1cef5.js} +1 -3
  146. package/dist/esm/index.js +13 -14
  147. package/dist/esm/{main-7255814e.js → main-d7ee6151.js} +34 -65
  148. package/dist/esm/{moment-12415288.js → moment-e2f9b20c.js} +1 -1
  149. package/dist/esm/urlFor.js +2 -2
  150. package/package.json +107 -107
  151. /package/dist/cjs/{ADInfeed-17a378db.js → ADInfeed-df340285.js} +0 -0
  152. /package/dist/cjs/{ADlgInfeed-070d911c.js → ADlgInfeed-2110d08c.js} +0 -0
  153. /package/dist/esm/{ADInfeed-cecd42e8.js → ADInfeed-a5a1f81f.js} +0 -0
  154. /package/dist/esm/{ADlgInfeed-234ba767.js → ADlgInfeed-99f14909.js} +0 -0
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- require('./_commonjsHelpers-06173234.js');
3
+ var _commonjsHelpers = require('./_commonjsHelpers-06173234.js');
4
4
  require('./_to-object-329a650b.js');
5
5
  require('./core.get-iterator-method-41e87ec1.js');
6
6
  require('./_library-dd23b178.js');
@@ -8,9 +8,358 @@ require('./_iter-detect-4d0352f8.js');
8
8
  require('./web.dom.iterable-43c3e277.js');
9
9
  var asyncToGenerator = require('./asyncToGenerator-8e707718.js');
10
10
  require('./_set-species-4458e975.js');
11
- var nookies = require('nookies');
11
+ var index$4 = require('./index-bd6c9f56.js');
12
12
  var getQuery = require('./getQuery.js');
13
13
 
14
+ var defaultParseOptions = {
15
+ decodeValues: true,
16
+ map: false,
17
+ silent: false,
18
+ };
19
+
20
+ function isNonEmptyString(str) {
21
+ return typeof str === "string" && !!str.trim();
22
+ }
23
+
24
+ function parseString(setCookieValue, options) {
25
+ var parts = setCookieValue.split(";").filter(isNonEmptyString);
26
+ var nameValue = parts.shift().split("=");
27
+ var name = nameValue.shift();
28
+ var value = nameValue.join("="); // everything after the first =, joined by a "=" if there was more than one part
29
+
30
+ options = options
31
+ ? Object.assign({}, defaultParseOptions, options)
32
+ : defaultParseOptions;
33
+
34
+ var cookie = {
35
+ name: name, // grab everything before the first =
36
+ value: options.decodeValues ? decodeURIComponent(value) : value, // decode cookie value
37
+ };
38
+
39
+ parts.forEach(function (part) {
40
+ var sides = part.split("=");
41
+ var key = sides.shift().trimLeft().toLowerCase();
42
+ var value = sides.join("=");
43
+ if (key === "expires") {
44
+ cookie.expires = new Date(value);
45
+ } else if (key === "max-age") {
46
+ cookie.maxAge = parseInt(value, 10);
47
+ } else if (key === "secure") {
48
+ cookie.secure = true;
49
+ } else if (key === "httponly") {
50
+ cookie.httpOnly = true;
51
+ } else if (key === "samesite") {
52
+ cookie.sameSite = value;
53
+ } else {
54
+ cookie[key] = value;
55
+ }
56
+ });
57
+
58
+ return cookie;
59
+ }
60
+
61
+ function parse(input, options) {
62
+ options = options
63
+ ? Object.assign({}, defaultParseOptions, options)
64
+ : defaultParseOptions;
65
+
66
+ if (!input) {
67
+ if (!options.map) {
68
+ return [];
69
+ } else {
70
+ return {};
71
+ }
72
+ }
73
+
74
+ if (input.headers && input.headers["set-cookie"]) {
75
+ // fast-path for node.js (which automatically normalizes header names to lower-case
76
+ input = input.headers["set-cookie"];
77
+ } else if (input.headers) {
78
+ // slow-path for other environments - see #25
79
+ var sch =
80
+ input.headers[
81
+ Object.keys(input.headers).find(function (key) {
82
+ return key.toLowerCase() === "set-cookie";
83
+ })
84
+ ];
85
+ // warn if called on a request-like object with a cookie header rather than a set-cookie header - see #34, 36
86
+ if (!sch && input.headers.cookie && !options.silent) {
87
+ console.warn(
88
+ "Warning: set-cookie-parser appears to have been called on a request object. It is designed to parse Set-Cookie headers from responses, not Cookie headers from requests. Set the option {silent: true} to suppress this warning."
89
+ );
90
+ }
91
+ input = sch;
92
+ }
93
+ if (!Array.isArray(input)) {
94
+ input = [input];
95
+ }
96
+
97
+ options = options
98
+ ? Object.assign({}, defaultParseOptions, options)
99
+ : defaultParseOptions;
100
+
101
+ if (!options.map) {
102
+ return input.filter(isNonEmptyString).map(function (str) {
103
+ return parseString(str, options);
104
+ });
105
+ } else {
106
+ var cookies = {};
107
+ return input.filter(isNonEmptyString).reduce(function (cookies, str) {
108
+ var cookie = parseString(str, options);
109
+ cookies[cookie.name] = cookie;
110
+ return cookies;
111
+ }, cookies);
112
+ }
113
+ }
114
+
115
+ /*
116
+ Set-Cookie header field-values are sometimes comma joined in one string. This splits them without choking on commas
117
+ that are within a single set-cookie field-value, such as in the Expires portion.
118
+
119
+ This is uncommon, but explicitly allowed - see https://tools.ietf.org/html/rfc2616#section-4.2
120
+ Node.js does this for every header *except* set-cookie - see https://github.com/nodejs/node/blob/d5e363b77ebaf1caf67cd7528224b651c86815c1/lib/_http_incoming.js#L128
121
+ React Native's fetch does this for *every* header, including set-cookie.
122
+
123
+ Based on: https://github.com/google/j2objc/commit/16820fdbc8f76ca0c33472810ce0cb03d20efe25
124
+ Credits to: https://github.com/tomball for original and https://github.com/chrusart for JavaScript implementation
125
+ */
126
+ function splitCookiesString(cookiesString) {
127
+ if (Array.isArray(cookiesString)) {
128
+ return cookiesString;
129
+ }
130
+ if (typeof cookiesString !== "string") {
131
+ return [];
132
+ }
133
+
134
+ var cookiesStrings = [];
135
+ var pos = 0;
136
+ var start;
137
+ var ch;
138
+ var lastComma;
139
+ var nextStart;
140
+ var cookiesSeparatorFound;
141
+
142
+ function skipWhitespace() {
143
+ while (pos < cookiesString.length && /\s/.test(cookiesString.charAt(pos))) {
144
+ pos += 1;
145
+ }
146
+ return pos < cookiesString.length;
147
+ }
148
+
149
+ function notSpecialChar() {
150
+ ch = cookiesString.charAt(pos);
151
+
152
+ return ch !== "=" && ch !== ";" && ch !== ",";
153
+ }
154
+
155
+ while (pos < cookiesString.length) {
156
+ start = pos;
157
+ cookiesSeparatorFound = false;
158
+
159
+ while (skipWhitespace()) {
160
+ ch = cookiesString.charAt(pos);
161
+ if (ch === ",") {
162
+ // ',' is a cookie separator if we have later first '=', not ';' or ','
163
+ lastComma = pos;
164
+ pos += 1;
165
+
166
+ skipWhitespace();
167
+ nextStart = pos;
168
+
169
+ while (pos < cookiesString.length && notSpecialChar()) {
170
+ pos += 1;
171
+ }
172
+
173
+ // currently special character
174
+ if (pos < cookiesString.length && cookiesString.charAt(pos) === "=") {
175
+ // we found cookies separator
176
+ cookiesSeparatorFound = true;
177
+ // pos is inside the next cookie, so back up and return it.
178
+ pos = nextStart;
179
+ cookiesStrings.push(cookiesString.substring(start, lastComma));
180
+ start = pos;
181
+ } else {
182
+ // in param ',' or param separator ';',
183
+ // we continue from that comma
184
+ pos = lastComma + 1;
185
+ }
186
+ } else {
187
+ pos += 1;
188
+ }
189
+ }
190
+
191
+ if (!cookiesSeparatorFound || pos >= cookiesString.length) {
192
+ cookiesStrings.push(cookiesString.substring(start, cookiesString.length));
193
+ }
194
+ }
195
+
196
+ return cookiesStrings;
197
+ }
198
+
199
+ var setCookie = parse;
200
+ var parse_1 = parse;
201
+ var parseString_1 = parseString;
202
+ var splitCookiesString_1 = splitCookiesString;
203
+ setCookie.parse = parse_1;
204
+ setCookie.parseString = parseString_1;
205
+ setCookie.splitCookiesString = splitCookiesString_1;
206
+
207
+ var dist = _commonjsHelpers.createCommonjsModule(function (module, exports) {
208
+ var __assign = (_commonjsHelpers.commonjsGlobal && _commonjsHelpers.commonjsGlobal.__assign) || function () {
209
+ __assign = Object.assign || function(t) {
210
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
211
+ s = arguments[i];
212
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
213
+ t[p] = s[p];
214
+ }
215
+ return t;
216
+ };
217
+ return __assign.apply(this, arguments);
218
+ };
219
+ Object.defineProperty(exports, "__esModule", { value: true });
220
+ exports.destroyCookie = exports.setCookie = exports.parseCookies = void 0;
221
+
222
+
223
+ var isBrowser = function () { return typeof window !== 'undefined'; };
224
+ function hasSameProperties(a, b) {
225
+ var aProps = Object.getOwnPropertyNames(a);
226
+ var bProps = Object.getOwnPropertyNames(b);
227
+ if (aProps.length !== bProps.length) {
228
+ return false;
229
+ }
230
+ for (var i = 0; i < aProps.length; i++) {
231
+ var propName = aProps[i];
232
+ if (a[propName] !== b[propName]) {
233
+ return false;
234
+ }
235
+ }
236
+ return true;
237
+ }
238
+ /**
239
+ * Compare the cookie and return true if the cookies has equivalent
240
+ * options and the cookies would be overwritten in the browser storage.
241
+ *
242
+ * @param a first Cookie for comparison
243
+ * @param b second Cookie for comparison
244
+ */
245
+ function areCookiesEqual(a, b) {
246
+ var sameSiteSame = a.sameSite === b.sameSite;
247
+ if (typeof a.sameSite === 'string' && typeof b.sameSite === 'string') {
248
+ sameSiteSame = a.sameSite.toLowerCase() === b.sameSite.toLowerCase();
249
+ }
250
+ return (hasSameProperties(__assign(__assign({}, a), { sameSite: undefined }), __assign(__assign({}, b), { sameSite: undefined })) && sameSiteSame);
251
+ }
252
+ /**
253
+ * Create an instance of the Cookie interface
254
+ *
255
+ * @param name name of the Cookie
256
+ * @param value value of the Cookie
257
+ * @param options Cookie options
258
+ */
259
+ function createCookie(name, value, options) {
260
+ var sameSite = options.sameSite;
261
+ if (sameSite === true) {
262
+ sameSite = 'strict';
263
+ }
264
+ if (sameSite === undefined || sameSite === false) {
265
+ sameSite = 'lax';
266
+ }
267
+ var cookieToSet = __assign(__assign({}, options), { sameSite: sameSite });
268
+ delete cookieToSet.encode;
269
+ return __assign({ name: name, value: value }, cookieToSet);
270
+ }
271
+ /**
272
+ *
273
+ * Parses cookies.
274
+ *
275
+ * @param ctx
276
+ * @param options
277
+ */
278
+ function parseCookies(ctx, options) {
279
+ if (ctx && ctx.req && ctx.req.headers && ctx.req.headers.cookie) {
280
+ return index$4.cookie.parse(ctx.req.headers.cookie, options);
281
+ }
282
+ if (isBrowser()) {
283
+ return index$4.cookie.parse(document.cookie, options);
284
+ }
285
+ return {};
286
+ }
287
+ exports.parseCookies = parseCookies;
288
+ /**
289
+ *
290
+ * Sets a cookie.
291
+ *
292
+ * @param ctx
293
+ * @param name
294
+ * @param value
295
+ * @param options
296
+ */
297
+ function setCookie$1(ctx, name, value, options) {
298
+ if (ctx && ctx.res && ctx.res.getHeader && ctx.res.setHeader) {
299
+ var cookies = ctx.res.getHeader('Set-Cookie') || [];
300
+ if (typeof cookies === 'string')
301
+ cookies = [cookies];
302
+ if (typeof cookies === 'number')
303
+ cookies = [];
304
+ var parsedCookies = setCookie.parse(cookies);
305
+ var cookiesToSet_1 = [];
306
+ parsedCookies.forEach(function (parsedCookie) {
307
+ if (!areCookiesEqual(parsedCookie, createCookie(name, value, options))) {
308
+ cookiesToSet_1.push(index$4.cookie.serialize(parsedCookie.name, parsedCookie.value, __assign({ encode: function (val) { return val; } }, parsedCookie)));
309
+ }
310
+ });
311
+ cookiesToSet_1.push(index$4.cookie.serialize(name, value, options));
312
+ if (!ctx.res.finished) {
313
+ ctx.res.setHeader('Set-Cookie', cookiesToSet_1);
314
+ }
315
+ }
316
+ if (isBrowser()) {
317
+ if (options && options.httpOnly) {
318
+ throw new Error('Can not set a httpOnly cookie in the browser.');
319
+ }
320
+ document.cookie = index$4.cookie.serialize(name, value, options);
321
+ }
322
+ return {};
323
+ }
324
+ exports.setCookie = setCookie$1;
325
+ /**
326
+ *
327
+ * Destroys a cookie with a particular name.
328
+ *
329
+ * @param ctx
330
+ * @param name
331
+ * @param options
332
+ */
333
+ function destroyCookie(ctx, name, options) {
334
+ var opts = __assign(__assign({}, (options || {})), { maxAge: -1 });
335
+ if (ctx && ctx.res && ctx.res.setHeader && ctx.res.getHeader) {
336
+ var cookies = ctx.res.getHeader('Set-Cookie') || [];
337
+ if (typeof cookies === 'string')
338
+ cookies = [cookies];
339
+ if (typeof cookies === 'number')
340
+ cookies = [];
341
+ cookies.push(index$4.cookie.serialize(name, '', opts));
342
+ ctx.res.setHeader('Set-Cookie', cookies);
343
+ }
344
+ if (isBrowser()) {
345
+ document.cookie = index$4.cookie.serialize(name, '', opts);
346
+ }
347
+ return {};
348
+ }
349
+ exports.destroyCookie = destroyCookie;
350
+ exports.default = {
351
+ set: setCookie$1,
352
+ get: parseCookies,
353
+ destroy: destroyCookie,
354
+ };
355
+
356
+ });
357
+
358
+ _commonjsHelpers.unwrapExports(dist);
359
+ var dist_1 = dist.destroyCookie;
360
+ var dist_2 = dist.setCookie;
361
+ var dist_3 = dist.parseCookies;
362
+
14
363
  var _this = undefined;
15
364
 
16
365
  var getRelatedArticle = function () {
@@ -63,13 +412,13 @@ var getRelatedArticle = function () {
63
412
  conditions = '';
64
413
 
65
414
  if (ctx && url) {
66
- cookies = nookies.parseCookies(ctx);
415
+ cookies = dist_3(ctx);
67
416
  prevSlugs = cookies['prevSlugs'];
68
417
 
69
418
  if (!!prevSlugs) {
70
- nookies.setCookie(ctx, 'prevSlugs', prevSlugs + ',"' + url + '"', {});
419
+ dist_2(ctx, 'prevSlugs', prevSlugs + ',"' + url + '"', {});
71
420
  conditions = '&& !(url.current in [' + prevSlugs + '])';
72
- } else nookies.setCookie(ctx, 'prevSlugs', '"' + url + '"', {});
421
+ } else dist_2(ctx, 'prevSlugs', '"' + url + '"', {});
73
422
  }
74
423
  relatedArticleQuery = getQuery('related', conditions, '', articleCount);
75
424
  _context.next = 12;
@@ -12,18 +12,18 @@ require('./web.dom.iterable-43c3e277.js');
12
12
  require('./typeof-1869832c.js');
13
13
  require('./_is-array-754e012d.js');
14
14
  require('react');
15
- require('./index-f7ee1612.js');
15
+ require('./index-fa3cec70.js');
16
16
  require('prop-types');
17
17
  require('react-bootstrap/Row');
18
18
  require('react-bootstrap/Col');
19
- require('./moment-66a6a284.js');
19
+ require('./moment-575fe24c.js');
20
20
  require('next/router');
21
21
  require('./isSymbol-488934a7.js');
22
22
  require('./debounce-32e57002.js');
23
23
  require('react-dom');
24
- require('./index-b5eb3ff8.js');
24
+ require('./index-be0c82be.js');
25
25
  require('./index-fa0fb52c.js');
26
- require('./main-bc4db521.js');
26
+ require('./main-88348b15.js');
27
27
  require('./entities-310b46ee.js');
28
28
  require('./slicedToArray-8063ee51.js');
29
29
  require('./stringify-7c5aff47.js');
@@ -32,12 +32,12 @@ require('./_set-species-4458e975.js');
32
32
  require('./beam-d22818d3.js');
33
33
  require('./AdSlot.js');
34
34
  require('./lodash-fc2922d0.js');
35
- require('./BlockContent-f942392e.js');
35
+ require('./BlockContent-77f81ffc.js');
36
36
  require('./smoothscroll-95231a70.js');
37
37
  require('./GroupDeck.js');
38
38
  require('react-bootstrap');
39
39
  require('react-bootstrap/Button');
40
- var getSerializers = require('./index-e7f86168.js');
40
+ var getSerializers = require('./index-c4972b44.js');
41
41
  require('./util-f2c1b65b.js');
42
42
  require('./brightcove-react-player-loader.es-156bd4d6.js');
43
43
  require('react-bootstrap/Pagination');
@@ -1,21 +1,21 @@
1
1
  'use strict';
2
2
 
3
3
  var toConsumableArray = require('./toConsumableArray-ca04303b.js');
4
- var _extends = require('./extends-60837c34.js');
4
+ var _extends$1 = require('./extends-60837c34.js');
5
5
 
6
6
  var getContentPlacementUrl = function getContentPlacementUrl(cp) {
7
- var cp_url = '';
8
- if (cp.ancestor && typeof cp.ancestor == 'string') {
9
- cp_url += (cp_url === '' ? '' : '/') + cp.ancestor;
10
- }
7
+ var cp_url = '';
8
+ if (cp.ancestor && typeof cp.ancestor == 'string') {
9
+ cp_url += (cp_url === '' ? '' : '/') + cp.ancestor;
10
+ }
11
11
 
12
- if (!cp.ancestor && cp.parent && typeof cp.parent == 'string') {
13
- cp_url += (cp_url === '' ? '' : '/') + cp.parent;
14
- }
12
+ if (!cp.ancestor && cp.parent && typeof cp.parent == 'string') {
13
+ cp_url += (cp_url === '' ? '' : '/') + cp.parent;
14
+ }
15
15
 
16
- cp_url += (cp_url === '' ? '' : '/') + cp.path;
16
+ cp_url += (cp_url === '' ? '' : '/') + cp.path;
17
17
 
18
- return cp_url;
18
+ return cp_url;
19
19
  };
20
20
 
21
21
  var getTargeting = function getTargeting(props) {
@@ -102,7 +102,7 @@ var getTargeting = function getTargeting(props) {
102
102
  }
103
103
 
104
104
  if (props.cache && props.cache.hyperTargeting) {
105
- targeting = _extends._extends({}, targeting, { campaign_id: props.cache.hyperTargeting });
105
+ targeting = _extends$1._extends({}, targeting, { campaign_id: props.cache.hyperTargeting });
106
106
  }
107
107
 
108
108
  if (position && position.length) {
@@ -8,7 +8,7 @@ require('./from-ea347372.js');
8
8
  require('./toConsumableArray-ca04303b.js');
9
9
  require('./_object-pie-68c5bcbc.js');
10
10
  require('./extends-60837c34.js');
11
- var getTargeting = require('./getTargeting-b15993cb.js');
11
+ var getTargeting = require('./getTargeting-3d208b98.js');
12
12
 
13
13
 
14
14
 
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var _commonjsHelpers = require('./_commonjsHelpers-06173234.js');
4
- var moment = require('./moment-66a6a284.js');
4
+ var moment = require('./moment-575fe24c.js');
5
5
 
6
6
  var momentTimezone = _commonjsHelpers.createCommonjsModule(function (module) {
7
7
  //! moment-timezone.js
@@ -0,0 +1,211 @@
1
+ 'use strict';
2
+
3
+ /*!
4
+ * cookie
5
+ * Copyright(c) 2012-2014 Roman Shtylman
6
+ * Copyright(c) 2015 Douglas Christopher Wilson
7
+ * MIT Licensed
8
+ */
9
+
10
+ /**
11
+ * Module exports.
12
+ * @public
13
+ */
14
+
15
+ var parse_1 = parse;
16
+ var serialize_1 = serialize;
17
+
18
+ /**
19
+ * Module variables.
20
+ * @private
21
+ */
22
+
23
+ var decode = decodeURIComponent;
24
+ var encode = encodeURIComponent;
25
+ var pairSplitRegExp = /; */;
26
+
27
+ /**
28
+ * RegExp to match field-content in RFC 7230 sec 3.2
29
+ *
30
+ * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]
31
+ * field-vchar = VCHAR / obs-text
32
+ * obs-text = %x80-FF
33
+ */
34
+
35
+ var fieldContentRegExp = /^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;
36
+
37
+ /**
38
+ * Parse a cookie header.
39
+ *
40
+ * Parse the given cookie header string into an object
41
+ * The object has the various cookies as keys(names) => values
42
+ *
43
+ * @param {string} str
44
+ * @param {object} [options]
45
+ * @return {object}
46
+ * @public
47
+ */
48
+
49
+ function parse(str, options) {
50
+ if (typeof str !== 'string') {
51
+ throw new TypeError('argument str must be a string');
52
+ }
53
+
54
+ var obj = {};
55
+ var opt = options || {};
56
+ var pairs = str.split(pairSplitRegExp);
57
+ var dec = opt.decode || decode;
58
+
59
+ for (var i = 0; i < pairs.length; i++) {
60
+ var pair = pairs[i];
61
+ var eq_idx = pair.indexOf('=');
62
+
63
+ // skip things that don't look like key=value
64
+ if (eq_idx < 0) {
65
+ continue;
66
+ }
67
+
68
+ var key = pair.substr(0, eq_idx).trim();
69
+ var val = pair.substr(++eq_idx, pair.length).trim();
70
+
71
+ // quoted values
72
+ if ('"' == val[0]) {
73
+ val = val.slice(1, -1);
74
+ }
75
+
76
+ // only assign once
77
+ if (undefined == obj[key]) {
78
+ obj[key] = tryDecode(val, dec);
79
+ }
80
+ }
81
+
82
+ return obj;
83
+ }
84
+
85
+ /**
86
+ * Serialize data into a cookie header.
87
+ *
88
+ * Serialize the a name value pair into a cookie string suitable for
89
+ * http headers. An optional options object specified cookie parameters.
90
+ *
91
+ * serialize('foo', 'bar', { httpOnly: true })
92
+ * => "foo=bar; httpOnly"
93
+ *
94
+ * @param {string} name
95
+ * @param {string} val
96
+ * @param {object} [options]
97
+ * @return {string}
98
+ * @public
99
+ */
100
+
101
+ function serialize(name, val, options) {
102
+ var opt = options || {};
103
+ var enc = opt.encode || encode;
104
+
105
+ if (typeof enc !== 'function') {
106
+ throw new TypeError('option encode is invalid');
107
+ }
108
+
109
+ if (!fieldContentRegExp.test(name)) {
110
+ throw new TypeError('argument name is invalid');
111
+ }
112
+
113
+ var value = enc(val);
114
+
115
+ if (value && !fieldContentRegExp.test(value)) {
116
+ throw new TypeError('argument val is invalid');
117
+ }
118
+
119
+ var str = name + '=' + value;
120
+
121
+ if (null != opt.maxAge) {
122
+ var maxAge = opt.maxAge - 0;
123
+
124
+ if (isNaN(maxAge) || !isFinite(maxAge)) {
125
+ throw new TypeError('option maxAge is invalid')
126
+ }
127
+
128
+ str += '; Max-Age=' + Math.floor(maxAge);
129
+ }
130
+
131
+ if (opt.domain) {
132
+ if (!fieldContentRegExp.test(opt.domain)) {
133
+ throw new TypeError('option domain is invalid');
134
+ }
135
+
136
+ str += '; Domain=' + opt.domain;
137
+ }
138
+
139
+ if (opt.path) {
140
+ if (!fieldContentRegExp.test(opt.path)) {
141
+ throw new TypeError('option path is invalid');
142
+ }
143
+
144
+ str += '; Path=' + opt.path;
145
+ }
146
+
147
+ if (opt.expires) {
148
+ if (typeof opt.expires.toUTCString !== 'function') {
149
+ throw new TypeError('option expires is invalid');
150
+ }
151
+
152
+ str += '; Expires=' + opt.expires.toUTCString();
153
+ }
154
+
155
+ if (opt.httpOnly) {
156
+ str += '; HttpOnly';
157
+ }
158
+
159
+ if (opt.secure) {
160
+ str += '; Secure';
161
+ }
162
+
163
+ if (opt.sameSite) {
164
+ var sameSite = typeof opt.sameSite === 'string'
165
+ ? opt.sameSite.toLowerCase() : opt.sameSite;
166
+
167
+ switch (sameSite) {
168
+ case true:
169
+ str += '; SameSite=Strict';
170
+ break;
171
+ case 'lax':
172
+ str += '; SameSite=Lax';
173
+ break;
174
+ case 'strict':
175
+ str += '; SameSite=Strict';
176
+ break;
177
+ case 'none':
178
+ str += '; SameSite=None';
179
+ break;
180
+ default:
181
+ throw new TypeError('option sameSite is invalid');
182
+ }
183
+ }
184
+
185
+ return str;
186
+ }
187
+
188
+ /**
189
+ * Try decoding a string using a decoding function.
190
+ *
191
+ * @param {string} str
192
+ * @param {function} decode
193
+ * @private
194
+ */
195
+
196
+ function tryDecode(str, decode) {
197
+ try {
198
+ return decode(str);
199
+ } catch (e) {
200
+ return str;
201
+ }
202
+ }
203
+
204
+ var cookie = {
205
+ parse: parse_1,
206
+ serialize: serialize_1
207
+ };
208
+
209
+ exports.cookie = cookie;
210
+ exports.parse_1 = parse_1;
211
+ exports.serialize_1 = serialize_1;