@times-components/ts-slices 1.8.44-alpha.74 → 1.8.44-alpha.77
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/dist/utils/resizeImage.js +6 -4
- package/package.json +4 -4
- package/rnw.js +1 -1
- package/src/utils/resizeImage.ts +6 -5
|
@@ -6,10 +6,12 @@ const getResizeImage = (url, width) => {
|
|
|
6
6
|
const api = new URL(url);
|
|
7
7
|
const params = new URLSearchParams(api.search.slice(1));
|
|
8
8
|
params.set('resize', resize.toString());
|
|
9
|
-
const origin = api.origin
|
|
10
|
-
?
|
|
9
|
+
const origin = api.origin.includes('uat-thetimes')
|
|
10
|
+
? api.origin.replace('uat-thetimes', 'thetimes')
|
|
11
11
|
: api.origin;
|
|
12
12
|
return `${origin}${api.pathname}?${params.toString()}`;
|
|
13
13
|
};
|
|
14
|
-
export const resizeImage = (url, width) => url.includes('thetimes.
|
|
15
|
-
|
|
14
|
+
export const resizeImage = (url, width) => url.includes('thetimes.') && url.includes('/imageserver')
|
|
15
|
+
? getResizeImage(url, width)
|
|
16
|
+
: url;
|
|
17
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzaXplSW1hZ2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXRpbHMvcmVzaXplSW1hZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsTUFBTSxTQUFTLEdBQUcsQ0FBQyxHQUFHLEVBQUUsR0FBRyxFQUFFLEdBQUcsRUFBRSxHQUFHLEVBQUUsR0FBRyxFQUFFLEdBQUcsRUFBRSxHQUFHLEVBQUUsR0FBRyxFQUFFLEdBQUcsRUFBRSxHQUFHLEVBQUUsRUFBRSxDQUFDLENBQUM7QUFFekUsTUFBTSxjQUFjLEdBQUcsQ0FBQyxRQUFnQixFQUFFLEVBQUUsQ0FDMUMsU0FBUyxDQUFDLE1BQU0sQ0FDZCxDQUFDLEdBQUcsRUFBRSxLQUFLLEVBQUUsRUFBRSxDQUFDLENBQUMsUUFBUSxJQUFJLEtBQUssQ0FBQyxDQUFDLENBQUMsS0FBSyxDQUFDLENBQUMsQ0FBQyxHQUFHLENBQUMsRUFDakQsU0FBUyxDQUFDLENBQUMsQ0FBQyxDQUNiLENBQUM7QUFFSixNQUFNLGNBQWMsR0FBRyxDQUFDLEdBQVcsRUFBRSxLQUFhLEVBQUUsRUFBRTtJQUNwRCxNQUFNLFdBQVcsR0FBRyxjQUFjLENBQUMsS0FBSyxDQUFDLENBQUM7SUFDMUMsTUFBTSxNQUFNLEdBQUcsV0FBVyxHQUFHLE1BQU0sQ0FBQyxnQkFBZ0IsQ0FBQztJQUVyRCxNQUFNLEdBQUcsR0FBRyxJQUFJLEdBQUcsQ0FBQyxHQUFHLENBQUMsQ0FBQztJQUN6QixNQUFNLE1BQU0sR0FBRyxJQUFJLGVBQWUsQ0FBQyxHQUFHLENBQUMsTUFBTSxDQUFDLEtBQUssQ0FBQyxDQUFDLENBQUMsQ0FBQyxDQUFDO0lBQ3hELE1BQU0sQ0FBQyxHQUFHLENBQUMsUUFBUSxFQUFFLE1BQU0sQ0FBQyxRQUFRLEVBQUUsQ0FBQyxDQUFDO0lBRXhDLE1BQU0sTUFBTSxHQUFHLEdBQUcsQ0FBQyxNQUFNLENBQUMsUUFBUSxDQUFDLGNBQWMsQ0FBQztRQUNoRCxDQUFDLENBQUMsR0FBRyxDQUFDLE1BQU0sQ0FBQyxPQUFPLENBQUMsY0FBYyxFQUFFLFVBQVUsQ0FBQztRQUNoRCxDQUFDLENBQUMsR0FBRyxDQUFDLE1BQU0sQ0FBQztJQUVmLE9BQU8sR0FBRyxNQUFNLEdBQUcsR0FBRyxDQUFDLFFBQVEsSUFBSSxNQUFNLENBQUMsUUFBUSxFQUFFLEVBQUUsQ0FBQztBQUN6RCxDQUFDLENBQUM7QUFFRixNQUFNLENBQUMsTUFBTSxXQUFXLEdBQUcsQ0FBQyxHQUFXLEVBQUUsS0FBYSxFQUFFLEVBQUUsQ0FDeEQsR0FBRyxDQUFDLFFBQVEsQ0FBQyxXQUFXLENBQUMsSUFBSSxHQUFHLENBQUMsUUFBUSxDQUFDLGNBQWMsQ0FBQztJQUN2RCxDQUFDLENBQUMsY0FBYyxDQUFDLEdBQUcsRUFBRSxLQUFLLENBQUM7SUFDNUIsQ0FBQyxDQUFDLEdBQUcsQ0FBQyJ9
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@times-components/ts-slices",
|
|
3
|
-
"version": "1.8.44-alpha.
|
|
3
|
+
"version": "1.8.44-alpha.77+bdce7a88d0",
|
|
4
4
|
"description": "Reuseable Typescript React Components",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"dev": "dist/index.js",
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"node": ">=8.9"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@times-components/ts-styleguide": "^1.50.
|
|
54
|
+
"@times-components/ts-styleguide": "^1.50.11",
|
|
55
55
|
"date-fns": "2.28.0",
|
|
56
56
|
"lodash.get": "4.4.2",
|
|
57
57
|
"react": "16.9.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"@testing-library/react": "^12.1.2",
|
|
62
|
-
"@times-components/storybook": "^4.12.
|
|
62
|
+
"@times-components/storybook": "^4.12.11",
|
|
63
63
|
"@types/lodash.get": "4.4.6",
|
|
64
64
|
"@types/lodash.shuffle": "4.2.6",
|
|
65
65
|
"@types/mockdate": "2.0.0",
|
|
@@ -87,5 +87,5 @@
|
|
|
87
87
|
"@testing-library/jest-dom/extend-expect"
|
|
88
88
|
]
|
|
89
89
|
},
|
|
90
|
-
"gitHead": "
|
|
90
|
+
"gitHead": "bdce7a88d032ef454a9d44936d65c947439774fd"
|
|
91
91
|
}
|
package/rnw.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
module.exports=function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=5)}([function(e,t){e.exports=require("react")},function(e,t){e.exports=require("@times-components/ts-styleguide/rnw")},function(e,t){e.exports=require("styled-components")},function(e,t){var n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/,r=/^\./,a=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,l=/^\[object .+?Constructor\]$/,c="object"==typeof global&&global&&global.Object===Object&&global,d="object"==typeof self&&self&&self.Object===Object&&self,s=c||d||Function("return this")();var m,p=Array.prototype,u=Function.prototype,f=Object.prototype,h=s["__core-js_shared__"],y=(m=/[^.]+$/.exec(h&&h.keys&&h.keys.IE_PROTO||""))?"Symbol(src)_1."+m:"",g=u.toString,b=f.hasOwnProperty,x=f.toString,w=RegExp("^"+g.call(b).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),S=s.Symbol,v=p.splice,_=H(s,"Map"),k=H(Object,"create"),E=S?S.prototype:void 0,C=E?E.toString:void 0;function I(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function A(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function z(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function O(e,t){for(var n,i,r=e.length;r--;)if((n=e[r][0])===(i=t)||n!=n&&i!=i)return r;return-1}function j(e,t){for(var r,a=0,o=(t=function(e,t){if(L(e))return!1;var r=typeof e;if("number"==r||"symbol"==r||"boolean"==r||null==e||P(e))return!0;return i.test(e)||!n.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:L(r=t)?r:R(r)).length;null!=e&&a<o;)e=e[D(t[a++])];return a&&a==o?e:void 0}function F(e){return!(!B(e)||(t=e,y&&y in t))&&(function(e){var t=B(e)?x.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?w:l).test(function(e){if(null!=e){try{return g.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function N(e,t){var n,i,r=e.__data__;return("string"==(i=typeof(n=t))||"number"==i||"symbol"==i||"boolean"==i?"__proto__"!==n:null===n)?r["string"==typeof t?"string":"hash"]:r.map}function H(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return F(n)?n:void 0}I.prototype.clear=function(){this.__data__=k?k(null):{}},I.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},I.prototype.get=function(e){var t=this.__data__;if(k){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return b.call(t,e)?t[e]:void 0},I.prototype.has=function(e){var t=this.__data__;return k?void 0!==t[e]:b.call(t,e)},I.prototype.set=function(e,t){return this.__data__[e]=k&&void 0===t?"__lodash_hash_undefined__":t,this},A.prototype.clear=function(){this.__data__=[]},A.prototype.delete=function(e){var t=this.__data__,n=O(t,e);return!(n<0)&&(n==t.length-1?t.pop():v.call(t,n,1),!0)},A.prototype.get=function(e){var t=this.__data__,n=O(t,e);return n<0?void 0:t[n][1]},A.prototype.has=function(e){return O(this.__data__,e)>-1},A.prototype.set=function(e,t){var n=this.__data__,i=O(n,e);return i<0?n.push([e,t]):n[i][1]=t,this},z.prototype.clear=function(){this.__data__={hash:new I,map:new(_||A),string:new I}},z.prototype.delete=function(e){return N(this,e).delete(e)},z.prototype.get=function(e){return N(this,e).get(e)},z.prototype.has=function(e){return N(this,e).has(e)},z.prototype.set=function(e,t){return N(this,e).set(e,t),this};var R=T((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(P(e))return C?C.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return r.test(e)&&n.push(""),e.replace(a,(function(e,t,i,r){n.push(i?r.replace(o,"$1"):t||e)})),n}));function D(e){if("string"==typeof e||P(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function T(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var i=arguments,r=t?t.apply(this,i):i[0],a=n.cache;if(a.has(r))return a.get(r);var o=e.apply(this,i);return n.cache=a.set(r,o),o};return n.cache=new(T.Cache||z),n}T.Cache=z;var L=Array.isArray;function B(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function P(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==x.call(e)}e.exports=function(e,t,n){var i=null==e?void 0:j(e,t);return void 0===i?n:i}},function(e,t){e.exports=require("date-fns")},function(e,t,n){"use strict";n.r(t);var i=n(0),r=n.n(i),a=n(3),o=n.n(a);function l(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||d(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||d(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach((function(t){u(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var f=["sm","md","lg","xlg"],h=function(e){if(e){var t={};return f.reduce((function(n,i){var r=p(p({},t),o()(e,i));return t=r,p(p({},n),{},u({},i,r))}),{})}},y=function(e,t){return!0===o()(o()(t,e),"isSideBySide")},g=function(e,t){return!0===o()(o()(t,e),"isCentered")},b=function(e,t){return"calc(".concat(e,"% - ").concat(function(e){return 12*(2*e-2)/e}(t),"px)")},x=n(4),w=function(e){return o()(e,"images.alt",o()(e,"headline"))},S=[760,660,560,480,380,320,270,230,180,120,80],v=function(e,t){var n,i=(n=t,S.reduce((function(e,t){return n<=t?t:e}),S[0]))*window.devicePixelRatio,r=new URL(e),a=new URLSearchParams(r.search.slice(1));a.set("resize",i.toString());var o="https://www.uat-thetimes.co.uk"===r.origin?"https://www.thetimes.co.uk":r.origin;return"".concat(o).concat(r.pathname,"?").concat(a.toString())},_=function(e,t){return e.includes("thetimes.co.uk/imageserver")?v(e,t):e},k=n(2),E=n.n(k),C=E.a.div.withConfig({displayName:"styles__LazyContainer",componentId:"qsbah5-0"})(["position:absolute;width:100%;height:100%;background-color:",";border-radius:",";transition:0.5s;div,img{width:100%;height:100%;border-radius:",";opacity:",";transition:opacity 0.5s;}"],(function(e){return e.visible?"transparent":"#f0f0f0"}),(function(e){return e.isRoundal?"50%":0}),(function(e){return e.isRoundal?"50%":0}),(function(e){return e.visible?1:0})),I=E.a.div.withConfig({displayName:"styles__BackgroundImage",componentId:"qsbah5-1"})(["background:",";background-size:cover;"],(function(e){var t=e.src;return t?"url(".concat(t,") no-repeat center center"):"none"}));function A(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return z(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var O=function(e){var t=e.url,n=e.alt,a=e.isRoundal,o=e.isBackground,l=r.a.createRef(),c=A(Object(i.useState)(),2),d=c[0],s=c[1];return Object(i.useEffect)((function(){if("IntersectionObserver"in window){var e=new IntersectionObserver((function(n){return n.forEach((function(n){if(n.isIntersecting&&(e.disconnect(),t&&l.current)){var i=l.current.offsetWidth,r=new Image;r.onload=function(){return s(r.src)},r.src=_(t,i)}}))}),{rootMargin:"60px"});return l.current&&e.observe(l.current),function(){return e.disconnect()}}t&&l.current&&s(_(t,l.current.offsetWidth))}),[t,l]),r.a.createElement(C,{visible:!!d,isRoundal:a},o?r.a.createElement(I,{src:d,ref:l,role:"img","aria-label":n}):r.a.createElement("img",{src:d,alt:n,ref:l}))},j=n(1),F=function(e,t){return y(e,t)||function(e,t){return!0===o()(o()(t,e),"isImageHidden")}(e,t)?0:"12px"},N=function(e,t){return t&&t.includes(e)?"block":"none"},H=E.a.div.withConfig({displayName:"styles__ImageContainer",componentId:"sc-8lglkt-0"})(["margin-bottom:",";@media (min-width:","px){margin-bottom:",";}@media (min-width:","px){margin-bottom:",";}@media (min-width:","px){margin-bottom:",";}"],(function(e){var t=e.schema;return F("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return F("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return F("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return F("xlg",t)})),R=E.a.div.withConfig({displayName:"styles__ImageRatio",componentId:"sc-8lglkt-1"})(["position:relative;display:",";overflow:hidden;&:after{content:'';display:block;padding-bottom:",";}@media (min-width:","px){display:",";}@media (min-width:","px){display:",";}@media (min-width:","px){display:",";}"],(function(e){var t=e.schema;return N("sm",t)}),(function(e){return function(e){switch(e){case"16:9":return"56.25%";case"3:2":return"66.66%";case"1:1":return"100%";default:return 0}}(e.ratio)}),j.breakpoints.medium,(function(e){var t=e.schema;return N("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return N("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return N("xlg",t)}));function D(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return T(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return T(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var L=function(e){var t,n,i=e.article,a=e.displaySchema,d=e.clickHandler,s=(t=a)?Object.entries(t).reduce((function(e,t){var i=c(t,2),r=i[0],a=i[1],d=o()(a,"imageRatio",n);return n=d,d&&!o()(a,"isImageHidden")?p(p({},e),{},u({},d,[].concat(l(o()(e,d,[])),[r]))):e}),{}):{};return r.a.createElement(H,{schema:a},r.a.createElement("a",{onClick:function(e){i&&d&&d(e,i)},href:i.url},Object.entries(s).map((function(e,t){var n=D(e,2),a=n[0],l=n[1],c=function(e,t){return t.images.crops.find((function(t){return"*"===t.ratio||t.ratio===e}))}(a,i);return r.a.createElement(R,{key:t,ratio:a,schema:l},r.a.createElement(O,{url:o()(c,"url"),alt:w(i),isRoundal:"1:1"===a,isBackground:"*"===o()(c,"ratio")}))}))))},B=function(e,t){return o()(o()(t,e),"headlineFontSize",10)},P=function(e,t){return g(e,t)?"sm"===e||"md"===e?"90%":"80%":"100%"},M=function(e,t){return g(e,t)?"center":"left"},U=E.a.div.withConfig({displayName:"styles__HeadlineContainer",componentId:"k0mgwi-0"})(["width:",";margin:0 auto;@media (min-width:","px){width:",";}@media (min-width:","px){width:",";}@media (min-width:","px){width:",";}a{text-decoration:none;h3{margin:0;color:",";font-size:","px;line-height:","px;font-family:",";font-weight:normal;text-align:",";@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}}&:hover{h3{color:#006699;}}}"],(function(e){var t=e.schema;return P("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return P("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return P("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return P("xlg",t)}),j.colours.functional.brandColour,(function(e){var t=e.schema;return B("sm",t)}),(function(e){var t=e.schema;return B("sm",t)}),j.fonts.headline,(function(e){var t=e.schema;return M("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return B("md",t)}),(function(e){var t=e.schema;return B("md",t)}),(function(e){var t=e.schema;return M("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return B("lg",t)}),(function(e){var t=e.schema;return B("lg",t)}),(function(e){var t=e.schema;return M("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return B("xlg",t)}),(function(e){var t=e.schema;return B("xlg",t)}),(function(e){var t=e.schema;return M("xlg",t)})),$=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t.headline)return null;return r.a.createElement(U,{schema:n},r.a.createElement("a",{onClick:function(e){t&&i&&i(e,t)},href:t.url},r.a.createElement("h3",null,t.headline)))},q=function(e,t){return y(e,t)?"row":"column"},W=function(e,t){return y(e,t)?o()(o()(t,e),"sideBySideWidth","50%"):"100%"},Y=function(e,t){return y(e,t)?"".concat(o()(o()(t,e),"sideBySidePadding",8),"px"):0},V=function(e,t){return g(e,t)?"center":"flex-start"},G=function(e,t){return g(e,t)&&!y(e,t)?"16px 0 24px 0":0},J=function(e,t){return o()(o()(t,e),"backgroundColor","transparent")},K=E.a.article.withConfig({displayName:"shared-styles__ArticleContainer",componentId:"sc-1kek94e-0"})(["display:flex;flex-direction:",";background-color:",";@media (min-width:","px){flex-direction:",";background-color:",";}@media (min-width:","px){flex-direction:",";background-color:",";}@media (min-width:","px){flex-direction:",";background-color:",";}"],(function(e){var t=e.schema;return q("sm",t)}),(function(e){var t=e.schema;return J("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return q("md",t)}),(function(e){var t=e.schema;return J("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return q("lg",t)}),(function(e){var t=e.schema;return J("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return q("xlg",t)}),(function(e){var t=e.schema;return J("xlg",t)})),Q=E.a.div.withConfig({displayName:"shared-styles__SideBySideColumn",componentId:"sc-1kek94e-1"})(["width:100%;&:first-of-type{flex-shrink:0;width:",";padding-right:",";}&:last-of-type{display:flex;flex-direction:column;justify-content:",";align-items:",";margin:",";padding-left:",";}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}"],(function(e){var t=e.schema;return W("sm",t)}),(function(e){var t=e.schema;return Y("sm",t)}),(function(e){var t=e.schema;return V("sm",t)}),(function(e){var t=e.schema;return V("sm",t)}),(function(e){var t=e.schema;return G("sm",t)}),(function(e){var t=e.schema;return Y("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return W("md",t)}),(function(e){var t=e.schema;return Y("md",t)}),(function(e){var t=e.schema;return V("md",t)}),(function(e){var t=e.schema;return V("md",t)}),(function(e){var t=e.schema;return G("md",t)}),(function(e){var t=e.schema;return Y("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return W("lg",t)}),(function(e){var t=e.schema;return Y("lg",t)}),(function(e){var t=e.schema;return V("lg",t)}),(function(e){var t=e.schema;return V("lg",t)}),(function(e){var t=e.schema;return G("lg",t)}),(function(e){var t=e.schema;return Y("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return W("xlg",t)}),(function(e){var t=e.schema;return Y("xlg",t)}),(function(e){var t=e.schema;return V("xlg",t)}),(function(e){var t=e.schema;return V("xlg",t)}),(function(e){var t=e.schema;return G("xlg",t)}),(function(e){var t=e.schema;return Y("xlg",t)})),X=E.a.p.withConfig({displayName:"shared-styles__Label",componentId:"sc-1kek94e-2"})(["margin:0 0 4px 0;color:",";font-size:12px;line-height:16px;letter-spacing:0.5px;font-family:",";text-transform:uppercase;"],j.colours.functional.secondary,j.fonts.supporting),Z=function(e,t){return g(e,t)?"sm"===e||"md"===e?"90%":"80%":"100%"},ee=function(e,t){return g(e,t)?"center":"left"},te=E.a.p.withConfig({displayName:"styles__Strapline",componentId:"p3h2iu-0"})(["width:",";margin:4px auto 0 auto;color:",";font-size:14px;line-height:20px;text-align:",";font-family:",";@media (min-width:","px){width:",";text-align:",";}@media (min-width:","px){width:",";text-align:",";}@media (min-width:","px){width:",";text-align:",";}"],(function(e){var t=e.schema;return Z("sm",t)}),j.colours.functional.secondary,(function(e){var t=e.schema;return ee("sm",t)}),j.fonts.body,j.breakpoints.medium,(function(e){var t=e.schema;return Z("md",t)}),(function(e){var t=e.schema;return ee("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return Z("lg",t)}),(function(e){var t=e.schema;return ee("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return Z("xlg",t)}),(function(e){var t=e.schema;return ee("xlg",t)})),ne=E.a.p.withConfig({displayName:"styles__TimeSince",componentId:"p3h2iu-1"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;letter-spacing:1px;font-family:",";text-transform:uppercase;"],j.colours.functional.secondary,j.fonts.supporting),ie=E.a.div.withConfig({displayName:"styles__Link",componentId:"p3h2iu-2"})(["margin-top:8px;a{color:#006699;font-size:13px;line-height:13px;letter-spacing:0px;font-family:",";font-weight:500;text-decoration:none;&:after{display:inline-block;content:'\\E003';font-size:10px;font-family:iconfont;padding:0 0 1px 6px;vertical-align:middle;}}"],j.fonts.supporting),re=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t)return null;var a=t.standfirst||t.summary,l=function(e){var t=Object(x.parseISO)(o()(e,"datePublished","")),n=Object(x.parseISO)(o()(e,"dateUpdated","")),i=Object(x.max)([t,n].filter((function(e){return Object(x.isValid)(e)}))),r=Object(x.differenceInCalendarDays)(new Date,i);return!Object(x.isValid)(i)||r>=7?null:"".concat(Object(x.formatDistanceToNowStrict)(i,{roundingMethod:"floor"})," ago")}(t);return r.a.createElement(K,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i})),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}),a&&r.a.createElement(te,{schema:n},a),l&&r.a.createElement(ne,null,l),t.cta&&r.a.createElement(ie,null,r.a.createElement("a",{href:t.url},t.cta))))},ae=E.a.div.withConfig({displayName:"shared-styles__SliceContainer",componentId:"ismxwo-0"})(["display:flex;flex-wrap:wrap;justify-content:space-between;margin:0 auto;padding:",";@media (min-width:","px){max-width:520px;}@media (min-width:","px){max-width:860px;padding:",";}@media (min-width:","px){max-width:1024px;}@media (min-width:","px){max-width:1180px;}"],(function(e){var t=e.styles;return t&&t.removePadding?0:"0 16px"}),j.breakpoints.small,j.breakpoints.medium,(function(e){var t=e.styles;return t&&t.removePadding?0:"0 20px"}),j.breakpoints.wide,j.breakpoints.huge),oe=E.a.div.withConfig({displayName:"shared-styles__SlotContainer",componentId:"ismxwo-1"})(["position:relative;width:100%;margin-bottom:",";padding-bottom:",";box-sizing:content-box;:before{content:'';display:none;position:absolute;top:0;right:0;bottom:0;width:1px;background-color:",";}:after{content:'';display:",";position:absolute;right:0;bottom:0;left:0;height:1px;background-color:",";}"],(function(e){return e.collapse?0:"12px"}),(function(e){return e.collapse?0:"12px"}),(function(e){var t=e.styles;return t&&t.lineColor?t.lineColor:"#dbdbdb"}),(function(e){return e.collapse?"none":"block"}),(function(e){var t=e.styles;return t&&t.lineColor?t.lineColor:"#dbdbdb"})),le=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-614vlg-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),ce=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-614vlg-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:0;padding-bottom:24px;}"],j.breakpoints.medium),de=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(le,{styles:n},r.a.createElement(ce,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",isCentered:!0,headlineFontSize:28,backgroundColor:"#f0f0f0"},md:{isSideBySide:!0},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})))})),se=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-1r0nv22-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),me=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-1r0nv22-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium),pe=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-1r0nv22-2"})(["@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(33.33,3)),ue=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(se,{styles:n},r.a.createElement(me,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:28},md:{imageRatio:"16:9"},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})),r.a.createElement(pe,{styles:n},r.a.createElement(re,{article:o()(t,"children[1].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},lg:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})))})),fe=function(e){return e&&("maincomment"===e.template||"magazinecomment"===e.template||"externalcomment"===e.template)},he=E()(K).withConfig({displayName:"styles__ArticleContainer",componentId:"sc-2eizyd-0"})(["align-items:center;"]),ye=E.a.div.withConfig({displayName:"styles__ImageContainer",componentId:"sc-2eizyd-1"})(["max-width:120px;margin:0 auto;@media (min-width:","px){max-width:140px;}"],j.breakpoints.huge),ge=E.a.p.withConfig({displayName:"styles__Byline",componentId:"sc-2eizyd-2"})(["margin:0 0 4px 0;color:",";font-size:22px;line-height:22px;font-family:",";@media (min-width:","px){font-size:24px;line-height:24px;}"],j.colours.functional.secondary,j.fonts.headlineRegular,j.breakpoints.huge),be=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;return t?r.a.createElement(he,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(ye,null,r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i}))),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),t.byline&&r.a.createElement(ge,null,t.byline),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}))):null},xe=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"fss0bs-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),we=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"fss0bs-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium),Se=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"fss0bs-2"})(["@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(33.33,3)),ve=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(xe,{styles:n},r.a.createElement(we,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:28},md:{imageRatio:"16:9"},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})),r.a.createElement(Se,{styles:n},r.a.createElement(oe,{styles:n},r.a.createElement(re,{article:o()(t,"children[1].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},lg:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})),fe(o()(t,"children[2].article"))?r.a.createElement(be,{article:t.children[2].article,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{headlineFontSize:16},lg:{sideBySideWidth:"50%"},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:o()(t,"children[2].article"),displaySchema:h({sm:{isSideBySide:!0,imageRatio:"3:2",headlineFontSize:18},md:{headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i})))})),_e=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"rqwi1t-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium,b(50,2)),ke=E.a.div.withConfig({displayName:"styles__SideBySideColumn",componentId:"rqwi1t-1"})(["display:flex;flex-wrap:wrap;justify-content:space-between;"]),Ee=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"rqwi1t-2"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(50,2)),Ce=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"rqwi1t-3"})(["width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:last-of-type{padding-left:12px;}"],b(50,2));function Ie(e){return function(e){if(Array.isArray(e))return Ae(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Ae(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ae(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ae(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var ze=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},r.a.createElement(_e,{styles:n},r.a.createElement(ke,null,Ie(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ce,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18},md:{imageRatio:"16:9"},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))}))),r.a.createElement(re,{article:o()(t,"children[2].article"),displaySchema:h({sm:{isSideBySide:!0,sideBySidePadding:12,imageRatio:"3:2",headlineFontSize:18},md:{imageRatio:"16:9",headlineFontSize:22},lg:{headlineFontSize:24}}),clickHandler:i})),r.a.createElement(Ee,{styles:n},r.a.createElement(re,{article:o()(t,"children[3].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})))})),Oe=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"z7ncw3-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}"],j.breakpoints.medium,b(50,2)),je=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(Oe,{key:t,styles:n},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{imageRatio:"16:9",headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i}))})))})),Fe=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"xnsfmb-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Ne=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"xnsfmb-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),He=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"xnsfmb-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Re=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"xnsfmb-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}@media (min-width:","px){width:100%;margin-bottom:12px;padding-bottom:12px;&:first-of-type{padding-right:0;:before{display:none;}}&:last-of-type{margin-bottom:0;padding:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function De(e){return function(e){if(Array.isArray(e))return Te(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Te(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Te(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Te(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var Le=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Fe,{styles:n},De(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ne,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(He,{styles:n},De(Array(2)).fill(null).map((function(e,a){var l=o()(t,"children[".concat(a+2,"].article"));return r.a.createElement(Re,{key:a,styles:n},fe(l)?r.a.createElement(be,{article:l,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{sideBySideWidth:"50%",headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:l,displaySchema:h({sm:{isSideBySide:!0,imageRatio:"3:2",headlineFontSize:18},md:{headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}))}))))})),Be=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-7y5fg-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Pe=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-7y5fg-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),Me=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"sc-7y5fg-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Ue=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-7y5fg-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;:before{display:none;}}}@media (min-width:","px){width:100%;margin-bottom:12px;padding:0 0 12px 0;:before{display:none;}&:last-of-type{margin-bottom:0;padding-bottom:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function $e(e){return function(e){if(Array.isArray(e))return qe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return qe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return qe(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function qe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var We=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Be,{styles:n},$e(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Pe,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(Me,{styles:n},$e(Array(3)).fill(null).map((function(e,a){return r.a.createElement(Ue,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a+2,"].article")),displaySchema:h({sm:{isImageHidden:!0,imageRatio:"3:2",headlineFontSize:18},lg:{isSideBySide:!0,isImageHidden:!1,headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}))}))))})),Ye=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-11upv3n-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Ve=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-11upv3n-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),Ge=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"sc-11upv3n-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Je=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-11upv3n-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;:before{display:none;}}}@media (min-width:","px){width:100%;margin-bottom:12px;padding:0 0 12px 0;:before{display:none;}&:last-of-type{margin-bottom:0;padding-bottom:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function Ke(e){return function(e){if(Array.isArray(e))return Qe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Qe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Qe(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Qe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var Xe=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Ye,{styles:n},Ke(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ve,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(Ge,{styles:n},Ke(Array(3)).fill(null).map((function(e,a){return r.a.createElement(Je,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a+2,"].article")),displaySchema:h({sm:{isImageHidden:!0,headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))}))))})),Ze=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"bazswq-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}:after{display:block;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],j.breakpoints.medium,b(33.33,3)),et=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(Ze,{key:t,styles:n,collapse:!e.article},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),tt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-1gqjewy-0"})(["width:",";&:nth-of-type(odd){padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(even){padding-left:12px;}@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px !important;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],b(50,2),j.breakpoints.medium,b(25,4)),nt=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(tt,{key:t,styles:n},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),it=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"c5tu9p-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),rt=E()(oe).withConfig({displayName:"styles__SlotContainerLarge",componentId:"c5tu9p-1"})(["order:1;@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(3){padding-left:12px;}}@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(3){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide,b(33.33,3)),at=E()(oe).withConfig({displayName:"styles__SlotContainerSmall",componentId:"c5tu9p-2"})(["order:2;@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:nth-of-type(2){padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}@media (min-width:","px){order:1;&:nth-of-type(2){padding-left:12px;:before{bottom:24px;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function ot(e){return function(e){if(Array.isArray(e))return lt(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return lt(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return lt(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function lt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var ct=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(it,{styles:n},ot(Array(2)).fill(null).map((function(e,a){var l=o()(t,"children[".concat(2*a,"].article")),c=o()(t,"children[".concat(2*a+1,"].article"));return r.a.createElement(r.a.Fragment,{key:a},r.a.createElement(rt,{styles:n},r.a.createElement(re,{article:l,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i})),r.a.createElement(at,{styles:n},fe(c)?r.a.createElement(be,{article:c,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{sideBySideWidth:"50%",headlineFontSize:16},lg:{isSideBySide:!1},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:c,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"3:2",headlineFontSize:18},md:{isImageHidden:!1,isSideBySide:!0,headlineFontSize:16},lg:{isSideBySide:!1},xlg:{headlineFontSize:18}}),clickHandler:i})))})))})),dt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-189xcog-0"})(["width:",";&:nth-of-type(odd){padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(even){padding-left:12px;}@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px !important;}&:nth-of-type(5n + 1){padding-left:0;}&:nth-of-type(5n){padding-right:0;&:before{display:none;}}}"],b(50,2),j.breakpoints.medium,b(20,5)),st=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(dt,{key:t,styles:n},r.a.createElement(re,{article:o()(e,"article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18,isCentered:!0},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),mt=function(e,t){var n=new Date(Date.UTC(t,e+1,0)),i=n.getDay(),r=n.getDate()-i,a=new Date(Date.UTC(t,e,r));return a.setHours(1),a},pt=function(e){if(e){var t=function(e){var t=new Date(e);return new Date(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate(),t.getUTCHours(),t.getUTCMinutes())}(e),n=Object(x.addMinutes)(t,function(e){var t=mt(2,e.getFullYear()),n=mt(9,e.getFullYear()),i=e.getTime()>=t.getTime(),r=e.getTime()<n.getTime();return i&&r}(t)?60:0);return Object(x.format)(n,"MMMM dd yyyy, h.mmaaa")}return null},ut=E.a.p.withConfig({displayName:"styles__DateTime",componentId:"sc-1p1alcs-0"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;font-family:",";"],j.colours.functional.secondary,j.fonts.supporting),ft=E.a.p.withConfig({displayName:"styles__Byline",componentId:"sc-1p1alcs-1"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;font-family:",";"],j.colours.functional.brandColour,j.fonts.supporting),ht=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t)return null;var a=pt(t.datePublished);return r.a.createElement(K,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i})),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}),a&&r.a.createElement(ut,null,a),t.byline&&r.a.createElement(ft,null,t.byline)))},yt=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"b33h2c-0"})(["@media (min-width:","px){flex-wrap:nowrap;width:80.8%;max-width:none;padding:0;}@media (min-width:","px){width:56.2%;}"],j.breakpoints.medium,j.breakpoints.wide),gt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"b33h2c-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:0;padding-bottom:24px;}"],j.breakpoints.medium),bt=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(yt,{styles:n},r.a.createElement(gt,{styles:n},r.a.createElement(ht,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"16:9",headlineFontSize:22},md:{isSideBySide:!0}}),clickHandler:i})))})),xt=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"v1jynn-0"})(["@media (min-width:","px){width:80.8%;max-width:none;padding:0;}@media (min-width:","px){width:56.2%;}"],j.breakpoints.medium,j.breakpoints.wide),wt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"v1jynn-1"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}"],j.breakpoints.medium,b(50,2)),St=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(xt,{styles:n},t.children.map((function(e,t){return r.a.createElement(wt,{key:t,styles:n},r.a.createElement(ht,{article:e.article,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"16:9",headlineFontSize:22},md:{isImageHidden:!1}}),clickHandler:i}))})))})),vt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"yjxerl-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}:after{display:block;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],j.breakpoints.medium,b(33.33,3)),_t=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(vt,{key:t,styles:n},r.a.createElement(ht,{article:e.article,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"16:9",headlineFontSize:22},md:{isImageHidden:!1}}),clickHandler:i}))})))})),kt=function(e){var t=e.slice,n=e.styles,i=e.clickHandler,a=function(e){switch(e){case"LEAD_1":case"LEAD_1_COMPONENT":case"INTERACTIVE_FULL_WIDTH":return de;case"LEAD_1_AND_1":case"LEAD_1_AND_1_COMPONENT":return ue;case"LEAD_1_AND_2":case"LEAD_1_AND_2_COLUMNIST":return ve;case"LEAD_1_AND_3_REVERSED":return ze;case"LEAD_2":case"LEAD_2_COMPONENT":case"INTERACTIVE_HALF_WIDTH":return je;case"SECONDARY_2_AND_2":return Le;case"SECONDARY_2_AND_3":return We;case"SECONDARY_2_AND_3_NO_PIC":return Xe;case"SECONDARY_3":return et;case"SECONDARY_4":return nt;case"SECONDARY_4_ODD":case"SECONDARY_4_ODD_COLUMNIST":return ct;case"SECONDARY_10":return st;case"RELATED_ARTICLE_1":return bt;case"RELATED_ARTICLE_2":return St;case"RELATED_ARTICLE_3":return _t;default:return function(){return null}}}(t.name);return r.a.createElement(a,{slice:t,styles:n,clickHandler:i})};n.d(t,"Slice",(function(){return kt}))}]);
|
|
1
|
+
module.exports=function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=5)}([function(e,t){e.exports=require("react")},function(e,t){e.exports=require("@times-components/ts-styleguide/rnw")},function(e,t){e.exports=require("styled-components")},function(e,t){var n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/,r=/^\./,a=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,l=/^\[object .+?Constructor\]$/,c="object"==typeof global&&global&&global.Object===Object&&global,d="object"==typeof self&&self&&self.Object===Object&&self,s=c||d||Function("return this")();var m,p=Array.prototype,u=Function.prototype,f=Object.prototype,h=s["__core-js_shared__"],y=(m=/[^.]+$/.exec(h&&h.keys&&h.keys.IE_PROTO||""))?"Symbol(src)_1."+m:"",g=u.toString,b=f.hasOwnProperty,x=f.toString,w=RegExp("^"+g.call(b).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),S=s.Symbol,v=p.splice,_=H(s,"Map"),k=H(Object,"create"),E=S?S.prototype:void 0,C=E?E.toString:void 0;function I(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function A(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function z(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function O(e,t){for(var n,i,r=e.length;r--;)if((n=e[r][0])===(i=t)||n!=n&&i!=i)return r;return-1}function j(e,t){for(var r,a=0,o=(t=function(e,t){if(L(e))return!1;var r=typeof e;if("number"==r||"symbol"==r||"boolean"==r||null==e||P(e))return!0;return i.test(e)||!n.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:L(r=t)?r:R(r)).length;null!=e&&a<o;)e=e[D(t[a++])];return a&&a==o?e:void 0}function F(e){return!(!B(e)||(t=e,y&&y in t))&&(function(e){var t=B(e)?x.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?w:l).test(function(e){if(null!=e){try{return g.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function N(e,t){var n,i,r=e.__data__;return("string"==(i=typeof(n=t))||"number"==i||"symbol"==i||"boolean"==i?"__proto__"!==n:null===n)?r["string"==typeof t?"string":"hash"]:r.map}function H(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return F(n)?n:void 0}I.prototype.clear=function(){this.__data__=k?k(null):{}},I.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},I.prototype.get=function(e){var t=this.__data__;if(k){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return b.call(t,e)?t[e]:void 0},I.prototype.has=function(e){var t=this.__data__;return k?void 0!==t[e]:b.call(t,e)},I.prototype.set=function(e,t){return this.__data__[e]=k&&void 0===t?"__lodash_hash_undefined__":t,this},A.prototype.clear=function(){this.__data__=[]},A.prototype.delete=function(e){var t=this.__data__,n=O(t,e);return!(n<0)&&(n==t.length-1?t.pop():v.call(t,n,1),!0)},A.prototype.get=function(e){var t=this.__data__,n=O(t,e);return n<0?void 0:t[n][1]},A.prototype.has=function(e){return O(this.__data__,e)>-1},A.prototype.set=function(e,t){var n=this.__data__,i=O(n,e);return i<0?n.push([e,t]):n[i][1]=t,this},z.prototype.clear=function(){this.__data__={hash:new I,map:new(_||A),string:new I}},z.prototype.delete=function(e){return N(this,e).delete(e)},z.prototype.get=function(e){return N(this,e).get(e)},z.prototype.has=function(e){return N(this,e).has(e)},z.prototype.set=function(e,t){return N(this,e).set(e,t),this};var R=T((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(P(e))return C?C.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return r.test(e)&&n.push(""),e.replace(a,(function(e,t,i,r){n.push(i?r.replace(o,"$1"):t||e)})),n}));function D(e){if("string"==typeof e||P(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function T(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var i=arguments,r=t?t.apply(this,i):i[0],a=n.cache;if(a.has(r))return a.get(r);var o=e.apply(this,i);return n.cache=a.set(r,o),o};return n.cache=new(T.Cache||z),n}T.Cache=z;var L=Array.isArray;function B(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function P(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==x.call(e)}e.exports=function(e,t,n){var i=null==e?void 0:j(e,t);return void 0===i?n:i}},function(e,t){e.exports=require("date-fns")},function(e,t,n){"use strict";n.r(t);var i=n(0),r=n.n(i),a=n(3),o=n.n(a);function l(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||d(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||d(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach((function(t){u(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var f=["sm","md","lg","xlg"],h=function(e){if(e){var t={};return f.reduce((function(n,i){var r=p(p({},t),o()(e,i));return t=r,p(p({},n),{},u({},i,r))}),{})}},y=function(e,t){return!0===o()(o()(t,e),"isSideBySide")},g=function(e,t){return!0===o()(o()(t,e),"isCentered")},b=function(e,t){return"calc(".concat(e,"% - ").concat(function(e){return 12*(2*e-2)/e}(t),"px)")},x=n(4),w=function(e){return o()(e,"images.alt",o()(e,"headline"))},S=[760,660,560,480,380,320,270,230,180,120,80],v=function(e,t){var n,i=(n=t,S.reduce((function(e,t){return n<=t?t:e}),S[0]))*window.devicePixelRatio,r=new URL(e),a=new URLSearchParams(r.search.slice(1));a.set("resize",i.toString());var o=r.origin.includes("uat-thetimes")?r.origin.replace("uat-thetimes","thetimes"):r.origin;return"".concat(o).concat(r.pathname,"?").concat(a.toString())},_=function(e,t){return e.includes("thetimes.")&&e.includes("/imageserver")?v(e,t):e},k=n(2),E=n.n(k),C=E.a.div.withConfig({displayName:"styles__LazyContainer",componentId:"qsbah5-0"})(["position:absolute;width:100%;height:100%;background-color:",";border-radius:",";transition:0.5s;div,img{width:100%;height:100%;border-radius:",";opacity:",";transition:opacity 0.5s;}"],(function(e){return e.visible?"transparent":"#f0f0f0"}),(function(e){return e.isRoundal?"50%":0}),(function(e){return e.isRoundal?"50%":0}),(function(e){return e.visible?1:0})),I=E.a.div.withConfig({displayName:"styles__BackgroundImage",componentId:"qsbah5-1"})(["background:",";background-size:cover;"],(function(e){var t=e.src;return t?"url(".concat(t,") no-repeat center center"):"none"}));function A(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return z(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var O=function(e){var t=e.url,n=e.alt,a=e.isRoundal,o=e.isBackground,l=r.a.createRef(),c=A(Object(i.useState)(),2),d=c[0],s=c[1];return Object(i.useEffect)((function(){if("IntersectionObserver"in window){var e=new IntersectionObserver((function(n){return n.forEach((function(n){if(n.isIntersecting&&(e.disconnect(),t&&l.current)){var i=l.current.offsetWidth,r=new Image;r.onload=function(){return s(r.src)},r.src=_(t,i)}}))}),{rootMargin:"60px"});return l.current&&e.observe(l.current),function(){return e.disconnect()}}t&&l.current&&s(_(t,l.current.offsetWidth))}),[t,l]),r.a.createElement(C,{visible:!!d,isRoundal:a},o?r.a.createElement(I,{src:d,ref:l,role:"img","aria-label":n}):r.a.createElement("img",{src:d,alt:n,ref:l}))},j=n(1),F=function(e,t){return y(e,t)||function(e,t){return!0===o()(o()(t,e),"isImageHidden")}(e,t)?0:"12px"},N=function(e,t){return t&&t.includes(e)?"block":"none"},H=E.a.div.withConfig({displayName:"styles__ImageContainer",componentId:"sc-8lglkt-0"})(["margin-bottom:",";@media (min-width:","px){margin-bottom:",";}@media (min-width:","px){margin-bottom:",";}@media (min-width:","px){margin-bottom:",";}"],(function(e){var t=e.schema;return F("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return F("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return F("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return F("xlg",t)})),R=E.a.div.withConfig({displayName:"styles__ImageRatio",componentId:"sc-8lglkt-1"})(["position:relative;display:",";overflow:hidden;&:after{content:'';display:block;padding-bottom:",";}@media (min-width:","px){display:",";}@media (min-width:","px){display:",";}@media (min-width:","px){display:",";}"],(function(e){var t=e.schema;return N("sm",t)}),(function(e){return function(e){switch(e){case"16:9":return"56.25%";case"3:2":return"66.66%";case"1:1":return"100%";default:return 0}}(e.ratio)}),j.breakpoints.medium,(function(e){var t=e.schema;return N("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return N("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return N("xlg",t)}));function D(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var i,r,a=[],o=!0,l=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(a.push(i.value),!t||a.length!==t);o=!0);}catch(e){l=!0,r=e}finally{try{o||null==n.return||n.return()}finally{if(l)throw r}}return a}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return T(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return T(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var L=function(e){var t,n,i=e.article,a=e.displaySchema,d=e.clickHandler,s=(t=a)?Object.entries(t).reduce((function(e,t){var i=c(t,2),r=i[0],a=i[1],d=o()(a,"imageRatio",n);return n=d,d&&!o()(a,"isImageHidden")?p(p({},e),{},u({},d,[].concat(l(o()(e,d,[])),[r]))):e}),{}):{};return r.a.createElement(H,{schema:a},r.a.createElement("a",{onClick:function(e){i&&d&&d(e,i)},href:i.url},Object.entries(s).map((function(e,t){var n=D(e,2),a=n[0],l=n[1],c=function(e,t){return t.images.crops.find((function(t){return"*"===t.ratio||t.ratio===e}))}(a,i);return r.a.createElement(R,{key:t,ratio:a,schema:l},r.a.createElement(O,{url:o()(c,"url"),alt:w(i),isRoundal:"1:1"===a,isBackground:"*"===o()(c,"ratio")}))}))))},B=function(e,t){return o()(o()(t,e),"headlineFontSize",10)},P=function(e,t){return g(e,t)?"sm"===e||"md"===e?"90%":"80%":"100%"},M=function(e,t){return g(e,t)?"center":"left"},U=E.a.div.withConfig({displayName:"styles__HeadlineContainer",componentId:"k0mgwi-0"})(["width:",";margin:0 auto;@media (min-width:","px){width:",";}@media (min-width:","px){width:",";}@media (min-width:","px){width:",";}a{text-decoration:none;h3{margin:0;color:",";font-size:","px;line-height:","px;font-family:",";font-weight:normal;text-align:",";@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}@media (min-width:","px){font-size:","px;line-height:","px;text-align:",";}}&:hover{h3{color:#006699;}}}"],(function(e){var t=e.schema;return P("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return P("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return P("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return P("xlg",t)}),j.colours.functional.brandColour,(function(e){var t=e.schema;return B("sm",t)}),(function(e){var t=e.schema;return B("sm",t)}),j.fonts.headline,(function(e){var t=e.schema;return M("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return B("md",t)}),(function(e){var t=e.schema;return B("md",t)}),(function(e){var t=e.schema;return M("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return B("lg",t)}),(function(e){var t=e.schema;return B("lg",t)}),(function(e){var t=e.schema;return M("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return B("xlg",t)}),(function(e){var t=e.schema;return B("xlg",t)}),(function(e){var t=e.schema;return M("xlg",t)})),$=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t.headline)return null;return r.a.createElement(U,{schema:n},r.a.createElement("a",{onClick:function(e){t&&i&&i(e,t)},href:t.url},r.a.createElement("h3",null,t.headline)))},q=function(e,t){return y(e,t)?"row":"column"},W=function(e,t){return y(e,t)?o()(o()(t,e),"sideBySideWidth","50%"):"100%"},Y=function(e,t){return y(e,t)?"".concat(o()(o()(t,e),"sideBySidePadding",8),"px"):0},V=function(e,t){return g(e,t)?"center":"flex-start"},G=function(e,t){return g(e,t)&&!y(e,t)?"16px 0 24px 0":0},J=function(e,t){return o()(o()(t,e),"backgroundColor","transparent")},K=E.a.article.withConfig({displayName:"shared-styles__ArticleContainer",componentId:"sc-1kek94e-0"})(["display:flex;flex-direction:",";background-color:",";@media (min-width:","px){flex-direction:",";background-color:",";}@media (min-width:","px){flex-direction:",";background-color:",";}@media (min-width:","px){flex-direction:",";background-color:",";}"],(function(e){var t=e.schema;return q("sm",t)}),(function(e){var t=e.schema;return J("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return q("md",t)}),(function(e){var t=e.schema;return J("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return q("lg",t)}),(function(e){var t=e.schema;return J("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return q("xlg",t)}),(function(e){var t=e.schema;return J("xlg",t)})),Q=E.a.div.withConfig({displayName:"shared-styles__SideBySideColumn",componentId:"sc-1kek94e-1"})(["width:100%;&:first-of-type{flex-shrink:0;width:",";padding-right:",";}&:last-of-type{display:flex;flex-direction:column;justify-content:",";align-items:",";margin:",";padding-left:",";}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}@media (min-width:","px){&:first-of-type{width:",";padding-right:",";}&:last-of-type{justify-content:",";align-items:",";margin:",";padding-left:",";}}"],(function(e){var t=e.schema;return W("sm",t)}),(function(e){var t=e.schema;return Y("sm",t)}),(function(e){var t=e.schema;return V("sm",t)}),(function(e){var t=e.schema;return V("sm",t)}),(function(e){var t=e.schema;return G("sm",t)}),(function(e){var t=e.schema;return Y("sm",t)}),j.breakpoints.medium,(function(e){var t=e.schema;return W("md",t)}),(function(e){var t=e.schema;return Y("md",t)}),(function(e){var t=e.schema;return V("md",t)}),(function(e){var t=e.schema;return V("md",t)}),(function(e){var t=e.schema;return G("md",t)}),(function(e){var t=e.schema;return Y("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return W("lg",t)}),(function(e){var t=e.schema;return Y("lg",t)}),(function(e){var t=e.schema;return V("lg",t)}),(function(e){var t=e.schema;return V("lg",t)}),(function(e){var t=e.schema;return G("lg",t)}),(function(e){var t=e.schema;return Y("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return W("xlg",t)}),(function(e){var t=e.schema;return Y("xlg",t)}),(function(e){var t=e.schema;return V("xlg",t)}),(function(e){var t=e.schema;return V("xlg",t)}),(function(e){var t=e.schema;return G("xlg",t)}),(function(e){var t=e.schema;return Y("xlg",t)})),X=E.a.p.withConfig({displayName:"shared-styles__Label",componentId:"sc-1kek94e-2"})(["margin:0 0 4px 0;color:",";font-size:12px;line-height:16px;letter-spacing:0.5px;font-family:",";text-transform:uppercase;"],j.colours.functional.secondary,j.fonts.supporting),Z=function(e,t){return g(e,t)?"sm"===e||"md"===e?"90%":"80%":"100%"},ee=function(e,t){return g(e,t)?"center":"left"},te=E.a.p.withConfig({displayName:"styles__Strapline",componentId:"p3h2iu-0"})(["width:",";margin:4px auto 0 auto;color:",";font-size:14px;line-height:20px;text-align:",";font-family:",";@media (min-width:","px){width:",";text-align:",";}@media (min-width:","px){width:",";text-align:",";}@media (min-width:","px){width:",";text-align:",";}"],(function(e){var t=e.schema;return Z("sm",t)}),j.colours.functional.secondary,(function(e){var t=e.schema;return ee("sm",t)}),j.fonts.body,j.breakpoints.medium,(function(e){var t=e.schema;return Z("md",t)}),(function(e){var t=e.schema;return ee("md",t)}),j.breakpoints.wide,(function(e){var t=e.schema;return Z("lg",t)}),(function(e){var t=e.schema;return ee("lg",t)}),j.breakpoints.huge,(function(e){var t=e.schema;return Z("xlg",t)}),(function(e){var t=e.schema;return ee("xlg",t)})),ne=E.a.p.withConfig({displayName:"styles__TimeSince",componentId:"p3h2iu-1"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;letter-spacing:1px;font-family:",";text-transform:uppercase;"],j.colours.functional.secondary,j.fonts.supporting),ie=E.a.div.withConfig({displayName:"styles__Link",componentId:"p3h2iu-2"})(["margin-top:8px;a{color:#006699;font-size:13px;line-height:13px;letter-spacing:0px;font-family:",";font-weight:500;text-decoration:none;&:after{display:inline-block;content:'\\E003';font-size:10px;font-family:iconfont;padding:0 0 1px 6px;vertical-align:middle;}}"],j.fonts.supporting),re=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t)return null;var a=t.standfirst||t.summary,l=function(e){var t=Object(x.parseISO)(o()(e,"datePublished","")),n=Object(x.parseISO)(o()(e,"dateUpdated","")),i=Object(x.max)([t,n].filter((function(e){return Object(x.isValid)(e)}))),r=Object(x.differenceInCalendarDays)(new Date,i);return!Object(x.isValid)(i)||r>=7?null:"".concat(Object(x.formatDistanceToNowStrict)(i,{roundingMethod:"floor"})," ago")}(t);return r.a.createElement(K,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i})),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}),a&&r.a.createElement(te,{schema:n},a),l&&r.a.createElement(ne,null,l),t.cta&&r.a.createElement(ie,null,r.a.createElement("a",{href:t.url},t.cta))))},ae=E.a.div.withConfig({displayName:"shared-styles__SliceContainer",componentId:"ismxwo-0"})(["display:flex;flex-wrap:wrap;justify-content:space-between;margin:0 auto;padding:",";@media (min-width:","px){max-width:520px;}@media (min-width:","px){max-width:860px;padding:",";}@media (min-width:","px){max-width:1024px;}@media (min-width:","px){max-width:1180px;}"],(function(e){var t=e.styles;return t&&t.removePadding?0:"0 16px"}),j.breakpoints.small,j.breakpoints.medium,(function(e){var t=e.styles;return t&&t.removePadding?0:"0 20px"}),j.breakpoints.wide,j.breakpoints.huge),oe=E.a.div.withConfig({displayName:"shared-styles__SlotContainer",componentId:"ismxwo-1"})(["position:relative;width:100%;margin-bottom:",";padding-bottom:",";box-sizing:content-box;:before{content:'';display:none;position:absolute;top:0;right:0;bottom:0;width:1px;background-color:",";}:after{content:'';display:",";position:absolute;right:0;bottom:0;left:0;height:1px;background-color:",";}"],(function(e){return e.collapse?0:"12px"}),(function(e){return e.collapse?0:"12px"}),(function(e){var t=e.styles;return t&&t.lineColor?t.lineColor:"#dbdbdb"}),(function(e){return e.collapse?"none":"block"}),(function(e){var t=e.styles;return t&&t.lineColor?t.lineColor:"#dbdbdb"})),le=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-614vlg-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),ce=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-614vlg-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:0;padding-bottom:24px;}"],j.breakpoints.medium),de=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(le,{styles:n},r.a.createElement(ce,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",isCentered:!0,headlineFontSize:28,backgroundColor:"#f0f0f0"},md:{isSideBySide:!0},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})))})),se=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-1r0nv22-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),me=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-1r0nv22-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium),pe=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-1r0nv22-2"})(["@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(33.33,3)),ue=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(se,{styles:n},r.a.createElement(me,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:28},md:{imageRatio:"16:9"},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})),r.a.createElement(pe,{styles:n},r.a.createElement(re,{article:o()(t,"children[1].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},lg:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})))})),fe=function(e){return e&&("maincomment"===e.template||"magazinecomment"===e.template||"externalcomment"===e.template)},he=E()(K).withConfig({displayName:"styles__ArticleContainer",componentId:"sc-2eizyd-0"})(["align-items:center;"]),ye=E.a.div.withConfig({displayName:"styles__ImageContainer",componentId:"sc-2eizyd-1"})(["max-width:120px;margin:0 auto;@media (min-width:","px){max-width:140px;}"],j.breakpoints.huge),ge=E.a.p.withConfig({displayName:"styles__Byline",componentId:"sc-2eizyd-2"})(["margin:0 0 4px 0;color:",";font-size:22px;line-height:22px;font-family:",";@media (min-width:","px){font-size:24px;line-height:24px;}"],j.colours.functional.secondary,j.fonts.headlineRegular,j.breakpoints.huge),be=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;return t?r.a.createElement(he,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(ye,null,r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i}))),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),t.byline&&r.a.createElement(ge,null,t.byline),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}))):null},xe=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"fss0bs-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.medium),we=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"fss0bs-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium),Se=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"fss0bs-2"})(["@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(33.33,3)),ve=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(xe,{styles:n},r.a.createElement(we,{styles:n},r.a.createElement(re,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:28},md:{imageRatio:"16:9"},lg:{headlineFontSize:32},xlg:{headlineFontSize:36}}),clickHandler:i})),r.a.createElement(Se,{styles:n},r.a.createElement(oe,{styles:n},r.a.createElement(re,{article:o()(t,"children[1].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},lg:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})),fe(o()(t,"children[2].article"))?r.a.createElement(be,{article:t.children[2].article,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{headlineFontSize:16},lg:{sideBySideWidth:"50%"},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:o()(t,"children[2].article"),displaySchema:h({sm:{isSideBySide:!0,imageRatio:"3:2",headlineFontSize:18},md:{headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i})))})),_e=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"rqwi1t-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-right:12px;padding-bottom:24px;:before{display:block;bottom:24px;}}"],j.breakpoints.medium,b(50,2)),ke=E.a.div.withConfig({displayName:"styles__SideBySideColumn",componentId:"rqwi1t-1"})(["display:flex;flex-wrap:wrap;justify-content:space-between;"]),Ee=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"rqwi1t-2"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;}"],j.breakpoints.medium,b(50,2)),Ce=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"rqwi1t-3"})(["width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:last-of-type{padding-left:12px;}"],b(50,2));function Ie(e){return function(e){if(Array.isArray(e))return Ae(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Ae(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ae(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ae(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var ze=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},r.a.createElement(_e,{styles:n},r.a.createElement(ke,null,Ie(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ce,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18},md:{imageRatio:"16:9"},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))}))),r.a.createElement(re,{article:o()(t,"children[2].article"),displaySchema:h({sm:{isSideBySide:!0,sideBySidePadding:12,imageRatio:"3:2",headlineFontSize:18},md:{imageRatio:"16:9",headlineFontSize:22},lg:{headlineFontSize:24}}),clickHandler:i})),r.a.createElement(Ee,{styles:n},r.a.createElement(re,{article:o()(t,"children[3].article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i})))})),Oe=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"z7ncw3-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}"],j.breakpoints.medium,b(50,2)),je=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(Oe,{key:t,styles:n},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{imageRatio:"16:9",headlineFontSize:24},xlg:{headlineFontSize:28}}),clickHandler:i}))})))})),Fe=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"xnsfmb-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Ne=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"xnsfmb-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),He=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"xnsfmb-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Re=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"xnsfmb-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}@media (min-width:","px){width:100%;margin-bottom:12px;padding-bottom:12px;&:first-of-type{padding-right:0;:before{display:none;}}&:last-of-type{margin-bottom:0;padding:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function De(e){return function(e){if(Array.isArray(e))return Te(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Te(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Te(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Te(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var Le=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Fe,{styles:n},De(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ne,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(He,{styles:n},De(Array(2)).fill(null).map((function(e,a){var l=o()(t,"children[".concat(a+2,"].article"));return r.a.createElement(Re,{key:a,styles:n},fe(l)?r.a.createElement(be,{article:l,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{sideBySideWidth:"50%",headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:l,displaySchema:h({sm:{isSideBySide:!0,imageRatio:"3:2",headlineFontSize:18},md:{headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}))}))))})),Be=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-7y5fg-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Pe=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-7y5fg-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),Me=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"sc-7y5fg-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Ue=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-7y5fg-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;:before{display:none;}}}@media (min-width:","px){width:100%;margin-bottom:12px;padding:0 0 12px 0;:before{display:none;}&:last-of-type{margin-bottom:0;padding-bottom:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function $e(e){return function(e){if(Array.isArray(e))return qe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return qe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return qe(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function qe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var We=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Be,{styles:n},$e(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Pe,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(Me,{styles:n},$e(Array(3)).fill(null).map((function(e,a){return r.a.createElement(Ue,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a+2,"].article")),displaySchema:h({sm:{isImageHidden:!0,imageRatio:"3:2",headlineFontSize:18},lg:{isSideBySide:!0,isImageHidden:!1,headlineFontSize:16},xlg:{headlineFontSize:18}}),clickHandler:i}))}))))})),Ye=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"sc-11upv3n-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),Ve=E()(oe).withConfig({displayName:"styles__SlotContainerLead",componentId:"sc-11upv3n-1"})(["@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(2){padding-left:12px;}}@media (min-width:","px){margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(2){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide),Ge=E()(oe).withConfig({displayName:"styles__StackedColumn",componentId:"sc-11upv3n-2"})(["margin-bottom:0;padding-bottom:0;:after{display:none;}@media (min-width:","px){display:flex;justify-content:space-between;}@media (min-width:","px){display:block;flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;padding-left:12px;:after{display:block;}}"],j.breakpoints.medium,j.breakpoints.wide,b(33.33,3)),Je=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-11upv3n-3"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;:before{display:none;}}}@media (min-width:","px){width:100%;margin-bottom:12px;padding:0 0 12px 0;:before{display:none;}&:last-of-type{margin-bottom:0;padding-bottom:0;:after{display:none;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function Ke(e){return function(e){if(Array.isArray(e))return Qe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Qe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Qe(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Qe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var Xe=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(Ye,{styles:n},Ke(Array(2)).fill(null).map((function(e,a){return r.a.createElement(Ve,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a,"].article")),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})),r.a.createElement(Ge,{styles:n},Ke(Array(3)).fill(null).map((function(e,a){return r.a.createElement(Je,{key:a,styles:n},r.a.createElement(re,{article:o()(t,"children[".concat(a+2,"].article")),displaySchema:h({sm:{isImageHidden:!0,headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))}))))})),Ze=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"bazswq-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}:after{display:block;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],j.breakpoints.medium,b(33.33,3)),et=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(Ze,{key:t,styles:n,collapse:!e.article},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},md:{headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),tt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-1gqjewy-0"})(["width:",";&:nth-of-type(odd){padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(even){padding-left:12px;}@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px !important;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],b(50,2),j.breakpoints.medium,b(25,4)),nt=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(tt,{key:t,styles:n},r.a.createElement(re,{article:e.article,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),it=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"c5tu9p-0"})(["@media (min-width:","px){flex-wrap:nowrap;}"],j.breakpoints.wide),rt=E()(oe).withConfig({displayName:"styles__SlotContainerLarge",componentId:"c5tu9p-1"})(["order:1;@media (min-width:","px){width:",";&:first-of-type{padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(3){padding-left:12px;}}@media (min-width:","px){flex-shrink:0;width:",";margin-bottom:24px;padding-bottom:24px;:before{display:block;bottom:24px !important;}&:nth-of-type(3){padding-right:12px;}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide,b(33.33,3)),at=E()(oe).withConfig({displayName:"styles__SlotContainerSmall",componentId:"c5tu9p-2"})(["order:2;@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:nth-of-type(2){padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}@media (min-width:","px){order:1;&:nth-of-type(2){padding-left:12px;:before{bottom:24px;}}}"],j.breakpoints.medium,b(50,2),j.breakpoints.wide);function ot(e){return function(e){if(Array.isArray(e))return lt(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return lt(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return lt(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function lt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}var ct=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(it,{styles:n},ot(Array(2)).fill(null).map((function(e,a){var l=o()(t,"children[".concat(2*a,"].article")),c=o()(t,"children[".concat(2*a+1,"].article"));return r.a.createElement(r.a.Fragment,{key:a},r.a.createElement(rt,{styles:n},r.a.createElement(re,{article:l,displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i})),r.a.createElement(at,{styles:n},fe(c)?r.a.createElement(be,{article:c,displaySchema:h({sm:{isSideBySide:!0,sideBySideWidth:"35%",imageRatio:"1:1",headlineFontSize:18},md:{sideBySideWidth:"50%",headlineFontSize:16},lg:{isSideBySide:!1},xlg:{headlineFontSize:18}}),clickHandler:i}):r.a.createElement(re,{article:c,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"3:2",headlineFontSize:18},md:{isImageHidden:!1,isSideBySide:!0,headlineFontSize:16},lg:{isSideBySide:!1},xlg:{headlineFontSize:18}}),clickHandler:i})))})))})),dt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"sc-189xcog-0"})(["width:",";&:nth-of-type(odd){padding-right:12px;:before{display:block;bottom:12px;}}&:nth-of-type(even){padding-left:12px;}@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px !important;}&:nth-of-type(5n + 1){padding-left:0;}&:nth-of-type(5n){padding-right:0;&:before{display:none;}}}"],b(50,2),j.breakpoints.medium,b(20,5)),st=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(dt,{key:t,styles:n},r.a.createElement(re,{article:o()(e,"article"),displaySchema:h({sm:{imageRatio:"3:2",headlineFontSize:18,isCentered:!0},lg:{headlineFontSize:22},xlg:{headlineFontSize:24}}),clickHandler:i}))})))})),mt=function(e,t){var n=new Date(Date.UTC(t,e+1,0)),i=n.getDay(),r=n.getDate()-i,a=new Date(Date.UTC(t,e,r));return a.setHours(1),a},pt=function(e){if(e){var t=function(e){var t=new Date(e);return new Date(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate(),t.getUTCHours(),t.getUTCMinutes())}(e),n=Object(x.addMinutes)(t,function(e){var t=mt(2,e.getFullYear()),n=mt(9,e.getFullYear()),i=e.getTime()>=t.getTime(),r=e.getTime()<n.getTime();return i&&r}(t)?60:0);return Object(x.format)(n,"MMMM dd yyyy, h.mmaaa")}return null},ut=E.a.p.withConfig({displayName:"styles__DateTime",componentId:"sc-1p1alcs-0"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;font-family:",";"],j.colours.functional.secondary,j.fonts.supporting),ft=E.a.p.withConfig({displayName:"styles__Byline",componentId:"sc-1p1alcs-1"})(["margin:8px 0 0 0;color:",";font-size:12px;line-height:16px;font-family:",";"],j.colours.functional.brandColour,j.fonts.supporting),ht=function(e){var t=e.article,n=e.displaySchema,i=e.clickHandler;if(!t)return null;var a=pt(t.datePublished);return r.a.createElement(K,{schema:n},r.a.createElement(Q,{schema:n},r.a.createElement(L,{article:t,displaySchema:n,clickHandler:i})),r.a.createElement(Q,{schema:n},t.label&&r.a.createElement(X,null,t.label),r.a.createElement($,{article:t,displaySchema:n,clickHandler:i}),a&&r.a.createElement(ut,null,a),t.byline&&r.a.createElement(ft,null,t.byline)))},yt=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"b33h2c-0"})(["@media (min-width:","px){flex-wrap:nowrap;width:80.8%;max-width:none;padding:0;}@media (min-width:","px){width:56.2%;}"],j.breakpoints.medium,j.breakpoints.wide),gt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"b33h2c-1"})(["@media (min-width:","px){margin-bottom:24px;padding-right:0;padding-bottom:24px;}"],j.breakpoints.medium),bt=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(yt,{styles:n},r.a.createElement(gt,{styles:n},r.a.createElement(ht,{article:o()(t,"children[0].article"),displaySchema:h({sm:{imageRatio:"16:9",headlineFontSize:22},md:{isSideBySide:!0}}),clickHandler:i})))})),xt=E()(ae).withConfig({displayName:"styles__SliceContainer",componentId:"v1jynn-0"})(["@media (min-width:","px){width:80.8%;max-width:none;padding:0;}@media (min-width:","px){width:56.2%;}"],j.breakpoints.medium,j.breakpoints.wide),wt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"v1jynn-1"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding-bottom:24px;&:first-of-type{padding-right:12px;:before{display:block;bottom:24px;}}&:last-of-type{padding-left:12px;}}"],j.breakpoints.medium,b(50,2)),St=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(xt,{styles:n},t.children.map((function(e,t){return r.a.createElement(wt,{key:t,styles:n},r.a.createElement(ht,{article:e.article,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"16:9",headlineFontSize:22},md:{isImageHidden:!1}}),clickHandler:i}))})))})),vt=E()(oe).withConfig({displayName:"styles__SlotContainer",componentId:"yjxerl-0"})(["@media (min-width:","px){width:",";margin-bottom:24px;padding:0 12px 24px 12px;:before{display:block;bottom:24px;}:after{display:block;}&:first-of-type{padding-left:0;}&:last-of-type{padding-right:0;&:before{display:none;}}}"],j.breakpoints.medium,b(33.33,3)),_t=r.a.memo((function(e){var t=e.slice,n=e.styles,i=e.clickHandler;return r.a.createElement(ae,{styles:n},t.children.map((function(e,t){return r.a.createElement(vt,{key:t,styles:n},r.a.createElement(ht,{article:e.article,displaySchema:h({sm:{isImageHidden:!0,imageRatio:"16:9",headlineFontSize:22},md:{isImageHidden:!1}}),clickHandler:i}))})))})),kt=function(e){var t=e.slice,n=e.styles,i=e.clickHandler,a=function(e){switch(e){case"LEAD_1":case"LEAD_1_COMPONENT":case"INTERACTIVE_FULL_WIDTH":return de;case"LEAD_1_AND_1":case"LEAD_1_AND_1_COMPONENT":return ue;case"LEAD_1_AND_2":case"LEAD_1_AND_2_COLUMNIST":return ve;case"LEAD_1_AND_3_REVERSED":return ze;case"LEAD_2":case"LEAD_2_COMPONENT":case"INTERACTIVE_HALF_WIDTH":return je;case"SECONDARY_2_AND_2":return Le;case"SECONDARY_2_AND_3":return We;case"SECONDARY_2_AND_3_NO_PIC":return Xe;case"SECONDARY_3":return et;case"SECONDARY_4":return nt;case"SECONDARY_4_ODD":case"SECONDARY_4_ODD_COLUMNIST":return ct;case"SECONDARY_10":return st;case"RELATED_ARTICLE_1":return bt;case"RELATED_ARTICLE_2":return St;case"RELATED_ARTICLE_3":return _t;default:return function(){return null}}}(t.name);return r.a.createElement(a,{slice:t,styles:n,clickHandler:i})};n.d(t,"Slice",(function(){return kt}))}]);
|
package/src/utils/resizeImage.ts
CHANGED
|
@@ -14,13 +14,14 @@ const getResizeImage = (url: string, width: number) => {
|
|
|
14
14
|
const params = new URLSearchParams(api.search.slice(1));
|
|
15
15
|
params.set('resize', resize.toString());
|
|
16
16
|
|
|
17
|
-
const origin =
|
|
18
|
-
api.origin
|
|
19
|
-
|
|
20
|
-
: api.origin;
|
|
17
|
+
const origin = api.origin.includes('uat-thetimes')
|
|
18
|
+
? api.origin.replace('uat-thetimes', 'thetimes')
|
|
19
|
+
: api.origin;
|
|
21
20
|
|
|
22
21
|
return `${origin}${api.pathname}?${params.toString()}`;
|
|
23
22
|
};
|
|
24
23
|
|
|
25
24
|
export const resizeImage = (url: string, width: number) =>
|
|
26
|
-
url.includes('thetimes.
|
|
25
|
+
url.includes('thetimes.') && url.includes('/imageserver')
|
|
26
|
+
? getResizeImage(url, width)
|
|
27
|
+
: url;
|