@micromag/viewer-build 0.4.49 → 0.4.50
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.
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! For license information please see main.f5f2a51b.js.LICENSE.txt */
|
|
2
|
+
(self.webpackChunk_micromag_viewer_build=self.webpackChunk_micromag_viewer_build||[]).push([[792],{1056:function(e,t,l){"use strict";var a=l(4041),n=l(5873),i=l(9740),o=l(4619),r=l(9850),s=l(7316),u=l(3514),d=l.n(u),c=l(2438),m=l.n(c),v=l(5187),g=l(8138),y=l.n(g),h=l(4586),f=l(5152),p=l(414),b=l(3142),x=l.n(b),A=l(1580),S=l.n(A),C=(l(9106),l(74),l(8160)),w=l(9296),k=l(3315),j=l.n(k),M=l(4240),N=l(7835),F=l.n(N),T=l(7545),R=l(2061),z=l(7863);function $(e){var t=e||{},l=t.fields,a=void 0===l?null:l,n=t.states,r=void 0===n?null:n;if(null===r)return a;var s=r.reduce(function(e,t){var l=t||{},a=l.id,n=l.fields,r=void 0===n?[]:n,s=l.repeatable,u=void 0!==s&&s,d=l.fieldName,c=void 0===d?null:d,m=l.label,v=l.defaultValue,g=void 0===v?null:v;return[].concat((0,o.A)(e),(0,o.A)(u?[{type:"items",name:c||a,label:m,defaultValue:g,stateId:a,itemsField:{label:m,type:"fields",fields:r}}]:[]),(0,o.A)(u||null===c?[]:[{type:"fields",name:c,stateId:a,fields:r}]),(0,o.A)(u||null!==c?[]:r.map(function(e){return(0,i.A)((0,i.A)({},e),{},{stateId:a})})))},[]);return[].concat((0,o.A)(s),(0,o.A)(a))}var L=function(e){function t(){var e,l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,f.A)(this,t),(e=(0,C.A)(this,t)).components=l,e}return(0,w.A)(t,e),(0,p.A)(t,[{key:"addComponent",value:function(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return this.addComponents((0,h.A)({},e,t),l)}},{key:"addComponents",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=null!==t?Object.keys(e).reduce(function(l,a){return(0,i.A)((0,i.A)({},l),{},(0,h.A)({},"".concat(t,".").concat(a),e[a]))},{}):e;return this.components=(0,i.A)((0,i.A)({},this.components),l),this.emit("change"),this}},{key:"merge",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return this.addComponents(e.getComponents(),t)}},{key:"addNamespace",value:function(e){var t=this;return null===e||(this.components=Object.keys(this.components).reduce(function(l,a){return(0,i.A)((0,i.A)({},l),{},(0,h.A)({},"".concat(e,".").concat(a),t.components[a]))},{})),this}},{key:"getComponent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return null===t||null===e?l:t[(0,M.fL)(e)]||t[e]||l}(e,this.getComponents(t))}},{key:"getComponents",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null!==t?Object.keys(this.components||{}).reduce(function(l,a){var n=new RegExp("^".concat(t,"\\.(.*)$")).exec(a);return null!==n?(0,i.A)((0,i.A)({},l),{},(0,h.A)({},n[1],e.components[a])):l},{}):this.components}},{key:"hasComponent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return null!==this.components&&void 0!==this.components[null!==t?"".concat(t,".").concat(e):e]}}])}(j()),I=function(e){function t(){var e,l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return(0,f.A)(this,t),(e=(0,C.A)(this,t)).definitions=l||[],e}return(0,w.A)(t,e),(0,p.A)(t,[{key:"addDefinition",value:function(e){return this.addDefinitions(x()(e)?e:[e]),this}},{key:"addDefinitions",value:function(e){return this.definitions=F()([].concat((0,o.A)(e),(0,o.A)(this.definitions)),function(e){return e.id}),this.emit("change"),this}},{key:"merge",value:function(e){return this.addDefinitions(e.getDefinitions())}},{key:"filter",value:function(e){return new t(this.definitions.filter(e))}},{key:"getDefinition",value:function(e){return null===e?null:this.definitions.find(function(t){return t.id===e})||null}},{key:"getDefinitions",value:function(){return this.definitions}},{key:"hasDefinition",value:function(e){return null!==this.getDefinition(e)}},{key:"getComponent",value:function(e){var t=(this.getDefinition(e)||{}).component;return void 0===t?null:t}},{key:"getComponents",value:function(){return this.definitions.reduce(function(e,t){var l=t.id,a=t.component,n=void 0===a?null:a;return null!==n?(0,i.A)((0,i.A)({},e),{},(0,h.A)({},l,n)):e},{})}}])}(j()),P=function(e){function t(e){var l;return(0,f.A)(this,t),(l=(0,C.A)(this,t)).element=e,l.events={},l.listeners={},l}return(0,w.A)(t,e),(0,p.A)(t,[{key:"subscribe",value:function(e,t){this.on(e,t),this.events=(0,i.A)((0,i.A)({},this.events),{},(0,h.A)({},e,[].concat((0,o.A)(this.events[e]||[]),[t]))),1===this.events[e].length&&this.addEventListener(e)}},{key:"unsubscribe",value:function(e,t){var l=this;this.off(e,t),this.events=Object.keys(this.events).reduce(function(a,n){if(n!==e)return(0,i.A)((0,i.A)({},a),{},(0,h.A)({},n,l.events[n]));var o=l.events[n].filter(function(e){return e!==t});return o.length>0?(0,i.A)((0,i.A)({},a),{},(0,h.A)({},n,o)):a},{}),void 0===this.events[e]&&this.removeEventListener(e)}},{key:"addEventListener",value:function(e){var t=this;void 0===this.listeners[e]&&(this.listeners[e]=function(){for(var l=arguments.length,a=new Array(l),n=0;n<l;n++)a[n]=arguments[n];return t.emit.apply(t,[e].concat(a))}),this.element.addEventListener(e,this.listeners[e])}},{key:"removeEventListener",value:function(e){this.element.removeEventListener(e,this.listeners[e])}}])}(j()),B=["medias"],E=["medias"],V=function(){function e(t){var l=t.fieldsManager,a=t.screensManager,n=t.fieldsPattern,i=void 0===n?{}:n;(0,f.A)(this,e),this.fieldsManager=l,this.screensManager=a,this.fieldsPatternCache=i||{},this.parsedThemesCache={}}return(0,p.A)(e,[{key:"getParsedStoryTheme",value:function(e,t){if(void 0===this.parsedThemesCache[e]){var l=this.toPath(t),a=l.medias,n=(0,r.A)(l,B);this.parsedThemesCache[e]={themeMedias:a,newTheme:n}}return this.parsedThemesCache[e]}},{key:"getFieldsPatternByScreen",value:function(e){if(void 0===this.fieldsPatternCache[e]){var t=$(this.screensManager.getDefinition(e)||{});this.fieldsPatternCache[e]=this.getFieldsPattern(t||[])}return this.fieldsPatternCache[e]}},{key:"toPath",value:function(t){var l=this;if(null===t)return t;var a=t||{},n=a.id,s=void 0===n?null:n,u=a.theme,d=void 0===u?null:u,c=a.components,m=(void 0===c?[]:c).reduce(function(t,a){var n=t.components,r=t.medias,s=a.type,u=l.getFieldsPatternByScreen(s),d=e.replaceMediasWithPaths(a,u),c=d.data,m=d.medias;return{components:[].concat((0,o.A)(n),[c]),medias:(0,i.A)((0,i.A)({},r),m)}},{components:[],medias:null}),v=m.components,g=m.medias;if(null!==d){var y=this.getParsedStoryTheme(s,d),h=y.medias,f=(0,r.A)(y,E);return null!==g||null!==h?(0,i.A)((0,i.A)({},t),{},{theme:f,components:v,medias:(0,i.A)((0,i.A)({},h),g)}):t}return null!==g?(0,i.A)((0,i.A)({},t),{},{components:v,medias:g}):t}},{key:"fromPath",value:function(t){var l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(null===t)return t;var a=t||{},n=a.theme,o=void 0===n?null:n,r=a.components,s=void 0===r?[]:r,u=a.medias,d=void 0===u?l:u;if(null===d&&null===o)return t;var c=e.getMediaPatternsFromData(s),m=null!==d&&c.length>0?e.replacePathsWithMedias(s,d,c):s;if(null!==o){var v=this.fromPath(o,d);return v!==o||m!==s?(0,i.A)((0,i.A)({},t),{},{theme:v,components:m}):t}return m!==s?(0,i.A)((0,i.A)({},t),{},{components:m}):t}},{key:"getFieldsPattern",value:function(t){var l=this,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return(t||[]).reduce(function(t,n){var r=n.name,s=void 0===r?null:r,u=n.type,d=void 0===u?null:u,c=[a,s].filter(function(e){return null!==e&&""!==e}).join("\\."),m=(0,i.A)((0,i.A)({},null!==d?l.fieldsManager.getDefinition(d):null),n),v=m.fields,g=void 0===v?[]:v,y=m.itemsField,h=void 0===y?null:y,f=m.settings,p=void 0===f?[]:f;return[].concat((0,o.A)(t),(0,o.A)(e.fieldIsMedia(m)?[new RegExp("^".concat(c,"$"))]:[]),(0,o.A)(e.fieldIsFontFamily(m)?[new RegExp("^".concat(c,"\\.media$")),new RegExp("^".concat(c,"\\.variants\\.[0-9]+\\.media$"))]:[]),(0,o.A)(l.getFieldsPattern(g,c)),(0,o.A)(l.getFieldsPattern(p,c)),(0,o.A)(null!==h?l.getFieldsPattern([h],"".concat(c,"\\.[0-9]+")):[]))},[])}}],[{key:"fieldIsMedia",value:function(e){var t=e.media;return void 0!==t&&t}},{key:"fieldIsFontFamily",value:function(e){var t=e.id;return"font-family"===(void 0===t?null:t)}},{key:"replacePathsWithMedias",value:function(t,l,a){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=x()(t);return e.keys(t).reduce(function(s,u){var d,c=[n,u].filter(function(e){return null!==e}).join("."),m=a.reduce(function(e,t){return e||t.test(c)},!1),v=t[u];return d=m?S()(v)?v:l[v]||v:S()(v)||x()(v)?e.replacePathsWithMedias(v,l,a,c):v,r?[].concat((0,o.A)(s),[d]):(0,i.A)((0,i.A)({},s),{},(0,h.A)({},u,d))},r?[]:{})}},{key:"getMediaPath",value:function(e){var t=e.id,l=void 0===t?null:t;return null!==l?"media://".concat(l):null}},{key:"replaceMediasWithPaths",value:function(t,l){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=x()(t),s=e.keys(t);return s.reduce(function(s,u){var d,c=s.data,m=s.medias,v=[n,u].filter(function(e){return null!==e}).join("."),g=l.reduce(function(e,t){return e||t.test(v)},!1),y=t[u],f=null,p=null;if(g&&S()(y)){var b=e.getMediaPath(y);d=null!==b?b:y,f=null!==b?y:null}else if(S()(y)||x()(y)){var A=e.replaceMediasWithPaths(y,l,a,v);d=A.data,p=A.medias}else d=y;return{data:r?[].concat((0,o.A)(c||[]),[d]):(0,i.A)((0,i.A)({},c),{},(0,h.A)({},u,d)),medias:null!==f?(0,i.A)((0,i.A)((0,i.A)({},m),p),{},(0,h.A)({},d,f)):(0,i.A)((0,i.A)({},m),p)}},{data:0===s.length?t:null,medias:a})}},{key:"getMediaPatternsFromData",value:function(t){var l=e.dot(t);return Object.keys(l).filter(function(e){return y()(l[e])&&null!==l[e].match(/^media:\/\/([^/]+)$/)}).map(function(e){return new RegExp("^".concat(e,"$"))})}},{key:"dot",value:function(t){return e.keys(t).reduce(function(l,a){if("object"!==(0,T.A)(t[a])||!t[a])return(0,i.A)((0,i.A)({},l),{},(0,h.A)({},a,t[a]));var n=e.dot(t[a]);return(0,i.A)((0,i.A)({},l),e.keys(n).reduce(function(e,t){return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},"".concat(a,".").concat(t),n[t]))},{}))},{})}},{key:"keys",value:function(e){return x()(e)?(0,o.A)(e.keys()):Object.keys(e)}}])}(),D=function(e){function t(){var e,l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return(0,f.A)(this,t),(e=(0,C.A)(this,t,[l])).fieldsPattern=null,e}return(0,w.A)(t,e),(0,p.A)(t,[{key:"getFields",value:function(e){var t=(this.getDefinition(e)||{}).fields;return void 0===t?null:t}},{key:"getLayouts",value:function(e){var t=(this.getDefinition(e)||{}).layouts;return void 0===t?null:t}},{key:"getFieldsPattern",value:function(){return this.fieldsPattern}},{key:"setFieldsPattern",value:function(e){this.fieldsPattern=e}},{key:"filter",value:function(e){return new t(this.definitions.filter(e))}},{key:"merge",value:function(e){var t=e.getFieldsPattern();return null!==t&&null===this.fieldsPattern&&(this.fieldsPattern=t),this.addDefinitions(e.getDefinitions())}}])}(I),O=["fonts"],H=function(){function e(t){var l=t.fieldsManager,a=t.screensManager,n=t.fieldsPattern,i=void 0===n?{}:n;(0,f.A)(this,e),this.fieldsManager=l,this.screensManager=a,this.fieldsPatternCache=i||{}}return(0,p.A)(e,[{key:"getFieldsPatternByScreen",value:function(e){if(void 0===this.fieldsPatternCache[e]){var t=$(this.screensManager.getDefinition(e)||{});this.fieldsPatternCache[e]=this.getFieldsPattern(t||[])}return this.fieldsPatternCache[e]}},{key:"parse",value:function(t){var l=this;if(null===t)return t;var a=t||{},n=a.theme,s=void 0===n?null:n,u=a.components,d=void 0===u?[]:u,c=m()(d.reduce(function(t,a){var n=a.type,i=l.getFieldsPatternByScreen(n),r=e.extractFontsWithPaths(a,i);return r.length>0?[].concat((0,o.A)(t),(0,o.A)(r)):t},[]),"name");if(null!==s){var v=this.parse(s),g=v.fonts,y=void 0===g?[]:g,h=(0,r.A)(v,O);return c.length>0||y.length>0?(0,i.A)((0,i.A)({},t),{},{theme:h,fonts:m()([].concat((0,o.A)(y),(0,o.A)(c)),"name")}):t}return c.length>0?(0,i.A)((0,i.A)({},t),{},{fonts:c}):t}},{key:"getFieldsPattern",value:function(t){var l=this,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return(t||[]).reduce(function(t,n){var r=n.name,s=void 0===r?null:r,u=n.type,d=void 0===u?null:u,c=[a,s].filter(function(e){return null!==e&&""!==e}).join("\\."),m=(0,i.A)((0,i.A)({},null!==d?l.fieldsManager.getDefinition(d):null),n),v=m.fields,g=void 0===v?[]:v,y=m.itemsField,h=void 0===y?null:y,f=m.settings,p=void 0===f?[]:f;return[].concat((0,o.A)(t),(0,o.A)(e.fieldIsFontFamily(m)?[new RegExp("^".concat(c,"$"))]:[]),(0,o.A)(l.getFieldsPattern(g,c)),(0,o.A)(l.getFieldsPattern(p,c)),(0,o.A)(null!==h?l.getFieldsPattern([h],"".concat(c,"\\.[0-9]+")):[]))},[])}}],[{key:"fieldIsFontFamily",value:function(e){var t=e.id;return"font-family"===(void 0===t?null:t)}},{key:"valueIsFont",value:function(e){var t=e.type,l=void 0===t?null:t;return"custom"===l||"google"===l}},{key:"extractFontsWithPaths",value:function(t,l){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return(x()(t)?(0,o.A)(t.keys()):Object.keys(t)).reduce(function(n,i){var r=[a,i].filter(function(e){return null!==e}).join("."),s=l.reduce(function(e,t){return e||t.test(r)},!1),u=t[i],d=null,c=null;return s&&S()(u)&&e.valueIsFont(u)?d=u:(S()(u)||x()(u))&&(c=e.extractFontsWithPaths(u,l,r)),null!==c||null!==d?[].concat((0,o.A)(n),(0,o.A)(c||[]),(0,o.A)(null!==d?[d]:[])):n},[])}}])}(),Z=["shareIncentive","callToAction"],W=function(){return(0,p.A)(function e(){(0,f.A)(this,e)},[{key:"test",value:function(e){var t=e||{},l=t.shareIncentive,a=void 0===l?null:l,n=t.callToAction;return null!==a||null!==(void 0===n?null:n)}},{key:"parse",value:function(e){var t=e||{},l=t.shareIncentive,a=void 0===l?null:l,n=t.callToAction,o=void 0===n?null:n,s=(0,r.A)(t,Z),u=e||{},d=u.header,c=void 0===d?null:d,m=u.footer,v=void 0===m?null:m,g=null!==a?(0,i.A)((0,i.A)({},null!==a?{shareIncentive:a}:null),null!==c?{header:c}:null):c,y=null!==o?(0,i.A)((0,i.A)({},null!==o?{callToAction:o}:null),null!==v?{footer:v}:null):v;return(0,i.A)((0,i.A)((0,i.A)({},s),null!==g?{header:g}:null),null!==y?{footer:y}:null)}}])}();W.prototype.priority=0;var q=["answers"],_=["customAnswerLabel"],G=function(){return(0,p.A)(function e(){(0,f.A)(this,e)},[{key:"test",value:function(e){var t=(e||{}).answers,l=void 0===t?null:t;if(null===l||0===l.length)return!1;var a=(l||[]).some(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null!==e&&void 0!==e.customAnswerLabel});return!!a}},{key:"parse",value:function(e){var t=e||{},l=t.answers,a=void 0===l?null:l,n=(0,r.A)(t,q);return(0,i.A)((0,i.A)({},n),{},{answers:a.map(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null===e||void 0===e.customAnswerLabel)return e;var t=e||{},l=t.customAnswerLabel,a=(0,r.A)(t,_);return(0,i.A)((0,i.A)({},a),{},{result:l})})})}}])}();G.prototype.priority=1;var Y=["items"],U=["label","textStyle"],Q=function(){return(0,p.A)(function e(){(0,f.A)(this,e)},[{key:"test",value:function(e){var t=e||{},l=t.type,a=void 0===l?null:l,n=t.items,i=void 0===n?null:n;if("keypad"!==a||null===i||0===i.length)return!1;var o=(i||[]).some(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null!==e&&y()(null==e?void 0:e.label)});return!!o}},{key:"parse",value:function(e){var t=e||{},l=t.items,a=void 0===l?null:l,n=(0,r.A)(t,Y);return(0,i.A)((0,i.A)({},n),{},{items:a.map(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null===e||!y()(null==e?void 0:e.label))return e;var t=e||{},l=t.label,a=t.textStyle,n=(0,r.A)(t,U);return(0,i.A)((0,i.A)({},n),{},{label:{body:l,textStyle:a}})})})}}])}();Q.prototype.priority=1;var X=["keypadSettings"],J=function(){return(0,p.A)(function e(){(0,f.A)(this,e)},[{key:"test",value:function(e){var t=e||{},l=t.type,a=void 0===l?null:l,n=t.keypadSettings,i=void 0===n?null:n;if("keypad"!==a||null===i)return!1;var o=(i||{}).layout;return null!==(void 0===o?null:o)}},{key:"parse",value:function(e){var t=e||{},l=t.keypadSettings,a=void 0===l?null:l,n=(0,r.A)(t,X),o=(a||{}).layout,s=void 0===o?null:o;return(0,i.A)((0,i.A)({},n),{},{keypadLayout:s})}}])}();J.prototype.priority=1;var K=Object.freeze({__proto__:null,CustomAnswerLabel:G,KeypadItemLabel:Q,KeypadSettings:J,ShareCall:W}),ee=["components"],te=function(){return(0,p.A)(function e(t){var l=t.screensManager;(0,f.A)(this,e),this.screensManager=l,this.parsers=Object.keys(K).map(function(e){return new K[e]}),this.parsers.sort(function(e,t){return void 0===e.priority||void 0===t.priority||e.priority===t.priority?0:e.priority<t.priority?-1:1})},[{key:"parse",value:function(e){var t=this;if(null===e)return e;var l=e||{},a=l.components,n=void 0===a?[]:a,s=(0,r.A)(l,ee),u=n.reduce(function(l,a){var n=t.parsers.reduce(function(t,l){return l.test(t,e)?l.parse(t,e):t},a);return[].concat((0,o.A)(l),[n])},[]);return(0,i.A)((0,i.A)({},s),{},{components:u})}}])}(),le=["textStyle","color","boxStyle"],ae=function(){return(0,p.A)(function e(t){var l=t.screensManager;(0,f.A)(this,e),this.screensManager=l,this.definitionCache={},this.fieldsCache={}},[{key:"getDefinitionByScreen",value:function(e,t){if(void 0===this.definitionCache[e]){var l=this.screensManager.getDefinition(e)||{},a=t.find(function(t){return t.type===e})||null;this.definitionCache[e]={definition:l,themeScreen:a}}return this.definitionCache[e]}},{key:"getFieldsForDefinition",value:function(e){var t=e||{},l=t.id,a=void 0===l?null:l,n=t.fields,i=void 0===n?[]:n,o=t.states,r=void 0===o?[]:o;if(void 0===this.fieldsCache[a])if(null===r||0===r.length)this.fieldsCache[a]={fields:i};else{var s=i,u=[];if(null!==r&&r.length>0){var d=r.filter(function(e){var t=e.repeatable;return!1===(void 0!==t&&t)});u=r.filter(function(e){var t=e.repeatable;return!0===(void 0!==t&&t)}),s=d.reduce(function(e,t){var l=(t||{}).fields,a=void 0===l?[]:l;return null!==a&&a.length>0?e.concat(a):e},s)}this.fieldsCache[a]={fields:s,repetableStates:u}}return this.fieldsCache[a]}},{key:"parse",value:function(e){var t=this;if(null===e)return e;var l=e||{},a=l.theme,n=void 0===a?null:a,r=l.components,s=void 0===r?null:r;if(null===n||null===s)return e;var u=n.components,d=void 0===u?[]:u,c=n.background,m=void 0===c?null:c,v=n.colors,g=void 0===v?{}:v,y=n.textStyles,h=void 0===y?null:y,f=n.boxStyles,p=void 0===f?null:f,b=s.reduce(function(e,l,a){var n=l.type,r=t.getDefinitionByScreen(n,d).definition,s=t.parseScreen(r,l,null,m,g,h,p);return s!==l?[].concat((0,o.A)(e.slice(0,a)),[(0,i.A)((0,i.A)({},null),s)],(0,o.A)(e.slice(a+1))):e},s);return b!==s?(0,i.A)((0,i.A)({},e),{},{components:b}):e}},{key:"parseScreen",value:function(e,t,l,a,n,o,r){var s=this,u=this.getFieldsForDefinition(e),d=u.fields,c=void 0===d?null:d,m=u.repetableStates,v=void 0===m?null:m,g=null===l&&null!==a?{}:l;null!==a&&void 0!==g.background?g.background=(0,i.A)((0,i.A)({},a),g.background):null!==a&&(g.background=a);var y=Object.keys(t).reduce(function(e,l){var a=null;null!==v&&v.length>0&&(a=v.find(function(e){var t=e.id,a=void 0===t?null:t;return null!==a&&a===l})||null);var u=(c||null).find(function(e){return e.name===l})||a||{},d=t[l],m=null!==g&&g[l]||null,y=(u||{}).theme,f=void 0===y?null:y;if((null===f||!S()(f))&&null===c)return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},l,d));var p=s.parseField(d,u,m,n,o,r);return p!==d?(0,i.A)((0,i.A)({},e),{},(0,h.A)({},l,p)):e},t);return null!==g?(0,i.A)((0,i.A)({},g),y):y}},{key:"parseField",value:function(e,t,l,a,n,o){var r=this,s=t.theme,u=void 0===s?null:s,d=t.fields,c=void 0===d?null:d;return null!==c&&null!==e?x()(e)?e.map(function(e){return null===e?e:r.parseInnerFields(e,c,l,a,n,o)}):this.parseInnerFields(e,c,l,a,n,o):null!==u&&S()(u)?x()(e)?e.map(function(e){return null!==e?Object.keys(e).reduce(function(t,l){if(!S()(e[l]))return t;var r=u[l]||{},s=r.textStyle,d=void 0===s?null:s,c=r.color,m=void 0===c?null:c,v=r.boxStyle,g=void 0===v?null:v;if(null===d&&null===m&&null===g)return t;var y=e[l]||{},f=y.textStyle,p=void 0!==f&&f,b=y.boxStyle,x=void 0!==b&&b,A=null!==m?{color:null!==m&&null!==a&&a[m]||null}:null,C=null!==d?{textStyle:!1!==p?p:(0,i.A)((0,i.A)({},null!==d&&null!==n&&n[d]||null),p)}:null,w=null!==g?{boxStyle:!1!==x?x:(0,i.A)((0,i.A)({},null!==g&&null!==o&&o[g]||null),x)}:null;return null===A&&null===C&&null===w?t:(0,i.A)((0,i.A)({},t),{},(0,h.A)({},l,(0,i.A)((0,i.A)((0,i.A)((0,i.A)({},A),e[l]),C),w)))},e):e}):S()(e)?this.parseValue(e,u,l,a,n,o):e:e}},{key:"parseInnerFields",value:function(e,t,l,a,n,i){var o=this;return Object.keys(e).reduce(function(r,s){var u=x()(t)?t.find(function(e){return e.name===s})||null:t,d=(u||{}).theme,c=void 0===d?null:d,m=e[s];return null!==m&&null!==u&&x()(m)?(r[s]=o.parseField(m,u,l,a,n,i),r):null!==m&&null!==c&&S()(c)&&S()(m)?(r[s]=o.parseValue(m,c,l,a,n,i),r):(r[s]=e[s],r)},{})}},{key:"parseValue",value:function(e,t,l,a,n,o){var s=this;if(S()(e)||S()(t)){var u=e||null,c=t||{},m=c.textStyle,v=void 0===m?null:m,g=c.color,y=void 0===g?null:g,f=c.boxStyle,p=void 0===f?null:f,b=(0,r.A)(c,le);if(null===v&&null===y&&null===p&&d()(b)&&!S()(t))return u;var x=null;d()(b)||(x=Object.keys(b).reduce(function(e,t){var r=null!==u&&u[t]||null,d=s.parseValue(r,b[t],l,a,n,o);return(0,i.A)((0,i.A)({},e),null!==d?(0,h.A)({},t,d):null)},{}));var A=u||{},C=A.textStyle,w=void 0!==C&&C,k=A.boxStyle,j=void 0!==k&&k,M=null!==y&&null!==a&&a[y]||null,N=null!==M?{color:M}:null,F=null!==v&&null!==n&&n[v]||null,T=null!==l&&l.textStyle||null,R=null!==F||null!==T?{textStyle:!1!==w?w:(0,i.A)((0,i.A)((0,i.A)({},F),T),w||null)}:null,z=null!==p&&null!==o&&o[p]||null,$=null!==l&&l.boxStyle||null,L=null!==z||null!==$?{boxStyle:!1!==j?j:(0,i.A)((0,i.A)((0,i.A)({},z),$),j||null)}:null;return null!==N||null!==l||null!==R||null!==L||null!==x?(0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)({},N),l),u),L),R),x):u}return e}}])}(),ne=function(){return(0,p.A)(function e(t){var l=t.screensManager,a=t.fieldsManager,n=t.fieldsPattern;(0,f.A)(this,e);var i=n||{},o=i.medias,r=void 0===o?null:o,s=i.fonts,u=void 0===s?null:s;this.themeParser=new ae({screensManager:l}),this.mediasParser=new V({screensManager:l,fieldsManager:a,fieldsPattern:r}),this.fontsParser=new H({screensManager:l,fieldsManager:a,fieldsPattern:u}),this.migrationsParser=new te({screensManager:l})},[{key:"parse",value:function(e){var t=this,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=l.withTheme,n=void 0===a||a,i=l.withMedias,o=void 0===i||i,r=l.withFonts,s=void 0===r||r,u=l.withMigrations;return null===e?e:[[o,function(e){return t.mediasParser.fromPath(e)}],[n,function(e){return t.themeParser.parse(e)}],[s,function(e){return t.fontsParser.parse(e)}],[void 0===u||u,function(e){return t.migrationsParser.parse(e)}]].reduce(function(e,t){var l=(0,R.A)(t,2),a=l[0],n=l[1];return a?n(e):e},e)}}])}(),ie=["value"],oe=["value","currentTime"],re=function(e){function t(){var e,l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,f.A)(this,t),(e=(0,C.A)(this,t,[l])).screensViewed=[],e}return(0,w.A)(t,e),(0,p.A)(t,[{key:"trackScreenView",value:function(e,t){var l=(this.variables||{}).screensCount,a=void 0===l?null:l,n=e||{},i=n.id,r=void 0===i?null:i,s=n.type,u=void 0===s?null:s,d=n.metadata,c=void 0===d?null:d,m=n.parameters,v=(void 0===m?{}:m).metadata,g=c||v||{},y=g.title,h=g.description;-1===this.screensViewed.indexOf(r||t)&&(this.screensViewed=[].concat((0,o.A)(this.screensViewed),[r||t]));var f={event:"screenView",screenId:r,screenType:u,screenIndex:t,screenTitle:y,screenDescrition:h,screenProgress:null!==a&&null!==t?(t+1)/a:null,screensViewed:this.screensViewed,screensViewedProgress:null!==a?this.screensViewed.length/a:null};this.push(f)}},{key:"trackEvent",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=(arguments.length>3&&void 0!==arguments[3]?arguments[3]:null)||{},n=a.value,o=void 0===n?null:n,s=(0,r.A)(a,ie),u=(0,i.A)((0,i.A)({},s||null),{},{event:"eventInteraction",eventCategory:e,eventAction:t,eventLabel:l,eventValue:o});this.push(u)}},{key:"trackMedia",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=(arguments.length>3&&void 0!==arguments[3]?arguments[3]:null)||{},n=a.value,o=void 0===n?null:n,s=a.currentTime,u=void 0===s?null:s,d=(0,r.A)(a,oe),c=t||{},m=c.id,v=void 0===m?null:m,g=c.url,y=void 0===g?null:g,h=c.name,f=void 0===h?null:h,p=c.duration,b=void 0===p?null:p,x=c.currentTime,A=void 0===x?u:x,S=c.metadata,C=((void 0===S?{}:S)||{}).duration,w=void 0===C?b:C,k=(0,i.A)((0,i.A)({},d||null),{},{event:"eventInteraction",eventCategory:e,eventAction:l,eventLabel:f||y,eventValue:o,mediaId:v,mediaUrl:y,mediaName:f});null!==w&&(k.mediaDuration=Math.round(w)),null!==A&&(k.mediaCurrentTime=Math.round(A)),null!==A&&null!==w&&w>0&&(k.mediaProgress=A/w),this.push(k)}}])}(z.yI),se=l(1085),ue=(l(3478),l(3551)),de=l(7252),ce=l(986),me=l.n(ce),ve=l(9993),ge=l(6330),ye=l(1919);l(9182);var he=function(e){return null!==e?Object.keys(e).map(function(t){return"".concat((0,M.kW)(t),":").concat(me()(e[t])?"".concat(e[t],"px"):e[t],";")}).join("\n"):""};function fe(){return new DOMException("The request is not allowed","NotAllowedError")}function pe(e){return be.apply(this,arguments)}function be(){return(be=(0,ge.A)((0,ve.A)().m(function e(t){return(0,ve.A)().w(function(e){for(;;)switch(e.n){case 0:if(navigator.clipboard){e.n=1;break}throw fe();case 1:return e.a(2,navigator.clipboard.writeText(t))}},e)}))).apply(this,arguments)}function xe(e){return Ae.apply(this,arguments)}function Ae(){return(Ae=(0,ge.A)((0,ve.A)().m(function e(t){var l,a,n,i;return(0,ve.A)().w(function(e){for(;;)switch(e.n){case 0:(l=document.createElement("span")).textContent=t,l.style.whiteSpace="pre",l.style.webkitUserSelect="auto",l.style.userSelect="all",document.body.appendChild(l),a=window.getSelection(),n=window.document.createRange(),a.removeAllRanges(),n.selectNode(l),a.addRange(n),i=!1;try{i=window.document.execCommand("copy")}finally{a.removeAllRanges(),window.document.body.removeChild(l)}if(i){e.n=1;break}throw fe();case 1:return e.a(2)}},e)}))).apply(this,arguments)}function Se(){return(Se=(0,ge.A)((0,ve.A)().m(function e(t){var l;return(0,ve.A)().w(function(e){for(;;)switch(e.p=e.n){case 0:return e.p=0,e.n=1,pe(t);case 1:case 4:e.n=6;break;case 2:return e.p=2,l=e.v,e.p=3,e.n=4,xe(t);case 5:throw e.p=5,e.v||l||fe();case 6:return e.a(2)}},e,null,[[3,5],[0,2]])}))).apply(this,arguments)}var Ce=function(e){return function(t,l){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];(0,a.useEffect)(function(){return n&&null!==e&&e.subscribe(t,l),function(){n&&null!==e&&e.unsubscribe(t,l)}},[e,t,l,n])}};function we(e){return"undefined"!=typeof CSS&&"function"==typeof CSS.escape?CSS.escape(e):e.replace(/([^\x00-\x7F]|[!"#$%&'()*+,.\/:;<=>?@\[\\\]^`{|}~])/g,"\\$1")}var ke=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(null===e)return null;var l=y()(e)?{color:e}:e,a=l.color,n=void 0===a?null:a,i=l.alpha,o=void 0===i?null:i;return null!==o||null!==t?(0,ye.A)(n).setAlpha(null!==t?t:o).toRgbString():n},je=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return null===t||null===e?l:t[(0,M.fL)(e)]||t[e]||l},Me=[{name:"mobile"},{name:"small",mediaQuery:"only screen and (min-width: 500px)"},{name:"medium",mediaQuery:"only screen and (min-width: 790px)"},{name:"large",mediaQuery:"only screen and (min-width: 1000px)"},{name:"very-large",mediaQuery:"only screen and (min-width: 1600px)"}],Ne=function(){return Me},Fe=function(e){var t=e.displayName,l=void 0===t?null:t,a=e.name;return l||(void 0===a?null:a)||"Component"},Te=function(e){if(null==e)return null;var t=S()(e)?e:{name:e},l=t.name,a=t.fallback;return[l,void 0===a?null:a].filter(function(e){return null!==e}).map(function(e){return'"'.concat(e,'"')}).join(", ")},Re=["isPreview","isView","current","openWebView","enableInteraction","disableInteraction"],ze=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.isPreview,n=void 0!==l&&l,o=t.isView,s=void 0!==o&&o,u=t.current,d=void 0!==u&&u,c=t.openWebView,m=void 0!==c&&c,v=t.enableInteraction,g=void 0===v||v,y=t.disableInteraction,h=void 0!==y&&y,f=(0,r.A)(t,Re),p=(e||{}).callToAction,b=void 0===p?null:p;return(0,a.useMemo)(function(){return{callToAction:(0,i.A)((0,i.A)({},b),{},{animationDisabled:n,focusable:d&&s,openWebView:m,enableInteraction:g,disableInteraction:h},f)}},[b,n,s,d,g,h,f])},$e=function(e){return(e-Math.floor(e)).toFixed(4)},Le=["image","video","media","color"],Ie=function(e){return null!==e&&x()(e)?e:Object.keys(e||{}).reduce(function(t,l){return[].concat((0,o.A)(t),[(0,i.A)({handle:l},e[l])])},[])},Pe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},n=a.resolution,o=void 0===n?1:n,r=a.maxDiff,s=void 0===r?800:r,u=a.supportsWebp,d=void 0!==u&&u,c=e||{},m=c.sizes,v=void 0===m?null:m,g=c.url,y=void 0===g?null:g,h=c.webp_url,f=void 0===h?null:h,p=c.metadata,b=void 0===p?{}:p,x=b.width,A=b.height,S=d&&null!==f?f:y;if(null===v||null===t&&null===l)return S;var C=(0,i.A)({original:{url:S,width:x,height:A}},v),w=null!==t&&null!==o?t*o:t,k=null!==l&&null!==o?l*o:l;return Object.keys(C).reduce(function(e,t){var l=e.diff,a=e.isLarger,n=e.size,i=C[t],o=i.url,r=i.webp_url,u=void 0===r?null:r,c=i.width,m=void 0===c?null:c,v=i.height,g=void 0===v?null:v,y=d&&null!==u?u:o,h=null!==m&&null!==w?m-w:null,f=null!==g&&null!==k?g-k:null,p=(null===h||h>=0)&&(null===f||f>=0),b=[h,f].reduce(function(e,t){return null!==t?(e||0)+Math.abs(t):e},null);null===b&&(b=1/0);var x=(m||0)+(g||0)>n;return b<l&&p||b<l&&(!a&&x||l>s)||b<=s&&!a&&p||b<=s&&!a&&!p&&x?{key:t,url:y,diff:b,isLarger:p}:e},{key:null,url:S,diff:1/0,isLarger:!1,size:0}).url},Be=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(null===e)return null;var a=e.horizontal,n=void 0===a?null:a,i=e.vertical,o=void 0===i?null:i,r=function(e){return"left"===e?"flex-start":"middle"===e?"center":"right"===e?"flex-end":null}(n),s=function(e){return"top"===e?"flex-start":"middle"===e?"center":"bottom"===e?"flex-end":null}(o);return t?{justifyContent:s||l,alignItems:r||l}:{justifyContent:r||l,alignItems:s||s}},Ee=function(){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"backgroundColor",t=ke(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,arguments.length>2&&void 0!==arguments[2]?arguments[2]:null);return null!==t?(0,h.A)({},e,t):null},Ve=function(e){if(null===e)return null;var t=e.backgroundColor,l=void 0===t?null:t,a=e.borderRadius,n=void 0===a?null:a,o=e.padding,r=void 0===o?null:o,s=e.paddingTop,u=void 0===s?null:s,d=e.paddingRight,c=void 0===d?null:d,m=e.paddingBottom,v=void 0===m?null:m,g=e.paddingLeft,y=void 0===g?null:g,h=e.borderWidth,f=void 0===h?null:h,p=e.borderStyle,b=void 0===p?null:p,x=e.borderColor,A=void 0===x?null:x,C=e.shadowAngle,w=void 0===C?null:C,k=e.shadowDistance,j=void 0===k?null:k,M=e.shadowBlur,N=void 0===M?null:M,F=e.shadowColor,T={width:f,style:b,color:A},R={shadowAngle:w,shadowDistance:j,shadowBlur:N,shadowColor:void 0===F?null:F},z=S()(r)?r:{padding:r},$=z.top,L=void 0===$?null:$,I=z.right,P=void 0===I?null:I,B=z.bottom,E=void 0===B?null:B,V=z.left,D=void 0===V?null:V,O=z.padding,H=void 0===O?null:O;return(0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)({},Ee(l,"backgroundColor")),null!==n?{borderRadius:n}:null),function(e){if(null==e)return null;var t=e.width,l=void 0===t?null:t,a=e.style,n=void 0===a?null:a,o=e.color,r=void 0===o?null:o;return(0,i.A)((0,i.A)((0,i.A)({},null!==l?{borderWidth:l}:null),null!==n?{borderStyle:n}:null),Ee(r,"borderColor"))}(T)),function(e){if(null==e)return null;var t=e||{},l=t.shadowAngle,a=void 0===l?null:l,n=t.shadowDistance,i=void 0===n?null:n,o=t.shadowBlur,r=void 0===o?null:o,s=t.shadowColor;if(!a)return null;var u,d,c=r||"0",m=ke(void 0===s?null:s)||"#000000",v=(u=a,d=i,{x:(Math.cos(u)*d).toFixed(3),y:(Math.sin(u)*d).toFixed(3)}),g=v.y;return{boxShadow:"".concat(v.x,"px ").concat(g,"px ").concat(c,"px 0 ").concat(m)}}(R)),null!==r||null!==H?{padding:r||H}:null),null!==u||null!==L?{paddingTop:u||L}:null),null!==c||null!=P?{paddingRight:c||P}:null),null!==v||null!==E?{paddingBottom:v||E}:null),null!==y||null!==D?{paddingLeft:y||D}:null)},De=function(e){if(null==e)return null;var t=e.textColor,l=void 0===t?null:t,a=e.color,n=void 0===a?null:a,o=null!==n?ke(n):null,r=null!==o?"0.05em 0px 0px ".concat(o,", -0.05em 0px 0px ").concat(o):null;return null!==n||null!==l?(0,i.A)((0,i.A)((0,i.A)({},null!==n?Ee(n,"backgroundColor"):null),null!==l?Ee(l,"color"):null),null!==n?{boxShadow:r,mozBoxShadow:r,msBoxShadow:r,webkitBoxShadow:r}:null):null},Oe=function(e){if(null==e)return null;var t=e.color,l=void 0===t?null:t,a=e.fontStyle||{},n=a.italic,o=void 0!==n&&n,r=a.bold,s=void 0!==r&&r,u=a.underline,d=void 0!==u&&u;return(0,i.A)((0,i.A)((0,i.A)((0,i.A)({},null!==l?Ee(l,"color"):null),o?{fontStyle:"italic"}:null),s?{fontWeight:"bold"}:null),d?{textDecoration:"underline"}:null)},He=function(e){if(null==e)return null;var t=e.fontFamily,l=void 0===t?null:t,a=e.fontSize,n=void 0===a?null:a,o=e.fontStyle,r=void 0===o?null:o,s=e.fontWeight,u=void 0===s?null:s,d=e.lineHeight,c=void 0===d?null:d,m=e.letterSpacing,v=void 0===m?null:m,g=e.align,y=void 0===g?null:g,h=e.color,f=void 0===h?null:h,p=r||{},b=p.italic,x=void 0!==b&&b,A=p.bold,S=void 0!==A&&A,C=p.underline,w=void 0!==C&&C,k=p.transform,j=void 0===k?null:k,M=p.outline,N=void 0!==M&&M;return(0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)({fontFamily:Te(l)},null!==n?{fontSize:n}:null),x?{fontStyle:"italic"}:null),S?{fontWeight:"bold"}:null),null!==u?{fontWeight:u}:null),w?{textDecoration:"underline"}:null),null!==j?{textTransform:j}:null),null!==y?{textAlign:y}:null),null!==c?{lineHeight:c}:null),null!==v?{letterSpacing:v}:null),Ee(f,"color")),N?{WebkitTextStroke:"2px ".concat(ke(f,"color")),color:"transparent"}:null)},Ze=function(e){if(null==e)return null;var t=e.top,l=void 0===t?null:t,a=e.bottom,n=void 0===a?null:a;return(0,i.A)((0,i.A)({},null!==l?{marginTop:l}:null),null!==n?{marginBottom:n}:null)},We=["video/mp4"],qe=null;function _e(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:We;if(null===qe){var t=document.createElement("video");qe=(e||We).filter(function(e){return""!==t.canPlayType(e)})}return qe}var Ge=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(null==e)return!1;var t=(e||{}).badge,l=(void 0===t?null:t)||{},a=l.active,n=void 0!==a&&a,i=l.label,o=((void 0===i?null:i)||{}).body;return n&&null!==(void 0===o?null:o)},Ye=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(null==e)return!1;var t=(e||{}).callToAction,l=(void 0===t?null:t)||{},a=l.active,n=void 0!==a&&a,i=l.label,o=((void 0===i?null:i)||{}).body;return n&&null!==(void 0===o?null:o)},Ue=function(){return["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document},Qe=function(e){if(null==e)return!1;var t=e||{},l=t.media,a=void 0===l?null:l,n=t.url;return null!==a||null!==(void 0===n?null:n)},Xe=function(e){if(null==e)return!1;var t=(e||{}).label,l=((void 0===t?null:t)||{}).length,a=void 0===l?0:l;return"number"==typeof a&&a>0},Je=function(e){if(null==e)return!1;var t=(e||{}).body,l=((void 0===t?null:t)||{}).length,a=void 0===l?0:l;return"number"==typeof a&&a>0},Ke=function(e){if(null==e)return!1;var t;try{t=new URL(e)}catch(e){return!1}return"http:"===t.protocol||"https:"===t.protocol},et="screens",tt=a.createContext(null),lt={},at=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=(0,a.useContext)(tt);return(0,a.useMemo)(function(){return null!==e?new L(t.getComponents(e)):t},[t,e])};function nt(e){var t=e.components,l=void 0===t?lt:t,n=e.manager,o=void 0===n?null:n,r=e.namespace,s=void 0===r?null:r,u=e.children,d=at()||null,c=(0,a.useMemo)(function(){return new L((0,i.A)((0,i.A)((0,i.A)({},null!==d?d.getComponents():null),null!==o?o.getComponents():null),new L(l).addNamespace(s).getComponents()))},[d,o,l,s]);return(0,se.jsx)(tt.Provider,{value:c,children:u})}var it=(0,ue.YK)({functionality_title:{id:"consent.functionality_title",defaultMessage:[{type:0,value:"Functionnal"}]},functionality_description:{id:"consent.functionality_description",defaultMessage:[{type:0,value:"Cookies required for the site to function properly."}]},analytics_title:{id:"consent.analytics_title",defaultMessage:[{type:0,value:"Analytics"}]},analytics_description:{id:"consent.analytics_description",defaultMessage:[{type:0,value:"Cookies used to measure user behavior."}]},ad_storage_title:{id:"consent.ad_storage_title",defaultMessage:[{type:0,value:"Ad Storage"}]},ad_storage_description:{id:"consent.ad_storage_description",defaultMessage:[{type:0,value:"Cookies used for advertising purposes."}]},ad_personalization_title:{id:"consent.ad_personalization_title",defaultMessage:[{type:0,value:"Ad Personalization"}]},ad_personalization_description:{id:"consent.ad_personalization_description",defaultMessage:[{type:0,value:"Cookies used for ad targeting."}]},ad_user_data_title:{id:"consent.ad_user_data_title",defaultMessage:[{type:0,value:"User Ad Data"}]},ad_user_data_description:{id:"consent.ad_user_data_description",defaultMessage:[{type:0,value:"Cookies used for user-specific ad data."}]},personalization_storage_title:{id:"consent.personalization_storage_title",defaultMessage:[{type:0,value:"Personalization Storage"}]},personalization_storage_description:{id:"consent.personalization_storage_description",defaultMessage:[{type:0,value:"Cookies used for personalizing user experience."}]},security_storage_title:{id:"consent.security_storage_title",defaultMessage:[{type:0,value:"Security Storage"}]},security_storage_description:{id:"consent.security_storage_description",defaultMessage:[{type:0,value:"Cookies used for security purposes."}]}});it.functionality_title,it.functionality_description,it.security_storage_title,it.security_storage_description,it.personalization_storage_title,it.personalization_storage_description,it.analytics_title,it.analytics_description,it.ad_storage_title,it.ad_storage_description,it.ad_personalization_title,it.ad_personalization_description,it.ad_user_data_title,it.ad_user_data_description;var ot=a.createContext(null),rt=a.createContext(new D),st=function(){return(0,a.useContext)(rt)};function ut(e){var t=e.screens,l=void 0===t?null:t,n=e.namespaces,i=void 0===n?null:n,o=e.filterNamespaces,r=void 0!==o&&o,s=e.manager,u=void 0===s?null:s,d=e.children,c=st(),m=(0,a.useMemo)(function(){var e=null!==u?u:new D(l);return null!==(c||null)&&(e=c.merge(e)),r&&(e=c.filter(function(e){var t=e.namespaces,l=void 0===t?null:t;return null===l||null!==i&&l.reduce(function(e,t){return e||-1!==i.indexOf(t)},!1)})),e},[u,l,i,r,c]),v=(0,a.useMemo)(function(){return m.getComponents()},[m]),g=(0,a.useState)(v),y=(0,R.A)(g,2),h=y[0],f=y[1];return(0,a.useEffect)(function(){var e=function(){return f(m.getComponents())};return m.on("change",e),function(){m.off("change",e)}},[m,f]),(0,se.jsx)(rt.Provider,{value:m,children:(0,se.jsx)(nt,{namespace:et,components:h,children:d})})}var dt=(0,a.createContext)(null),ct=function(){return(0,a.useContext)(dt)};function mt(e){var t=e.story,l=void 0===t?null:t,a=e.children;return(0,se.jsx)(dt.Provider,{value:l,children:a})}var vt=a.createContext({}),gt=function(){return(0,a.useContext)(vt)},yt=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=(gt()||{})[e];return void 0===l?t:l};function ht(e){var t=e.children,l=e.settings,n=void 0===l?null:l,o=gt(),r=(0,a.useMemo)(function(){return(0,i.A)((0,i.A)({},o),n)},[n,o]);return(0,se.jsx)(vt.Provider,{value:r,children:t})}var ft=a.createContext({apiKey:null}),pt=function(){return(0,a.useContext)(ft)};function bt(e){var t=e.children,l=e.apiKey,n=void 0===l?null:l,i=pt().apiKey,o=yt("googleApiKey"),r=(0,a.useMemo)(function(){return{apiKey:n||i||o}},[n,i,o]);return(0,se.jsx)(ft.Provider,{value:r,children:t})}var xt=a.createContext(null),At=function(){return(0,a.useContext)(xt)};function St(e){var t=e.children,l=e.locale,n=void 0===l?"fr":l,i=e.libraries,o=void 0===i?null:i,r=pt().apiKey,s=At(),u=(0,a.useState)(s),d=(0,R.A)(u,2),c=d[0],m=d[1];return(0,a.useEffect)(function(){null===s&&(0,de.pO)({apiKey:r,locale:n,libraries:o}).then(function(e){m(e)})},[r,n,o,m,s]),(0,se.jsx)(xt.Provider,{value:c,children:t})}var Ct={seekBarOnly:!1,color:null,progressColor:null},wt={playing:!1,paused:!1,completed:!1,muted:!0,controls:!1,controlsSuggestPlay:!1,controlsVisible:!1,media:null,controlsTheme:Ct,currentQualityLevel:null},kt=a.createContext((0,i.A)((0,i.A)({},wt),{},{setMuted:function(){},setPlaying:function(){},setControls:function(){},setControlsVisible:function(){},setControlsTheme:function(){},showControls:function(){},hideControls:function(){},setMedia:function(){},setCurrentQualityLevel:function(){},setIsBackground:function(){}})),jt=function(){return(0,a.useContext)(kt)},Mt=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=jt(),i=n.setMedia,o=n.setIsBackground,r=n.media,s=(0,a.useRef)(null);return(0,a.useEffect)(function(){return function(){e&&(i(null),o(!1))}},[e,i,o,l]),(0,a.useEffect)(function(){e&&null!==s.current&&null===r&&(o(t),i(s.current))},[e,t,r,l,i,o]),{ref:s,isCurrent:s.current===r}};function Nt(e){var t=e.muted,l=void 0===t||t,n=e.playing,o=void 0!==n&&n,r=e.paused,s=void 0!==r&&r,u=e.controls,d=void 0!==u&&u,c=e.controlsSuggestPlay,m=void 0!==c&&c,v=e.controlsVisible,g=void 0!==v&&v,y=e.controlsTheme,h=void 0===y?Ct:y,f=e.currentQualityLevel,p=void 0===f?null:f,b=e.children,x=(0,a.useState)(l),A=(0,R.A)(x,2),S=A[0],C=A[1],w=(0,a.useState)(o),k=(0,R.A)(w,2),j=k[0],M=k[1],N=(0,a.useState)(null),F=(0,R.A)(N,2),T=F[0],z=F[1],$=(0,a.useState)(!1),L=(0,R.A)($,2),I=L[0],P=L[1],B=(0,a.useState)(d),E=(0,R.A)(B,2),V=E[0],D=E[1],O=(0,a.useState)(m),H=(0,R.A)(O,2),Z=H[0],W=H[1],q=(0,a.useState)(g),_=(0,R.A)(q,2),G=_[0],Y=_[1],U=(0,a.useState)(h),Q=(0,R.A)(U,2),X=Q[0],J=Q[1],K=(0,a.useState)(p),ee=(0,R.A)(K,2),te=ee[0],le=ee[1],ae=(0,a.useCallback)(function(e){e?(D(!0),Y(!0),W(!1)):(D(!1),Y(!1),W(!1))},[D,Y,W]),ne=(0,a.useCallback)(function(e){J((0,i.A)((0,i.A)({},Ct),e))},[J]),ie=(0,a.useCallback)(function(e){e&&W(!1),M(e)},[M,W]);(0,a.useEffect)(function(){W(!1)},[T,W]);var oe=(0,a.useState)(!1),re=(0,R.A)(oe,2),ue=re[0],de=re[1],ce=(0,a.useCallback)(function(){return de(!0)},[de]);(0,a.useEffect)(function(){return null!==T&&T.addEventListener("ended",ce),function(){null!==T&&T.removeEventListener("ended",ce),de(!1)}},[T,ce,de]);var me=(0,a.useCallback)(function(){return Y(!0)},[Y]),ve=(0,a.useCallback)(function(){Y(!1)},[Y]),ge=(0,a.useMemo)(function(){return null!==T&&"video"===T.tagName.toLowerCase()&&("audio"===T.tagName.toLowerCase()||(void 0===T.dataset.hasAudio?null:"true"===T.dataset.hasAudio||!0===T.dataset.hasAudio))},[T]),ye=(0,a.useCallback)(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;null!==t&&null!==T&&t!==T||le(e)},[T,le]),he=(0,a.useMemo)(function(){return{muted:S,playing:j&&!s,completed:ue,controls:V,controlsSuggestPlay:Z,controlsVisible:G,media:T,hasAudio:ge,controlsTheme:X,currentQualityLevel:te,setMuted:C,setIsBackground:P,isBackground:I,setPlaying:ie,setControls:ae,setControlsSuggestPlay:W,setControlsVisible:Y,setControlsTheme:ne,showControls:me,hideControls:ve,setMedia:z,setCurrentQualityLevel:ye}},[S,j,ue,s,V,Z,G,X,T,ge,te,C,P,I,ie,ae,ne,W,Y,me,ve,z,ye]);return(0,se.jsx)(kt.Provider,{value:he,children:b})}var Ft=a.createContext({data:null,definition:null,renderContext:null}),Tt=function(){return(0,a.useContext)(Ft)},Rt=function(){var e=(Tt()||{}).renderContext,t=void 0===e?"view":e,l="static"===t,a="capture"===t;return{renderContext:t,isPlaceholder:"placeholder"===t,isPreview:"preview"===t,isEdit:"edit"===t,isView:"view"===t||l||a,isStatic:l,isCapture:a}},zt=function(){return(Tt()||{}).screenState};function $t(e){var t=e.data,l=void 0===t?null:t,n=e.definition,i=void 0===n?null:n,o=e.renderContext,r=void 0===o?null:o,s=e.screenState,u=void 0===s?null:s,d=e.children,c=Tt()||{},m=c.data,v=void 0===m?null:m,g=c.definition,y=void 0===g?null:g,h=c.renderContext,f=void 0===h?null:h,p=c.screenState,b=void 0===p?null:p,x=l||v||null,A=(x||{}).type,S=void 0===A?null:A,C=st(),w=null!==C?C.getDefinition(S):null,k=i||w||y,j=r||f||"view",M=u||b||null,N=(0,a.useMemo)(function(){return{data:x,definition:k,renderContext:j,screenState:M}},[x,k,j,M]);return(0,se.jsx)(Ft.Provider,{value:N,children:d})}var Lt=a.createContext({screen:null,screens:[],width:0,height:0,resolution:1,landscape:!1}),It=function(){return(0,a.useContext)(Lt)};function Pt(e){var t=e.size,l=void 0===t?{}:t,n=e.children,i=l.screen,o=l.width,r=l.height,s=l.resolution,u=(0,a.useMemo)(function(){return l},[i,o,r,s]);return(0,se.jsx)(Lt.Provider,{value:u,children:n})}var Bt=function(){return(0,a.useContext)(z.fu)};function Et(e){var t=e.variables,l=void 0===t?null:t,n=e.disabled,o=void 0!==n&&n,r=e.paused,s=void 0!==r&&r,u=e.children,d=Bt()||null,c=(0,a.useRef)(null),m=(0,a.useMemo)(function(){return null===c.current?c.current=new re({variables:(0,i.A)((0,i.A)({},null!==d?d.getVariables():null),l),disabled:o,paused:s}):(c.current.setVariables((0,i.A)((0,i.A)({},c.current.getVariables()),l)),c.current.setDisabled(o),c.current.setPaused(s)),c.current},[d,l,o,s]);return(0,se.jsx)(z.fE,{tracking:m,children:u})}var Vt={events:new(j()),menuVisible:!1,menuOverScreen:!1,topHeight:0,bottomHeight:0,bottomSidesWidth:0,gotoNextScreen:function(){},gotoPreviousScreen:function(){},disableInteraction:function(){},enableInteraction:function(){}},Dt=a.createContext((0,i.A)((0,i.A)({},Vt),{},{webView:null,setWebView:function(){}})),Ot=function(){return(0,a.useContext)(Dt)},Ht=function(){var e=Ot();return{gotoNextScreen:e.gotoNextScreen,gotoPreviousScreen:e.gotoPreviousScreen}},Zt=function(){var e=Ot().containerRef,t=void 0===e?null:e;return null!==t?t.current:null},Wt=function(){var e=Ot();return{disableInteraction:e.disableInteraction,enableInteraction:e.enableInteraction}},qt=function(){var e=Ot(),t=e.webView,l=e.setWebView;return(0,a.useMemo)(function(){return(0,i.A)((0,i.A)({},t),{},{opened:null!==t,open:function(e){return l(y()(e)?{url:e}:e)},close:function(){return l(null)},update:function(e){return l((0,i.A)((0,i.A)({},t),e))}})},[t,l])};function _t(e){var t=e.children,l=e.containerRef,n=e.events,i=void 0===n?new(j()):n,o=e.menuVisible,r=void 0!==o&&o,s=e.menuOverScreen,u=void 0!==s&&s,d=e.width,c=e.height,m=e.topHeight,v=void 0===m?0:m,g=e.bottomHeight,y=void 0===g?0:g,h=e.bottomSidesWidth,f=void 0===h?0:h,p=e.gotoNextScreen,b=void 0===p?function(){}:p,x=e.gotoPreviousScreen,A=void 0===x?function(){}:x,S=e.disableInteraction,C=void 0===S?function(){}:S,w=e.enableInteraction,k=void 0===w?function(){}:w,M=(0,a.useState)(null),N=(0,R.A)(M,2),F=N[0],T=N[1],z=(0,a.useMemo)(function(){return{containerRef:l,events:i,menuVisible:r,menuOverScreen:u,width:d,height:c,topHeight:v,bottomHeight:y,bottomSidesWidth:f,gotoNextScreen:b,gotoPreviousScreen:A,disableInteraction:C,enableInteraction:k,webView:F,setWebView:T}},[l,i,r,u,d,c,v,y,f,b,A,C,k,F,T]);return(0,se.jsx)(Dt.Provider,{value:z,children:t})}var Gt=(0,a.createContext)({visitor:null,setVisitor:function(){}});function Yt(){return(0,a.useContext)(Gt).visitor}function Ut(e){var t=e.visitor,l=void 0===t?null:t,n=e.children,i=(0,a.useState)(y()(l)?{id:l}:l),o=(0,R.A)(i,2),r=o[0],s=o[1];(0,a.useEffect)(function(){l!==r&&s(y()(l)?{id:l}:l)},[l,s]);var u=(0,a.useMemo)(function(){return{visitor:r,setVisitor:function(e){return s(y()(e)?{id:e}:e)}}},[r,s]);return(0,se.jsx)(Gt.Provider,{value:u,children:n})}var Qt=l(7736),Xt=l(3022),Jt=l(3373),Kt=l.n(Jt),el=l(4739),tl=l.n(el),ll=l(719),al=l.n(ll),nl=l(124),il=l.n(nl),ol=l(2992),rl=l(3464);function sl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.element,l=void 0===t?null:t,n=e.disabled,i=void 0!==n&&n,o=e.timeout,r=void 0===o?2e3:o,s=(0,a.useRef)(l),u=(0,a.useState)(!1),d=(0,R.A)(u,2),c=d[0],m=d[1],v=(0,a.useRef)(c);return null!==l&&l!==s.current&&(s.current=l),(0,a.useEffect)(function(){var e=s.current,t=void 0===e?null:e;if(null===t||i)return function(){};var l=null;function a(){null!==l&&(clearTimeout(l),l=null),v.current||(v.current=!0,m(!0)),l=setTimeout(function(){v.current=!1,m(!1)},r)}return t.addEventListener("keydown",a),t.addEventListener("mousedown",a),t.addEventListener("mousemove",a),t.addEventListener("mouseup",a),t.addEventListener("pointerdown",a),t.addEventListener("pointermove",a),t.addEventListener("pointerup",a),t.addEventListener("touchmove",a),t.addEventListener("touchstart",a),function(){null!==l&&(clearTimeout(l),l=null),t.removeEventListener("keydown",a),t.removeEventListener("mousedown",a),t.removeEventListener("mousemove",a),t.removeEventListener("mouseup",a),t.removeEventListener("pointerdown",a),t.removeEventListener("pointermove",a),t.removeEventListener("pointerup",a),t.removeEventListener("touchmove",a),t.removeEventListener("touchstart",a)}},[l,i,r]),{ref:s,detected:c}}l(7228);var ul=function(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:300;(0,a.useEffect)(function(){var a=setTimeout(function(){null!==e&&e(t)},l);return function(){clearTimeout(a)}},[t,l])};function dl(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.progress,l=e.onTap,n=void 0===l?null:l,o=e.disabled,r=void 0!==o&&o,s=e.dragDisabled,u=void 0!==s&&s,d=e.computeProgress,c=void 0===d?null:d,m=e.onProgress,v=void 0===m?null:m,g=e.onPointerDown,y=void 0===g?null:g,h=e.onScroll,f=void 0===h?null:h,p=e.springParams,b=void 0===p?void 0:p,x=e.dragOptions,A=void 0===x?{filterTaps:!0}:x,S=(0,a.useRef)(!1),C=(0,a.useRef)(t),w=(0,a.useRef)(t);t!==w.current&&(w.current=t);var k=(0,a.useState)(!1),j=(0,R.A)(k,2),M=j[0],N=j[1],F=(0,a.useState)(0),T=(0,R.A)(F,2),z=T[0],$=T[1],L=(0,Qt.U2)(),I=(0,Qt.zh)(function(){return(0,i.A)({ref:L,from:{progress:t}},b)}),P=(0,R.A)(I,2),B=P[0].progress,E=P[1],V=(0,a.useCallback)(function(e){var t=e.active,l=e.tap;if(r)S.current=!1;else{if(l)return S.current=!1,void(null!==n&&n(e));if(u)S.current=!1;else{var a=c(e);S.current=t,$(a<w.current?-1:1),C.current=a,t!==M&&N(t),E.start((0,i.A)({progress:a,immediate:t,onResolve:t?function(){}:function(){$(0)}},b)),null!==v&&v(a,e)}}},[N,r,n,c,M,v]),D=(0,Xt.useGesture)({onDrag:V,onPointerDown:null!==y?y:function(){},onScroll:null!==f?f:function(){}},{drag:A});return(0,a.useEffect)(function(){S.current||t===C.current||($(t<C.current?-1:1),C.current=t,E.start((0,i.A)({progress:t,immediate:r,onResolve:function(){$(0)}},b)))},[t,r]),{transitioning:(0,a.useMemo)(function(){return t!==B.get()||B.isAnimating||M},[t,B.isAnimating,M]),bind:D,dragging:M,progress:B,direction:z}}Ce("undefined"!=typeof document?new P(document):null);var cl=["entry"],ml=new Map,vl=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=t.root,r=void 0===n?null:n,s=t.rootMargin,u=void 0===s?null:s,d=t.threshold,c=void 0===d?null:d,m=t.disabled,v=void 0!==m&&m,g=(0,a.useState)(l),y=(0,R.A)(g,2),h=y[0],f=y[1],p=(0,a.useRef)(null),b=(0,a.useRef)(null),x=p.current!==b.current;return(0,a.useEffect)(function(){var t=p.current,l=function(e){return f(e)},a=null;if(null!==t){var n={};null!==r&&(n.root=r),null!==u&&(n.rootMargin=u),null!==c&&(n.threshold=c);var s=function(e){var t,l,a,n,r,s,u=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},d=(a=void 0===(l=(t=u).root)?null:l,n=t.rootMargin,s=void 0===(r=t.threshold)?null:r,"root_".concat(a,"_rootMargin_").concat(n||null,"_threshold_").concat(s));ml.has(e)||ml.set(e,{});var c=ml.get(e);return void 0===c[d]&&(c[d]=function(e){var t=[],l=new e(function(e){e.forEach(function(e){t.forEach(function(t){var l=t.element,a=t.callbacks;l===e.target&&a.forEach(function(t){t(e)})})})},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{});return{subscribe:function(e,a){var n=t.find(function(t){return t.element===e})||null;t=function(e,l){return null!==(t.find(function(t){return t.element===e})||null)?t.map(function(t){return t.element===e&&-1===t.callbacks.indexOf(l)?(0,i.A)((0,i.A)({},t),{},{callbacks:[].concat((0,o.A)(t.callbacks),[l])}):t}).filter(function(e){return e.callbacks.length>0}):[].concat((0,o.A)(t),[{element:e,callbacks:[l]}])}(e,a),null===n&&l.observe(e)},unsubscribe:function(e){if(t=function(e,l){return t.map(function(t){return t.element===e?(0,i.A)((0,i.A)({},t),{},{callbacks:t.callbacks.filter(function(e){return e!==l})}):t}).filter(function(e){return e.callbacks.length>0})}(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:null),void 0===l.unobserve)return l.disconnect(),void t.forEach(function(e){l.observe(e.element)});null===(t.find(function(t){return t.element===e})||null)&&l.unobserve(e)},observer:l}}(e,u),ml.set(e,c)),c[d]}(e,n),d=s.subscribe,m=s.unsubscribe;a=m,d(t,l)}return b.current=t,function(){null!==a&&a(t,l)}},[e,x,v,r,u,c]),{ref:p,entry:h}},gl=[0,1],yl={target:null,time:null,isVisible:!1,isIntersecting:!1,intersectionRatio:0,intersectionRect:null,boundingClientRect:null,rootBounds:null},hl={target:null,contentRect:null,contentBoxSize:null,borderBoxSize:null},fl=function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).disabled;return vl("undefined"!=typeof window?ResizeObserver:null,{disabled:void 0!==e&&e},hl)},pl=function(){var e=fl.apply(void 0,arguments),t=e.entry,l=(0,r.A)(e,cl),a=t||{},n=a.contentRect,o=void 0===n?null:n,s=a.borderBoxSize,u=void 0===s?null:s,d=o||{},c=d.width,m=void 0===c?0:c,v=d.height,g=void 0===v?0:v,y=x()(u)?u[0]||{}:u||{},h=y.blockSize,f=void 0===h?null:h,p=y.inlineSize,b=void 0===p?null:p;return(0,i.A)((0,i.A)({},l),{},{entry:t,width:b||m,height:f||g})},bl=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.rootMargin,l=e.persist,n=void 0!==l&&l,i=e.disabled,o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.root,l=void 0===t?null:t,a=e.rootMargin,n=void 0===a?"0px":a,i=e.threshold,o=void 0===i?gl:i,r=e.disabled;return vl("undefined"!=typeof window?IntersectionObserver:null,{root:l,rootMargin:n,threshold:o,disabled:void 0!==r&&r},yl)}({rootMargin:t,disabled:void 0!==i&&i}),r=o.ref,s=o.entry.isIntersecting,u=(0,a.useRef)(s);return s&&!u.current&&(u.current=s),{ref:r,visible:!n&&s||n&&u.current}},xl={loading:[],active:[]};function Al(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).attributeName,l=void 0===t?"data-ts-offset":t,n=function(){return null!==e&&e.hasAttribute(l)?parseFloat(e.getAttribute(l)):0},i=(0,a.useState)(n()),o=(0,R.A)(i,2),r=o[0],s=o[1],u=(0,a.useRef)(null);return(0,a.useEffect)(function(){return null!==e&&(u.current=new MutationObserver(function(e){e.forEach(function(e){"attributes"===e.type&&s(n())})}),u.current.observe(e,{attributes:!0,attributeFilter:[l]})),function(){null!==u.current&&u.current.disconnect()}},[e]),r}function Sl(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.id,n=void 0===l?null:l,i=t.disabled,o=void 0!==i&&i,r=t.updateInterval,s=void 0===r?1e3:r,u=t.onUpdate,d=void 0===u?null:u,c=(0,a.useState)(0),m=(0,R.A)(c,2),v=m[0],g=m[1],y=(0,a.useRef)(v),h=Al(e),f=n||e,p=(0,a.useRef)(f),b=p.current!==f,x=(0,a.useRef)(o),A=x.current!==o;return(b||A)&&(y.current=null!==e?Math.max((e.currentTime||0)-h,0):0,p.current=f,x.current=o),(0,a.useEffect)(function(){if(null===e)return function(){};function t(){var t=Math.max((e.currentTime||0)-h,0);return t!==y.current&&(y.current=t,g(t),null!==d&&d(t)),t}if(o)return t(),function(){};var l=null;return function a(){var n=e.duration,i=void 0===n?0:n,o=t(),r=Math.floor(1e3*((i||0)-o));l=setTimeout(a,Math.max(Math.min(s,r),s))}(),function(){null!==e&&(y.current=e.currentTime-h),null!==l&&clearInterval(l)}},[n,e,g,o,s]),y.current}function Cl(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).id,l=void 0===t?null:t,n=(0,a.useState)(null!==e&&e.duration||0),i=(0,R.A)(n,2),o=i[0],r=i[1],s=Al(e),u=(0,a.useRef)(o),d=l||e,c=(0,a.useRef)(d);return c.current!==d&&(u.current=null!==e?Math.max((e.duration||0)-s,0):0,c.current=d),(0,a.useEffect)(function(){if(null===e)return u.current=0,r(0),function(){};function t(){var t=Math.max((e.duration||0)-s,0);t!==u.current&&(u.current=t,r(t))}return t(),e.addEventListener("canplay",t),e.addEventListener("loadedmetadata",t),e.addEventListener("durationchange",t),function(){e.removeEventListener("canplay",t),e.removeEventListener("loadedmetadata",t),e.removeEventListener("durationchange",t)}},[e,l,r]),u.current}var wl=["disabled"];function kl(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).id,l=void 0===t?null:t,n=(0,a.useState)(null!==e&&e.readyState>0),i=(0,R.A)(n,2),o=i[0],r=i[1],s=(0,a.useRef)(o),u=(0,a.useRef)(l);return u.current!==l&&(s.current=!1,u.current=l),(0,a.useEffect)(function(){if(null===e)return function(){};function t(){var t=o;return e.readyState>0&&!o?(r(!0),t=!0):o&&0===e.readyState&&(r(!1),t=!1),s.current=t,t}var l=t();return l||(e.addEventListener("loadedmetadata",t),e.addEventListener("canplay",t),e.addEventListener("canplaythrough",t)),function(){l||(e.removeEventListener("loadedmetadata",t),e.removeEventListener("canplay",t),e.removeEventListener("canplaythrough",t))}},[e,l]),s.current}function jl(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return(0,a.useMemo)(function(){if(S()(t))return t;var l=e||{},a=l.thumbnail_url,n=void 0===a?null:a,i=l.files,o=void 0===i?null:i,r=l.metadata,s=(void 0===r?null:r)||{},u=s.width,d=s.height,c=Ie(o)||[],m=(null!==t&&c.find(function(e){return e.handle===t})||{}).url,v=void 0===m?null:m;return null!==v||null!==n?{url:v||n,metadata:{width:u,height:d}}:null},[e,t])}function Ml(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.disabled,l=void 0!==t&&t,n=e.currentTime,i=e.duration,o=e.onStep,r=void 0===o?null:o,s=e.steps,u=void 0===s?[.1,.25,.5,.75,.9]:s,d=(0,a.useRef)({});(0,a.useEffect)(function(){if(0!==i&&!l){var e=n/i,t=d.current;u.filter(function(l){return e>l&&void 0===t[l]}).forEach(function(e){null!==r&&r(e,{duration:i,currentTime:n}),t[e]=!0})}},[i,n,l])}var Nl=["width","height"],Fl=function(){var e=(0,a.useState)(1),t=(0,R.A)(e,2),l=t[0],n=t[1];return(0,a.useEffect)(function(){n("undefined"!=typeof window&&window.devicePixelRatio||1)},[n]),l},Tl=function(e){var t=e.width,l=void 0===t?null:t,n=e.height,i=void 0===n?null:n,r=e.landscape,s=void 0!==r&&r,u=e.menuOverScreen,d=void 0!==u&&u,c=e.screens,m=void 0===c?null:c,v=e.mediaType,g=void 0===v?"screen":v,y=e.media,h=void 0===y?null:y,f=e.scale,p=void 0===f?null:f,b=Fl(),x=m||[];return(0,a.useMemo)(function(){var e=null!==h?h:{type:g,width:"".concat(l,"px"),height:"".concat(i,"px")},t=(0,o.A)(x).reverse().filter(function(t){var l=t.mediaQuery,a=void 0===l?null:l;return null===a||(0,ol.Y)(a,e)});return{screen:t.length>0?t[0].name:null,screens:(0,o.A)(t).reverse().map(function(e){return e.name}),width:l,height:i,landscape:s,menuOverScreen:d,resolution:null!==p?p*b:b,imageResolution:null!==p?Math.max(p,b):b}},[x,h,g,l,i,s,d])};var Rl=function(e,t){var l=(e||{}).data,a=(void 0===l?null:l)||{},n=a.id,i=void 0===n?null:n,o=a.type,r=t||{},s=r.screenId,u=void 0===s?null:s,d=r.screenType;return{screenId:null!==i?i:u,screenType:null!==o?o:void 0===d?null:d}},zl=function(e){return void 0!==e},$l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=Bt();if(!zl(t))return function(){};var l=Tt();return"view"!==l.renderContext?function(){}:(0,a.useCallback)(function(){var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;null!==e&&null!==a&&t.trackEvent("screen_".concat(e),a,n,(0,i.A)((0,i.A)({},o),Rl(l,o)))},[l])},Ll=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=Bt();if(!zl(t))return function(){};var l=Tt();return"view"!==l.renderContext?function(){}:(0,a.useCallback)(function(){var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;null!==e&&null!==a&&null!==n&&t.trackMedia("screen_".concat(e),a,n,(0,i.A)((0,i.A)({},o),Rl(l,o)))},[l])},Il=function(){var e=Bt();return zl(e)?(0,a.useCallback)(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;null!==t&&null!==l&&e.trackEvent(t,l,a,n)},[]):function(){}},Pl=(Ce("undefined"!=typeof window?new P(window):null),l(6220)),Bl=l(8048),El=function(){return(0,p.A)(function e(){(0,f.A)(this,e),this.locales=[]},[{key:"addLocale",value:function(e,t){var l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=this.getLocale(e);this.locales=[].concat((0,o.A)(null!==a?this.locales.filter(function(t){return t.locale!==e}):this.locales),[{locale:e,messages:null===a||l?t:(0,i.A)((0,i.A)({},a.messages),t)}])}},{key:"getLocale",value:function(e){return this.locales.find(function(t){return t.locale===e})||null}},{key:"hasLocale",value:function(e){return null!==this.getLocale(e)}},{key:"getMessages",value:function(e){var t=this.locales.find(function(t){return t.locale===e})||null;return null===t?null:t.messages}}])}(),Vl=new El,Dl=["en","fr"],Ol=a.createContext(Dl);function Hl(e){var t=e.intlManager,l=void 0===t?Vl:t,n=e.locale,o=void 0===n?null:n,r=e.locales,s=void 0===r?null:r,u=e.children,d=void 0===u?null:u,c=e.extraMessages,m=void 0===c?null:c,v=(0,a.use)(Ol),g=(0,a.use)(Pl.ob)||{},y=g.locale,h=void 0===y?null:y,f=g.messages,p=void 0===f?null:f,b=(0,a.useMemo)(function(){var e=l.getMessages(o);return(0,i.A)((0,i.A)((0,i.A)({},e),m),h===o?p:null)},[o,h,p,m]),x=(0,a.useCallback)(function(e){"MISSING_TRANSLATION"!==e.code&&console.error(e)},[]);return(0,se.jsx)(Bl.A,{locale:o,messages:b,onError:x,children:(0,se.jsx)(Ol,{value:s||v,children:d})})}var Zl=l(2348),Wl=l(95),ql=l(2005),_l=(l(7331),l(6123),l(3144),l(9208)),Gl=l(7784),Yl=l(7614),Ul=l(3106),Ql=l(2240),Xl=l(7014),Jl=l(951),Kl=l(3953),ea=l(4724),ta=l(4089),la=l(3568),aa=l(33),na=l(8524),ia=l(4609),oa=l(7558),ra={};function sa(e){var t,l=e.children,a=(e.isHtml,e.values),n=void 0===a?ra:a,o=Wl.A;return t=l,S()(t)&&void 0!==t.defaultMessage?(0,se.jsx)(o,(0,i.A)({values:n},l)):l}var ua={container:"micromag-core-buttons-button-container",icon:"micromag-core-buttons-button-icon",label:"micromag-core-buttons-button-label",withoutStyle:"micromag-core-buttons-button-withoutStyle",asLink:"micromag-core-buttons-button-asLink",withIcon:"micromag-core-buttons-button-withIcon",right:"micromag-core-buttons-button-right",withIconColumns:"micromag-core-buttons-button-withIconColumns",linkDisabled:"micromag-core-buttons-button-linkDisabled"},da=["type","theme","size","href","external","direct","target","label","children","focusable","active","icon","iconPosition","disabled","loading","disableOnLoading","small","big","withShadow","withoutStyle","withoutBootstrapStyles","withoutTheme","asLink","outline","onClick","className","iconClassName","labelClassName","refButton"];function ca(e){var t,l=e.type,a=void 0===l?"button":l,n=e.theme,o=void 0===n?null:n,s=e.size,u=void 0===s?null:s,d=e.href,c=void 0===d?null:d,m=e.external,g=void 0!==m&&m,y=e.direct,f=void 0!==y&&y,p=e.target,b=void 0===p?"_blank":p,x=e.label,A=void 0===x?null:x,S=e.children,C=void 0===S?null:S,w=e.focusable,k=void 0===w||w,j=e.active,M=void 0!==j&&j,N=e.icon,F=void 0===N?null:N,T=e.iconPosition,R=void 0===T?"inline":T,z=e.disabled,$=void 0!==z&&z,L=e.loading,I=void 0!==L&&L,P=e.disableOnLoading,B=void 0===P||P,E=e.small,V=void 0!==E&&E,D=e.big,O=void 0!==D&&D,H=e.withShadow,Z=void 0!==H&&H,W=e.withoutStyle,q=void 0!==W&&W,_=e.withoutBootstrapStyles,G=void 0!==_&&_,Y=e.withoutTheme,U=void 0!==Y&&Y,Q=e.asLink,X=void 0!==Q&&Q,J=e.outline,K=void 0!==J&&J,ee=e.onClick,te=void 0===ee?null:ee,le=e.className,ae=void 0===le?null:le,ne=e.iconClassName,ie=void 0===ne?null:ne,oe=e.labelClassName,re=void 0===oe?null:oe,ue=e.refButton,de=void 0===ue?null:ue,ce=(0,r.A)(e,da),me=A||C,ve=null!==me?(0,se.jsx)(sa,{children:me}):null,ge=null!==A&&null!==C,ye=null!==F,he=ye&&("inline"===R||null===ve),fe=ye&&!he,pe=(0,se.jsxs)(se.Fragment,{children:[he?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("span",{className:Kt()([ua.icon,ie]),children:F}),null!==ve?(0,se.jsx)("span",{className:Kt()([ua.label,re]),children:ve}):null]}):null,fe?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("span",{className:Kt()([ua.left,"left"===R?ie:null]),children:"left"===R?F:null}),(0,se.jsx)("span",{className:Kt()([ua.center,re]),children:ve}),(0,se.jsx)("span",{className:Kt()([ua.right,"right"===R?ie:null]),children:"right"===R?F:null}),ge?C:null]}):null,ye?null:ve,ge?C:null]}),be=!U&&!q&&!X,xe=Kt()([G?null:(0,h.A)((0,h.A)((0,h.A)({btn:be},"btn-".concat(K?"outline-":"").concat(o),be&&null!==o),"btn-".concat(u),be&&null!==u),"active",!q&&M),ua.container,(t={},(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)(t,ua.withoutStyle,q),ua.withIcon,ye),ua.withIconColumns,fe),ua.withText,null!==ve),ua.withShadow,Z),ua.isSmall,V),ua.isBig,O),ua.isLink,null!==c),ua.asLink,X),ua.isDisabled,$),(0,h.A)(t,ua.isLoading,I)),ae]);if(null!==c){var Ae=Kt()([xe,(0,h.A)({disabled:$},ua.linkDisabled,$)]);return g||f?(0,se.jsx)("a",(0,i.A)((0,i.A)({},ce),{},{href:$?null:c,className:Ae,onClick:te,target:g?b:null,ref:de,tabIndex:k?"":"-1",children:pe})):(0,se.jsx)(v.N_,{href:c,className:Ae,onClick:te,ref:de,tabIndex:k?"":"-1",children:pe})}return(0,se.jsx)("button",(0,i.A)((0,i.A)({},ce),{},{type:a,className:xe,onClick:te,disabled:$||B&&I,ref:de,tabIndex:k?"0":"-1",children:pe}))}function ma(e){var t=e.animated,l=void 0===t||t,a=e.color,n=void 0===a?"currentColor":a,i=e.strokeWidth,o=void 0===i?3:i,r=e.className,s=void 0===r?null:r;return(0,se.jsx)("svg",{className:Kt()(["micromag-core-partials-spinner-container",s,(0,h.A)({},"micromag-core-partials-spinner-animated",l)]),width:"40",height:"40",viewBox:"0 0 40 40",xmlns:"http://www.w3.org/2000/svg",children:(0,se.jsx)("circle",{className:"micromag-core-partials-spinner-path",cx:"20",cy:"20",r:"12",fill:"none",stroke:n,strokeWidth:o})})}function va(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{width:"20",height:"14",viewBox:"0 0 20 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:(0,se.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.353 0.371014L19.319 6.33704C19.6851 6.70314 19.6851 7.29671 19.319 7.66282L13.353 13.6288C12.9869 13.9949 12.3933 13.9949 12.0272 13.6288C11.6611 13.2627 11.6611 12.6692 12.0272 12.3031L16.3929 7.9374H0V6.06246H16.3929L12.0272 1.6968C11.6611 1.33069 11.6611 0.737119 12.0272 0.371014C12.3933 0.0049094 12.9869 0.0049094 13.353 0.371014Z",fill:l})})}function ga(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsxs)("svg",{width:"22",height:"22",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:[(0,se.jsx)("path",{d:"M1 1L21 21",stroke:l,strokeWidth:"1.5",strokeLinecap:"round"}),(0,se.jsx)("path",{d:"M1 21L21 0.999998",stroke:l,strokeWidth:"1.5",strokeLinecap:"round"})]})}function ya(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{width:"16",height:"14",viewBox:"0 0 16 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:(0,se.jsx)("path",{d:"M11.2 0H16V4.66667H14.4V1.55556H11.2V0ZM0 0H4.8V1.55556H1.6V4.66667H0V0ZM14.4 12.4444V9.33333H16V14H11.2V12.4444H14.4ZM1.6 12.4444H4.8V14H0V9.33333H1.6V12.4444Z",fill:l})})}function ha(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsxs)("svg",{width:"26",height:"26",viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:[(0,se.jsx)("path",{d:"M7.09929 8.77987H1C0.447715 8.77987 0 9.22758 0 9.77987V15.7799C0 16.3322 0.447715 16.7799 1 16.7799H7.1076C7.35984 16.7799 7.60276 16.8752 7.78768 17.0467L14.3199 23.1062C14.9599 23.6999 16 23.246 16 22.3731V3.00199C16 2.12221 14.9458 1.67117 14.3095 2.2787L7.78983 8.50316C7.6038 8.68077 7.35649 8.77987 7.09929 8.77987Z",fill:l}),(0,se.jsx)("path",{d:"M18 18.6875C21.3137 18.6875 24 16.0012 24 12.6875C24 9.37379 21.3137 6.6875 18 6.6875",stroke:l}),(0,se.jsx)("path",{d:"M18 15.6875C19.6569 15.6875 21 14.3444 21 12.6875C21 11.0306 19.6569 9.6875 18 9.6875",stroke:l})]})}function fa(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsxs)("svg",{className:n,width:"14",height:"18",viewBox:"0 0 14 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,se.jsx)("rect",{width:"6",height:"18",rx:"2",fill:l}),(0,se.jsx)("rect",{x:"8",width:"6",height:"18",rx:"2",fill:l})]})}function pa(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{width:"40",height:"45.1",viewBox:"0 0 40 45.1",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:(0,se.jsx)("path",{d:"M38.2,25.7L5.5,44.6C3,46,0,44.2,0,41.4L0,3.6c0-2.8,3-4.5,5.5-3.1l32.7,18.9C40.6,20.8,40.6,24.3,38.2,25.7z",fill:l,stroke:l})})}function ba(e){var t=e.color,l=void 0===t?"#fff":t,a=e.className,n=void 0===a?null:a;return(0,se.jsxs)("svg",{width:"26",height:"26",viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n,children:[(0,se.jsx)("path",{d:"M7.09929 8.77987H1C0.447715 8.77987 0 9.22758 0 9.77987V15.7799C0 16.3322 0.447715 16.7799 1 16.7799H7.1076C7.35984 16.7799 7.60276 16.8752 7.78768 17.0467L14.3199 23.1062C14.9599 23.6999 16 23.246 16 22.3731V3.00199C16 2.12221 14.9458 1.67117 14.3095 2.2787L7.78983 8.50316C7.6038 8.68077 7.35649 8.77987 7.09929 8.77987Z",fill:l}),(0,se.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M20.8536 13.3946L23 15.5411L23.7071 14.834L21.5607 12.6875L23.7071 10.5411L23 9.83398L20.8536 11.9804L18.7071 9.83398L18 10.5411L20.1464 12.6875L18 14.834L18.7071 15.5411L20.8536 13.3946Z",fill:l})]})}(0,ue.YK)({previous:{id:"menus.pagination.previous",defaultMessage:[{type:0,value:"Previous"}]},next:{id:"menus.pagination.next",defaultMessage:[{type:0,value:"next"}]}});"WithModals(".concat(Fe(function(e){var t=e.modals,l=e.setModalsContainer,n=e.className,i=void 0===n?null:n,o=(0,a.useRef)(null);return(0,a.useEffect)(function(){l(o.current)},[]),(0,se.jsx)("div",{className:Kt()(["micromag-core-modals-container",i]),children:(0,se.jsx)("div",{className:Kt()(["micromag-core-modals-modals",(0,h.A)({},"micromag-core-modals-hasModals",t.length>0)]),ref:o})})}),")");var xa={container:"micromag-core-panels-container"},Aa=[];function Sa(e){var t=e.stroke,l=void 0===t?"currentColor":t,a=e.border,n=void 0===a?"rgba(0,0,0,0.67)":a,i=e.fill,o=void 0===i?"#fff":i,r=e.className,s=void 0===r?null:r;return(0,se.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"42.9",height:"42.9",viewBox:"0 0 42.9 42.9",className:s,children:(0,se.jsxs)("g",{transform:"translate(-352.531 -47.531)",children:[n?(0,se.jsx)("path",{fill:n,d:"M374,47.5c11.9,0,21.5,9.6,21.5,21.5s-9.6,21.5-21.5,21.5s-21.5-9.6-21.5-21.5c0,0,0,0,0,0 C352.5,57.1,362.1,47.5,374,47.5z"}):null,(0,se.jsx)("path",{fill:o,d:"M374,50c10.5,0,19,8.5,19,19s-8.5,19-19,19s-19-8.5-19-19S363.5,50,374,50z"}),(0,se.jsx)("g",{transform:"translate(366.893 61.893)",children:(0,se.jsxs)("g",{transform:"translate(0 0)",children:[(0,se.jsx)("path",{fill:o,stroke:l,strokeWidth:"2",strokeLinecap:"round",d:"M14.2,0.3L0,13.9"}),(0,se.jsx)("path",{fill:o,stroke:l,strokeWidth:"2",strokeLinecap:"round",d:"M0.3,0l13.7,14.2"})]})})]})})}!function(e){"WithPanels(".concat(Fe(e),")")}(function(e){var t=e.panels,l=void 0===t?Aa:t,n=e.setPanelsContainer,i=void 0===n?null:n,o=e.className,r=void 0===o?null:o,s=(0,a.useRef)(null);return(0,a.useEffect)(function(){i(s.current)},[]),(0,se.jsx)("div",{className:Kt()([xa.container,r]),children:(0,se.jsx)("div",{className:Kt()([xa.panels,(0,h.A)({},xa.hasPanels,l.length>0)]),ref:s})})});function Ca(e){var t=e.width,l=void 0===t?"100%":t,a=e.height,n=void 0===a?"3em":a,i=e.outline,o=void 0!==i&&i,r=e.className,s=void 0===r?null:r,u=e.boxClassName,d=void 0===u?null:u,c=e.withInvertedColors,m=void 0===c||c,v=e.children,g=void 0===v?null:v;return(0,se.jsx)("div",{className:Kt()(["micromag-core-partials-placeholder-block-container",s,(0,h.A)((0,h.A)({},"micromag-core-partials-placeholder-block-outline",o),"micromag-core-partials-placeholder-block-withInvertedColors",m)]),children:(0,se.jsx)("div",{className:Kt()(["micromag-core-partials-placeholder-block-box",d]),style:{width:l,height:n},children:g})})}var wa={container:"micromag-core-partials-empty-container",middle:"micromag-core-partials-empty-middle",withoutBorder:"micromag-core-partials-empty-withoutBorder"};function ka(e){var t=e.children,l=void 0===t?null:t,a=e.withoutBorder,n=void 0!==a&&a,i=e.light,o=void 0!==i&&i,r=e.className,s=void 0===r?null:r;return(0,se.jsx)("div",{className:Kt()([wa.container,s,(0,h.A)((0,h.A)({},wa.withoutBorder,n),wa.light,o)]),children:(0,se.jsx)("div",{className:wa.middle,children:(0,se.jsx)(sa,{children:l})})})}var ja=[],Ma=["eot","woff2","woff",{name:"otf",format:"opentype"},{name:"ttf",format:"truetype"},"svg"],Na=function(e,t){var l=(e||{}).files,a=void 0===l?{}:l,n=(a||{}).original,i=void 0===n?null:n,r=i||{},s=r.name,u=void 0===s?null:s,d=r.mime,c=void 0===d?null:d;return t.reduce(function(e,t){var l=S()(t)?t.format:t,n=S()(t)?t.name:t,r=a["webfonts.".concat(n)]||a[n]||null;if(null!==r)return[].concat((0,o.A)(e),['url("'.concat(r.url,'?") format("').concat(l,'")')]);var s=new RegExp(".".concat(n,"$"),"i"),d=new RegExp("".concat(l),"i");return null!==u&&null!==u.match(s)||null!==c&&null!==c.match(d)?[].concat((0,o.A)(e),['url("'.concat(i.url,'?") format("').concat(l,'")')]):e},[])};function Fa(e){var t=e.fonts,l=void 0===t?ja:t,a=e.formats,n=void 0===a?Ma:a,o=(l||[]).filter(function(e){return S()(e)&&"custom"===e.type&&null!==(e.media||null)}).reduce(function(e,t){var l=t.name,a=void 0===l?null:l,o=t.media,r=void 0===o?null:o,s=t.variants,u=void 0===s?[]:s;if(null===a)return e;var d=null!==r?Na(r,n):null,c=a.toLowerCase();return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},c,null!==d&&d.length>0?'\n @font-face {\n font-family: "'.concat(a,'";\n src: ').concat(d.join(","),";\n }\n "):null),u.reduce(function(e,t){var l=t.weight,o=t.style,r=t.media,s=void 0===r?null:r;if(null==s)return e;var u=Na(s,n),d="".concat(c,"-").concat(null!==l?l:"normal","-").concat(null!==o?o:"normal");return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},d,null!==u&&u.length>0?'\n @font-face {\n font-family: "'.concat(a,'";\n ').concat(null!==l?"font-weight: ".concat(l,";"):"","\n ").concat(null!==o?"font-style: ".concat(o,";"):"","\n src: ").concat(u.join(","),";\n }\n "):null))},{}))},{});return Object.keys(o).length>0?(0,se.jsx)("style",{type:"text/css",dangerouslySetInnerHTML:{__html:Object.keys(o).map(function(e){return o[e]}).filter(function(e){return null!==e}).join("\n")}}):null}function Ta(e){var t=e.title,l=void 0===t?null:t,a=e.url,n=void 0===a?null:a,i=e.metadata,o=void 0===i?null:i,r=e.fullTitle,s=void 0===r?null:r,u=e.suffix,d=void 0===u?"Micromag":u,c=e.children,m=void 0===c?null:c,v=o||{},g=v.canonical,h=void 0===g?null:g,f=v.description,p=void 0===f?null:f,b=v.keywords,A=void 0===b?null:b,S=v.image,C=void 0===S?null:S,w=v.favicon,k=void 0===w?null:w,j=v.rssUrl,M=void 0===j?null:j,N=v.atomUrl,F=void 0===N?null:N,T=v.microformats,R=void 0===T?null:T,z=v.language,$=void 0===z?null:z,L=null!==l?"".concat(l," | ").concat(d):s,I=C||{},P=I.url,B=void 0===P?null:P,E=I.metadata,V=(void 0===E?null:E)||{},D=V.width,O=void 0===D?null:D,H=V.height,Z=void 0===H?null:H,W=(k||{}).url,q=void 0===W?null:W;return(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("title",{children:null!==L&&L.length>0?L:"Micromag"}),null!==p?(0,se.jsx)("meta",{name:"description",content:p}):null,null!==$?(0,se.jsx)("meta",{name:"language",content:$}):null,null!==A&&y()(A)?(0,se.jsx)("meta",{name:"keywords",content:A}):null,null!==A&&x()(A)?(0,se.jsx)("meta",{name:"keywords",content:A.join(",")}):null,null!==h?(0,se.jsx)("link",{rel:"canonical",href:h}):null,null!==q?(0,se.jsx)("link",{rel:"icon",type:"image/png",href:q}):null,null!==M?(0,se.jsx)("link",{rel:"alternate",type:"application/rss+xml",href:M}):null,null!==F?(0,se.jsx)("link",{rel:"alternate",type:"application/atom+xml",href:F}):null,null!==B?(0,se.jsx)("meta",{property:"og:image",content:B}):null,null!==B?(0,se.jsx)("meta",{property:"og:image:url",content:B}):null,null!==O?(0,se.jsx)("meta",{property:"og:image:width",content:O}):null,null!==Z?(0,se.jsx)("meta",{property:"og:image:height",content:Z}):null,null!==L?(0,se.jsx)("meta",{property:"og:title",content:L}):null,null!==p?(0,se.jsx)("meta",{property:"og:description",content:p}):null,null!==n?(0,se.jsx)("meta",{property:"og:url",content:n}):null,(0,se.jsx)("meta",{name:"twitter:card",content:null!==B?"summary_large_image":"summary"}),null!==L?(0,se.jsx)("meta",{name:"twitter:title",content:L}):null,null!==p?(0,se.jsx)("meta",{name:"twitter:description",content:p}):null,null!==B?(0,se.jsx)("meta",{name:"twitter:image",content:B}):null,(R||[]).map(function(e){return(0,se.jsx)("script",{type:"application/ld+json",id:"".concat(e["@type"],"-").concat(e.identifier),async:!0,children:JSON.stringify(e)},"microformat-".concat(e["@type"],"-").concat(e.identifier))}),m]})}var Ra={icon:"micromag-core-placeholders-icon"};function za(e){var t=e.lines,l=void 0===t?1:t,a=e.lineMargin,n=void 0===a?1:a,i=e.width,r=void 0===i?"100%":i,s=e.height,u=void 0===s?null:s,d=e.fontSize,c=void 0===d?16:d,m=e.className,v=void 0===m?null:m,g=e.withInvertedColors,y=void 0===g||g,f=null!==u&&me()(u)?"".concat(Math.round(u*c),"px"):u,p=me()(r)?.9*r:"80%";return(0,se.jsx)("div",{className:Kt()(["micromag-core-partials-placeholder-text-container",v,(0,h.A)({},"micromag-core-partials-placeholder-text-withInvertedColors",y)]),children:(0,o.A)(Array(l)).map(function(e,t){return(0,se.jsx)("div",{className:"micromag-core-partials-placeholder-text-line",style:{width:t%2==0?r:p,height:f,marginTop:n,marginBottom:n}},"line-".concat(t))})})}var $a=["width","height","className"];function La(e){var t=e.width,l=e.height,a=e.className,n=(0,r.A)(e,$a);return(0,se.jsx)(Ca,(0,i.A)((0,i.A)({},n),{},{width:t,height:l,className:a,children:(0,se.jsx)(ql.gc,{icon:Gl.jb,className:Ra.icon})}))}var Ia="micromag-core-placeholders-map-icon";function Pa(e){return(0,se.jsxs)(Ca,(0,i.A)((0,i.A)({},e),{},{width:"100%",height:"100%",className:Kt()(["micromag-core-placeholders-map-container",(0,h.A)({},e.className,null!==e.className)]),children:[(0,se.jsx)(ql.gc,{icon:e.withImages?Gl.jb:Ul.Pc,className:Ia}),(0,se.jsx)(ql.gc,{icon:e.withImages?Gl.jb:Ul.Pc,className:Ia}),(0,se.jsx)(ql.gc,{icon:e.withImages?Gl.jb:Ul.Pc,className:Ia}),(0,se.jsx)(ql.gc,{icon:e.withImages?Gl.jb:Ul.Pc,className:Ia})]}))}function Ba(e){return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.subtitle]),height:.3,lines:1}))}function Ea(e){var t=e.className,l=void 0===t?null:t,a=e.height,n=void 0===a?.2:a,o=e.lines,r=void 0===o?4:o,s=e.lineMargin,u=void 0===s?2:s;return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{height:n,lines:r,lineMargin:u,className:Kt()([l,Ra.text])}))}function Va(e){var t=e.height,l=void 0===t?.5:t,a=e.lines,n=void 0===a?2:a,o=e.lineMargin,r=void 0===o?2:o;return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.title]),height:l,lines:n,lineMargin:r}))}function Da(e){var t=e.width,l=e.height,a=e.className;return(0,se.jsx)(Ca,{width:t,height:l,className:a,children:(0,se.jsx)(ql.gc,{icon:Xl.n2,className:Ra.icon})})}function Oa(e){var t=e.width,l=e.height,a=e.className;return(0,se.jsxs)(Ca,{width:t,height:l,className:Kt()(["micromag-core-placeholders-video-360-container",a]),boxClassName:"micromag-core-placeholders-video-360-box",children:[(0,se.jsx)(ql.gc,{icon:Xl.n2,className:"micromag-core-placeholders-video-360-icon"}),(0,se.jsx)("div",{className:"micromag-core-placeholders-video-360-label",children:"360"})]})}function Ha(e){var t=e.width,l=void 0===t?null:t,n=e.height,i=void 0===n?null:n,o=e.fit,r=void 0===o?null:o,s=e.screenWidth,u=void 0===s?320:s,d=e.screenHeight,c=void 0===d?480:d,m=e.className,v=void 0===m?null:m,g=e.children,y=null!==l||null!==i,h=pl(),f=h.ref,p=h.width,b=void 0===p?0:p,x=h.height,A=void 0===x?0:x,S=(0,a.useMemo)(function(){var e=l||b||null,t=i||A||null;if(null===e&&null===t)return{};var a=u/c,n=y?l||t*a:e,o=y&&i||e/a;if(null===r){var s=n/u;return{width:n,height:o,scale:s,transform:"scale(".concat(s,")")}}var d=(0,ia.kL)(u,c,n,o,{cover:"cover"===r}),m=d.width,v=d.height,g=d.scale,h=(n-m)/2,f=(o-v)/2;return{width:n,height:o,scale:g,transform:"scale(".concat(g,") translate(").concat(h,"px, ").concat(f,"px)")}},[u,c,l,i,r,b,A,y]),C=S.width,w=void 0===C?null:C,k=S.height,j=void 0===k?null:k,M=S.scale,N=void 0===M?null:M,F=S.transform,T=void 0===F?null:F,R=Fl(),z=(0,a.useMemo)(function(){return{screen:"mobile",screens:["mobile"],width:u,height:c,resolution:null!==N?N*R:R}},[u,c,N]),$=null!==w&&null!==j;return(0,se.jsx)("div",{className:Kt()(["micromag-core-screens-screen-sizer-container",v]),ref:y?null:f,children:$?(0,se.jsx)("div",{className:"micromag-core-screens-screen-sizer-frame",style:{width:w,height:j},children:(0,se.jsx)("div",{className:"micromag-core-screens-screen-sizer-screen",style:{width:u,height:c,transform:T},children:(0,se.jsx)(Pt,{size:z,children:a.cloneElement(g,{width:u,height:c})})})}):null})}function Za(e){var t=e.screen,l=e.renderContext,n=void 0===l?null:l,o=e.screenState,r=void 0===o?null:o,s=e.index,u=void 0===s?null:s,d=e.active,c=void 0===d||d,m=e.current,v=void 0!==m&&m,g=e.preload,h=void 0===g||g,f=e.components,p=void 0===f?null:f,b=e.component,x=void 0===b?null:b,A=e.className,S=void 0===A?null:A,C=e.mediaRef,w=void 0===C?null:C,k=(t||{}).type,j=void 0===k?null:k,M=null!==p&&je(j,p)||null,N=function(e){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,l=at(arguments.length>2&&void 0!==arguments[2]?arguments[2]:null);return(0,a.useMemo)(function(){return y()(e)?l.getComponent(e)||t:e||t},[l,e,t])}(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,et)}(j),F=M||N;return(0,se.jsx)($t,{data:t,renderContext:n,screenState:r,children:null!==F?(0,se.jsx)("div",{className:Kt()(["micromag-core-screens-screen-container",S]),children:(0,se.jsx)(F,(0,i.A)((0,i.A)({},t),{},{index:u,active:c,current:v,preload:h,mediaRef:w}))}):(0,se.jsx)("div",{className:S,children:x})})}var Wa=["screen","screenState","width","height","screenWidth","screenHeight","className","withSize","fit","hidden"];function qa(e){var t=e.screen,l=e.screenState,a=void 0===l?null:l,n=e.width,o=void 0===n?void 0:n,s=e.height,u=void 0===s?void 0:s,d=e.screenWidth,c=void 0===d?void 0:d,m=e.screenHeight,v=void 0===m?void 0:m,g=e.className,y=void 0===g?null:g,f=e.withSize,p=void 0!==f&&f,b=e.fit,x=e.hidden,A=void 0!==x&&x,S=(0,r.A)(e,Wa),C=(0,se.jsx)(Za,(0,i.A)({screen:t,renderContext:"preview",screenState:a,width:p?void 0:o,height:p?void 0:u,className:Kt()(["micromag-core-screens-preview-screen",(0,h.A)({},y,!p)])},S)),w=A?(0,se.jsx)("div",{}):C;return p?(0,se.jsx)(Ha,{className:y,screenWidth:c,screenHeight:v,width:o,height:u,fit:b,children:w}):w}var _a={container:"micromag-core-placeholders-conversation-container",icon:"micromag-core-placeholders-conversation-icon",message:"micromag-core-placeholders-conversation-message",placeholderMessage0:"micromag-core-placeholders-conversation-placeholderMessage0",placeholderMessage1:"micromag-core-placeholders-conversation-placeholderMessage1",placeholderMessage2:"micromag-core-placeholders-conversation-placeholderMessage2",placeholderMessage3:"micromag-core-placeholders-conversation-placeholderMessage3"},Ga="micromag-core-placeholders-share-options-icon",Ya="micromag-core-placeholders-share-options-item",Ua=Object.freeze({__proto__:null,AdFrame:function(e){var t=e.width,l=e.height,a=e.className;return(0,se.jsx)(Ca,{width:t,height:l,className:a,children:(0,se.jsx)(ql.gc,{icon:_l.HX,className:Ra.icon})})},AdImage:function(e){var t=e.width,l=e.height,a=e.className;return(0,se.jsx)(Ca,{width:t,height:l,className:a,children:(0,se.jsx)(ql.gc,{icon:Gl.jb,className:Ra.icon})})},Audio:function(e){var t=e.width,l=void 0===t?"100%":t,a=e.height,n=void 0===a?"2em":a,i=e.className;return(0,se.jsx)(Ca,{width:l,height:n,className:i,children:(0,se.jsx)(ql.gc,{icon:Yl.X,className:Ra.icon})})},Button:function(e){var t=e.width,l=void 0===t?"75%":t,a=e.height,n=void 0===a?"0.4em":a,i=e.className;return(0,se.jsx)(Ca,{outline:!0,width:l,height:n,className:i,children:(0,se.jsx)(za,{line:1,height:"0.1em"})})},Conversation:function(){return(0,se.jsxs)("div",{className:_a.container,children:[(0,o.A)(Array(4)).map(function(e,t){return(0,se.jsx)("div",{className:Kt()([_a.message,_a["placeholderMessage".concat(t)]])},"message-".concat(t+1))}),(0,se.jsx)(ql.gc,{icon:ea.Be,className:_a.icon})]})},Image:La,InputText:function(e){var t=e.width,l=void 0===t?"75%":t,a=e.height,n=void 0===a?"0.5em":a,i=e.className;return(0,se.jsx)(Ca,{outline:!0,width:l,height:n,className:i})},Line:function(e){return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.shortText]),height:.2,lines:1}))},Map:Pa,MapPath:function(e){return(0,se.jsx)(Ca,(0,i.A)((0,i.A)({},e),{},{width:"100%",height:"70%",className:Kt()([e.className,Ra.mapPath]),children:(0,se.jsx)(ql.gc,{icon:Ql.Bg,size:"lg",className:Ra.icon})}))},QuizAnswer:function(e){var t=e.width,l=void 0===t?"75%":t,a=e.height,n=void 0===a?"0.3em":a,i=e.className,o=e.good,r=void 0===o||o;return(0,se.jsxs)("div",{className:Kt()(["micromag-core-placeholders-quiz-answer-container",i,(0,h.A)({},"micromag-core-placeholders-quiz-answer-good",r)]),children:[(0,se.jsx)("div",{className:"micromag-core-placeholders-quiz-answer-answer",children:(0,se.jsx)(ql.gc,{className:"micromag-core-placeholders-quiz-answer-answerIcon",icon:r?ta.e6:la.GR})}),(0,se.jsx)(Ca,{outline:!0,width:l,height:n,className:"micromag-core-placeholders-quiz-answer-block",children:(0,se.jsx)(za,{line:1,height:"0.2em"})})]})},Quote:function(e){return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.subtitle]),height:.5,lines:6}))},ShareOptions:function(e){return(0,se.jsxs)(Ca,(0,i.A)((0,i.A)({},e),{},{width:"100%",height:"100%",className:Kt()(["micromag-core-placeholders-share-options-container",(0,h.A)({},e.className,null!==e.className)]),boxClassName:"micromag-core-placeholders-share-options-box",children:[(0,se.jsx)("div",{className:Ya,children:(0,se.jsx)(ql.gc,{icon:aa.GE,className:Ga})}),(0,se.jsx)("div",{className:Ya,children:(0,se.jsx)(ql.gc,{icon:aa.GE,className:Ga})}),(0,se.jsx)("div",{className:Ya,children:(0,se.jsx)(ql.gc,{icon:aa.GE,className:Ga})})]}))},ShortText:function(e){return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.shortText]),height:.2,lines:2}))},Subtitle:Ba,SurveyAnswer:function(e){var t=e.width,l=void 0===t?"75%":t,a=e.height,n=void 0===a?"0.3em":a,i=e.className;return(0,se.jsxs)("div",{className:Kt()(["micromag-core-placeholders-survey-answer-container",i]),children:[(0,se.jsx)(Ca,{outline:!0,width:l,height:n,className:"micromag-core-placeholders-survey-answer-block",children:(0,se.jsx)(za,{line:1,height:"0.2em"})}),(0,se.jsx)("div",{className:"micromag-core-placeholders-survey-answer-percent",children:(0,se.jsx)(ql.gc,{className:"micromag-core-placeholders-survey-answer-percentIcon",icon:na.Bi})})]})},Text:Ea,Timeline:function(e){return(0,se.jsx)(za,(0,i.A)((0,i.A)({},e),{},{className:Kt()([e.className,Ra.timeline])}))},Title:Va,Video:Da,Video360:Oa,VideoLoop:function(e){var t=e.width,l=e.height,a=e.className;return(0,se.jsxs)(Ca,{width:t,height:l,className:a,children:[(0,se.jsx)(ql.gc,{icon:Jl.ij,className:Ra.icon}),(0,se.jsx)(ql.gc,{icon:Kl.ye,className:Ra.icon})]})}});function Qa(e){var t=e.children,l=void 0===t?null:t,a=e.placeholder,n=void 0===a?null:a,o=e.empty,r=void 0===o?null:o,s=e.emptyLabel,u=void 0===s?null:s,d=e.preview,c=void 0===d?null:d,m=e.isEmpty,v=void 0!==m&&m,g=e.placeholderProps,h=void 0===g?null:g,f=e.emptyClassName,p=void 0===f?null:f,b=Rt(),x=b.isPlaceholder,A=b.isEdit,S=b.isPreview;if(x){var C=y()(n)?je(n,Ua):null;return null!==C?(0,se.jsx)(C,(0,i.A)({},h)):n}return A&&v?null!==r?r:(0,se.jsx)(ka,{className:p,children:u}):S&&null!==c?c:l}function Xa(e){var t=e.fullscreen,l=void 0!==t&&t,n=e.from,o=void 0===n?null:n,r=e.to,s=void 0===r?null:r,u=e.playing,d=void 0!==u&&u,c=e.direction,m=void 0===c?null:c,v=e.delay,g=void 0===v?0:v,y=e.reversible,f=void 0===y||y,p=e.duration,b=void 0===p?void 0:p,x=e.easing,A=void 0===x?void 0:x,S=e.config,C=void 0===S?null:S,w=e.children,k=void 0===w?null:w,j=e.className,M=void 0===j?null:j,N=e.onStart,F=void 0===N?null:N,T=e.onComplete,z=void 0===T?null:T,$=(0,Qt.U2)(),L=(0,Qt.zh)(function(){return{ref:$}}),I=(0,R.A)(L,2),P=I[0],B=I[1];return(0,a.useEffect)(function(){var e=!d&&"in"===m||d&&"out"===m,t=e||d,l=f&&d&&!e,a=null!==b?b:void 0,n=g>0&&d&&"out"!==m,i=null!==A&&oa.$W[A]?oa.$W[A]||null:C,r={from:t?o:s,to:t?s:o,immediate:e,delay:n?g:null,reset:l,onStart:F,onRest:z,config:null!==i?i:{duration:e?0:a}};(t||f)&&B.start(r)},[d,m,g,b,f,A,C,o,s,B,F,z]),(0,se.jsx)(oa.CS.div,{style:(0,i.A)({},P),className:Kt()(["micromag-core-transitions-transition-container",M,(0,h.A)({},"micromag-core-transitions-transition-fullscreen",l)]),children:k})}var Ja={Fade:function(e){var t=(0,a.useMemo)(function(){return{opacity:0}},[]),l=(0,a.useMemo)(function(){return{opacity:1}},[]);return(0,se.jsx)(Xa,(0,i.A)((0,i.A)({},e),{},{from:t,to:l}))},Scale:function(e){var t=(0,a.useMemo)(function(){return{transform:"scale(0)"}},[]),l=(0,a.useMemo)(function(){return{transform:"scale(1)"}},[]);return(0,se.jsx)(Xa,(0,i.A)((0,i.A)({},e),{},{from:t,to:l}))}};function Ka(e){var t=e.fullscreen,l=void 0!==t&&t,a=e.playing,n=void 0!==a&&a,o=e.delay,r=void 0===o?0:o,s=e.transitions,u=void 0===s?null:s,d=e.onComplete,c=void 0===d?null:d,m=e.disabled,v=void 0!==m&&m,g=e.children,y=void 0===g?null:g,h=It().landscape,f=n||void 0===h||h,p={in:null,out:null},b=null!==u?u:{in:"fade",out:"fade"};Object.keys(b).forEach(function(e){var t=b[e];p[e]="string"==typeof t?{name:t}:t});var x=p.in,A=void 0===x?null:x,S=p.out,C=void 0===S?null:S,w=null!==A?A:C,k=null!==C?C:A,j=(w||{}).name,M=void 0===j?null:j,N=(k||{}).name,F=void 0===N?null:N,T=M===F,R=null!==w?je(M,Ja,null):null,z=null===k||T?null:je(F,Ja,null),$=null!==w?(0,i.A)((0,i.A)({},w),{},{name:void 0,delay:r,onComplete:c}):null,L=null!==k?(0,i.A)((0,i.A)({},k),{},{name:void 0,delay:r,onComplete:c}):null,I=null===z||v?y:(0,se.jsx)(z,(0,i.A)((0,i.A)({fullscreen:l,playing:f,direction:"out"},L),{},{children:y}));return null===R||v?I:(0,se.jsx)(R,(0,i.A)((0,i.A)({fullscreen:l,playing:f,direction:T?null:"in"},$),{},{children:I}))}function en(e){var t=e.selector,l=void 0===t?null:t,a=e.highlightSelector,n=void 0===a?"mark":a,i=e.style,o=void 0===i?null:i;return null!==o?(0,se.jsx)("style",{type:"text/css",dangerouslySetInnerHTML:{__html:"".concat([l,n].filter(function(e){return null!==e}).join(" "),"{").concat(he(o),"}")}}):null}function tn(e){var t=e.selector,l=void 0===t?null:t,a=e.linkSelector,n=void 0===a?"a":a,i=e.style,o=void 0===i?null:i;return null!==o?(0,se.jsx)("style",{type:"text/css",dangerouslySetInnerHTML:{__html:"".concat([l,n].filter(function(e){return null!==e}).join(" "),"{").concat(he(o),"}")}}):null}var ln="micromag-element-link-container";function an(e){var t=e.url,l=void 0===t?null:t,n=e.target,o=void 0===n?null:n,r=e.rel,s=void 0===r?null:r,u=e.external,d=void 0===u||u,c=e.margin,m=void 0===c?null:c,v=e.className,g=void 0===v?null:v,y=e.children,h=void 0===y?null:y,f=e.focusable,p=void 0===f||f,b=null;null!==m&&(b=(0,i.A)((0,i.A)({},b),Ze(m)));var x=(0,a.useId)(),A=null!==b?"link-component-".concat(x):null,S=d?{target:"_blank",rel:"noopener noreferer"}:{target:o,rel:s},C=S.target,w=S.rel;return l?(0,se.jsx)("a",{id:A,className:Jt([ln,g]),style:b,href:l,target:C,rel:w,tabIndex:p?"0":"-1",children:h}):(0,se.jsx)("div",{id:A,className:Jt([ln,g]),style:b,children:h})}function nn(e){var t=e.body,l=void 0===t?null:t,n=e.textStyle,o=void 0===n?null:n,r=e.boxStyle,s=void 0===r?null:r,u=e.linksStyle,d=void 0===u?null:u,c=e.margin,m=void 0===c?null:c,v=e.lineClamp,g=void 0===v?null:v,y=e.showEmpty,f=void 0!==y&&y,p=e.className,b=void 0===p?null:p,x=e.emptyClassName,A=void 0===x?null:x,S=e.inline,C=void 0!==S&&S,w=e.refText,k=void 0===w?null:w,j=o||{},M=j.link,N=void 0===M?null:M,F=j.highlight,T=void 0===F?null:F,R={},z=null!==N?Oe(N):null,$=null!==T?De(T):null;null!==o&&(R=(0,i.A)((0,i.A)({},R),He(o))),null!==s&&(R=(0,i.A)((0,i.A)({},R),Ve(s))),null!==g&&(R.WebkitLineClamp=g),null!==m&&(R=(0,i.A)((0,i.A)({},R),Ze(m))),null!==d&&(z=(0,i.A)((0,i.A)({},z),He(d)));var L=null!==z||null!==T,I=(0,a.useId)(),P=L?"text-component-".concat(I):null,B={id:P,className:Jt(["micromag-element-text-container",b,(0,h.A)((0,h.A)((0,h.A)({},"micromag-element-text-withLineClamp",null!==g),"micromag-element-text-showEmpty",f),A,f&&null!==A)]),style:R,dangerouslySetInnerHTML:{__html:l},ref:k},E="".concat(C?"span":"div");return(0,se.jsxs)(se.Fragment,{children:[null!==z?(0,se.jsx)(tn,{selector:"#".concat(we(P)),style:z}):null,null!==$?(0,se.jsx)(en,{selector:"#".concat(we(P)),style:$}):null,(0,se.jsx)(E,(0,i.A)({},B))]})}var on={container:"micromag-element-author-avatar-container",shape:"micromag-element-author-avatar-shape",shapeCircle:"micromag-element-author-avatar-shapeCircle"};function rn(e){var t=e.image,l=void 0===t?null:t,a=e.width,n=void 0===a?100:a,i=e.height,o=void 0===i?100:i,r=e.resolution,s=void 0===r?1:r,u=e.shape,d=void 0===u?"circle":u,c=e.isTag,m=void 0!==c&&c,v=e.className,g=void 0===v?null:v,y=e.shouldLoad,f=void 0===y||y,p=yt("supportsWebp",!1),b=yt("imageResolution",s),x=Pe(l,n,o,{resolution:b,supportsWebp:p}),A=null!==d?(0,M.fL)(d):null;return(0,se.jsx)("span",{className:Jt([on.container,(0,h.A)((0,h.A)({className:g},on["shape".concat(A)],null!==A),on.isTag,m)]),children:(0,se.jsx)("span",{className:on.shape,style:{backgroundImage:f?'url("'.concat(x,'")'):null}})})}var sn=["author","withImage","withoutLink","linkUnderlineColor","className","backgroundClassName","collaboratorClassName","shouldLoad"];function un(e){var t=e.author,l=void 0===t?null:t,a=e.withImage,n=void 0===a||a,o=e.withoutLink,s=void 0!==o&&o,u=e.linkUnderlineColor,d=void 0===u?null:u,c=e.className,m=void 0===c?null:c,v=e.backgroundClassName,g=void 0===v?null:v,y=e.collaboratorClassName,h=void 0===y?null:y,f=e.shouldLoad,p=void 0===f||f,b=(0,r.A)(e,sn),x=l||{},A=x.name,S=void 0===A?null:A,C=x.image,w=void 0===C?null:C,k=x.url,j=void 0===k?null:k,M=x.collaborator,N=void 0===M?null:M,F=n&&null!==w,T=Je(S)?(0,se.jsx)(nn,(0,i.A)({className:Jt(["micromag-element-author-name",g])},S)):null,R=Je(N)?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:"micromag-element-author-collaboratorText"},N),{},{inline:!0})):null;return(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:Jt(["micromag-element-author-container",m])},b),{},{children:[F?(0,se.jsx)(rn,{className:"micromag-element-author-image",image:w,shouldLoad:p}):null,(0,se.jsxs)("div",{className:"micromag-element-author-right",children:[null===j||s?(0,se.jsx)("div",{children:T}):(0,se.jsx)(an,{className:"micromag-element-author-link",url:j,external:!0,style:{backgroundImage:null!==d?"linear-gradient(0deg, ".concat(d," 0, ").concat(d,")"):null},children:T}),null!==R?(0,se.jsx)("div",{className:Jt(["micromag-element-author-collaborator",h]),children:null!==R?R:null}):null]})]}))}var dn=l(3655),cn="micromag-element-video-media",mn=["ref"];function vn(e){var t=e.media,l=void 0===t?null:t,n=e.thumbnail,i=void 0===n?null:n,o=e.width,r=void 0===o?null:o,s=e.height,u=void 0===s?null:s,d=e.mediaRef,c=void 0===d?null:d,m=e.muted,v=void 0!==m&&m,g=e.autoPlay,y=void 0!==g&&g,f=e.paused,p=void 0!==f&&f,b=e.loop,x=void 0!==b&&b,A=e.playsInline,S=void 0===A||A,C=e.preload,w=void 0===C?"auto":C,k=e.shouldLoad,j=void 0===k||k,M=e.withoutCors,N=void 0!==M&&M,F=e.className,T=void 0===F?null:F,z=e.innerClassName,$=void 0===z?null:z,L=e.onReady,I=void 0===L?null:L,P=e.onPlay,B=void 0===P?null:P,E=e.onPause,V=void 0===E?null:E,D=e.onEnded,O=void 0===D?null:D,H=e.onSeeked,Z=void 0===H?null:H,W=e.onTimeUpdate,q=void 0===W?null:W,_=e.onProgressStep,G=void 0===_?null:_,Y=e.onDurationChange,U=void 0===Y?null:Y,Q=e.onVolumeChange,X=void 0===Q?null:Q,J=e.onSuspend,K=void 0===J?null:J,ee=e.onSuspended,te=void 0===ee?null:ee,le=e.onPlayError,ae=void 0===le?null:le,ne=e.focusable,ie=void 0===ne||ne,oe=e.withPoster,re=void 0!==oe&&oe,ue=e.withLoading,de=void 0!==ue&&ue,ce=e.disablePictureInPicture,me=void 0===ce||ce,ve=l||{},ge=ve.url,ye=void 0===ge?null:ge,he=ve.metadata,fe=(void 0===he?null:he)||{},pe=fe.description,be=void 0===pe?null:pe,xe=fe.has_audio,Ae=void 0===xe?null:xe,Se=jl(l,i),Ce=function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).possibleMimes,l=void 0===t?null:t,n=e||{},i=n.files,o=void 0===i?null:i,r=n.metadata,s=((void 0===r?null:r)||{}).mime,u=void 0===s?null:s,d=yt("supportedVideoMimes"),c=l||d||["video/mp4"],m=(0,a.useMemo)(function(){return Ie(o)},[o]),v=(0,a.useState)(c),g=(0,R.A)(v,2),y=g[0],h=g[1];(0,a.useEffect)(function(){var e=_e(c);0===e.length&&(e=["video/mp4"]),h(e)},[c]);var f=(0,a.useMemo)(function(){if(0===m.length)return null;var e=m.filter(function(e){var t=e.handle||e.id,l=e.mime,a=void 0===l?"video/".concat("h264"===t?"mp4":t):l;return-1!==y.indexOf(a)}),t=e.filter(function(e){return"original"!==(e.handle||e.id)});return(t.length>0?t:e).sort(function(e,t){var l=e.size,a=void 0===l?1/0:l,n=t.size,i=void 0===n?1/0:n;return a===i?0:a>i?1:-1})},[m,y]),p=m.find(function(e){return"original"===e.handle})||{},b=p.type,x=void 0===b?null:b,A=p.mime,S=void 0===A?u:A,C="image"===x||null!==S&&0===S.indexOf("image/");return{sources:null!==f&&f.length>0?f:null,files:m,isImage:C}}(l),we=Ce.sources,ke=Ce.isImage&&(null===we||0===we.length),je=(0,a.useRef)(null),Me=Sl(je.current,{id:ye,disabled:p||null===G}),Ne=Cl(je.current,{id:ye}),Fe=(0,a.useState)(!1),Te=(0,R.A)(Fe,2),Re=Te[0],ze=Te[1],$e=kl(je.current,{id:ye});(0,a.useEffect)(function(){var e=null;return ze(!1),ye&&de&&(e=setTimeout(function(){ze(!0)},2e3)),function(){clearTimeout(e)}},[ye,de]);var Le=null!==r&&null!==u;(0,a.useEffect)(function(){Ne>0&&null!==U&&U(Ne)},[Ne,U]);var Pe=(0,a.useCallback)(function(){var e=je.current,t=void 0===e?null:e;null!==t&&null!==X&&X(t.volume)},[X]),Be=(0,a.useState)(!1),Ee=(0,R.A)(Be,2),Ve=Ee[0],De=Ee[1],Oe=(0,a.useCallback)(function(e){Ve&&De(!1),null!==B&&B(e)},[Ve,De,B]),He=(0,a.useCallback)(function(){Ve&&De(!1)},[Ve,De]),Ze=(0,a.useCallback)(function(e){!e.currentTarget.paused||p||Ve||(De(!0),null!==te&&te()),null!==K&&K(e)},[Ve,p,De,K,te]);(0,a.useEffect)(function(){$e&&null!==I&&I()},[$e,I]);var We=j?w:"none";return(0,a.useEffect)(function(){var e=je.current,t=void 0===e?null:e;if(null!==t&&null!==ye){var l=t.paused;p&&!l?t.pause():!p&&l&&t.play().catch(function(e){null!==ae&&ae(e)})}},[p,l,ye,ae]),Ml({currentTime:Me,duration:Ne,disabled:p,onStep:G}),(0,se.jsxs)("div",{className:Jt(["micromag-element-video-container",(0,h.A)({},"micromag-element-video-withSize",Le),T]),style:Le?{width:r,height:u}:null,children:[ke&&j?(0,se.jsx)("img",{src:ye,alt:be,tabIndex:"-1",className:Jt([cn,$])}):null,ke?null:(0,se.jsx)("video",{ref:function(e){je.current=e,null!==c&&dn(c)?c(e):null!==c&&(c.current=e)},src:null===we&&j?"".concat(ye,"#t=0.001"):null,autoPlay:y&&!p,loop:x,muted:v,poster:j&&re&&null!==Se&&Se.url||null,preload:We,playsInline:S,crossOrigin:N?"anonymous":null,disablePictureInPicture:me,tabIndex:ie?"0":"-1",className:Jt([cn,$]),onPlay:Oe,onPlaying:He,onPause:V,onEnded:O,onSeeked:Z,onVolumeChange:Pe,onTimeUpdate:q,onSuspend:Ze,"data-has-audio":Ae,"data-is-suspended":Ve,"aria-hidden":!0,children:(j&&null!==we?we:[]).map(function(e){var t=e.url,l=e.mime;return(0,se.jsx)("source",{src:null!==t?"".concat(t,"#t=0.001"):null,type:l},"source-".concat(t,"-").concat(l))})},ye),ke||$e||!Re?null:(0,se.jsx)(ma,{className:"micromag-element-video-spinner"})]})}var gn=function(e){var t=e.ref,l=(0,r.A)(e,mn);return(0,se.jsx)(vn,(0,i.A)({mediaRef:t},l))},yn={container:"micromag-element-background-container",videoContainer:"micromag-element-background-videoContainer",video:"micromag-element-background-video",layers:"micromag-element-background-layers",layer:"micromag-element-background-layer",right:"micromag-element-background-right",background:"micromag-element-background-background",bottom:"micromag-element-background-bottom"};function hn(e){var t=e.width,l=void 0===t?null:t,n=e.height,o=void 0===n?null:n,r=e.resolution,s=void 0===r?1:r,u=e.fit,d=void 0===u?null:u,c=e.horizontalAlign,m=void 0===c?"center":c,v=e.verticalAlign,g=void 0===v?"center":v,y=e.repeat,h=void 0!==y&&y,f=e.color,p=void 0===f?null:f,b=e.media,x=void 0===b?null:b,A=e.mediaRef,S=void 0===A?null:A,C=e.className,w=void 0===C?null:C,k=e.playing,j=void 0!==k&&k,M=e.muted,N=void 0!==M&&M,F=e.children,T=void 0===F?null:F,R=e.loadingMode,z=void 0===R?"lazy":R,$=e.shouldLoad,L=void 0===$||$,I=e.onPlayError,P=void 0===I?null:I,B=e.withoutVideo,E=void 0!==B&&B,V=e.forceMuted,D=void 0!==V&&V,O=e.qualityStartLevel,H=void 0===O?null:O,Z=e.onQualityLevelChange,W=void 0===Z?null:Z,q=x||{},_=q.type,G=void 0===_?null:_,Y=q.metadata,U=void 0===Y?null:Y,Q=q.thumbnail_url,X=U||{},J=X.width,K=void 0===J?0:J,ee=X.height,te=void 0===ee?0:ee,le="video"===G,ae="image"===G,ne=L||"lazy"!==z,ie=(0,a.useRef)(ne);ne&&!ie.current&&(ie.current=ne);var oe=ie.current,re=(0,i.A)({width:l,height:o},Ee(p)),ue=yt("supportsWebp",!1),de=yt("imageResolution",s);if(null!==x&&(ae||le&&(!L||E))){var ce=Pe(le?{url:Q}:x,l,o,{resolution:de,supportsWebp:ue});re.backgroundImage=null!==ce&&oe?'url("'.concat(ce,'")'):null,re.backgroundRepeat=h&&!le?"repeat":"no-repeat",re.backgroundPosition=[m,g].join(" "),null!==d?re.backgroundSize=d:h&&!le||(re.backgroundSize="cover")}var me={};if(le&&L)if(l>0&&o>0){var ve=(0,ia.kL)(K,te,l,o,{cover:"cover"===d||null===d}),ge=ve.width,ye=void 0===ge?0:ge,he=ve.height,fe=void 0===he?0:he;me.width=ye,me.height=fe,me.left=-(ye-l)/2,me.top=-(fe-o)/2}else me.objectFit="cover";return(0,se.jsxs)("div",{className:Jt([yn.container,w]),style:re,children:[le&&L&&!E?(0,se.jsx)("div",{className:yn.videoContainer,style:me,children:(0,se.jsx)(gn,{className:yn.video,media:x,mediaRef:D?null:S,paused:!j,muted:N||D,shouldLoad:L,onPlayError:P,disablePictureInPicture:!0,autoPlay:!0,loop:!0,withPoster:!0,focusable:!1,qualityStartLevel:H,onQualityLevelChange:W})}):null,(0,se.jsx)("div",{className:yn.content,children:T})]})}var fn=["horizontalAlign","verticalAlign"];function pn(e){var t=e.width,l=void 0===t?null:t,n=e.height,s=void 0===n?null:n,u=e.resolution,d=void 0===u?1:u,c=e.background,m=void 0===c?null:c,v=e.playing,g=void 0!==v&&v,y=e.muted,f=void 0!==y&&y,p=e.children,b=void 0===p?null:p,A=e.className,S=void 0===A?null:A,C=e.layerClassName,w=void 0===C?null:C,k=e.backgroundClassName,j=void 0===k?null:k,M=e.loadingMode,N=void 0===M?"lazy":M,F=e.mediaRef,T=void 0===F?null:F,R=e.shouldLoad,z=void 0===R||R,$=e.withoutVideo,L=void 0!==$&&$,I=e.onPlayError,P=void 0===I?null:I,B=e.qualityStartLevel,E=void 0===B?null:B,V=e.onQualityLevelChange,D=void 0===V?null:V,O=null!==l&&null!==s&&l>0&&s>0,H=(0,a.useMemo)(function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null===e?[]:(x()(e)?e:[e]).reduce(function(e,t){var l=t.image,a=void 0===l?null:l,n=t.video,s=void 0===n?null:n,u=t.media,d=void 0===u?null:u,c=t.color,m=void 0===c?null:c,v=(0,r.A)(t,Le);return null===a&&null===s&&null===m?e:[].concat((0,o.A)(e),null!==a&&null!==s?[(0,i.A)({media:a},v),(0,i.A)({media:s,color:m},v)]:[(0,i.A)({media:d||a||s,color:m},v)])},[])}(m)},[m]),Z=H.length;if(0===H.length)return null;var W=(0,i.A)({},O?{width:l,height:s}:null);return(0,se.jsxs)("div",{className:Jt([yn.container,S]),style:W,children:[(0,se.jsx)("div",{className:yn.layers,children:H.map(function(e,t){var a=e.horizontalAlign,n=void 0===a?void 0:a,o=e.verticalAlign,u=void 0===o?void 0:o,c=(0,r.A)(e,fn);return(0,se.jsx)("div",{className:Jt([yn.layer,w,(0,h.A)((0,h.A)({},yn.bottom,"bottom"===u),yn.right,"right"===n)]),style:{zIndex:Z-t},children:(0,se.jsx)(hn,(0,i.A)({width:l,height:s,resolution:d,className:Jt([yn.background,j]),playing:g,muted:f,horizontalAlign:n,verticalAlign:u,loadingMode:N,shouldLoad:z,mediaRef:T,withoutVideo:L,onPlayError:P,qualityStartLevel:E,onQualityLevelChange:D},c))},"background-".concat(t))})}),(0,se.jsx)("div",{className:yn.content,children:b})]})}var bn=["ref"];function xn(e){var t=e.containerRef,l=void 0===t?null:t,a=e.width,n=e.height,o=e.style,r=void 0===o?null:o,s=e.className,u=void 0===s?null:s,d=e.children,c=void 0===d?null:d,m=a>0&&n>0?(0,i.A)({width:a,height:n},r):r;return(0,se.jsx)("div",{ref:l,className:Jt(["micromag-element-container-container",u]),style:m,children:c})}var An=function(e){var t=e.ref,l=(0,r.A)(e,bn);return(0,se.jsx)(xn,(0,i.A)({containerRef:t},l))},Sn=["ref"],Cn={};function wn(e){var t=e.media,l=void 0===t?null:t,n=e.alt,o=void 0===n?null:n,r=e.width,s=void 0===r?null:r,u=e.height,d=void 0===u?null:u,c=e.resolution,m=void 0===c?1:c,v=e.objectFit,g=void 0===v?null:v,y=e.containerStyle,h=void 0===y?Cn:y,f=e.imageStyle,p=void 0===f?Cn:f,b=e.className,x=void 0===b?null:b,A=e.imageClassName,S=void 0===A?null:A,C=e.onLoaded,w=void 0===C?null:C,k=e.loadingMode,j=void 0===k?"lazy":k,M=e.shouldLoad,N=void 0===M||M,F=e.containerRef,T=void 0===F?null:F,z=(l||{}).metadata,$=(void 0===z?null:z)||{},L=$.width,I=void 0===L?0:L,P=$.height,B=void 0===P?0:P,E=$.description,V=void 0===E?"image":E,D=I/B,O=(0,a.useState)({width:I,height:B}),H=(0,R.A)(O,2),Z=H[0],W=Z.width,q=void 0===W?0:W,_=Z.height,G=void 0===_?0:_,Y=H[1],U=yt("supportsWebp",!1),Q=yt("imageResolution",m),X=(0,a.useRef)(N);N&&!X.current&&(X.current=N);var J,K,ee=X.current,te=(0,a.useCallback)(function(e){var t=e.target,l=t.naturalWidth,a=void 0===l?0:l,n=t.naturalHeight,i=void 0===n?0:n;a===q&&i===G||Y({width:a||0,height:i||0}),null!==w&&w(e)},[w]),le=q>0&&G>0;if(null!==g){var ae=0,ne=0,ie=s,oe=d,re=null,ue=null,de=g||{},ce=de.fit,me=void 0===ce?null:ce,ve=de.horizontalPosition,ge=void 0===ve?"center":ve,ye=de.verticalPosition,he=void 0===ye?"center":ye;if(le){var fe=(0,ia.kL)(q,G,s,d,{cover:"cover"===me}),pe=fe.width,be=fe.height;ie=pe,oe=be,"center"===ge?ne=-(pe-s)/2:"right"===ge&&(ne=-(pe-s)),"center"===he?ae=-(be-d)/2:"bottom"===he&&(ae=-(be-d))}else re=me,ue="".concat(ge," ").concat(he);J={width:s,height:d},K={position:"absolute",width:ie,height:oe,top:ae,left:ne,objectFit:re,objectPosition:ue}}else{var xe=null!==d&&"number"==typeof d,Ae=null!==s?s:D&&xe?d*D:null,Se=null!==d?d:D&&null!==s&&"number"==typeof s?s/D:null;null===Ae&&null===Se&&(Ae=q>0?I:null,Se=G>0?B:null),J={width:Ae,height:Se},K={width:"100%",height:xe?"100%":"auto"}}J=(0,i.A)((0,i.A)({},J),h);var Ce=K=(0,i.A)((0,i.A)({},K),p),we=Ce.width,ke=void 0===we?null:we,je=Ce.height,Me=Pe(l,ke,(void 0===je?null:je)||ke,{resolution:Q,supportsWebp:U});return(0,se.jsx)("div",{className:Jt(["micromag-element-image-container",x]),style:J,ref:T,children:null!==Me&&ee?(0,se.jsx)("img",{src:Me,alt:o||V,className:Jt(["micromag-element-image-img",S]),style:K,onLoad:te,loading:j}):null})}var kn=function(e){var t=e.ref,l=(0,r.A)(e,Sn);return(0,se.jsx)(wn,(0,i.A)({containerRef:t},l))},jn="micromag-element-visual-container",Mn=["media","mediaRef","width","height","ratio","resolution","objectFit","playing","muted","loadingMode","shouldLoad","videoLoop","videoInitialMuted","onLoaded","className","imageClassName","videoClassName","withoutVideo","qualityStartLevel","onQualityLevelChange"];function Nn(e){var t=e.media,l=void 0===t?null:t,n=e.mediaRef,o=void 0===n?null:n,s=e.width,u=void 0===s?null:s,d=e.height,c=void 0===d?null:d,m=e.ratio,v=void 0===m?null:m,g=e.resolution,y=void 0===g?1:g,f=e.objectFit,p=void 0===f?null:f,b=e.playing,x=void 0===b||b,A=e.muted,S=void 0===A||A,C=e.loadingMode,w=void 0===C?null:C,k=e.shouldLoad,j=void 0===k||k,M=e.videoLoop,N=void 0===M||M;e.videoInitialMuted;var F=e.onLoaded,T=void 0===F?null:F,R=e.className,z=void 0===R?null:R,$=e.imageClassName,L=void 0===$?null:$,I=e.videoClassName,P=void 0===I?null:I,B=e.withoutVideo,E=void 0!==B&&B,V=e.qualityStartLevel,D=void 0===V?null:V,O=e.onQualityLevelChange,H=void 0===O?null:O,Z=(0,r.A)(e,Mn),W=l||{},q=W.type,_=void 0===q?null:q,G=W.thumbnail_url,Y=void 0===G?null:G,U=W.url,Q=void 0===U?null:U,X="video"===_,J=(0,a.useMemo)(function(){return(0,i.A)((0,i.A)({},Z),{},{media:l})},[Z,l]),K="lazy"===w,ee=bl({rootMargin:"200px",persist:!0,disabled:!K}),te=ee.ref,le=ee.visible,ae=(!K||le)&&j,ne=(0,a.useMemo)(function(){var e=j&&!E||!X?J:(0,i.A)((0,i.A)({},J),{},{media:{url:Y}});return j&&!E?(0,i.A)((0,i.A)({},J),{},{media:(0,i.A)((0,i.A)({},l),{},{url:Q})}):e},[X,J,Y,Q,j]),ie=null;if("video"===_&&null!==p&&j){var oe=(p||{}).fit,re=void 0===oe?"cover":oe,ue=(l||{}).metadata,de=(void 0===ue?null:ue)||{},ce=de.width,me=void 0===ce?0:ce,ve=de.height,ge=void 0===ve?0:ve,ye=(0,ia.kL)(me,ge,u,c,{cover:"cover"===re}),he=ye.width,fe=ye.height;ie={width:he,height:fe,left:-(he-u)/2,top:-(fe-c)/2}}var pe=null===p,be=(0,a.useCallback)(function(e){null!==T&&T(e)},[]);return null!==_?(0,se.jsxs)(se.Fragment,{children:["image"===_||!j||E?(0,se.jsx)(kn,(0,i.A)((0,i.A)({},ne),{},{ref:te,loadingMode:"lazy"!==w?"lazy":null,objectFit:p,width:u,height:c,resolution:y,shouldLoad:ae,onLoaded:be,className:Jt([jn,z]),imageClassName:L})):null,"video"===_&&j&&!E?(0,se.jsx)("div",{className:Jt([jn,z,(0,h.A)({},"micromag-element-visual-natural",pe)]),style:{width:u,height:c,aspectRatio:null!==v?"".concat(v):null},ref:te,children:(0,se.jsxs)("div",{className:Jt(["micromag-element-visual-videoContainer",P]),style:ie,children:[(0,se.jsx)(gn,(0,i.A)((0,i.A)({},J),{},{innerClassName:"micromag-element-visual-videoTag",mediaRef:o,width:null===p?u:null,height:null===p?c:null,paused:!x,muted:S,loop:N,shouldLoad:ae,onReady:be,autoPlay:!0,qualityStartLevel:D,onQualityLevelChange:H})),(0,se.jsx)("div",{className:"micromag-element-visual-videoTouchOverlay"})]})}):null]}):null}var Fn={container:"micromag-element-button-container",rich:"micromag-element-button-rich",layoutLabelBottom:"micromag-element-button-layoutLabelBottom",layoutLabelTop:"micromag-element-button-layoutLabelTop",layoutNoLabel:"micromag-element-button-layoutNoLabel",layoutLabelLeft:"micromag-element-button-layoutLabelLeft",layoutLabelRight:"micromag-element-button-layoutLabelRight",layoutLabelOver:"micromag-element-button-layoutLabelOver",text:"micromag-element-button-text",textFullWidth:"micromag-element-button-textFullWidth",emptyButton:"micromag-element-button-emptyButton",visual:"micromag-element-button-visual",video:"micromag-element-button-video"},Tn=["textStyle","buttonStyle","type","disabled","focusable","inline","onClick","children","className","withoutExternalBorder","refButton","style"],Rn=["body"];function zn(e){var t=e.textStyle,l=void 0===t?null:t,a=e.buttonStyle,n=void 0===a?null:a,o=e.type,s=void 0===o?"button":o,u=e.disabled,d=void 0!==u&&u,c=e.focusable,m=void 0===c||c,v=e.inline,g=void 0!==v&&v,y=e.onClick,h=void 0===y?null:y,f=e.children,p=void 0===f?null:f,b=e.className,x=void 0===b?null:b,A=e.withoutExternalBorder,S=void 0===A||A,C=e.refButton,w=void 0===C?null:C,k=e.style,j=void 0===k?null:k,M=(0,r.A)(e,Tn)||{};M.body;var N=(0,r.A)(M,Rn);if(null!==l&&(j=(0,i.A)((0,i.A)({},j),He(l))),null!==n&&(j=(0,i.A)((0,i.A)((0,i.A)({},j),Ve(n)),{},{display:S&&g?"inline-block":null})),!S){var F=(j||{}).borderWidth,T=void 0===F?null:F,R=null!==T&&T>0?"-1px":null;j=(0,i.A)((0,i.A)({},j),{},{display:g?"inline-block":null},null!==R?{margin:R}:null)}return(0,se.jsx)(ca,(0,i.A)((0,i.A)({className:Jt([Fn.container,x]),disabled:d,style:j,onClick:h,refButton:w,type:s,focusable:m,withoutBootstrapStyles:!0},N),{},{children:p}))}var $n=["label","visual","visualWidth","labelBoxStyle","textStyle","buttonStyle","resolution","shouldLoad","layout","type","disabled","focusable","inline","onClick","className","textClassName","visualClassName","imageClassName","videoClassName","withoutExternalBorder","refButton","children"];function Ln(e){var t=e.label,l=void 0===t?null:t,n=e.visual,o=void 0===n?null:n,s=e.visualWidth,u=void 0===s?null:s,d=e.labelBoxStyle,c=void 0===d?null:d,m=e.textStyle,v=void 0===m?null:m,g=e.buttonStyle,y=void 0===g?null:g,f=e.resolution,p=void 0===f?null:f,b=e.shouldLoad,x=void 0===b||b,A=e.layout,S=void 0===A?"label-bottom":A,C=e.type,w=void 0===C?"button":C,k=e.disabled,j=void 0!==k&&k,M=e.focusable,N=void 0===M||M,F=e.inline,T=void 0!==F&&F,R=e.onClick,z=void 0===R?null:R,$=e.className,L=void 0===$?null:$,I=e.textClassName,P=void 0===I?null:I,B=e.visualClassName,E=void 0===B?null:B,V=e.imageClassName,D=void 0===V?null:V,O=e.videoClassName,H=void 0===O?null:O,Z=e.withoutExternalBorder,W=void 0===Z||Z,q=e.refButton,_=void 0===q?null:q,G=e.children,Y=void 0===G?null:G,U=(0,r.A)(e,$n),Q=(0,a.useMemo)(function(){switch(w){case"submit":case"button":return zn;default:return"div"}},[w]),X=(o||{}).url,J=null!==(void 0===X?null:X),K=(l||{}).body,ee=void 0===K?null:K,te=null!==ee&&""!==ee.trim(),le="no-label"!==S,ae=("label-left"===S||"label-right"===S)&&te&&J?"30%":"100%",ne=J?S:null;return(0,se.jsx)(Q,(0,i.A)((0,i.A)({type:w,buttonStyle:y,disabled:j,focusable:N,inline:T,onClick:z,className:Jt([Fn.container,Fn.rich,L,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Fn.layoutLabelBottom,"label-bottom"===ne),Fn.layoutLabelTop,"label-top"===ne),Fn.layoutNoLabel,"no-label"===ne),Fn.layoutLabelOver,"label-over"===ne),Fn.layoutLabelLeft,"label-left"===ne),Fn.layoutLabelRight,"label-right"===ne),Fn.textFullWidth,te&&(!J||"label-right"!==S&&"label-left"!==S))]),withoutExternalBorder:W,refButton:_},U),{},{children:(0,se.jsxs)(Qa,{placeholder:"button",emptyLabel:(0,se.jsx)(Wl.A,{id:"bv3rRe",defaultMessage:[{type:0,value:"Button"}]}),emptyClassName:Fn.emptyButton,isEmpty:!J&&!te,children:[J?(0,se.jsx)(Nn,{media:o,width:u||ae,resolution:p,shouldLoad:x,className:Jt([Fn.visual,E]),imageClassName:Jt([Fn.image,D]),videoClassName:Jt([Fn.video,H])}):null,te&&le?(0,se.jsx)(nn,{boxStyle:c,textStyle:v,body:ee,className:Jt([Fn.text,P])}):null,Y]})}))}function In(e){var t=e.color,l=void 0===t?"currentColor":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0",y:"0px",width:"48.53px",height:"12.38px",viewBox:"0 0 48.53 12.38",className:n,xmlSpace:"preserve",children:(0,se.jsx)("g",{transform:"matrix(1, 0, 0, 1, 0, 0)",children:(0,se.jsx)("path",{id:"b",fill:"none",stroke:l,strokeWidth:"3px",strokeLinejoin:"round",strokeLinecap:"round",d:"M1.5,10.88L24.26,1.5l22.77,9.38"})})})}var Pn={container:"micromag-element-call-to-action-container",arrow:"micromag-element-call-to-action-arrow",button:"micromag-element-call-to-action-button",withoutLinkStyle:"micromag-element-call-to-action-withoutLinkStyle",label:"micromag-element-call-to-action-label",icon:"micromag-element-call-to-action-icon",text:"micromag-element-call-to-action-text",selfTargetLink:"micromag-element-call-to-action-selfTargetLink",leavingFrame:"micromag-element-call-to-action-leavingFrame",animationDisabled:"micromag-element-call-to-action-animationDisabled",invalidUrl:"micromag-element-call-to-action-invalidUrl"},Bn=["ref"];function En(e){var t=e.type,l=void 0===t?null:t,n=e.url,o=void 0===n?null:n,r=e.label,s=void 0===r?null:r,u=e.boxStyle,d=void 0===u?null:u,c=e.inWebView,m=void 0!==c&&c,v=e.elRef,y=void 0===v?null:v,f=e.disabled,p=void 0!==f&&f,b=e.animationDisabled,x=void 0!==b&&b,A=e.icon,S=void 0===A?null:A,C=e.arrow,w=void 0===C?null:C,k=e.dragAmount,j=void 0===k?50:k,M=e.className,N=void 0===M?null:M,F=e.buttonClassName,T=void 0===F?null:F,z=e.buttonBorderClassName,$=void 0===z?null:z,L=e.labelClassName,I=void 0===L?null:L,P=e.arrowClassName,B=void 0===P?null:P,E=e.focusable,V=void 0===E||E,D=e.external,O=void 0===D||D,H=e.openWebView,Z=void 0===H?null:H,W=e.onClick,q=void 0===W?null:W,_=Il(),G=null===l||"swipe-up"===l,Y=(0,a.useMemo)(function(){return Ke(o)},[o]),U=(0,a.useRef)(null),Q=(s||{}).textStyle,X=void 0===Q?null:Q,J=X||{},K=J.fontSize,ee=void 0===K?null:K,te=J.color,le=void 0===te?null:te,ae=J.lineHeight,ne=void 0===ae?null:ae,ie=(d||{}).backgroundColor,oe=void 0===ie?null:ie,re=(0,a.useMemo)(function(){return(0,i.A)((0,i.A)({},{fontSize:ee}),Ee(null===oe?le:oe,"color"))},[ee,oe,le]),ue=(0,a.useRef)(null),de=(0,a.useState)(!1),ce=(0,R.A)(de,2),me=ce[0],ve=ce[1],ge=(0,a.useState)(!1),ye=(0,R.A)(ge,2),he=ye[0],fe=ye[1],pe=(0,a.useCallback)(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"click";fe(!he),m&&null!==Z&&Z({url:o}),null!==q&&"click"===t&&q(e),null!==_&&_("call_to_action",g(t)?t:"click",o)},[he,o,q,_,m,Z]),be=(0,a.useCallback)(function(e){e.event.preventDefault()},[]),xe=(0,a.useCallback)(function(e){(0,R.A)(e.movement,2)[1]<-j&&(m?pe(null,"swipe"):Ue()&&null!==ue.current?(ue.current.click(),ve(!0),pe(null,"swipe")):U.current&&(U.current.click(),pe(null,"swipe")))},[j,m,pe,ve]),Ae=(0,Xt.useGesture)({onDrag:be,onDragEnd:xe});return(0,a.useEffect)(function(){var e=function(){ve(!1)};return window.addEventListener("pagehide",e),function(){window.removeEventListener("pagehide",e)}},[ve]),(0,se.jsxs)("div",{className:Jt([Pn.container,N,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Pn.disabled,p),Pn.animationDisabled,x),Pn.invalidUrl,!Y),Pn.inWebView,m)]),ref:y,children:[me?(0,se.jsx)("div",{className:Pn.leavingFrame}):null,!m&&G?(0,se.jsx)("a",{className:Pn.selfTargetLink,href:o,ref:ue,tabIndex:V?"0":"-1"}):null,G?(0,se.jsx)("div",{className:Jt([Pn.arrow,B]),style:re,children:w||(0,se.jsx)(In,{})}):null,(0,se.jsx)("div",{className:Jt([Pn.buttonBorder,$]),children:(0,se.jsx)(zn,(0,i.A)((0,i.A)({className:Jt([Pn.button,T,(0,h.A)({},Pn.withoutLinkStyle,!m)]),refButton:U,focusable:V,buttonStyle:d,inline:!0,"aria-pressed":he,href:m?null:o,external:!m&&O,onClick:pe},G&&!p?Ae():null),{},{children:(0,se.jsxs)("span",{className:Jt([Pn.label,I]),children:[null!==S?(0,se.jsx)("div",{className:Pn.icon,children:S}):null,(0,se.jsx)(nn,(0,i.A)((0,i.A)({},s),{},{className:Pn.text,textStyle:(0,i.A)((0,i.A)({},X),{},{lineHeight:ne||1}),inline:!0}))]})}))})]})}var Vn=function(e){var t=e.ref,l=(0,r.A)(e,Bn);return(0,se.jsx)(En,(0,i.A)({elRef:t},l))};function Dn(e){var t=e.callToAction,l=void 0===t?null:t,a=e.className,n=void 0===a?null:a;return null===l?null:(0,se.jsx)("div",{className:Jt(["micromag-element-footer-container",n]),children:(0,se.jsx)(Vn,(0,i.A)({},l))})}function On(e){var t=e.label,l=void 0===t?null:t,a=e.boxStyle,n=void 0===a?null:a,o=e.className,r=void 0===o?null:o,s=e.labelClassName,u=void 0===s?null:s,d=(l||{}).textStyle,c=void 0===d?null:d,m=(c||{}).lineHeight,v=void 0===m?null:m,g=null;return null!==n&&(g=(0,i.A)((0,i.A)({},g),Ve(n))),(0,se.jsx)("div",{className:Jt(["micromag-element-badge-container",r]),style:g,children:(0,se.jsx)("span",{className:Jt(["micromag-element-badge-label",u]),children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},l),{},{textStyle:(0,i.A)((0,i.A)({},c),{},{lineHeight:v||1}),inline:!0}))})})}var Hn={container:"micromag-element-header-container",fade:"micromag-element-header-fade"};function Zn(e){var t=e.badge,l=void 0===t?null:t,a=e.fade,n=void 0!==a&&a,o=e.className,r=void 0===o?null:o;return null===l?null:(0,se.jsx)("div",{className:Jt([Hn.container,r,(0,h.A)({},Hn.fade,!0===n)]),children:null!==l?(0,se.jsx)(On,(0,i.A)({className:Hn.badge},l)):null})}var Wn=["ref"];function qn(e){var t=e.size,l=void 0===t?1:t,n=e.body,o=void 0===n?null:n,r=e.textStyle,s=void 0===r?null:r,u=e.linksStyle,d=void 0===u?null:u,c=e.margin,m=void 0===c?null:c,v=e.withoutNonBreakingSpaces,g=void 0!==v&&v,h=e.className,f=void 0===h?null:h,p=e.headingRef,b=void 0===p?null:p,x="h".concat(l),A=s||{},S=A.link,C=void 0===S?null:S,w=A.highlight,k=void 0===w?null:w,j=null,M=null!==C?Oe(C):null,N=null!==k?De(k):null;null!==s&&(j=(0,i.A)((0,i.A)({},j),He(s))),null!==m&&(j=(0,i.A)((0,i.A)({},j),Ze(m))),null!==d&&(M=(0,i.A)((0,i.A)({},M),He(d)));var F,T=null!==M||null!==k,R=(0,a.useId)(),z=T?"heading-component-".concat(R):null;return(0,se.jsxs)(se.Fragment,{children:[null!==M?(0,se.jsx)(tn,{selector:"#".concat(we(z)),style:M}):null,null!==N?(0,se.jsx)(en,{selector:"#".concat(we(z)),style:N}):null,(0,se.jsx)(x,{id:z,className:Jt(["micromag-element-heading-container",f]),style:j,dangerouslySetInnerHTML:{__html:g?o:(F=o,y()(F)?F.replace(/«\s/g,"« ").replace(/\s»/g," »").replace(/\s:\s/g," : "):F)},ref:b})]})}var _n=function(e){var t=e.ref,l=(0,r.A)(e,Wn);return(0,se.jsx)(qn,(0,i.A)({headingRef:t},l))},Gn=a.createContext({direction:"horizontal"});function Yn(e){var t=e.direction,l=void 0===t?"vertical":t,n=e.children,i=(0,a.useMemo)(function(){return{direction:l}},[l]);return(0,se.jsx)(Gn,{value:i,children:n})}function Un(e){var t=e.size,l=void 0===t?null:t,n=e.minSize,i=void 0===n?null:n,o=e.maxSize,r=void 0===o?null:o,s=e.className,u=void 0===s?null:s,d=(0,a.use)(Gn).direction;return(0,se.jsx)("div",{className:Jt(["micromag-element-stack-spacer-container",u,(0,h.A)({},"micromag-element-stack-spacer-hasSize",null!==l)]),style:{width:"horizontal"===d?l:null,minWidth:"horizontal"===d?i:null,maxWidth:"horizontal"===d?r:null,height:"vertical"===d?l:null,minHeight:"vertical"===d?i:null,maxHeight:"vertical"===d?r:null}})}Un.withoutTransitionsWrapper=!0;function Qn(e){var t=e.width,l=void 0===t?null:t,a=e.height,n=void 0===a?null:a,o=e.horizontalAlign,r=void 0===o?"left":o,s=e.verticalAlign,u=void 0===s?"top":s,d=e.distribution,c=void 0===d?null:d,m=e.fullscreen,v=void 0!==m&&m,g=e.className,y=void 0===g?null:g,f=e.children,p=void 0===f?null:f,b=e.style,x=void 0===b?null:b,A=null;null!==c?A="space-".concat(c):"middle"===u?A="center":"bottom"===u&&(A="flex-end");var S=null;"center"===r?S="center":"right"===r&&(S="flex-end");var C=(0,i.A)({width:l,height:n,justifyContent:A,alignItems:S},x);return(0,se.jsx)(Yn,{direction:"vertical",children:(0,se.jsx)("div",{className:Jt(["micromag-element-layout-container",y,(0,h.A)({},"micromag-element-layout-fullscreen",v)]),style:C,children:p})})}var Xn={container:"micromag-element-scroll-container",scrollable:"micromag-element-scroll-scrollable",arrowContainer:"micromag-element-scroll-arrowContainer",arrow:"micromag-element-scroll-arrow",upAndDown:"micromag-element-scroll-upAndDown",withScroll:"micromag-element-scroll-withScroll",withArrow:"micromag-element-scroll-withArrow",withShadow:"micromag-element-scroll-withShadow",top:"micromag-element-scroll-top",scrollee:"micromag-element-scroll-scrollee",middle:"micromag-element-scroll-middle",bottom:"micromag-element-scroll-bottom",disabled:"micromag-element-scroll-disabled"},Jn=["ref"];function Kn(e){var t=e.width,l=void 0===t?null:t,n=e.height,r=void 0===n?null:n,s=e.disabled,u=void 0!==s&&s,d=e.verticalAlign,c=void 0===d?null:d,m=e.className,v=void 0===m?null:m,g=e.scrollableClassName,y=void 0===g?null:g,f=e.scrolleeClassName,p=void 0===f?null:f,b=e.children,x=void 0===b?null:b,A=e.scrollPosition,S=void 0===A?null:A,C=e.triggers,w=void 0===C?[.1,.25,.5,.75,.9,1]:C,k=e.onScrolledTrigger,j=void 0===k?null:k,M=e.onScrolledBottom,N=void 0===M?null:M,F=e.onScrolledNotBottom,T=void 0===F?null:F,z=e.onScrollHeightChange,$=void 0===z?null:z,L=e.scrollContainerRef,I=void 0===L?null:L,P=e.withShadow,B=void 0!==P&&P,E=e.withArrow,V=void 0===E||E,D={width:l,height:r},O=(0,a.useRef)([]),H=(0,a.useState)(!1),Z=(0,R.A)(H,2),W=Z[0],q=Z[1],_=pl(),G=_.ref,Y=_.height;null!==I&&(I.current=G.current);var U=pl(),Q=U.ref,X=U.height,J=(0,a.useRef)(!1),K=(0,a.useRef)(!1),ee=(0,a.useRef)(!1),te=(0,Xt.useScroll)(function(e){var t=(0,R.A)(e.xy,2)[1],l=t<=1,a=X-Y,n=t+1>=a,i=Math.min(Math.max((t+1)/a,0),1),r=(w||[]).filter(function(e){return i>=e&&-1===O.current.indexOf(e)});r.forEach(function(e){null!=j&&j(e)}),r.length>0&&(O.current=[].concat((0,o.A)(O.current),(0,o.A)(r))),n?ee.current||(null!==N&&N({initial:!J.current}),J.current=!0):ee.current&&(null!==T&&T({initial:!K.current}),K.current=!0),l!==W&&V&&q(l),ee.current=n},{enabled:!u,threshold:10,axis:"y",filterTaps:!0});return(0,a.useEffect)(function(){if(X>0&&Y>0&&!u){q(Math.round(X)>Math.round(Y));var e=X-Y;G.current.scrollTop+1>=e?null!==N&&N({initial:!1}):null!==T&&T({initial:!1})}},[Y,X,q,u]),(0,a.useEffect)(function(){null!==$&&$({scrollableHeight:Y,scrolleeHeight:X,canScroll:(X||0)>(Y||0)})},[Y,X,$]),(0,a.useEffect)(function(){null!==G.current&&null!==S&&(G.current.scrollTop=S)},[Q,S]),(0,se.jsxs)("div",{className:Jt([Xn.container,Xn.withScroll,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Xn.disabled,u),Xn[c],null!==c&&X<Y),Xn.withArrow,V&&W),Xn.withShadow,B),"className",v)]),style:D,children:[(0,se.jsx)("div",(0,i.A)((0,i.A)({className:Jt([Xn.scrollable,y]),ref:G},te()),{},{children:(0,se.jsx)("div",{className:Jt([Xn.scrollee,p]),ref:Q,children:x})})),!u&&V?(0,se.jsx)("div",{className:Xn.arrowContainer,children:(0,se.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"10",height:"16",viewBox:"0 0 10 16",className:Xn.arrow,fill:"currentColor",children:(0,se.jsx)("polygon",{points:".38 11.38 5 16 9.62 11.38 8.56 10.32 5.75 13.13 5.75 1.61 4.25 1.61 4.25 13.13 1.44 10.32 .38 11.38"})})}):null]})}var ei=function(e){var t=e.ref,l=(0,r.A)(e,Jn);return(0,se.jsx)(Kn,(0,i.A)({scrollContainerRef:t},l))},ti={container:"micromag-screen-article-container",background:"micromag-screen-article-background",content:"micromag-screen-article-content",layout:"micromag-screen-article-layout",emptyTitle:"micromag-screen-article-emptyTitle",emptyAuthor:"micromag-screen-article-emptyAuthor",emptySubtitle:"micromag-screen-article-emptySubtitle",emptyText:"micromag-screen-article-emptyText",emptySurtitle:"micromag-screen-article-emptySurtitle",emptyDate:"micromag-screen-article-emptyDate",main:"micromag-screen-article-main",hasText:"micromag-screen-article-hasText",visualContainer:"micromag-screen-article-visualContainer",surtitle:"micromag-screen-article-surtitle",subtitle:"micromag-screen-article-subtitle",date:"micromag-screen-article-date",title:"micromag-screen-article-title",author:"micromag-screen-article-author",text:"micromag-screen-article-text",topContent:"micromag-screen-article-topContent",footer:"micromag-screen-article-footer",disabled:"micromag-screen-article-disabled",isPlaceholder:"micromag-screen-article-isPlaceholder"},li=[{id:"article",type:"screen",group:{label:(0,ue.zR)({id:"fIawTr",defaultMessage:[{type:0,value:"Text"}]}),order:2},title:(0,ue.zR)({id:"ouMwWq",defaultMessage:[{type:0,value:"Article"}]}),component:function(e){var t=e.image,l=void 0===t?null:t,n=e.title,o=void 0===n?null:n,r=e.surtitle,s=void 0===r?null:r,u=e.date,d=void 0===u?null:u,c=e.author,m=void 0===c?null:c,v=e.subtitle,g=void 0===v?null:v,y=e.text,f=void 0===y?null:y,p=e.spacing,b=void 0===p?20:p,x=e.background,A=void 0===x?null:x,S=e.header,C=void 0===S?null:S,w=e.footer,k=void 0===w?null:w,j=e.current,M=void 0===j||j,N=e.preload,F=void 0===N||N,T=e.type,z=void 0===T?null:T,$=e.className,L=void 0===$?null:$,I=(0,Zl.A)(),P=$l(z),B=It(),E=B.width,V=B.height,D=B.resolution,O=Ot(),H=O.topHeight,Z=O.bottomHeight,W=O.bottomSidesWidth,q=qt().open,_=jt().muted,G=Mt(M,!0),Y=G.ref,U=G.isCurrent,Q=void 0!==U&&U,X=pl(),J=X.ref,K=X.height,ee=Rt(),te=ee.isView,le=ee.isPreview,ae=ee.isPlaceholder,ne=ee.isEdit,ie=ee.isStatic,oe=ee.isCapture,re=M&&(te||ne)&&(Q||!te),ue=M||F,de=!ne&&(ie||oe||ae||le||ne)||!M,ce=m||{},me=ce.name,ve=void 0===me?null:me,ge=ce.image,ye=void 0===ge?null:ge,he=ce.collaborator,fe=Je(f),pe=Ge(C),be=Ye(k),xe=Je(o),Ae=Je(s),Se=Je(g),Ce=Je(m),we=Je(ve)||Qe(ye)||Je(he),ke=Qe(l),je=Je(d),Me=ze(k,{isView:te,current:M,openWebView:q,isPreview:le}),Ne=(0,a.useMemo)(function(){if(!ke)return 0;var e=(l||{}).metadata,t=(void 0===e?{}:e)||{},a=t.width,n=void 0===a?0:a,i=t.height;return E*(void 0===i?0:i)/n},[l]),Fe=je&&d.body||null,Te=(0,a.useMemo)(function(){return null!==Fe?"<p>".concat(I.formatDate(rl(Fe).toDate(),{year:"numeric",month:"long",day:"2-digit"}),"</p>"):null},[Fe]),Re=(0,se.jsx)(Qa,{placeholder:"image",emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:ti.emptyText,isEmpty:!ke,children:(0,se.jsx)("div",{ref:J,className:ti.visualContainer,children:ke?(0,se.jsx)(Nn,{media:l,width:E,height:Ne,shouldLoad:ue,resolution:D,className:ti.visual}):null})}),$e=(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:ti.emptyTitle,isEmpty:!xe,children:xe?(0,se.jsx)(_n,(0,i.A)({className:ti.title},o)):null},"title"),Le=(0,se.jsx)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"vdWMTA",defaultMessage:[{type:0,value:"Surtitle"}]}),emptyClassName:ti.emptySurtitle,isEmpty:!Ae,children:Ae?(0,se.jsx)(nn,(0,i.A)({className:ti.surtitle},s)):null},"surtitle"),Ie=(0,se.jsx)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"d60tSn",defaultMessage:[{type:0,value:"Subtitle"}]}),emptyClassName:ti.emptySubtitle,isEmpty:!Se,children:Se?(0,se.jsx)(nn,(0,i.A)({className:ti.subtitle},g)):null},"subtitle"),Pe=(0,se.jsx)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"/MsgWe",defaultMessage:[{type:0,value:"Date"}]}),emptyClassName:ti.emptyDate,isEmpty:!je,children:je?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:ti.date},d),{},{body:Te})):null},"date"),Be=(0,se.jsxs)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"xYqGzM",defaultMessage:[{type:0,value:"Author"}]}),emptyClassName:ti.emptyAuthor,isEmpty:!we&&!Ce,children:[Ce?(0,se.jsx)(nn,(0,i.A)({className:ti.author},m)):null,we?(0,se.jsx)(un,{author:m}):null]},"author"),Ee=(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"z4CiV1",defaultMessage:[{type:0,value:"Text"}]}),emptyClassName:ti.emptyText,isEmpty:!fe,children:fe?(0,se.jsx)(nn,(0,i.A)({className:ti.text},f)):null}),Ve=(0,a.useState)(!1),De=(0,R.A)(Ve,2),Oe=De[0],He=De[1],Ze=(0,a.useCallback)(function(e){e.initial&&P("scroll","Screen"),He(!0)},[P]),We=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);P("scroll",t,{scrollPercent:t})}},[P]),qe=(0,a.useCallback)(function(){He(!1)},[He]);return(0,se.jsxs)("div",{className:Jt([ti.container,L,(0,h.A)({},ti.isPlaceholder,ae)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:E,height:V,className:ti.content,children:(0,se.jsx)(ei,{disabled:de,onScrolledTrigger:We,onScrolledBottom:Ze,onScrolledNotBottom:qe,withShadow:!0,children:(0,se.jsxs)(Qn,{className:ti.layout,style:ae?null:{padding:b,paddingTop:pe?b/2+(le?0:H):b/2+K,paddingBottom:(M&&!le?Z:0)+b/2},children:[!ae&&pe?(0,se.jsx)("div",{style:{height:ke&&K>0?0:"auto",paddingBottom:K>0?K-H:b},children:(0,se.jsx)(Zn,(0,i.A)({},C))},"header"):null,(0,se.jsxs)("div",{className:Jt([ti.main,(0,h.A)({},ti.hasText,fe&&we)]),children:[Re,(0,se.jsxs)("div",{className:ti.topContent,children:[Le,Pe]}),$e,Be,Ie]}),Ee,!ae&&be?(0,se.jsx)("div",{className:Jt([ti.footer,(0,h.A)({},ti.disabled,!Oe)]),style:{paddingLeft:Math.max(W-b,0),paddingRight:Math.max(W-b,0),paddingTop:b},children:(0,se.jsx)(Dn,(0,i.A)({},Me))}):null]})})}),ae?null:(0,se.jsx)(pn,{background:A,width:E,height:V,resolution:D,playing:re,muted:_,shouldLoad:ue,mediaRef:Y,withoutVideo:le,className:ti.background})]})},layouts:["normal"],fields:[{name:"image",type:"visual",label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"title",type:"heading-element",inline:!0,theme:{textStyle:"header2"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"surtitle",type:"text-element",label:(0,ue.zR)({id:"YD9M2p",defaultMessage:[{type:0,value:"Overtitle"}]})},{name:"date",type:"date-element",label:(0,ue.zR)({id:"9AP246",defaultMessage:[{type:0,value:"Date"}]})},{name:"author",type:"author-element",label:(0,ue.zR)({id:"73hxYw",defaultMessage:[{type:0,value:"Author"}]})},{name:"subtitle",type:"text-element",label:(0,ue.zR)({id:"EcZYpr",defaultMessage:[{type:0,value:"Subtitle"}]})},{name:"text",type:"text-modal",label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}];function ai(e){var t=e.progress,l=void 0===t?0:t,n=e.playing,r=void 0!==n&&n,s=e.duration,u=void 0===s?0:s,d=e.seek,c=void 0===d?null:d,m=e.play,v=void 0===m?null:m,g=e.className,y=void 0===g?null:g,h=(0,Zl.A)(),f=pl(),p=f.ref,b=f.width,x=void 0===b?null:b,A=f.height,S=l*x,C=(0,a.useState)(null),w=(0,R.A)(C,2),k=w[0],j=w[1],M=(0,a.useMemo)(function(){var e=Math.floor(x/2);return(0,o.A)(Array(e).keys()).map(function(){return Math.floor(100*Math.random())})},[x,2]),N=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=p.current.getBoundingClientRect(),l=t.left,a=t.width,n=Math.max(0,Math.min(1,(e-l)/a));null!==c&&null!==u&&c(parseFloat(n*u,10)),r||null==v||v()}},[p.current,x,u,r,c,v]),F=(0,a.useCallback)(function(e){var t=p.current.getBoundingClientRect(),l=t.left,a=t.width,n=Math.max(0,Math.min(1,(e-l)/a));j(n*x)},[p.current,x,j]),T=(0,a.useCallback)(function(e){e&&(N(e.clientX||null),j(null))},[N,j]),z=(0,Xt.useGesture)({onDrag:function(e){var t=(0,R.A)(e.xy,1)[0],l=e.elapsedTime;!e.active&&l>300||F(t)},onDragStart:function(e){var t=(0,R.A)(e.xy,1)[0],l=e.elapsedTime;!e.active&&l>300||F(t)},onDragEnd:function(e){var t=(0,R.A)(e.xy,1)[0];N(t),setTimeout(function(){j(null)},1e3)}},{drag:{axis:"x",filterTaps:!0}});return(0,se.jsxs)("div",{className:Jt(["micromag-element-audio-audio-bars-container",y]),ref:p,children:[(0,se.jsx)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0",y:"0",width:"".concat(x,"px"),height:"".concat(A,"px"),viewBox:"0 0 ".concat(x," ").concat(A),className:y,xmlSpace:"preserve",children:M.map(function(e,t){return(0,se.jsx)("rect",{width:1,height:e,x:2*t,y:A/2-e/2,fill:(k||S)>2*t?"white":"gray",stroke:"black",strokeWidth:"0px",strokeLinejoin:"round",strokeLinecap:"round"},"bar-".concat(t+1))})}),(0,se.jsx)("button",(0,i.A)((0,i.A)({},z()),{},{onClick:T,type:"button",className:"micromag-element-audio-audio-bars-seekButton",title:h.formatMessage({id:"G1Gyjn",defaultMessage:[{type:0,value:"Seek"}]}),"aria-label":h.formatMessage({id:"G1Gyjn",defaultMessage:[{type:0,value:"Seek"}]})}))]})}var ni=["ref"];function ii(e){var t=e.media,l=void 0===t?null:t,n=e.mediaRef,i=void 0===n?null:n,o=e.muted,r=void 0!==o&&o,s=e.autoPlay,u=void 0!==s&&s,d=e.paused,c=void 0!==d&&d,m=e.loop,v=void 0!==m&&m,g=e.preload,y=void 0===g?"auto":g,f=e.shouldLoad,p=void 0===f||f,b=e.waveFake,x=void 0!==b&&b,A=e.withWave,S=void 0!==A&&A,C=e.autoWaveHeight,w=void 0!==C&&C,k=e.updateInterval,j=void 0===k?1e3:k,M=e.className,N=void 0===M?null:M,F=e.withoutSeek,T=void 0!==F&&F,z=e.onReady,$=void 0===z?null:z,L=e.onPlay,I=void 0===L?null:L,P=e.onPause,B=void 0===P?null:P,E=e.onEnded,V=void 0===E?null:E,D=e.onSeeked,O=void 0===D?null:D,H=e.onTimeUpdate,Z=void 0===H?null:H,W=e.onProgressStep,q=void 0===W?null:W,_=e.onDurationChange,G=void 0===_?null:_,Y=e.onVolumeChange,U=void 0===Y?null:Y,Q=e.onPlayError,X=void 0===Q?null:Q,J=l||{},K=J.url,ee=void 0===K?null:K,te=J.files,le=void 0===te?null:te,ae=(0,a.useMemo)(function(){if(le){var e=Object.entries(le).find(function(e){return"mp3"===(0,R.A)(e,1)[0]})||[],t=(0,R.A)(e,2)[1],l=void 0===t?null:t;if(l)return l.url}return ee},[le,ee]),ne=(0,a.useRef)(null),ie=Sl(ne.current,{id:ae,disabled:c||!S&&null===q,updateInterval:j}),oe=kl(ne.current,{id:ae}),re=Cl(ne.current,{id:ae});!function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.preload,n=void 0===l?"auto":l,i=t.shouldLoad,o=void 0!==i&&i,r=(0,a.useRef)(n),s=(0,a.useRef)(o),u=(0,a.useRef)("none"!==n&&"metadata"!==n&&o);(0,a.useEffect)(function(){var t="none"!==n&&"metadata"!==n&&o,l=r.current!==n,a=s.current!==o;t&&(l||a)&&!u.current&&null!==e&&void 0!==e.load&&(u.current=!0,e.load())},[e,o,n])}(ne.current,{preload:y,shouldLoad:p});var ue=x||oe;(0,a.useEffect)(function(){re>0&&null!==G&&G(re)},[re,G]);var de=(0,a.useCallback)(function(){var e=ne.current,t=void 0===e?null:e;null!==t&&null!==U&&U(t.volume)},[ne.current,U]),me=(0,a.useCallback)(function(){var e=ne.current,t=void 0===e?null:e;null!==t&&t.play()},[ne.current]),ve=(0,a.useCallback)(function(e){var t=ne.current,l=void 0===t?null:t;null!==l&&ce(e)&&(l.currentTime=e)},[ne.current]);(0,a.useEffect)(function(){ue&&null!==$&&$()},[ue,$]),(0,a.useEffect)(function(){var e=ne.current,t=void 0===e?null:e;if(null!==t){var l=t.paused;c&&!l?t.pause():!c&&l&&t.play().catch(function(e){null!==X&&X(e)})}},[c,l,X]),Ml({currentTime:ie,duration:re,disabled:c,onStep:q});var ge=null!==ie&&re>0?ie/re:0;return(0,se.jsxs)("div",{className:Jt(["micromag-element-audio-container",N]),children:[(0,se.jsx)("audio",{ref:function(e){ne.current=e,null!==i&&dn(i)?i(e):null!==i&&(i.current=e)},src:ae,autoPlay:u&&!c,muted:r,loop:v,crossOrigin:"anonymous",preload:y,onPlay:I,onPause:B,onEnded:V,onSeeked:O,onTimeUpdate:Z,onVolumeChange:de},ae),S?(0,se.jsx)(ai,{className:Jt(["micromag-element-audio-wave",(0,h.A)({},"micromag-element-audio-withAutoHeight",w)]),progress:ge,duration:re,playing:!c,seek:T?null:ve,play:me}):null]})}var oi=function(e){var t=e.ref,l=(0,r.A)(e,ni);return(0,se.jsx)(ii,(0,i.A)({mediaRef:t},l))},ri=l(9645);function si(e){var t=e.currentTime,l=void 0===t?0:t,n=e.timeOffset,i=void 0===n?null:n,o=e.media,r=void 0===o?null:o,s=e.textStyle,u=void 0===s?null:s,d=e.boxStyle,c=void 0===d?null:d,m=e.className,v=void 0===m?null:m,g=(r||{}).url,y=void 0===g?null:g,h=(0,a.useState)([]),f=(0,R.A)(h,2),p=f[0],b=f[1],x=(0,a.useState)(-1),A=(0,R.A)(x,2),S=A[0],C=A[1],w=null!==i?i.split(/[\t ]*-->[\t ]*/):null,k=null!==w&&w.length?function(e){var t=e.split(":");try{var l=t[2].split(",");return 1===l.length&&(l=t[2].split(".")),3600*parseFloat(t[0],10)+60*parseFloat(t[1],10)+parseFloat(l[0],10)+parseFloat(l[1],10)/1e3}catch(e){return 0}}(w[0]):0;(0,a.useEffect)(function(){null!==y&&fetch(y,{mode:"cors"}).then(function(e){return e.text()}).then(function(e){return ri(e)}).then(function(e){b(e)}).catch(function(e){console.error(e)})},[y,fetch,b]);var j=(0,a.useCallback)(function(e){var t=p.findIndex(function(t){return e>=t.start-k&&e<=t.end-k});return t},[p,k]);(0,a.useEffect)(function(){if(p.length>0){var e=j(l);e!==S&&C(e)}},[l,p,j,C]);var M=-1!==S?p[S]:null,N=null!==M,F=null!==c?Ve(c):null;return(0,se.jsx)("div",{className:Jt(["micromag-element-closed-captions-container",v]),children:N?(0,se.jsx)("div",{className:"micromag-element-closed-captions-captions",style:F,children:(0,se.jsx)(nn,{textStyle:u,body:M.text})}):null})}var ui={container:"micromag-screen-audio-container",background:"micromag-screen-audio-background",content:"micromag-screen-audio-content",audio:"micromag-screen-audio-audio",bottom:"micromag-screen-audio-bottom",empty:"micromag-screen-audio-empty",isPreview:"micromag-screen-audio-isPreview"},di={id:"audio",type:"screen",group:{label:(0,ue.zR)({id:"+9akmg",defaultMessage:[{type:0,value:"Audio and Video"}]}),order:5},title:(0,ue.zR)({id:"bhEaUt",defaultMessage:[{type:0,value:"Audio"}]}),component:function(e){e.layout;var t=e.audio,l=void 0===t?null:t,n=e.spacing,o=void 0===n?20:n,r=e.background,s=void 0===r?null:r,u=e.header,d=void 0===u?null:u,c=e.footer,m=void 0===c?null:c,v=e.current,g=void 0===v||v,y=e.preload,f=void 0===y||y,p=e.mediaRef,b=void 0===p?null:p,x=e.showWave,A=void 0===x||x,S=e.className,C=void 0===S?null:S,w=It(),k=w.width,j=w.height,M=w.resolution,N=Rt(),F=N.isPlaceholder,T=N.isPreview,z=N.isView,$=N.isEdit,L=N.isStatic,I=N.isCapture,P=Ot(),B=P.topHeight,E=P.bottomHeight,V=P.bottomSidesWidth,D=qt().open,O=Ll("audio"),H=(0,a.useState)(L||F),Z=(0,R.A)(H,2),W=Z[0],q=Z[1],_=g&&(z||$),G=g||f,Y=Ge(d),U=Ye(m),Q=ze(m,{isView:z,current:g,openWebView:D,isPreview:T}),X=null!==l,J=l||{},K=J.media,ee=void 0===K?null:K,te=J.autoPlay,le=void 0===te||te,ae=J.closedCaptions,ne=void 0===ae?null:ae,ie=J.captions,oe=void 0===ie?null:ie,re=J.withWave,ue=void 0!==re&&re,de=J.withControls,ce=void 0!==de&&de,me=J.withSeekBar,ve=void 0!==me&&me,ge=J.color,ye=void 0===ge?null:ge,he=J.progressColor,fe=void 0===he?null:he,pe=(ee||{}).url,be=null!==(void 0===pe?null:pe),xe=X?(0,i.A)((0,i.A)({},l),{},{autoPlay:!T&&!L&&!I&&le&&g}):null,Ae=null!==ne||null!==oe,Se=jt(),Ce=Se.playing,we=Se.muted,ke=Se.setControls,je=Se.setControlsSuggestPlay,Me=Se.setControlsTheme,Ne=Se.setPlaying,Fe=Mt(g),Te=Fe.ref,Re=Fe.isCurrent,$e=!g||!Ce||!(void 0!==Re&&Re)&&z;(0,a.useEffect)(function(){return g?(ce||ve?(ke(!0),Me({seekBarOnly:ve,color:ye,progressColor:fe})):ke(!1),function(){(ce||ve)&&ke(!1)}):function(){}},[g,ce,ve,ke,ye,fe]),(0,a.useEffect)(function(){null!==b&&b(Te.current)},[Te.current]);var Le=(0,a.useCallback)(function(){q(!0)},[q]),Ie=(0,a.useState)(null),Pe=(0,R.A)(Ie,2),Be=Pe[0],Ee=Pe[1],Ve=(0,a.useState)(null),De=(0,R.A)(Ve,2),Oe=De[0],He=De[1],Ze=(0,a.useMemo)(function(){return Ue()},[Ue]);(0,a.useEffect)(function(){g&&le&&!Ce&&Ne(!0)},[g,le]);var We=(0,a.useCallback)(function(e){var t=e.timeStamp;Ee(void 0===t?0:t)},[Ee,He,Oe]),qe=(0,a.useCallback)(function(e,t){O(ee,"progress_".concat(Math.round(100*e,10),"%"),t)},[O,ee]),_e=(0,a.useCallback)(function(e){He(e)},[He]),Qe=(0,a.useCallback)(function(e){var t=e.initial;O(ee,t?"play":"resume")},[O,ee]),Xe=(0,a.useCallback)(function(e){var t=e.midway;O(ee,t?"pause":"ended")},[O,ee]),Je=(0,a.useCallback)(function(){g&&Ne(!1)},[g,Ne]),Ke=(0,a.useCallback)(function(e){e>0&&O(ee,"seek")},[O,ee]),et=(0,a.useCallback)(function(){z&&Ce&&g&&X&&le&&(Ne(!1),je(!0))},[z,g,Ce,X,le,Ne,je]);return(0,se.jsxs)("div",{className:Jt([ui.container,C,(0,h.A)((0,h.A)({},ui.placeholder,F),ui.isPreview,T)]),"data-screen-ready":W,children:[(0,se.jsx)(An,{width:k,height:j,className:ui.content,children:(0,se.jsxs)(Qn,{fullscreen:!0,style:F?null:{padding:o,paddingTop:(T?0:B)+(Y?o/2:o)},children:[Y?(0,se.jsx)(Zn,(0,i.A)({},d)):(0,se.jsx)(Un,{},"spacer-top"),(0,se.jsx)(Qa,{placeholder:"audio",emptyLabel:(0,se.jsx)(Wl.A,{id:"MYZwSA",defaultMessage:[{type:0,value:"Audio"}]}),emptyClassName:ui.empty,isEmpty:!be,children:(0,se.jsx)(oi,(0,i.A)((0,i.A)({},xe),{},{mediaRef:Te,waveFake:Ze||T,waveProps:T?{sampleWidth:10,sampleMargin:5,minSampleHeight:5,backgroundColor:ye,progressColor:fe}:{backgroundColor:ye,progressColor:fe},paused:$e,muted:we,className:ui.audio,onReady:Le,onPlay:Qe,onPause:Xe,onTimeUpdate:We,onProgressStep:qe,onDurationChange:_e,onSeeked:Ke,onEnded:Je,onPlayError:et,withWave:A&&ue}))},"audio"),(0,se.jsx)(Un,{},"spacer-middle"),F?null:(0,se.jsxs)("div",{className:ui.bottom,style:{transform:g&&!T?"translate(0, -".concat(E,"px)"):null,paddingLeft:Math.max(o/2,V),paddingRight:Math.max(o/2,V),paddingBottom:o/2,paddingTop:0},children:[!Ae||T||I||L?null:(0,se.jsx)(si,(0,i.A)((0,i.A)({className:ui.closedCaptions,media:ne},oe),{},{currentTime:Be})),U?(0,se.jsx)(Dn,(0,i.A)((0,i.A)({},Q),{},{className:ui.callToAction})):null]},"bottom")]})}),F?null:(0,se.jsx)(pn,{background:s,width:k,height:j,resolution:M,playing:_,muted:we,shouldLoad:G,withoutVideo:T,className:ui.background})]})},layouts:["middle"],fields:[{name:"audio",type:"audio-element",theme:{color:"primary"},defaultValue:{autoPlay:!0},label:(0,ue.zR)({id:"169xnt",defaultMessage:[{type:0,value:"Audio"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},ci=l(8031),mi=l(4918),vi=l(2717),gi=l(7519),yi=a.createContext(null),hi=function(){return(0,a.useContext)(yi)},fi=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.initialData,n=void 0===l?null:l,i=t.autoload,o=void 0===i||i,r=(0,a.useState)(!1),s=(0,R.A)(r,2),u=s[0],d=s[1],c=(0,a.useState)(!1),m=(0,R.A)(c,2),v=m[0],g=m[1],y=(0,a.useState)(n),h=(0,R.A)(y,2),f=h[0],p=h[1],b=(0,a.useCallback)(function(){var t=!1;d(!0);var l=e.apply(void 0,arguments).then(function(e){return t||(p(e),d(!1)),e}).catch(function(e){g(e),d(!1)});return l.cancel=function(){t=!0,d(!1)},l},[e,d,p]);return(0,a.useEffect)(function(){var e=null;return o&&(e=b()),function(){null!==e&&e.cancel()}},[o,b]),{data:f,load:b,loading:u,error:v}},pi=["data"],bi=["data"],xi=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.screenId,l=e.visitorId,n=void 0===l?null:l,o=e.storyId,r=void 0===o?null:o,s=e.onSuccess,u=void 0===s?null:s,d=hi(),c=(0,a.useState)(!1),m=(0,R.A)(c,2),v=m[0],g=m[1],y=(Yt()||{}).id,h=ct()||{},f=h.id,p=h.document_id;return{create:(0,a.useCallback)(function(e){return null===d?null:(g(!0),d.quiz.create((0,i.A)({screen_id:t,visitor_id:n||y,story_id:p||r||f},e)).then(function(e){return g(!1),null!==u&&u(e),e}))},[d,g,u,t,y,f,n,r]),creating:v}},Ai="micromag-element-text-input-element";function Si(e){var t=e.label,l=void 0===t?null:t,n=e.labelOutside,o=void 0!==n&&n,r=e.labelClassName,s=void 0===r?null:r,u=e.textStyle,c=void 0===u?null:u,m=e.placeholderTextStyle,v=void 0===m?null:m,g=e.buttonStyle,y=void 0===g?null:g,f=e.labelOutsideStyle,p=void 0===f?null:f,b=e.margin,x=void 0===b?null:b,A=e.multiline,S=void 0!==A&&A,C=e.value,w=void 0===C?"":C,k=e.onChange,j=void 0===k?null:k,M=e.onFocus,N=void 0===M?null:M,F=e.onBlur,T=void 0===F?null:F,R=e.required,z=void 0!==R&&R,$=e.disabled,L=void 0!==$&&$,I=e.focusable,P=void 0===I||I,B=e.className,E=void 0===B?null:B,V={},D={},O={},H={},Z=(0,a.useId)();null!==x&&(V=(0,i.A)((0,i.A)({},V),Ze(x))),null!==p&&(D=(0,i.A)((0,i.A)({},D),He(p))),null!==c&&(O=(0,i.A)((0,i.A)({},O),He(c))),null!==y&&(O=(0,i.A)((0,i.A)({},O),Ve(y))),null!==v&&(H=(0,i.A)((0,i.A)({},H),He(v)));var W={className:Jt(["micromag-element-text-input-container",E,(0,h.A)({},Ai,!o),E]),style:V},q=(0,i.A)((0,i.A)({className:Ai},o?null:W),{},{style:O,placeholder:o?void 0:l,value:w,onChange:j,onFocus:N,onBlur:T,required:z,disabled:L}),_=S?(0,se.jsx)("textarea",(0,i.A)((0,i.A)({},q),{},{tabIndex:P?0:-1,id:"input-".concat(Z)})):(0,se.jsx)("input",(0,i.A)((0,i.A)({},q),{},{type:"text",tabIndex:P?0:-1,id:"input-".concat(Z)})),G=function(e,t){var l=null!==t?Object.keys(t).reduce(function(e,l){var a=t[l];return d()(a)?e:(0,i.A)((0,i.A)({},e),{},(0,h.A)({},l.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),a))},{}):null;return null!==l&&Object.keys(l).length>0?"\n ".concat(e,"::placeholder {\n ").concat(Object.keys(l).map(function(e){return"".concat(e,": ").concat(l[e],";")}).join("\n"),"\n }\n "):null}("#input-".concat(Z),H),Y=null!==G?(0,se.jsx)("style",{type:"text/css",children:G}):null;return o?(0,se.jsxs)("label",(0,i.A)((0,i.A)({},W),{},{children:[(0,se.jsx)("div",{className:s,style:D,children:l}),_,Y]})):(0,se.jsxs)(se.Fragment,{children:[_,Y]})}var Ci={container:"micromag-screen-contribution-container",background:"micromag-screen-contribution-background",content:"micromag-screen-contribution-content",inner:"micromag-screen-contribution-inner",layout:"micromag-screen-contribution-layout",header:"micromag-screen-contribution-header",emptyTitle:"micromag-screen-contribution-emptyTitle",emptyInputName:"micromag-screen-contribution-emptyInputName",emptyInputMessage:"micromag-screen-contribution-emptyInputMessage",emptySubmit:"micromag-screen-contribution-emptySubmit",emptySkip:"micromag-screen-contribution-emptySkip",title:"micromag-screen-contribution-title",interactiveContainer:"micromag-screen-contribution-interactiveContainer",form:"micromag-screen-contribution-form",inputName:"micromag-screen-contribution-inputName",inputMessage:"micromag-screen-contribution-inputMessage",buttonSubmit:"micromag-screen-contribution-buttonSubmit",buttonSkip:"micromag-screen-contribution-buttonSkip",showBack:"micromag-screen-contribution-showBack",formContent:"micromag-screen-contribution-formContent",formLoading:"micromag-screen-contribution-formLoading",loadingIcon:"micromag-screen-contribution-loadingIcon",contributionsContainer:"micromag-screen-contribution-contributionsContainer",contributionsContent:"micromag-screen-contribution-contributionsContent",contributions:"micromag-screen-contribution-contributions",contribution:"micromag-screen-contribution-contribution",footer:"micromag-screen-contribution-footer",disabled:"micromag-screen-contribution-disabled",submitting:"micromag-screen-contribution-submitting",submitted:"micromag-screen-contribution-submitted",showContributions:"micromag-screen-contribution-showContributions",isPlaceholder:"micromag-screen-contribution-isPlaceholder",reset:"micromag-screen-contribution-reset"},wi={id:"contribution",type:"screen",group:{label:(0,ue.zR)({id:"ZiWlL6",defaultMessage:[{type:0,value:"Questions"}]}),order:7},title:(0,ue.zR)({id:"g6b9Lg",defaultMessage:[{type:0,value:"Contribution"}]}),component:function(e){var t=e.id,l=void 0===t?null:t,n=e.layout,s=void 0===n?"middle":n,u=e.title,d=void 0===u?null:u,c=e.name,m=void 0===c?null:c,v=e.message,g=void 0===v?null:v,y=e.submit,f=void 0===y?null:y,p=e.nameStyle,b=void 0===p?null:p,x=e.messageStyle,A=void 0===x?null:x,S=e.settings,C=void 0===S?null:S,w=e.spacing,k=void 0===w?20:w,j=e.background,M=void 0===j?null:j,N=e.header,F=void 0===N?null:N,T=e.footer,z=void 0===T?null:T,$=e.current,L=void 0===$||$,I=e.preload,P=void 0===I||I,B=e.transitions,E=void 0===B?null:B,V=e.transitionStagger,D=void 0===V?100:V,O=e.resizeTransitionDuration,H=void 0===O?750:O,Z=e.type,W=void 0===Z?null:Z,q=e.className,_=void 0===q?null:q,G=(0,Zl.A)(),Y=l||"screen-id",U=$l(W),Q=It(),X=Q.width,J=Q.height,K=Q.resolution,ee=Ot(),te=ee.topHeight,le=ee.bottomHeight,ae=ee.bottomSidesWidth,ne=Rt(),ie=ne.isView,oe=ne.isPreview,re=ne.isPlaceholder,ue=ne.isEdit,de=ne.isStatic,ce=ne.isCapture,me=qt().open,ve=jt().muted,ge=Mt(L,!0),ye=ge.ref,he=ge.isCurrent,fe=L&&(ie||ue)&&(void 0!==he&&he||!ie),pe=L||P,be=L,xe=de||ce||re||oe||ue,Ae=!ue&&xe||!L,Se=Ge(F),Ce=Ye(z),we=ze(z,{isView:ie,current:L,openWebView:me,isPreview:oe}),ke=Je(d),je=Xe(m),Me=Xe(g),Ne=Je(f),Fe=(0,a.useRef)(null),Te=(0,a.useRef)(null),Re=(0,a.useState)(null),$e=(0,R.A)(Re,2),Le=$e[0],Ie=$e[1],Pe=(0,a.useState)(""),Be=(0,R.A)(Pe,2),Ve=Be[0],De=Be[1],Oe=(0,a.useState)(""),He=(0,R.A)(Oe,2),Ze=He[0],We=He[1],qe=(0,a.useState)(de||ce?4:0),_e=(0,R.A)(qe,2),Ue=_e[0],Qe=_e[1],Ke=(0,a.useState)(!1),et=(0,R.A)(Ke,2),tt=et[0],lt=et[1],at=C||{},nt=at.canViewAnswers,it=void 0!==nt&&nt,ot=at.skipButton,rt=void 0===ot?null:ot,st=at.backButton,ut=4===Ue?void 0===st?null:st:rt,dt=Je(ut)?ut:(0,i.A)((0,i.A)({},ut),{},{body:4===Ue?G.formatMessage({id:"8NyYTH",defaultMessage:[{type:0,value:"Back"}]}):G.formatMessage({id:"HpkW4J",defaultMessage:[{type:0,value:"Skip"}]})}),mt=(0,a.useCallback)(function(){Qe(2),U("submit_success","".concat(Ve,": ").concat(Ze)),lt(!0)},[Qe,lt,U,Ve,Ze]),vt=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.screenId,l=e.visitorId,n=void 0===l?null:l,o=e.storyId,r=void 0===o?null:o,s=e.onSuccess,u=void 0===s?null:s,d=hi(),c=(0,a.useState)(!1),m=(0,R.A)(c,2),v=m[0],g=m[1],y=(Yt()||{}).id,h=ct()||{},f=h.id,p=h.document_id;return{create:(0,a.useCallback)(function(e){return null===d?null:(g(!0),d.contributions.create((0,i.A)({screen_id:t,visitor_id:n||y,story_id:p||r||f},e)).then(function(e){return g(!1),null!==u&&u(e),e}))},[d,g,u,t,y,f,n,r]),creating:v}}({screenId:Y}),gt=vt.create,yt=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.screenId,l=e.storyId,n=void 0===l?null:l,s=e.opts,u=void 0===s?{}:s,d=hi(),c=ct()||{},m=c.id,v=c.document_id,g=(0,a.useState)((0,o.A)(new Array(10)).map(function(e,t){return{name:"Nom ".concat(t+1),message:"Message ".concat(t+1)}})),y=(0,R.A)(g,1)[0],h=(0,a.useCallback)(function(){return null!==d?d.contributions.get(t,{story_id:v||n||m}):null},[d,t,v,n,m]),f=null!==d?fi(h,u):{data:null},p=f.data,b=(0,r.A)(f,pi);return(0,i.A)({contributions:p||y},b)}({screenId:Y,opts:{autoload:!re}}),ht=yt.contributions,ft=(0,a.useCallback)(function(e){var t=gi.A.sanitize(e.currentTarget.value||"");De(t)},[De]),pt=(0,a.useCallback)(function(e){var t=gi.A.sanitize(e.currentTarget.value||"");We(t)},[We]),bt=(0,a.useCallback)(function(){De(""),We(""),Qe(0),lt(!1)},[De,We,Qe,lt]),xt=(0,a.useRef)(!1),At=(0,a.useCallback)(function(e){!xt.current&&e.currentTarget.value.length>0&&(xt.current=!0,U("input_filled","Name",{userName:e.currentTarget.value,userMessage:Ze}))},[U,Ze]),St=(0,a.useRef)(!1),Ct=(0,a.useCallback)(function(e){!St.current&&e.currentTarget.value.length>0&&(St.current=!0,U("input_filled","Message",{userName:Ve,userMessage:e.currentTarget.value}))},[U,Ve]),wt=(0,a.useState)(!1),kt=(0,R.A)(wt,2),Nt=kt[0],Ft=kt[1],Tt=Nt&&4===Ue,zt=pl(),$t=zt.ref,Lt=zt.height,Pt=void 0===Lt?0:Lt,Bt=(0,a.useCallback)(function(e){e.initial&&U("scroll","Contributions list"),Ft(!0)},[U,Ft]),Et=(0,a.useCallback)(function(){Ft(!1)},[Ft]),Vt=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);U("scroll",t,{scrollPercent:t})}},[U]),Dt=(0,a.useCallback)(function(e){e.preventDefault(),0===Ue&&(Ie(Te.current.offsetHeight),Qe(1),gt({name:Ve,message:Ze}),mt(),U("click_submit","".concat(Ve,": ").concat(Ze),{userName:Ve,userMessage:Ze}))},[Ue,Qe,Ve,Ze,U,mt]),Ht=(0,a.useCallback)(function(){4===Ue?(Qe(0),U("click_skip","Skip button")):(Qe(4),U("click_back","Back button"))},[Ue,Qe,U]);(0,a.useEffect)(function(){var e=null;return 2===Ue&&(e=setTimeout(Qe,H,4),Ie(Fe.current.offsetHeight),Qe(3)),function(){3===Ue&&null!==e&&clearTimeout(e)}},[Ue,Ie,Qe,H]);var Zt=[(0,se.jsx)(Qa,{placeholder:"title",placeholderProps:{height:"0.75em"},emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Ci.emptyTitle,isEmpty:!ke,children:ke?(0,se.jsx)(_n,(0,i.A)((0,i.A)({},d),{},{className:Ci.title})):null},"title")],Wt=[].concat((0,o.A)(null!==Ve&&""!==Ve&&null!==Ze&&""!==Ze?[{name:Ve,message:Ze}]:[]),(0,o.A)(ht||[]));Zt.push((0,se.jsxs)("div",{className:Ci.interactiveContainer,style:{height:Ue<4?Le:null,transitionDuration:"".concat(H,"ms")},children:[(0,se.jsxs)("form",{className:Ci.form,onSubmit:Dt,ref:Te,children:[(0,se.jsxs)("div",{className:Ci.formContent,children:[(0,se.jsx)(Qa,{placeholder:"inputText",placeholderProps:{height:"0.25em"},emptyLabel:(0,se.jsx)(Wl.A,{id:"G/ITGY",defaultMessage:[{type:0,value:"Your name"}]}),emptyClassName:Ci.emptyInputName,isEmpty:!je,children:(0,se.jsx)(Ka,{transitions:E,playing:be,delay:D,disabled:xe,children:(0,se.jsx)(Si,(0,i.A)((0,i.A)({className:Ci.inputName},m),{},{value:Ve,onChange:function(e){return ft(e)},onBlur:function(e){return At(e)},focusable:L&&ie,disabled:oe,required:!0}))})}),(0,se.jsx)(Qa,{placeholder:"inputText",placeholderProps:{height:"0.75em"},emptyLabel:(0,se.jsx)(Wl.A,{id:"JAguka",defaultMessage:[{type:0,value:"Your message"}]}),emptyClassName:Ci.emptyInputMessage,isEmpty:!Me,children:(0,se.jsx)(Ka,{transitions:E,playing:be,delay:2*D,disabled:xe,children:(0,se.jsx)(Si,(0,i.A)((0,i.A)({className:Ci.inputMessage},g),{},{value:Ze,onChange:function(e){return pt(e)},onBlur:function(e){return Ct(e)},disabled:oe,focusable:L&&ie,multiline:!0,required:!0}))})}),(0,se.jsx)(Qa,{placeholder:"button",emptyLabel:(0,se.jsx)(Wl.A,{id:"5uH4x7",defaultMessage:[{type:0,value:"Submit"}]}),emptyClassName:Ci.emptySubmit,isEmpty:!Ne,children:(0,se.jsx)(Ka,{transitions:E,playing:be,delay:3*D,disabled:xe,children:(0,se.jsx)(zn,{type:"submit",className:Ci.buttonSubmit,disabled:oe,buttonStyle:null!==f?f.buttonStyle:null,focusable:L&&ie,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},f),{},{inline:!0}))})})})]}),(0,se.jsx)("div",{className:Ci.formLoading,children:(0,se.jsx)(vi.gc,{className:Ci.loadingIcon,icon:mi.z1})})]}),it&&!tt?(0,se.jsx)(Qa,{placeholder:"button",emptyLabel:4!==Ue?(0,se.jsx)(Wl.A,{id:"U2RZp5",defaultMessage:[{type:0,value:"Skip"}]}):(0,se.jsx)(Wl.A,{id:"AzN1aW",defaultMessage:[{type:0,value:"Back"}]}),emptyClassName:Ci.emptySkip,children:(0,se.jsx)(Ka,{transitions:E,playing:be,delay:3*D,disabled:xe,children:(0,se.jsx)(zn,{type:"button",className:Jt([Ci.buttonSkip,(0,h.A)({},Ci.showBack,4===Ue)]),disabled:oe,onClick:Ht,buttonStyle:null!==dt?dt.buttonStyle:null,focusable:L&&ie,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},dt),{},{inline:!0}))})})}):null,(0,se.jsx)("div",{className:Ci.contributionsContainer,"aria-hidden":4===Ue?null:"true",children:(0,se.jsx)("div",{className:Ci.contributionsContent,children:(0,se.jsx)("div",{className:Ci.contributions,ref:Fe,children:Wt.map(function(e,t){var l=null!==b&&b.style||null,a=null!==A&&A.style||null;return(0,se.jsxs)("div",{className:Ci.contribution,style:null!==l?Ee(l.color,"borderColor"):null,children:[(0,se.jsx)(_n,{className:Ci.contributionName,body:e.name,size:2,textStyle:l}),(0,se.jsx)(nn,{className:Ci.contributionMessage,body:e.message,textStyle:a})]},"contribution-".concat(t))})})})}),Ce?(0,se.jsx)("div",{style:{height:Pt}}):null]},"form"));var _t=!re&&Se?(0,se.jsx)("div",{className:Ci.header,style:{paddingBottom:k},children:(0,se.jsx)(Zn,(0,i.A)({},F))}):null,Gt=ue&&4===Ue;return(0,se.jsxs)("div",{className:Jt([Ci.container,_,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Ci.isPlaceholder,re),Ci.submitting,1===Ue),Ci.submitted,Ue>1),Ci.showContributions,4===Ue)]),"data-screen-ready":!0,children:[(0,se.jsxs)(An,{width:X,height:J,className:Ci.content,children:[Gt?(0,se.jsx)(zn,{className:Ci.reset,icon:(0,se.jsx)(vi.gc,{icon:ci.ye,size:"md"}),onClick:bt}):null,(0,se.jsxs)("div",{className:Ci.inner,children:[(0,se.jsx)(ei,{verticalAlign:s,disabled:Ae,onScrolledTrigger:Vt,onScrolledBottom:Bt,onScrolledNotBottom:Et,scrolleeClassName:Ci.scrollee,withShadow:!0,children:(0,se.jsxs)(Qn,{className:Ci.layout,style:re?null:{padding:k,paddingTop:Se?k/2+(oe?0:te):k/2,paddingBottom:(L&&!oe?le:0)+k/2},children:[_t,Zt]})}),!re&&Ce?(0,se.jsx)("div",{ref:$t,className:Jt([Ci.footer,(0,h.A)({},Ci.disabled,!Tt)]),style:{paddingLeft:Math.max(ae,k/2),paddingRight:Math.max(ae,k/2),paddingTop:0,paddingBottom:(oe?0:le)+k/2},children:(0,se.jsx)(Dn,(0,i.A)({},we))}):null]})]}),re?null:(0,se.jsx)(pn,{background:M,width:X,height:J,resolution:K,playing:fe,muted:ve,shouldLoad:pe,mediaRef:ye,withoutVideo:oe,className:Ci.background})]})},layouts:["top","middle","bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"name",type:"input-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"nXVNeg",defaultMessage:[{type:0,value:"Name"}]})},{name:"message",type:"input-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"RcLsua",defaultMessage:[{type:0,value:"Message"}]})},{name:"submit",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"uAKPQ9",defaultMessage:[{type:0,value:"Submit"}]})},{name:"nameStyle",type:"item-text-style",theme:{style:{textStyle:"heading2"}},label:(0,ue.zR)({id:"SyMSDa",defaultMessage:[{type:0,value:"Published name style"}]})},{name:"messageStyle",type:"item-text-style",theme:{style:{textStyle:"text"}},label:(0,ue.zR)({id:"+SlKOi",defaultMessage:[{type:0,value:"Published message style"}]})},{name:"settings",component:"toggle-section",toggleField:"canViewAnswers",isList:!0,label:(0,ue.zR)({id:"9omJnT",defaultMessage:[{type:0,value:"Answer settings"}]}),fields:[{name:"canViewAnswers",type:"toggle",isHorizontal:!0,label:(0,ue.zR)({id:"xcHW4o",defaultMessage:[{type:0,value:"Can view answers"}]})},{name:"skipButton",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"CpCykm",defaultMessage:[{type:0,value:"Skip button"}]})},{name:"backButton",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"KIXg9M",defaultMessage:[{type:0,value:"Back button"}]})}]},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},ki=l(3104),ji={container:"micromag-screen-conversation-container",background:"micromag-screen-conversation-background",content:"micromag-screen-conversation-content",empty:"micromag-screen-conversation-empty",title:"micromag-screen-conversation-title",footer:"micromag-screen-conversation-footer",disabled:"micromag-screen-conversation-disabled",layout:"micromag-screen-conversation-layout",messageContainer:"micromag-screen-conversation-messageContainer",message:"micromag-screen-conversation-message",normalLeft:"micromag-screen-conversation-normalLeft",inBetweenLeft:"micromag-screen-conversation-inBetweenLeft",normalRight:"micromag-screen-conversation-normalRight",inBetweenRight:"micromag-screen-conversation-inBetweenRight",last:"micromag-screen-conversation-last",messageBody:"micromag-screen-conversation-messageBody",speakerDetails:"micromag-screen-conversation-speakerDetails",right:"micromag-screen-conversation-right",avatarContainer:"micromag-screen-conversation-avatarContainer",avatar:"micromag-screen-conversation-avatar",imageContainer:"micromag-screen-conversation-imageContainer",withAnimation:"micromag-screen-conversation-withAnimation",loadingContainer:"micromag-screen-conversation-loadingContainer",loading:"micromag-screen-conversation-loading",dot:"micromag-screen-conversation-dot",loadingSpeakerName:"micromag-screen-conversation-loadingSpeakerName",audioMessageContainer:"micromag-screen-conversation-audioMessageContainer",playButtonContainer:"micromag-screen-conversation-playButtonContainer",button:"micromag-screen-conversation-button",audioMessage:"micromag-screen-conversation-audioMessage",icon:"micromag-screen-conversation-icon"};function Mi(e){var t=e.audio,l=void 0===t?null:t,n=e.audioEventsChannelName,i=void 0===n?null:n,o=e.messageId,r=void 0===o?null:o,s=e.nextAudioMessageId,u=void 0===s?null:s,d=e.className,c=void 0===d?null:d,m=(0,a.useState)(!0),v=(0,R.A)(m,2),g=v[0],y=v[1],h=(0,a.useMemo)(function(){return new BroadcastChannel(i)},[i]);return(0,a.useEffect)(function(){var e=function(e){var t=e.data,l=t.type,a=t.id;"play"===l&&y(a!==r)};return h.addEventListener("message",e),function(){return h.removeEventListener("message",e)}},[h]),(0,se.jsxs)("div",{className:Jt([ji.audioMessageContainer,c]),children:[(0,se.jsx)("div",{className:ji.playButtonContainer,children:g?(0,se.jsx)(pa,{className:ji.icon}):(0,se.jsx)(fa,{className:ji.icon})}),(0,se.jsx)(oi,{withWave:!0,autoWaveHeight:!0,className:ji.audioMessage,media:l,paused:g,updateInterval:100,onEnded:function(){u&&h.postMessage({type:"play",id:u}),y(!0)}}),(0,se.jsx)(ca,{onClick:function(){g?(y(!1),h.postMessage({type:"play",id:r})):y(!0)},className:ji.button})]})}function Ni(e){var t=e.message,l=void 0===t?null:t,n=e.messageId,o=void 0===n?null:n,r=e.previousMessage,s=void 0===r?null:r,u=e.nextMessage,d=void 0===u?null:u,c=e.nextAudioMessageId,m=void 0===c?null:c,v=e.nextMessageState,g=void 0===v?null:v,y=e.currentSpeaker,f=void 0===y?null:y,p=e.conversationTiming,b=void 0===p?null:p,x=e.typingTiming,A=void 0===x?null:x,S=e.onChange,C=void 0===S?null:S,w=e.withAnimation,k=void 0!==w&&w,j=e.active,M=void 0!==j&&j,N=e.isPlaying,F=void 0!==N&&N,T=e.messageStyle,z=void 0===T?null:T,$=e.speakerStyle,L=void 0===$?null:$,I=e.className,P=void 0===I?null:I,B=e.audioEventsChannelName,E=void 0===B?null:B,V=l||{},D=V.message,O=V.image,H=void 0===O?null:O,Z=V.audio,W=V.putAudioBeforeText,q=void 0!==W&&W,_=f||{},G=_.avatar,Y=void 0===G?null:G,U=_.name,Q=_.side,X=void 0===Q?"left":Q,J=_.id,K=_.color,ee=(Y||{}).url,te=void 0===ee?null:ee,le="right"===X,ae=null!==s&&s.speaker===J,ne=null!==d&&d.speaker===J,ie=(0,a.useState)(k?"pause":"send"),oe=(0,R.A)(ie,2),re=oe[0],ue=oe[1],de=b,ce=A;(0,a.useEffect)(function(){if(!k||!F)return function(){};var e=null;return"pause"===re?e=setTimeout(function(){return ue("typing")},de):"typing"===re&&(e=setTimeout(function(){return ue("send")},ce)),function(){null!==e&&clearTimeout(e)}},[k,F,re,ue,de,ce]),(0,a.useEffect)(function(){"pause"!==re&&null!==C&&C(re)},[re]);var me=ne&&g;return"pause"!==re?(0,se.jsx)("div",{className:Jt([ji.messageContainer,P,(0,h.A)((0,h.A)({},ji.withAnimation,!0===k),ji.right,le)]),children:"typing"===re?(0,se.jsxs)("div",{className:ji.loadingContainer,children:[(0,se.jsxs)("div",{className:ji.loading,children:[(0,se.jsx)("div",{className:ji.dot}),(0,se.jsx)("div",{className:ji.dot}),(0,se.jsx)("div",{className:ji.dot})]}),(0,se.jsx)("div",{className:ji.loadingSpeakerName,children:U})]}):(0,se.jsxs)("div",{className:Jt([ji.message,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},ji.normalRight,le),ji.nextTheSame,!0===ne&&ae),ji.inBetweenRight,me&&le),ji.normalLeft,!le),ji.inBetweenLeft,me&&!le),ji.last,!1===ne)]),style:(0,i.A)({},Ee(K)),children:[ae?null:(0,se.jsxs)("div",{className:Jt([ji.speakerDetails,(0,h.A)({},ji.right,"right"===X)]),children:[null!==te?(0,se.jsx)("div",{className:Jt([ji.avatarContainer,(0,h.A)({},ji.right,"right"===X)]),children:(0,se.jsx)("img",{className:ji.avatar,src:te,alt:U,loading:"lazy"})}):null,(0,se.jsx)(nn,{body:U,textStyle:L})]}),(0,se.jsxs)("div",{className:ji.messageBody,children:[null!==H?(0,se.jsx)("div",{className:ji.imageContainer,children:(0,se.jsx)(Nn,{media:H,width:"100%",playing:F,active:M})}):null,Z&&q?(0,se.jsx)(Mi,{audio:Z,messageId:o,nextAudioMessageId:m,audioEventsChannelName:E,className:Jt(ji.audioAttachment,ji.beforeText)}):null,(0,se.jsx)(nn,{className:ji.messageText,body:D,textStyle:z}),Z&&!q?(0,se.jsx)(Mi,{audio:Z,messageId:o,nextAudioMessageId:m,audioEventsChannelName:E,className:Jt(ji.audioAttachment,ji.afterText)}):null]})]})}):null}var Fi={id:"conversation",type:"screen",group:{label:(0,ue.zR)({id:"fIawTr",defaultMessage:[{type:0,value:"Text"}]}),order:3},title:(0,ue.zR)({id:"rBPIgw",defaultMessage:[{type:0,value:"Conversation"}]}),component:function(e){var t=e.title,l=void 0===t?null:t,n=e.timing,r=void 0===n?"sequence":n,s=e.readingSpeed,u=void 0===s?255:s,d=e.spacing,c=void 0===d?20:d,m=e.background,v=void 0===m?null:m,g=e.header,y=void 0===g?null:g,f=e.footer,p=void 0===f?null:f,b=e.current,x=void 0===b||b,A=e.preload,S=void 0===A||A,C=e.type,w=void 0===C?null:C,k=e.conversation,j=void 0===k?null:k,M=e.transitions,N=void 0===M?null:M,F=e.className,T=void 0===F?null:F,z=It(),$=z.width,L=z.height,I=z.resolution,P=Ot(),B=P.topHeight,E=P.bottomHeight,V=P.bottomSidesWidth,D=qt().open,O=$l(w),H=jt().muted,Z=Mt(x,!0),W=Z.ref,q=Z.isCurrent,_=void 0!==q&&q,G=new BroadcastChannel("conversation_".concat((0,ki.A)(),"_audioEvents")),Y=Rt(),U=Y.isView,Q=Y.isPreview,X=Y.isPlaceholder,J=Y.isEdit,K=Y.isStatic,ee=Y.isCapture,te=x&&(U||J)&&(_||!U),le=x||S,ae=U&&!K&&"sequence"===r,ne=j||{},ie=ne.speakers,oe=void 0===ie?null:ie,re=ne.messages,ue=void 0===re?[]:re,de=ne.messageStyle,ce=ne.speakerStyle,me=(0,a.useState)([]),ve=(0,R.A)(me,2),ge=ve[0],ye=ve[1],he=(0,a.useRef)(null),fe=Ge(y),pe=Ye(p),be=ze(p,{isView:U,current:x,openWebView:D,isPreview:Q}),xe=Je(l),Ae=pl(),Se=Ae.ref,Ce=Ae.height,we=(0,a.useRef)(null),ke=(0,a.useState)(!1),je=(0,R.A)(ke,2),Me=je[0],Ne=je[1];(0,a.useEffect)(function(){ae&&null!==we.current&&Me&&we.current.scrollTo({top:Ce,behavior:"smooth"})},[Ce,ae]);var Fe=ue.length===ge.length,Te=(0,a.useCallback)(function(e){var t=(0,o.A)(ge);"send"===e&&(t.push(!0),ye(t))},[ge,ye]),Re=6e4/u,$e=(ue||[]).filter(function(e){return null!==e}),Le=$e.map(function(e,t){if(0===t)return 0;var l,a=e||{},n=a.timing,i=void 0===n?null:n,o=a.message,r=void 0===o?null:o,s=a.image,u=a.audio,d=a.timingOverrides;if(null!==i)return i;if(null!=d&&d.enabled&&Number.isFinite(null==d?void 0:d.writingDuration))return 1e3*d.writingDuration;if(u)return null===(l=u.metadata)||void 0===l?void 0:l.duration;var c=(r?r.replace(/[^\w\d\s]/g,"").trim().split(/\s/g).length:0)*Re;return s&&(c+=5e3),c}),Ie=$e.map(function(e,t){var l=e.timingOverrides;return 0!==t&&null!=l&&l.enabled&&Number.isFinite(null==l?void 0:l.appearDelay)?1e3*l.appearDelay:1500}),Pe=(0,a.useMemo)(function(){return(ue||[]).map(function(){return(0,ki.A)()})},[ue]),Be=K||ee||X||Q||J,Ee=!J&&Be||!x,Ve=Fe&&!X&&pe||!ae,De=(0,a.useCallback)(function(e){e.initial&&O("scroll","Screen"),Ne(!0)},[O]),Oe=(0,a.useCallback)(function(){Ne(!1)},[Ne]),He=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);O("scroll",t,{scrollPercent:t})}},[O]);return(0,se.jsxs)("div",{className:Jt([ji.container,T,(0,h.A)({},ji.isPlaceholder,X)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:$,height:L,className:ji.content,children:(0,se.jsx)(ei,{ref:we,disabled:Ee,onScrolledTrigger:He,onScrolledBottom:De,onScrolledNotBottom:Oe,withShadow:!0,children:(0,se.jsx)("div",{ref:Se,children:(0,se.jsxs)(Qn,{className:ji.layout,style:X?null:{padding:c,paddingTop:(Q?0:B)+c/2,paddingBottom:(x&&!Q?E:0)+c/2},children:[!X&&fe?(0,se.jsx)("div",{style:{paddingBottom:c},children:(0,se.jsx)(Zn,(0,i.A)({},y))},"header"):null,(0,se.jsx)(Qa,{placeholder:"conversation",emptyLabel:(0,se.jsx)(Wl.A,{id:"NmCfTO",defaultMessage:[{type:0,value:"Conversation"}]}),emptyClassName:ji.empty,isEmpty:0===ue.length&&null===l,children:(0,se.jsxs)(Ka,{transitions:N,playing:x,disabled:Be,children:[xe?(0,se.jsx)(_n,(0,i.A)((0,i.A)({},l),{},{className:ji.title,isEmpty:null===l})):null,(0,se.jsx)("div",{className:ji.conversation,children:$e.map(function(e,t){var l=0!==t?ue[t-1]:null,a=t+1<ue.length?ue[t+1]:null,n=e.speaker,i=(oe||[]).find(function(e){return e.id===n})||null,o=0===t||!0===ge[t-1],r=Ie[t],s=Le[t],u="".concat(e.message,"-").concat(Pe[t]),d=$e.slice(t+1).find(function(e){return null!=e.audio}),c=d?"".concat(e.message,"-").concat(Pe[$e.indexOf(d)]):null;return(0,se.jsx)(Ni,{message:e,messageId:u,previousMessage:l,nextMessage:a,nextAudioMessageId:c,nextMessageState:ge[t+1]||!ae,currentSpeaker:i,conversationTiming:r,typingTiming:s,onChange:Te,withAnimation:ae,isPlaying:x&&o,shouldLoad:le,withoutVideo:Q,messageStyle:de,speakerStyle:ce,audioEventsChannelName:G.name},u)})}),Ve?(0,se.jsx)("div",{className:Jt([ji.footer,(0,h.A)({},ji.disabled,!Me)]),style:{paddingLeft:Math.max(V-c,0),paddingRight:Math.max(V-c,0),paddingTop:c},children:(0,se.jsx)(Dn,(0,i.A)({},be))}):null,(0,se.jsx)("div",{ref:he})]})})]})})})}),X?null:(0,se.jsx)(pn,{background:v,width:$,height:L,resolution:I,playing:te,muted:H,shouldLoad:le,mediaRef:W,withoutVideo:Q,className:ji.background})]})},layouts:["normal"],fields:[{name:"timing",type:"select",options:[{value:"instant",label:"Instant"},{value:"sequence",label:"Sequence"}],label:(0,ue.zR)({id:"6DV50M",defaultMessage:[{type:0,value:"Timing"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"conversation",type:"conversation",label:(0,ue.zR)({id:"8tANs8",defaultMessage:[{type:0,value:"Conversation"}]})},{name:"readingSpeed",type:"number",defaultValue:255,label:(0,ue.zR)({id:"QjbLZ9",defaultMessage:[{type:0,value:"Reading speed (in Words Per Minute)"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Ti=l(8360);function Ri(e){var t=e.items,l=void 0===t?null:t,a=e.layout,n=void 0===a?null:a,i=e.width,o=void 0===i?null:i,r=e.height,s=void 0===r?null:r,u=e.spacing,d=void 0===u?0:u,c=e.vertical,m=void 0!==c&&c,v=e.className,g=void 0===v?null:v,y=e.axisClassName,h=void 0===y?null:y,f=e.crossClassName,p=void 0===f?null:f,x=0,A=l||[],S=b(n)?n:[{rows:m?A.map(function(){return 1}):1,columns:m?1:A.map(function(){return 1})}],C=S.reduce(function(e,t){var l=t.rows,a=void 0===l?1:l,n=t.columns;return e+(m?void 0===n?1:n:a)},0);return(0,se.jsx)("div",{className:Jt(["micromag-element-grid-container",g]),style:{width:o,height:s,padding:null!==d&&d>0?d/2:null},children:(0,se.jsx)("div",{className:"micromag-element-grid-items",style:{flexDirection:m?"row":"column"},children:S.map(function(e,t){var l=e.rows,a=e.columns,n="".concat((m?a:l)/C*100,"%"),i=m?l:a,o=b(i)?i:[i],r=o.reduce(function(e,t){return e+t},0);return(0,se.jsx)("div",{className:Jt(["micromag-element-grid-cross",p]),style:{flexDirection:m?"column":"row",width:m?n:null,height:m?null:n},children:o.map(function(e,t){var l="".concat(e/r*100,"%"),a=A[x];return x+=1,(0,se.jsx)("div",{className:Jt(["micromag-element-grid-axis",h]),style:{width:m?null:l,height:m?l:null,padding:d>0?d/2:0},children:a},"axis-".concat(t))})},"cross-".concat(t))})})})}var zi=l(6207),$i=l(9575),Li={"two-vertical-equal":{vertical:!0,layout:[{columns:1,rows:[1,1]}]},"two-vertical-top":{vertical:!0,layout:[{columns:1,rows:[2,1]}]},"two-vertical-bottom":{vertical:!0,layout:[{columns:1,rows:[1,2]}]},"three-vertical":{vertical:!0,layout:[{columns:1,rows:[1,1,1]}]},"one-two":{layout:[{rows:2,columns:[1]},{rows:1,columns:[1,1]}]},"two-one":{layout:[{rows:1,columns:[1,1]},{rows:2,columns:[1]}]},"two-by-two":{layout:[{rows:1,columns:[1,1]},{rows:1,columns:[1,1]}]},"four-vertical":{vertical:!0,layout:[{columns:1,rows:[1,1,1,1]}]},"one-two-one":{layout:[{rows:3,columns:[1]},{rows:2,columns:[1,1]},{rows:3,columns:[1]}]},"four-mosaic":{vertical:!0,layout:[{columns:1,rows:[2,1]},{columns:1,rows:[1,2]}]},"two-one-two":{layout:[{rows:2,columns:[1,1]},{rows:3,columns:[1]},{rows:2,columns:[1,1]}]},"one-two-two":{layout:[{rows:3,columns:[1]},{rows:2,columns:[1,1]},{rows:2,columns:[1,1]}]},"two-two-one":{layout:[{rows:2,columns:[1,1]},{rows:2,columns:[1,1]},{rows:3,columns:[1]}]},"two-by-three":{layout:[{rows:1,columns:[1,1]},{rows:1,columns:[1,1]},{rows:1,columns:[1,1]}]},"one-one-two-two":{layout:[{rows:1,columns:[1]},{rows:1,columns:[1]},{rows:1,columns:[1,1]},{rows:1,columns:[1,1]}]},"two-two-one-one":{layout:[{rows:1,columns:[1,1]},{rows:1,columns:[1,1]},{rows:1,columns:[1]},{rows:1,columns:[1]}]}},Ii={container:"micromag-screen-gallery-container",background:"micromag-screen-gallery-background",content:"micromag-screen-gallery-content",inner:"micromag-screen-gallery-inner",grid:"micromag-screen-gallery-grid",placeholder:"micromag-screen-gallery-placeholder",emptyImage:"micromag-screen-gallery-emptyImage",emptyCaption:"micromag-screen-gallery-emptyCaption",gridItem:"micromag-screen-gallery-gridItem",imageContainer:"micromag-screen-gallery-imageContainer",header:"micromag-screen-gallery-header",footer:"micromag-screen-gallery-footer",image:"micromag-screen-gallery-image",caption:"micromag-screen-gallery-caption"},Pi=[];function Bi(e){var t=e.layout,l=void 0===t?"four-mosaic":t,n=e.images,r=void 0===n?Pi:n,s=e.withCaptions,u=void 0!==s&&s,d=e.imageCaptionStyle,c=void 0===d?null:d,m=e.background,v=void 0===m?null:m,g=e.header,y=void 0===g?null:g,f=e.footer,p=void 0===f?null:f,b=e.current,x=void 0===b||b,A=e.active,S=void 0===A||A,C=e.preload,w=void 0===C||C,k=e.spacing,j=void 0===k?20:k,M=e.captionMaxLines,N=void 0===M?2:M,F=e.className,T=void 0===F?null:F,z=It(),$=z.width,L=z.height,I=z.resolution,P=Ot(),B=P.topHeight,E=P.bottomHeight,V=P.bottomSidesWidth,D=qt().open,O=jt().muted,H=Mt(x,!0),Z=H.ref,W=H.isCurrent,q=void 0!==W&&W,_=null!==j?Math.max(0,j||0):20,G=Rt(),Y=G.isView,U=G.isPreview,Q=G.isPlaceholder,X=G.isEdit,J=x&&(Y||X)&&(q||!Y),K=x||w,ee=Q?5:_,te=Ti(Li[l])?Li[l]:{},le=te.layout,ae=void 0===le?[]:le,ne=te.vertical,ie=void 0!==ne&&ne,oe=ae.reduce(function(e,t){var l=t.rows,a=t.columns;return e+(ie?l:a).length},0),re=(0,a.useState)(0),ue=(0,R.A)(re,2),de=ue[0],ce=ue[1],me=de>=(null!==r?Math.min(oe,r.length):0),ve=(0,a.useCallback)(function(){ce(function(e){return e+1})},[ce]),ge=(0,a.useRef)([]),ye=(0,a.useState)([]),he=(0,R.A)(ye,2),fe=he[0],pe=he[1],be=pl(),xe=be.ref,Ae=be.width,Se=void 0===Ae?null:Ae,Ce=be.height,we=void 0===Ce?null:Ce;(0,a.useEffect)(function(){ge.current.length&&pe(ge.current.map(function(e){return null!==e?{width:e.offsetWidth,height:e.offsetHeight}:{}}))},[Se,we,l,pe]);var ke=Ge(y),je=Ye(p),Me=ze(p,{isView:Y,current:x,openWebView:D,isPreview:U}),Ne=pl(),Fe=Ne.ref,Te=Ne.height,Re=void 0===Te?0:Te,$e=pl(),Le=$e.ref,Ie=$e.height,Pe=void 0===Ie?0:Ie,Be=(0,o.A)(Array(oe)).map(function(e,t){var l=null!==r?r[t]:null,a=fe[t]||{},n=u?l:{media:l},o=(n||{}).caption,s=void 0===o?null:o,d=Qe(n),m=Je(s),v=(s||{}).textStyle,g=void 0===v?null:v;return(0,se.jsxs)("div",{className:Ii.gridItem,children:[(0,se.jsx)("div",{className:Ii.imageContainer,ref:function(e){ge.current[t]=e},children:(0,se.jsx)(Qa,{placeholder:"image",placeholderProps:{className:Ii.placeholder,height:"100%"},emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:Ii.emptyImage,isEmpty:!d,children:S||x?(0,se.jsx)(Nn,(0,i.A)((0,i.A)((0,i.A)({className:Ii.image},n),a),{},{loadingMode:"lazy",resolution:I,objectFit:{fit:"cover"},playing:J,active:S,shouldLoad:K,withoutVideo:U,onLoaded:ve})):null})}),u?(0,se.jsx)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"6tIigB",defaultMessage:[{type:0,value:"Caption"}]}),emptyClassName:Ii.emptyCaption,isEmpty:!m,children:(0,se.jsx)("div",{className:Ii.caption,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},s),{},{className:Ii.captionText,lineClamp:N,textStyle:(0,i.A)((0,i.A)({},c||null),g)}))})}):null]},"item-".concat(t))});return(0,se.jsxs)("div",{className:Jt([Ii.container,T,(0,h.A)({},Ii.isPlaceholder,Q)]),"data-screen-ready":me,children:[(0,se.jsx)(An,{width:$,height:L,className:Ii.content,children:(0,se.jsxs)("div",{className:Ii.inner,style:{paddingTop:(ke?Re:0)+(U?0:B),paddingBottom:(je?Pe:0)+(x&&!U?E:0)},ref:xe,children:[!Q&&ke?(0,se.jsx)("div",{className:Ii.header,ref:Fe,style:{paddingTop:ke?ee/2:_,paddingLeft:_,paddingRight:_,transform:U?null:"translate(0, ".concat(B,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},y))}):null,(0,se.jsx)(Ri,(0,i.A)({className:Ii.grid,spacing:ee,items:Be},te)),!Q&&je?(0,se.jsx)("div",{className:Ii.footer,ref:Le,style:{paddingLeft:Math.max(ee/2,V),paddingRight:Math.max(ee/2,V),paddingBottom:ee/2,transform:U?null:"translate(0, -".concat(E,"px)")},children:(0,se.jsx)(Dn,(0,i.A)({},Me))}):null]})}),Q?null:(0,se.jsx)(pn,{background:v,width:$,height:L,resolution:I,playing:J,muted:O,shouldLoad:K,mediaRef:Z,withoutVideo:U,className:Ii.background})]})}var Ei=[{id:"gallery",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"jaFXki",defaultMessage:[{type:0,value:"Gallery"}]}),component:Bi,layouts:["two-vertical-equal","two-vertical-top","two-vertical-bottom","three-vertical","one-two","two-one","two-by-two","four-vertical","one-two-one","four-mosaic","two-one-two","one-two-two","two-two-one","two-by-three","one-one-two-two","two-two-one-one"],fields:[{name:"layout",type:"screen-layout",defaultValue:"two-vertical-equal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"images",type:"visuals",label:(0,ue.zR)({id:"muYwrB",defaultMessage:[{type:0,value:"Images"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"gallery-captions",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"MmJQ7o",defaultMessage:[{type:0,value:"Gallery with captions"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(Bi,(0,i.A)((0,i.A)({},t),{},{withCaptions:!0}))},layouts:["two-vertical-equal","two-vertical-top","two-vertical-bottom","three-vertical","one-two","two-one","two-by-two","four-vertical","one-two-one","four-mosaic","two-one-two","one-two-two","two-two-one","two-by-three","one-one-two-two","two-two-one-one"],fields:[{name:"layout",type:"screen-layout",defaultValue:"two-vertical-equal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"images",type:"visuals-with-caption",theme:{caption:{textStyle:"text"}},label:(0,ue.zR)({id:"59f2bg",defaultMessage:[{type:0,value:"Images"}]})},{name:"imageCaptionStyle",type:"text-style-form",label:(0,ue.zR)({id:"Qz7nUz",defaultMessage:[{type:0,value:"Caption style"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],Vi={container:"micromag-screen-gallery-feed-container",background:"micromag-screen-gallery-feed-background",content:"micromag-screen-gallery-feed-content",emptyImage:"micromag-screen-gallery-feed-emptyImage",emptyCaption:"micromag-screen-gallery-feed-emptyCaption",image:"micromag-screen-gallery-feed-image",imageContainer:"micromag-screen-gallery-feed-imageContainer",video:"micromag-screen-gallery-feed-video",footer:"micromag-screen-gallery-feed-footer",disabled:"micromag-screen-gallery-feed-disabled",caption:"micromag-screen-gallery-feed-caption",isPlaceholder:"micromag-screen-gallery-feed-isPlaceholder",layout:"micromag-screen-gallery-feed-layout"};function Di(e){var t=e.layout,l=void 0===t?"normal":t,n=e.images,r=void 0===n?null:n,s=e.withCaptions,u=void 0!==s&&s,d=e.imageCaptionStyle,c=void 0===d?null:d,m=e.spacing,v=void 0===m?20:m,g=e.background,y=void 0===g?null:g,f=e.header,p=void 0===f?null:f,b=e.footer,x=void 0===b?null:b,A=e.current,S=void 0===A||A,C=e.active,w=void 0===C||C,k=e.preload,j=void 0===k||k,M=e.type,N=void 0===M?null:M,F=e.className,T=void 0===F?null:F,z=$l(N),$=It(),L=$.width,I=$.height,P=$.resolution,B=Ot(),E=B.topHeight,V=B.bottomHeight,D=B.bottomSidesWidth,O=qt().open,H=jt().muted,Z=Mt(S,!0),W=Z.ref,q=Z.isCurrent,_=void 0!==q&&q,G=null!==v?Math.max(0,v||0):20,Y=Rt(),U=Y.isView,Q=Y.isPreview,X=Y.isPlaceholder,J=Y.isEdit,K=Y.isStatic,ee=Y.isCapture,te=S&&(U||J)&&(_||!U),le=S||j,ae=null!==r?r.length:0,ne=(0,a.useState)(0),ie=(0,R.A)(ne,2),oe=ie[0],re=ie[1],ue=oe>=ae,de=!J&&(K||ee||X||Q||J)||!S,ce=(0,a.useCallback)(function(){re(oe+1)},[oe,re]),me="reverse"===l,ve=[],ge=J&&0===ae?[null]:r,ye=X?(0,o.A)(Array(5)):ge,he=pl(),fe=he.ref,pe=he.width;(ye||[]).forEach(function(e,t){var l=u?e:{media:e},a=(l||{}).caption,n=void 0===a?null:a,o=Qe(l),r=Je(n),s=(n||{}).textStyle,d=void 0===s?null:s,m=(0,se.jsx)(Qa,{placeholder:"image",emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:Vi.emptyImage,isEmpty:!o,children:(0,se.jsx)("div",{className:Vi.imageContainer,ref:0===t?fe:null,children:(0,se.jsx)(Nn,(0,i.A)((0,i.A)({},l),{},{loadingMode:"lazy",className:Vi.image,videoClassName:Vi.video,width:pe,resolution:P,playing:te,active:w,shouldLoad:le,withoutVideo:Q,onLoaded:ce}))})},"image-".concat(t)),v=null;if(u){var g=!me||t>0?G/2:0,y=me||t<(ye||[]).length-1?G/2:0;v=(0,se.jsx)(Qa,{placeholder:"text",placeholderProps:{lines:2},emptyLabel:(0,se.jsx)(Wl.A,{id:"6tIigB",defaultMessage:[{type:0,value:"Caption"}]}),emptyClassName:Vi.emptyCaption,isEmpty:!r,children:r?(0,se.jsx)("div",{className:Vi.caption,style:{marginTop:g,marginBottom:y},children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},n),{},{textStyle:(0,i.A)((0,i.A)({},c||null),d),className:Vi.captionText}))}):null},"caption-".concat(t))}me?(u&&ve.push(v),ve.push(m)):(ve.push(m),u&&ve.push(v)),!X&&t<(ye||[]).length-1&&ve.push((0,se.jsx)("div",{style:{height:G}},"spacing-".concat(t)))});var be=Ge(p),xe=Ye(x),Ae=ze(x,{isView:U,current:S,openWebView:O,isPreview:Q}),Se=(0,a.useState)(!1),Ce=(0,R.A)(Se,2),we=Ce[0],ke=Ce[1],je=(0,a.useCallback)(function(e){e.initial&&z("scroll","Screen"),ke(!0)},[z]),Me=(0,a.useCallback)(function(){ke(!1)},[ke]),Ne=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);z("scroll",t,{scrollPercent:t})}},[z]);return(0,se.jsxs)("div",{className:Jt([Vi.container,T,(0,h.A)({},Vi.isPlaceholder,X)]),"data-screen-ready":ue,children:[(0,se.jsx)(An,{width:L,height:I,className:Vi.content,children:(0,se.jsx)(ei,{disabled:de,onScrolledTrigger:Ne,onScrolledBottom:je,onScrolledNotBottom:Me,withShadow:!0,children:(0,se.jsxs)(Qn,{className:Vi.layout,style:X?null:{padding:G,paddingTop:(Q?0:E)+(be?G/2:G),paddingBottom:(S&&!Q?V:0)+G/2},children:[!X&&be?(0,se.jsx)("div",{style:{paddingBottom:G},children:(0,se.jsx)(Zn,(0,i.A)({},p))},"header"):null,ve,!X&&xe?(0,se.jsx)("div",{className:Jt([Vi.footer,(0,h.A)({},Vi.disabled,!we)]),style:{paddingLeft:Math.max(D-G,0),paddingRight:Math.max(D-G,0),paddingTop:G},children:(0,se.jsx)(Dn,(0,i.A)({},Ae))}):null]})})}),X?null:(0,se.jsx)(pn,{background:y,width:L,height:I,resolution:P,playing:te,muted:H,shouldLoad:le,mediaRef:W,withoutVideo:Q,className:Vi.background})]})}var Oi=[{id:"gallery-feed",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"4bHvRS",defaultMessage:[{type:0,value:"Gallery Feed"}]}),component:Di,layouts:["normal"],fields:[{name:"images",type:"visuals",label:(0,ue.zR)({id:"muYwrB",defaultMessage:[{type:0,value:"Images"}]})},{name:"spacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Zpl5bJ",defaultMessage:[{type:0,value:"Spacing"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"gallery-feed-captions",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"XTJGzY",defaultMessage:[{type:0,value:"Gallery feed with captions"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(Di,(0,i.A)((0,i.A)({},t),{},{withCaptions:!0}))},layouts:["normal","reverse"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"images",type:"visuals-with-caption",theme:{caption:{textStyle:"text"}},label:(0,ue.zR)({id:"T9NZPQ",defaultMessage:[{type:0,value:"Images"}]})},{name:"spacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Zpl5bJ",defaultMessage:[{type:0,value:"Spacing"}]})},{name:"imageCaptionStyle",type:"text-style-form",label:(0,ue.zR)({id:"Qz7nUz",defaultMessage:[{type:0,value:"Caption style"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],Hi=l(938),Zi={container:"micromag-screen-game-sort-container",background:"micromag-screen-game-sort-background",content:"micromag-screen-game-sort-content",heading:"micromag-screen-game-sort-heading",layout:"micromag-screen-game-sort-layout",emptyHeading:"micromag-screen-game-sort-emptyHeading",emptyItems:"micromag-screen-game-sort-emptyItems",header:"micromag-screen-game-sort-header",footer:"micromag-screen-game-sort-footer",items:"micromag-screen-game-sort-items",item:"micromag-screen-game-sort-item",itemInner:"micromag-screen-game-sort-itemInner",thumbnail:"micromag-screen-game-sort-thumbnail",sorted:"micromag-screen-game-sort-sorted",draggable:"micromag-screen-game-sort-draggable",button:"micromag-screen-game-sort-button",buttonLabel:"micromag-screen-game-sort-buttonLabel",buttonResults:"micromag-screen-game-sort-buttonResults",label:"micromag-screen-game-sort-label",isEmpty:"micromag-screen-game-sort-isEmpty",valid:"micromag-screen-game-sort-valid",invalid:"micromag-screen-game-sort-invalid",resultsVisible:"micromag-screen-game-sort-resultsVisible",layoutLabelTop:"micromag-screen-game-sort-layoutLabelTop",layoutNoLabel:"micromag-screen-game-sort-layoutNoLabel",layoutLabelOver:"micromag-screen-game-sort-layoutLabelOver",buttonVisual:"micromag-screen-game-sort-buttonVisual",submitButton:"micromag-screen-game-sort-submitButton",results:"micromag-screen-game-sort-results"},Wi={id:"game-sort",type:"screen",group:{label:(0,ue.zR)({id:"w3+kFW",defaultMessage:[{type:0,value:"Game"}]}),order:12},title:(0,ue.zR)({id:"eJMcXw",defaultMessage:[{type:0,value:"Sort game"}]}),component:function(e){var t=e.layout,l=void 0===t?"top":t,n=e.heading,r=void 0===n?null:n,s=e.items,u=void 0===s?null:s,d=e.spacing,c=void 0===d?20:d,m=e.itemsLayout,v=void 0===m?"label-bottom":m,y=e.itemsBoxStyle,f=void 0===y?null:y,p=e.itemsTextStyle,b=void 0===p?null:p,x=e.itemsResultsTextStyle,A=void 0===x?null:x,S=e.validBoxStyle,C=void 0===S?null:S,w=e.invalidBoxStyle,k=void 0===w?null:w,j=e.submitBoxStyle,M=void 0===j?null:j,N=e.submitTextStyle,F=void 0===N?null:N,T=e.submitButtonLabel,z=void 0===T?null:T,$=e.results,L=void 0===$?null:$,I=e.resultsBoxStyle,P=void 0===I?null:I,B=e.background,E=void 0===B?null:B,V=e.header,D=void 0===V?null:V,O=e.footer,H=void 0===O?null:O,Z=e.current,W=void 0===Z||Z,q=e.active,_=void 0===q||q,G=e.className,Y=void 0===G?null:G,U=(0,Zl.A)(),Q=It(),X=Q.width,J=Q.height,K=Q.resolution,ee=Rt(),te=ee.isView,le=ee.isPreview,ae=ee.isPlaceholder,ne=ee.isEdit,ie=Ot(),oe=ie.topHeight,re=ie.bottomHeight,ue=ie.bottomSidesWidth,de=qt().open,ce=jt().muted,me=Mt(W,!0),ve=me.ref,ge=me.isCurrent,ye=W&&(te||ne)&&(void 0!==ge&&ge||!te),he=W||_,fe=Ge(D),pe=Ye(H),be=ze(H,{isView:te,current:W,openWebView:de,isPreview:le}),xe=pl(),Ae=xe.ref,Se=xe.height,Ce=void 0===Se?0:Se,we=pl(),ke=we.ref,je=we.height,Me=void 0===je?0:je,Ne=pl(),Fe=Ne.ref,Te=Ne.height,Re=void 0===Te?0:Te,$e=te,Le=$l("game-sort"),Ie=(0,a.useMemo)(function(){return(u||[]).map(function(e,t){return(0,i.A)({id:"item-".concat(t)},e)})},[u]),Pe=te,Be=(0,a.useState)(Pe?Hi(Ie||[]):Ie||[]),Ee=(0,R.A)(Be,2),De=Ee[0],Oe=Ee[1],Ze=(0,a.useRef)(De),We=(0,a.useRef)(Ie),qe=(0,a.useRef)({}),_e=(0,a.useState)(!1),Ue=(0,R.A)(_e,2),Qe=Ue[0],Xe=Ue[1],Je=(0,a.useState)(null),Ke=(0,R.A)(Je,2),et=Ke[0],tt=Ke[1],lt=(0,a.useRef)(De),at=(0,a.useState)(!1),nt=(0,R.A)(at,2),it=nt[0],ot=nt[1],rt=te&&_&&W&&null===et;(0,a.useEffect)(function(){if(We.current!==Ie&&!te){var e=Pe?Hi(Ie||[]):Ie||[];Oe(e),Ze.current=e,We.current=Ie}},[Ie]);var st=(0,a.useCallback)(function(e,t,l){var a=e.findIndex(function(e){return e===t}),n=(0,o.A)(e),i=n[l];return n[l]=t,n[a]=i,n},[]),ut=(0,a.useCallback)(function(e,t){var l=st(De,e,t);Oe(l),Ze.current=l},[De,st]),dt=(0,oa.mX)((Ie||[]).length,function(){return{y:"0%",scale:1}},[]),ct=(0,R.A)(dt,2),mt=ct[0],vt=ct[1],gt=(0,a.useCallback)(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.dragItem,a=t.dragY,n=t.initial,i=void 0!==n&&n,o=e.map(function(e){return qe.current[e.id]||null}),r=(Ie||[]).map(function(e){return qe.current[e.id]||null}).map(function(e){var t;return(null==e||null===(t=e.getBoundingClientRect())||void 0===t?void 0:t.height)||0}),s=o.map(function(e){var t;return(null==e||null===(t=e.getBoundingClientRect())||void 0===t?void 0:t.height)||0});vt.start(function(t){var n=(Ie||[])[t]||null,o=e.findIndex(function(e){return e.id===n.id}),u=r[t]||0,d=r.slice(0,t).reduce(function(e,t){return e+t},0);if(n===l)return{y:"".concat((a-d)/u*100,"%"),scale:1.02,immediate:!0};var c=s.slice(0,o).reduce(function(e,t){return e+t},0);return{y:"".concat((c-d)/u*100,"%"),scale:1,immediate:i}}),i&&Xe(!0)},[vt]);(0,a.useEffect)(function(){te&>(De,{initial:lt.current===De})},[De,Re]);var yt=(0,Xt.useDrag)(function(e){var t=(0,R.A)(e.args,1)[0],l=e.active,a=(0,R.A)(e.movement,2)[1],n=e.tap,i=Ie[t]||{};if(n){var o=De.findIndex(function(e){return e===i}),r=0===o?De.length-1:o-1;return ut(i,r),void($e&&Le("tap","item_".concat(t)))}var s=De.findIndex(function(e){return e===i}),u=De.map(function(e){return qe.current[e.id]||null}).map(function(e){var t;return(null==e||null===(t=e.getBoundingClientRect())||void 0===t?void 0:t.height)||0}),d=u.map(function(e,t){var l=e+u.slice(0,t).reduce(function(e,t){return e+t},0);return{isStart:0===t,isEnd:t===u.length-1,start:l-e,end:l}}),c=d[s].end-u[s]/2+a,m=d.findIndex(function(e){var t=e.isStart,l=e.isEnd,a=e.start,n=e.end;return(t||c>=a)&&(l||c<n)});if(l){var v=st(Ze.current,i,m);Ze.current=v,gt(v,{dragItem:i,dragY:d[s].start+a})}else Oe(Ze.current),$e&&Le("drag","item_".concat(t))},{axis:"y",preventDefault:!0,filterTaps:!0,enabled:rt}),ht=(0,a.useCallback)(function(){var e=Ie.map(function(e,t){return t===De.findIndex(function(t){return t===e})});tt(e);var t=e.reduce(function(e,t){return e&&t},!0),l=e.filter(function(e){return!e}).length;$e&&Le("submit",t?"valid":"invalid_".concat(l))},[Ie,De,$e,Le]);return(0,a.useEffect)(function(){if(null===et)return function(){};var e=setTimeout(function(){Oe(Ie),ot(!0)},1e3);return function(){clearTimeout(e)}},[et]),(0,se.jsxs)("div",{className:Jt([Zi.container,Y,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Zi.sorted,Qe||!te),Zi.draggable,rt),Zi.resultsVisible,it),Zi.isPlaceholder,ae)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:X,height:J,className:Zi.content,children:(0,se.jsxs)(Qn,{className:Zi.layout,verticalAlign:l,fullscreen:!0,style:ae?null:{padding:c,paddingTop:(le?0:oe)+(Ce||c),paddingBottom:(W&&!le?re:0)+(Me||c)},children:[!ae&&fe?(0,se.jsx)("div",{className:Zi.header,ref:Ae,style:{paddingTop:c/2,paddingBottom:c,paddingLeft:c,paddingRight:c,transform:"translate(0px, ".concat(oe,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},D))}):null,(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"X7kRRa",defaultMessage:[{type:0,value:"Heading"}]}),emptyClassName:Zi.emptyHeading,isEmpty:!r||""===(null==r?void 0:r.body),children:r?(0,se.jsx)(_n,(0,i.A)({className:Jt([Zi.heading])},r)):null},"title"),(0,se.jsxs)("div",{className:Zi.items,ref:Fe,children:[(0,se.jsx)(Un,{size:5},"spacer"),(0,se.jsx)(Qa,{placeholder:"items",emptyLabel:(0,se.jsx)(Wl.A,{id:"03U69o",defaultMessage:[{type:0,value:"Buttons"}]}),emptyClassName:Zi.emptyItems,isEmpty:0===(Ie||[]).length,children:mt.map(function(e,t){var l=e.y,a=e.scale,n=Ie[t]||{}||{},o=n.id,r=void 0===o?null:o,s=n.visual,u=void 0===s?null:s,d=n.label,c=n.boxStyle,m=void 0===c?null:c,y=n.results,p=void 0===y?null:y,x=g(d)?{body:d}:d||{},S=x||{},w=S.body,j=void 0===w?null:w,M=S.textStyle,N=null===j&&null===u,F=null!==et&&et[t];return(0,se.jsx)(oa.CS.div,(0,i.A)((0,i.A)({className:Jt([Zi.item,(0,h.A)((0,h.A)((0,h.A)({clickable:rt},Zi.isEmpty,N),Zi.valid,null!==et&&F),Zi.invalid,null!==et&&!F)]),ref:function(e){qe.current[r]=e},style:(0,i.A)((0,i.A)({transform:l.to(function(e){return"translateY(".concat(e,")")})},He(b)),He(M))},yt(t)),{},{children:(0,se.jsx)("div",{className:Zi.itemInner,children:(0,se.jsxs)(oa.CS.div,{className:Jt([Zi.button,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Zi.layoutLabelBottom,"label-bottom"===v),Zi.layoutLabelTop,"label-top"===v),Zi.layoutNoLabel,"no-label"===v),Zi.layoutLabelOver,"label-over"===v)]),style:(0,i.A)((0,i.A)((0,i.A)((0,i.A)({transform:a.to(function(e){return"scale(".concat(e,")")})},Ve(f)),Ve(m)),Ve(et&&F?C:null)),Ve(et&&!F?k:null)),children:[null!==u?(0,se.jsx)(Nn,{className:Zi.buttonVisual,imageClassName:Zi.thumbnail,media:u,width:"auto"}):null,null!==j||null!==p&&it?(0,se.jsxs)("div",{className:Zi.buttonLabel,children:[null!==j?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},x),{},{textStyle:(0,i.A)((0,i.A)({},b),M),className:Zi.label})):null,null!==p&&it?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},p),{},{className:Zi.buttonResults,textStyle:(0,i.A)((0,i.A)({},A),p.textStyle)})):null]}):null]})})}),"button-".concat(t))})},"items")]}),it&&null!==L?(0,se.jsx)("div",{className:Zi.results,style:(0,i.A)({},Ve(P)),children:(0,se.jsx)(nn,(0,i.A)({},L))}):ae?null:(0,se.jsx)(zn,{className:Zi.submitButton,disabled:null!==et,type:"button",onClick:ht,style:(0,i.A)((0,i.A)({},Ve(M)),He(F)),children:z||U.formatMessage({id:"IbZVf0",defaultMessage:[{type:0,value:"Submit"}]})}),!ae&&pe?(0,se.jsx)("div",{className:Zi.footer,ref:ke,style:{paddingTop:c,paddingBottom:c/2,paddingLeft:Math.max(ue-c,0),paddingRight:Math.max(ue-c,0)},children:(0,se.jsx)(Dn,(0,i.A)({},be))}):null]})}),ae?null:(0,se.jsx)(pn,{background:E,width:X,height:J,resolution:K,playing:ye,muted:ce,shouldLoad:he,mediaRef:ve,withoutVideo:le,className:Zi.background})]})},layouts:["top","middle","bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"middle",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"heading",type:"heading-element",label:(0,ue.zR)({id:"wx5PI0",defaultMessage:[{type:0,value:"Heading"}]})},{name:"items",type:"game-sort-items",label:(0,ue.zR)({id:"fbUW2U",defaultMessage:[{type:0,value:"Items"}]}),isSection:!0},{label:(0,ue.zR)({id:"83959F",defaultMessage:[{type:0,value:"Items style"}]}),type:"fields",isList:!0,isSection:!0,fields:[{name:"itemsLayout",type:"button-layout",label:(0,ue.zR)({id:"OPxJx/",defaultMessage:[{type:0,value:"Layout"}]})},{name:"itemsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"rzXCu2",defaultMessage:[{type:0,value:"Label style"}]})},{name:"resultsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"ex1Bgx",defaultMessage:[{type:0,value:"Results style"}]})},{name:"itemsBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"p1pghO",defaultMessage:[{type:0,value:"Box style"}]})},{name:"validBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"ao5VYd",defaultMessage:[{type:0,value:"Valid box style"}]})},{name:"invalidBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"JLYWNN",defaultMessage:[{type:0,value:"Invalid box style"}]})}]},{label:(0,ue.zR)({id:"WjigmA",defaultMessage:[{type:0,value:"Submit button"}]}),type:"fields",isList:!0,isSection:!0,fields:[{name:"submitButtonLabel",type:"text",label:(0,ue.zR)({id:"Cg3LGu",defaultMessage:[{type:0,value:"Label"}]})},{name:"submitBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"nno1Pq",defaultMessage:[{type:0,value:"Button style"}]})},{name:"submitTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"OEckOD",defaultMessage:[{type:0,value:"Text style"}]})}]},{label:(0,ue.zR)({id:"jINZkT",defaultMessage:[{type:0,value:"Results"}]}),type:"fields",isList:!0,isSection:!0,fields:[{name:"results",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZMS1Wv",defaultMessage:[{type:0,value:"Text"}]})},{name:"resultsBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"p1pghO",defaultMessage:[{type:0,value:"Box style"}]})}]},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},qi={container:"micromag-screen-image-container",background:"micromag-screen-image-background",content:"micromag-screen-image-content",emptyImage:"micromag-screen-image-emptyImage",emptyTitle:"micromag-screen-image-emptyTitle",emptyText:"micromag-screen-image-emptyText",emptyLegend:"micromag-screen-image-emptyLegend",imageContainer:"micromag-screen-image-imageContainer",image:"micromag-screen-image-image",placeholderImage:"micromag-screen-image-placeholderImage",isPlaceholder:"micromag-screen-image-isPlaceholder",layout:"micromag-screen-image-layout",isCard:"micromag-screen-image-isCard",isCardReverse:"micromag-screen-image-isCardReverse",footer:"micromag-screen-image-footer",isFullscreen:"micromag-screen-image-isFullscreen",header:"micromag-screen-image-header"};function _i(e){var t=e.layout,l=void 0===t?"normal":t,n=e.image,o=void 0===n?null:n,r=e.imageFit,s=void 0===r?null:r,u=e.defaultImageFit,d=void 0===u?"cover":u,c=e.title,m=void 0===c?null:c,v=e.text,g=void 0===v?null:v,y=e.legend,f=void 0===y?null:y,p=e.withTitle,b=void 0!==p&&p,x=e.withText,A=void 0!==x&&x,S=e.withLegend,C=void 0!==S&&S,w=e.spacing,k=void 0===w?20:w,j=e.background,M=void 0===j?null:j,N=e.header,F=void 0===N?null:N,T=e.footer,z=void 0===T?null:T,$=e.current,L=void 0===$||$,I=e.active,P=void 0===I||I,B=e.preload,E=void 0===B||B,V=e.className,D=void 0===V?null:V,O=It(),H=O.width,Z=O.height,W=O.resolution,q=Rt(),_=q.isView,G=q.isPreview,Y=q.isPlaceholder,U=q.isEdit,Q=Ot(),X=Q.topHeight,J=Q.bottomHeight,K=Q.bottomSidesWidth,ee=qt().open,te=jt().muted,le=Mt(L,!0),ae=le.ref,ne=le.isCurrent,ie=void 0!==ne&&ne,oe=Ge(F),re=Ye(z),ue=ze(z,{isView:_,current:L,openWebView:ee,isPreview:G}),de=null!==o,ce=Je(m),me=Je(g),ve=Je(f),ge=(0,a.useState)(!de),ye=(0,R.A)(ge,2),he=ye[0],fe=ye[1],pe=L&&(_||U)&&(ie||!_),be=L||E,xe=(0,a.useCallback)(function(){fe(!0)},[fe]),Ae=(0,a.useMemo)(function(){return{fit:s||d}},[s,d]),Se="reverse"===l||"card-reverse"===l,Ce="title-top"===l,we="card"===l||"card-reverse"===l,ke="card"===l,je="card-reverse"===l,Me="fullscreen"===l,Ne=Me||Y?0:k,Fe=pl(),Te=Fe.ref,Re=Fe.width,$e=Fe.height,Le=je?"".concat(Ne/2,"px ").concat(-Ne/2,"px 0"):"0 ".concat(-Ne/2,"px ").concat(Ne/2,"px"),Ie=we?Le:Ne/2,Pe=Y?null:{margin:Ne/2,marginTop:je&&!oe?Ne:Ne/2,marginBottom:ke&&!oe?Ne:Ne/2},Be=[(0,se.jsx)("div",{ref:Te,className:qi.imageContainer,style:Y?null:{margin:Ie},children:(0,se.jsx)(Qa,{placeholder:"image",placeholderProps:{className:qi.placeholderImage,height:"100%"},emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:qi.emptyImage,isEmpty:!de,children:de?(0,se.jsx)(Nn,{className:qi.image,media:o,objectFit:Ae,width:Re,height:$e,resolution:W,playing:pe,muted:te,active:P,shouldLoad:be,withoutVideo:G,onLoaded:xe}):null})},"image"),b&&(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:qi.emptyTitle,isEmpty:!ce,children:ce?(0,se.jsx)("div",{style:Pe,children:(0,se.jsx)(_n,(0,i.A)({},m))}):null},"title"),A&&(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"z4CiV1",defaultMessage:[{type:0,value:"Text"}]}),emptyClassName:qi.emptyText,isEmpty:!me,children:me?(0,se.jsx)("div",{style:Pe,children:(0,se.jsx)(nn,(0,i.A)({},g))}):null},"text"),C&&(0,se.jsx)(Qa,{placeholder:"shortText",emptyLabel:(0,se.jsx)(Wl.A,{id:"dqnkQk",defaultMessage:[{type:0,value:"Legend"}]}),emptyClassName:qi.emptyLegend,isEmpty:!ve,children:ve?(0,se.jsx)("div",{style:Pe,children:(0,se.jsx)(nn,(0,i.A)({},f))}):null},"legend")];Se?Be.reverse():Ce&&b&&(ce||Y)&&Be.splice(0,0,Be.splice(1,1)[0]);var Ee=(L&&!G?J:0)+Ne/2,Ve=(G?0:X)+Ne/2;return(we||Me)&&(Ve=0,Ee=0),je&&(Ve=L&&!G?X:0,Ee=L&&!G?J:0),(0,se.jsxs)("div",{className:Jt([qi.container,D,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},qi.isReversed,Se),qi.isPlaceholder,Y),qi.isCard,ke),qi.isCardReverse,je),qi.isFullscreen,Me)]),"data-screen-ready":he,children:[(0,se.jsx)(An,{width:H,height:Z,className:qi.content,children:(0,se.jsxs)(Qn,{className:qi.layout,fullscreen:!0,style:Y?null:{padding:Ne/2,paddingTop:Ve,paddingBottom:Ee},children:[!Y&&oe?(0,se.jsx)("div",{className:qi.header,style:Me||je?{paddingTop:oe?k/2:k,paddingBottom:oe?k/2:k,paddingLeft:je?k/2:k,paddingRight:je?k/2:k,transform:G?null:"translate(0, ".concat(X,"px)")}:{paddingTop:we?k/2:null,paddingBottom:we?k:k/2,paddingLeft:k/2,paddingRight:k/2},children:(0,se.jsx)(Zn,(0,i.A)({},F))}):null,Be,!Y&&re?(0,se.jsx)("div",{className:qi.footer,style:Me||je?{paddingLeft:Math.max(k/2,K),paddingRight:Math.max(k/2,K),paddingTop:k/2,paddingBottom:k/2,transform:G?null:"translate(0, -".concat(J,"px)")}:{paddingLeft:Math.max(K-k,0),paddingRight:Math.max(K-k,0),paddingTop:we?k/2:null,paddingBottom:we?k/2:null},children:(0,se.jsx)(Dn,(0,i.A)({},ue))}):null]})}),Y?null:(0,se.jsx)(pn,{background:M,width:H,height:Z,resolution:W,playing:pe,muted:te,shouldLoad:be,mediaRef:ae,withoutVideo:G,className:qi.background})]})}var Gi=[{id:"image",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"uJ9eBc",defaultMessage:[{type:0,value:"Image"}]}),component:_i,layouts:["normal","fullscreen"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"image",type:"visual",label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"imageFit",type:"fit",defaultValue:"cover",values:["cover","contain"],label:(0,ue.zR)({id:"dkBBRa",defaultMessage:[{type:0,value:"Image fit"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"image-title",type:"screen",group:{label:(0,ue.zR)({id:"S/mavZ",defaultMessage:[{type:0,value:"Text and Images"}]}),order:3},title:(0,ue.zR)({id:"AA8TV9",defaultMessage:[{type:0,value:"Image with title"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(_i,(0,i.A)((0,i.A)({},t),{},{withTitle:!0}))},layouts:["normal","reverse","card","card-reverse"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"image",type:"visual",label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"imageFit",type:"fit",defaultValue:"cover",values:["cover","contain"],label:(0,ue.zR)({id:"dkBBRa",defaultMessage:[{type:0,value:"Image fit"}]})},{name:"title",type:"heading-element",inline:!0,theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"image-text",type:"screen",group:{label:(0,ue.zR)({id:"S/mavZ",defaultMessage:[{type:0,value:"Text and Images"}]}),order:3},title:(0,ue.zR)({id:"CJmQeh",defaultMessage:[{type:0,value:"Image with text"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(_i,(0,i.A)((0,i.A)({},t),{},{withText:!0}))},layouts:["normal","reverse","card","card-reverse"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"image",type:"visual",label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"imageFit",type:"fit",defaultValue:"cover",values:["cover","contain"],label:(0,ue.zR)({id:"dkBBRa",defaultMessage:[{type:0,value:"Image fit"}]})},{name:"text",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"image-title-text",type:"screen",group:{label:(0,ue.zR)({id:"S/mavZ",defaultMessage:[{type:0,value:"Text and Images"}]}),order:3},title:(0,ue.zR)({id:"eWIM/8",defaultMessage:[{type:0,value:"Image with title and text"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(_i,(0,i.A)((0,i.A)({},t),{},{withTitle:!0,withText:!0}))},layouts:["normal","reverse","title-top","card","card-reverse"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"image",type:"visual",isHorizontal:!1,label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"imageFit",type:"fit",defaultValue:"cover",values:["cover","contain"],label:(0,ue.zR)({id:"dkBBRa",defaultMessage:[{type:0,value:"Image fit"}]})},{name:"title",type:"text-element",inline:!0,theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"text",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"image-legend",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:4},title:(0,ue.zR)({id:"H1YcaV",defaultMessage:[{type:0,value:"Image with legend"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(_i,(0,i.A)((0,i.A)({},t),{},{withLegend:!0}))},layouts:["normal","reverse","card","card-reverse"],fields:[{name:"layout",type:"screen-layout",defaultValue:"normal",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"image",type:"visual",label:(0,ue.zR)({id:"xsipID",defaultMessage:[{type:0,value:"Image"}]})},{name:"imageFit",type:"fit",defaultValue:"cover",values:["cover","contain"],label:(0,ue.zR)({id:"dkBBRa",defaultMessage:[{type:0,value:"Image fit"}]})},{name:"legend",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"3OS3Ms",defaultMessage:[{type:0,value:"Legend"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],Yi={inner:"micromag-element-keypad-inner"};function Ui(e){var t=e.items,l=void 0===t?null:t,a=e.align,n=void 0===a?null:a,o=e.columns,r=void 0===o?1:o,s=e.spacing,u=void 0===s?10:s,d=e.className,c=void 0===d?null:d,m=e.itemClassName,v=void 0===m?null:m,g=e.innerClassName,y=void 0===g?null:g,h="".concat(100/r,"%");return(0,se.jsx)("div",{className:Jt([Yi.container,c]),children:(0,se.jsx)("div",{className:Jt([Yi.inner,y]),style:(0,i.A)({},Be({horizontal:n})),children:null!==l?l.map(function(e){var t=(e||{}).key;return(0,se.jsx)("div",{className:Jt([Yi.item,v]),style:{width:h,padding:u/2},children:e},t)}):null})})}var Qi={container:"micromag-screen-keypad-container",isPlaceholder:"micromag-screen-keypad-isPlaceholder",layout:"micromag-screen-keypad-layout",background:"micromag-screen-keypad-background",fixedHeader:"micromag-screen-keypad-fixedHeader",open:"micromag-screen-keypad-open",close:"micromag-screen-keypad-close",closeIcon:"micromag-screen-keypad-closeIcon",header:"micromag-screen-keypad-header",footer:"micromag-screen-keypad-footer",inner:"micromag-screen-keypad-inner",title:"micromag-screen-keypad-title",subtitle:"micromag-screen-keypad-subtitle",emptyTitle:"micromag-screen-keypad-emptyTitle",emptyText:"micromag-screen-keypad-emptyText",grid:"micromag-screen-keypad-grid",item:"micromag-screen-keypad-item",button:"micromag-screen-keypad-button",withSquareItems:"micromag-screen-keypad-withSquareItems",isEmpty:"micromag-screen-keypad-isEmpty",disableHover:"micromag-screen-keypad-disableHover",isLink:"micromag-screen-keypad-isLink",imagePlaceholder:"micromag-screen-keypad-imagePlaceholder",buttonPlaceholder:"micromag-screen-keypad-buttonPlaceholder",buttonLabel:"micromag-screen-keypad-buttonLabel",empty:"micromag-screen-keypad-empty",emptyButtonVisual:"micromag-screen-keypad-emptyButtonVisual",emptyButtonLabel:"micromag-screen-keypad-emptyButtonLabel",popupBackdrop:"micromag-screen-keypad-popupBackdrop",popup:"micromag-screen-keypad-popup",popupButton:"micromag-screen-keypad-popupButton",popupScroll:"micromag-screen-keypad-popupScroll",popupInner:"micromag-screen-keypad-popupInner",withShadow:"micromag-screen-keypad-withShadow",popupContent:"micromag-screen-keypad-popupContent",popupVisualImage:"micromag-screen-keypad-popupVisualImage",popupVisualVideo:"micromag-screen-keypad-popupVisualVideo",placeholder:"micromag-screen-keypad-placeholder",popupHeading:"micromag-screen-keypad-popupHeading",popupVisual:"micromag-screen-keypad-popupVisual",contentSplit:"micromag-screen-keypad-contentSplit",emptyHeading:"micromag-screen-keypad-emptyHeading",emptyVisual:"micromag-screen-keypad-emptyVisual",emptyContent:"micromag-screen-keypad-emptyContent",emptyCTA:"micromag-screen-keypad-emptyCTA",popupCTA:"micromag-screen-keypad-popupCTA",contentBottom:"micromag-screen-keypad-contentBottom"},Xi=[{id:"1"},{id:"2"},{id:"3"},{id:"4"},{id:"5"},{id:"6"},{id:"7"},{id:"8"},{id:"9"}],Ji={padding:{left:30,top:30,right:30,bottom:30}},Ki=[{id:"keypad",type:"screen",group:{label:(0,ue.zR)({id:"cGItoy",defaultMessage:[{type:0,value:"List"}]}),order:4},title:(0,ue.zR)({id:"75nZbY",defaultMessage:[{type:0,value:"Keypad"}]}),layouts:["top","middle","bottom"],component:function(e){var t=e.items,l=void 0===t?null:t,n=e.title,o=void 0===n?null:n,r=e.subtitle,s=void 0===r?null:r,d=e.layout,c=void 0===d?null:d,m=e.spacing,v=void 0===m?20:m,y=e.keypadLayout,f=void 0===y?null:y,p=e.buttonStyles,b=void 0===p?null:p,x=e.popupStyles,A=void 0===x?null:x,S=e.header,C=void 0===S?null:S,w=e.footer,k=void 0===w?null:w,j=e.background,N=void 0===j?null:j,F=e.current,T=void 0===F||F,z=e.preload,$=void 0===z||z,L=e.withoutCloseButton,I=void 0!==L&&L,P=e.className,B=void 0===P?null:P,E=(0,a.useRef)(null),V=(0,a.useRef)(null),D=$l("keypad"),O=jt().muted,H=Mt(T,!0),Z=H.ref,W=H.isCurrent,q=void 0!==W&&W,_=zt(),G=It(),Y=G.width,U=G.height,Q=G.resolution,X=Ot(),J=X.topHeight,K=X.bottomHeight,ee=X.bottomSidesWidth,te=qt().open,le=Wt(),ae=le.enableInteraction,ne=le.disableInteraction,ie=Rt(),oe=ie.isView,re=ie.isPreview,ue=ie.isPlaceholder,de=ie.isEdit,ce=Ge(C),me=Ye(k),ve=ze(k,{isView:oe,current:T,openWebView:te,isPreview:re}),ge=Je(o),ye=(o||{}).textStyle,he=void 0===ye?null:ye,fe=Je(s),pe=pl(),be=pe.ref,xe=pe.height,Ae=void 0===xe?0:xe,Se=pl(),Ce=Se.ref,we=Se.height,ke=void 0===we?0:we,je=T&&(oe||de)&&(q||!oe),Me=!ue&&(T||$),Ne=de&&null===_,Fe=de&&null!==_,Te=f||{},Re=Te.columnAlign,$e=void 0===Re?null:Re,Le=Te.columns,Ie=void 0===Le?null:Le,Pe=Te.spacing,Be=void 0===Pe?null:Pe,Ee=Te.withSquareItems,De=void 0!==Ee&&Ee,Oe=b||{},He=Oe.layout,Ze=void 0===He?null:He,We=Oe.textStyle,qe=void 0===We?null:We,_e=Oe.labelBoxStyle,Ue=void 0===_e?null:_e,Qe=Oe.boxStyle,Xe=void 0===Qe?null:Qe,Ke=Oe.visualWidth,et=void 0===Ke?null:Ke,tt=A||{},lt=tt.layout,at=void 0===lt?null:lt,nt=tt.headingTextStyle,it=void 0===nt?null:nt,ot=tt.contentTextStyle,rt=void 0===ot?null:ot,st=tt.button,ut=void 0===st?null:st,dt=tt.boxStyle,ct=void 0===dt?null:dt,mt=ut||{},vt=mt.buttonTextStyle,gt=void 0===vt?null:vt,yt=mt.boxStyle,ht=void 0===yt?null:yt,ft=(0,a.useMemo)(function(){return null!==at?(0,M.xQ)(at):""},[at]),pt=(0,a.useState)(!1),bt=(0,R.A)(pt,2),xt=bt[0],At=bt[1],St=(0,a.useState)(null),Ct=(0,R.A)(St,2),wt=Ct[0],kt=Ct[1],Nt=wt||{},Ft=Nt.heading,Tt=void 0===Ft?null:Ft,$t=Nt.content,Lt=void 0===$t?null:$t,Pt=Nt.largeVisual,Bt=void 0===Pt?null:Pt,Et=Nt.button,Vt=void 0===Et?null:Et,Dt=Nt.popupBoxStyle,Ht=void 0===Dt?null:Dt,Zt=Je(Tt),_t=(Tt||{}).textStyle,Gt=void 0===_t?null:_t,Yt=Je(Lt),Ut=(Lt||{}).textStyle,Qt=void 0===Ut?null:Ut,Xt=Vt||{},Kt=Xt.label,el=void 0===Kt?null:Kt,tl=Xt.url,ll=void 0===tl?null:tl,al=Xt.inWebView,nl=void 0!==al&&al,il=Xt.boxStyle,ol=void 0===il?null:il,rl=(0,a.useCallback)(function(e,t,l){if(e.stopPropagation(),!Fe){var a=t||{},n=a.label,i=void 0===n?null:n,o=a.heading,r=void 0===o?null:o,s=a.inWebView,d=void 0!==s&&s,c=a.url,m=void 0===c?null:c;d&&null!==m?te({url:m}):(kt(t),At(!0));var v=(r||{}).body,y=void 0===v?null:v,h=g(i)?i:(i||{}).body||null;D("click_item",["#".concat(l+1),h||y||""].filter(function(e){return!u(e)}).join(" "),{linkType:"keypad_item",linkUrl:m||null})}},[kt,At,D,te,Fe]),sl=(0,a.useCallback)(function(){Fe||(arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&D("close_modal"),At(!1),Sl(!1))},[At,Sl,D,Fe]),ul=(0,a.useCallback)(function(e){Fe||(e.preventDefault(),e.stopPropagation(),sl(xt))},[sl,Fe,xt]),cl=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;null!==e&&e.stopPropagation()},[]),ml=(0,a.useState)(0),vl=(0,R.A)(ml,2),gl=vl[0],yl=vl[1],hl=(0,a.useCallback)(function(e){var t=e.scrolleeHeight,l=void 0===t?0:t;Math.floor(l)>=Math.floor(U)?yl("top"):yl("bottom")},[U]),fl=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.movement,2)[1],a=(0,R.A)(e.velocity,2)[1],n="undefined"!=typeof window?window.innerHeight:0,i=n>0?Math.abs(l)/n:0,o=0;return"top"===gl&&l<0?o=.5*i*-1:"bottom"===gl&&l>0&&(o=.5*i),t?o:a>1||i>.3?(sl(!0),1):0},[sl,gl]);(0,a.useEffect)(function(){xt?ne():ae()},[xt]),(0,a.useEffect)(function(){function e(e){(!T&&oe||V.current&&!V.current.contains(e.target)&&E.current&&E.current.contains(e.target)&&!Ne&&!de&&xt)&&(e.preventDefault(),e.stopPropagation(),sl(xt))}return document.addEventListener("mouseup",e),function(){document.removeEventListener("mouseup",e)}},[T,V,E,Ne,de,xt]);var bl=(0,a.useState)(!1),xl=(0,R.A)(bl,2),Al=xl[0],Sl=xl[1],Cl=(0,a.useCallback)(function(){Sl(!1)},[Sl]),wl=(0,a.useCallback)(function(){Sl(!0)},[Sl]),kl=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);D("scroll",t,{scrollPercent:t})}},[D]),jl=(0,a.useCallback)(function(){sl(xt)},[sl,xt]),Ml=dl({disabled:!oe||Al,progress:xt?0:1,computeProgress:fl,springParams:{config:{tension:300,friction:30}},dragOptions:{filterTaps:!0,preventDefault:!0,stopPropagation:!0},onTap:jl}),Nl=Ml.bind,Fl=Ml.progress;(0,a.useEffect)(function(){var e=function(e){"Escape"===e.key&&xt&&sl(xt)};return document.addEventListener("keyup",e),function(){document.removeEventListener("keyup",e)}},[xt,sl]);var Tl=(0,a.useMemo)(function(){return(null===l||0===l.length?Xi:l).map(function(e,t){var l=e||{},a=l.id,n=void 0===a?null:a,o=l.label,r=void 0===o?null:o,s=l.visual,u=void 0===s?null:s,d=l.boxStyle,c=void 0===d?null:d,m=l.heading,v=void 0===m?null:m,y=l.content,f=void 0===y?null:y,p=l.url,b=void 0===p?null:p,x=l.inWebView,A=void 0!==x&&x,S=l.largeVisual,C=void 0===S?null:S,w=(u||{}).url,k=void 0===w?null:w,j=(v||{}).body,M=void 0===j?null:j,N=(f||{}).body,F=void 0===N?null:N,R=g(r)?{body:r}:r||{},z=(R||{}).textStyle,$=void 0===z?null:z,L=(R||{}).body,I=void 0===L?null:L,P=I||k||n,B=null===I&&null===u,E=null!==b&&!A,V=!(null!==v&&null!==M&&""!==M||null!==f&&null!==F&&""!==F||null!==C);return(0,se.jsx)("div",{className:Qi.item,children:(0,se.jsx)(Ln,{className:Jt([Qi.button,(0,h.A)((0,h.A)((0,h.A)({},Qi.isEmpty,B),Qi.isLink,null!==b),Qi.disableHover,V&&null===b)]),layout:Ze||null,external:E,href:E?b:null,focusable:T,onClick:!V||null!==b&&!E?function(l){return rl(l,e,t)}:null,textStyle:(0,i.A)((0,i.A)({},qe),$),buttonStyle:(0,i.A)((0,i.A)({},Xe),c),label:R,labelBoxStyle:Ue,visual:u,visualWidth:null!==et?"".concat(et,"%"):null,resolution:Q,textClassName:Qi.buttonLabel})},P)})},[l,_,Xe,qe,Ze,Fe]);return(0,a.useEffect)(function(){if("popup"===_&&ue&&(kt(Ji),At(!0)),"keypad"===_&&(kt(null),At(!1)),null!==_&&_.includes("popup")){var e=_.split(".").pop(),t=l[e];kt(t),At(!0)}null!==_||oe||(kt(null),At(!1))},[_,l,oe,xt,kt,At]),(0,se.jsxs)("div",{ref:E,className:Jt([Qi.container,B,(0,h.A)((0,h.A)({},Qi.isPlaceholder,ue),Qi.withSquareItems,De)]),"data-screen-ready":!0,children:[ue?null:(0,se.jsx)(pn,{background:N,width:Y,height:U,resolution:Q,playing:je,muted:O,shouldLoad:Me,mediaRef:Z,className:Qi.background}),!oe||ue||I?null:(0,se.jsx)(oa.CS.div,{className:Jt([Qi.fixedHeader,(0,h.A)({},Qi.open,xt)]),children:(0,se.jsx)("div",{className:Qi.buttons,children:(0,se.jsx)(zn,{className:Qi.close,onClick:ul,focusable:!re&&!ue&&xt,withoutStyle:!0,children:(0,se.jsx)(Sa,{color:"#000",className:Qi.closeIcon})})})}),(0,se.jsxs)(An,{width:Y,height:U,className:Qi.inner,children:[(0,se.jsxs)(ei,{width:Y,height:U,verticalAlign:c,withArrow:!xt,withShadow:!xt,disabled:re||ue||xt,onScrolledTrigger:kl,children:[(0,se.jsxs)(Qn,{className:Qi.layout,verticalAlign:c,width:Y,style:ue?null:{padding:v,paddingTop:(ce?Ae:v)+(T&&!re?J:0),paddingBottom:(me?ke:v)+(T&&!re?K:0)},children:[!ue&&ce?(0,se.jsx)("div",{ref:be,className:Qi.header,style:{paddingTop:v/2,paddingLeft:v,paddingRight:v,paddingBottom:v,transform:re?null:"translate(0, ".concat(J,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},C))}):null,(0,se.jsx)(Qa,{placeholder:"Title",emptyLabel:(0,se.jsx)(Wl.A,{id:"BSTWf8",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyHeading]),isEmpty:!ge,children:ge?(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:Qi.title},o),{},{textStyle:he})):null}),(0,se.jsx)(Qa,{placeholder:"Subtitle",emptyLabel:(0,se.jsx)(Wl.A,{id:"ZG8/oK",defaultMessage:[{type:0,value:"Subtitle"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyHeading]),isEmpty:!fe,children:fe?(0,se.jsx)(nn,(0,i.A)({className:Qi.subtitle},s)):null}),(0,se.jsx)(Ui,{className:Jt([Qi.grid,(0,h.A)({},Qi.gridPlaceholder,ue)]),align:$e,columns:ue?3:Ie,spacing:ue?2:Be,items:Tl})]}),null!==wt?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)(oa.CS.div,{className:Jt([Qi.popupBackdrop]),style:{opacity:Fl.to(function(e){return 1-Math.abs(e)})}}),(0,se.jsx)(oa.CS.div,(0,i.A)((0,i.A)({className:Qi.popup,style:{transform:Fl.to(function(e){return"translateY(".concat(100*e,"%) scale(").concat(1-Math.abs(.5*e),")")}),pointerEvents:Fl.to(function(e){return Math.abs(e)>.5?"none":"auto"})}},Nl()),{},{children:(0,se.jsx)(ei,{disabled:re||ue,verticalAlign:"middle",withArrow:!1,scrollPosition:xt?null:1,onScrolledBottom:Cl,onScrolledNotBottom:wl,onScrollHeightChange:hl,className:Qi.popupScroll,withShadow:!0,children:(0,se.jsxs)("div",{ref:V,className:Jt([Qi.popupInner,Qi[ft],(0,h.A)({},Qi.withShadow,null===ct)]),style:(0,i.A)((0,i.A)((0,i.A)({},Ve(Ji)),Ve(ct)),Ve(Ht)),children:[(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"IE7U/Q",defaultMessage:[{type:0,value:"Heading"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyHeading]),isEmpty:!Zt,children:Zt?(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:Qi.popupHeading},Tt),{},{textStyle:(0,i.A)((0,i.A)({},it),Gt)})):null}),(0,se.jsx)(Qa,{placeholder:"popupContent",emptyLabel:(0,se.jsx)(Wl.A,{id:"JRZoe6",defaultMessage:[{type:0,value:"Content"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyContent]),isEmpty:!Yt,children:Yt?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:Qi.popupContent},Lt),{},{textStyle:(0,i.A)((0,i.A)({},rt),Qt)})):null}),(0,se.jsx)(Qa,{placeholder:"image",emptyLabel:(0,se.jsx)(Wl.A,{id:"z4Pr+g",defaultMessage:[{type:0,value:"Visual (Image or Video)"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyVisual]),isEmpty:null===Bt,children:null!==Bt?(0,se.jsx)(Nn,{className:Qi.popupVisual,imageClassName:Qi.popupVisualImage,videoClassName:Qi.popupVisualVideo,media:Bt,resolution:Q,width:"100%"}):null}),(0,se.jsx)(Qa,{placeholder:"button",emptyLabel:(0,se.jsx)(Wl.A,{id:"N7Kj8z",defaultMessage:[{type:0,value:"Button"}]}),emptyClassName:Jt([Qi.empty,Qi.emptyCTA]),isEmpty:null===Vt,children:null!==Vt?(0,se.jsx)(Vn,{className:Qi.popupCTA,label:(0,i.A)((0,i.A)({},gt),el),url:ll,onClick:cl,inWebView:nl,openWebView:te,type:"click",boxStyle:(0,i.A)((0,i.A)({},ht),ol)}):null})]})})}))]}):null]}),!ue&&me?(0,se.jsx)("div",{ref:Ce,className:Qi.footer,style:{transform:T&&!re?"translate(0, -".concat(K,"px)"):null,paddingLeft:Math.max(v/2,ee),paddingRight:Math.max(v/2,ee),paddingBottom:v/2,paddingTop:v},children:(0,se.jsx)(Dn,(0,i.A)({},ve))}):null]})]})},states:[{id:"keypad",label:(0,ue.zR)({id:"Z4f5qh",defaultMessage:[{type:0,value:"Buttons"}]}),fields:[{name:"layout",type:"screen-layout",defaultValue:"middle",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"items",type:"buttons",label:(0,ue.zR)({id:"fbUW2U",defaultMessage:[{type:0,value:"Items"}]}),isSection:!0},{name:"keypadLayout",type:"keypad-layout",isList:!0,withoutLabel:!0,defaultValue:{columnAlign:"middle",columns:3,spacing:2,withSquareItems:!1},label:(0,ue.zR)({id:"FjuRaw",defaultMessage:[{type:0,value:"Keypad settings"}]})},{name:"buttonStyles",type:"rich-button-styles",defaultValue:{layout:"label-bottom",boxStyle:{backgroundColor:{alpha:.15,color:"#000000"}}},label:(0,ue.zR)({id:"Arl5Ze",defaultMessage:[{type:0,value:"Button styles"}]}),isList:!0}]},{id:"popups",label:(0,ue.zR)({id:"FYm4w+",defaultMessage:[{type:0,value:"Popups"}]}),fields:[{name:"popupStyles",type:"fields",defaultValue:{layout:"content-top"},fields:[{name:"layout",type:"card-layout",label:(0,ue.zR)({id:"OPxJx/",defaultMessage:[{type:0,value:"Layout"}]})},{name:"headingTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"zrK6ak",defaultMessage:[{type:0,value:"Heading text style"}]})},{name:"contentTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"z9nSIG",defaultMessage:[{type:0,value:"Content text style"}]})},{name:"boxStyle",type:"box-style-form",label:(0,ue.zR)({id:"p1pghO",defaultMessage:[{type:0,value:"Box style"}]})},{name:"button",type:"fields",isList:!0,label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]}),fields:[{name:"buttonTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"p5RHzq",defaultMessage:[{type:0,value:"Button text style"}]})},{name:"buttonStyle",type:"box-style-form",label:(0,ue.zR)({id:"nno1Pq",defaultMessage:[{type:0,value:"Button style"}]})}]}]}]},{id:"popup",label:(0,ue.zR)({id:"sSahY1",defaultMessage:[{type:0,value:"Popup"}]}),defaultValue:[],repeatable:!0,fieldName:"items",fields:[{name:"heading",type:"heading-element",label:(0,ue.zR)({id:"6iR9Mt",defaultMessage:[{type:0,value:"Heading"}]})},{name:"content",type:"text-element",label:(0,ue.zR)({id:"uoF5Pv",defaultMessage:[{type:0,value:"Content"}]}),theme:{label:{textStyle:"text"}}},{name:"largeVisual",type:"visual",label:(0,ue.zR)({id:"HwqzVR",defaultMessage:[{type:0,value:"Visual"}]})},{name:"popupBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"p1pghO",defaultMessage:[{type:0,value:"Box style"}]})},{name:"button",type:"button-link",label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]}),theme:{label:{textStyle:"button"}}}]}],fields:[{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"subtitle",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"EcZYpr",defaultMessage:[{type:0,value:"Subtitle"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],eo=[{elementType:"geometry",stylers:[{color:"#f5f5f5"}]},{elementType:"labels.icon",stylers:[{visibility:"off"}]},{elementType:"labels.text.fill",stylers:[{color:"#616161"}]},{elementType:"labels.text.stroke",stylers:[{color:"#f5f5f5"}]},{featureType:"administrative.land_parcel",stylers:[{visibility:"off"}]},{featureType:"administrative.land_parcel",elementType:"labels.text.fill",stylers:[{color:"#bdbdbd"}]},{featureType:"administrative.neighborhood",stylers:[{visibility:"off"}]},{featureType:"poi",elementType:"geometry",stylers:[{color:"#eeeeee"}]},{featureType:"poi",elementType:"labels.text",stylers:[{visibility:"off"}]},{featureType:"poi",elementType:"labels.text.fill",stylers:[{color:"#757575"}]},{featureType:"poi.business",stylers:[{visibility:"off"}]},{featureType:"poi.park",elementType:"geometry",stylers:[{color:"#e5e5e5"}]},{featureType:"poi.park",elementType:"labels.text.fill",stylers:[{color:"#9e9e9e"}]},{featureType:"road",elementType:"geometry",stylers:[{color:"#ffffff"}]},{featureType:"road",elementType:"labels",stylers:[{visibility:"off"}]},{featureType:"road",elementType:"labels.icon",stylers:[{visibility:"off"}]},{featureType:"road.arterial",elementType:"labels",stylers:[{visibility:"off"}]},{featureType:"road.arterial",elementType:"labels.text.fill",stylers:[{color:"#757575"}]},{featureType:"road.highway",elementType:"geometry",stylers:[{color:"#dadada"}]},{featureType:"road.highway",elementType:"labels",stylers:[{visibility:"off"}]},{featureType:"road.highway",elementType:"labels.text.fill",stylers:[{color:"#616161"}]},{featureType:"road.local",stylers:[{visibility:"off"}]},{featureType:"road.local",elementType:"labels.text.fill",stylers:[{color:"#9e9e9e"}]},{featureType:"transit",stylers:[{visibility:"off"}]},{featureType:"transit.line",elementType:"geometry",stylers:[{color:"#e5e5e5"}]},{featureType:"transit.station",elementType:"geometry",stylers:[{color:"#eeeeee"}]},{featureType:"water",elementType:"geometry",stylers:[{color:"#c9c9c9"}]},{featureType:"water",elementType:"labels.text",stylers:[{visibility:"off"}]},{featureType:"water",elementType:"labels.text.fill",stylers:[{color:"#9e9e9e"}]}],to={onClick:["click",function(e){return e.getCenter()}],onCenterChanged:["center_changed",function(e){return e.getCenter()}],onBoundsChanged:["bounds_changed",function(e){return e.getBounds()}],onDragEnd:["dragend",function(e){return e.getCenter()}],onTilesLoaded:["tilesloaded",function(){}]},lo={onTouchMove:function(e){return e.stopPropagation()},onTouchStart:function(e){return e.stopPropagation()},onTouchEnd:function(e){return e.stopPropagation()},onPointerMove:function(e){return e.stopPropagation()},onPointerUp:function(e){return e.stopPropagation()},onPointerDown:function(e){return e.stopPropagation()}};function ao(e){var t=e.center,l=void 0===t?null:t,n=e.zoom,o=void 0===n?null:n,r=e.maxZoom,s=void 0===r?16:r,u=e.bounds,d=void 0===u?null:u,c=e.draggable,m=void 0===c||c,v=e.withoutStyle,g=void 0!==v&&v,y=e.events,f=void 0===y?null:y,p=e.fitBounds,b=void 0!==p&&p,x=e.zoomControl,A=void 0!==x&&x,S=e.mapTypeControl,C=void 0!==S&&S,w=e.scaleControl,k=void 0!==w&&w,j=e.streetViewControl,M=void 0!==j&&j,N=e.rotateControl,F=void 0!==N&&N,T=e.fullscreenControl,z=void 0!==T&&T,$=e.className,L=void 0===$?null:$,I=e.children,P=void 0===I?null:I,B=e.focusable,E=void 0===B||B,V=function(e){var t=e.zoom,l=e.maxZoom,n=void 0===l?null:l,i=e.center,o=void 0===i?null:i,r=e.withoutStyle,s=void 0!==r&&r,u=e.fitBounds,d=void 0!==u&&u,c=e.bounds,m=void 0===c?null:c,v=e.events,g=e.draggable,y=void 0!==g&&g,h=e.zoomControl,f=e.mapTypeControl,p=e.scaleControl,b=e.streetViewControl,x=e.rotateControl,A=e.fullscreenControl,S=At(),C=(0,a.useState)(!1),w=(0,R.A)(C,2),k=w[0],j=w[1],M=(0,a.useRef)(null),N=(0,a.useRef)(null),F=pl(),T=F.ref,z=F.width,$=void 0===z?null:z,L=F.height,I=void 0===L?null:L;(0,a.useEffect)(function(){var e=N.current;if(null!==e&&null!==o){var t=o||{},l=t.lat,a=void 0===l?null:l,n=t.lng,i=void 0===n?null:n;e.panTo({lat:a||0,lng:i||0})}},[o]),(0,a.useEffect)(function(){var e=N.current;null!==e&&null!==t&&e.setZoom(Math.min(n,t))},[t,n]);var P=(0,a.useCallback)(function(e,t){null===t||t.equals(e.getBounds())||(e.fitBounds(t),e.getZoom()>n&&e.setZoom(n),e.panToBounds(t))},[n]);return(0,a.useEffect)(function(){var e=N.current;null!==e&&d&&P(e,m)},[P,m,d,$,I]),(0,a.useEffect)(function(){var e=N.current;k&&null!==e&&e.setOptions({draggable:y,scrollWheel:y,disableDoubleClickZoom:!y,gestureHandling:y?"cooperative":"none"})},[k,y]),(0,a.useEffect)(function(){if(null===S||null===M.current||null!==N.current)return function(){};var e=new S.maps.Map(M.current,{zoom:t,center:o,styles:s?null:eo,zoomControl:h,mapTypeControl:f,scaleControl:p,streetViewControl:b,rotateControl:x,fullscreenControl:A});return d&&P(e,m),N.current=e,null!==v&&Object.keys(v).forEach(function(t){null!==v[t]&&e.addListener(to[t][0],function(){return v[t](to[t][1](e))})}),j(!0),function(){}},[S,j]),{ref:(0,a.useCallback)(function(e){T.current=e,M.current=e},[]),map:N.current,ready:k,loading:!k}}({zoom:o,maxZoom:s,bounds:d,draggable:m,fitBounds:b,center:l,events:f,withoutStyle:g,zoomControl:A,mapTypeControl:C,scaleControl:k,streetViewControl:M,rotateControl:F,fullscreenControl:z}),D=V.map,O=V.ref;return(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:Jt(["micromag-element-map-container",L,(0,h.A)({},"micromag-element-map-preventScroll",!m)])},lo),{},{children:[(0,se.jsx)("div",{ref:O,className:"micromag-element-map-map",tabIndex:E?"0":"-1"}),a.Children.map(P,function(e){return a.cloneElement(e,{map:D})})]}))}var no={onClick:"click",onDoubleClick:"dblclick"};function io(e){var t=e.map,l=void 0===t?null:t,n=e.position,i=e.type,o=e.events,r=void 0===o?null:o,s=e.active,u=void 0===s||s,d=e.title,c=void 0===d?null:d,m=e.image,v=void 0===m?null:m,g=e.iconSize;return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.position,n=void 0===l?null:l,i=t.icon,o=void 0===i?null:i,r=t.iconSize,s=void 0===r?null:r,u=t.events,d=t.title,c=At(),m=(0,a.useRef)(null);(0,a.useEffect)(function(){var e=m.current;null!==e&&null!==n&&e.setPosition(n)},[n]);var v=(0,a.useCallback)(function(e,t){if(null!==c)if(A(t)){var l=(t||{}).url,a=void 0===l?null:l;e.setIcon({url:a,scaledSize:new c.maps.Size(s.width,s.height)})}else e.setIcon(t)},[c,s]);(0,a.useEffect)(function(){var e=m.current;null!==e&&null!==c&&v(e,o)},[c,o,v]),(0,a.useEffect)(function(){if(null===c||null===e||null!==m.current)return function(){};var t=new c.maps.Marker({position:n,map:e,title:d});return v(t,o),Object.keys(u).forEach(function(e){t.addListener(no[e],u[e])}),m.current=t,function(){c.maps.event.clearInstanceListeners(t),t.setMap(null)}},[c,e]),m.current}(l,{position:n,type:i,events:r,title:c,icon:v||(u?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABsAAAArCAYAAACJrvP4AAAC+ElEQVR4AWIgBP7//88DxCGAWssB1pIkCsO1iLG27WCtYG17x3Ywtm3bthlNMLZtz/NrXvStM/cbP/Vln6RSOfq/xqlOi2nO10bxUe26RRKLRdnxiZOnTqVpQO6NOc5AiYSd6O4dRcbAnlJQv4rk/fWt5HzzkbDjEydPHfX0pQr6Q4dcI7RqqZP7Z1z8i/cSLuqop4/+ZCB3iOt214UFVkG9SoikvOijHx1fGAXeqWNm7u9f0Zj2oh+dCoHcOlfkA0oZiB66ZYaBZ53uo/N7pOiWGBqmyF21xKEg24uhQf/mOWJsmaYgYOiiDwfYn5yTRE2X42vNWy/KyKcelZ6PPMCOTzwhEH04ii8ABzMRaNwzj0uXB+8rs4gnAqIPR/HJ4UvgV8wdlICUXOR9+9GHo/jG8enxK+aR+cDI+/ajD0eJ50Vzvv3Yt5h35Acj79ePPhylbetyXuVfA70z9OEoXVy0pbBl40DfGfpwVMy1R1kTRnpBTqM1cZQHh3P2Tiwv1wzynKEPR2HaNI4VNmsQyBcE3bj+UTgYE1kncmCvFQQMXRGpfQsmcre27fNFHVtkFYSeOM459OHcDvw+/mwtzkQ2QOigh64qz7RlrXRmTw1nA4ZOXG+F3z/Iozrkmvm1/80IRD866CkfY1hqeSeOGZnA6EdHJWPaNjdYw/tH0wHRR38q/43Padcx8/75ISUQ9fTRr1IxiUZbR7ZtSulxUk9fsoySZ8+xjxZ1bpkUiDrq6Uv3f/9TXVxk53z3qS+IPHXUq0xMbHuRNWGk77CQp05laiLysoRCbu4vn5cLIk6eOpUN06a52J46zisPRpy8ypaJyOvaMqycrz4sAcInTl5l07RprC3u1qYEDJ+4yraJSI3w5vVmiXO1dYNJPAjYQzo+CDlfvi+A2PGJqyBMG8aegiY1BRg7vgrKYqY53RjUS4Cx4wcGk1isa3zUNTB2/OBgIvVDq5bawNjxg4R96Z07U5T393fCjh8k7E7t2PPEi7rs+Kn0XwF82Z38cjx5pwAAAABJRU5ErkJggg==":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABsAAAArCAYAAACJrvP4AAAACXBIWXMAAAsTAAALEwEAmpwYAAAFFmlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDAgNzkuMTYwNDUxLCAyMDE3LzA1LzA2LTAxOjA4OjIxICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6cGhvdG9zaG9wPSJodHRwOi8vbnMuYWRvYmUuY29tL3Bob3Rvc2hvcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RFdnQ9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZUV2ZW50IyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ0MgKE1hY2ludG9zaCkiIHhtcDpDcmVhdGVEYXRlPSIyMDIwLTA0LTA3VDE2OjQ0OjQ4LTA0OjAwIiB4bXA6TW9kaWZ5RGF0ZT0iMjAyMC0wNC0wN1QxNzo1MToxMi0wNDowMCIgeG1wOk1ldGFkYXRhRGF0ZT0iMjAyMC0wNC0wN1QxNzo1MToxMi0wNDowMCIgZGM6Zm9ybWF0PSJpbWFnZS9wbmciIHBob3Rvc2hvcDpDb2xvck1vZGU9IjMiIHBob3Rvc2hvcDpJQ0NQcm9maWxlPSJzUkdCIElFQzYxOTY2LTIuMSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxMDRhNzAzOS01Mjk1LTQzNjktYmMxNS1kYzEzODM3NDQ0MmIiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MTA0YTcwMzktNTI5NS00MzY5LWJjMTUtZGMxMzgzNzQ0NDJiIiB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9InhtcC5kaWQ6MTA0YTcwMzktNTI5NS00MzY5LWJjMTUtZGMxMzgzNzQ0NDJiIj4gPHhtcE1NOkhpc3Rvcnk+IDxyZGY6U2VxPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0iY3JlYXRlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDoxMDRhNzAzOS01Mjk1LTQzNjktYmMxNS1kYzEzODM3NDQ0MmIiIHN0RXZ0OndoZW49IjIwMjAtMDQtMDdUMTY6NDQ6NDgtMDQ6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCBDQyAoTWFjaW50b3NoKSIvPiA8L3JkZjpTZXE+IDwveG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5lxvhNAAAEzUlEQVRYhbWXTWgbRxiG329mNLuKtVrrEMlEQsL4YhNIIoiQffFhcwkG44MugRBIXFpyq2+BUnJom0Mgh/bWQ35EcimE3kJoAg605BZMqLB7SEKMChKKA7bDypK1vz1UNrZr70qx+l52Z76fZ2b4ZoYhhMj3/RiAi51O55LneWeFECeFEEOO42w5jvORMfanoii/APiNiJpBuSgAMmxZ1k3O+fVarWZVKhW9Xq/DNE20221Eo1FomoZTp07hzJkzn9LptHRd92cp5XdEtNkzzPf9km3bD1ZWVsTi4mK02QwcMAAgFovhwoUL7dOnTzuRSOQaEf0aCPN9n2zb/t627YVHjx4NNRqNUMhBjYyM4MqVK1uRSORHKeW3R8Isy/phc3Pz63K5HGu1Wn2DdnTixAlcvXq1OTw8/NNeINv56S7dwnFBANBqtVAul2O2bS/4vl/a6acuaNi27b/v37+vfc7SHaWRkRHMz8+bkUgkS0SbDAAsy7q5vLwsBgkCgEajgZWVFWFZ1k0AYL7vxzjn11+8eBEdKKmrxcXFKOf8uu/7MQHgYq1Ws5rNZiisWq1ibW1td58lk0nkcrnAmGaziVqtZmWz2Yui0+lcqlQqehjo9evX2NjY2G2bpgnTNLG+vo58Ph8YW6lU9FQqdYl5nne2Xq+HzmgvaK82NjZQrVYD4+v1OjzPO8uEECdN0wx0XltbO5bdNE0IIU4yzvlQu90OdB6EnXM+xGzbXo/H44HO0Whw7YTZ4/E4bNteZ57nVROJRKBzMpk8lj2RSMDzvCrjnC+l02k3yDmXy+GoASUSidDyz2QyLud8iUkp7xYKheBFB5DP5zE2NgZN0yCEgKZpGBsbCy17ADh//nxbSnlXENFSu93+MDo6GltdXQ0MyuVyobM4qNHRUUQikQYRLTEAkFLeNgxjq68sPcowjC1VVW8D3SuGMfYgmUx+Gh8fHyhofHwcqVRqE0B5F0ZEjpTyy5mZmS3O+UBAnHPMzMxsRSKRr4jI2YV1gU+llH8YhmENAmYYhiWl/J2Inu70sb0OiqLMFwoFK2zfhCmZTKJQKFiKonyxt38fjIganPOFUqkUfFiGqFQqmZzzBSLadxuzg46c83u6ri8Xi0Xnc0DFYtHRdX2Zc37voO0/MABQFOWyYRjbYWfmQcXjcRiGsa0oyuXD7IfCiGhVCHFrbm6ur+Wcm5szhRC3iOjQ0+FQGAAwxu5kMpkPExMTPYEmJiaQyWQ+MMbuHJnzKEN3712bnZ1tCSECQUIIzM7OtqSU13b2VF+wLvAl5/z51NRUYLFMTU05nPPnRPQyyC8QBgBSyhvT09OOqqqH2lVVxfT0tCOlvBGWKxRGRG8cx3k2OTl56J03OTnpOo7zjIjeHBsGAKqqflMsFrcZ2+/OGEOxWNxWVfWbXvL0BCOivwC8OliZ3farrn0wMABQVfXhuXPn9r0K8/l8U1XVh73m6BkG4EkulxNE/z7piAjZbFYAeDJwGBF9dF33bTqdBgCk02m4rvuWiD4OHNZVJZVKAQC630o/wX3BFEV5r2maDwCapvmKorz/32BEVNd1vQ0Auq63iSj4RXIcGIB32WzW1jQN2WzWBvCuz/je5fs+63Q6j13XbXc6nce+7/c12H8A3aa8zLNKuWMAAAAASUVORK5CYII="),iconSize:void 0===g?{width:50,height:50}:g}),null}function oo(e){var t=e.center,l=void 0===t?null:t,n=e.zoom,i=void 0===n?null:n,o=e.draggable,r=void 0===o||o,s=e.markers,u=void 0===s?null:s,d=e.onClickMap,c=void 0===d?null:d,m=e.onClickMarker,v=void 0===m?null:m,g=e.className,y=void 0===g?null:g,h=e.onReady,f=void 0===h?null:h,p=e.onCenterChanged,b=void 0===p?null:p,x=e.onBoundsChanged,A=void 0===x?null:x,S=e.onDrag,C=void 0===S?null:S,w=e.onDragEnd,k=void 0===w?null:w,j=e.withoutStyle,M=void 0!==j&&j,N=e.fitBounds,F=void 0!==N&&N,z=e.zoomControl,$=void 0!==z&&z,L=e.mapTypeControl,I=void 0!==L&&L,P=e.scaleControl,B=void 0!==P&&P,E=e.streetViewControl,V=void 0!==E&&E,D=e.rotateControl,O=void 0!==D&&D,H=e.fullscreenControl,Z=void 0!==H&&H,W=e.focusable,q=void 0===W||W,_=u||[],G=At(),Y=(0,a.useCallback)(function(e){null!==c&&c(e)},[c]),U=(0,a.useMemo)(function(){var e=(_||[]).filter(function(e){return null!==e&&null!==(e.geoPosition||null)});return null===G||null===e||0===e.length?null:e.reduce(function(e,t){var l=t.geoPosition,a=(void 0===l?null:l)||{},n=a.lat,i=void 0===n?null:n,o=a.lng,r=void 0===o?null:o;return null!==i&&null!==r&&e.extend(new G.maps.LatLng(i,r)),e},new G.maps.LatLngBounds)},[G,_]),Q=(0,a.useState)(!1),X=(0,R.A)(Q,2),J=X[0],K=X[1];(0,a.useEffect)(function(){null!==G&&J&&null!==f&&f(G)},[G,J,f]);var ee=(0,a.useCallback)(function(){return K(!0)},[K]),te=(0,a.useMemo)(function(){return{onClick:Y,onCenterChanged:b,onBoundsChanged:A,onDrag:C,onDragEnd:k,onTilesLoaded:ee}},[Y,b,A,C,k,ee]);return(0,se.jsx)("div",{className:Jt(["micromag-element-map-container",y]),children:(0,se.jsx)(ao,{center:l,zoom:i,withoutStyle:M,bounds:U,draggable:r,events:te,fitBounds:F,zoomControl:$,mapTypeControl:I,scaleControl:B,streetViewControl:V,rotateControl:O,fullscreenControl:Z,focusable:q,children:null!==_?_.map(function(e,t){var l=e.active,a=void 0===l||l,n=e.geoPosition,i=void 0===n?null:n,o=e.image,r=void 0===o?null:o,s=e.title,u=void 0===s?null:s;return null!==i&&null!==(i.lat||null)&&null!==(i.lng||null)?(0,se.jsx)(io,{active:a,title:null!==u&&(0,T.A)(u.body)?u.body:null,image:r,position:i,events:{onClick:null!==v?function(e){return v(e,t)}:function(){return console.log(t)}}},"marker-".concat(t)):(0,se.jsx)("div",{})}):null})})}var ro={container:"micromag-screen-map-container",background:"micromag-screen-map-background",content:"micromag-screen-map-content",placeholder:"micromag-screen-map-placeholder",markerOverlayContainer:"micromag-screen-map-markerOverlayContainer",markerOverlayScrollable:"micromag-screen-map-markerOverlayScrollable",markerOverlaySafe:"micromag-screen-map-markerOverlaySafe",markerOverlay:"micromag-screen-map-markerOverlay",markerOverlayContent:"micromag-screen-map-markerOverlayContent",markerOverlayContentInner:"micromag-screen-map-markerOverlayContentInner",swipeIndicator:"micromag-screen-map-swipeIndicator",splash:"micromag-screen-map-splash",title:"micromag-screen-map-title",description:"micromag-screen-map-description",button:"micromag-screen-map-button",emptyTitle:"micromag-screen-map-emptyTitle",emptyDescription:"micromag-screen-map-emptyDescription",emptyButton:"micromag-screen-map-emptyButton",splashButton:"micromag-screen-map-splashButton",closeButton:"micromag-screen-map-closeButton",markerImage:"micromag-screen-map-markerImage",markerTitle:"micromag-screen-map-markerTitle",markerSubtitle:"micromag-screen-map-markerSubtitle",markerDescription:"micromag-screen-map-markerDescription",hasSelectedMarker:"micromag-screen-map-hasSelectedMarker",opened:"micromag-screen-map-opened"},so={lat:45.5,lng:-73.56},uo={onTouchMove:function(e){return e.stopPropagation()},onTouchStart:function(e){return e.stopPropagation()},onTouchEnd:function(e){return e.stopPropagation()},onPointerMove:function(e){return e.stopPropagation()},onPointerUp:function(e){return e.stopPropagation()},onPointerDown:function(e){return e.stopPropagation()}},co=[];function mo(e){var t,l=e.layout,n=void 0===l?"normal":l,o=e.draggable,r=void 0===o||o,s=e.markers,u=void 0===s?co:s,d=e.title,c=void 0===d?null:d,m=e.description,v=void 0===m?null:m,g=e.button,y=void 0===g?null:g,f=e.openedMarkerSpacerHeight,p=void 0===f?.75:f,b=e.withMarkerImages,x=void 0!==b&&b,A=e.zoom,S=void 0===A?10:A,C=e.center,w=void 0===C?so:C,k=e.fitBounds,j=void 0===k||k,M=e.background,N=void 0===M?null:M,F=e.current,T=void 0===F||F,z=e.active,$=void 0===z||z,L=e.type,I=void 0===L?null:L,P=e.className,B=void 0===P?null:P,E=(0,Zl.A)().locale,V=pt().apiKey,D=void 0===V?null:V,O=$l(I),H=(0,a.useState)(null),Z=(0,R.A)(H,2),W=Z[0],q=Z[1],_=null!==W,G=(0,a.useRef)(null),Y=It(),U=Y.width,Q=Y.height,X=Y.resolution,J=jt().muted,K=Mt(T,!0),ee=K.ref,te=K.isCurrent,le=void 0!==te&&te,ae=(N||{}).color,ne=Ee(ae),ie=Rt(),oe=ie.isView,re=ie.isPreview,ue=ie.isPlaceholder,de=ie.isEdit,ce=ie.isStatic,me=ie.isCapture,ve=zt(),ge=(0,a.useState)(!1),ye=(0,R.A)(ge,2),he=ye[0],fe=ye[1],pe=!de&&(ce||me||ue||re||de)||!T,be=T&&(oe||de)&&(le||!oe),xe=T||$,Ae=(0,a.useState)(ce||me),Se=(0,R.A)(Ae,2),Ce=Se[0],we=Se[1],ke=Wt(),je=ke.enableInteraction,Me=ke.disableInteraction,Ne=(0,a.useCallback)(function(){return fe(!0)},[fe]),Fe=(0,a.useMemo)(function(){return(u||[]).map(function(e,t){return(0,i.A)((0,i.A)({},e),{},{active:t===W})})},[u,W]),Te=(0,a.useCallback)(function(){var e=Fe[W];G.current=e,q(null)},[Fe,W,q]),Re=(0,a.useCallback)(function(){var e=Fe[W];O("click_marker_close","Marker ".concat(W+1,": ").concat(e.title.body),{marker:e,markerIndex:W}),Te()},[Fe,W,O,Te]),ze=(0,a.useCallback)(function(e,t){var l=Fe[t];q(t),O("click_marker_open","Marker ".concat(t+1,": ").concat(l.title.body),{marker:l,markerIndex:t})},[Fe,q,O]),$e=(0,a.useCallback)(function(){we(!0),null!==Me&&Me(),O("click_button",y.body)},[we,Me,O,y]),Le=(0,a.useCallback)(function(){we(!1),null!==je&&je(),O("click_close","Close icon"),Te()},[we,je,O]),Ie=(0,a.useCallback)(function(e){var t=e.toJSON();O("drag_map","Latitude: ".concat(t.lat.toFixed(4),", Longitude: ").concat(t.lng.toFixed(4)),{coords:t})},[O]),Pe=(0,a.useCallback)(function(e){if(e.initial){var t=(u||[])[W];O("scroll","Marker ".concat(W+1,": ").concat(t.title.body),{marker:t,markerIndex:W})}},[O,u,W]),Be=pl({disabled:!oe}),Ve=Be.ref,De=Be.width,Oe=void 0===De?"100%":De,He=(0,a.useState)(0),Ze=(0,R.A)(He,2),We=Ze[0],qe=Ze[1],_e=We===(u||[]).length,Ge=he&&(!x||_e);if((0,a.useEffect)(function(){if(x&&null!==u&&(u||[]).length){qe(0);var e=u.map(function(e){var t=(e||{}).image,l=((void 0===t?null:t)||{}).url,a=void 0===l?null:l;if(null!==a){var n=new Image;return n.src=a,n.onload=function(){qe(function(e){return qe(e+1)})},n}return null});return function(){e.filter(function(e){return null!==e}).forEach(function(e){e.onload=function(){}})}}return function(){}},[x,u]),(0,a.useEffect)(function(){if(de||re){var e=null!==ve?ve.split("."):[],t=(0,R.A)(e,2),l=t[0],a=void 0===l?null:l,n=t[1],i=void 0===n?null:n;"intro"===a?(we(!1),q(null)):"map"===a?(we(!0),q(null)):"markers"!==a&&"markers-with-image"!==a||(we(!0),q(parseInt(i,10)))}},[ve,de,we]),U>0&&Q>0&&null!==D){var Ye=null!==u?u.filter(function(e){return null!==e}).filter(function(e){var t=e.geoPosition;return null!==(void 0===t?null:t)}):null;if(t="https://maps.googleapis.com/maps/api/staticmap?size=".concat(Math.round(U),"x").concat(Math.round(Q)),null!==w&&(null===Ye||0===Ye.length)){var Ue=w||{},Qe=Ue.lat,Xe=void 0===Qe?null:Qe,Ke=Ue.lng,et=void 0===Ke?null:Ke;t+="¢er=".concat(Xe,",").concat(et)}null!==S&&(t+="&zoom=".concat(S)),null!==D&&(t+="&key=".concat(D)),null!==E&&(t+="&language=".concat(E)),null!==Ye&&(t+=Ye.map(function(e){var t=(e||{}).geoPosition,l=(void 0===t?null:t)||{},a=l.lat,n=void 0===a?null:a,i=l.lng,o=void 0===i?null:i,r=(e||{}).image,s=((void 0===r?null:r)||{}).url,u=void 0===s?null:s;return null!==n&&null!==o?"&markers=".concat(null!==u?"icon:".concat(u):"","%7C").concat(n,",").concat(o):""}).join(""))}var tt=(_?Fe[W]:G.current)||{},lt=tt.title,at=void 0===lt?null:lt,nt=tt.subtitle,it=void 0===nt?null:nt,ot=tt.description,rt=void 0===ot?null:ot,st=tt.image,ut=void 0===st?null:st,dt=null!==at,ct=null!==it,mt=null!==rt,vt=null!==ut,gt=Je(c),yt=Je(v),ht=Je(y);return(0,se.jsxs)("div",{className:Jt([ro.container,B,(0,h.A)((0,h.A)((0,h.A)({},ro["".concat(n,"Layout")],null!==n),ro.opened,Ce||re&&"intro"!==ve),ro.hasSelectedMarker,_)]),"data-screen-ready":Ge,children:[(0,se.jsx)(An,{width:U,height:Q,className:ro.content,children:ue?(0,se.jsx)(Pa,{className:ro.placeholder,withImages:x}):(0,se.jsxs)(se.Fragment,{children:[re?(0,se.jsx)(kn,{media:null!==t?{url:t,metadata:{width:Math.min(640,U),height:Math.min(640,Q)}}:null,width:U,height:Q,resolution:X,objectFit:{fit:"cover"}}):(0,se.jsx)(oo,{center:w,zoom:S,draggable:r,markers:Fe,fitBounds:j,onClickMarker:ze,onReady:Ne,onDragEnd:Ie},"map"),(0,se.jsx)("div",(0,i.A)((0,i.A)({className:ro.markerOverlayContainer},uo),{},{children:(0,se.jsx)("div",{className:ro.markerOverlayScrollable,children:(0,se.jsxs)(ei,{fullscreen:!0,disabled:pe,onScrolledBottom:Pe,children:[(0,se.jsx)(ca,{className:ro.markerOverlaySafe,onClick:Re,withoutStyle:!0,style:{height:Q*p},disabled:re,focusable:T&&oe}),(0,se.jsx)("div",{className:ro.markerOverlay,style:{minHeight:Q*(1-p)},children:(0,se.jsxs)("div",{className:ro.markerOverlayContent,style:ne,children:[(0,se.jsx)("div",{className:ro.swipeIndicator}),(0,se.jsxs)("div",{className:ro.markerOverlayContentInner,ref:Ve,children:[vt?(0,se.jsx)(kn,{className:ro.markerImage,media:ut,width:Oe,resolution:X}):null,dt?(0,se.jsx)(_n,(0,i.A)({className:ro.markerTitle},at)):null,ct?(0,se.jsx)(_n,(0,i.A)({size:3,className:ro.markerSubtitle},it)):null,mt?(0,se.jsx)(nn,(0,i.A)({className:ro.markerDescription},rt)):null]},"markerContent-".concat(W))]})})]})})}),"marker-overlay"),(0,se.jsxs)("div",{className:Jt([ro.splash]),children:[(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:ro.emptyTitle,isEmpty:!gt,children:(0,se.jsx)(_n,(0,i.A)({className:ro.title},c))}),(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"507VAi",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:ro.emptyDescription,isEmpty:!yt,children:(0,se.jsx)(nn,(0,i.A)({className:ro.description},v))}),(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"bv3rRe",defaultMessage:[{type:0,value:"Button"}]}),emptyClassName:ro.emptyButton,isEmpty:!ht,children:(0,se.jsx)(zn,{className:ro.splashButton,onClick:$e,buttonStyle:null!==y?y.buttonStyle:null,focusable:T&&oe,children:ht?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},y),{},{className:ro.button})):(0,se.jsx)(Wl.A,{id:"sXfFFw",defaultMessage:[{type:0,value:"Enter"}]})})})]},"splash"),ce||me||re||de?null:(0,se.jsx)(ca,{className:ro.closeButton,onClick:Le,focusable:T&&oe,children:"×"},"close-button")]})}),ue?null:(0,se.jsx)(hn,{color:{color:"#FFFFFF",alpha:1},width:U,height:Q,resolution:X,playing:be,muted:J,shouldLoad:xe,mediaRef:ee,withoutVideo:re,className:ro.background})]})}var vo=[{id:"map",type:"screen",group:{label:(0,ue.zR)({id:"Z27IP6",defaultMessage:[{type:0,value:"Map"}]}),order:6},title:(0,ue.zR)({id:"dPYwJG",defaultMessage:[{type:0,value:"Map"}]}),component:mo,layouts:["normal"],states:[{id:"intro",label:(0,ue.zR)({id:"BgrRxZ",defaultMessage:[{type:0,value:"Intro"}]}),fields:[{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"button",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]})}]},{id:"map",label:(0,ue.zR)({id:"eYHEYe",defaultMessage:[{type:0,value:"Map"}]}),fields:[{name:"draggable",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"A7ncT3",defaultMessage:[{type:0,value:"Draggable"}]})},{name:"fitBounds",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"NVUpOG",defaultMessage:[{type:0,value:"Map fit markers"}]})},{name:"zoom",type:"slider",defaultValue:9,min:0,max:16,label:(0,ue.zR)({id:"vRzzo6",defaultMessage:[{type:0,value:"Zoom"}]})},{name:"center",type:"geo-position",label:(0,ue.zR)({id:"W5qWPj",defaultMessage:[{type:0,value:"Center"}]})}]},{id:"markers",label:(0,ue.zR)({id:"+LvOvJ",defaultMessage:[{type:0,value:"Markers"}]}),repeatable:!0,fieldName:"markers",fields:[{name:"title",type:"heading-element",label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"geoPosition",type:"geo-position",label:(0,ue.zR)({id:"u3ok54",defaultMessage:[{type:0,value:"Position"}]})}]}],fields:[{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})}]},{id:"map-images",type:"screen",group:{label:(0,ue.zR)({id:"Z27IP6",defaultMessage:[{type:0,value:"Map"}]}),order:6},title:(0,ue.zR)({id:"ro6yHS",defaultMessage:[{type:0,value:"Map with image markers"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(mo,(0,i.A)((0,i.A)({},t),{},{withMarkerImages:!0}))},layouts:["normal"],states:[{id:"intro",label:(0,ue.zR)({id:"BgrRxZ",defaultMessage:[{type:0,value:"Intro"}]}),fields:[{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"button",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]})}]},{id:"map",label:(0,ue.zR)({id:"eYHEYe",defaultMessage:[{type:0,value:"Map"}]}),fields:[{name:"draggable",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"A7ncT3",defaultMessage:[{type:0,value:"Draggable"}]})},{name:"fitBounds",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"NVUpOG",defaultMessage:[{type:0,value:"Map fit markers"}]})},{name:"zoom",type:"slider",defaultValue:9,min:0,max:16,label:(0,ue.zR)({id:"vRzzo6",defaultMessage:[{type:0,value:"Zoom"}]})},{name:"center",type:"geo-position",label:(0,ue.zR)({id:"W5qWPj",defaultMessage:[{type:0,value:"Center"}]})}]},{id:"markers-with-image",label:(0,ue.zR)({id:"+LvOvJ",defaultMessage:[{type:0,value:"Markers"}]}),repeatable:!0,fieldName:"markers",fields:[{name:"title",type:"heading-element",label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"geoPosition",type:"geo-position",label:(0,ue.zR)({id:"u3ok54",defaultMessage:[{type:0,value:"Position"}]})}]}],fields:[{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})}]}],go=l(5979),yo=l(2802),ho=l(8842),fo=l(3700),po={container:"micromag-screen-quiz-answers-container",items:"micromag-screen-quiz-answers-items",emptyAnswer:"micromag-screen-quiz-answers-emptyAnswer",item:"micromag-screen-quiz-answers-item",isPlaceholder:"micromag-screen-quiz-answers-isPlaceholder",userAnswer:"micromag-screen-quiz-answers-userAnswer",otherAnswer:"micromag-screen-quiz-answers-otherAnswer",withoutOpacity:"micromag-screen-quiz-answers-withoutOpacity",button:"micromag-screen-quiz-answers-button",withIcon:"micromag-screen-quiz-answers-withIcon",withSquareItems:"micromag-screen-quiz-answers-withSquareItems",resultIcon:"micromag-screen-quiz-answers-resultIcon",answered:"micromag-screen-quiz-answers-answered",rightAnswer:"micromag-screen-quiz-answers-rightAnswer",faIcon:"micromag-screen-quiz-answers-faIcon",itemContent:"micromag-screen-quiz-answers-itemContent"};function bo(e){var t=e.items,l=e.keypadLayout,n=void 0===l?null:l,r=e.answeredIndex,s=void 0===r?null:r,u=e.answersCollapseDelay,d=void 0===u?1e3:u,c=e.buttonsStyle,m=void 0===c?null:c,v=e.buttonsLayout,g=void 0===v?null:v,y=e.inactiveButtonsStyle,f=void 0===y?null:y,p=e.buttonsTextStyle,b=void 0===p?null:p,x=e.inactiveButtonsTextStyle,A=void 0===x?null:x,S=e.goodAnswerColor,C=void 0===S?null:S,w=e.badAnswerColor,k=void 0===w?null:w,j=e.showUserAnswer,M=void 0!==j&&j,N=e.withoutGoodAnswer,F=void 0!==N&&N,T=e.withoutIcon,z=void 0!==T&&T,$=e.focusable,L=void 0!==$&&$,I=e.animated,P=void 0!==I&&I,B=e.collapsed,E=void 0!==B&&B,V=e.onClick,D=void 0===V?null:V,O=e.onCollapse,H=void 0===O?null:O,Z=e.onCollapsed,W=void 0===Z?null:Z,q=e.onTransitionEnd,_=void 0===q?null:q,G=e.withoutCollapse,Y=void 0!==G&&G,U=e.className,Q=void 0===U?null:U,X=Rt(),J=X.isView,K=X.isPreview,ee=X.isPlaceholder,te=X.isEdit,le=null!==s,ae=(null!==s?t[s]:{}).good,ne=void 0!==ae&&ae,ie=(0,a.useState)(!0),oe=(0,R.A)(ie,1)[0],re=null!==t&&!ee&&t.reduce(function(e,t){var l=(t||{}).good;return e||void 0!==l&&l},!1),ue=M||!re,de=!F||ue&&null!==s&&!Y,ce=(0,a.useState)(null!==s),me=(0,R.A)(ce,2),ve=me[0],ge=me[1],ye=(0,a.useState)(E||null!==s),he=(0,R.A)(ye,2),fe=he[0];he[1];var pe=(0,a.useState)(E||null!==s),be=(0,R.A)(pe,2),xe=be[0],Ae=be[1];(0,a.useEffect)(function(){var e=null;return null!==s&&de?e=setTimeout(function(){ge(!0),null!==H&&H()},ne||ue?500:d):null===s||de?null===s&&de&&ge(!1):e=setTimeout(function(){null!==H&&H(),null!==W&&W(),null!==_&&_()},d),function(){null!==e&&clearTimeout(e)}},[s,F,ge,H,W,_,d,ne,ue,de]),(0,a.useEffect)(function(){var e=null,t=null;return ve&&(e=setTimeout(function(){Ae(!0)},300),t=setTimeout(function(){null!==_&&_()},500)),function(){null!==e&&clearTimeout(e),null!==t&&clearTimeout(t)}},[ve,_,Ae]);var Se=(0,a.useRef)([]),Ce=ee||te&&0===t.length?(0,o.A)(new Array(2)):t,we=(0,a.useMemo)(function(){return P?Ce.reduce(function(e,t,l){if(Se.current[l]&&P){var a=(Se.current[l].getBoundingClientRect()||{}).height,n=void 0===a?0:a;e.push(n)}return e},[]):[]},[P,s,de,P,Ce]),ke=J||te,je=Ce.map(function(e,t){var l=we[t]?we[t]:0,a=t===s,n=(e||{}).good,o=void 0!==n&&n,r=!1;null===s||!ke||!fe||o||!re&&a||(r=!0),null!==s&&ke&&ve&&!o&&(r=!0);var u=(e||{}).label,d=void 0===u?null:u,c="key-".concat(t,"-").concat((null==d?void 0:d.body)||null);return(0,i.A)((0,i.A)({},e),{},{hidden:r,userAnswer:a,index:t,maxHeight:l,key:c})}),Me=(0,a.useMemo)(function(){return null!==je&&je.reduce(function(e,t){return e||!0===t.good&&!F||!1===t.good&&!z},!1)},[je,F,z]),Ne=(0,a.useMemo)(function(){var e=(f||{}).backgroundColor;return null===(void 0===e?null:e)},[f]),Fe=(je.map(function(e){var t=e||{},l=t.hidden,a=t.maxHeight,n={opacity:l&&ke&&!F?0:1,maxHeight:l&&ke&&!F&&P&&xe?0:a>0?a:null,height:l&&ke&&!F&&!P&&xe?0:"auto"};return(0,i.A)((0,i.A)({},e),{},{style:n})})||[]).map(function(e,t){var l=t===s,a=e||{},n=a.good,o=void 0===n?null:n,r=a.label,u=void 0===r?null:r,d=a.visual,c=void 0===d?null:d,v=a.buttonLayout,y=void 0===v?null:v,p=a.buttonStyle,x=void 0===p?null:p,S=a.textStyle,w=void 0===S?null:S,j=a.style,M=void 0===j?null:j,N=(u||{}).textStyle,T=void 0===N?null:N,R=Je(u),$=Qe(c),I=R||$,P=F&&l,B=F&&!l,E=B&&null!==s,V=E?f:null,O=E?A:null,H=(0,i.A)((0,i.A)((0,i.A)({},m),V),x),Z=(0,i.A)((0,i.A)((0,i.A)((0,i.A)({},Object.keys(b||{}).reduce(function(e,t){var l=b[t];return null!==l&&""!==l&&(e[t]=l),e},{})),Object.keys(T||{}).reduce(function(e,t){var l=T[t];return null!==l&&""!==l&&(e[t]=l),e},{})),O),w);return(0,se.jsx)("div",{className:Jt([po.item,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},po.rightAnswer,!F&&!0===o),po.userAnswer,P),po.otherAnswer,B),po.withoutOpacity,!Ne)]),style:(0,i.A)({},M),children:(0,se.jsx)("div",{className:po.itemContent,ref:function(e){Se.current[t]=e},children:(0,se.jsx)(Qa,{placeholder:"quizAnswer",placeholderProps:{good:0===t},emptyLabel:(0,se.jsx)(Wl.A,{id:"+Ok+7S",defaultMessage:[{type:0,value:"Answer"}]}),emptyClassName:po.emptyAnswer,isEmpty:!I,children:I?(0,se.jsxs)(Ln,{className:po.button,onPointerUp:function(l){"mouse"===l.pointerType&&0!==l.button||D(e,t)},disabled:!oe||K||le,focusable:L,buttonStyle:H,textStyle:Z,label:u,visual:c,visualClassName:po.optionVisual,imageClassName:po.optionImage,layout:y||g||($?"label-right":null),children:[le&&!z&&!0===o?(0,se.jsx)("span",{className:po.resultIcon,style:Ee(C,"backgroundColor"),children:(0,se.jsx)(yo.gc,{className:po.faIcon,icon:ho.e6})}):null,!z&&le&&!1===o?(0,se.jsx)("span",{className:po.resultIcon,style:Ee(k,"backgroundColor"),children:(0,se.jsx)(yo.gc,{className:po.faIcon,icon:fo.GR})}):null]}):null})})},"answer-".concat(t))}),Te=n||{},Re=Te.columnAlign,ze=void 0===Re?null:Re,$e=Te.columns,Le=void 0===$e?1:$e,Ie=Te.spacing,Pe=void 0===Ie?null:Ie,Be=Te.withSquareItems,Ve=void 0!==Be&&Be;return(0,se.jsx)("div",{className:Jt([po.container,Q,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},po.answered,le),po.withIcon,!z&&Me),po.withSquareItems,!0===Ve),po.isPlaceholder,ee)]),children:null!==je||ee?(0,se.jsx)(Ui,{className:po.items,items:Fe,align:ze,columns:Le,spacing:Pe}):null})}var xo={container:"micromag-screen-quiz-question-container",question:"micromag-screen-quiz-question-question",index:"micromag-screen-quiz-question-index",resultContent:"micromag-screen-quiz-question-resultContent",result:"micromag-screen-quiz-question-result",emptyQuestion:"micromag-screen-quiz-question-emptyQuestion",emptyResult:"micromag-screen-quiz-question-emptyResult",resultVisible:"micromag-screen-quiz-question-resultVisible",resultHidden:"micromag-screen-quiz-question-resultHidden",isPlaceholder:"micromag-screen-quiz-question-isPlaceholder"};function Ao(e){var t=e.question,l=void 0===t?null:t,n=e.answers,o=void 0===n?null:n,r=e.keypadLayout,s=void 0===r?null:r,u=e.result,d=void 0===u?null:u,c=e.resultImage,m=void 0===c?null:c,v=e.index,g=void 0===v?null:v,y=e.totalCount,f=void 0===y?null:y,p=e.answeredIndex,b=void 0===p?null:p,x=e.buttonsLayout,A=void 0===x?null:x,S=e.buttonsStyle,C=void 0===S?null:S,w=e.inactiveButtonsStyle,k=void 0===w?null:w,j=e.buttonsTextStyle,M=void 0===j?null:j,N=e.inactiveButtonsTextStyle,F=void 0===N?null:N,T=e.questionsHeadingStyle,z=void 0===T?null:T,$=e.feedbackTextStyle,L=void 0===$?null:$,I=e.numbersTextStyle,P=void 0===I?null:I,B=e.goodAnswerColor,E=void 0===B?null:B,V=e.badAnswerColor,D=void 0===V?null:V,O=e.focusable,H=void 0!==O&&O,Z=e.animated,W=void 0!==Z&&Z,q=e.showInstantAnswer,_=void 0!==q&&q,G=e.withResult,Y=void 0!==G&&G,U=e.withoutGoodAnswer,Q=void 0!==U&&U,X=e.withoutTrueFalse,J=void 0!==X&&X,K=e.withoutIndex,ee=void 0!==K&&K,te=e.layout,le=void 0===te?null:te,ae=e.transitions,ne=void 0===ae?null:ae,ie=e.transitionPlaying,oe=void 0!==ie&&ie,re=e.transitionStagger,ue=void 0===re?100:re,de=e.transitionDisabled,ce=void 0!==de&&de,me=e.onAnswerClick,ve=void 0===me?null:me,ge=e.onAnswerTransitionEnd,ye=void 0===ge?null:ge,he=e.withoutCollapse,fe=void 0!==he&&he,pe=e.className,be=void 0===pe?null:pe,xe=e.style,Ae=void 0===xe?null:xe,Se=Rt().isPlaceholder,Ce="split"===le,we=Ce?null:le,ke=Je(l),je=(l||{}).textStyle,Me=void 0===je?null:je,Ne=(0,a.useState)(_),Fe=(0,R.A)(Ne,2),Te=Fe[0],Re=Fe[1],ze=null!==b,$e=(null!==b&&o[b]?o[b]:null)||{},Le=$e.result,Ie=void 0===Le?null:Le,Pe=$e.answerImage,Be=void 0===Pe?null:Pe,Ee=Je(Ie)||Je(d),Ve=Qe(Be)||Qe(m),De=Je(d)?d:null,Oe=(Je(Ie)?Ie:null)||De,He=(Oe||{}).textStyle,Ze=void 0===He?null:He,We=(0,a.useCallback)(function(){Re(!0)},[Re]),qe=null!==g&&null!==f;return(0,se.jsx)(Qn,{className:Jt([xo.container,be,(0,h.A)((0,h.A)((0,h.A)({},xo.isPlaceholder,Se),xo.resultVisible,Te),xo.resultHidden,!Ee)]),verticalAlign:we,style:Ae,children:[!ee&&qe?(0,se.jsx)(Qa,{placeholder:(0,se.jsx)("div",{className:xo.index,children:"1 / 10"}),children:f>1?(0,se.jsx)(Ka,{transitions:ne,playing:oe,disabled:ce,children:(0,se.jsx)(nn,{className:xo.index,body:"".concat(g+1," / ").concat(f),textStyle:P})}):null},"stats"):null,(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"FOmgqv",defaultMessage:[{type:0,value:"Question"}]}),emptyClassName:xo.emptyQuestion,isEmpty:!ke,children:ke?(0,se.jsx)(Ka,{transitions:ne,playing:oe,disabled:ce,children:(0,se.jsx)(_n,(0,i.A)((0,i.A)({},l),{},{className:xo.question,textStyle:(0,i.A)((0,i.A)({},z),Me)}))}):null},"question"),Ce?(0,se.jsx)(Un,{},"spacer"):null,(0,se.jsx)(bo,{items:o||[],keypadLayout:s,answeredIndex:b,goodAnswerColor:E,badAnswerColor:D,withoutGoodAnswer:Q,withoutIcon:J,showUserAnswer:J,buttonsLayout:A,buttonsStyle:C,inactiveButtonsStyle:k,buttonsTextStyle:M,inactiveButtonsTextStyle:F,focusable:H,animated:W,transitions:ne,transitionStagger:ue,transitionPlaying:oe,transitionDisabled:ce,onClick:ve,onCollapse:We,onTransitionEnd:ye,withoutCollapse:fe},"answers"),Y?(0,se.jsx)("div",{className:xo.result,children:(0,se.jsx)("div",{className:xo.resultContent,children:(0,se.jsx)(Qa,{emptyLabel:ze?(0,se.jsx)(Wl.A,{id:"li7ADr",defaultMessage:[{type:0,value:"Result"}]}):null,isEmpty:ze&&!Ee,emptyClassName:xo.emptyResult,children:(Ee||Ve)&&null!==o?(0,se.jsxs)(Ka,{transitions:ne,playing:oe,delay:(1+o.length)*ue,disabled:ce,children:[Ee?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},Oe||{}),{},{className:xo.resultText,textStyle:(0,i.A)((0,i.A)({},L||null),Ze||null)})):null,Ve?(0,se.jsx)(Nn,{media:Be||m,width:"100%",height:"auto"}):null]}):null})})},"results"):null]})}var So={container:"micromag-screen-quiz-container",background:"micromag-screen-quiz-background",content:"micromag-screen-quiz-content",disabled:"micromag-screen-quiz-disabled",reset:"micromag-screen-quiz-reset",points:"micromag-screen-quiz-points",header:"micromag-screen-quiz-header",footer:"micromag-screen-quiz-footer",nextButton:"micromag-screen-quiz-nextButton",question:"micromag-screen-quiz-question",results:"micromag-screen-quiz-results",intro:"micromag-screen-quiz-intro"},Co={container:"micromag-screen-quiz-results-container",title:"micromag-screen-quiz-results-title",emptyTitle:"micromag-screen-quiz-results-emptyTitle",emptyDescription:"micromag-screen-quiz-results-emptyDescription"};function wo(e){var t=e.layout,l=void 0===t?null:t,a=e.title,n=void 0===a?null:a,o=e.description,r=void 0===o?null:o,s=e.resultsHeadingStyle,u=void 0===s?null:s,d=e.resultsTextStyle,c=void 0===d?null:d,m=e.transitions,v=void 0===m?null:m,g=e.transitionPlaying,y=void 0!==g&&g,h=e.transitionStagger,f=void 0===h?100:h,p=e.transitionDisabled,b=void 0!==p&&p,x=e.className,A=void 0===x?null:x,S=e.style,C=void 0===S?null:S,w="split"===l,k=w?null:l,j=Je(n),M=(n||{}).textStyle,N=void 0===M?null:M,F=Je(r),T=(r||{}).textStyle,R=void 0===T?null:T;return(0,se.jsx)(Qn,{className:Jt([Co.container,A]),fullscreen:!0,verticalAlign:k,style:C,children:[(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"BSTWf8",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Co.emptyTitle,isEmpty:!j,children:j?(0,se.jsx)(Ka,{transitions:v,playing:y,disabled:b,children:(0,se.jsx)(_n,(0,i.A)((0,i.A)({},n),{},{className:Co.title,textStyle:(0,i.A)((0,i.A)({},u),N)}))}):null},"title"),w?(0,se.jsx)(Un,{},"spacer"):null,(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"hoDz0O",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:Co.emptyDescription,isEmpty:!F,children:j?(0,se.jsx)(Ka,{transitions:v,playing:y,disabled:b,delay:f,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},r),{},{className:Co.description,textStyle:(0,i.A)((0,i.A)({},c),R)}))}):null},"description")]})}var ko={container:"micromag-screen-quiz-title-container",title:"micromag-screen-quiz-title-title",description:"micromag-screen-quiz-title-description",emptyTitle:"micromag-screen-quiz-title-emptyTitle",emptyDescription:"micromag-screen-quiz-title-emptyDescription"};function jo(e){var t=e.layout,l=void 0===t?null:t,a=e.title,n=void 0===a?null:a,o=e.description,r=void 0===o?null:o,s=e.button,u=void 0===s?null:s,d=e.buttonDisabled,c=void 0!==d&&d,m=e.focusable,v=void 0!==m&&m,g=e.className,y=void 0===g?null:g,h=e.style,f=void 0===h?null:h,p=e.onClickButton,b=void 0===p?null:p,x="split"===l,A=x?null:l,S=Je(n),C=Je(r),w=Je(u);return(0,se.jsx)(Qn,{className:Jt([ko.container,y]),fullscreen:!0,verticalAlign:A,style:f,children:[(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"BSTWf8",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:ko.emptyTitle,isEmpty:!S,children:S?(0,se.jsx)(_n,(0,i.A)((0,i.A)({},n),{},{className:ko.title})):null},"title"),(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"hoDz0O",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:ko.emptyDescription,isEmpty:!C,children:C?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},r),{},{className:ko.description})):null},"description"),x?(0,se.jsx)(Un,{},"spacer"):null,(0,se.jsx)(Qa,{placeholder:"button",children:(0,se.jsx)(zn,{disabled:c,focusable:v,buttonStyle:null!==u?u.buttonStyle:null,className:ko.button,onClick:b,children:w?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},u),{},{className:ko.label})):(0,se.jsx)(Wl.A,{id:"D7LIZQ",defaultMessage:[{type:0,value:"Start"}]})})},"button")]})}var Mo=[{id:"quiz",type:"screen",group:{label:(0,ue.zR)({id:"ZiWlL6",defaultMessage:[{type:0,value:"Questions"}]}),order:7},title:(0,ue.zR)({id:"zW7IVm",defaultMessage:[{type:0,value:"Quiz"}]}),component:function(e){var t=e.id,l=void 0===t?null:t,n=e.layout,o=void 0===n?"middle":n,r=e.keypadLayout,s=void 0===r?null:r,u=e.question,d=void 0===u?null:u,c=e.answers,m=void 0===c?null:c,v=e.result,g=void 0===v?null:v,y=e.resultImage,f=void 0===y?null:y,p=e.buttonsLayout,b=void 0===p?null:p,x=e.buttonsStyle,A=void 0===x?null:x,S=e.inactiveButtonsStyle,C=void 0===S?null:S,w=e.buttonsTextStyle,k=void 0===w?null:w,j=e.inactiveButtonsTextStyle,M=void 0===j?null:j,N=e.feedbackTextStyle,F=void 0===N?null:N,T=e.numbersTextStyle,z=void 0===T?null:T,$=e.goodAnswerColor,L=void 0===$?null:$,I=e.badAnswerColor,P=void 0===I?null:I,B=e.withoutTrueFalse,E=void 0!==B&&B,V=e.spacing,D=void 0===V?20:V,O=e.header,H=void 0===O?null:O,Z=e.footer,W=void 0===Z?null:Z,q=e.background,_=void 0===q?null:q,G=e.current,Y=void 0===G||G,U=e.preload,Q=void 0===U||U,X=e.ready,J=void 0===X||X,K=e.transitions,ee=void 0===K?null:K,te=e.transitionStagger,le=void 0===te?100:te,ae=e.type,ne=void 0===ae?null:ae,ie=e.className,oe=void 0===ie?null:ie,re=l||"screen-id",ue=$l(ne),de=It(),ce=de.width,me=de.height,ve=de.resolution,ge=Rt(),ye=ge.isView,he=ge.isPreview,fe=ge.isPlaceholder,pe=ge.isEdit,be=ge.isStatic,xe=ge.isCapture,Ae=!J,Se=Ot(),Ce=Se.topHeight,we=Se.bottomHeight,ke=Se.bottomSidesWidth,je=qt().open,Me=jt().muted,Ne=Mt(Y,!0),Fe=Ne.ref,Te=Ne.isCurrent,Re=Y&&J,$e=be||xe||fe||he||pe,Le=Y&&(ye||pe)&&(void 0!==Te&&Te||!ye),Ie=Y||Q,Pe=Ge(H),Be=Ye(W),Ee=ze(W,{isView:ye,current:Y,openWebView:je,isPreview:he}),Ve=pl(),De=Ve.ref,Oe=Ve.height,He=void 0===Oe?0:Oe,Ze=pl(),We=Ze.ref,qe=Ze.height,_e=void 0===qe?0:qe,Ue=be||xe,Qe=null!==m?m.findIndex(function(e){return null!==e&&e.good}):null,Xe=null===Qe||-1===Qe,Je=(0,a.useState)(Ue?Qe:null),Ke=(0,R.A)(Je,2),et=Ke[0],tt=Ke[1],lt=xi({screenId:re}).create,at=(0,a.useCallback)(function(e,t){null===et&&(tt(t),ue("click_answer","".concat(et+1,": ").concat(e.label.body),{linkType:"quiz_answer",answer:e,answerIndex:t,isGood:e.good||!1}))},[et,tt,ue,m]);(0,a.useEffect)(function(){!Y&&pe&&null!==et&&tt(null)},[pe,Y,et,tt]),(0,a.useEffect)(function(){if(ye&&null!==et){var e=null!==et&&m?m[et]:{},t=e.good,l=void 0!==t&&t,a=e.label,n=((void 0===a?{}:a)||{}).body;lt({choice:(void 0===n?"":n)||et,value:l?1:0})}},[ye,et,m,lt]);var nt=!pe&&$e||!Y,it=(0,a.useState)(!1),ot=(0,R.A)(it,2),rt=ot[0],st=ot[1],ut=(0,a.useCallback)(function(e){e.initial&&ue("scroll","Screen"),st(!0)},[ue]),dt=(0,a.useCallback)(function(){st(!1)},[st]),ct=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);ue("scroll",t,{scrollPercent:t})}},[ue]),mt=(0,a.useState)(!1),vt=(0,R.A)(mt,2),gt=vt[0],yt=vt[1],ht=(0,a.useCallback)(function(e){var t=e.canScroll;yt(void 0!==t&&t)},[yt]),ft=(0,a.useCallback)(function(){tt(null)},[tt]),pt=(m||[]).length;(0,a.useEffect)(function(){ft()},[pt,ft]);var bt="split"===o?null:o,xt=pe&&null!==et;return(0,se.jsxs)("div",{className:Jt([So.container,oe,(0,h.A)({},So.disabled,Ae)]),"data-screen-ready":!0,children:[(0,se.jsxs)(An,{width:ce,height:me,className:So.content,children:[xt?(0,se.jsx)(ca,{className:So.reset,icon:(0,se.jsx)(yo.gc,{icon:go.ye,size:"md"}),onClick:ft}):null,(0,se.jsxs)(ei,{verticalAlign:bt,disabled:nt,onScrolledTrigger:ct,onScrolledBottom:ut,onScrolledNotBottom:dt,onScrollHeightChange:ht,withShadow:!0,children:[!fe&&Pe?(0,se.jsx)("div",{className:Jt([So.header,(0,h.A)({},So.disabled,null!==et||rt&&!nt&>)]),ref:De,style:{paddingTop:D/2,paddingLeft:D,paddingRight:D,paddingBottom:D,transform:he?null:"translate(0, ".concat(Ce,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},H))}):null,(0,se.jsx)(Ao,{question:d,answers:m,keypadLayout:s,result:g,resultImage:f,answeredIndex:et,buttonsLayout:b,buttonsStyle:A,buttonsTextStyle:k,inactiveButtonsStyle:C,inactiveButtonsTextStyle:M,feedbackTextStyle:F,numbersTextStyle:z,goodAnswerColor:L,badAnswerColor:P,withoutTrueFalse:E,withoutGoodAnswer:Xe,focusable:Y&&ye,animated:ye,showInstantAnswer:Ue,withResult:!0,layout:o,transitions:ee,transitionPlaying:Re,transitionStagger:le,transitionDisabled:$e,onAnswerClick:at,className:So.question,style:fe?null:{padding:D,paddingTop:(he?0:Ce)+(He||D),paddingBottom:(Y&&!he?we:0)+(_e||D)}})]}),!fe&&Be?(0,se.jsx)("div",{ref:We,className:Jt([So.footer,(0,h.A)({},So.disabled,!rt&>)]),style:{transform:Y&&!he?"translate(0, -".concat(we,"px)"):null,paddingLeft:Math.max(D/2,ke),paddingRight:Math.max(D/2,ke),paddingTop:D/2,paddingBottom:D/2},children:(0,se.jsx)(Dn,(0,i.A)({},Ee))}):null]}),fe?null:(0,se.jsx)(pn,{background:_,width:ce,height:me,resolution:ve,playing:Le,muted:Me,shouldLoad:Ie,mediaRef:Fe,withoutVideo:he,className:So.background})]})},layouts:["top","middle","bottom","split"],fields:[{name:"question",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"hVE7TA",defaultMessage:[{type:0,value:"Question"}]})},{name:"answers",type:"quiz-answers",theme:{label:{textStyle:"button"}},label:(0,ue.zR)({id:"KHWeV7",defaultMessage:[{type:0,value:"Answers"}]})},{name:"keypadLayout",type:"keypad-layout",isList:!0,defaultValue:{columnAlign:"middle",columns:1,spacing:10,withSquareItems:!1},label:(0,ue.zR)({id:"FjuRaw",defaultMessage:[{type:0,value:"Keypad settings"}]})},{name:"withoutTrueFalse",type:"toggle",label:(0,ue.zR)({id:"LFziCV",defaultMessage:[{type:0,value:"Without right/wrong icon"}]})},{name:"result",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"iQ5Uf7",defaultMessage:[{type:0,value:"Default feedback"}]})},{name:"resultImage",type:"visual",label:(0,ue.zR)({id:"yA4B6h",defaultMessage:[{type:0,value:"Result feedback image"}]})},{type:"fields",isList:!0,label:(0,ue.zR)({id:"R9DB4a",defaultMessage:[{type:0,value:"Styles"}]}),fields:[{name:"buttonsLayout",type:"button-layout",label:(0,ue.zR)({id:"8Dmlwh",defaultMessage:[{type:0,value:"Answer button layout"}]})},{name:"buttonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"gwPu/I",defaultMessage:[{type:0,value:"Buttons text"}]})},{name:"buttonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"l5uLMd",defaultMessage:[{type:0,value:"Buttons"}]})},{name:"inactiveButtonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"my7Kox",defaultMessage:[{type:0,value:"Inactive buttons text"}]})},{name:"inactiveButtonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"xlFOg3",defaultMessage:[{type:0,value:"Inactive buttons"}]})},{name:"feedbackTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"4w7K2K",defaultMessage:[{type:0,value:"Feedback text"}]})},{name:"goodAnswerColor",type:"color",label:(0,ue.zR)({id:"hZcXoa",defaultMessage:[{type:0,value:"Good answer icon color"}]})},{name:"badAnswerColor",type:"color",label:(0,ue.zR)({id:"NbTtNk",defaultMessage:[{type:0,value:"Bad answer icon color"}]})}]},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"quiz-multiple",type:"screen",group:{label:(0,ue.zR)({id:"ZiWlL6",defaultMessage:[{type:0,value:"Questions"}]}),order:7},title:(0,ue.zR)({id:"ACkeH6",defaultMessage:[{type:0,value:"Quiz with multiple questions"}]}),component:function(e){var t=e.id,l=void 0===t?null:t,n=e.layout,o=void 0===n?"middle":n,r=e.introLayout,s=void 0===r?null:r,u=e.title,d=void 0===u?null:u,c=e.description,m=void 0===c?null:c,v=e.questions,g=void 0===v?null:v,y=e.results,f=void 0===y?null:y,p=e.buttonsStyle,x=void 0===p?null:p,A=e.inactiveButtonsStyle,S=void 0===A?null:A,C=e.buttonsTextStyle,w=void 0===C?null:C,k=e.inactiveButtonsTextStyle,j=void 0===k?null:k,M=e.questionsHeadingStyle,N=void 0===M?null:M,F=e.resultsHeadingStyle,T=void 0===F?null:F,z=e.resultsTextStyle,$=void 0===z?null:z,L=e.feedbackTextStyle,I=void 0===L?null:L,P=e.numbersTextStyle,B=void 0===P?null:P,E=e.goodAnswerColor,V=void 0===E?null:E,D=e.badAnswerColor,O=void 0===D?null:D,H=e.spacing,Z=void 0===H?20:H,W=e.background,q=void 0===W?null:W,_=e.introBackground,G=void 0===_?null:_,Y=e.introButton,U=void 0===Y?null:Y,Q=e.nextButton,X=void 0===Q?null:Q,J=e.header,K=void 0===J?null:J,ee=e.footer,te=void 0===ee?null:ee,le=e.current,ae=void 0===le||le,ne=e.active,ie=void 0===ne||ne,oe=e.transitions,re=void 0===oe?null:oe,ue=e.transitionStagger,de=void 0===ue?100:ue,ce=e.type,me=void 0===ce?null:ce,ve=e.className,ge=void 0===ve?null:ve,ye=l||"screen-id",he=$l(me),fe=It(),pe=fe.width,be=fe.height,xe=fe.resolution,Ae=Ot(),Se=Ae.topHeight,Ce=Ae.bottomHeight,we=Ae.bottomSidesWidth,ke=Rt(),je=ke.isView,Me=ke.isPreview,Ne=ke.isPlaceholder,Fe=ke.isEdit,Te=ke.isStatic,Re=ke.isCapture,$e=jt().muted,Le=qt().open,Ie=zt(),Pe=null!==Ie?Ie.split("."):[],Be=(0,R.A)(Pe,2),Ee=Be[0],Ve=void 0===Ee?null:Ee,De=Be[1],Oe=void 0===De?0:De,He=ae,Ze=Te||Re||Ne||Me||Fe,We=Je(X),qe=Ge(K),_e=Ye(te),Ue=ze(te,{isView:je,current:ae,openWebView:Le,isPreview:Me}),Xe=pl(),Ke=Xe.ref,et=Xe.height,tt=void 0===et?0:et,lt=pl(),at=lt.ref,nt=lt.height,it=void 0===nt?0:nt,ot=Te||Re,rt=null!==d||null!==m||Fe||"intro"===Ve,st=(0,a.useState)(null),ut=(0,R.A)(st,2),dt=ut[0],ct=ut[1],mt="intro";null!==Ve?mt="questions"===Ve?parseInt(Oe,10):Ve:!Ne&&rt||(mt=0);var vt=(0,a.useState)(mt),gt=(0,R.A)(vt,2),yt=gt[0],ht=gt[1];(0,a.useEffect)(function(){Me&&rt&&"intro"!==yt&&ht("intro")},[Me,rt,yt,ht]);var ft=(0,a.useCallback)(function(e,t){ct((0,i.A)((0,i.A)({},dt),{},(0,h.A)({},yt,t))),he("click_answer","Question #".concat(yt+1," ").concat(t+1,": ").concat(e.label.body),{linkType:"quiz_answer",question:g[yt],questionIndex:yt,answer:e,answerIndex:t})},[dt,ct,he,g,yt]),pt=(0,a.useCallback)(function(){ht(0)},[ht]);(0,a.useEffect)(function(){!ae&&Fe&&null!==dt&&ct(null)},[Fe,ae,dt,ct]);var bt=null!==g&&g.length>0&&g[yt]||{}||{},xt=bt.text,At=void 0===xt?null:xt,St=bt.answers,Ct=void 0===St?[]:St,wt=bt.background,kt=void 0===wt?null:wt,Nt=bt.layout,Ft=void 0===Nt?null:Nt,Tt=bt.keypadLayout,$t=void 0===Tt?null:Tt,Lt=bt.result,Pt=void 0===Lt?null:Lt,Bt=bt.resultImage,Et=void 0===Bt?null:Bt,Vt=null!==dt&&void 0!==dt[yt]?dt[yt]:null,Dt=((null!==Vt&&void 0!==Ct[Vt]?Ct[Vt]:null)||{}).result,Ht=void 0===Dt?null:Dt,Zt=null!==Ct&&void 0!==(Ct||[]).find(function(e){return!0===(null==e?void 0:e.good)||!1===(null==e?void 0:e.good)}),Wt=null!==Ct?Ct.findIndex(function(e){return null!==e&&!0===e.good}):null,_t=null===Wt||-1===Wt,Gt=Je(Pt),Yt=Qe(Et),Ut=Je(Ht),Qt=Gt||Yt||Ut,Xt=(0,a.useCallback)(function(){if(!Fe&&!Me){var e=yt+1,t=g.length;e<t?ht(e):e===t&&ht("results")}},[g,yt,ht,Fe,Me]),Kt=(0,a.useMemo)(function(){return null!==dt?Object.keys(dt).reduce(function(e,t){var l=(null!==g&&g[t]||{}).answers,a=((void 0===l?[]:l)[dt[t]]||{}).points;return(void 0===a?0:a)+e},0):0},[dt,g]),el=rt&&"intro"===yt,tl="results"===yt,ll=!el&&!tl,al=(0,a.useMemo)(function(){return tl?"results"===Ve?(f||[])[parseInt(Oe,10)]||null:(f||[]).sort(function(e,t){var l=e.points,a=void 0===l?0:l,n=t.points,i=void 0===n?0:n;return a===i?0:a>i?1:-1}).reduce(function(e,t){var l=(e||{}).points,a=void 0===l?0:l,n=(t||{}).points;return Kt>=(a||0)&&Kt>=(void 0===n?0:n)?t:e},null):null},[tl,f,Kt,Ve,Oe]);(0,a.useEffect)(function(){if(null!==al&&tl){var e=al||{},t=e.title,l=void 0===t?null:t,a=e.points,n=void 0===a?null:a;he("view_result","Result: ".concat((null==l?void 0:l.body)||"No title"),{resultPoints:n||null,userPoints:Kt||null})}},[al,Kt,tl,he]);var nl=al||{},il=nl.background,ol=void 0===il?null:il,rl=nl.layout,sl=void 0===rl?null:rl,ul=xi({screenId:ye}).create;(0,a.useEffect)(function(){if(tl&&je){var e=b(dt)?JSON.stringify(dt):dt;ul({choice:e,value:Kt})}},[je,tl,dt,ul]),(0,a.useEffect)(function(){(Fe||Me)&&("questions"===Ve?ht(parseInt(Oe,10)):"results"===Ve?ht("results"):"intro"===Ve&&ht("intro"))},[Ve,Oe,Fe,Me,ht]);var dl=q,cl="background";el&&null!==G?(dl=G,cl="results"):tl&&null!==ol?(dl=ol,cl="results"):ll&&null!==kt&&(dl=kt,cl="question_".concat(yt));var ml=Mt(ae,null!==dl,cl),vl=ml.ref,gl=ml.isCurrent,yl=ae&&(je||Fe)&&(void 0!==gl&&gl||!je),hl=ae||ie,fl=(0,a.useRef)(yt),bl=(0,a.useMemo)(function(){if(yt===fl.current)return null;var e=fl.current;return fl.current=yt,"intro"===yt||"results"===e||e>yt?"left":(fl.current=yt,"right")},[yt]),xl=!Fe&&Ze||!ae||el,Al=(0,a.useState)(!1),Sl=(0,R.A)(Al,2),Cl=Sl[0],wl=Sl[1],kl=(0,a.useCallback)(function(e){e.initial&&he("scroll","Screen"),wl(!0)},[he]),jl=(0,a.useCallback)(function(){wl(!1)},[wl]),Ml=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);he("scroll",t,{scrollPercent:t})}},[he]),Nl=(0,a.useState)(!1),Fl=(0,R.A)(Nl,2),Tl=Fl[0],Rl=Fl[1],zl=(0,a.useCallback)(function(e){var t=e.canScroll;Rl(void 0!==t&&t)},[Rl]),Ll=(0,a.useCallback)(function(){ct(null)},[ct]),Il=o;el&&null!==s?Il=s:(ll&&null!==Ft||tl&&null!==sl)&&(Il=Ft);var Pl=Fe,Bl=Fe&&null!==Vt,El=[];el&&El.push({key:"intro",element:(0,se.jsx)(jo,{title:d,description:m,layout:s||o,button:U,buttonDisabled:(g||[]).length<1||Fe||Me,focusable:ae&&je,transitions:re,transitionPlaying:He,transitionStagger:de,transitionDisabled:Ze,className:So.intro,style:Ne?null:{paddingLeft:Z,paddingRight:Z,paddingTop:(Me?0:Se)+Z,paddingBottom:(ae&&!Me?Ce:0)+(it||Z)},onClickButton:pt})}),ll&&El.push({key:"question-".concat(yt),element:(0,se.jsx)(Ao,{index:yt,totalCount:(g||[]).length,question:At,answers:Ct,keypadLayout:$t,answeredIndex:Vt,buttonsStyle:x,inactiveButtonsStyle:S,buttonsTextStyle:w,inactiveButtonsTextStyle:j,questionsHeadingStyle:N,feedbackTextStyle:I,numbersTextStyle:B,goodAnswerColor:V,badAnswerColor:O,focusable:ae&&je,showInstantAnswer:ot,layout:Ft||o,result:Pt,resultImage:Et,withResult:Qt,withoutGoodAnswer:_t,withoutTrueFalse:!Zt,withoutCollapse:Zt,transitions:re,transitionPlaying:He,transitionStagger:de,transitionDisabled:Ze,onAnswerClick:ft,onAnswerTransitionEnd:Qt?null:Xt,className:So.question,style:Ne?null:{padding:Z,paddingTop:(ae&&!Me?Se:0)+(tt||Z),paddingBottom:(ae&&!Me?Ce:0)+(it||Z)}})}),Qt&&null!==Vt&&El.push({key:"next",element:(0,se.jsx)("div",{className:So.next,style:Ne?null:{padding:Z,paddingTop:(ae&&!Me?Se:0)+(tt||Z),paddingBottom:(ae&&!Me?Ce:0)+(it||Z)},children:(0,se.jsx)(zn,{disabled:null===Vt,focusable:!0,buttonStyle:null!==X?X.buttonStyle:null,className:So.nextButton,onClick:Xt,children:We?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},X),{},{className:So.label})):(0,se.jsx)("span",{className:So.label,children:(0,se.jsx)(Wl.A,{id:"SVLGTA",defaultMessage:[{type:0,value:"Next"}]})})})})}),tl&&El.push({key:"results",element:(0,se.jsx)(wo,(0,i.A)((0,i.A)({},al),{},{resultsHeadingStyle:T,resultsTextStyle:$,layout:sl||o,transitions:re,transitionPlaying:He,transitionStagger:de,transitionDisabled:Ze,className:So.results,style:Ne?null:{padding:Z,paddingTop:(ae&&!Me?Se:0)+(tt||Z),paddingBottom:(ae&&!Me?Ce:0)+(it||Z)}}))});var Vl=(0,oa.pn)(El,{keys:function(e){return e.key},from:function(e){return"next"===e.key?{transform:"translateX(0%)"}:{transform:"left"===bl?"translateX(-100%)":"translateX(100%)"}},enter:{transform:"translateX(0%)"},leave:function(e){return"next"===e.key?{transform:"translateX(0%)"}:{transform:"left"===bl?"translateX(100%)":"translateX(-100%)"}},config:function(e){return"next"===e.key?{duration:0}:{duration:1e3,easing:oa.le.easeInOutSine}}}),Dl=(0,a.useMemo)(function(){return{key:cl,background:dl||null}},[cl,dl]),Ol=(0,oa.pn)(Dl,{keys:function(e){return e.key},from:{opacity:0},enter:{opacity:1},leave:{opacity:0},config:{duration:1e3,easing:oa.le.easeInOutSine}});return(0,se.jsxs)("div",{className:Jt([So.container,ge]),"data-screen-ready":!0,children:[(0,se.jsxs)(An,{width:pe,height:be,className:So.content,children:[Pl&&null!==Kt&&Kt>0?(0,se.jsxs)("div",{className:So.points,children:["".concat(Kt," "),(0,se.jsx)(Wl.A,{id:"Xr1v8l",defaultMessage:[{type:0,value:"points gained"}]})]}):null,Bl?(0,se.jsx)(zn,{className:So.reset,icon:(0,se.jsx)(yo.gc,{icon:go.ye,size:"md"}),onClick:Ll}):null,!Ne&&qe?(0,se.jsx)("div",{className:Jt([So.header,(0,h.A)({},So.disabled,Cl&&!xl&&Tl)]),ref:Ke,style:{paddingTop:Z/2,paddingLeft:Z,paddingRight:Z,paddingBottom:Z,transform:Me?null:"translate(0, ".concat(Se,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},K))}):null,(0,se.jsx)(ei,{verticalAlign:Il,disabled:xl,onScrolledTrigger:Ml,onScrolledBottom:kl,onScrolledNotBottom:jl,onScrollHeightChange:zl,withShadow:!0,children:(0,se.jsx)("div",{style:{position:"absolute",inset:"0"},children:Vl(function(e,t){var l=El.some(function(e){return e.key===t.key});return(0,se.jsx)(oa.CS.div,{style:(0,i.A)((0,i.A)({},e),l?{position:"relative",zIndex:1,top:0,left:0,width:"100%",minHeight:Qt&&null!==Vt?0:"100%"}:{position:"absolute",top:0,left:0,width:"100%",minHeight:"100%",zIndex:0}),children:t.element})})})}),!Ne&&_e?(0,se.jsx)("div",{ref:at,className:Jt([So.footer,(0,h.A)({},So.disabled,!Cl)]),style:{paddingLeft:Math.max(Z/2,we),paddingRight:Math.max(Z/2,we),paddingTop:Z/2,paddingBottom:Z/2,transform:Me?null:"translate(0, -".concat(Ce,"px)")},children:(0,se.jsx)(Dn,(0,i.A)({},Ue))}):null]}),Ne?null:Ol(function(e,t){return(0,se.jsx)(oa.CS.div,{style:(0,i.A)((0,i.A)({},e),{},{position:"absolute",top:0,left:0,width:"100%",height:"100%",zIndex:t.key===Dl.key?1:0}),children:(0,se.jsx)(pn,{background:t.background,width:pe,height:be,resolution:xe,playing:t.key===Dl.key&&yl,muted:$e,shouldLoad:hl,mediaRef:t.key===Dl.key?vl:null,className:So.background,withoutVideo:Me})})})]})},layouts:["top","middle","bottom","split"],states:[{id:"intro",label:(0,ue.zR)({id:"BgrRxZ",defaultMessage:[{type:0,value:"Intro"}]}),fields:[{name:"introLayout",type:"screen-layout",defaultValue:"middle",screenState:"intro",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"introButton",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]})},{name:"introBackground",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})}]},{id:"questions",label:(0,ue.zR)({id:"VMd1oG",defaultMessage:[{type:0,value:"Questions"}]}),repeatable:!0,fieldName:"questions",fields:[{name:"text",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"hVE7TA",defaultMessage:[{type:0,value:"Question"}]})},{name:"answers",type:"quiz-points-answers",theme:{label:{textStyle:"button"}},label:(0,ue.zR)({id:"KHWeV7",defaultMessage:[{type:0,value:"Answers"}]})},{name:"keypadLayout",type:"keypad-layout",isList:!0,withoutLabel:!0,defaultValue:{columnAlign:"middle",columns:1,spacing:10,withSquareItems:!1},label:(0,ue.zR)({id:"FjuRaw",defaultMessage:[{type:0,value:"Keypad settings"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})}]},{id:"results",label:(0,ue.zR)({id:"uiTxd7",defaultMessage:[{type:0,value:"Results"}]}),repeatable:!0,fields:[{name:"layout",type:"screen-layout",defaultValue:"top",screenState:"results",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"points",type:"number",isHorizontal:!0,label:(0,ue.zR)({id:"jWAJW4",defaultMessage:[{type:0,value:"Points"}]}),help:(0,ue.zR)({id:"JoyIgA",defaultMessage:[{type:0,value:"Minimum points for this result"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})}]}],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"OPxJx/",defaultMessage:[{type:0,value:"Layout"}]})},{type:"fields",label:(0,ue.zR)({id:"LOknw0",defaultMessage:[{type:0,value:"Styles"}]}),isList:!0,fields:[{name:"buttonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"l5uLMd",defaultMessage:[{type:0,value:"Buttons"}]})},{name:"buttonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"gwPu/I",defaultMessage:[{type:0,value:"Buttons text"}]})},{name:"inactiveButtonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"my7Kox",defaultMessage:[{type:0,value:"Inactive buttons text"}]})},{name:"inactiveButtonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"xlFOg3",defaultMessage:[{type:0,value:"Inactive buttons"}]})},{name:"questionsHeadingStyle",type:"text-style-form",label:(0,ue.zR)({id:"+FHxPO",defaultMessage:[{type:0,value:"Questions title"}]})},{name:"resultsHeadingStyle",type:"text-style-form",label:(0,ue.zR)({id:"BnRW4y",defaultMessage:[{type:0,value:"Results title"}]})},{name:"resultsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"uDHTZn",defaultMessage:[{type:0,value:"Results description"}]})},{name:"numbersTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"iltluX",defaultMessage:[{type:0,value:"Numbers text"}]})}]},{name:"nextButton",type:"button-element",theme:{textStyle:"button"},label:(0,ue.zR)({id:"Yu/PB5",defaultMessage:[{type:0,value:"Next button"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}];function No(e){var t=e.body,l=void 0===t?null:t,n=e.textStyle,o=void 0===n?null:n,r=e.linksStyle,s=void 0===r?null:r,u=e.margin,d=void 0===u?null:u,c=e.showEmpty,m=void 0!==c&&c,v=e.className,g=void 0===v?null:v,y=e.emptyClassName,f=void 0===y?null:y,p=o||{},b=p.link,x=void 0===b?null:b,A=p.highlight,S=void 0===A?null:A,C={},w=null!==x?Oe(x):null,k=null!==S?De(S):null;null!==o&&(C=(0,i.A)((0,i.A)({},C),He(o))),null!==d&&(C=(0,i.A)((0,i.A)({},C),Ze(d))),null!==s&&(w=(0,i.A)((0,i.A)({},w),He(s)));var j=(0,a.useId)(),M=null!==w?"quote-component-".concat(j):null;return(0,se.jsxs)(se.Fragment,{children:[null!==w?(0,se.jsx)(tn,{selector:"#".concat(we(M)),style:w}):null,null!==k?(0,se.jsx)(en,{selector:"#".concat(we(M)),style:k}):null,(0,se.jsx)("blockquote",{id:M,className:Jt(["micromag-element-quote-container",g,(0,h.A)((0,h.A)({},"micromag-element-quote-showEmpty",m),f,m&&null!==f)]),style:C,dangerouslySetInnerHTML:{__html:l}})]})}var Fo={container:"micromag-screen-quote-container",background:"micromag-screen-quote-background",content:"micromag-screen-quote-content",emptyQuote:"micromag-screen-quote-emptyQuote",emptyAuthor:"micromag-screen-quote-emptyAuthor",quote:"micromag-screen-quote-quote",withMargin:"micromag-screen-quote-withMargin",isPlaceholder:"micromag-screen-quote-isPlaceholder",layout:"micromag-screen-quote-layout"},To={id:"quote",type:"screen",group:{label:(0,ue.zR)({id:"fIawTr",defaultMessage:[{type:0,value:"Text"}]}),order:2},title:(0,ue.zR)({id:"3q9GPv",defaultMessage:[{type:0,value:"Quote"}]}),component:function(e){var t=e.layout,l=void 0===t?"top":t,a=e.quote,n=void 0===a?null:a,o=e.author,r=void 0===o?null:o,s=e.spacing,u=void 0===s?20:s,d=e.background,c=void 0===d?null:d,m=e.header,v=void 0===m?null:m,g=e.footer,y=void 0===g?null:g,f=e.current,p=void 0===f||f,b=e.preload,x=void 0===b||b,A=e.className,S=void 0===A?null:A,C=It(),w=C.width,k=C.height,j=C.resolution,M=Rt(),N=M.isView,F=M.isPreview,T=M.isPlaceholder,R=M.isEdit,z=Ot(),$=z.topHeight,L=z.bottomHeight,I=z.bottomSidesWidth,P=qt().open,B=jt().muted,E=Mt(p,!0),V=E.ref,D=E.isCurrent,O=void 0!==D&&D,H="split"===l,Z="top"===l,W="middle"===l,q="bottom"===l,_=H?null:l,G=Ge(v),Y=Ye(y),U=ze(y,{isView:N,current:p,openWebView:P,isPreview:F}),Q=Je(n),X=Je(r),J=Q&&X&&!H,K=p&&(N||R)&&(O||!N),ee=p||x;return(0,se.jsxs)("div",{className:Jt([Fo.container,S,(0,h.A)({},Fo.isPlaceholder,T)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:w,height:k,className:Fo.content,children:(0,se.jsxs)(Qn,{className:Fo.layout,fullscreen:!0,verticalAlign:_,style:T?null:{padding:u,paddingTop:(F?0:$)+(G?u/2:u),paddingBottom:(F?0:L)+(Y?u/2:u)},children:[!T&&G?(0,se.jsx)("div",{style:{paddingBottom:u},children:(0,se.jsx)(Zn,(0,i.A)({},v))}):null,!T&&Y&&W?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!T&&G&&q?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!T&&G&&!Y&&W?(0,se.jsx)(Un,{},"spacer-cta-top"):null,(0,se.jsx)(Qa,{placeholder:"quote",emptyLabel:(0,se.jsx)(Wl.A,{id:"CrzYgw",defaultMessage:[{type:0,value:"Quote"}]}),emptyClassName:Fo.emptyQuote,isEmpty:!Q,children:Q?(0,se.jsx)(No,(0,i.A)({className:Jt([Fo.quote,(0,h.A)({},Fo.withMargin,J)])},n)):null},"quote"),H?(0,se.jsx)(Un,{},"spacer"):null,(0,se.jsx)(Qa,{placeholder:"subtitle",emptyLabel:(0,se.jsx)(Wl.A,{id:"xYqGzM",defaultMessage:[{type:0,value:"Author"}]}),emptyClassName:Fo.emptyAuthor,isEmpty:!X,children:X?(0,se.jsx)(nn,(0,i.A)({className:Fo.author},r)):null},"author"),!T&&Y&&(Z||W)?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!T&&G&&!Y&&W?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!T&&Y?(0,se.jsx)("div",{style:{paddingTop:u,paddingLeft:Math.max(I-u,0),paddingRight:Math.max(I-u,0)},children:(0,se.jsx)(Dn,(0,i.A)({},U))}):null]})}),T?null:(0,se.jsx)(pn,{background:c,width:w,height:k,resolution:j,playing:K,muted:B,shouldLoad:ee,mediaRef:V,withoutVideo:F,className:Fo.background})]})},layouts:["top","middle","bottom","split"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"quote",type:"heading-element",fieldType:"multi",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"88/Ge8",defaultMessage:[{type:0,value:"Quote"}]})},{name:"author",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"73hxYw",defaultMessage:[{type:0,value:"Author"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Ro={container:"micromag-screen-ranking-container",background:"micromag-screen-ranking-background",content:"micromag-screen-ranking-content",empty:"micromag-screen-ranking-empty",emptyTitle:"micromag-screen-ranking-emptyTitle",item:"micromag-screen-ranking-item",rankText:"micromag-screen-ranking-rankText",itemTitle:"micromag-screen-ranking-itemTitle",description:"micromag-screen-ranking-description",callToAction:"micromag-screen-ranking-callToAction",disabled:"micromag-screen-ranking-disabled",sideLayout:"micromag-screen-ranking-sideLayout",elementsContainer:"micromag-screen-ranking-elementsContainer",rank:"micromag-screen-ranking-rank",label:"micromag-screen-ranking-label",isPlaceholder:"micromag-screen-ranking-isPlaceholder",scroll:"micromag-screen-ranking-scroll"},zo=[null],$o={id:"ranking",type:"screen",group:{label:(0,ue.zR)({id:"cGItoy",defaultMessage:[{type:0,value:"List"}]}),order:8},title:(0,ue.zR)({id:"17BMn2",defaultMessage:[{type:0,value:"Ranking"}]}),component:function(e){var t=e.layout,l=void 0===t?"side":t,n=e.title,r=void 0===n?null:n,s=e.items,u=void 0===s?zo:s,d=e.itemTitleStyle,c=void 0===d?null:d,m=e.itemDescriptionStyle,v=void 0===m?null:m,g=e.numbersStyle,y=void 0===g?null:g,f=e.ascending,p=void 0!==f&&f,b=e.spacing,x=void 0===b?20:b,A=e.background,S=void 0===A?null:A,C=e.header,w=void 0===C?null:C,k=e.footer,j=void 0===k?null:k,M=e.current,N=void 0===M||M,F=e.preload,T=void 0===F||F,z=e.type,$=void 0===z?null:z,L=e.className,I=void 0===L?null:L,P=$l($),B=It(),E=B.width,V=B.height,D=B.resolution,O=Ot(),H=O.topHeight,Z=O.bottomHeight,W=O.bottomSidesWidth,q=qt().open,_=jt().muted,G=Mt(N,!0),Y=G.ref,U=G.isCurrent,Q=void 0!==U&&U,X=Rt(),J=X.isView,K=X.isPreview,ee=X.isPlaceholder,te=X.isEdit,le=X.isStatic,ae=X.isCapture,ne=ee?(0,o.A)(new Array(10)).map(function(){return{}}):u||[null],ie=null!==ne?ne.length:0,oe=!te&&(le||ae||ee||K||te)||!N,re=N&&(J||te)&&(Q||!J),ue=N||T,de=Je(r),ce=(0,se.jsx)(Qa,{placeholder:"Title",emptyLabel:(0,se.jsx)(Wl.A,{id:"BSTWf8",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Jt([Ro.empty,Ro.emptyTitle]),isEmpty:!de,children:de?(0,se.jsx)(_n,(0,i.A)({className:Ro.title},r)):null}),me=(ne||[]).map(function(e,t){var l=e||{},a=l.title,n=void 0===a?null:a,o=l.description,r=void 0===o?null:o,s=Je(n),u=Je(r),d=(n||{}).textStyle,m=void 0===d?null:d,g=(r||{}).textStyle,h=void 0===g?null:g,f=(0,se.jsx)("div",{className:Ro.itemTitle,children:(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"bmO4Ss",defaultMessage:[{type:0,value:"Entry Title"}]}),emptyClassName:Ro.empty,isEmpty:!s,children:s?(0,se.jsx)(_n,(0,i.A)((0,i.A)({},n),{},{textStyle:(0,i.A)((0,i.A)({},c||null),m)})):null})}),b=(0,se.jsx)("div",{className:Ro.description,children:(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"507VAi",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:Ro.empty,isEmpty:!u,children:u?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},r),{},{textStyle:(0,i.A)((0,i.A)({},v||null),h)})):null})}),x="".concat(p?t+1:ie-t);return(0,se.jsxs)("div",{className:Ro.item,children:[(0,se.jsx)("div",{className:Ro.rank,children:ee?x:(0,se.jsx)(nn,{className:Ro.rankText,body:x,textStyle:y})}),(0,se.jsxs)("div",{className:Ro.label,children:[f,b]})]},"item-".concat(t))}),ve=Ge(w),ge=Ye(j),ye=ze(j,{isView:J,current:N,openWebView:q,isPreview:K}),he=(0,a.useState)(!1),fe=(0,R.A)(he,2),pe=fe[0],be=fe[1],xe=pl(),Ae=xe.ref,Se=xe.height,Ce=void 0===Se?0:Se,we=(0,a.useCallback)(function(e){e.initial&&P("scroll","Screen"),be(!0)},[P]),ke=(0,a.useCallback)(function(){be(!1)},[be]),je=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);P("scroll",t,{scrollPercent:t})}},[P]);return(0,se.jsxs)("div",{className:Jt([Ro.container,I,(0,h.A)((0,h.A)({},Ro["".concat(l,"Layout")],null!==l),Ro.isPlaceholder,ee)]),"data-screen-ready":!0,children:[(0,se.jsxs)(An,{width:E,height:V,className:Ro.content,children:[(0,se.jsxs)(ei,{className:Ro.scroll,verticalAlign:"middle",disabled:oe,onScrolledTrigger:je,onScrolledBottom:we,onScrolledNotBottom:ke,withShadow:!0,children:[!ee&&ve?(0,se.jsx)("div",{style:{paddingTop:x/2+H,paddingLeft:x,paddingRight:x},children:(0,se.jsx)(Zn,(0,i.A)({},w))}):null,(0,se.jsxs)(Qn,{className:Ro.layout,style:ee?null:{padding:x,paddingTop:!ee&&ve?x:(K?0:H)+x,paddingBottom:(N&&!K?Z:0)+(Ce||x)},children:[ce,(0,se.jsx)("div",{className:Ro.elementsContainer,children:me})]})]}),!ee&&ge?(0,se.jsx)("div",{ref:Ae,className:Jt([Ro.callToAction,(0,h.A)({},Ro.disabled,!pe)]),style:{transform:N&&!K?"translate(0, -".concat(Z,"px)"):null,paddingLeft:Math.max(x/2,W),paddingRight:Math.max(x/2,W),paddingTop:x/2,paddingBottom:x/2},children:(0,se.jsx)(Dn,(0,i.A)({},ye))}):null]}),ee?null:(0,se.jsx)(pn,{background:S,width:E,height:V,resolution:D,playing:re,muted:_,shouldLoad:ue,mediaRef:Y,withoutVideo:K,className:Ro.background})]})},layouts:["side","over"],fields:[{name:"layout",type:"screen-layout",defaultValue:"side",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"items",type:"entries",theme:{title:{textStyle:"heading2"},description:{textStyle:"text"}},label:(0,ue.zR)({id:"sESmah",defaultMessage:[{type:0,value:"Entries"}]})},{type:"fields",label:(0,ue.zR)({id:"xac4z/",defaultMessage:[{type:0,value:"Entry styles"}]}),isList:!0,fields:[{name:"itemTitleStyle",type:"text-style-form",label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"itemDescriptionStyle",type:"text-style-form",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"numbersStyle",type:"text-style-form",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"UdrdRF",defaultMessage:[{type:0,value:"Numbers style"}]})}]},{name:"ascending",type:"toggle",label:(0,ue.zR)({id:"9DhYaZ",defaultMessage:[{type:0,value:"Ascending"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Lo=l(4625);function Io(e){var t=e.className,l=void 0===t?null:t,a=e.size,n=void 0===a?45:a;return(0,se.jsxs)("svg",{width:n,height:n,viewBox:"0 0 45 45",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:Jt([l]),children:[(0,se.jsxs)("g",{clipPath:"url(#clip0_837_18233)",children:[(0,se.jsx)("path",{d:"M32.8293 17.0498L27.3973 22.5436C27.3582 22.5825 27.3582 22.6453 27.3973 22.6842L31.1987 26.7044C31.4557 26.9576 31.4568 27.3694 31.2007 27.6247L31.1987 27.6267C30.9417 27.8809 30.526 27.8809 30.2699 27.6267L26.4836 23.6214C26.4435 23.5816 26.3782 23.5816 26.337 23.6214L25.4143 24.5557C24.6512 25.3304 23.607 25.7671 22.5156 25.7691C21.4011 25.7631 20.3367 25.3135 19.5606 24.5198L18.672 23.6224C18.6318 23.5826 18.5666 23.5826 18.5254 23.6224L14.7371 27.6286C14.48 27.8829 14.0644 27.8829 13.8083 27.6286C13.5513 27.3754 13.5503 26.9636 13.8063 26.7084L13.8083 26.7064L17.6097 22.6862C17.6448 22.6463 17.6448 22.5855 17.6097 22.5456L12.1717 17.0498C12.1335 17.0109 12.0703 17.0099 12.0301 17.0478C12.011 17.0667 12 17.0927 12 17.1196V28.1132C12.003 28.9976 12.7239 29.7145 13.6155 29.7175H31.3855C32.2761 29.7145 32.998 28.9986 33.001 28.1132V17.1196C33.001 17.0647 32.9568 17.0199 32.9016 17.0199C32.8745 17.0199 32.8484 17.0308 32.8293 17.0498Z",fill:"currentColor"}),(0,se.jsx)("path",{d:"M22.4995 24.459C23.2425 24.461 23.9544 24.1648 24.4735 23.6364L32.3946 15.631C32.1114 15.4036 31.759 15.28 31.3955 15.28H13.6105C13.246 15.279 12.8936 15.4026 12.6105 15.631L20.5305 23.6364C21.0476 24.1628 21.7585 24.46 22.4995 24.459Z",fill:"currentColor"})]}),(0,se.jsx)("defs",{children:(0,se.jsx)("clipPath",{id:"clip0_837_18233",children:(0,se.jsx)("rect",{width:"21",height:"14.4375",fill:"currentColor",transform:"translate(12 15.28)"})})})]})}function Po(e){var t=e.className,l=void 0===t?null:t,a=e.size,n=void 0===a?45:a;return(0,se.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:n,height:n,viewBox:"0 0 64 64",className:Jt([l]),children:[(0,se.jsx)("path",{d:"M29.1,33.4a7.19,7.19,0,0,0,10.1,1.4,5,5,0,0,0,.8-.7l4.3-4.3a7.24,7.24,0,0,0,.1-10.2,7.34,7.34,0,0,0-10.2.1l-.1.1-2.5,2.5",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"3"}),(0,se.jsx)("path",{d:"M34.9,30.6a7.19,7.19,0,0,0-10.1-1.4,5,5,0,0,0-.8.7l-4.3,4.3a7.24,7.24,0,0,0-.1,10.2,7.15,7.15,0,0,0,10.2.1l.1-.1,2.5-2.5",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"3"})]})}function Bo(e){var t=e.className,l=void 0===t?null:t,a=e.size,n=void 0===a?45:a;return(0,se.jsx)("svg",{width:n,height:n,viewBox:"0 0 45 45",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:Jt([l]),children:(0,se.jsx)("path",{d:"M30.8988 12H14.1001C12.9444 12.0053 12.0106 12.9444 12.0106 14.1001L12 32.9989L16.2002 28.7987H30.8999C32.0578 28.7955 32.9968 27.8576 33 26.6986V14.1001C32.9968 12.9422 32.0588 12.0032 30.8999 12H30.8988ZM19.3498 20.3999C19.3498 20.9798 18.8797 21.4499 18.2998 21.4499V21.4499C17.7199 21.4499 17.2497 20.9798 17.2497 20.3999V20.3999C17.2497 19.82 17.7199 19.3498 18.2998 19.3498V19.3498C18.8797 19.3498 19.3498 19.82 19.3498 20.3999V20.3999ZM23.5501 20.3999C23.5501 20.9798 23.0799 21.4499 22.5 21.4499V21.4499C21.9201 21.4499 21.4499 20.9798 21.4499 20.3999V20.3999C21.4499 19.82 21.9201 19.3498 22.5 19.3498V19.3498C23.0799 19.3498 23.5501 19.82 23.5501 20.3999V20.3999ZM27.7503 20.3999C27.7503 20.9798 27.2801 21.4499 26.7002 21.4499V21.4499C26.1203 21.4499 25.6502 20.9798 25.6502 20.3999V20.3999C25.6502 19.82 26.1203 19.3498 26.7002 19.3498V19.3498C27.2801 19.3498 27.7503 19.82 27.7503 20.3999V20.3999Z",fill:"currentColor"})})}var Eo={item:"micromag-element-share-options-item",button:"micromag-element-share-options-button",icon:"micromag-element-share-options-icon",label:"micromag-element-share-options-label",spacer:"micromag-element-share-options-spacer",labelText:"micromag-element-share-options-labelText"};function Vo(e){var t=e.className,l=void 0===t?null:t,n=e.itemClassName,o=void 0===n?null:n,r=e.labelClassName,s=void 0===r?null:r,u=e.buttonClassName,d=void 0===u?null:u,c=e.title,m=void 0===c?null:c,v=e.url,g=void 0===v?null:v,y=e.options,f=void 0===y?null:y,p=e.buttonsStyle,x=void 0===p?null:p,A=e.buttonsTextStyle,S=void 0===A?null:A,C=e.iconSize,w=void 0===C?45:C,k=e.theme,j=void 0===k?null:k,M=e.onShare,N=void 0===M?null:M,F=e.onClose,T=void 0===F?null:F,z=e.focusable,$=void 0===z||z,L=(j||{}).menuTheme,I=((void 0===L?null:L)||{}).colors,P=((void 0===I?null:I)||{}).primary,B=Ee(void 0===P?null:P,"color");null!==S&&(B=(0,i.A)((0,i.A)({},B),He(S))),null!==x&&(B=(0,i.A)((0,i.A)({},B),Ve(x)));var E=(0,a.useState)(!1),V=(0,R.A)(E,2),D=V[0],O=V[1],H=(0,a.useCallback)(function(){(function(e){return Se.apply(this,arguments)})(g).then(function(){O(!0),setTimeout(function(){O(!1)},2e3)})},[g,O]),Z=(0,a.useCallback)(function(e){null!==N&&N(e)},[N]),W=(0,a.useMemo)(function(){return{className:Jt([Eo.button,d]),url:g,onShareWindowClose:function(){null!==T&&T()}}},[g,T]),q=(0,a.useMemo)(function(){return{className:Eo.icon,size:w,bgStyle:{fill:"none"},iconFillColor:"currentColor"}},[w]),_=[{id:"facebook",button:(0,se.jsxs)(Lo.uI,(0,i.A)((0,i.A)({},W),{},{quote:m,beforeOnClick:function(){return Z("Facebook"),Promise.resolve()},tabIndex:$?null:"-1",style:B,children:[(0,se.jsx)(Lo.ik,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:"Facebook"}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]}))},{id:"twitter",button:(0,se.jsxs)(Lo.r6,(0,i.A)((0,i.A)({},W),{},{title:m,beforeOnClick:function(){return Z("Twitter"),Promise.resolve()},tabIndex:$?null:"-1",style:B,children:[(0,se.jsx)(Lo.Fi,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:"X (Twitter)"}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]}))},{id:"linkedin",button:(0,se.jsxs)(Lo.wk,(0,i.A)((0,i.A)({},W),{},{title:m,beforeOnClick:function(){return Z("LinkedIn"),Promise.resolve()},tabIndex:$?null:"-1",style:B,children:[(0,se.jsx)(Lo._z,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:"LinkedIn"}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]}))},{id:"whatsapp",button:(0,se.jsxs)(Lo.Kz,(0,i.A)((0,i.A)({},W),{},{title:m,beforeOnClick:function(){return Z("Whatsapp"),Promise.resolve()},tabIndex:$?null:"-1",style:B,children:[(0,se.jsx)(Lo.Y4,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:"Whatsapp"}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]}))},{id:"email",button:(0,se.jsxs)(Lo.Ot,(0,i.A)((0,i.A)({},W),{},{subject:m,beforeOnClick:function(){return Z("Email"),Promise.resolve()},tabIndex:$?null:"-1",style:B,children:[(0,se.jsx)(Io,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:(0,se.jsx)(Wl.A,{id:"Lrwi2G",defaultMessage:[{type:0,value:"Email"}]})}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]}))},{id:"sms",button:(0,se.jsxs)(ca,{className:Jt([Eo.button,d]),href:"sms:?&body=".concat(g),focusable:$,style:B,external:!0,withoutBootstrapStyles:!0,children:[(0,se.jsx)(Bo,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:(0,se.jsx)("span",{className:Eo.labelText,children:(0,se.jsx)(Wl.A,{id:"dSfmnf",defaultMessage:[{type:0,value:"SMS"}]})})}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]})}],G=null===f||f.includes("copylink"),Y=null!==f&&b(f)?_.filter(function(e){return f.includes(e.id)}):_;return(0,se.jsx)("div",{className:Jt([Eo.container,l]),children:(0,se.jsxs)("div",{className:Eo.options,children:[G?(0,se.jsx)("div",{className:Jt([Eo.item,o,(0,h.A)({},Eo.isLinkCopied,D)]),children:(0,se.jsxs)(ca,{className:Jt([Eo.button,d]),onClick:H,focusable:$,style:B,withoutBootstrapStyles:!0,children:[(0,se.jsx)(Po,(0,i.A)({},q)),(0,se.jsx)("div",{className:Jt([Eo.label,s]),children:(0,se.jsxs)("span",{className:Eo.labelText,children:[D?null:(0,se.jsx)(Wl.A,{id:"D21uVQ",defaultMessage:[{type:0,value:"Copy link"}]}),D?(0,se.jsx)(Wl.A,{id:"xFlbR7",defaultMessage:[{type:0,value:"Link copied!"}]}):null]})}),(0,se.jsx)("div",{className:Eo.spacer,style:{width:"".concat(w,"px")}})]})}):null,Y.map(function(e){var t=e.id,l=e.button;return(0,se.jsx)("div",{className:Jt([Eo.item,o]),children:l},t)})]})})}var Do={container:"micromag-screen-share-container",background:"micromag-screen-share-background",content:"micromag-screen-share-content",heading:"micromag-screen-share-heading",layout:"micromag-screen-share-layout",shareOptions:"micromag-screen-share-shareOptions",isCentered:"micromag-screen-share-isCentered",shareButton:"micromag-screen-share-shareButton",emptyHeading:"micromag-screen-share-emptyHeading",emptyOptions:"micromag-screen-share-emptyOptions",header:"micromag-screen-share-header",footer:"micromag-screen-share-footer"},Oo={id:"share",type:"screen",group:{label:(0,ue.zR)({id:"64JlRq",defaultMessage:[{type:0,value:"Share"}]}),order:12},title:(0,ue.zR)({id:"5mk1b+",defaultMessage:[{type:0,value:"Share"}]}),component:function(e){var t=e.layout,l=void 0===t?"top":t,n=e.heading,r=void 0===n?null:n,s=e.shareUrl,u=void 0===s?null:s,d=e.options,c=void 0===d?null:d,m=e.buttonsStyle,v=void 0===m?null:m,g=e.buttonsTextStyle,y=void 0===g?null:g,f=e.centered,p=void 0!==f&&f,b=e.spacing,x=void 0===b?20:b,A=e.background,S=void 0===A?null:A,C=e.header,w=void 0===C?null:C,k=e.footer,j=void 0===k?null:k,M=e.id,N=void 0===M?null:M,F=e.index,T=void 0===F?null:F,R=e.current,z=void 0===R||R,$=e.active,L=void 0===$||$,I=e.className,P=void 0===I?null:I,B=It(),E=B.width,V=B.height,D=B.resolution,O=Rt(),H=O.isView,Z=O.isPreview,W=O.isPlaceholder,q=O.isEdit,_=Ot(),G=_.topHeight,Y=_.bottomHeight,U=_.bottomSidesWidth,Q=qt().open,X=jt().muted,J=Mt(z,!0),K=J.ref,ee=J.isCurrent,te=z&&(H||q)&&(void 0!==ee&&ee||!H),le=z||L,ae=Ge(w),ne=Ye(j),ie=ze(j,{isView:H,current:z,openWebView:Q,isPreview:Z}),oe=pl(),re=oe.ref,ue=oe.height,de=void 0===ue?0:ue,ce=pl(),me=ce.ref,ve=ce.height,ge=void 0===ve?0:ve,ye=(0,a.useMemo)(function(){if("undefined"==typeof window)return"";var e=window.location||{},t=e.hostname,l=void 0===t?null:t,a=e.pathname,n=(void 0===a?null:a).split("/");return n.reduce(function(e,t,l){return l===n.length-1&&parseInt(t,10)===T||t===N||""===t?e:"".concat(e,"/").concat(t)},l)},[T,N]),he=u||ye,fe=null!==c?["email","facebook","twitter","linkedin","whatsapp"]:[],pe=null!==c?Object.keys(c).reduce(function(e,t){return c[t]?[].concat((0,o.A)(e),[t]):e},[]):fe,be=H,xe=$l("share"),Ae=(0,a.useCallback)(function(e){be&&xe("click_share",e,{shareUrl:he})},[xe]);return(0,se.jsxs)("div",{className:Jt([Do.container,P,(0,h.A)({},Do.isPlaceholder,W)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:E,height:V,className:Do.content,children:(0,se.jsxs)(Qn,{className:Do.layout,verticalAlign:l,fullscreen:!0,style:W?null:{padding:x,paddingTop:(Z?0:G)+(de||x),paddingBottom:(z&&!Z?Y:0)+(ge||x)},children:[!W&&ae?(0,se.jsx)("div",{className:Do.header,ref:re,style:{paddingTop:x/2,paddingBottom:x,paddingLeft:x,paddingRight:x,transform:"translate(0px, ".concat(G,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},w))}):null,(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"X7kRRa",defaultMessage:[{type:0,value:"Heading"}]}),emptyClassName:Do.emptyHeading,isEmpty:!r||""===(null==r?void 0:r.body),children:r?(0,se.jsx)(_n,(0,i.A)({className:Jt([Do.heading])},r)):null},"title"),(0,se.jsx)(Un,{size:5},"spacer"),(0,se.jsx)(Qa,{placeholder:"share-options",emptyLabel:(0,se.jsx)(Wl.A,{id:"RucIeL",defaultMessage:[{type:0,value:"Share options"}]}),emptyClassName:Do.emptyOptions,isEmpty:!c,children:(0,se.jsx)(Vo,{className:Jt([Do.shareOptions,(0,h.A)({},Do.isCentered,p)]),buttonClassName:Do.shareButton,url:he,options:pe,onShare:Ae,buttonsStyle:v,buttonsTextStyle:y})},"share-options"),!W&&ne?(0,se.jsx)("div",{className:Do.footer,ref:me,style:{paddingTop:x,paddingBottom:x/2,paddingLeft:Math.max(U-x,0),paddingRight:Math.max(U-x,0)},children:(0,se.jsx)(Dn,(0,i.A)({},ie))}):null]})}),W?null:(0,se.jsx)(pn,{background:S,width:E,height:V,resolution:D,playing:te,muted:X,shouldLoad:le,mediaRef:K,withoutVideo:Z,className:Do.background})]})},layouts:["top","middle","bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"shareUrl",type:"url",label:(0,ue.zR)({id:"0R+nB5",defaultMessage:[{type:0,value:"Custom URL"}]}),help:(0,ue.zR)({id:"bQsPrs",defaultMessage:[{type:0,value:"If this field is left empty, this Micromag's URL will be shared."}]})},{name:"heading",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"wx5PI0",defaultMessage:[{type:0,value:"Heading"}]})},{name:"options",type:"fields",isList:!0,label:(0,ue.zR)({id:"4js1kW",defaultMessage:[{type:0,value:"Share Options"}]}),fields:[{name:"copylink",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"rKuiKj",defaultMessage:[{type:0,value:"Copy link"}]})},{name:"facebook",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"r+bcpa",defaultMessage:[{type:0,value:"Facebook"}]})},{name:"twitter",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"mlucL+",defaultMessage:[{type:0,value:"Twitter"}]})},{name:"linkedin",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"hvxkzE",defaultMessage:[{type:0,value:"LinkedIn"}]})},{name:"whatsapp",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"3B9cb3",defaultMessage:[{type:0,value:"Whatsapp"}]})},{name:"email",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"LI0Gz4",defaultMessage:[{type:0,value:"Email"}]})},{name:"sms",type:"toggle",defaultValue:!0,label:(0,ue.zR)({id:"d3va12",defaultMessage:[{type:0,value:"SMS"}]})}]},{name:"buttonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"gwPu/I",defaultMessage:[{type:0,value:"Buttons text"}]})},{name:"buttonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"l5uLMd",defaultMessage:[{type:0,value:"Buttons"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Ho={container:"micromag-screen-slideshow-container",background:"micromag-screen-slideshow-background",content:"micromag-screen-slideshow-content",inner:"micromag-screen-slideshow-inner",placeholder:"micromag-screen-slideshow-placeholder",caption:"micromag-screen-slideshow-caption",header:"micromag-screen-slideshow-header",footer:"micromag-screen-slideshow-footer"},Zo=[],Wo=[{id:"slideshow",type:"screen",group:{label:(0,ue.zR)({id:"6mX2ya",defaultMessage:[{type:0,value:"Images"}]}),order:7},title:(0,ue.zR)({id:"MhGUaY",defaultMessage:[{type:0,value:"Slideshow"}]}),component:function(e){var t=e.slides,l=void 0===t?Zo:t,n=e.withCaptions,o=void 0!==n&&n,r=e.background,s=void 0===r?null:r,u=e.header,d=void 0===u?null:u,c=e.footer,m=void 0===c?null:c,v=e.current,g=void 0===v||v,y=e.active,f=void 0===y||y,p=e.preload,b=void 0===p||p,x=e.spacing,A=void 0===x?20:x,S=e.transitionDelay,C=void 0===S?1:S,w=e.captionMaxLines,k=void 0===w?2:w,j=e.transitions,M=void 0===j?null:j,N=e.className,F=void 0===N?null:N,T=It(),z=T.width,$=T.height,L=T.resolution,I=Ot(),P=I.topHeight,B=I.bottomHeight,E=Wt(),V=E.enableInteraction,D=E.disableInteraction,O=Rt(),H=O.isView,Z=O.isPreview,W=O.isPlaceholder,q=O.isEdit,_=O.isStatic,G=O.isCapture,Y=jt().muted,U=Mt(g,!0),Q=U.ref,X=U.isCurrent,J=g&&(H||q)&&(void 0!==X&&X||!H),K=g||b,ee=W?5:A,te=(0,a.useState)(0),le=(0,R.A)(te,2),ae=le[0],ne=le[1],ie=!0,oe=g&&ie,re=_||G||W||Z,ue=(0,a.useCallback)(function(){ne(ae+1)},[ae,ne]),de=(0,a.useRef)([]),ce=Ge(d),me=Ye(m),ve=ze(m,{isView:H,current:g,isPreview:Z,enableInteraction:V,disableInteraction:D}),ge=pl(),ye=ge.ref,he=ge.height,fe=void 0===he?0:he,pe=pl().ref,be=(l||[]).map(function(e,t){var l=e||{},a=l.media,n=void 0===a?null:a,r=l.caption,s=void 0===r?null:r,u={width:z,height:$},d=null!==n,c=Je(s),m=t>0?t*(1e3*C):0;return(0,se.jsxs)("div",{className:Ho.gridItem,children:[(0,se.jsx)("div",{className:Ho.imageContainer,ref:function(e){de.current[t]=e},children:(0,se.jsx)(Ka,{transitions:M,delay:m,playing:oe,disabled:re,fullscreen:!0,children:(0,se.jsx)(Qa,{placeholder:"image",placeholderProps:{className:Ho.placeholder,height:"100%"},emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:Ho.emptyImage,isEmpty:!d,children:K?(0,se.jsx)(Nn,(0,i.A)((0,i.A)({className:Ho.image,media:n,muted:Y},u),{},{resolution:L,objectFit:{fit:"cover"},playing:J,active:f,withoutVideo:Z,onLoaded:ue})):null})})}),o?(0,se.jsx)(Ka,{transitions:M,delay:m,playing:oe,disabled:re,children:(0,se.jsx)(Qa,{placeholder:"line",emptyLabel:(0,se.jsx)(Wl.A,{id:"6tIigB",defaultMessage:[{type:0,value:"Caption"}]}),emptyClassName:Ho.emptyCaption,isEmpty:!c,children:c?(0,se.jsx)("div",{className:Ho.caption,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},s),{},{className:Ho.captionText,lineClamp:k}))}):null})}):null]},"item-".concat(t))});return(0,se.jsxs)("div",{className:Jt([Ho.container,F,(0,h.A)({},Ho.isPlaceholder,W)]),"data-screen-ready":ie,children:[(0,se.jsx)(An,{width:z,height:$,className:Ho.content,children:(0,se.jsxs)("div",{className:Ho.inner,style:{paddingTop:Z?null:P,paddingBottom:(me?fe-ee:0)+(g&&!Z?B:0)},children:[W?(0,se.jsx)(Qa,{placeholder:"image",placeholderProps:{className:Ho.placeholder,height:"100%"},emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]})}):null,!W&&ce?(0,se.jsx)("div",{className:Ho.header,ref:pe,style:{padding:ee,paddingTop:ee/2,transform:Z?null:"translate(0, ".concat(P,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},d))}):null,be,!W&&me?(0,se.jsx)("div",{className:Ho.footer,ref:ye,style:{padding:ee/2},children:(0,se.jsx)(Dn,(0,i.A)({},ve))}):null]})}),W?null:(0,se.jsx)(pn,{background:s,width:z,height:$,resolution:L,muted:Y,mediaRef:Q,playing:J,shouldLoad:K,withoutVideo:Z,className:Ho.background})]})},fields:[{name:"slides",type:"visuals-with-caption",label:(0,ue.zR)({id:"muYwrB",defaultMessage:[{type:0,value:"Images"}]})},{name:"transitionDelay",type:"number",min:0,float:!0,label:(0,ue.zR)({id:"/6zaOP",defaultMessage:[{type:0,value:"Transition Delay (in seconds)"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],qo=l(3831),_o=l(5569),Go="micromag-screen-survey-disabled",Yo="micromag-screen-survey-resultText",Uo={id:"survey",type:"screen",group:{label:(0,ue.zR)({id:"ZiWlL6",defaultMessage:[{type:0,value:"Questions"}]}),order:7},title:(0,ue.zR)({id:"650XRF",defaultMessage:[{type:0,value:"Survey"}]}),component:function(e){var t=e.id,l=void 0===t?null:t,n=e.layout,s=void 0===n?"middle":n,u=e.question,d=void 0===u?null:u,c=e.answers,m=void 0===c?null:c,v=e.result,g=void 0===v?null:v,y=e.buttonsStyle,f=void 0===y?null:y,p=e.buttonsTextStyle,b=void 0===p?null:p,A=e.resultsStyle,S=void 0===A?null:A,C=e.spacing,w=void 0===C?20:C,k=e.header,j=void 0===k?null:k,M=e.footer,N=void 0===M?null:M,F=e.background,T=void 0===F?null:F,z=e.customAnswer,$=void 0!==z&&z,L=e.showCount,I=void 0!==L&&L,P=e.withoutPercentage,B=void 0!==P&&P,E=e.withoutBar,V=void 0!==E&&E,D=e.current,O=void 0===D||D,H=e.preload,Z=void 0===H||H,W=e.transitions,q=void 0===W?null:W,_=e.resultTransitionDuration,G=void 0===_?500:_,Y=e.type,U=void 0===Y?null:Y,Q=e.className,X=void 0===Q?null:Q,J=l||"screen-id",K=$l(U),ee=It(),te=ee.width,le=ee.height,ae=ee.resolution,ne=xi({screenId:J}).create,ie=Rt(),oe=ie.isView,re=ie.isPreview,ue=ie.isPlaceholder,de=ie.isEdit,me=ie.isStatic,ve=ie.isCapture,ge=Ot(),ye=ge.topHeight,he=ge.bottomHeight,fe=ge.bottomSidesWidth,pe=qt().open,be=jt().muted,xe=Mt(O,!0),Ae=xe.ref,Se=xe.isCurrent,Ce=void 0!==Se&&Se,we=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.screenId,l=e.storyId,n=void 0===l?null:l,o=e.opts,s=void 0===o?{}:o,u=hi(),d=ct()||{},c=d.id,m=d.document_id,v=(0,a.useCallback)(function(){return null!==u?u.quiz.results(t,{story_id:m||n||c}):null},[u,t,m,n,c]),g=null!==u?fi(v,s):{data:null},y=g.data,h=(0,r.A)(g,bi);return(0,i.A)({quiz:y||[]},h)}({screenId:J,opts:{autoload:!ue}}),ke=we.quiz,je=(void 0===ke?[]:ke).filter(function(e){var t=(e||{}).choice,l=void 0===t?null:t;return!!(m||[]).map(function(e){var t=(e||{}).label,l=((void 0===t?null:t)||{}).body;return void 0===l?null:l}).filter(function(e){return null!==e}).find(function(e){return e===l})}),Me=Je(d),Ne=Je(g),Fe=$||{},Te=Fe.active,Re=void 0!==Te&&Te,Le=Fe.placeholder,Ie=void 0===Le?null:Le,Pe=Fe.textStyle,Be=void 0===Pe?null:Pe,Ve=Fe.boxStyle,De=void 0===Ve?null:Ve,Oe=Fe.submit,He=void 0===Oe?null:Oe,Ze=Fe.multiline,We=void 0!==Ze&&Ze,qe=Ie||{},_e=qe.body,Ue=void 0===_e?null:_e,Qe=qe.textStyle,Xe=void 0===Qe?null:Qe,Ke=me||ve,et=(0,a.useState)(Ke?-1:null),tt=(0,R.A)(et,2),lt=tt[0],at=tt[1],nt=null!==lt,it=(0,a.useMemo)(function(){var e=null!==m?(je||[]).reduce(function(e,t){var l=t.count;return e+parseInt(void 0===l?0:l,10)},null!==lt&<>-1?1:0):0,t=null!==m?(m||[]).reduce(function(t,l,a){var n=(l||{}).label,o=((void 0===n?{}:n)||{}).body,r=void 0===o?null:o,s=(je.find(function(e){return e.choice===r})||{}).count,u=void 0===s?0:s,d=a===lt?u+1:u;return null!==r?(0,i.A)((0,i.A)({},t),{},(0,h.A)({},r,{percent:e>0?d/e*100:0,count:d})):t},{}):{},l=function(e){if(!x()(e)||e.length<1)return e;for(var t=e.map(function(e,t){return{floor:Math.floor(e)||0,remainder:$e(e),index:t}}).sort(function(e,t){return t.remainder-e.remainder}),l=100-t.reduce(function(e,t){return e+t.floor},0),a=0;a<l;a+=1)t[a]&&(t[a].floor+=1);return t.sort(function(e,t){return e.index-t.index}).map(function(e){return e.floor})}(e>0?Object.keys(t).map(function(e){return t[e].percent||0}):[]);return Object.keys(t).reduce(function(e,a,n){return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},a,(0,i.A)((0,i.A)({},t[a]),{},{percent:l[n]})))},{})},[m,je,lt]),ot="split"===s,rt="middle"===s,st=ot?null:s,ut=O,dt=me||ve||ue||re||de,mt=O&&(oe||de)&&(Ce||!oe),vt=O||Z,gt=(0,a.useCallback)(function(e){if(null===lt){at(e);var t=null!==m?m[e]:null;ne({choice:t.label.body||e,value:1}),K("click_answer","Answer ".concat(lt+1,": ").concat(t.label.body),{linkType:"survey_answer",answer:t,answerIndex:e,answerType:"button"})}},[lt,at,K,ne]);(0,a.useEffect)(function(){!O&&de&&null!==lt&&at(null)},[de,O,lt,at]);var yt=(0,a.useCallback)(function(){at(null)},[at]),ht=(0,a.useState)(null),ft=(0,R.A)(ht,2),pt=ft[0],bt=ft[1],xt=(0,a.useState)(!1),At=(0,R.A)(xt,2),St=At[0],Ct=At[1],wt=re||nt,kt=(0,a.useCallback)(function(e){e.preventDefault(),e.stopPropagation(),Ct(!0)},[Ct]),Nt=(0,a.useCallback)(function(e){e.preventDefault(),e.stopPropagation(),Ct(!1)},[Ct]),Ft=(0,a.useCallback)(function(e){var t=gi.A.sanitize(e.currentTarget.value||"");bt(""!==t?t:null)},[bt]),Tt=(0,a.useCallback)(function(){bt("")},[bt]),zt=(0,a.useCallback)(function(e){e.preventDefault(),e.stopPropagation(),null===pt||""===pt||nt||(ne({choice:pt,value:1}),at("input"),Ct(!1),K("click_answer","Answer input: ".concat(pt),{textInput:pt,answerIndex:null,answerType:"custom"}))},[pt,ne,nt,at,Ct,K]),$t=Ge(j),Lt=Ye(N),Pt=ze(N,{isView:oe,current:O,openWebView:pe,isPreview:re}),Bt=pl(),Et=Bt.ref,Vt=Bt.height,Dt=void 0===Vt?0:Vt,Ht=pl(),Zt=Ht.ref,Wt=Ht.height,_t=void 0===Wt?0:Wt,Gt=!de&&dt||!O,Yt=(0,a.useState)(!1),Ut=(0,R.A)(Yt,2),Qt=Ut[0],Xt=Ut[1],Kt=(0,a.useCallback)(function(e){e.initial&&K("scroll","Screen"),Xt(!0)},[K]),el=(0,a.useCallback)(function(){Xt(!1)},[Xt]),tl=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);K("scroll",t,{scrollPercent:t})}},[K]),ll=(0,a.useState)(!1),al=(0,R.A)(ll,2),nl=al[0],il=al[1],ol=(0,a.useCallback)(function(e){var t=e.canScroll;il(void 0!==t&&t)},[il]),rl=[(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"e1I+KU",defaultMessage:[{type:0,value:"Question"}]}),emptyClassName:"micromag-screen-survey-emptyQuestion",isEmpty:!Me,children:Me?(0,se.jsx)(Ka,{transitions:q,playing:ut,disabled:dt,children:(0,se.jsx)(_n,(0,i.A)((0,i.A)({},d),{},{className:"micromag-screen-survey-question"}))}):null},"question")];(ot||!ue&&Lt&&rt)&&rl.push((0,se.jsx)(Un,{},"spacer"));var sl=(0,a.useMemo)(function(){return Ke?0:"".concat(G,"ms")},[Ke,G]),ul=S||{},dl=ul.barColor,cl=void 0===dl?null:dl,ml=ul.textColor,vl=void 0===ml?null:ml,gl=ul.percentageTextStyle,yl=void 0===gl?null:gl,hl=(0,a.useMemo)(function(){var e=Ne?g:null,t=((null!==m&&null!==lt?m[lt]:null)||{}).result;return(void 0===t?null:t)||e},[Ne,g,m,lt]),fl=de&&null!==lt;return rl.push((0,se.jsx)("div",{className:"micromag-screen-survey-answers",children:null!==m||ue?(0,se.jsx)("div",{className:"micromag-screen-survey-items",children:(ue?(0,o.A)(new Array(3)):m).map(function(e,t){var l=null!==e,a=e||{},n=a.label,o=void 0===n?null:n,r=a.buttonStyle,s=void 0===r?null:r,u=a.textStyle,d=void 0===u?null:u,c=a.resultStyle,m=(void 0===c?null:c)||{},v=m.barColor,g=void 0===v?null:v,y=m.textColor,p=m.percentageTextStyle,x=void 0===p?null:p,A=(o||{}).body,S=void 0===A?null:A,C=null!==S&&it[S]||{},w=C.percent,k=void 0===w?0:w,j=C.count,M=void 0===j?0:j,N=(o||{}).textStyle,F=void 0===N?null:N,T=(F||{}).color,R=void 0===T?null:T,z=Je(o),$=lt===t,L=(0,i.A)((0,i.A)((0,i.A)({},f),s),nt?{textAlign:"left"}:null),P=(L||{}).borderRadius,E=void 0===P?null:P,D=null!==E&&ce(E)&&E>2?E-2:E;return(0,se.jsx)("div",{className:Jt(["micromag-screen-survey-item",(0,h.A)({},"micromag-screen-survey-userAnswer",$)]),children:(0,se.jsx)(Qa,{placeholder:"surveyAnswer",placeholderProps:{className:"micromag-screen-survey-placeholderAnswer"},emptyLabel:(0,se.jsx)(Wl.A,{id:"+Ok+7S",defaultMessage:[{type:0,value:"Answer"}]}),emptyClassName:"micromag-screen-survey-emptyAnswer",isEmpty:!z,children:l?(0,se.jsx)("div",{className:"micromag-screen-survey-itemContent",children:(0,se.jsx)("div",{className:"micromag-screen-survey-itemInner",style:{borderRadius:E,transitionDuration:sl},children:(0,se.jsx)(zn,{className:"micromag-screen-survey-button",onPointerUp:function(e){"mouse"===e.pointerType&&0!==e.button||gt(t)},disabled:re||null!==lt,focusable:O&&oe,buttonStyle:L,textStyle:(0,i.A)((0,i.A)((0,i.A)({},b),F),d),children:(0,se.jsxs)("span",{className:"micromag-screen-survey-itemLabel",children:[(0,se.jsx)(nn,(0,i.A)((0,i.A)({},o),{},{textStyle:(0,i.A)((0,i.A)((0,i.A)({},b),F),d),inline:!0,className:"micromag-screen-survey-itemText"})),B?null:(0,se.jsx)("div",{className:"micromag-screen-survey-resultLabel",style:(0,i.A)((0,i.A)({},Ee(nt?y||vl||g||cl||R:null,"color")),nt?{opacity:1}:{opacity:0}),children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},o),{},{textStyle:(0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)((0,i.A)({},b),F),d),vl),yl),y),x),inline:!0,className:Yo,body:I?M:"".concat(k,"%")}))}),V?null:(0,se.jsx)("div",{className:"micromag-screen-survey-resultBar",style:(0,i.A)((0,i.A)({borderRadius:D,transitionDuration:sl,width:null!==k?"".concat(k,"%"):"0%"},Ee(g||cl||R,"backgroundColor")),nt?{opacity:.5}:{opacity:0})})]})})})}):null})},"answer-".concat(t+1))})}):null},"answers")),(0,se.jsxs)("div",{className:Jt(["micromag-screen-survey-container",X,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},"micromag-screen-survey-answered",nt),"micromag-screen-survey-inputFocused",St),"micromag-screen-survey-withPercentage",!B),"micromag-screen-survey-withBar",!V),"micromag-screen-survey-isPlaceholder",ue)]),children:[(0,se.jsxs)(An,{width:te,height:le,className:"micromag-screen-survey-content",children:[(0,se.jsxs)(ei,{verticalAlign:st,disabled:Gt,onScrolledTrigger:tl,onScrolledBottom:Kt,onScrolledNotBottom:el,onScrollHeightChange:ol,withShadow:!0,children:[fl?(0,se.jsx)(zn,{className:"micromag-screen-survey-reset",icon:(0,se.jsx)(_o.gc,{icon:qo.ye,size:"md"}),onClick:yt}):null,!ue&&$t?(0,se.jsx)("div",{className:Jt(["micromag-screen-survey-header",(0,h.A)({},Go,Qt&&!Gt&&nl)]),ref:Et,style:{paddingTop:w/2,paddingLeft:w,paddingRight:w,paddingBottom:w,transform:re?null:"translate(0, ".concat(ye,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},j))}):null,(0,se.jsxs)(Qn,{className:"micromag-screen-survey-layout",verticalAlign:st,style:ue?null:{padding:w,paddingTop:(O&&!re?ye:0)+(Dt||w),paddingBottom:(O&&!re?he:0)+(_t+w)},children:[rl,!ue&&Re?(0,se.jsxs)("form",{className:Jt(["micromag-screen-survey-input",(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},"micromag-screen-survey-focused",St),"micromag-screen-survey-filled",null!==pt&&""!==pt),Go,wt),"micromag-screen-survey-selected","input"===lt),"micromag-screen-survey-multiline",We)]),onSubmit:zt,children:[(0,se.jsx)(Si,{className:"micromag-screen-survey-textInput",disabled:wt,focusable:O&&oe,buttonStyle:(0,i.A)((0,i.A)({},f),De),textStyle:(0,i.A)((0,i.A)({},b),Be),placeholderTextStyle:(0,i.A)((0,i.A)((0,i.A)({},b),Be),Xe),value:pt,label:Ue,onChange:Ft,onFocus:kt,onBlur:Nt,multiline:We}),nt?null:(0,se.jsx)(zn,{className:Jt(["micromag-screen-survey-confirm",(0,h.A)({},Go,wt||null===pt||""===pt)]),type:"button",onClick:Tt,disabled:wt||null===pt||""===pt,children:(0,se.jsx)(ga,{className:"micromag-screen-survey-icon"})}),nt?null:(0,se.jsx)(zn,{className:Jt(["micromag-screen-survey-submit",(0,h.A)({},Go,wt||null===pt||""===pt)]),type:"submit",buttonStyle:null==He?void 0:He.buttonStyle,disabled:wt||null===pt||""===pt,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},He),{},{inline:!0}))})]}):null,null!==lt&&null!==hl?(0,se.jsx)(Ka,{transitions:q,playing:ut,disabled:dt,children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},hl||{}),{},{className:Yo}))}):null]})]}),!ue&&Lt?(0,se.jsx)("div",{ref:Zt,className:Jt(["micromag-screen-survey-footer",(0,h.A)({},Go,!Qt)]),style:{transform:re?null:"translate(0, -".concat(he,"px)"),paddingLeft:Math.max(w/2,fe),paddingRight:Math.max(w/2,fe),paddingTop:w/2,paddingBottom:w/2},children:(0,se.jsx)(Dn,(0,i.A)({},Pt))}):null]}),ue?null:(0,se.jsx)(pn,{background:T,width:te,height:le,resolution:ae,playing:mt,muted:be,shouldLoad:vt,mediaRef:Ae,withoutVideo:re,className:"micromag-screen-survey-background"})]})},layouts:["top","middle","bottom","split"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"question",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"hVE7TA",defaultMessage:[{type:0,value:"Question"}]})},{name:"answers",type:"answers",theme:{label:{textStyle:"button"}},label:(0,ue.zR)({id:"KHWeV7",defaultMessage:[{type:0,value:"Answers"}]})},{name:"result",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"iQ5Uf7",defaultMessage:[{type:0,value:"Default feedback"}]})},{name:"customAnswer",type:"custom-answer",defaultValue:!1,isList:!0,theme:{textStyle:"button"}},{type:"fields",isList:!0,label:(0,ue.zR)({id:"R9DB4a",defaultMessage:[{type:0,value:"Styles"}]}),fields:[{name:"showCount",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"ppGXAR",defaultMessage:[{type:0,value:"Show the answer count"}]})},{name:"withoutPercentage",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"crLqJd",defaultMessage:[{type:0,value:"Without percentage"}]})},{name:"withoutBar",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"D7kxD3",defaultMessage:[{type:0,value:"Without bar"}]})},{name:"buttonsStyle",type:"box-style-form",label:(0,ue.zR)({id:"l5uLMd",defaultMessage:[{type:0,value:"Buttons"}]})},{name:"buttonsTextStyle",type:"text-style-form",label:(0,ue.zR)({id:"gwPu/I",defaultMessage:[{type:0,value:"Buttons text"}]})},{name:"resultsStyle",type:"graph-bar-style-form",label:(0,ue.zR)({id:"e4UTx9",defaultMessage:[{type:0,value:"Results"}]}),noValueLabel:(0,ue.zR)({id:"65rc70",defaultMessage:[{type:0,value:"Edit style..."}]})}]},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Qo={container:"micromag-screen-text-container",background:"micromag-screen-text-background",content:"micromag-screen-text-content",emptyTitle:"micromag-screen-text-emptyTitle",emptyText:"micromag-screen-text-emptyText",title:"micromag-screen-text-title",withMargin:"micromag-screen-text-withMargin",isPlaceholder:"micromag-screen-text-isPlaceholder",layout:"micromag-screen-text-layout"};function Xo(e){var t=e.layout,l=void 0===t?"top":t,a=e.text,n=void 0===a?null:a,o=e.title,r=void 0===o?null:o,s=e.withTitle,u=void 0!==s&&s,d=e.spacing,c=void 0===d?20:d,m=e.header,v=void 0===m?null:m,g=e.footer,y=void 0===g?null:g,f=e.background,p=void 0===f?null:f,b=e.current,x=void 0===b||b,A=e.preload,S=void 0===A||A,C=e.className,w=void 0===C?null:C,k=It(),j=k.width,M=k.height,N=k.resolution,F=Rt(),T=F.isView,R=F.isPreview,z=F.isPlaceholder,$=F.isEdit,L=Ot(),I=L.topHeight,P=L.bottomHeight,B=L.bottomSidesWidth,E=qt().open,V=jt().muted,D=Mt(x,!0),O=D.ref,H=D.isCurrent,Z=void 0!==H&&H,W=Je(r),q=Je(n),_="split"===l,G="top"===l,Y="middle"===l,U="bottom"===l,Q=_?null:l,X=W&&q&&!_,J=x&&(T||$)&&(Z||!T),K=x||S,ee=Ge(v),te=Ye(y),le=ze(y,{isView:T,current:x,openWebView:E,isPreview:R});return(0,se.jsxs)("div",{className:Jt([Qo.container,w,(0,h.A)({},Qo.isPlaceholder,z)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:j,height:M,className:Qo.content,children:(0,se.jsxs)(Qn,{className:Qo.layout,fullscreen:!0,verticalAlign:Q,style:z?null:{padding:c,paddingTop:(R?0:I)+(ee?c/2:c),paddingBottom:(x&&!R?P:0)+(te?c/2:c)},children:[!z&&ee?(0,se.jsx)("div",{style:{paddingBottom:c},children:(0,se.jsx)(Zn,(0,i.A)({},v))}):null,!z&&te&&Y?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!z&&ee&&U?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!z&&ee&&!te&&Y?(0,se.jsx)(Un,{},"spacer-cta-top"):null,u?(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Qo.emptyTitle,isEmpty:!W,children:W?(0,se.jsx)(_n,(0,i.A)({className:Jt([Qo.title,(0,h.A)({},Qo.withMargin,X)])},r)):null},"title"):null,_&&u?(0,se.jsx)(Un,{},"spacer"):null,(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"z4CiV1",defaultMessage:[{type:0,value:"Text"}]}),emptyClassName:Qo.emptyText,isEmpty:!q,children:q?(0,se.jsx)(nn,(0,i.A)({className:Qo.text},n)):null},"description"),!z&&te&&(G||Y)?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!z&&ee&&!te&&Y?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!z&&te?(0,se.jsx)("div",{className:Qo.footer,style:{paddingTop:c,paddingLeft:Math.max(0,B-c),paddingRight:Math.max(0,B-c)},children:(0,se.jsx)(Dn,(0,i.A)({},le))}):null]})}),z?null:(0,se.jsx)(pn,{background:p,width:j,height:M,resolution:N,playing:J,muted:V,shouldLoad:K,mediaRef:O,withoutVideo:R,className:Qo.background})]})}var Jo=[{id:"text",type:"screen",group:{label:(0,ue.zR)({id:"fIawTr",defaultMessage:[{type:0,value:"Text"}]}),order:2},title:(0,ue.zR)({id:"S9YpbV",defaultMessage:[{type:0,value:"Text"}]}),component:Xo,layouts:["top","middle","bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"text",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"text-title",type:"screen",group:{label:(0,ue.zR)({id:"fIawTr",defaultMessage:[{type:0,value:"Text"}]}),order:2},title:(0,ue.zR)({id:"oCBQKV",defaultMessage:[{type:0,value:"Text with title"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(Xo,(0,i.A)((0,i.A)({},t),{},{withTitle:!0}))},layouts:["top","middle","bottom","split"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",inline:!0,theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"text",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],Ko={container:"micromag-screen-timeline-container",background:"micromag-screen-timeline-background",content:"micromag-screen-timeline-content",empty:"micromag-screen-timeline-empty",emptyTitle:"micromag-screen-timeline-emptyTitle",item:"micromag-screen-timeline-item",element:"micromag-screen-timeline-element",hidden:"micromag-screen-timeline-hidden",body:"micromag-screen-timeline-body",timeline:"micromag-screen-timeline-timeline",line:"micromag-screen-timeline-line",bullet:"micromag-screen-timeline-bullet",title:"micromag-screen-timeline-title",description:"micromag-screen-timeline-description",imageContainer:"micromag-screen-timeline-imageContainer",image:"micromag-screen-timeline-image",video:"micromag-screen-timeline-video",callToAction:"micromag-screen-timeline-callToAction",disabled:"micromag-screen-timeline-disabled",isPlaceholder:"micromag-screen-timeline-isPlaceholder",scroll:"micromag-screen-timeline-scroll",circleBulletShape:"micromag-screen-timeline-circleBulletShape",withoutLines:"micromag-screen-timeline-withoutLines"},er=[null];function tr(e){var t=e.layout,l=void 0===t?"normal":t,n=e.title,r=void 0===n?null:n,s=e.items,u=void 0===s?er:s,d=e.itemTitleStyle,c=void 0===d?null:d,m=e.itemDescriptionStyle,v=void 0===m?null:m,g=e.withoutLine,y=void 0!==g&&g,f=e.bulletColor,p=void 0===f?null:f,b=e.lineColor,x=void 0===b?null:b,A=e.bulletShape,S=void 0===A?"circle":A,C=e.bulletFilled,w=void 0===C||C,k=e.illustrated,j=void 0!==k&&k,M=e.spacing,N=void 0===M?null:M,F=e.itemBottomSpacing,T=void 0===F?null:F,z=e.header,$=void 0===z?null:z,L=e.footer,I=void 0===L?null:L,P=e.background,B=void 0===P?null:P,E=e.alternatives,V=void 0===E?null:E,D=e.current,O=void 0===D||D,H=e.active,Z=void 0===H||H,W=e.preload,q=void 0===W||W,_=e.type,G=void 0===_?null:_,Y=e.className,U=void 0===Y?null:Y,Q=$l(G),X=It(),J=X.width,K=X.height,ee=X.imageResolution,te=X.resolution,le=Ot(),ae=le.topHeight,ne=le.bottomHeight,ie=le.bottomSidesWidth,oe=qt().open,re=Rt(),ue=re.isView,de=re.isPreview,ce=re.isPlaceholder,me=re.isEdit,ve=re.isStatic,ge=re.isCapture,ye=jt(),he=ye.muted,fe=ye.playing,pe=ye.setControls;ye.setControlsSuggestPlay;var be=ye.setControlsTheme,xe=ye.setPlaying;ye.controlsVisible;var Ae=ye.showControls,Se=ye.hideControls,Ce=Mt(O),we=Ce.ref,ke=Ce.isCurrent,je=void 0!==ke&&ke,Me=(V||{}).audio,Ne=void 0===Me?null:Me,Fe=Ne||{},Te=Fe.autoPlay,Re=void 0!==Te&&Te,$e=Fe.loop,Le=void 0!==$e&&$e,Ie=Fe.media,Pe=void 0===Ie?null:Ie,Be=Fe.withSeekBar,Ve=void 0!==Be&&Be,De=Fe.withControls,Oe=void 0!==De&&De,He=Fe.color,Ze=void 0===He?null:He,We=Fe.progressColor,qe=void 0===We?null:We,_e=(0,a.useMemo)(function(){return null!==Ne?(0,i.A)((0,i.A)({},Ne),{},{autoPlay:!de&&!ve&&!ge&&Re&&O}):null},[Ne,de,ve,ge,Re,O]),Ue=(0,a.useState)(!1),Qe=(0,R.A)(Ue,2),Xe=Qe[0],Ke=Qe[1],et=O&&(ue||me)&&(je||!ue),tt=O&&(ue||me)&&fe&&(je||!ue);(0,a.useEffect)(function(){return O?(be({seekBarOnly:Ve&&!Oe,color:Ze,progressColor:qe}),pe(!(!Oe&&!Ve)),function(){(Oe||Ve)&&pe(!1)}):function(){}},[O,Oe,pe,Ve,Ze,qe]),(0,a.useEffect)(function(){O&&Re&&xe(!0)},[O,Re]);var lt=sl({element:Zt(),disabled:!ue,timeout:2e3}).detected,at=(0,a.useCallback)(function(){lt?Ae():Se()},[lt,Ae,Se]);ul(at,lt,1e3);var nt=Ll("video"),it=(0,a.useState)(null),ot=(0,R.A)(it,2);ot[0];var rt=ot[1],st=(0,a.useState)(null),ut=(0,R.A)(st,2),dt=ut[0],ct=ut[1],mt=(0,a.useState)(null===Pe),vt=(0,R.A)(mt,2),gt=vt[0],yt=vt[1],ht=(0,a.useCallback)(function(){yt(!0)},[yt]),ft=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e&&void 0!==e.currentTarget){var t=(e.currentTarget||{}).currentTime;rt(void 0===t?0:t)}else rt(0)},[dt,rt]),pt=(0,a.useCallback)(function(e,t){nt(Pe,"progress_".concat(Math.round(100*e,10),"%"),t)},[nt,Pe]),bt=(0,a.useCallback)(function(e){ct(e)},[ct]),xt=(0,a.useCallback)(function(e){var t=e.initial;Xe||Ke(!0),nt(Pe,t?"play":"resume")},[nt,Pe]),At=(0,a.useCallback)(function(e){var t=e.midway;nt(Pe,t?"pause":"ended")},[nt,Pe]),St=(0,a.useCallback)(function(e){e>0&&nt(Pe,"seek",{currentTime:e})},[nt,Pe]),Ct=(0,a.useCallback)(function(){O&&!Le&&xe(!1)},[Le,O]),wt=(0,a.useMemo)(function(){return ce?(0,o.A)(new Array(5)).map(function(){return{}}):u||[null]},[ce,u]),kt=Je(r),Nt=(0,a.useMemo)(function(){return null!==N?Math.max(0,N||0):20},[N]),Ft=(0,a.useMemo)(function(){return ce?4:null!==T?Math.max(0,T||0):20},[ce,T]),Tt=null!==wt?wt.length:0,zt=null!==wt&&Tt?wt.reduce(function(e,t){var l=(t||{}).image;return e+(null!==(void 0===l?null:l)?1:0)},0):0,$t=(0,a.useState)(0),Lt=(0,R.A)($t,2),Pt=Lt[0],Bt=Lt[1],Et=Pt>=zt&>,Vt=!me&&(ve||ge||ce||de||me)||!O,Dt=O||q,Ht=(0,a.useCallback)(function(){Bt(function(e){return e+1})},[Bt]),Wt=pl(),_t=Wt.ref,Gt=Wt.width,Yt=void 0===Gt?null:Gt,Ut=pl(),Qt=Ut.ref,Xt=Ut.width,Kt=void 0===Xt?null:Xt,el=(null!=Kt?Kt:0)-(null!=Yt?Yt:0),tl=(wt||[]).map(function(e,t){var a=e||{},n=a.title,o=void 0===n?null:n,r=a.description,s=void 0===r?null:r,u=a.image,d=void 0===u?null:u,m=Je(o),g=Je(s),f=null!==d,b=("normal"===l?"title-description-image":l).split("-"),A=b.indexOf("title"),S=b.indexOf("image");j||b.splice(S,1);var C=b.length,k=(o||{}).textStyle,M=(s||{}).textStyle;return(0,se.jsx)("div",{className:Ko.item,children:b.map(function(e,l){var a=null,n=!1;switch(e){case"title":n=m,a=(0,se.jsx)("div",{className:Ko.title,children:(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"bmO4Ss",defaultMessage:[{type:0,value:"Entry Title"}]}),emptyClassName:Ko.empty,isEmpty:!m,children:m?(0,se.jsx)(_n,(0,i.A)((0,i.A)({},o),{},{textStyle:(0,i.A)((0,i.A)({},c||null),k)})):null})});break;case"image":n=f,a=(0,se.jsx)("div",{className:Ko.imageContainer,children:(0,se.jsx)(Qa,{placeholder:"image",emptyLabel:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]}),emptyClassName:Ko.empty,isEmpty:!f,children:f?(0,se.jsx)(Nn,{className:Ko.image,videoClassName:Ko.video,loadingMode:"lazy",media:d,width:el,resolution:te,playing:et,active:Z,shouldLoad:Dt,withoutVideo:de,onLoaded:Ht}):null})});break;case"description":n=g,a=(0,se.jsx)("div",{className:Ko.description,children:(0,se.jsx)(Qa,{placeholder:"text",emptyLabel:(0,se.jsx)(Wl.A,{id:"507VAi",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:Ko.empty,isEmpty:!g,children:g?(0,se.jsx)(nn,(0,i.A)((0,i.A)({},s),{},{textStyle:(0,i.A)((0,i.A)({},v||null),M)})):null})});break;default:a=null,n=!1}var r=0===t,u=t===Tt-1,b=l===C-1,S=r&&l<=A||u&&l>A,j=r&&l<A||u&&l>=A;return(0,se.jsxs)("div",{className:Jt([Ko.element,Ko["element-".concat(e)],(0,h.A)({},Ko.hidden,(ue||ve)&&!n)]),ref:0===t?Qt:null,children:[y?null:(0,se.jsxs)("div",{className:Ko.timeline,ref:0===t?_t:null,children:[(0,se.jsx)("div",{className:Jt([Ko.line,(0,h.A)({},Ko.hidden,S)]),style:(0,i.A)({},S?null:Ee(x,"backgroundColor"))}),"title"===e?(0,se.jsx)("div",{className:Ko.bullet,style:(0,i.A)((0,i.A)({},Ee(p,"borderColor")),w?Ee(p,"backgroundColor"):null)}):null,(0,se.jsx)("div",{className:Jt([Ko.line,(0,h.A)({},Ko.hidden,j)]),style:(0,i.A)({},j?null:Ee(x,"backgroundColor"))})]}),(0,se.jsx)("div",{className:Ko.body,style:{marginBottom:b&&!u?Ft:0},children:a})]},"element-".concat(e))})},"item-".concat(t))}),ll=Ge($),al=Ye(I),nl=ze(I,{isView:ue,current:O,openWebView:oe,isPreview:de}),il=(0,a.useState)(!1),ol=(0,R.A)(il,2),rl=ol[0],dl=ol[1],cl=pl(),ml=cl.ref,vl=cl.height,gl=void 0===vl?0:vl,yl=(0,a.useCallback)(function(e){e.initial&&Q("scroll","Screen"),dl(!0)},[Q]),hl=(0,a.useCallback)(function(){dl(!1)},[dl]),fl=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);Q("scroll",t,{scrollPercent:t})}},[Q]);return(0,se.jsxs)("div",{className:Jt([Ko.container,U,(0,h.A)((0,h.A)((0,h.A)({},Ko.isPlaceholder,ce),Ko["".concat(S,"BulletShape")],null!==S),Ko.withoutLines,Tt<2)]),"data-screen-ready":Et,children:[(0,se.jsxs)(An,{width:J,height:K,className:Ko.content,children:[(0,se.jsx)(ei,{className:Ko.scroll,verticalAlign:"middle",disabled:Vt,onScrolledTrigger:fl,onScrolledBottom:yl,onScrolledNotBottom:hl,withShadow:!0,children:(0,se.jsxs)(Qn,{style:ce?null:{padding:Nt,paddingTop:(de?0:ae)+(ll?Nt/2:Nt),paddingBottom:(O&&!de?ne:0)+(gl||Nt)},children:[!ce&&ll?(0,se.jsx)("div",{style:{paddingBottom:Nt},children:(0,se.jsx)(Zn,(0,i.A)({},$))}):null,(0,se.jsx)(Qa,{placeholder:"Title",emptyLabel:(0,se.jsx)(Wl.A,{id:"BSTWf8",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:Jt([Ko.empty,Ko.emptyTitle]),isEmpty:!kt,children:kt?(0,se.jsx)(_n,(0,i.A)({className:Ko.title},r)):null}),tl]})}),!ce&&al?(0,se.jsx)("div",{ref:ml,className:Jt([Ko.callToAction,(0,h.A)({},Ko.disabled,!rl)]),style:{transform:O&&!de?"translate(0, -".concat(ne,"px)"):null,paddingLeft:Math.max(Nt/2,ie),paddingRight:Math.max(Nt/2,ie),paddingTop:Nt/2,paddingBottom:Nt/2},children:(0,se.jsx)(Dn,(0,i.A)({},nl))}):null]}),null!==Pe?(0,se.jsx)(oi,(0,i.A)((0,i.A)({},_e),{},{paused:!tt,mediaRef:we,muted:he,className:Ko.audio,shouldLoad:Dt,onReady:ht,onPlay:xt,onPause:At,onTimeUpdate:ft,onProgressStep:pt,onDurationChange:bt,onSeeked:St,onEnded:Ct})):null,ce?null:(0,se.jsx)(pn,{background:B,width:J,height:K,resolution:ee,playing:et,muted:he,shouldLoad:Dt,mediaRef:null===Pe?we:null,withoutVideo:de,className:Ko.background})]})}var lr=[{id:"timeline",type:"screen",group:{label:(0,ue.zR)({id:"cGItoy",defaultMessage:[{type:0,value:"List"}]}),order:8},title:(0,ue.zR)({id:"GzoKNb",defaultMessage:[{type:0,value:"Timeline"}]}),component:tr,layouts:["normal"],fields:[{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"items",type:"entries",theme:{title:{textStyle:"heading2"},description:{textStyle:"text"}},label:(0,ue.zR)({id:"3ifj0j",defaultMessage:[{type:0,value:"Entries"}]})},{name:"spacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Zpl5bJ",defaultMessage:[{type:0,value:"Spacing"}]})},{type:"fields",label:(0,ue.zR)({id:"xac4z/",defaultMessage:[{type:0,value:"Entry styles"}]}),isList:!0,fields:[{name:"itemTitleStyle",type:"text-style-form",label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"itemDescriptionStyle",type:"text-style-form",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"itemBottomSpacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Lp0bG4",defaultMessage:[{type:0,value:"Bottom spacing"}]})}]},{name:"bulletShape",type:"radios",defaultValue:"circle",options:[{value:"circle",label:(0,ue.zR)({id:"+uInZz",defaultMessage:[{type:0,value:"Circle"}]})},{value:"square",label:(0,ue.zR)({id:"fusnxf",defaultMessage:[{type:0,value:"Square"}]})}],label:(0,ue.zR)({id:"twTaAZ",defaultMessage:[{type:0,value:"Bullet shape"}]})},{name:"withoutLine",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"N4lZhy",defaultMessage:[{type:0,value:"Without line"}]})},{name:"bulletFilled",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"YWcp4v",defaultMessage:[{type:0,value:"Bullet filled"}]})},{name:"bulletColor",type:"color",defaultValue:{alpha:1,color:"#FFFFFF"},label:(0,ue.zR)({id:"uNpHnA",defaultMessage:[{type:0,value:"Bullet color"}]})},{name:"lineColor",type:"color",defaultValue:{alpha:1,color:"#FFFFFF"},label:(0,ue.zR)({id:"RHMS2f",defaultMessage:[{type:0,value:"Line color"}]})},{name:"alternatives",type:"alternatives",label:(0,ue.zR)({id:"68NE9W",defaultMessage:[{type:0,value:"Alternatives"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"timeline-illustrated",type:"screen",group:{label:(0,ue.zR)({id:"cGItoy",defaultMessage:[{type:0,value:"List"}]}),order:8},title:(0,ue.zR)({id:"33UbSd",defaultMessage:[{type:0,value:"Timeline with images"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(tr,(0,i.A)((0,i.A)({},t),{},{illustrated:!0}))},layouts:["title-image-description","title-description-image","image-title-description"],fields:[{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"layout",type:"screen-layout",defaultValue:"title-image-description",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"items",type:"entries-with-visual",theme:{title:{textStyle:"heading2"},description:{textStyle:"text"}},label:(0,ue.zR)({id:"3ifj0j",defaultMessage:[{type:0,value:"Entries"}]})},{name:"spacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Zpl5bJ",defaultMessage:[{type:0,value:"Spacing"}]})},{type:"fields",label:(0,ue.zR)({id:"xac4z/",defaultMessage:[{type:0,value:"Entry styles"}]}),isList:!0,fields:[{name:"itemTitleStyle",type:"text-style-form",label:(0,ue.zR)({id:"+AEVbJ",defaultMessage:[{type:0,value:"Title"}]})},{name:"itemDescriptionStyle",type:"text-style-form",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{name:"itemBottomSpacing",type:"number",defaultValue:20,isHorizontal:!0,label:(0,ue.zR)({id:"Lp0bG4",defaultMessage:[{type:0,value:"Bottom spacing"}]})}]},{name:"withoutLine",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"N4lZhy",defaultMessage:[{type:0,value:"Without line"}]})},{name:"bulletShape",type:"radios",defaultValue:"circle",options:[{value:"circle",label:(0,ue.zR)({id:"+uInZz",defaultMessage:[{type:0,value:"Circle"}]})},{value:"square",label:(0,ue.zR)({id:"fusnxf",defaultMessage:[{type:0,value:"Square"}]})}],label:(0,ue.zR)({id:"twTaAZ",defaultMessage:[{type:0,value:"Bullet shape"}]})},{name:"bulletFilled",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"YWcp4v",defaultMessage:[{type:0,value:"Bullet filled"}]})},{name:"bulletColor",type:"color",defaultValue:{alpha:1,color:"#FFFFFF"},label:(0,ue.zR)({id:"uNpHnA",defaultMessage:[{type:0,value:"Bullet color"}]})},{name:"lineColor",type:"color",defaultValue:{alpha:1,color:"#FFFFFF"},label:(0,ue.zR)({id:"RHMS2f",defaultMessage:[{type:0,value:"Line color"}]})},{name:"alternatives",type:"alternatives",label:(0,ue.zR)({id:"68NE9W",defaultMessage:[{type:0,value:"Alternatives"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],ar="micromag-screen-title-withMargin",nr="micromag-screen-title-box";function ir(e){var t=e.layout,l=void 0===t?"top":t,a=e.title,n=void 0===a?null:a,o=e.subtitle,r=void 0===o?null:o,s=e.description,u=void 0===s?null:s,d=e.boxStyle,c=void 0===d?null:d,m=e.withSubtitle,v=void 0!==m&&m,g=e.withDescription,y=void 0!==g&&g,f=e.withBox,p=void 0!==f&&f,b=e.spacing,x=void 0===b?20:b,A=e.descriptionEmptyLabel,S=void 0===A?(0,se.jsx)(Wl.A,{id:"507VAi",defaultMessage:[{type:0,value:"Description"}]}):A,C=e.header,w=void 0===C?null:C,k=e.footer,j=void 0===k?null:k,M=e.background,N=void 0===M?null:M,F=e.current,T=void 0===F||F,R=e.active,z=void 0===R||R,$=e.className,L=void 0===$?null:$,I=It(),P=I.width,B=I.height,E=I.resolution,V=Rt(),D=V.isView,O=V.isPreview,H=V.isPlaceholder,Z=V.isEdit,W=Ot(),q=W.topHeight,_=W.bottomHeight,G=W.bottomSidesWidth,Y=qt().open,U=jt().muted,Q=Mt(T,!0),X=Q.ref,J=Q.isCurrent,K=void 0!==J&&J,ee=Je(n),te=Je(r),le=Je(u),ae=l.split("-"),ne="split"===ae[0],ie="top"===l,oe="middle"===l,re="bottom"===l,ue=ne?ae[1]||null:ae[0],de=ee&&(te||le)&&(!ne||"top"===ue),ce=te&&le&&(!ne||"bottom"===ue),me=T&&(D||Z)&&(K||!D),ve=T||z,ge=Ge(w),ye=Ye(j),he=ze(j,{isView:D,current:T,openWebView:Y,isPreview:O}),fe=(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:"micromag-screen-title-emptyTitle",isEmpty:!ee,children:ee?(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:Jt(["micromag-screen-title-title",(0,h.A)({},ar,de)])},n),{},{size:1})):null},"title"),pe=v?(0,se.jsx)(Qa,{placeholder:"subtitle",emptyLabel:(0,se.jsx)(Wl.A,{id:"d60tSn",defaultMessage:[{type:0,value:"Subtitle"}]}),emptyClassName:"micromag-screen-title-emptySubtitle",isEmpty:!te,children:te?(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:Jt(["micromag-screen-title-subtitle",(0,h.A)({},ar,ce)])},r),{},{size:2})):null},"subtitle"):null,be=y?(0,se.jsx)(Qa,{placeholder:"shortText",emptyLabel:S,emptyClassName:"micromag-screen-title-emptyDescription",isEmpty:!le,children:le?(0,se.jsx)(nn,(0,i.A)({},u)):null},"description"):null;return(0,se.jsxs)("div",{className:Jt(["micromag-screen-title-container",L,(0,h.A)({},"micromag-screen-title-isPlaceholder",H)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:P,height:B,className:"micromag-screen-title-content",children:(0,se.jsxs)(Qn,{className:"micromag-screen-title-layout",fullscreen:!0,verticalAlign:ue,style:H?null:{padding:x,paddingTop:(O?0:q)+(ge?x/2:x),paddingBottom:(T&&!O?_:0)+(ye?x/2:x)},children:[!H&&ge?(0,se.jsx)("div",{style:{paddingBottom:x},children:(0,se.jsx)(Zn,(0,i.A)({},w))}):null,!H&&ye&&oe?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!H&&ge&&re?(0,se.jsx)(Un,{},"spacer-cta-top"):null,!H&&ge&&!ye&&oe?(0,se.jsx)(Un,{},"spacer-cta-top"):null,p&&!ne?(0,se.jsx)("div",{className:nr,style:Z||H||ee||te||le?Ve(c):null,children:[fe,pe,be]}):null,p&&ne?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsxs)("div",{className:nr,style:Z||H||ee||y&&"top"===ue&&te?Ve(c):null,children:[fe,y&&"top"===ue?pe:null]},"top"),(0,se.jsx)(Un,{},"spacer1"),(0,se.jsxs)("div",{className:nr,style:Z||H||le||(!y||"bottom"===ue)&&te?Ve(c):null,children:[y&&"bottom"!==ue?null:pe,be]},"bottom")]}):null,p?null:(0,se.jsxs)(se.Fragment,{children:[fe,ne&&(!y||"bottom"===ue)&&(0,se.jsx)(Un,{},"spacer1"),pe,ne&&y&&"top"===ue&&(0,se.jsx)(Un,{},"spacer2"),be]}),!H&&ye&&(ie||oe)?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!H&&ge&&!ye&&oe?(0,se.jsx)(Un,{},"spacer-cta-bottom"):null,!H&&ye?(0,se.jsx)("div",{style:{paddingTop:x,paddingLeft:Math.max(0,G-x),paddingRight:Math.max(0,G-x)},children:(0,se.jsx)(Dn,(0,i.A)({},he))},"call-to-action"):null]})}),H?null:(0,se.jsx)(pn,{background:N,width:P,height:B,resolution:E,playing:me,muted:U,shouldLoad:ve,mediaRef:X,withoutVideo:O,className:"micromag-screen-title-background"})]})}var or=["credits"],rr=[{id:"title",type:"screen",group:{label:(0,ue.zR)({id:"uKJRh2",defaultMessage:[{type:0,value:"Title"}]}),order:1},title:(0,ue.zR)({id:"dVcog7",defaultMessage:[{type:0,value:"Title"}]}),component:ir,layouts:["top","middle","bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"title-subtitle",type:"screen",group:{label:(0,ue.zR)({id:"uKJRh2",defaultMessage:[{type:0,value:"Title"}]}),order:1},title:(0,ue.zR)({id:"P1dwGU",defaultMessage:[{type:0,value:"Title with subtitle"}]}),component:function(e){var t=(0,$i.A)({},((0,zi.A)(e),e));return(0,se.jsx)(ir,(0,i.A)((0,i.A)({},t),{},{withSubtitle:!0}))},layouts:["top","middle","bottom","split"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"subtitle",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"EcZYpr",defaultMessage:[{type:0,value:"Subtitle"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"title-subtitle-credits",type:"screen",group:{label:(0,ue.zR)({id:"uKJRh2",defaultMessage:[{type:0,value:"Title"}]}),order:1},title:(0,ue.zR)({id:"vZrFq6",defaultMessage:[{type:0,value:"Title with subtitle and credits"}]}),component:function(e){var t=e.credits,l=void 0===t?null:t,a=(0,r.A)(e,or);return(0,se.jsx)(ir,(0,i.A)((0,i.A)({},a),{},{description:l,withSubtitle:!0,withDescription:!0,descriptionEmptyLabel:(0,se.jsx)(Wl.A,{id:"/hupzO",defaultMessage:[{type:0,value:"Credits"}]})}))},layouts:["top","middle","bottom","split-top","split-bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"subtitle",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"EcZYpr",defaultMessage:[{type:0,value:"Subtitle"}]})},{name:"credits",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"upzOTm",defaultMessage:[{type:0,value:"Credits"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},{id:"title-with-box",type:"screen",group:{label:(0,ue.zR)({id:"uKJRh2",defaultMessage:[{type:0,value:"Title"}]}),order:1},title:(0,ue.zR)({id:"9a5s+m",defaultMessage:[{type:0,value:"Title with box"}]}),component:function(e){return(0,se.jsx)(ir,(0,i.A)((0,i.A)({},e),{},{withSubtitle:!0,withDescription:!0,withBox:!0}))},layouts:["top","middle","bottom","split-top","split-bottom"],fields:[{name:"layout",type:"screen-layout",defaultValue:"top",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"title",type:"heading-element",theme:{textStyle:"heading1"},label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"subtitle",type:"heading-element",theme:{textStyle:"heading2"},label:(0,ue.zR)({id:"EcZYpr",defaultMessage:[{type:0,value:"Subtitle"}]})},{name:"description",type:"text-element",theme:{textStyle:"text"},label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})},{type:"fields",isList:!0,label:(0,ue.zR)({id:"LOknw0",defaultMessage:[{type:0,value:"Styles"}]}),fields:[{name:"boxStyle",type:"box-style-form",label:(0,ue.zR)({id:"f5Yipd",defaultMessage:[{type:0,value:"Box"}]})}]},{name:"background",type:"background",label:(0,ue.zR)({id:"cDj1mZ",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],sr=l(734),ur={container:"micromag-element-urbania-author-avatar-container",shapeCircle:"micromag-element-urbania-author-avatar-shapeCircle",shape:"micromag-element-urbania-author-avatar-shape"};function dr(e){var t=e.image,l=void 0===t?null:t,a=e.width,n=void 0===a?100:a,i=e.height,o=void 0===i?100:i,r=e.resolution,s=void 0===r?1:r,u=e.shape,d=void 0===u?"circle":u,c=e.isTag,m=void 0!==c&&c,v=e.className,g=void 0===v?null:v,y=e.shouldLoad,f=void 0===y||y,p=yt("supportsWebp",!1),b=yt("imageResolution",s),x=Pe(l,n,o,{resolution:b,supportsWebp:p}),A=null!==d?(0,M.fL)(d):null;return(0,se.jsx)("span",{className:Jt([ur.container,(0,h.A)((0,h.A)({className:g},ur["shape".concat(A)],null!==A),ur.isTag,m)]),children:(0,se.jsx)("span",{className:ur.shape,style:{backgroundImage:f?'url("'.concat(x,'")'):null}})})}var cr={container:"micromag-element-urbania-author-container",image:"micromag-element-urbania-author-image",link:"micromag-element-urbania-author-link",right:"micromag-element-urbania-author-right",name:"micromag-element-urbania-author-name",prefix:"micromag-element-urbania-author-prefix",collaborator:"micromag-element-urbania-author-collaborator",collaboratorText:"micromag-element-urbania-author-collaboratorText",isSmall:"micromag-element-urbania-author-isSmall",withoutImage:"micromag-element-urbania-author-withoutImage",withoutBackground:"micromag-element-urbania-author-withoutBackground"},mr=["author","withImage","withoutLink","withoutPrefix","withoutBackground","isSmall","linkUnderlineColor","className","backgroundClassName","collaboratorClassName","shouldLoad"];function vr(e){var t=e.author,l=void 0===t?null:t,a=e.withImage,n=void 0===a||a,o=e.withoutLink,s=void 0!==o&&o,u=e.withoutPrefix,d=void 0!==u&&u,c=e.withoutBackground,m=void 0!==c&&c,v=e.isSmall,g=void 0!==v&&v,y=e.linkUnderlineColor,f=void 0===y?null:y,p=e.className,b=void 0===p?null:p,x=e.backgroundClassName,A=void 0===x?null:x,S=e.collaboratorClassName,C=void 0===S?null:S,w=e.shouldLoad,k=void 0===w||w,j=(0,r.A)(e,mr),M=(0,Zl.A)(),N=l||{},F=N.name,T=void 0===F?null:F,R=N.image,z=void 0===R?null:R,$=N.url,L=void 0===$?null:$,I=N.collaborator,P=void 0===I?null:I,B=n&&null!==z,E=M.formatMessage({id:"jEK6B8",defaultMessage:[{type:0,value:"By"}]}),V=Je(T)?(0,se.jsx)(nn,(0,i.A)({className:Jt([cr.name,A])},T)):null,D=Je(P)?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:cr.collaboratorText},P),{},{inline:!0})):null;return(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:Jt([cr.container,b,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},cr.isSmall,g),cr.withoutAvatar,B),cr.withoutImage,!n||null===z),cr.withoutBackground,m)])},j),{},{children:[d?null:(0,se.jsx)(nn,(0,i.A)((0,i.A)({},T),{},{className:Jt([cr.prefix,A]),body:"<span>".concat(E,"<span>")})),B?(0,se.jsx)(dr,{className:cr.image,image:z,shouldLoad:k}):null,(0,se.jsxs)("div",{className:cr.right,children:[null===L||s?(0,se.jsx)("div",{children:V}):(0,se.jsx)(an,{className:cr.link,url:L,external:!0,style:{backgroundImage:null!==f?"linear-gradient(0deg, ".concat(f," 0, ").concat(f,")"):null},children:V}),null!==D?(0,se.jsx)("div",{className:Jt([cr.collaborator,C]),children:null!==D?D:null}):null]})]}))}var gr=l(6451);function yr(e){var t=e.color,l=void 0===t?"currentColor":t,a=e.strokeWidth,n=void 0===a?3:a,i=e.className,o=void 0===i?null:i;return(0,se.jsx)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0",y:"0px",width:"48.53px",height:"12.38px",viewBox:"0 0 48.53 12.38",className:o,xmlSpace:"preserve",children:(0,se.jsx)("g",{transform:"matrix(1, 0, 0, 1, 0, 0)",children:(0,se.jsx)("path",{id:"b",fill:"none",stroke:l,strokeWidth:"".concat(n,"px"),strokeLinejoin:"round",strokeLinecap:"round",d:"M1.5,10.88L24.26,1.5l22.77,9.38"})})})}function hr(e){var t=e.color,l=void 0===t?"#222":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",x:"0",y:"0px",width:"17.76px",height:"17.76px",viewBox:"0 0 17.76 17.76",className:n,xmlSpace:"preserve",children:(0,se.jsxs)("g",{transform:"translate(0 0)",children:[(0,se.jsx)("path",{fill:l,d:"M8.34,0h1.08s.06,.02,.1,.02c.89,.07,1.77,.26,2.6,.59,1.9,.74,3.48,2.11,4.48,3.88,.5,.88,.85,1.84,1.02,2.84,.06,.34,.1,.69,.14,1.04v1.05s-.02,.1-.03,.15c-.2,2.62-1.55,5.01-3.69,6.53-1.17,.85-2.54,1.39-3.98,1.57l-.64,.09h-1.08s-.1-.02-.15-.03c-.94-.07-1.87-.3-2.74-.66C2.55,15.85,.51,13.18,.08,10.06c-.03-.21-.06-.43-.08-.64v-1.08c0-.06,.02-.11,.03-.17C.21,5.84,1.32,3.67,3.1,2.15,4.4,1.02,6,.3,7.71,.08l.63-.08Zm7.94,8.71c-.09-4.09-3.48-7.32-7.57-7.23-4.09,.09-7.32,3.48-7.23,7.57,.09,4.09,3.48,7.32,7.57,7.23,.04,0,.07,0,.11,0,4.04-.16,7.2-3.53,7.12-7.56h0Z"}),(0,se.jsx)("path",{fill:l,d:"M7.42,8.89v-2.61c-.02-.2,.09-.4,.28-.48,.15-.06,.32-.04,.44,.06,.39,.28,.78,.56,1.17,.85,.82,.59,1.63,1.19,2.45,1.78,.22,.11,.3,.38,.19,.59-.04,.08-.11,.15-.19,.19-.6,.45-1.21,.89-1.82,1.33-.59,.43-1.18,.86-1.78,1.29-.16,.17-.43,.17-.6,0-.02-.02-.03-.03-.04-.05-.07-.11-.1-.24-.1-.37,0-.86,0-1.72,0-2.58h0Z"})]})})}var fr={container:"micromag-screen-urbania-article-urbania-base-article-container",isPlaceholder:"micromag-screen-urbania-article-urbania-base-article-isPlaceholder",articleContent:"micromag-screen-urbania-article-urbania-base-article-articleContent",visual:"micromag-screen-urbania-article-urbania-base-article-visual",isVideo:"micromag-screen-urbania-article-urbania-base-article-isVideo",title:"micromag-screen-urbania-article-urbania-base-article-title",description:"micromag-screen-urbania-article-urbania-base-article-description",sponsors:"micromag-screen-urbania-article-urbania-base-article-sponsors",callToAction:"micromag-screen-urbania-article-urbania-base-article-callToAction",placeholder:"micromag-screen-urbania-article-urbania-base-article-placeholder",emptyContainer:"micromag-screen-urbania-article-urbania-base-article-emptyContainer",small:"micromag-screen-urbania-article-urbania-base-article-small",empty:"micromag-screen-urbania-article-urbania-base-article-empty",background:"micromag-screen-urbania-article-urbania-base-article-background",video:"micromag-screen-urbania-article-urbania-base-article-video",content:"micromag-screen-urbania-article-urbania-base-article-content",overTitle:"micromag-screen-urbania-article-urbania-base-article-overTitle",authors:"micromag-screen-urbania-article-urbania-base-article-authors",lede:"micromag-screen-urbania-article-urbania-base-article-lede",isAboveDescription:"micromag-screen-urbania-article-urbania-base-article-isAboveDescription",sponsor:"micromag-screen-urbania-article-urbania-base-article-sponsor",quatre95:"micromag-screen-urbania-article-urbania-base-article-quatre95",author:"micromag-screen-urbania-article-urbania-base-article-author",urbania:"micromag-screen-urbania-article-urbania-base-article-urbania",dehors:"micromag-screen-urbania-article-urbania-base-article-dehors",universities:"micromag-screen-urbania-article-urbania-base-article-universities",footerContainer:"micromag-screen-urbania-article-urbania-base-article-footerContainer",footer:"micromag-screen-urbania-article-urbania-base-article-footer",arrow:"micromag-screen-urbania-article-urbania-base-article-arrow",icon:"micromag-screen-urbania-article-urbania-base-article-icon",button:"micromag-screen-urbania-article-urbania-base-article-button",mediaControls:"micromag-screen-urbania-article-urbania-base-article-mediaControls",header:"micromag-screen-urbania-article-urbania-base-article-header",bottom:"micromag-screen-urbania-article-urbania-base-article-bottom",visible:"micromag-screen-urbania-article-urbania-base-article-visible",withGradient:"micromag-screen-urbania-article-urbania-base-article-withGradient",image:"micromag-screen-urbania-article-urbania-base-article-image",isCurrent:"micromag-screen-urbania-article-urbania-base-article-isCurrent",slowZoom:"micromag-screen-urbania-article-urbania-base-article-slowZoom",img:"micromag-screen-urbania-article-urbania-base-article-img"},pr=["callToAction"];function br(e){var t=e.hasArticle,l=void 0!==t&&t,n=e.type,o=void 0===n?null:n,s=e.image,u=void 0===s?null:s,d=e.title,c=void 0===d?null:d,m=e.description,v=void 0===m?null:m,g=e.overTitle,y=void 0===g?null:g,f=e.author,p=void 0===f?null:f,b=e.sponsors,x=void 0===b?null:b,A=e.sponsorPrefix,S=void 0===A?null:A,C=e.sponsorColor,w=void 0===C?null:C,k=e.site,j=void 0===k?null:k,M=e.header,N=void 0===M?null:M,F=e.footer,T=void 0===F?null:F,R=e.background,z=void 0===R?null:R,$=e.current,L=void 0===$||$,I=e.preload,P=void 0===I||I,B=e.spacing,E=void 0===B?20:B,V=e.className,D=void 0===V?null:V,O=It(),H=O.width,Z=O.height,W=O.resolution,q=Rt(),_=q.isView,G=q.isPreview,Y=q.isPlaceholder,U=q.isEdit,Q=q.isStatic,X=q.isCapture,J=(z||{}).color,K=void 0===J?null:J,ee=qt(),te=ee.opened,le=ee.open,ae=Ot(),ne=ae.bottomSidesWidth,ie=ae.topHeight,oe=Wt(),re=oe.enableInteraction,ue=oe.disableInteraction,de=jt(),ce=de.muted,me=de.playing,ve=pl(),ge=ve.ref,ye=ve.entry.contentRect,he=ve.height,fe=(ye||{}).top,pe=(0,a.useMemo)(function(){return{imageHeight:Z-he-fe+1}},[fe,he,H,Z]).minContentHeight,be=void 0===pe?null:pe,xe="video"===o,Ae=Je(y),Se=Je(c),Ce=Je(v),we=(x||[]).length>0&&Je(x[0]),ke=(p||{}).name,je=Je(ke),Me=u||{},Ne=Me.url,Fe=void 0===Ne?null:Ne,Te=Me.type,Re=void 0===Te?null:Te,$e=null!==Fe,Le=Ge(N),Ie=Ye(T)||l,Pe={buttonClassName:fr.button,labelClassName:fr.label,arrowClassName:fr.arrow,arrow:(0,se.jsx)(yr,{}),icon:"video"===o?(0,se.jsx)(hr,{className:fr.icon}):null},Be=T||{},Ve=Be.callToAction,De=void 0===Ve?null:Ve,Oe=(0,r.A)(Be,pr),He=ze((0,i.A)((0,i.A)({},Oe),{},{callToAction:(0,i.A)((0,i.A)({},De),Pe)}),{isView:_,current:L,openWebView:le,isPreview:G,animationDisabled:G,focusable:L&&_,enableInteraction:re,disableInteraction:ue}),Ze=(z||{}).video,We=null!==(void 0===Ze?null:Ze),qe=L||P,_e=me&&L,Ue="video"!==Re&&We,Qe=Mt(L,Ue),Xe=Qe.ref,Ke=Qe.isCurrent,et=L&&!te&&(_||U)&&(void 0!==Ke&&Ke||!_),tt=[(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Ba,{className:fr.placeholder}),empty:(0,se.jsx)("div",{className:Jt([fr.emptyContainer,fr.small]),children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"pRzSQ7",defaultMessage:[{type:0,value:"Overtitle"}]})})}),isEmpty:!Ae,children:Ae?(0,se.jsx)(_n,(0,i.A)({className:Jt([fr.overTitle])},y)):null},"overTitle"),(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Va,{className:fr.placeholder}),empty:(0,se.jsx)("div",{className:fr.emptyContainer,children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"2ZOPe+",defaultMessage:[{type:0,value:"Title"}]})})}),isEmpty:!Se,children:Se?(0,se.jsx)(_n,(0,i.A)({className:Jt([fr.title])},c)):null},"title"),(0,se.jsx)(Qa,{empty:(0,se.jsx)("div",{className:fr.emptyContainer,children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"6jX5Tb",defaultMessage:[{type:0,value:"Authors"}]})})}),isEmpty:!je,children:je?(0,se.jsx)("div",{className:Jt([fr.authors,(0,h.A)({},fr.isAboveDescription,Ce)]),children:(0,se.jsx)(vr,{author:p,shouldLoad:qe})}):null},"authors"),(0,se.jsx)(Qa,{empty:(0,se.jsx)("div",{className:fr.emptyContainer,children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"zl6zsZ",defaultMessage:[{type:0,value:"Lede"}]})})}),isEmpty:!Ce&&!l,children:Ce?(0,se.jsx)("div",{className:Jt([fr.description]),children:(0,se.jsx)(nn,(0,i.A)({className:Jt([fr.lede])},v))}):null},"description"),(0,se.jsx)(Qa,{empty:(0,se.jsx)("div",{className:Jt([fr.emptyContainer,fr.small]),children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"zGIcdn",defaultMessage:[{type:0,value:"Sponsors"}]})})}),isEmpty:!we&&!l,children:we?(0,se.jsx)("div",{className:fr.sponsors,style:(0,i.A)({},Ee(w)),children:x.map(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=(e||{}).body,l=void 0===t?"":t;return(0,se.jsxs)(a.Fragment,{children:[null!==S?(0,se.jsx)("span",{className:fr.sponsor,children:S}):null,(0,se.jsx)("span",{children:" "}),(0,se.jsx)(_n,(0,i.A)({className:fr.sponsor,size:"6"},e))]},l)})}):null},"sponsors")].filter(function(e){return null!==e});return(0,se.jsxs)("div",{className:Jt([fr.container,D,(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},fr.isCurrent,L),fr.isVideo,xe),fr.hasVideoBackground,We),fr.isPlaceholder,Y)]),"data-screen-ready":Q||X,children:[(0,se.jsx)(pn,{className:fr.background,background:z,width:H,height:Z,resolution:W,playing:et,muted:ce,shouldLoad:qe,mediaRef:Ue?Xe:null,withoutVideo:G}),(0,se.jsxs)(An,{className:fr.content,width:H,height:Z,children:[!Y&&Le?(0,se.jsx)("div",{className:fr.header,style:{paddingTop:E/2,paddingLeft:E,paddingRight:E,transform:G?null:"translate(0, ".concat(ie,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},N))},"header"):null,(0,se.jsx)("div",{className:Jt([fr.articleContent,(0,h.A)({},fr["".concat(j)],null!==j)]),style:(0,i.A)({paddingTop:E,minHeight:be},xe?null:Ee(K,"backgroundColor")),ref:ge,children:tt}),(0,se.jsx)("div",{className:fr.visual,children:(0,se.jsxs)(Qa,{placeholder:(0,se.jsx)(La,{className:fr.placeholder}),empty:(0,se.jsx)("div",{className:fr.emptyContainer,children:(0,se.jsx)(ka,{className:fr.empty,children:(0,se.jsx)(Wl.A,{id:"ebsPd4",defaultMessage:[{type:0,value:"Image"}]})})}),isEmpty:!$e&&!l,children:[$e&&!xe?(0,se.jsx)(Nn,{className:fr.image,imageClassName:fr.img,media:u,width:H,height:Z,resolution:W,objectFit:{fit:"cover"},shouldLoad:qe}):null,$e&&xe&&!We?(0,se.jsx)(Nn,{className:fr.video,media:u,width:H,height:Z,resolution:W,objectFit:{fit:"cover"},shouldLoad:qe,playing:_e,muted:ce,withoutVideo:G,mediaRef:Xe,autoPlay:!0}):null]},"image")}),(0,se.jsx)("div",{className:fr.footerContainer,children:!Y&&Ie?(0,se.jsx)("div",{style:{paddingTop:E,paddingLeft:Math.max(0,ne-E),paddingRight:Math.max(0,ne-E)},className:fr.footer,children:(0,se.jsx)(Dn,(0,i.A)({},He))}):null})]})]})}var xr=["component","title","articleType","overTitle","sponsorLabel","author","image","header","footer","url","article"];function Ar(e){var t=e.component,l=void 0===t?br:t,n=e.title,o=void 0===n?null:n,s=e.articleType,u=void 0===s?null:s,d=e.overTitle,c=void 0===d?null:d,m=e.sponsorLabel,v=void 0===m?null:m,g=e.author,y=void 0===g?null:g,h=e.image,f=void 0===h?null:h,p=e.header,b=void 0===p?null:p,x=e.footer,A=void 0===x?null:x,S=e.url,C=void 0===S?null:S,w=e.article,k=void 0===w?null:w,j=(0,r.A)(e,xr),M=(0,a.useState)(k),N=(0,R.A)(M,2),F=N[0],T=N[1],z=null!==C&&Ke(C)?C.replace(/^https?:\/\/([^.]+\.)?urbania\.(ca|ƒr)\//,"https://urbania.$2/"):null;(0,a.useEffect)(function(){null!==z&&(0,sr.hm)("https://api.urbania.ca/documents?uri=".concat(z),{mode:"cors"}).then(function(e){T(e||null)}).catch(function(e){T(null)})},[C,z,T]);var $=(0,a.useMemo)(function(){var e=(f||{}).url,t=void 0===e?null:e,l=(A||{}).callToAction,a=void 0===l?null:l,n=(a||{}).url,r=void 0===n?null:n,s=F||{},d=s.type,m=void 0===d?null:d,g=s.title,h=void 0===g?null:g,p=s.image,x=void 0===p?null:p,S=s.metadata,C=null!==F,w=(void 0===S?{}:S)||{},k=w.authors,j=void 0===k?[]:k,M=w.sponsors,N=void 0===M?[]:M,T=w.brands,$=void 0===T?[]:T,L=j||[],I=(0,R.A)(L,1)[0],P=void 0===I?null:I,B=$||[],E=(0,R.A)(B,1)[0],V=(void 0===E?{}:E).handle,D=void 0===V?null:V,O=(x||{}).sizes,H=(void 0===O?{}:O)||{},Z=H.medium,W=void 0===Z?{}:Z,q=H.large,_=void 0===q?{}:q,G=P||{},Y=G.name,U=void 0===Y?null:Y,Q=G.image,X=void 0===Q?null:Q,J=null!==U&&""!==U,K=(0,i.A)((0,i.A)({},J?{name:{body:"<p>".concat(U,"</p>")}}:null),null!==X?{image:X}:null),ee=u||m,te=(N||[]).length>0?(N||[]).map(function(e){var t=e.organisation,l=(void 0===t?{}:t).name;return void 0===l?null:l}).filter(function(e){return null!==e}).join(", ").trim():null,le=Je(o),ae=Je(c),ne=Je(v),ie=null!==y&&null!==y.name&&Je(y.name),oe=ne||null===te?null:(0,se.jsx)(Wl.A,{id:"+TPjd4",defaultMessage:[{type:0,value:"Presented by"}]});return{type:ee,title:le?o:(0,i.A)((0,i.A)({},o),{},{body:h}),articleTitle:h,overTitle:ae?c:(0,i.A)((0,i.A)({},c),{},{body:"En vedette"}),author:(0,i.A)((0,i.A)({},K),ie?y:null),sponsors:null===te||ne?[v]:[(0,i.A)((0,i.A)({},v),{},{body:"<strong>".concat(te,"</strong>")})],sponsorPrefix:oe,site:D,image:null!==t&&null!==f?f:(0,i.A)((0,i.A)({type:"image"},x),{},{sizes:{medium:W,large:_}}),url:z,header:b,footer:(0,i.A)((0,i.A)({},A),{},{callToAction:(0,i.A)((0,i.A)((0,i.A)({type:"swipe-up",label:"video"===ee?{body:"Regarder"}:{body:"Lire"},inWebView:!0},a),C?{active:null!==z}:null),{},{url:r||z})})}},[F,C,o,z,j,u,c,v,y,f,b,A]),L=($||{}).title,I=((void 0===L?null:L)||{}).body,P=void 0===I?null:I;return(0,se.jsx)(l,(0,i.A)((0,i.A)((0,i.A)({},j),$),{},{hasArticle:null!==P}))}var Sr={id:"urbania-article",type:"screen",namespaces:["urbania"],group:{label:(0,ue.zR)({id:"oPjl8f",defaultMessage:[{type:0,value:"Urbania"}]}),order:10},title:(0,ue.zR)({id:"nJgzwC",defaultMessage:[{type:0,value:"Urbania article"}]}),component:Ar,fields:[{name:"url",type:"url",label:(0,ue.zR)({id:"2pO2Cj",defaultMessage:[{type:0,value:"Url"}]})},{name:"articleType",type:"select",label:(0,ue.zR)({id:"ppq6CK",defaultMessage:[{type:0,value:"Type"}]}),options:[{value:"article",label:(0,ue.zR)({id:"pE7UhY",defaultMessage:[{type:0,value:"Article"}]})},{value:"video",label:(0,ue.zR)({id:"J9e9Qb",defaultMessage:[{type:0,value:"Video"}]})}]},{name:"overTitle",type:"heading-element",defaultValue:{body:"En vedette"},label:(0,ue.zR)({id:"z2I2bJ",defaultMessage:[{type:0,value:"Overtitle"}]})},{name:"title",type:"heading-element",label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"cuKSQz",defaultMessage:[{type:0,value:"Lede"}]})},{name:"author",type:"author-element",label:(0,ue.zR)({id:"73hxYw",defaultMessage:[{type:0,value:"Author"}]})},{name:"sponsorLabel",type:"heading-element",label:(0,ue.zR)({id:"hzvEim",defaultMessage:[{type:0,value:"Sponsor Label"}]})},{name:"sponsorColor",type:"color",label:(0,ue.zR)({id:"Qw8cb5",defaultMessage:[{type:0,value:"Sponsor color"}]})},{name:"image",type:"visual",label:(0,ue.zR)({id:"k+coTi",defaultMessage:[{type:0,value:"Image"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},Cr={container:"micromag-screen-urbania-article-urbania-base-article-card-container",background:"micromag-screen-urbania-article-urbania-base-article-card-background",content:"micromag-screen-urbania-article-urbania-base-article-card-content",layout:"micromag-screen-urbania-article-urbania-base-article-card-layout",text:"micromag-screen-urbania-article-urbania-base-article-card-text",cardContainer:"micromag-screen-urbania-article-urbania-base-article-card-cardContainer",isPlaceholder:"micromag-screen-urbania-article-urbania-base-article-card-isPlaceholder",card:"micromag-screen-urbania-article-urbania-base-article-card-card",callToAction:"micromag-screen-urbania-article-urbania-base-article-card-callToAction",arrow:"micromag-screen-urbania-article-urbania-base-article-card-arrow",ctaText:"micromag-screen-urbania-article-urbania-base-article-card-ctaText",cardInner:"micromag-screen-urbania-article-urbania-base-article-card-cardInner",pulse:"micromag-screen-urbania-article-urbania-base-article-card-pulse",dragHandle:"micromag-screen-urbania-article-urbania-base-article-card-dragHandle",articlePreview:"micromag-screen-urbania-article-urbania-base-article-card-articlePreview",articlePreviewInner:"micromag-screen-urbania-article-urbania-base-article-card-articlePreviewInner",articleTitle:"micromag-screen-urbania-article-urbania-base-article-card-articleTitle",placeholder:"micromag-screen-urbania-article-urbania-base-article-card-placeholder",empty:"micromag-screen-urbania-article-urbania-base-article-card-empty",header:"micromag-screen-urbania-article-urbania-base-article-card-header"};function wr(e){var t=e.hasArticle,l=void 0!==t&&t,n=e.url,o=void 0===n?null:n,r=e.title,s=void 0===r?null:r,u=e.author,d=void 0===u?null:u,c=e.text,m=void 0===c?null:c,v=e.image,y=void 0===v?null:v,f=e.header,p=void 0===f?null:f,b=e.background,x=void 0===b?null:b,A=e.callToAction,S=void 0===A?null:A,C=e.current,w=void 0===C||C,k=e.preload,j=void 0===k||k,M=e.spacing,N=void 0===M?20:M,F=e.className,T=void 0===F?null:F,z=(0,Zl.A)(),$=null!==x&&(void 0!==x.color&&null!==x.color||void 0!==x.image&&null!==x.image||void 0!==x.video&&null!==x.video)?x:{image:y},L=($||{}).video,I=null!==(void 0===L?null:L),P=It(),B=P.width,E=P.height,V=P.resolution,D=Rt(),O=D.isView,H=D.isPreview,Z=D.isPlaceholder,W=D.isEdit,q=D.isStatic,_=D.isCapture,G=qt(),Y=G.open,U=G.opened,Q=void 0!==U&&U,X=G.close,J=void 0===X?null:X,K=Ot(),ee=K.topHeight,te=K.bottomHeight,le=Wt(),ae=le.enableInteraction,ne=le.disableInteraction,ie=jt(),oe=ie.playing,re=ie.muted,ue=ie.setControls,de=ie.setControlsTheme,ce=ie.setControlsSuggestPlay,me=ie.setPlaying,ve=(d||{}).name,ge=void 0===ve?null:ve,ye=null!==o&&g(o)&&o.length>0,he=Ge(p),fe=Je(m),pe=Je(s),be=Je(ge),xe=Je(S),Ae=(0,a.useMemo)(function(){var e=ye?o.replace(/^https?:\/\/([^.]+\.)?urbania\.(fr|ca)\//,"https://urbania.$2/"):o,t=gr.A.parse(null!==e&&-1!==e.indexOf("?")?e.split("?")[1]:"");return null!==e?"".concat(e.split("?")[0],"?").concat(gr.A.stringify((0,i.A)({reader:!0,_ref:"micromag"},t))):o},[ye,o]),Se=w||j,Ce=Mt(w&&!Q,!0),we=Ce.ref,ke=Ce.isCurrent,je=w&&(O||W)&&(void 0!==ke&&ke||!O),Me=!Z&&!H&&!q,Ne=Me&&I&&je,Fe=Me&&w;(0,a.useEffect)(function(){return w?(de({seekBarOnly:!0}),ue(!(!I||Q)),function(){I&&!Q&&ue(!1)}):function(){}},[w,ue,I,Q,ue,de]);var Te=(0,a.useCallback)(function(){Q?ae():(Y(Ae),ne())},[Q,ne,ae,Y,Ae]),Re=(0,Xt.useGesture)({onDrag:function(e){var t=(0,R.A)(e.movement,2)[1];(!Q&&t<0||Q&&t>0)&&Te()},onWheel:function(e){var t=(0,R.A)(e.movement,2)[1];(!Q&&t>0||Q&&t<0)&&Te()}},{drag:{axis:"y",filterTaps:!0,preventDefault:!0},wheel:{axis:"y"}}),ze=fl({disabled:!Q}),$e=ze.ref,Le=ze.entry.contentRect,Ie=((void 0===Le?null:Le)||{}).height,Pe=void 0===Ie?0:Ie,Be=100;w&&(Be=100-Math.max(Pe/E*100,20));var Ee=(0,oa.zh)({from:{y:H?Be:100},to:{y:Be},delay:Ne?1500:0,config:{easing:oa.le.easeInOutSine,duration:100===Be?1e3:400}});(0,a.useEffect)(function(){},[w,Q,J,ae]);var Ve=(0,a.useCallback)(function(){O&&oe&&w&&I&&(me(!1),ce(!0))},[O,w,oe,I,me,ce]);return(0,se.jsxs)("div",{className:Jt([Cr.container,T,(0,h.A)((0,h.A)({},Cr.isCurrent,w),Cr.isPlaceholder,Z)]),"data-screen-ready":q||_,children:[(0,se.jsx)(pn,{className:Cr.background,background:$,width:B,height:E,resolution:V,playing:je&&!Q,muted:re,mediaRef:we,onPlayError:Ve,shouldLoad:Se,withoutVideo:H}),(0,se.jsxs)(An,{className:Cr.content,width:B,height:E,children:[!Z&&he?(0,se.jsx)("div",{className:Cr.header,style:{paddingTop:N/2,paddingLeft:N,paddingRight:N,transform:H?null:"translate(0, ".concat(ee,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},p))},"header"):null,(0,se.jsx)(Qn,{className:Cr.layout,height:.65*E,children:(0,se.jsx)(Qa,{empty:(0,se.jsx)(ka,{className:Cr.emptyText,children:(0,se.jsx)(Wl.A,{id:"z4CiV1",defaultMessage:[{type:0,value:"Text"}]})}),placeholder:(0,se.jsx)(Ea,{className:Cr.placeholderText}),children:fe?(0,se.jsx)(nn,(0,i.A)({className:Cr.text},m)):null},"text")}),(0,se.jsx)(An,{className:Jt([Cr.cardContainer,(0,h.A)({},Cr.isPlaceholder,Z)]),children:(0,se.jsx)(Qa,{placeholderProps:{className:Cr.placeholder},emptyLabel:(0,se.jsx)(Wl.A,{id:"yMpGIc",defaultMessage:[{type:0,value:"Article"}]}),emptyClassName:Cr.empty,isEmpty:!ye||!l,children:!Z&&l?(0,se.jsxs)(oa.CS.div,{className:Cr.card,style:{height:E,width:B,transform:H?"translateY(".concat(80,"%)"):Ee.y.to(function(e){return"translateY(".concat(e,"%")})},children:[(0,se.jsx)("button",(0,i.A)({type:"button",onClick:Te,className:Cr.dragHandle,tabIndex:w?0:-1,"aria-label":z.formatMessage({id:"IoMJgw",defaultMessage:[{type:0,value:"Toggle article"}]}),"aria-pressed":Q},w?Re():null)),(0,se.jsxs)("div",{className:Jt([Cr.cardInner,(0,h.A)({},Cr.pulse,Fe)]),children:[xe?(0,se.jsxs)("div",{className:Cr.callToAction,children:[(0,se.jsx)(yr,{strokeWidth:1,className:Cr.arrow}),(0,se.jsx)(nn,(0,i.A)({className:Cr.ctaText},S))]}):null,(0,se.jsx)("div",{className:Cr.articlePreview,ref:$e,children:(0,se.jsxs)("div",{className:Cr.articlePreviewInner,style:{paddingBottom:w&&!H?Math.max(te,20):null},children:[pe?(0,se.jsx)(_n,(0,i.A)({className:Jt([Cr.articleTitle])},s)):null,be?(0,se.jsx)(vr,{isSmall:!0,withoutBackground:!0,author:d,shouldLoad:Se}):null]})})]})]}):null})})]})]})}var kr={id:"urbania-article-card",type:"screen",namespaces:["urbania"],group:{label:(0,ue.zR)({id:"oPjl8f",defaultMessage:[{type:0,value:"Urbania"}]}),order:10},title:(0,ue.zR)({id:"nJgzwC",defaultMessage:[{type:0,value:"Urbania article"}]}),component:function(e){var t=(e||{}).cardCallToAction,l=void 0===t?{}:t;return(0,se.jsx)(Ar,(0,i.A)({component:wr,callToAction:l},e))},fields:[{name:"url",type:"url",label:(0,ue.zR)({id:"2pO2Cj",defaultMessage:[{type:0,value:"Url"}]})},{name:"title",type:"heading-element",label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"author",type:"author-element",label:(0,ue.zR)({id:"73hxYw",defaultMessage:[{type:0,value:"Author"}]})},{name:"text",type:"text-element",fieldsProps:{textStyle:{excludedFields:["highlight","link"]}},label:(0,ue.zR)({id:"4E2gbX",defaultMessage:[{type:0,value:"Text"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"cardCallToAction",type:"text-element",fieldsProps:{textStyle:{excludedFields:["highlight","link"]}},label:(0,ue.zR)({id:"eBFxNl",defaultMessage:[{type:0,value:"Call to Action"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}}]},jr=l.p+"static/media/38b67a045c917eba.e6e69508c2874940ccf5.png",Mr=l.p+"static/media/f1d91f035ccb8c4f.cf7fe3cdf6b99f3937c0.png",Nr=l.p+"static/media/c2730eca851f3186.6b706bc308ab406bdc0a.png",Fr=l.p+"static/media/a6d606997910361a.798f151041dae7550524.png",Tr=l.p+"static/media/12148919dcf14f67.86a591223295244b0d7f.png",Rr=l.p+"static/media/5ccc4bde48c478ee.906bd043a9344f192acf.png",zr=l.p+"static/media/d94c6aef4634d47f.0aa17efacea9438ca7af.png",$r=l.p+"static/media/bc3a4d9747d9235c.cb79868c1299ee1d9ce6.png",Lr=l.p+"static/media/4aec8c7b2b1f6739.f679137fdc2040d22d60.png",Ir=l.p+"static/media/01b9ca612cf4a6a6.77c1dfc199d2da49d465.png",Pr=l.p+"static/media/3a3a4d27b9a019b2.a66beb0b99213523e04d.png",Br=l.p+"static/media/f3452bab9d2d80d5.eae38988e000ba051294.png",Er=l.p+"static/media/f82faebe2d495394.042a94dd81202e81b92e.png",Vr=l.p+"static/media/ddafd58fab0d5925.d89063fa6da5b944d7ef.png",Dr=l.p+"static/media/7d6b81c3035f5968.846ef58b3f258346f088.png",Or=l.p+"static/media/422146a5faadb139.13a3f00ad0c07d3f9741.png",Hr=l.p+"static/media/ead69accd3f76ece.a95331e7f1e86a05ff08.png",Zr=l.p+"static/media/36c18c31d1e80a70.653a2699b3b21d9b1ed9.png",Wr=l.p+"static/media/ef219f6696d5ce04.a08d7046ef2af71205ba.png",qr=l.p+"static/media/f21db7431692d889.3f599fa556b406bbed82.png",_r=l.p+"static/media/0964d576c4c1da6d.6476c469b305c7e636c9.png",Gr=l.p+"static/media/1ffa37309c1fbcfa.12c9287ed3fe592ee844.png",Yr=l.p+"static/media/822018b354054d62.c8e23b27e8f926515005.png",Ur=l.p+"static/media/b3e1e35461e78e82.a86f7561afbc039e2933.png",Qr=[{id:"aries",image:Mr,thumbnail:Vr,label:(0,ue.zR)({id:"/PJA/1",defaultMessage:[{type:0,value:"Aries"}]}),date:(0,ue.zR)({id:"ZeosMy",defaultMessage:[{type:0,value:"Mar 21 - Apr 19"}]})},{id:"taurus",image:Pr,thumbnail:Yr,label:(0,ue.zR)({id:"XKcyqx",defaultMessage:[{type:0,value:"Taurus"}]}),date:(0,ue.zR)({id:"raUY02",defaultMessage:[{type:0,value:"Apr 20 - May 20"}]})},{id:"gemini",image:Tr,thumbnail:Hr,label:(0,ue.zR)({id:"4g35M0",defaultMessage:[{type:0,value:"Gemini"}]}),date:(0,ue.zR)({id:"142Fjj",defaultMessage:[{type:0,value:"May 21 - June 20"}]})},{id:"cancer",image:Nr,thumbnail:Dr,label:(0,ue.zR)({id:"0acGK7",defaultMessage:[{type:0,value:"Cancer"}]}),date:(0,ue.zR)({id:"bMdONM",defaultMessage:[{type:0,value:"June 21 - July 22"}]})},{id:"leo",image:Rr,thumbnail:Zr,label:(0,ue.zR)({id:"EEUc6n",defaultMessage:[{type:0,value:"Leo"}]}),date:(0,ue.zR)({id:"MBgLeH",defaultMessage:[{type:0,value:"July 23 - Aug 22"}]})},{id:"virgo",image:Br,thumbnail:Ur,label:(0,ue.zR)({id:"6bd963",defaultMessage:[{type:0,value:"Virgo"}]}),date:(0,ue.zR)({id:"xL0GD2",defaultMessage:[{type:0,value:"Aug 23 - Sept 22"}]})},{id:"libra",image:zr,thumbnail:Wr,label:(0,ue.zR)({id:"M/FGRs",defaultMessage:[{type:0,value:"Libra"}]}),date:(0,ue.zR)({id:"F0QDfY",defaultMessage:[{type:0,value:"Sept 23 - Oct 22"}]})},{id:"scorpio",image:Ir,thumbnail:Gr,label:(0,ue.zR)({id:"YyPYHk",defaultMessage:[{type:0,value:"Scorpio"}]}),date:(0,ue.zR)({id:"7ZzlUE",defaultMessage:[{type:0,value:"Oct 23 - Nov 22"}]})},{id:"sagittarius",image:Lr,thumbnail:_r,label:(0,ue.zR)({id:"7mMPO4",defaultMessage:[{type:0,value:"Sagittarius"}]}),date:(0,ue.zR)({id:"yCj5uv",defaultMessage:[{type:0,value:"Nov 23 - Dec 21"}]})},{id:"capricorn",image:Fr,thumbnail:Or,label:(0,ue.zR)({id:"NumcrW",defaultMessage:[{type:0,value:"Capricorn"}]}),date:(0,ue.zR)({id:"rAkTvt",defaultMessage:[{type:0,value:"Dec 22 - Jan 20"}]})},{id:"aquarius",image:jr,thumbnail:Er,label:(0,ue.zR)({id:"fBii8l",defaultMessage:[{type:0,value:"Aquarius"}]}),date:(0,ue.zR)({id:"Op1ZIp",defaultMessage:[{type:0,value:"Jan 21 - Feb 18"}]})},{id:"pisces",image:$r,thumbnail:qr,label:(0,ue.zR)({id:"dxAumJ",defaultMessage:[{type:0,value:"Pisces"}]}),date:(0,ue.zR)({id:"Evl2dG",defaultMessage:[{type:0,value:"Feb 19 - Mar 20"}]})}],Xr={container:"micromag-screen-urbania-horoscope-sign-card-container",placeholder:"micromag-screen-urbania-horoscope-sign-card-placeholder",thumbnail:"micromag-screen-urbania-horoscope-sign-card-thumbnail",name:"micromag-screen-urbania-horoscope-sign-card-name",date:"micromag-screen-urbania-horoscope-sign-card-date",emptyText:"micromag-screen-urbania-horoscope-sign-card-emptyText"};function Jr(e){var t=e.className,l=void 0===t?null:t,a=e.sign,n=void 0===a?null:a,o=e.focusable,r=void 0===o||o,s=e.onClick,u=void 0===s?null:s,d=n||{},c=d.id,m=void 0===c?null:c,v=d.thumbnail,g=void 0===v?null:v,y=d.label,h=void 0===y?null:y,f=d.date,p=void 0===f?null:f;return(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Va,{className:Xr.placeholder}),emptyLabel:(0,se.jsx)(Wl.A,{id:"ceaRdq",defaultMessage:[{type:0,value:"Horoscope sign"}]}),emptyClassName:Xr.emptyText,isEmpty:!m,children:(0,se.jsxs)("button",{className:Jt([Xr.container,l]),type:"button",tabIndex:r?"0":-1,onClick:u,children:[null!==g?(0,se.jsx)("img",{className:Xr.thumbnail,src:g,alt:m,loading:"lazy"}):null,(0,se.jsxs)("div",{className:Xr.gridText,children:[(0,se.jsx)("h2",{className:Xr.name,children:null!==h?(0,se.jsx)(Wl.A,(0,i.A)({},h)):null}),(0,se.jsx)("p",{className:Xr.date,children:null!==p?(0,se.jsx)(Wl.A,(0,i.A)({},p)):null})]})]})})}var Kr={container:"micromag-screen-urbania-horoscope-sign-modal-container",modalButton:"micromag-screen-urbania-horoscope-sign-modal-modalButton",modal:"micromag-screen-urbania-horoscope-sign-modal-modal",name:"micromag-screen-urbania-horoscope-sign-modal-name",wordContainer:"micromag-screen-urbania-horoscope-sign-modal-wordContainer",wordOfTheWeek:"micromag-screen-urbania-horoscope-sign-modal-wordOfTheWeek",word:"micromag-screen-urbania-horoscope-sign-modal-word",description:"micromag-screen-urbania-horoscope-sign-modal-description",illustration:"micromag-screen-urbania-horoscope-sign-modal-illustration"};function es(e){var t=e.width,l=void 0===t?null:t,a=e.height,n=void 0===a?null:a,o=e.sign,r=void 0===o?null:o,s=e.subtitle,u=void 0===s?null:s,d=e.current,c=void 0===d||d,m=e.transitionDisabled,v=void 0!==m&&m,g=e.focusable,y=void 0===g||g,f=e.onClick,p=void 0===f?null:f,b=e.className,x=void 0===b?null:b,A=r||{},S=A.label,C=void 0===S?null:S,w=A.image,k=void 0===w?null:w;A.date;var j=A.word,M=void 0===j?null:j,N=A.description,F=void 0===N?null:N,T=Rt().isEdit,R=Je(M),z=Je(u),$=!T&&v||!c;return(0,se.jsx)(An,{width:l,height:n,className:Jt([Kr.container,x,(0,h.A)({},Kr.withoutTransitions,v)]),children:(0,se.jsx)("button",{type:"button",className:Kr.modalButton,tabIndex:y?"0":"-1",onClick:function(e){null!==p&&p(e)},children:(0,se.jsx)(ei,{disabled:$,verticalAlign:"middle",children:(0,se.jsxs)("div",{className:Kr.modal,children:[null!==C?(0,se.jsx)(Qa,{children:(0,se.jsx)("h2",{className:Kr.name,children:(0,se.jsx)(Wl.A,(0,i.A)({},C))})}):null,R?(0,se.jsxs)("div",{className:Kr.wordContainer,children:[z?(0,se.jsx)(_n,(0,i.A)({className:Kr.wordOfTheWeek},u)):(0,se.jsx)("h3",{className:Kr.wordOfTheWeek,children:(0,se.jsx)(Wl.A,{id:"+vzDdb",defaultMessage:[{type:0,value:"Word of the Week"}]})}),(0,se.jsx)(nn,(0,i.A)({className:Kr.word},M))]}):null,F?(0,se.jsx)(nn,(0,i.A)({className:Kr.description},F)):null,k?(0,se.jsx)("img",{className:Kr.illustration,src:k,alt:C}):null]})})})})}var ts={container:"micromag-screen-urbania-horoscope-container",background:"micromag-screen-urbania-horoscope-background",content:"micromag-screen-urbania-horoscope-content",isPlaceholder:"micromag-screen-urbania-horoscope-isPlaceholder",layout:"micromag-screen-urbania-horoscope-layout",placeholderGrid:"micromag-screen-urbania-horoscope-placeholderGrid",placeholderItem:"micromag-screen-urbania-horoscope-placeholderItem",emptyText:"micromag-screen-urbania-horoscope-emptyText",headerContainer:"micromag-screen-urbania-horoscope-headerContainer",title:"micromag-screen-urbania-horoscope-title",titleImage:"micromag-screen-urbania-horoscope-titleImage",description:"micromag-screen-urbania-horoscope-description",button:"micromag-screen-urbania-horoscope-button",buttonLabel:"micromag-screen-urbania-horoscope-buttonLabel",header:"micromag-screen-urbania-horoscope-header",buttons:"micromag-screen-urbania-horoscope-buttons",close:"micromag-screen-urbania-horoscope-close",signsGridContainer:"micromag-screen-urbania-horoscope-signsGridContainer",author:"micromag-screen-urbania-horoscope-author",collaborator:"micromag-screen-urbania-horoscope-collaborator",authorBackground:"micromag-screen-urbania-horoscope-authorBackground",modal:"micromag-screen-urbania-horoscope-modal",backdrop:"micromag-screen-urbania-horoscope-backdrop"},ls={onTouchMove:function(e){return e.stopPropagation()},onTouchStart:function(e){return e.stopPropagation()},onTouchEnd:function(e){return e.stopPropagation()},onPointerMove:function(e){return e.stopPropagation()},onPointerUp:function(e){return e.stopPropagation()},onPointerDown:function(e){return e.stopPropagation()}},as=(0,i.A)((0,i.A)({},ls),{},{onClick:function(e){return e.stopPropagation()},style:{position:"fixed",zIndex:"1000",top:0,right:0,bottom:0,left:0,cursor:"default"}}),ns=[{id:"urbania-horoscope",type:"screen",namespaces:["urbania","bayard"],group:{label:(0,ue.zR)({id:"oPjl8f",defaultMessage:[{type:0,value:"Urbania"}]}),order:10},title:(0,ue.zR)({id:"F59wsl",defaultMessage:[{type:0,value:"Urbania horoscope"}]}),component:function(e){var t,l=e.defaultSigns,n=void 0===l?Qr:l,r=e.signs,s=void 0===r?null:r,u=e.title,d=void 0===u?null:u,c=e.description,m=void 0===c?null:c,v=e.author,g=void 0===v?null:v,y=e.button,f=void 0===y?null:y,p=e.signSubtitle,b=void 0===p?null:p,x=e.spacing,A=void 0===x?20:x,S=e.background,C=void 0===S?null:S,w=e.popupBackground,k=void 0===w?null:w,j=e.current,M=void 0===j||j,N=e.preload,F=void 0===N||N,T=e.type,z=void 0===T?"horoscope":T,$=e.className,L=void 0===$?null:$,I=(0,Zl.A)(),P=$l(z),B=Wt(),E=B.enableInteraction,V=B.disableInteraction,D=jt().muted,O=Mt(M,!0),H=O.ref,Z=O.isCurrent,W=void 0!==Z&&Z,q=null!==g&&Je(g.name),_=(0,a.useMemo)(function(){return n.map(function(e,t){return(0,i.A)((0,i.A)({},null!==s?s.find(function(t){return t.id===e.id})||s[t]:null),e)})},[s]),G=It(),Y=G.width,U=G.height,Q=G.resolution,X=Ot(),J=X.topHeight,K=X.bottomHeight,ee=Rt(),te=ee.isView,le=ee.isPreview,ae=ee.isPlaceholder,ne=ee.isEdit,ie=Je(d),oe=Je(m),re=Je(f),ue=M&&(te||ne)&&(W||!te),de=!ae&&(M||F),ce=(0,a.useState)(!1),me=(0,R.A)(ce,2),ve=me[0],ge=me[1],ye=(0,a.useState)(null),he=(0,R.A)(ye,2),fe=he[0],pe=he[1],be=(0,a.useState)(!1),xe=(0,R.A)(be,2),Ae=xe[0],Se=xe[1],Ce=(k||{}).video,we=((void 0===Ce?null:Ce)||{}).url,ke=void 0===we?null:we,je=(0,a.useCallback)(function(){ge(!0),V(),P("open")},[V,P]),Me=(0,a.useCallback)(function(){Ae?Se(!1):(ge(!1),Se(!1),E(),P("close"))},[Ae,ge,Se,E,P]),Ne=(0,a.useCallback)(function(e,t){e.stopPropagation();var l=_.findIndex(function(e){return e.id===t});pe(l),Se(!0),P("select_sign",_[l])},[_,pe,P]),Fe=(0,a.useCallback)(function(){Se(!1),P("close_sign")},[Se,P]),Te=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.movement,2)[1],a=(0,R.A)(e.velocity,2)[1],n="undefined"!=typeof window?window.innerHeight:0,i=n>0?Math.max(0,l)/(.8*n):0,o=a>.3||Math.abs(i)>.3;return t?1-i:(o&&Me(),o?0:1)},[Me]),Re=dl({disabled:!te,progress:ve?1:0,computeProgress:Te,springParams:{config:{tension:300,friction:30}},dragOptions:{pointer:{keys:!1}}}),ze=Re.bind,$e=Re.progress,Le=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.movement,2)[1],a=(0,R.A)(e.velocity,2)[1],n="undefined"!=typeof window?window.innerHeight:0,i=n>0?Math.max(0,l)/n:0,o=.5*i,r=a>.3||Math.abs(i)>.3;return t?1-o:(r&&Fe(),r?0:1)},[Ae,Fe]),Ie=dl({disabled:!te,progress:Ae?1:0,computeProgress:Le,springParams:{config:{tension:300,friction:30}},dragOptions:{pointer:{keys:!1}}}),Pe=Ie.bind,Be=Ie.progress,Ee=function(e){return{opacity:e,transform:e.to(function(e){return"translateY(".concat(3*Math.pow(1-e,5),"rem) scale(").concat(1-.25*(1-e),")")})}},Ve=zt();return(0,a.useEffect)(function(){if(ge(!1),null!==Ve&&"intro"!==Ve||(ge(!1),Se(!1)),"grid"===Ve&&(ge(!0),pe(null),Se(!1)),null!==Ve&&Ve.includes("signs")){var e=Ve.split(".").pop();ge(!0),Se(!0),pe(e)}},[Ve,ge,Se,pe]),(0,a.useEffect)(function(){var e=function(e){if("Escape"===e.key){if(Ae)return void Fe();ve&&Me()}};return document.addEventListener("keyup",e),function(){document.removeEventListener("keyup",e)}},[Ae,Fe,ve,Me]),(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:Jt([ts.container,L,(0,h.A)({},ts.isPlaceholder,ae)]),"data-screen-ready":!0},ve?ls:null),{},{children:[te?null:(0,se.jsx)("div",(0,i.A)({},as)),(0,se.jsx)(An,{width:Y,height:U,className:ts.content,children:(0,se.jsxs)(Qn,{className:ts.layout,style:ae?null:{padding:A,paddingTop:(le?0:J)+A,paddingBottom:(M&&!le?K:0)+A},height:.8*U,children:[ae?(0,se.jsx)("div",{className:ts.placeholderGrid,children:(0,o.A)(Array(12).keys()).map(function(){return(0,se.jsx)("div",{className:ts.placeholderItem})})}):null,(0,se.jsxs)(oa.CS.div,{className:ts.headerContainer,style:(t=$e,{transform:t.to(function(e){return"translateY(".concat(-100*e*(1-e),"%)")}),opacity:t.to(function(e){return e>.25?1-e:1})}),children:[(0,se.jsx)(Qa,{emptyClassName:ts.emptyText,children:ie?(0,se.jsx)(_n,(0,i.A)({className:ts.title},d)):(0,se.jsx)("img",{src:"data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%20906.64%20139.48%22%3E%20%20%20%20%3Cpath%20d%3D%22M35.88%2C4.42h35.5l34.66%2C119.78h-28.43l-5.89-23.72H35.55l-6.22%2C23.72H1.4L35.88%2C4.42Zm31.8%2C75.54l-13.63-52.15h-.34l-14.13%2C52.15h28.09Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M123.37%2C122.51c-6.84-3.36-12.17-8.13-15.98-14.3-3.81-6.17-5.78-13.34-5.89-21.53l26.24-4.21c0%2C7.07%2C1.96%2C12.73%2C5.89%2C16.99%2C3.92%2C4.26%2C8.92%2C6.39%2C14.97%2C6.39%2C4.82%2C0%2C8.72-1.29%2C11.69-3.87%2C2.97-2.58%2C4.46-5.89%2C4.46-9.92%2C0-3.37-1.15-6.2-3.45-8.5-2.3-2.3-6.03-4.34-11.19-6.14l-14.64-4.71c-10.66-3.25-18.37-7.68-23.13-13.29-4.77-5.61-7.15-13.01-7.15-22.21%2C0-10.88%2C3.53-19.63%2C10.6-26.24%2C7.07-6.62%2C16.99-9.93%2C29.78-9.93%2C11.89%2C0%2C21.48%2C3.23%2C28.77%2C9.67%2C7.29%2C6.45%2C11.05%2C15.17%2C11.27%2C26.16l-25.57%2C4.88c.11-5.83-1.24-10.51-4.04-14.05-2.8-3.53-6.45-5.3-10.94-5.3-3.93%2C0-7.12%2C1.21-9.59%2C3.62-2.47%2C2.41-3.7%2C5.47-3.7%2C9.17s1.15%2C6.54%2C3.45%2C8.83c2.3%2C2.3%2C6.08%2C4.23%2C11.36%2C5.8l13.96%2C4.71c10.88%2C3.25%2C18.76%2C7.66%2C23.64%2C13.21s7.32%2C12.93%2C7.32%2C22.12c0%2C7.29-1.74%2C13.79-5.22%2C19.51-3.48%2C5.72-8.52%2C10.18-15.14%2C13.38-6.62%2C3.2-14.58%2C4.79-23.89%2C4.79s-17.05-1.68-23.89-5.05Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M213.03%2C28.64h-28.26V4.42h84.96V28.64h-28.26V124.2h-28.43V28.64Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M335.5%2C122.35c-3.59-3.25-5.95-7.63-7.07-13.12l-5.05-21.37c-.79-2.92-2.19-5.3-4.21-7.15s-4.26-2.78-6.73-2.78h-10.09v46.26h-28.26V4.42h46.1c8.86%2C0%2C16.6%2C1.54%2C23.22%2C4.63%2C6.62%2C3.09%2C11.72%2C7.46%2C15.31%2C13.12%2C3.59%2C5.66%2C5.38%2C12.31%2C5.38%2C19.94%2C0%2C7.18-2.08%2C13.6-6.22%2C19.26-4.15%2C5.67-9.76%2C9.51-16.82%2C11.52v.17c2.8%2C1.24%2C4.96%2C3%2C6.48%2C5.3%2C1.51%2C2.3%2C2.66%2C5.13%2C3.45%2C8.5l3.53%2C15.48c.67%2C3.7%2C2.19%2C5.55%2C4.54%2C5.55%2C2.13%2C0%2C4.15-1.29%2C6.06-3.87l6.73%2C13.63c-2.8%2C2.92-6.2%2C5.24-10.18%2C6.98-3.98%2C1.74-8.05%2C2.61-12.2%2C2.61-5.72%2C0-10.38-1.63-13.96-4.88Zm-16.82-64.26c5.05%2C0%2C9.14-1.46%2C12.28-4.37%2C3.14-2.92%2C4.71-6.78%2C4.71-11.61%2C0-5.16-1.54-9.17-4.63-12.03-3.09-2.86-7.21-4.29-12.37-4.29h-16.32V58.08h16.32Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M396.23%2C119.74c-8.52-5.21-15.14-12.62-19.85-22.21-4.71-9.59-7.07-20.66-7.07-33.23s2.36-23.64%2C7.07-33.23c4.71-9.59%2C11.33-16.99%2C19.85-22.21%2C8.52-5.21%2C18.45-7.82%2C29.78-7.82s21.28%2C2.61%2C29.86%2C7.82c8.58%2C5.22%2C15.22%2C12.59%2C19.94%2C22.12%2C4.71%2C9.53%2C7.07%2C20.58%2C7.07%2C33.14s-2.36%2C23.8-7.07%2C33.39c-4.71%2C9.59-11.36%2C16.99-19.94%2C22.21s-18.53%2C7.82-29.86%2C7.82-21.26-2.61-29.78-7.82Zm50.47-27c5.16-7.07%2C7.74-16.54%2C7.74-28.43s-2.58-21.37-7.74-28.43c-5.16-7.07-12.06-10.6-20.69-10.6s-15.51%2C3.53-20.61%2C10.6c-5.1%2C7.07-7.65%2C16.54-7.65%2C28.43s2.55%2C21.37%2C7.65%2C28.43c5.1%2C7.07%2C11.97%2C10.6%2C20.61%2C10.6s15.53-3.53%2C20.69-10.6Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M489.26%2C4.42h28.26V99.97h37.68v24.23h-65.95V4.42Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M580.28%2C119.74c-8.52-5.21-15.14-12.62-19.85-22.21-4.71-9.59-7.07-20.66-7.07-33.23s2.36-23.64%2C7.07-33.23c4.71-9.59%2C11.33-16.99%2C19.85-22.21%2C8.52-5.21%2C18.45-7.82%2C29.78-7.82s21.28%2C2.61%2C29.86%2C7.82c8.58%2C5.22%2C15.22%2C12.59%2C19.94%2C22.12%2C4.71%2C9.53%2C7.07%2C20.58%2C7.07%2C33.14s-2.36%2C23.8-7.07%2C33.39c-4.71%2C9.59-11.36%2C16.99-19.94%2C22.21s-18.53%2C7.82-29.86%2C7.82-21.26-2.61-29.78-7.82Zm50.47-27c5.16-7.07%2C7.74-16.54%2C7.74-28.43s-2.58-21.37-7.74-28.43c-5.16-7.07-12.06-10.6-20.69-10.6s-15.51%2C3.53-20.61%2C10.6c-5.1%2C7.07-7.65%2C16.54-7.65%2C28.43s2.55%2C21.37%2C7.65%2C28.43c5.1%2C7.07%2C11.97%2C10.6%2C20.61%2C10.6s15.53-3.53%2C20.69-10.6Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M693.75%2C119.65c-7.68-5.05-13.6-12.31-17.75-21.79-4.15-9.48-6.22-20.66-6.22-33.56s2.21-24.25%2C6.65-33.73c4.43-9.48%2C10.77-16.77%2C19.01-21.87%2C8.24-5.1%2C17.97-7.65%2C29.19-7.65s21.53%2C3.28%2C29.95%2C9.84c8.41%2C6.56%2C14.19%2C15.56%2C17.33%2C27l-26.58%2C5.72c-1.8-5.72-4.54-10.2-8.24-13.46-3.7-3.25-7.96-4.88-12.79-4.88-8.08%2C0-14.44%2C3.42-19.09%2C10.26-4.66%2C6.84-6.98%2C16.21-6.98%2C28.09s2.63%2C21.84%2C7.91%2C28.85c5.27%2C7.01%2C12.5%2C10.51%2C21.7%2C10.51%2C8.19%2C0%2C14.66-2.49%2C19.43-7.49%2C4.77-4.99%2C7.26-11.92%2C7.49-20.78h-37.18v-18.51h64.26V124.2h-20.86l-1.68-18.67h-.17c-3.93%2C6.73-9.31%2C12.03-16.15%2C15.9-6.84%2C3.87-14.19%2C5.8-22.04%2C5.8-10.43%2C0-19.49-2.52-27.17-7.57Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M789.56%2C4.42h28.26V124.2h-28.26V4.42Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M827.74%2C4.42h68.81V27.13h-41.55v25.57h34.82v20.19h-34.82v28.6h43.24v22.71h-70.49V4.42Z%22%20fill%3D%22%23000f66%22%20stroke%3D%22aqua%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M43.24%2C15.29h35.5l34.66%2C119.78h-28.43l-5.89-23.72H42.91l-6.22%2C23.72H8.76L43.24%2C15.29Zm31.8%2C75.54l-13.63-52.15h-.34l-14.13%2C52.15h28.09Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M130.73%2C133.38c-6.84-3.36-12.17-8.13-15.98-14.3-3.81-6.17-5.78-13.34-5.89-21.53l26.24-4.21c0%2C7.07%2C1.96%2C12.73%2C5.89%2C16.99%2C3.92%2C4.26%2C8.92%2C6.39%2C14.97%2C6.39%2C4.82%2C0%2C8.72-1.29%2C11.69-3.87%2C2.97-2.58%2C4.46-5.89%2C4.46-9.92%2C0-3.37-1.15-6.2-3.45-8.5-2.3-2.3-6.03-4.34-11.19-6.14l-14.64-4.71c-10.66-3.25-18.37-7.68-23.13-13.29-4.77-5.61-7.15-13.01-7.15-22.21%2C0-10.88%2C3.53-19.63%2C10.6-26.24%2C7.07-6.62%2C16.99-9.93%2C29.78-9.93%2C11.89%2C0%2C21.48%2C3.23%2C28.77%2C9.67%2C7.29%2C6.45%2C11.05%2C15.17%2C11.27%2C26.16l-25.57%2C4.88c.11-5.83-1.24-10.51-4.04-14.05-2.8-3.53-6.45-5.3-10.94-5.3-3.93%2C0-7.12%2C1.21-9.59%2C3.62-2.47%2C2.41-3.7%2C5.47-3.7%2C9.17s1.15%2C6.54%2C3.45%2C8.83c2.3%2C2.3%2C6.08%2C4.23%2C11.36%2C5.8l13.96%2C4.71c10.88%2C3.25%2C18.76%2C7.66%2C23.64%2C13.21s7.32%2C12.93%2C7.32%2C22.12c0%2C7.29-1.74%2C13.79-5.22%2C19.51-3.48%2C5.72-8.52%2C10.18-15.14%2C13.38-6.62%2C3.2-14.58%2C4.79-23.89%2C4.79s-17.05-1.68-23.89-5.05Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M220.39%2C39.51h-28.26V15.29h84.96v24.23h-28.26v95.56h-28.43V39.51Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M342.86%2C133.22c-3.59-3.25-5.95-7.63-7.07-13.12l-5.05-21.37c-.79-2.92-2.19-5.3-4.21-7.15s-4.26-2.78-6.73-2.78h-10.09v46.26h-28.26V15.29h46.1c8.86%2C0%2C16.6%2C1.54%2C23.22%2C4.63%2C6.62%2C3.09%2C11.72%2C7.46%2C15.31%2C13.12%2C3.59%2C5.66%2C5.38%2C12.31%2C5.38%2C19.94%2C0%2C7.18-2.08%2C13.6-6.22%2C19.26-4.15%2C5.67-9.76%2C9.51-16.82%2C11.52v.17c2.8%2C1.24%2C4.96%2C3%2C6.48%2C5.3%2C1.51%2C2.3%2C2.66%2C5.13%2C3.45%2C8.5l3.53%2C15.48c.67%2C3.7%2C2.19%2C5.55%2C4.54%2C5.55%2C2.13%2C0%2C4.15-1.29%2C6.06-3.87l6.73%2C13.63c-2.8%2C2.92-6.2%2C5.24-10.18%2C6.98-3.98%2C1.74-8.05%2C2.61-12.2%2C2.61-5.72%2C0-10.38-1.63-13.96-4.88Zm-16.82-64.26c5.05%2C0%2C9.14-1.46%2C12.28-4.37%2C3.14-2.92%2C4.71-6.78%2C4.71-11.61%2C0-5.16-1.54-9.17-4.63-12.03-3.09-2.86-7.21-4.29-12.37-4.29h-16.32v32.3h16.32Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M403.59%2C130.61c-8.52-5.21-15.14-12.62-19.85-22.21-4.71-9.59-7.07-20.66-7.07-33.23s2.36-23.64%2C7.07-33.23c4.71-9.59%2C11.33-16.99%2C19.85-22.21%2C8.52-5.21%2C18.45-7.82%2C29.78-7.82s21.28%2C2.61%2C29.86%2C7.82c8.58%2C5.22%2C15.22%2C12.59%2C19.94%2C22.12%2C4.71%2C9.53%2C7.07%2C20.58%2C7.07%2C33.14s-2.36%2C23.8-7.07%2C33.39c-4.71%2C9.59-11.36%2C16.99-19.94%2C22.21s-18.53%2C7.82-29.86%2C7.82-21.26-2.61-29.78-7.82Zm50.47-27c5.16-7.07%2C7.74-16.54%2C7.74-28.43s-2.58-21.37-7.74-28.43c-5.16-7.07-12.06-10.6-20.69-10.6s-15.51%2C3.53-20.61%2C10.6c-5.1%2C7.07-7.65%2C16.54-7.65%2C28.43s2.55%2C21.37%2C7.65%2C28.43c5.1%2C7.07%2C11.97%2C10.6%2C20.61%2C10.6s15.53-3.53%2C20.69-10.6Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M496.62%2C15.29h28.26V110.84h37.68v24.23h-65.95V15.29Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M587.64%2C130.61c-8.52-5.21-15.14-12.62-19.85-22.21-4.71-9.59-7.07-20.66-7.07-33.23s2.36-23.64%2C7.07-33.23c4.71-9.59%2C11.33-16.99%2C19.85-22.21%2C8.52-5.21%2C18.45-7.82%2C29.78-7.82s21.28%2C2.61%2C29.86%2C7.82c8.58%2C5.22%2C15.22%2C12.59%2C19.94%2C22.12%2C4.71%2C9.53%2C7.07%2C20.58%2C7.07%2C33.14s-2.36%2C23.8-7.07%2C33.39c-4.71%2C9.59-11.36%2C16.99-19.94%2C22.21s-18.53%2C7.82-29.86%2C7.82-21.26-2.61-29.78-7.82Zm50.47-27c5.16-7.07%2C7.74-16.54%2C7.74-28.43s-2.58-21.37-7.74-28.43c-5.16-7.07-12.06-10.6-20.69-10.6s-15.51%2C3.53-20.61%2C10.6c-5.1%2C7.07-7.65%2C16.54-7.65%2C28.43s2.55%2C21.37%2C7.65%2C28.43c5.1%2C7.07%2C11.97%2C10.6%2C20.61%2C10.6s15.53-3.53%2C20.69-10.6Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M701.11%2C130.53c-7.68-5.05-13.6-12.31-17.75-21.79-4.15-9.48-6.22-20.66-6.22-33.56s2.21-24.25%2C6.65-33.73c4.43-9.48%2C10.77-16.77%2C19.01-21.87%2C8.24-5.1%2C17.97-7.65%2C29.19-7.65s21.53%2C3.28%2C29.95%2C9.84c8.41%2C6.56%2C14.19%2C15.56%2C17.33%2C27l-26.58%2C5.72c-1.8-5.72-4.54-10.2-8.24-13.46-3.7-3.25-7.96-4.88-12.79-4.88-8.08%2C0-14.44%2C3.42-19.09%2C10.26-4.66%2C6.84-6.98%2C16.21-6.98%2C28.09s2.63%2C21.84%2C7.91%2C28.85c5.27%2C7.01%2C12.5%2C10.51%2C21.7%2C10.51%2C8.19%2C0%2C14.66-2.49%2C19.43-7.49%2C4.77-4.99%2C7.26-11.92%2C7.49-20.78h-37.18v-18.51h64.26v67.97h-20.86l-1.68-18.67h-.17c-3.93%2C6.73-9.31%2C12.03-16.15%2C15.9-6.84%2C3.87-14.19%2C5.8-22.04%2C5.8-10.43%2C0-19.49-2.52-27.17-7.57Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M796.92%2C15.29h28.26v119.78h-28.26V15.29Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%20%20%20%20%3Cpath%20d%3D%22M835.1%2C15.29h68.81v22.71h-41.55v25.57h34.82v20.19h-34.82v28.6h43.24v22.71h-70.49V15.29Z%22%20fill%3D%22aqua%22%20stroke%3D%22%23000f66%22%20stroke-miterlimit%3D%2210%22%20stroke-width%3D%222.1%22%2F%3E%3C%2Fsvg%3E",alt:"",className:ts.titleImage})}),(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"EQdIAR",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:ts.emptyText,isEmpty:!oe,children:oe?(0,se.jsx)(nn,(0,i.A)({className:ts.description},m)):null},"description")]}),(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"bv3rRe",defaultMessage:[{type:0,value:"Button"}]}),emptyClassName:ts.emptyText,isEmpty:!re,children:re?(0,se.jsx)(zn,(0,i.A)((0,i.A)({className:ts.button,type:"button",onClick:je,withoutBootstrapStyles:!0,focusable:M&&!le&&!ae},f),{},{children:(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:ts.buttonLabel},f),{},{inline:!0}))})):null}),te&&!ae?(0,se.jsx)(oa.CS.div,{className:ts.header,style:{opacity:$e,pointerEvents:$e.to(function(e){return e<.25?"none":"auto"})},children:(0,se.jsx)("div",{className:ts.buttons,children:(0,se.jsx)(zn,{className:ts.close,onClick:Me,label:I.formatMessage({id:"dj/p/q",defaultMessage:[{type:0,value:"Close"}]}),iconPosition:"right",icon:(0,se.jsx)("svg",{className:ts.closeIcon,xmlns:"http://www.w3.org/2000/svg",width:"10",height:"16",viewBox:"0 0 10 16",fill:"currentColor",children:(0,se.jsx)("polygon",{points:"9.95 4.11 8.89 3.05 5 6.94 1.11 3.05 0.05 4.11 3.94 8 0.05 11.89 1.11 12.95 5 9.06 8.89 12.95 9.95 11.89 6.06 8 9.95 4.11"})}),focusable:!le&&!ae&&(ve||Ae),withoutStyle:!0})})}):null,ae?null:(0,se.jsxs)(oa.CS.div,(0,i.A)((0,i.A)({className:ts.signsGridContainer,style:function(e){return{opacity:e,pointerEvents:e.to(function(e){return e<.25?"none":"auto"})}}($e)},ze()),{},{children:[(0,se.jsx)(Ui,{columns:3,spacing:5,withoutCloseButton:!0,items:_.map(function(e){var t=(e||{}).id,l=void 0===t?null:t;return(0,se.jsx)(oa.CS.div,{className:ts.sign,style:Ee($e),children:(0,se.jsx)(Jr,{sign:e,focusable:!le&&!ae&&ve&&!Ae,onClick:function(e){return Ne(e,l)}},l)},l)})}),(0,se.jsx)(Qa,{emptyLabel:(0,se.jsx)(Wl.A,{id:"xYqGzM",defaultMessage:[{type:0,value:"Author"}]}),emptyClassName:ts.emptyText,isEmpty:!q,children:q&&!ae?(0,se.jsx)(vr,{author:g,className:ts.author,collaboratorClassName:ts.collaborator,backgroundClassName:ts.authorBackground,shouldLoad:de,style:function(e){return{transform:e.to(function(e){return"translateY(".concat(2*(1-e),"rem)")}),opacity:e}}($e)}):null},"author")]})),(0,se.jsx)(oa.CS.div,(0,i.A)((0,i.A)({className:ts.modal,style:function(e){return{transform:e.to(function(e){return"translateY(".concat(100*(1-(e<.2?.1*e+e:e)),"%)")}),pointerEvents:e.to(function(e){return e<.1?"none":"auto"})}}(Be)},Pe()),{},{children:(0,se.jsx)(es,{width:Y,height:U,sign:_[fe],subtitle:b,focusable:!le&&!ae&&Ae,onClick:Fe})})),ae?null:(0,se.jsx)(oa.CS.div,{className:ts.backdrop,style:function(e){return{opacity:e}}($e),children:null!==ke?(0,se.jsx)("video",{className:ts.videoBackdrop,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,children:(0,se.jsx)("source",{src:ke,type:"video/mp4"})}):null})]})}),ae?null:(0,se.jsx)(pn,{background:C,width:Y,height:U,resolution:Q,playing:ue,muted:D,shouldLoad:de,mediaRef:H,className:ts.background})]}))},states:[{id:"intro",label:(0,ue.zR)({id:"82g1F5",defaultMessage:[{type:0,value:"Intro"}]}),fields:[{name:"title",type:"heading-element",label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"Y7bs1v",defaultMessage:[{type:0,value:"Description"}]})},{name:"button",type:"button-element",label:(0,ue.zR)({id:"i6bmbD",defaultMessage:[{type:0,value:"Button"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})}]},{id:"grid",label:(0,ue.zR)({id:"xj0o1v",defaultMessage:[{type:0,value:"Grid"}]}),fields:[{name:"popupBackground",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"author",type:"author-element",label:(0,ue.zR)({id:"73hxYw",defaultMessage:[{type:0,value:"Author"}]})}]},{id:"signs",label:(0,ue.zR)({id:"ap68Fp",defaultMessage:[{type:0,value:"Signs"}]}),defaultValue:Qr,repeatable:!0,withoutCreate:!0,fieldName:"signs",fields:[{name:"word",type:"heading-element",label:(0,ue.zR)({id:"fLdjGi",defaultMessage:[{type:0,value:"Word of the week"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"ZCe0r4",defaultMessage:[{type:0,value:"Description"}]})}]}],fields:[{name:"signSubtitle",type:"heading-element",defaultValue:{body:"Le mot de la semaine"},label:(0,ue.zR)({id:"Qe03Xz",defaultMessage:[{type:0,value:"Sign Subtitle"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})}]}],is={container:"micromag-screen-urbania-recommendation-container",background:"micromag-screen-urbania-recommendation-background",backgroundTextContainer:"micromag-screen-urbania-recommendation-backgroundTextContainer",backgroundText:"micromag-screen-urbania-recommendation-backgroundText",hidden:"micromag-screen-urbania-recommendation-hidden",didAnimate:"micromag-screen-urbania-recommendation-didAnimate",animateFromBottom:"micromag-screen-urbania-recommendation-animateFromBottom",animateFromTop:"micromag-screen-urbania-recommendation-animateFromTop",content:"micromag-screen-urbania-recommendation-content",scroll:"micromag-screen-urbania-recommendation-scroll",empty:"micromag-screen-urbania-recommendation-empty",emptyText:"micromag-screen-urbania-recommendation-emptyText",emptyVisual:"micromag-screen-urbania-recommendation-emptyVisual",emptyCategory:"micromag-screen-urbania-recommendation-emptyCategory",footer:"micromag-screen-urbania-recommendation-footer",disabled:"micromag-screen-urbania-recommendation-disabled",close:"micromag-screen-urbania-recommendation-close",closeIcon:"micromag-screen-urbania-recommendation-closeIcon",textCard:"micromag-screen-urbania-recommendation-textCard",isPlaceholder:"micromag-screen-urbania-recommendation-isPlaceholder",appear:"micromag-screen-urbania-recommendation-appear",visualContainer:"micromag-screen-urbania-recommendation-visualContainer",visualBottom:"micromag-screen-urbania-recommendation-visualBottom",modalOpened:"micromag-screen-urbania-recommendation-modalOpened",sponsor:"micromag-screen-urbania-recommendation-sponsor",hasVisual:"micromag-screen-urbania-recommendation-hasVisual",sponsorPlaceholder:"micromag-screen-urbania-recommendation-sponsorPlaceholder",visualWrapper:"micromag-screen-urbania-recommendation-visualWrapper",visualButton:"micromag-screen-urbania-recommendation-visualButton",transitioning:"micromag-screen-urbania-recommendation-transitioning",iconContainer:"micromag-screen-urbania-recommendation-iconContainer",icon:"micromag-screen-urbania-recommendation-icon",text:"micromag-screen-urbania-recommendation-text",categoryContainer:"micromag-screen-urbania-recommendation-categoryContainer",category:"micromag-screen-urbania-recommendation-category",categoryPlaceholder:"micromag-screen-urbania-recommendation-categoryPlaceholder",textContent:"micromag-screen-urbania-recommendation-textContent",withoutCategory:"micromag-screen-urbania-recommendation-withoutCategory",title:"micromag-screen-urbania-recommendation-title",description:"micromag-screen-urbania-recommendation-description",location:"micromag-screen-urbania-recommendation-location",date:"micromag-screen-urbania-recommendation-date",titleContainer:"micromag-screen-urbania-recommendation-titleContainer",border:"micromag-screen-urbania-recommendation-border",descriptionPlaceholder:"micromag-screen-urbania-recommendation-descriptionPlaceholder",layout:"micromag-screen-urbania-recommendation-layout"},os=[{id:"urbania-recommendation",type:"screen",namespaces:["urbania","bayard"],group:{label:(0,ue.zR)({id:"oPjl8f",defaultMessage:[{type:0,value:"Urbania"}]}),order:10},title:(0,ue.zR)({id:"sUP5BO",defaultMessage:[{type:0,value:"Urbania recommendation"}]}),component:function(e){var t=e.layout,l=void 0===t?null:t,n=e.category,o=void 0===n?null:n,r=e.visual,s=void 0===r?null:r,u=e.title,d=void 0===u?null:u,c=e.date,m=void 0===c?null:c,v=e.location,g=void 0===v?null:v,y=e.description,f=void 0===y?null:y,p=e.sponsor,b=void 0===p?null:p,x=e.spacing,A=void 0===x?20:x,S=e.header,C=void 0===S?null:S,w=e.footer,k=void 0===w?null:w,j=e.background,M=void 0===j?null:j,N=e.cardBoxStyle,F=void 0===N?null:N,T=e.lineColor,z=void 0===T?null:T,$=e.withoutZoom,L=void 0!==$&&$,I=e.current,P=void 0===I||I,B=e.active,E=void 0===B||B,V=e.preload,D=void 0===V||V,O=e.className,H=void 0===O?null:O,Z=(0,Zl.A)(),W=$l(),q=It(),_=q.width,G=q.height,Y=q.resolution,U=Ot(),Q=U.topHeight,X=U.bottomHeight,J=U.bottomSidesWidth,K=qt().open,ee=jt(),te=ee.playing,le=ee.setPlaying,ae=ee.muted,ne=ee.setMuted,ie=Mt(P,!0),oe=ie.ref,re=ie.isCurrent,ue=void 0!==re&&re,de=Wt(),ce=de.enableInteraction,me=de.disableInteraction,ve=Rt(),ge=ve.isView,ye=ve.isPreview,he=ve.isPlaceholder,fe=ve.isEdit,pe=ve.isStatic,be=P&&!he&&!pe&&!ye&&!fe,xe=(0,a.useState)(be),Ae=(0,R.A)(xe,2),Se=Ae[0],Ce=Ae[1],we=(0,a.useState)(!1),je=(0,R.A)(we,2),Me=je[0],Ne=je[1],Fe=(s||{}).image,Te=void 0===Fe?null:Fe,Re=Te||{},$e=Re.type,Le=void 0===$e?null:$e,Ie=Re.metadata,Pe=(void 0===Ie?null:Ie)||{},Be=Pe.width,Ee=void 0===Be?0:Be,De=Pe.height,Oe=null!==Te,Ze="video"===Le,We=Oe&&Ze&&Ee>(void 0===De?0:De),qe=Je(o),_e=Je(d),Ue=Je(m),Qe=Je(g),Xe=Je(f),Ke=Je(b),et=qe||_e||Ue||Qe||Xe||Ke,tt=P&&(ge||fe)&&(ue||!ge),lt=P&&(ge||fe)&&te&&(ue||!ge),at=P||D,nt=!ge&&!fe||!P,it=Ge(C),ot=Ye(k),rt=ze(k,{isView:ge,current:P,openWebView:K,isPreview:ye}),st=(0,a.useState)(!1),ut=(0,R.A)(st,2),dt=ut[0],ct=ut[1],mt=fl(),vt=mt.ref,gt=mt.entry.contentRect,yt=(void 0===gt?null:gt)||{},ht=yt.width,ft=void 0===ht?0:ht,pt=yt.height,bt=void 0===pt?0:pt,xt=(0,a.useState)(!1),At=(0,R.A)(xt,2),St=At[0],Ct=At[1],wt=(0,a.useState)(!1),kt=(0,R.A)(wt,2),Nt=kt[0],Ft=kt[1],Tt=!St&&!Nt,zt=(M||{}).text,$t=void 0===zt?null:zt,Lt=$t||{},Pt=Lt.body,Bt=void 0===Pt?null:Pt,Et=Lt.textStyle,Vt=(0,a.useMemo)(function(){return(function(e){var t=null!==e?e.split(" "):[];if(t.length<2)return Array(4).fill(e);var l=Math.ceil(t.length/2),a=t.slice(0,l).join(" "),n=t.slice(l).join(" ");return[a,n,a,n]}(Bt)||[]).map(function(e){return(0,se.jsx)("span",{children:e})})},[Bt]);(0,a.useEffect)(function(){var e=null;return Se&&(e=setTimeout(function(){Ce(!1),Ne(!0)},1600)),function(){clearTimeout(e)}},[Se,be,Ne,Ce]),(0,a.useEffect)(function(){Ce(!(!ge||pe||!P))},[ge,P,Ce]);var Dt=(0,a.useCallback)(function(e){e.initial&&W("scroll","Screen"),ct(!0)},[W]),Ht=(0,a.useCallback)(function(){ct(!1)},[ct]),Zt=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e){var t=Math.round(100*e);W("scroll",t,{scrollPercent:t})}},[W]);(0,a.useEffect)(function(){var e=null;return St&&(e=setTimeout(function(){Ct(!1),Ft(!0)},400)),P||Ft(!1),function(){clearTimeout(e)}},[St,Ct,P]);var _t=(0,a.useCallback)(function(){Nt||Ct(!0),ae&&Ze&&ne(!1)},[Ft]),Gt=(0,a.useCallback)(function(){St&&Ct(!1),Ft(!1)},[Ft]);(0,a.useEffect)(function(){Nt?me():ce()},[P,Nt]),(0,a.useEffect)(function(){var e=function(e){"Escape"===e.key&&Nt&&Gt()};return document.addEventListener("keyup",e),function(){document.removeEventListener("keyup",e)}},[Nt,Gt]),(0,a.useEffect)(function(){P&&!Se&&le(!0)},[P,Se]);var Yt=(0,a.useMemo)(function(){var e=(d||{}).textStyle,t=void 0===e?null:e,l=t||{},a=l.color,n=void 0===a?null:a,r=l.fontFamily,s=void 0===r?null:r,u=l.fontStyle,c=void 0===u?null:u,v=ke(n),y=null===s?700:null,h=null===s?"uppercase":null,p=null===s?(0,i.A)((0,i.A)({},c),{},{transform:"uppercase"}):c,x=(o||{}).textStyle,A=void 0===x?null:x,S=A||{},C=S.fontFamily,w=void 0===C?null:C,k=S.fontStyle,j=void 0===k?null:k,M=null===w?900:null,N=null===w?(0,i.A)((0,i.A)({},j),{},{transform:"uppercase"}):j,F=(f||{}).textStyle,T=void 0===F?null:F,R=(T||{}).fontFamily,z=null===(void 0===R?null:R)?300:null,$=(m||{}).textStyle,L=void 0===$?null:$,I=L||{},P=I.fontFamily,B=void 0===P?null:P,E=I.fontStyle,V=void 0===E?null:E,D=null===B?(0,i.A)((0,i.A)({},V),{},{transform:"uppercase"}):V,O=(g||{}).textStyle,H=void 0===O?null:O,Z=H||{},W=Z.fontFamily,q=void 0===W?null:W,_=Z.fontStyle,G=void 0===_?null:_,Y=null===q?(0,i.A)((0,i.A)({},G),{},{transform:"uppercase"}):G,U=(b||{}).textStyle,Q=void 0===U?null:U,X=Q||{},J=X.fontFamily,K=void 0===J?null:J,ee=X.fontStyle,te=void 0===ee?null:ee,le=null===K?(0,i.A)((0,i.A)({},te),{},{transform:"uppercase"}):te,ae=Et||{},ne=ae.fontFamily,ie=void 0===ne?null:ne,oe=ae.fontStyle,re=void 0===oe?null:oe;return{defaultTextTransform:h,titleColor:v,titleTextStyle:t,titleFontWeight:y,titleFontStyle:p,categoryTextStyle:A,categoryFontWeight:M,categoryFontStyle:N,descriptionTextStyle:T,descriptionFontWeight:z,dateTextStyle:L,dateFontStyle:D,locationTextStyle:H,locationFontStyle:Y,sponsorTextStyle:Q,sponsorFontStyle:le,backgroundFontStyle:null===ie?(0,i.A)((0,i.A)({},re),{},{transform:"uppercase"}):re}},[d,o,f,m,g,b,Et]),Ut=Yt.titleTextStyle,Qt=Yt.titleColor,Xt=Yt.titleFontWeight,Kt=Yt.titleFontStyle,el=Yt.categoryTextStyle,tl=Yt.categoryFontWeight,ll=Yt.categoryFontStyle,al=Yt.descriptionTextStyle,nl=Yt.descriptionFontWeight,il=Yt.dateTextStyle,ol=Yt.dateFontStyle,rl=Yt.locationTextStyle,sl=Yt.locationFontStyle,ul=Yt.sponsorTextStyle,dl=Yt.sponsorFontStyle,cl=Yt.backgroundFontStyle,ml=he?null:Ve(F),vl=(ml||{}).borderRadius,gl=void 0===vl?null:vl,yl=0===gl,hl=(0,a.useMemo)(function(){return null!==z?ke(z):Qt},[z,Qt]);return(0,se.jsxs)("div",{className:Jt([is.container,H,(0,h.A)({},is.isPlaceholder,he)]),"data-screen-ready":!0,children:[(0,se.jsx)(An,{width:_,height:G,className:is.content,children:(0,se.jsx)(ei,{width:_,height:G,disabled:nt,onScrolledTrigger:Zt,onScrolledBottom:Dt,onScrolledNotBottom:Ht,verticalAlign:"middle",withShadow:!Nt,withArrow:!Nt,className:is.scroll,children:(0,se.jsxs)(Qn,{className:is.layout,width:_,style:he?null:{padding:A,paddingTop:(ye?0:Q)+A/2,paddingBottom:(P&&!ye?X:0)+A/2,minHeight:G},children:[!he&&it?(0,se.jsx)("div",{style:{paddingBottom:A},className:Jt([is.headerContainer]),children:(0,se.jsx)(Zn,(0,i.A)({},C))},"header"):null,he?null:(0,se.jsx)(Un,{},"spacer-cta-top"),Nt?(0,se.jsx)(zn,{className:is.close,onClick:Gt,children:(0,se.jsx)(Sa,{className:is.closeIcon})}):null,et||he||fe?(0,se.jsxs)(An,{className:Jt([is.textCard,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},is.isPlaceholder,he),is.visualBottom,"bottom"===l),is.appear,Se),is.modalOpened,St||Nt),is.hidden,!P&&ge&&!ye)]),style:(0,i.A)((0,i.A)({},ml),yl?{borderRadius:0}:null),children:[(0,se.jsxs)("div",{className:Jt([is.visualContainer,(0,h.A)({},is.modalOpened,St||Nt)]),style:null!==gl?"bottom"===l?{borderBottomLeftRadius:gl,borderBottomRightRadius:gl}:{borderTopLeftRadius:gl,borderTopRightRadius:gl}:null,children:[(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(La,{className:is.visualPlaceholder}),emptyLabel:(0,se.jsx)(Wl.A,{id:"JzSBzL",defaultMessage:[{type:0,value:"Visual"}]}),emptyClassName:Jt([is.empty,is.emptyVisual]),isEmpty:!Oe,children:Oe?(0,se.jsx)("div",{className:Jt([is.visualWrapper,(0,h.A)({},is.modalOpened,St||Nt)]),style:St||Nt?{width:_,height:G}:{width:ft,height:"auto"},children:(0,se.jsxs)(zn,{className:Jt([is.visualButton,(0,h.A)((0,h.A)({},is.transitioning,St),is.disabled,L)]),onClick:_t,disabled:ye||Se||Nt||L,focusable:P&&!ye&&!Nt,"aria-label":Z.formatMessage({id:"XHO5Ua",defaultMessage:[{type:0,value:"Expand visual"}]}),"aria-pressed":Nt,style:{transform:St?"scale(".concat(_/ft,")"):null},children:[Ze?(0,se.jsx)(Nn,{media:Te,mediaRef:oe,width:St||Nt?_:.9*(_-40)+1,height:St||Nt?G:250,resolution:Y,objectFit:{fit:(St||Nt)&&We?"contain":"cover"},shouldLoad:at,muted:ae||!Nt,withoutVideo:ye,playing:lt}):(0,se.jsx)(Nn,{media:Te,width:Nt?_:ft,resolution:Y,active:E,shouldLoad:at}),Tt?(0,se.jsx)("div",{className:Jt([is.iconContainer,(0,h.A)((0,h.A)({},is.visualBottom,"bottom"===l),is.hidden,L)]),children:Ze?(0,se.jsx)(ha,{color:"#000",className:is.icon}):(0,se.jsx)(ya,{color:"#000",className:is.icon})}):null]})}):null},"visual"),(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Ea,{className:is.sponsorPlaceholder}),children:Ke?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:Jt([is.sponsor,(0,h.A)({},is.hasVisual,Oe)])},b),{},{textStyle:(0,i.A)((0,i.A)({},ul),{},{fontStyle:dl})})):null},"sponsor")]}),(0,se.jsxs)("div",{ref:vt,className:is.text,children:[(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Va,{className:is.categoryPlaceholder}),emptyLabel:(0,se.jsx)(Wl.A,{id:"I5+AHN",defaultMessage:[{type:0,value:"Category"}]}),emptyClassName:is.emptyCategory,isEmpty:!qe,children:qe?(0,se.jsx)("div",{className:is.categoryContainer,style:{width:bt},children:(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:is.category},o),{},{textStyle:(0,i.A)((0,i.A)({},el),{},{fontWeight:tl,fontStyle:ll})}))}):null},"category"),(0,se.jsxs)("div",{className:Jt([is.textContent,(0,h.A)((0,h.A)({},is.isPlaceholder,he),is.withoutCategory,!qe)]),children:[(0,se.jsx)(Qa,{placeholder:"title",emptyLabel:(0,se.jsx)(Wl.A,{id:"2c1WFV",defaultMessage:[{type:0,value:"Title"}]}),emptyClassName:is.emptyText,isEmpty:!_e,children:_e?(0,se.jsxs)("div",{className:is.titleContainer,children:[(0,se.jsx)(_n,(0,i.A)((0,i.A)({className:is.title},d),{},{textStyle:(0,i.A)((0,i.A)({},Ut),{},{fontWeight:Xt,fontStyle:Kt})})),(0,se.jsx)("hr",{className:is.border,style:{borderColor:hl}})]}):null},"title"),(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Ea,{className:is.datePlaceholder}),children:Ue?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:is.date},m),{},{textStyle:(0,i.A)((0,i.A)({},il),{},{fontStyle:ol})})),(0,se.jsx)("hr",{className:is.border,style:{borderColor:hl}})]}):null},"date"),(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Ea,{className:is.locationPlaceholder}),children:Qe?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:is.location},g),{},{textStyle:(0,i.A)((0,i.A)({},rl),{},{fontStyle:sl})})),(0,se.jsx)("hr",{className:is.border,style:{borderColor:hl}})]}):null},"location"),(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Ea,{className:is.descriptionPlaceholder}),emptyLabel:(0,se.jsx)(Wl.A,{id:"EQdIAR",defaultMessage:[{type:0,value:"Description"}]}),emptyClassName:is.emptyText,isEmpty:!Xe,children:Xe?(0,se.jsx)(nn,(0,i.A)((0,i.A)({className:is.description},f),{},{textStyle:(0,i.A)((0,i.A)({},al),{},{fontWeight:nl})})):null},"description")]})]})]}):null,he?null:(0,se.jsx)(Un,{},"spacer-cta-bottom"),!he&&ot?(0,se.jsx)("div",{className:Jt([is.footer,(0,h.A)({},is.disabled,!dt&&!Nt)]),style:{paddingTop:A,paddingLeft:Math.max(0,J-A),paddingRight:Math.max(0,J-A)},children:(0,se.jsx)(Dn,(0,i.A)({},rt))},"footer"):null]})})}),he?null:(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)(pn,{background:M,width:_,height:G,resolution:Y,playing:tt&&!Nt,muted:ae||Nt,shouldLoad:at,mediaRef:oe,withoutVideo:ye,className:is.background}),null!==$t&&Vt.length>0?(0,se.jsx)(An,{width:_,height:G,className:is.backgroundTextContainer,children:(Vt||[]).map(function(e,t){return(0,se.jsx)("div",{className:Jt([is.backgroundText],(0,h.A)((0,h.A)((0,h.A)((0,h.A)({},is.hidden,!P&&ge&&!ye),is.didAnimate,Me),is.animateFromBottom,Se&&t%2!=0),is.animateFromTop,Se&&t%2==0)),style:(0,i.A)({animationDelay:"".concat(100*t,"ms")},He((0,i.A)((0,i.A)({},Et),{},{fontStyle:cl}))),children:e},"reco-background-text-".concat(t+1))})}):null]})]})},layouts:["top","bottom"],fields:[{name:"layout",type:"screen-layout",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"sponsor",type:"text-element",label:(0,ue.zR)({id:"WY14Zu",defaultMessage:[{type:0,value:"Sponsor"}]})},{name:"visual",type:"fields",isList:!0,label:(0,ue.zR)({id:"HwqzVR",defaultMessage:[{type:0,value:"Visual"}]}),fields:[{name:"image",type:"visual",label:(0,ue.zR)({id:"xT/onn",defaultMessage:[{type:0,value:"Image"}]})}]},{name:"category",type:"heading-element",label:(0,ue.zR)({id:"4grcMU",defaultMessage:[{type:0,value:"Category"}]})},{name:"title",type:"heading-element",label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"date",type:"text-element",label:(0,ue.zR)({id:"yEG9zh",defaultMessage:[{type:0,value:"Date"}]})},{name:"location",type:"text-element",label:(0,ue.zR)({id:"zLxBdl",defaultMessage:[{type:0,value:"Location"}]})},{name:"description",type:"text-element",label:(0,ue.zR)({id:"Y7bs1v",defaultMessage:[{type:0,value:"Description"}]})},{name:"background",type:"background-recommendation",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{id:"recommendation",type:"fields",isList:!0,label:(0,ue.zR)({id:"hPXJzA",defaultMessage:[{type:0,value:"Box params"}]}),fields:[{name:"cardBoxStyle",type:"box-style-form",label:(0,ue.zR)({id:"1yNxAl",defaultMessage:[{type:0,value:"Card box style"}]})},{name:"lineColor",type:"color",label:(0,ue.zR)({id:"Jti6I6",defaultMessage:[{type:0,value:"Lines color"}]})},{name:"withoutZoom",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"ehuj8A",defaultMessage:[{type:0,value:"Without image zoom"}]})}]},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]}],rs={container:"micromag-screen-urbania-trivia-container",background:"micromag-screen-urbania-trivia-background",content:"micromag-screen-urbania-trivia-content",emptyContainer:"micromag-screen-urbania-trivia-emptyContainer",empty:"micromag-screen-urbania-trivia-empty",itemsContainer:"micromag-screen-urbania-trivia-itemsContainer",videoContainer:"micromag-screen-urbania-trivia-videoContainer",video:"micromag-screen-urbania-trivia-video",isCustomBackground:"micromag-screen-urbania-trivia-isCustomBackground",isAnimated:"micromag-screen-urbania-trivia-isAnimated",heading:"micromag-screen-urbania-trivia-heading",placeholder:"micromag-screen-urbania-trivia-placeholder",videoPlaceholder:"micromag-screen-urbania-trivia-videoPlaceholder",bottomContent:"micromag-screen-urbania-trivia-bottomContent",fullscreen:"micromag-screen-urbania-trivia-fullscreen",image:"micromag-screen-urbania-trivia-image"},ss={image:{type:"image",url:"data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%201083.95%201920%22%3E%20%20%20%20%3Cg%20id%3D%22a%22%2F%3E%20%20%20%20%3Cg%20id%3D%22b%22%3E%20%20%20%20%20%20%20%20%3Cg%20id%3D%22c%22%3E%20%20%20%20%20%20%20%20%20%20%20%20%3Cpath%20d%3D%22M1083.95%2C0h-103.4l-438.55%2C959.95L1083.95%2C109.31V0Zm0%2C295L542.02%2C959.96l541.93-498.87v-166.08Zm0%2C274.99l-541.92%2C389.98%2C541.92-279.64v-110.34Zm0%2C190.53l-541.92%2C199.46%2C541.92-110.89v-88.57Zm0%2C158.17l-541.92%2C41.31%2C541.92%2C41.31v-82.61Zm0%2C152.21l-541.92-110.89%2C541.92%2C199.46v-88.58Zm0%2C168.77l-541.92-279.64%2C541.92%2C389.98v-110.34Zm0%2C219.25l-541.93-498.87%2C541.93%2C664.95v-166.08Zm0%2C351.77L542%2C960.05l438.55%2C959.95h103.4v-109.31ZM854.8%2C0h-138.91l-173.9%2C959.94L854.8%2C0Zm0%2C1920l-312.81-959.94%2C173.9%2C959.94h138.91ZM606.75%2C0h-129.56l64.78%2C959.94L606.75%2C0Zm0%2C1920l-64.78-959.94-64.78%2C959.94h129.56Zm-64.79-960.06L368.06%2C0H229.15l312.81%2C959.94Zm0%2C.12L229.15%2C1920h138.91l173.9-959.94Zm-.01-.11L103.4%2C0H0V109.31L541.94%2C959.95Zm0%2C.11L0%2C1810.69v109.31H103.4l438.55-959.95Zm-.01-.1L0%2C295.01v166.08l541.93%2C498.87Zm0%2C.09L0%2C1458.91v166.08L541.93%2C960.04Zm-.01-.07L0%2C570v110.34l541.92%2C279.63Zm0%2C.02L0%2C760.52v88.57l541.92%2C110.89Zm0%2C.02L0%2C918.69v82.61l541.92-41.31Zm0%2C.02L0%2C1070.9v88.57l541.92-199.46Zm0%2C.02L0%2C1239.66v110.34l541.92-389.97Z%22%20fill%3D%22%2312bbd7%22%2F%3E%20%20%20%20%20%20%20%20%3C%2Fg%3E%20%20%20%20%3C%2Fg%3E%3C%2Fsvg%3E",width:1083,height:1919},color:"#00cbff"},us={image:{type:"image",url:"data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%201083.95%201920%22%3E%20%20%20%20%3Cg%20id%3D%22a%22%2F%3E%20%20%20%20%3Cg%20id%3D%22b%22%3E%20%20%20%20%20%20%20%20%3Cg%20id%3D%22c%22%3E%20%20%20%20%20%20%20%20%20%20%20%20%3Cpath%20d%3D%22M1083.95%2C0h-103.4l-438.55%2C959.95L1083.95%2C109.31V0Zm0%2C295L542.02%2C959.96l541.93-498.87v-166.08Zm0%2C274.99l-541.92%2C389.98%2C541.92-279.64v-110.34Zm0%2C190.53l-541.92%2C199.46%2C541.92-110.89v-88.57Zm0%2C158.17l-541.92%2C41.31%2C541.92%2C41.31v-82.61Zm0%2C152.21l-541.92-110.89%2C541.92%2C199.46v-88.58Zm0%2C168.77l-541.92-279.64%2C541.92%2C389.98v-110.34Zm0%2C219.25l-541.93-498.87%2C541.93%2C664.95v-166.08Zm0%2C351.77L542%2C960.05l438.55%2C959.95h103.4v-109.31ZM854.8%2C0h-138.91l-173.9%2C959.94L854.8%2C0Zm0%2C1920l-312.81-959.94%2C173.9%2C959.94h138.91ZM606.75%2C0h-129.56l64.78%2C959.94L606.75%2C0Zm0%2C1920l-64.78-959.94-64.78%2C959.94h129.56Zm-64.79-960.06L368.06%2C0H229.15l312.81%2C959.94Zm0%2C.12L229.15%2C1920h138.91l173.9-959.94Zm-.01-.11L103.4%2C0H0V109.31L541.94%2C959.95Zm0%2C.11L0%2C1810.69v109.31H103.4l438.55-959.95Zm-.01-.1L0%2C295.01v166.08l541.93%2C498.87Zm0%2C.09L0%2C1458.91v166.08L541.93%2C960.04Zm-.01-.07L0%2C570v110.34l541.92%2C279.63Zm0%2C.02L0%2C760.52v88.57l541.92%2C110.89Zm0%2C.02L0%2C918.69v82.61l541.92-41.31Zm0%2C.02L0%2C1070.9v88.57l541.92-199.46Zm0%2C.02L0%2C1239.66v110.34l541.92-389.97Z%22%20fill%3D%22hsla%280%2C0%25%2C100%25%2C.6%29%22%2F%3E%20%20%20%20%20%20%20%20%3C%2Fg%3E%20%20%20%20%3C%2Fg%3E%3C%2Fsvg%3E",width:1083,height:1919},color:null},ds={id:"urbania-trivia",type:"screen",namespaces:["urbania"],group:{label:(0,ue.zR)({id:"oPjl8f",defaultMessage:[{type:0,value:"Urbania"}]}),order:10},title:(0,ue.zR)({id:"zDdDqI",defaultMessage:[{type:0,value:"Urbania trivia"}]}),component:function(e){var t=e.layout,l=void 0===t?"full":t,n=e.title,o=void 0===n?null:n,r=e.video,s=void 0===r?null:r,u=e.gotoNextScreenOnEnd,d=void 0!==u&&u,c=e.background,m=void 0===c?null:c,v=e.current,g=void 0===v||v,y=e.preload,f=void 0===y||y,p=e.spacing,x=void 0===p?20:p,A=e.padding,S=void 0===A?20:A,C=e.mediaRef,w=void 0===C?null:C,k=e.className,j=void 0===k?null:k,M=Ll("video"),N=It(),F=N.width,T=N.height,z=N.resolution,$=Rt(),L=$.isView,I=$.isPreview,P=$.isPlaceholder,B=$.isEdit,E=$.isStatic,V=$.isCapture,D=Ot().bottomHeight,O=Ht().gotoNextScreen,H=Je(o),Z=g&&(L||B),W=g||f,q=d&&L&&g,_=s||{},G=_.autoPlay,Y=void 0===G||G,U=_.media,Q=void 0===U?null:U,X=_.closedCaptions,J=void 0===X?null:X,K=_.withSeekBar,ee=void 0!==K&&K,te=_.withControls,le=void 0!==te&&te,ae=_.color,ne=void 0===ae?null:ae,ie=_.progressColor,oe=void 0===ie?null:ie,re=jt(),ue=re.playing,de=re.muted,ce=re.setControls,me=re.setControlsTheme,ve=re.setPlaying,ge=re.showControls,ye=re.hideControls,he=re.currentQualityLevel,fe=re.setCurrentQualityLevel,pe=Mt(g),be=pe.ref,xe=pe.isCurrent,Ae=void 0!==xe&&xe;(0,a.useEffect)(function(){return g?(le||ee?(ce(!0),me({seekBarOnly:ee&&!le})):ce(!1),function(){(le||ee)&&ce(!1)}):function(){}},[g,le,ce,ee,ne,oe]),(0,a.useEffect)(function(){null!==w&&w(be.current)},[be.current]);var Se=(0,a.useState)(null),Ce=(0,R.A)(Se,2),we=Ce[0],ke=Ce[1],je=(0,a.useState)(null),Me=(0,R.A)(je,2),Ne=Me[0],Fe=Me[1];(0,a.useEffect)(function(){g&&Y&&!ue&&ve(!0)},[g,Y]);var Te=(0,a.useCallback)(function(e){ke(e)},[Fe,Ne]),Re=(0,a.useCallback)(function(e,t){M(Q,"progress_".concat(Math.round(100*e,10),"%"),t)},[M,Q]),ze=(0,a.useCallback)(function(e){Fe(e)},[Fe]),$e=(0,a.useCallback)(function(e){var t=e.initial;M(Q,t?"play":"resume")},[M,Q]),Le=(0,a.useCallback)(function(e){var t=e.midway;M(Q,t?"pause":"ended")},[M,Q]),Ie=(0,a.useCallback)(function(e){e>0&&M(Q,"seek")},[M,Q]),Pe=(0,a.useCallback)(function(){g&&q&&O(),g&&ve(!1)},[g,q,O,ve]),Be=sl({element:Zt(),disabled:!g||!L,timeout:2e3}).detected;(0,a.useEffect)(function(){g&&(Be?ge():ye())},[Be,ge,ye]);var Ee="full"===l,Ve=m||{},De=Ve.image,Oe=void 0===De?null:De,He=Ve.video,Ze=null===m||null===Oe&&null===(void 0===He?null:He),We=!E&&!I&&Ze,qe=null!==s,_e=(0,a.useState)(qe),Ge=(0,R.A)(_e,2),Ye=Ge[0],Ue=Ge[1],Qe=(0,a.useMemo)(function(){return qe?(0,i.A)((0,i.A)({},s),{},{autoPlay:!I&&!E&&!V&&Y&&g}):null},[qe,s,I,E,V,Y,g]),Xe=Q||{},Ke=Xe.metadata,et=void 0===Ke?null:Ke,tt=Xe.url,lt=void 0===tt?null:tt,at=Xe.thumbnail_url,nt=void 0===at?null:at,it=null!==lt,ot=et||{},rt=ot.width,st=void 0===rt?0:rt,ut=ot.height,dt=void 0===ut?0:ut,ct=pl(),mt=ct.ref,vt=ct.height,gt=T-(void 0===vt?0:vt)-(S?2*S:40),yt=(0,ia.kL)(st,dt,F,gt,{cover:Ee}),ht=yt.width,ft=yt.height,pt=-(ht-F)/2,bt=ft>ht,xt=(0,a.useMemo)(function(){if(b(m)&&m.length>0)return m;var e=m||{},t=e.image,l=void 0===t?null:t,a=e.video,n=void 0===a?null:a,o=e.color,r=void 0===o?null:o;return null!==l||null!==n?(0,i.A)((0,i.A)({},ss),m):(0,i.A)((0,i.A)({},ss),null!==r?{color:r}:null)},[m]),At=Ee?{width:"100%",height:"100%"}:{width:"100%"};(0,a.useEffect)(function(){Ue(!it)},[lt,it,Ue]);var St=(0,a.useCallback)(function(){Ue(!0)},[Ue]);return(0,se.jsxs)("div",{className:Jt([rs.container,j,(0,h.A)({},rs.fullscreen,Ee)]),"data-screen-ready":E||V||Ye,children:[(0,se.jsx)(An,{width:F,height:T,className:rs.content,children:(0,se.jsx)("div",{className:rs.inner,style:bt?{justifyContent:"flex-start",marginTop:2*x}:null,children:(0,se.jsxs)(An,{className:rs.itemsContainer,style:{marginTop:-x/2},children:[(0,se.jsx)(Qa,{className:rs.headingScreenElement,placeholder:(0,se.jsx)(Va,(0,i.A)({className:rs.placeholder},At)),empty:(0,se.jsx)("div",{className:rs.emptyContainer,children:(0,se.jsx)(ka,{className:rs.empty,children:(0,se.jsx)(Wl.A,{id:"oAtOlP",defaultMessage:[{type:0,value:"Heading"}]})})}),isEmpty:!H,children:H?(0,se.jsx)("div",{ref:mt,children:(0,se.jsx)(_n,(0,i.A)({className:rs.heading},o))}):null},"heading"),(0,se.jsx)(Qa,{className:rs.videoScreenElement,placeholder:(0,se.jsx)(Da,(0,i.A)({className:rs.videoPlaceholder},At)),empty:(0,se.jsx)("div",{className:rs.emptyContainer,children:(0,se.jsx)(ka,{className:rs.empty,children:(0,se.jsx)(Wl.A,{id:"3ext9Q",defaultMessage:[{type:0,value:"Video"}]})})}),isEmpty:!it,children:it?(0,se.jsxs)("div",{className:rs.videoContainer,style:{width:Math.min(F,ht),height:ft,left:pt>0?pt:null,maxHeight:gt},children:[I||V?(0,se.jsx)(kn,{className:rs.image,media:{url:nt,metadata:{width:st,height:dt}},width:Math.min(F,ht),height:ft,resolution:z}):(0,se.jsx)(gn,(0,i.A)((0,i.A)({},Qe),{},{mediaRef:be,paused:!g||!ue||!Ae&&L,muted:de,width:ht,height:ft,className:rs.video,onReady:St,onPlay:$e,onPause:Le,onTimeUpdate:Te,onProgressStep:Re,onDurationChange:ze,onSeeked:Ie,onEnded:Pe,focusable:g&&L,shouldLoad:W,qualityStartLevel:he,onQualityLevelChange:fe})),g&&!P?(0,se.jsx)("div",{className:rs.bottomContent,style:{transform:"translate(0, -".concat(D,"px)")},children:null===J||I||V||E?null:(0,se.jsx)(si,{className:rs.closedCaptions,media:J,currentTime:we})},"bottom-content"):null]}):null},"video")]})})}),P?(0,se.jsx)(pn,{background:us,className:rs.background,width:F,height:T,resolution:z,withoutVideo:I}):(0,se.jsx)(pn,{background:xt,className:Jt([rs.background,j,(0,h.A)((0,h.A)({},rs.isCustomBackground,Ze),rs.isAnimated,We)]),width:F,height:T,resolution:z,playing:Z,shouldLoad:W,withoutVideo:I})]})},fields:[{name:"title",type:"heading-element",label:(0,ue.zR)({id:"N25iDO",defaultMessage:[{type:0,value:"Title"}]})},{name:"video",type:"video-element",defaultValue:{autoPlay:!0},label:(0,ue.zR)({id:"tvl2Zc",defaultMessage:[{type:0,value:"Video"}]})},{name:"gotoNextScreenOnEnd",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"n8zmLY",defaultMessage:[{type:0,value:"Go to next screen on end"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})}]},cs={container:"micromag-screen-video-container",content:"micromag-screen-video-content",emptyContainer:"micromag-screen-video-emptyContainer",empty:"micromag-screen-video-empty",inner:"micromag-screen-video-inner",header:"micromag-screen-video-header",bottom:"micromag-screen-video-bottom",placeholder:"micromag-screen-video-placeholder",videoContainer:"micromag-screen-video-videoContainer",fullscreen:"micromag-screen-video-fullscreen",image:"micromag-screen-video-image",video:"micromag-screen-video-video"},ms={id:"video",type:"screen",group:{label:(0,ue.zR)({id:"+9akmg",defaultMessage:[{type:0,value:"Audio and Video"}]}),order:5},title:(0,ue.zR)({id:"UBXIYP",defaultMessage:[{type:0,value:"Video"}]}),component:function(e){var t=e.layout,l=void 0===t?"middle":t,n=e.video,o=void 0===n?null:n,r=e.gotoNextScreenOnEnd,s=void 0!==r&&r,u=e.header,d=void 0===u?null:u,c=e.footer,m=void 0===c?null:c,v=e.background,g=void 0===v?null:v,y=e.current,f=void 0===y||y;e.active;var p=e.preload,b=void 0===p||p,x=e.spacing,A=void 0===x?20:x,S=e.mediaRef,C=void 0===S?null:S,w=e.className,k=void 0===w?null:w,j=Ll("video"),M=It(),N=M.width,F=M.height,T=M.resolution,z=Rt(),$=z.isView,L=z.isPreview,I=z.isPlaceholder,P=z.isEdit,B=z.isStatic,E=z.isCapture,V=Ht().gotoNextScreen,D=Ot(),O=D.topHeight,H=D.bottomHeight,Z=D.bottomSidesWidth,W=qt().open,q=f||b,_=s&&$&&f,G=o||{},Y=G.autoPlay,U=void 0===Y||Y,Q=G.loop,X=void 0!==Q&&Q,J=G.media,K=void 0===J?null:J,ee=G.thumbnail,te=void 0===ee?null:ee,le=G.captions,ae=void 0===le?null:le,ne=G.closedCaptions,ie=void 0===ne?null:ne,oe=G.withSeekBar,re=void 0!==oe&&oe,ue=G.withControls,de=void 0!==ue&&ue,ce=G.color,me=void 0===ce?null:ce,ve=G.progressColor,ge=void 0===ve?null:ve,ye=jt(),he=ye.playing,fe=ye.muted,pe=ye.setControls,be=ye.setControlsSuggestPlay,xe=ye.setControlsTheme,Ae=ye.setPlaying,Se=ye.controlsVisible,Ce=ye.showControls,we=ye.hideControls,ke=ye.currentQualityLevel,je=ye.setCurrentQualityLevel,Me=Mt(f),Ne=Me.ref,Fe=Me.isCurrent,Te=void 0!==Fe&&Fe,Re=(0,a.useState)(!1),$e=(0,R.A)(Re,2),Le=$e[0],Ie=$e[1],Pe=f&&($||P)&&(Te||!$),Be=f&&($||P)&&he&&(Te||!$),Ee=L||E;(0,a.useEffect)(function(){return f?(xe({seekBarOnly:re&&!de,color:me,progressColor:ge}),pe(!(!de&&!re)),function(){(de||re)&&pe(!1)}):function(){}},[f,de,pe,re,me,ge]),(0,a.useEffect)(function(){null!==C&&C(Ne.current)},[Ne.current]),(0,a.useEffect)(function(){f&&U&&Ae(!0)},[f,U]);var Ve=sl({element:Zt(),disabled:!$,timeout:2e3}).detected,De=(0,a.useCallback)(function(){Ve?Ce():we()},[Ve,Ce,we]);ul(De,Ve,1e3);var Oe=(0,a.useState)(null),He=(0,R.A)(Oe,2),Ze=He[0],We=He[1],qe=(0,a.useState)(null),_e=(0,R.A)(qe,2),Ue=_e[0],Qe=_e[1],Xe=(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null!==e&&void 0!==e.currentTarget){var t=(e.currentTarget||{}).currentTime;We(void 0===t?0:t)}else We(0)},[Ue,We]),Je=(0,a.useCallback)(function(e,t){j(K,"progress_".concat(Math.round(100*e,10),"%"),t)},[j,K]),Ke=(0,a.useCallback)(function(e){Qe(e)},[Qe]),et=(0,a.useCallback)(function(e){var t=e.initial;Le||Ie(!0),j(K,t?"play":"resume")},[j,K]),tt=(0,a.useCallback)(function(e){var t=e.midway;j(K,t?"pause":"ended")},[j,K]),lt=(0,a.useCallback)(function(e){e>0&&j(K,"seek",{currentTime:e})},[j,K]),at=(0,a.useCallback)(function(){f&&!X&&Ae(!1),f&&_&&V()},[X,f,_,V]),nt="full"===l,it=Ge(d),ot=Ye(m),rt=ze(m,{isView:$,current:f,openWebView:W,isPreview:L}),st=null!==o,ut=(0,a.useState)(st),dt=(0,R.A)(ut,2),ct=dt[0],mt=dt[1],vt=(0,a.useMemo)(function(){return st?(0,i.A)((0,i.A)({},o),{},{autoPlay:!L&&!B&&!E&&U&&f}):null},[st,o,L,B,E,U,f]),gt=K||{},yt=gt.metadata,ht=void 0===yt?null:yt,ft=gt.url,pt=void 0===ft?null:ft,bt=jl(K,te),xt=null!==pt,At=ht||{},St=At.width,Ct=void 0===St?0:St,wt=At.height,kt=void 0===wt?0:wt,Nt=(0,ia.kL)(Ct,kt,N,F,{cover:nt}),Ft=Nt.width,Tt=Nt.height,zt=-(Ft-N)/2,$t=-(Tt-F)/2,Lt=nt?{width:"100%",height:"100%"}:{width:"100%"};(0,a.useEffect)(function(){mt(!xt)},[pt,xt,mt]);var Pt=(0,a.useCallback)(function(){mt(!0)},[mt]),Bt=(0,a.useCallback)(function(){$&&he&&f&&xt&&U&&(Ae(!1),be(!0))},[$,f,he,xt,U,Ae,be]);return(0,se.jsxs)("div",{className:Jt([cs.container,k,(0,h.A)({},cs.fullscreen,nt)]),"data-screen-ready":B||E||ct,children:[(0,se.jsx)(An,{width:N,height:F,className:cs.content,children:(0,se.jsxs)("div",{className:cs.inner,children:[!I&&it?(0,se.jsx)("div",{className:cs.header,style:{paddingTop:A/2,paddingLeft:A,paddingRight:A,transform:L?null:"translate(0, ".concat(O,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({fade:f&&!Se},d))},"header"):null,(0,se.jsx)(Qa,{placeholder:(0,se.jsx)(Da,(0,i.A)({className:cs.placeholder},Lt)),empty:(0,se.jsx)("div",{className:cs.emptyContainer,children:(0,se.jsx)(ka,{className:cs.empty,children:(0,se.jsx)(Wl.A,{id:"3ext9Q",defaultMessage:[{type:0,value:"Video"}]})})}),isEmpty:!xt,children:xt?(0,se.jsx)("div",{className:cs.videoContainer,style:{width:Ft,height:Tt,left:zt,top:$t},children:Ee?(0,se.jsx)(kn,{className:cs.image,media:bt,width:Ft,height:Tt,objectFit:{fit:"cover"},resolution:T,shouldLoad:q}):(0,se.jsx)(gn,(0,i.A)((0,i.A)({},vt),{},{width:Ft,height:Tt,paused:!Be,muted:fe,mediaRef:Ne,className:cs.video,onReady:Pt,onPlay:et,onPause:tt,onTimeUpdate:Xe,onProgressStep:Je,onDurationChange:Ke,onSeeked:lt,onEnded:at,onPlayError:Bt,disablePictureInPicture:!0,focusable:f&&$,shouldLoad:q,qualityStartLevel:ke,onQualityLevelChange:je}))}):null},"video"),I?null:(0,se.jsxs)("div",{className:cs.bottom,style:{transform:f&&!L?"translate3d(0, -".concat(H,"px, 0)"):null,paddingLeft:Math.max(A/2,Z),paddingRight:Math.max(A/2,Z),paddingBottom:A/2,paddingTop:0},children:[null===ie&&null===ae||L||E||B?null:(0,se.jsx)(si,(0,i.A)((0,i.A)({className:cs.closedCaptions,media:ie},ae),{},{currentTime:Ze})),ot?(0,se.jsx)(Dn,(0,i.A)({},rt)):null]},"bottom-content")]})}),I?null:(0,se.jsx)(pn,{background:g,width:N,height:F,resolution:T,playing:Pe,muted:fe,shouldLoad:q,withoutVideo:L})]})},layouts:["middle","full"],fields:[{name:"layout",type:"screen-layout",defaultValue:"middle",label:(0,ue.zR)({id:"4iBXj2",defaultMessage:[{type:0,value:"Layout"}]})},{name:"video",type:"video-element",theme:{color:"primary"},defaultValue:{autoPlay:!0},label:(0,ue.zR)({id:"tvl2Zc",defaultMessage:[{type:0,value:"Video"}]})},{name:"gotoNextScreenOnEnd",type:"toggle",defaultValue:!1,label:(0,ue.zR)({id:"n8zmLY",defaultMessage:[{type:0,value:"Go to next screen on end"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},vs=null,gs={container:"micromag-screen-video-360-container",background:"micromag-screen-video-360-background",content:"micromag-screen-video-360-content",empty:"micromag-screen-video-360-empty",inner:"micromag-screen-video-360-inner",canvas:"micromag-screen-video-360-canvas",canvasButton:"micromag-screen-video-360-canvasButton",video:"micromag-screen-video-360-video",videoContainer:"micromag-screen-video-360-videoContainer",placeholder:"micromag-screen-video-360-placeholder",header:"micromag-screen-video-360-header",bottom:"micromag-screen-video-360-bottom",showVideo:"micromag-screen-video-360-showVideo"},ys={id:"video-360",type:"screen",group:{label:(0,ue.zR)({id:"+9akmg",defaultMessage:[{type:0,value:"Audio and Video"}]}),order:5},title:(0,ue.zR)({id:"GRVidW",defaultMessage:[{type:0,value:"360 Video"}]}),component:function(e){e.layout;var t=e.video,n=void 0===t?null:t,o=e.header,r=void 0===o?null:o,s=e.footer,u=void 0===s?null:s,d=e.background,c=void 0===d?null:d,m=e.current,v=void 0===m||m,g=e.preload,y=void 0===g||g,f=e.type,p=void 0===f?null:f,b=e.spacing,x=void 0===b?20:b,A=e.mediaRef,S=void 0===A?null:A,C=e.className,w=void 0===C?null:C,k=function(){var e=(0,a.useState)({package:vs}),t=(0,R.A)(e,2),n=t[0].package,i=t[1];return(0,a.useEffect)(function(){var e=!1;return null!==n||l.e(62).then(l.bind(l,5062)).then(function(t){var l=t.Scene,a=t.PerspectiveCamera,n=t.SphereBufferGeometry,o=t.VideoTexture,r=t.MeshBasicMaterial,s=t.Mesh,u=t.WebGLRenderer,d=t.MathUtils;vs={Scene:l,PerspectiveCamera:a,SphereBufferGeometry:n,VideoTexture:o,MeshBasicMaterial:r,Mesh:s,WebGLRenderer:u,MathUtils:d},e||i({package:vs})}),function(){e=!0}},[n,i]),n}(),j=$l(p),M=Ll("video_360"),N=Wt(),F=N.enableInteraction,T=N.disableInteraction,z=Ht(),$=z.gotoPreviousScreen,L=z.gotoNextScreen,I=Ot(),P=I.topHeight,B=I.bottomHeight,E=I.bottomSidesWidth,V=It(),D=V.width,O=V.height,H=V.landscape,Z=V.resolution,W=Rt(),q=W.isView,_=W.isPreview,G=W.isPlaceholder,Y=W.isEdit,U=W.isStatic,Q=W.isCapture,X=qt().open,J=Fl(),K=v&&(q||Y),ee=v||y,te=n||{},le=te.media,ae=void 0===le?null:le,ne=te.closedCaptions,ie=void 0===ne?null:ne,oe=te.captions,re=void 0===oe?null:oe,ue=te.withSeekBar,de=void 0!==ue&&ue,ce=te.withControls,me=void 0!==ce&&ce,ve=te.autoPlay,ge=void 0===ve||ve,ye=te.color,he=void 0===ye?null:ye,fe=te.progressColor,pe=void 0===fe?null:fe,be=(0,a.useRef)(),xe=jt(),Ae=xe.playing,Se=xe.muted,Ce=xe.setControls,we=xe.setControlsTheme,ke=xe.setControlsSuggestPlay,je=xe.setMedia,Me=xe.setPlaying,Ne=xe.showControls,Fe=xe.hideControls,Te=xe.currentQualityLevel,Re=xe.setCurrentQualityLevel,$e=(0,a.useRef)(null);(0,a.useEffect)(function(){return v?(me||de?(Ce(!0),we({seekBarOnly:de&&!me,color:he,progressColor:pe})):Ce(!1),function(){(me||de)&&Ce(!1)}):function(){}},[v,me,Ce,de,he,pe]),(0,a.useEffect)(function(){return v?(je($e.current),function(){je(null)}):function(){}},[v]),(0,a.useEffect)(function(){null!==S&&S($e.current)},[$e.current]),(0,a.useEffect)(function(){v&&ge&&!Ae&&Me(!0)},[v,ge]);var Le=sl({element:Zt(),disabled:!q,timeout:2e3}).detected,Ie=(0,a.useCallback)(function(){Le?Ne():Fe()},[Le,Ne,Fe]);ul(Ie,Le,1e3);var Pe=(0,a.useState)(null),Be=(0,R.A)(Pe,2),Ee=Be[0],Ve=Be[1],De=(0,a.useState)(null),Oe=(0,R.A)(De,2),He=Oe[0],Ze=Oe[1],We=(0,a.useCallback)(function(e){Ve(e)},[Ze,He]),qe=(0,a.useCallback)(function(e,t){M(ae,"progress_".concat(Math.round(100*e,10),"%"),t)},[M,ae]),_e=(0,a.useCallback)(function(e){Ze(e)},[Ze]),Ue=(0,a.useCallback)(function(e){var t=e.initial;M(ae,t?"play":"resume")},[M,ae]),Qe=(0,a.useCallback)(function(e){var t=e.midway;M(ae,t?"pause":"ended")},[M,ae]),Xe=(0,a.useCallback)(function(e){e>0&&M(ae,"seek")},[M,ae]),Je=(0,a.useCallback)(function(){v&&Me(!1)},[v,Me]),Ke=null!==n,et=(0,a.useState)(!Ke),tt=(0,R.A)(et,2),lt=tt[0],at=tt[1],nt=Ge(r),it=Ye(u),ot=ze(u,{isView:q,current:v,openWebView:X,isPreview:_,enableInteraction:F,disableInteraction:T}),rt=Ke?(0,i.A)((0,i.A)({},n),{},{autoPlay:!_&&!U&&!Q&&ge&&v}):null,st=ae||{},ut=st.metadata,dt=void 0===ut?null:ut,ct=st.url,mt=void 0===ct?null:ct,vt=st.thumbnail_url,gt=void 0===vt?null:vt,yt=null!==mt,ht=dt||{},ft=ht.width,pt=void 0===ft?0:ft,bt=ht.height,xt=void 0===bt?0:bt,At=null!==gt,St=(0,a.useState)(!At),Ct=(0,R.A)(St,2),wt=Ct[0],kt=Ct[1],Mt=yt&&(q||Y)&&!Q&&!U,Nt=(0,ia.kL)(pt,xt,D,O,{cover:!0}),Ft=Nt.width,Tt=Nt.height,zt=-(Ft-D)/2,$t=-(Tt-O)/2;(0,a.useEffect)(function(){at(!yt)},[mt,yt,at]),(0,a.useEffect)(function(){kt(!At)},[gt,At,kt]);var Lt=(0,a.useCallback)(function(){at(!0)},[at]),Pt=(0,a.useCallback)(function(){kt(!0)},[wt]),Bt=(0,a.useRef)(null),Et=(0,a.useRef)(null),Vt=(0,a.useRef)(null),Dt=(0,a.useRef)(null),_t=(0,a.useRef)(0),Gt=(0,a.useRef)(0),Yt=(0,a.useRef)(0),Ut=(0,a.useRef)(0),Qt=(0,a.useRef)(50),Xt=(0,a.useRef)(!1),Kt=(0,a.useRef)(0),el=(0,a.useRef)(0),tl=(0,a.useRef)(0),ll=(0,a.useRef)(0),al=(0,a.useCallback)(function(){if(null!==k){var e=k.MathUtils;Gt.current=Math.max(-85,Math.min(85,Gt.current)),Yt.current=e.degToRad(90-Gt.current),Ut.current=e.degToRad(_t.current),Et.current.position.x=Qt.current*Math.sin(Yt.current)*Math.cos(Ut.current),Et.current.position.y=Qt.current*Math.cos(Yt.current),Et.current.position.z=Qt.current*Math.sin(Yt.current)*Math.sin(Ut.current),Et.current.lookAt(0,0,0),Dt.current.render(Vt.current,Et.current)}},[]);(0,a.useEffect)(function(){if(null!==k&&yt&&Mt){var e=k||{},t=e.Scene,l=void 0===t?null:t,a=e.PerspectiveCamera,n=void 0===a?null:a,i=e.SphereBufferGeometry,o=void 0===i?null:i,r=e.VideoTexture,s=void 0===r?null:r,u=e.MeshBasicMaterial,d=void 0===u?null:u,c=e.Mesh,m=void 0===c?null:c,v=e.WebGLRenderer,g=void 0===v?null:v;if(null===l||null===n||null===o||null===s||null===d||null===m||null===g)return function(){Et.current=null,Vt.current=null,Dt.current=null};var y=Bt.current,h=y.offsetWidth,f=y.offsetHeight;Et.current=new n(75,h/f,1,1100),Vt.current=new l;var p=new o(500,60,40);p.scale(-1,1,1);var b=($e||{}).current,x=new m(p,new d({map:new s(void 0===b?null:b)}));Vt.current.add(x),Dt.current=new g({canvas:Bt.current}),Dt.current.setPixelRatio(J),Dt.current.setSize(h,f),al()}return function(){Mt&&(Et.current=null,Vt.current=null,Dt.current=null)}},[yt,Mt,al]),function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).disabled,l=void 0!==t&&t,n=(0,a.useRef)(null),i=(0,a.useRef)(null),o=function(t){i.current||(i.current=t);var l=t-i.current;e(l),n.current=requestAnimationFrame(o)};(0,a.useEffect)(function(){return l||(n.current=requestAnimationFrame(o)),function(){null!==n.current&&cancelAnimationFrame(n.current)}},[l])}(al,{disabled:!Mt}),(0,a.useEffect)(function(){null!==Et.current&&null!==Dt.current&&(Et.current.aspect=D/O,Et.current.updateProjectionMatrix(),Dt.current.setSize(D,O))},[D,O]);var nl=(0,a.useRef)(null),il=(0,a.useCallback)(function(e){Xt.current=!0,Kt.current=e.clientX,el.current=e.clientY,tl.current=_t.current,ll.current=Gt.current},[]),ol=(0,a.useRef)(0),rl=(0,a.useRef)(null),dl=(0,a.useRef)(!1),cl=(0,a.useCallback)(function(e){if(Xt.current){var t=e||{},l=t.clientX,a=void 0===l?null:l,i=t.clientY,o=void 0===i?null:i,r=Kt.current-a,s=el.current-o;_t.current=.2*r+tl.current,Gt.current=.2*s+ll.current;var u=rl.current||{},d=u.x,c=void 0===d?a:d,m=u.y,v=void 0===m?o:m,g=Math.abs(c-a)||0,y=Math.abs(v-o)||0;ol.current+=g+y,!dl.current&&ol.current>Math.min(D,O)&&(j("drag_sphere",n.name),dl.current=!0),rl.current={x:a,y:o},(Math.abs(r)>3||Math.abs(s)>3)&&null!==nl.current&&(clearTimeout(nl.current),nl.current=null)}},[D,O,j,n]),ml=(0,a.useCallback)(function(e){var t=be.current;if(Xt.current&&null!==t){var l=Math.abs(Kt.current-e.clientX),a=Math.abs(el.current-e.clientY);if(!H&&null!==nl.current&&l<3&&a<3){var n=t.getBoundingClientRect(),i=n.left,o=void 0===i?0:i,r=n.width;e.clientX-o<.5*r?null!==$&&$():null!==L&&L()}null!==nl.current&&(clearTimeout(nl.current),nl.current=null)}Xt.current=!1},[$,L,H]),vl=(0,a.useCallback)(function(){q&&Ae&&v&&yt&&ge&&(Me(!1),ke(!0))},[q,v,Ae,yt,ge,Me,ke]);return(0,se.jsxs)("div",{className:Jt([gs.container,w,(0,h.A)({},gs.showVideo,_||U||Q)]),"data-screen-ready":(U||Q)&&wt||lt,children:[(0,se.jsxs)(An,{width:D,height:O,className:gs.content,children:[Mt?(0,se.jsx)("div",{ref:be,className:gs.videoContainer,style:{width:Ft,height:Tt,left:zt,top:$t},children:(0,se.jsx)(gn,(0,i.A)((0,i.A)({},rt),{},{mediaRef:$e,className:gs.video,paused:!v||!Ae,muted:Se,withoutCors:!0,onReady:Lt,onPlay:Ue,onPause:Qe,onTimeUpdate:We,onProgressStep:qe,onDurationChange:_e,onSeeked:Xe,onEnded:Je,onPosterLoaded:Pt,onPlayError:vl,setPlaying:Me,focusable:v&&q,shouldLoad:ee,qualityStartLevel:Te,onQualityLevelChange:Re}))}):null,(0,se.jsxs)("div",{className:gs.inner,children:[(0,se.jsxs)(Qa,{placeholder:(0,se.jsx)(Oa,{className:gs.placeholder,width:"100%",height:"100%"}),emptyClassName:gs.empty,emptyLabel:(0,se.jsx)(Wl.A,{id:"oLtEu6",defaultMessage:[{type:0,value:"Video 360"}]}),isEmpty:!Mt,children:[!G&&nt?(0,se.jsx)("div",{className:gs.header,style:{paddingTop:x/2,paddingLeft:x,paddingRight:x,transform:_?null:"translate(0, ".concat(P,"px)")},children:(0,se.jsx)(Zn,(0,i.A)({},r))},"header"):null,Mt?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("canvas",{ref:Bt,className:gs.canvas}),(0,se.jsx)("button",{className:gs.canvasButton,type:"button","aria-label":"canvas-interaction",onPointerDown:il,onPointerMove:cl,onPointerUp:ml,tabIndex:v&&q?null:"-1"})]}):(0,se.jsx)("div",{className:gs.videoContainer,style:{width:Ft,height:Tt,left:zt,top:$t},children:(0,se.jsx)(kn,{className:gs.video,media:{url:gt,metadata:{width:pt,height:xt}},width:Ft,height:Tt,resolution:Z})})]},"video"),G?null:(0,se.jsxs)("div",{className:gs.bottom,style:{transform:v&&!_?"translate(0, -".concat(B,"px)"):null,paddingLeft:Math.max(x/2,E),paddingRight:Math.max(x/2,E),paddingBottom:x/2,paddingTop:0},children:[null===ie&&null===re||_||Q||U?null:(0,se.jsx)(si,(0,i.A)((0,i.A)({className:gs.closedCaptions,media:ie},re),{},{currentTime:Ee})),it?(0,se.jsx)(Dn,(0,i.A)((0,i.A)({},ot),{},{className:gs.callToAction})):null]},"bottom-content")]})]}),G?null:(0,se.jsx)(pn,{background:c,width:D,height:O,resolution:Z,playing:K,muted:Se,shouldLoad:ee,withoutVideo:_,className:gs.background})]})},layouts:["full"],fields:[{name:"video",type:"video-element",theme:{color:"primary"},defaultValue:{autoPlay:!0},label:(0,ue.zR)({id:"tvl2Zc",defaultMessage:[{type:0,value:"Video"}]})},{name:"background",type:"background",label:(0,ue.zR)({id:"+MPZRu",defaultMessage:[{type:0,value:"Background"}]})},{name:"header",type:"header",label:(0,ue.zR)({id:"rhuDxI",defaultMessage:[{type:0,value:"Header"}]}),theme:{badge:{label:{textStyle:"badge"},boxStyle:"badge"}}},{name:"footer",type:"footer",label:(0,ue.zR)({id:"g4nybp",defaultMessage:[{type:0,value:"Footer"}]}),theme:{callToAction:{label:{textStyle:"cta"},boxStyle:"cta"}}}]},hs=Object.freeze({__proto__:null,article:li,audio:di,contribution:wi,conversation:Fi,gallery:Ei,galleryFeed:Oi,gameSort:Wi,image:Gi,keypad:Ki,map:vo,quiz:Mo,quote:To,ranking:$o,share:Oo,slideshow:Wo,survey:Uo,text:Jo,timeline:lr,title:rr,urbaniaArticle:Sr,urbaniaArticleCard:kr,urbaniaHoroscope:ns,urbaniaRecommendation:os,urbaniaTrivia:ds,video:ms,video360:ys}),fs=new D(Object.keys(hs).reduce(function(e,t){return[].concat((0,o.A)(e),(0,o.A)(b(hs[t])?hs[t]:[hs[t]]))},[]));fs.setFieldsPattern({fonts:{article:[/^title\.textStyle\.fontFamily$/,/^surtitle\.textStyle\.fontFamily$/,/^date\.textStyle\.fontFamily$/,/^author\.name\.textStyle\.fontFamily$/,/^author\.collaborator\.textStyle\.fontFamily$/,/^subtitle\.textStyle\.fontFamily$/,/^text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],audio:[/^audio\.captions\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],contribution:[/^title\.textStyle\.fontFamily$/,/^name\.textStyle\.fontFamily$/,/^message\.textStyle\.fontFamily$/,/^submit\.textStyle\.fontFamily$/,/^nameStyle\.style\.fontFamily$/,/^messageStyle\.style\.fontFamily$/,/^settings\.skipButton\.textStyle\.fontFamily$/,/^settings\.backButton\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],conversation:[/^title\.textStyle\.fontFamily$/,/^conversation\.messageStyle\.fontFamily$/,/^conversation\.speakerStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],gallery:[/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"gallery-captions":[/^images\.[0-9]+\.caption\.textStyle\.fontFamily$/,/^imageCaptionStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"gallery-feed":[/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"gallery-feed-captions":[/^images\.[0-9]+\.caption\.textStyle\.fontFamily$/,/^imageCaptionStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"game-sort":[/^heading\.textStyle\.fontFamily$/,/^items\.[0-9]+\.label\.textStyle\.fontFamily$/,/^items\.[0-9]+\.results\.textStyle\.fontFamily$/,/^itemsTextStyle\.fontFamily$/,/^resultsTextStyle\.fontFamily$/,/^submitTextStyle\.fontFamily$/,/^results\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],image:[/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"image-title":[/^title\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"image-text":[/^text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"image-title-text":[/^title\.textStyle\.fontFamily$/,/^text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"image-legend":[/^legend\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],keypad:[/^items\.[0-9]+\.label\.textStyle\.fontFamily$/,/^buttonStyles\.textStyle\.fontFamily$/,/^popupStyles\.headingTextStyle\.fontFamily$/,/^popupStyles\.contentTextStyle\.fontFamily$/,/^popupStyles\.button\.buttonTextStyle\.fontFamily$/,/^items\.[0-9]+\.heading\.textStyle\.fontFamily$/,/^items\.[0-9]+\.content\.textStyle\.fontFamily$/,/^items\.[0-9]+\.button\.label\.textStyle\.fontFamily$/,/^title\.textStyle\.fontFamily$/,/^subtitle\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],map:[/^title\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^button\.textStyle\.fontFamily$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily$/],"map-images":[/^title\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^button\.textStyle\.fontFamily$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily$/],quiz:[/^question\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.textStyle\.fontFamily$/,/^result\.textStyle\.fontFamily$/,/^buttonsTextStyle\.fontFamily$/,/^inactiveButtonsTextStyle\.fontFamily$/,/^feedbackTextStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"quiz-multiple":[/^title\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^introButton\.textStyle\.fontFamily$/,/^questions\.[0-9]+\.text\.textStyle\.fontFamily$/,/^questions\.[0-9]+\.answers\.[0-9]+\.label\.textStyle\.fontFamily$/,/^results\.[0-9]+\.title\.textStyle\.fontFamily$/,/^results\.[0-9]+\.description\.textStyle\.fontFamily$/,/^buttonsTextStyle\.fontFamily$/,/^inactiveButtonsTextStyle\.fontFamily$/,/^questionsHeadingStyle\.fontFamily$/,/^resultsHeadingStyle\.fontFamily$/,/^resultsTextStyle\.fontFamily$/,/^numbersTextStyle\.fontFamily$/,/^nextButton\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],quote:[/^quote\.textStyle\.fontFamily$/,/^author\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],ranking:[/^title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily$/,/^itemTitleStyle\.fontFamily$/,/^itemDescriptionStyle\.fontFamily$/,/^numbersStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],share:[/^heading\.textStyle\.fontFamily$/,/^buttonsTextStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],slideshow:[/^slides\.[0-9]+\.caption\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],survey:[/^question\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily$/,/^answers\.[0-9]+\.resultStyle\.percentageTextStyle\.fontFamily$/,/^result\.textStyle\.fontFamily$/,/^customAnswer\.placeholder\.textStyle\.fontFamily$/,/^customAnswer\.submit\.textStyle\.fontFamily$/,/^customAnswer\.textStyle\.fontFamily$/,/^buttonsTextStyle\.fontFamily$/,/^resultsStyle\.percentageTextStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],text:[/^text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"text-title":[/^title\.textStyle\.fontFamily$/,/^text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],timeline:[/^title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily$/,/^itemTitleStyle\.fontFamily$/,/^itemDescriptionStyle\.fontFamily$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"timeline-illustrated":[/^title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily$/,/^itemTitleStyle\.fontFamily$/,/^itemDescriptionStyle\.fontFamily$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],title:[/^title\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"title-subtitle":[/^title\.textStyle\.fontFamily$/,/^subtitle\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"title-subtitle-credits":[/^title\.textStyle\.fontFamily$/,/^subtitle\.textStyle\.fontFamily$/,/^credits\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"title-with-box":[/^title\.textStyle\.fontFamily$/,/^subtitle\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"urbania-article":[/^overTitle\.textStyle\.fontFamily$/,/^title\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^author\.name\.textStyle\.fontFamily$/,/^author\.collaborator\.textStyle\.fontFamily$/,/^sponsorLabel\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"urbania-article-card":[/^title\.textStyle\.fontFamily$/,/^author\.name\.textStyle\.fontFamily$/,/^author\.collaborator\.textStyle\.fontFamily$/,/^text\.textStyle\.fontFamily$/,/^cardCallToAction\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/],"urbania-horoscope":[/^title\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^button\.textStyle\.fontFamily$/,/^author\.name\.textStyle\.fontFamily$/,/^author\.collaborator\.textStyle\.fontFamily$/,/^signs\.[0-9]+\.word\.textStyle\.fontFamily$/,/^signs\.[0-9]+\.description\.textStyle\.fontFamily$/,/^signSubtitle\.textStyle\.fontFamily$/],"urbania-recommendation":[/^sponsor\.textStyle\.fontFamily$/,/^category\.textStyle\.fontFamily$/,/^title\.textStyle\.fontFamily$/,/^date\.textStyle\.fontFamily$/,/^location\.textStyle\.fontFamily$/,/^description\.textStyle\.fontFamily$/,/^background\.text\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"urbania-trivia":[/^title\.textStyle\.fontFamily$/,/^video\.captions\.textStyle\.fontFamily$/],video:[/^video\.captions\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/],"video-360":[/^video\.captions\.textStyle\.fontFamily$/,/^header\.badge\.label\.textStyle\.fontFamily$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily$/,/^footer\.callToAction\.label\.textStyle\.fontFamily$/]},medias:{article:[/^image$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^surtitle\.textStyle\.fontFamily\.media$/,/^surtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^date\.textStyle\.fontFamily\.media$/,/^date\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.name\.textStyle\.fontFamily\.media$/,/^author\.name\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.image$/,/^author\.collaborator\.textStyle\.fontFamily\.media$/,/^author\.collaborator\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^subtitle\.textStyle\.fontFamily\.media$/,/^subtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^text$/,/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],audio:[/^audio\.media$/,/^audio\.captions\.textStyle\.fontFamily\.media$/,/^audio\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],contribution:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^name\.textStyle\.fontFamily\.media$/,/^name\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^message\.textStyle\.fontFamily\.media$/,/^message\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^submit\.textStyle\.fontFamily\.media$/,/^submit\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^nameStyle\.style\.fontFamily\.media$/,/^nameStyle\.style\.fontFamily\.variants\.[0-9]+\.media$/,/^messageStyle\.style\.fontFamily\.media$/,/^messageStyle\.style\.fontFamily\.variants\.[0-9]+\.media$/,/^settings\.skipButton\.textStyle\.fontFamily\.media$/,/^settings\.skipButton\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^settings\.backButton\.textStyle\.fontFamily\.media$/,/^settings\.backButton\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],conversation:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^conversation\.speakers\.[0-9]+\.avatar$/,/^conversation\.messages\.[0-9]+\.image$/,/^conversation\.messages\.[0-9]+\.audio$/,/^conversation\.messageStyle\.fontFamily\.media$/,/^conversation\.messageStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^conversation\.speakerStyle\.fontFamily\.media$/,/^conversation\.speakerStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],gallery:[/^images\.[0-9]+$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"gallery-captions":[/^images\.[0-9]+\.media$/,/^images\.[0-9]+\.caption\.textStyle\.fontFamily\.media$/,/^images\.[0-9]+\.caption\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^imageCaptionStyle\.fontFamily\.media$/,/^imageCaptionStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"gallery-feed":[/^images\.[0-9]+$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"gallery-feed-captions":[/^images\.[0-9]+\.media$/,/^images\.[0-9]+\.caption\.textStyle\.fontFamily\.media$/,/^images\.[0-9]+\.caption\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^imageCaptionStyle\.fontFamily\.media$/,/^imageCaptionStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"game-sort":[/^heading\.textStyle\.fontFamily\.media$/,/^heading\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.label\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.visual$/,/^items\.[0-9]+\.results\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.results\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemsTextStyle\.fontFamily\.media$/,/^itemsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^resultsTextStyle\.fontFamily\.media$/,/^resultsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^submitTextStyle\.fontFamily\.media$/,/^submitTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^results\.textStyle\.fontFamily\.media$/,/^results\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],image:[/^image$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"image-title":[/^image$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"image-text":[/^image$/,/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"image-title-text":[/^image$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"image-legend":[/^image$/,/^legend\.textStyle\.fontFamily\.media$/,/^legend\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],keypad:[/^items\.[0-9]+\.label\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.visual$/,/^buttonStyles\.textStyle\.fontFamily\.media$/,/^buttonStyles\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^popupStyles\.headingTextStyle\.fontFamily\.media$/,/^popupStyles\.headingTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^popupStyles\.contentTextStyle\.fontFamily\.media$/,/^popupStyles\.contentTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^popupStyles\.button\.buttonTextStyle\.fontFamily\.media$/,/^popupStyles\.button\.buttonTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.heading\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.heading\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.content\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.content\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.largeVisual$/,/^items\.[0-9]+\.button\.label\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.button\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^subtitle\.textStyle\.fontFamily\.media$/,/^subtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],map:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^button\.textStyle\.fontFamily\.media$/,/^button\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/],"map-images":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^button\.textStyle\.fontFamily\.media$/,/^button\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^markers\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^markers\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/],quiz:[/^question\.textStyle\.fontFamily\.media$/,/^question\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.visual$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.answerImage$/,/^answers\.[0-9]+\.textStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^result\.textStyle\.fontFamily\.media$/,/^result\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^resultImage$/,/^buttonsTextStyle\.fontFamily\.media$/,/^buttonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^inactiveButtonsTextStyle\.fontFamily\.media$/,/^inactiveButtonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^feedbackTextStyle\.fontFamily\.media$/,/^feedbackTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"quiz-multiple":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^introButton\.textStyle\.fontFamily\.media$/,/^introButton\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^introBackground\.image$/,/^introBackground\.video$/,/^questions\.[0-9]+\.text\.textStyle\.fontFamily\.media$/,/^questions\.[0-9]+\.text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^questions\.[0-9]+\.answers\.[0-9]+\.label\.textStyle\.fontFamily\.media$/,/^questions\.[0-9]+\.answers\.[0-9]+\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^questions\.[0-9]+\.answers\.[0-9]+\.visual$/,/^questions\.[0-9]+\.background\.image$/,/^questions\.[0-9]+\.background\.video$/,/^results\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^results\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^results\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^results\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^results\.[0-9]+\.background\.image$/,/^results\.[0-9]+\.background\.video$/,/^buttonsTextStyle\.fontFamily\.media$/,/^buttonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^inactiveButtonsTextStyle\.fontFamily\.media$/,/^inactiveButtonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^questionsHeadingStyle\.fontFamily\.media$/,/^questionsHeadingStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^resultsHeadingStyle\.fontFamily\.media$/,/^resultsHeadingStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^resultsTextStyle\.fontFamily\.media$/,/^resultsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^numbersTextStyle\.fontFamily\.media$/,/^numbersTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^nextButton\.textStyle\.fontFamily\.media$/,/^nextButton\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],quote:[/^quote\.textStyle\.fontFamily\.media$/,/^quote\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.textStyle\.fontFamily\.media$/,/^author\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],ranking:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemTitleStyle\.fontFamily\.media$/,/^itemTitleStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemDescriptionStyle\.fontFamily\.media$/,/^itemDescriptionStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^numbersStyle\.fontFamily\.media$/,/^numbersStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],share:[/^heading\.textStyle\.fontFamily\.media$/,/^heading\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^buttonsTextStyle\.fontFamily\.media$/,/^buttonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],slideshow:[/^slides\.[0-9]+\.media$/,/^slides\.[0-9]+\.caption\.textStyle\.fontFamily\.media$/,/^slides\.[0-9]+\.caption\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],survey:[/^question\.textStyle\.fontFamily\.media$/,/^question\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.result\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^answers\.[0-9]+\.resultStyle\.percentageTextStyle\.fontFamily\.media$/,/^answers\.[0-9]+\.resultStyle\.percentageTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^result\.textStyle\.fontFamily\.media$/,/^result\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^customAnswer\.placeholder\.textStyle\.fontFamily\.media$/,/^customAnswer\.placeholder\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^customAnswer\.submit\.textStyle\.fontFamily\.media$/,/^customAnswer\.submit\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^customAnswer\.textStyle\.fontFamily\.media$/,/^customAnswer\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^buttonsTextStyle\.fontFamily\.media$/,/^buttonsTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^resultsStyle\.percentageTextStyle\.fontFamily\.media$/,/^resultsStyle\.percentageTextStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],text:[/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"text-title":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],timeline:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemTitleStyle\.fontFamily\.media$/,/^itemTitleStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemDescriptionStyle\.fontFamily\.media$/,/^itemDescriptionStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^alternatives\.audio\.media$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily\.media$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"timeline-illustrated":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^items\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^items\.[0-9]+\.image$/,/^itemTitleStyle\.fontFamily\.media$/,/^itemTitleStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^itemDescriptionStyle\.fontFamily\.media$/,/^itemDescriptionStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^alternatives\.audio\.media$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily\.media$/,/^alternatives\.audio\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],title:[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"title-subtitle":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^subtitle\.textStyle\.fontFamily\.media$/,/^subtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"title-subtitle-credits":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^subtitle\.textStyle\.fontFamily\.media$/,/^subtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^credits\.textStyle\.fontFamily\.media$/,/^credits\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"title-with-box":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^subtitle\.textStyle\.fontFamily\.media$/,/^subtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"urbania-article":[/^overTitle\.textStyle\.fontFamily\.media$/,/^overTitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.name\.textStyle\.fontFamily\.media$/,/^author\.name\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.image$/,/^author\.collaborator\.textStyle\.fontFamily\.media$/,/^author\.collaborator\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^sponsorLabel\.textStyle\.fontFamily\.media$/,/^sponsorLabel\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^image$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"urbania-article-card":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.name\.textStyle\.fontFamily\.media$/,/^author\.name\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.image$/,/^author\.collaborator\.textStyle\.fontFamily\.media$/,/^author\.collaborator\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^text\.textStyle\.fontFamily\.media$/,/^text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^cardCallToAction\.textStyle\.fontFamily\.media$/,/^cardCallToAction\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"urbania-horoscope":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^button\.textStyle\.fontFamily\.media$/,/^button\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^popupBackground\.image$/,/^popupBackground\.video$/,/^author\.name\.textStyle\.fontFamily\.media$/,/^author\.name\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^author\.image$/,/^author\.collaborator\.textStyle\.fontFamily\.media$/,/^author\.collaborator\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^signs\.[0-9]+\.word\.textStyle\.fontFamily\.media$/,/^signs\.[0-9]+\.word\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^signs\.[0-9]+\.description\.textStyle\.fontFamily\.media$/,/^signs\.[0-9]+\.description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^signSubtitle\.textStyle\.fontFamily\.media$/,/^signSubtitle\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/],"urbania-recommendation":[/^sponsor\.textStyle\.fontFamily\.media$/,/^sponsor\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^visual\.image$/,/^category\.textStyle\.fontFamily\.media$/,/^category\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^date\.textStyle\.fontFamily\.media$/,/^date\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^location\.textStyle\.fontFamily\.media$/,/^location\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^description\.textStyle\.fontFamily\.media$/,/^description\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^background\.text\.textStyle\.fontFamily\.media$/,/^background\.text\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"urbania-trivia":[/^title\.textStyle\.fontFamily\.media$/,/^title\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^video\.media$/,/^video\.thumbnail$/,/^video\.captions\.textStyle\.fontFamily\.media$/,/^video\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/],video:[/^video\.media$/,/^video\.thumbnail$/,/^video\.captions\.textStyle\.fontFamily\.media$/,/^video\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/],"video-360":[/^video\.media$/,/^video\.thumbnail$/,/^video\.captions\.textStyle\.fontFamily\.media$/,/^video\.captions\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^background\.image$/,/^background\.video$/,/^header\.badge\.label\.textStyle\.fontFamily\.media$/,/^header\.badge\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.media$/,/^header\.shareIncentive\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.media$/,/^footer\.callToAction\.label\.textStyle\.fontFamily\.variants\.[0-9]+\.media$/]}});var ps=["children"];function bs(e){var t=e.children,l=(0,r.A)(e,ps);return(0,se.jsx)(ut,(0,i.A)((0,i.A)({},l),{},{manager:fs,children:t}))}var xs={box:"micromag-element-share-incentive-box",tip:"micromag-element-share-incentive-tip"};function As(e){var t=e.className,l=void 0===t?null:t,a=e.label,n=void 0===a?null:a,o=e.boxStyle,r=void 0===o?null:o,s=(r||{}).backgroundColor,u=ke(void 0===s?null:s);return(0,se.jsx)("div",{className:Jt([xs.container,l]),children:(0,se.jsxs)("div",{className:xs.box,style:(0,i.A)({},Ve(r)),children:[(0,se.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 10 10",className:xs.tip,fill:u,children:(0,se.jsx)("polygon",{points:"0,0 0,10 10,10"})}),(0,se.jsx)(nn,(0,i.A)({className:xs.text},n))]})})}var Ss={container:"micromag-element-webview-container",iframe:"micromag-element-webview-iframe",top:"micromag-element-webview-top",close:"micromag-element-webview-close"};function Cs(e){var t=e.url,l=void 0===t?null:t,a=e.width,n=void 0===a?null:a,i=e.height,o=void 0===i?null:i,r=e.closeable,s=void 0!==r&&r,u=e.focusable,d=void 0!==u&&u,c=e.onClose,m=void 0===c?null:c,v=e.className,g=void 0===v?null:v,y=(0,Zl.A)();return(0,se.jsxs)("div",{className:Jt([Ss.container,g,(0,h.A)((0,h.A)({},Ss.hidden,!d),Ss.closeable,s)]),style:{width:n,height:o},children:[s?(0,se.jsx)("div",{className:Ss.top,children:(0,se.jsx)(zn,{className:Ss.close,"aria-label":y.formatMessage({id:"cXt3NU",defaultMessage:[{type:0,value:"Close Popup"}]}),focusable:d,onClick:m,children:(0,se.jsx)(Sa,{className:Ss.closeIcon})})}):null,(0,se.jsx)("iframe",{className:Ss.iframe,"aria-hidden":d?null:"true",tabIndex:d?"0":"-1",title:y.formatMessage({id:"17zT4Q",defaultMessage:[{type:0,value:"Popup"}]}),src:l||"about:blank",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0})]})}var ws=l(4603);function ks(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).disabled,l=void 0!==t&&t;(0,a.useEffect)(function(){var t=function(t){if(!["input","textarea"].reduce(function(e,l){return e||t.target.matches(l)},!1)){var l=t.key.toLowerCase();void 0!==e[l]&&e[l]()}};return l||window.addEventListener("keydown",t),function(){l||window.removeEventListener("keydown",t)}},[l,e])}function js(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=t||{},n=a.maxParentDistance,i=void 0===n?7:n,o=a.tags,r=void 0===o?["BUTTON","A","INPUT","TEXTAREA"]:o,s=e||{},u=s.tagName,d=void 0===u?null:u,c=s.parentNode,m=void 0===c?null:c;s.dataset;var v=s.classList,g=void 0===v?null:v;return"BODY"!==d&&(!!(-1!==r.filter(function(e){return null!==e}).map(function(e){return e.toLowerCase()}).indexOf(d.toLowerCase())||null!==g&&g.contains("clickable"))||l<i&&js(m,t,l+1))}function Ms(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=(t||{}).maxParentDistance,n=void 0===a?5:a,i=e||{},o=i.tagName,r=void 0===o?null:o,s=i.parentNode,u=void 0===s?null:s,d=i.dataset;return"BODY"!==r&&(void 0!==(void 0===d?{}:d).draggable||l<n&&Ms(u,t,l+1))}var Ns={onTouchMove:function(e){return e.stopPropagation()},onTouchStart:function(e){return e.stopPropagation()},onTouchEnd:function(e){return e.stopPropagation()},onPointerMove:function(e){return e.stopPropagation()},onPointerUp:function(e){return e.stopPropagation()},onPointerDown:function(e){return e.stopPropagation()}},Fs={container:"micromag-viewer-buttons-button-container",icon:"micromag-viewer-buttons-button-icon",label:"micromag-viewer-buttons-button-label",asLink:"micromag-viewer-buttons-button-asLink",withIcon:"micromag-viewer-buttons-button-withIcon",right:"micromag-viewer-buttons-button-right","icon-right":"micromag-viewer-buttons-button-icon-right",withIconColumns:"micromag-viewer-buttons-button-withIconColumns",linkDisabled:"micromag-viewer-buttons-button-linkDisabled"},Ts=["type","theme","size","href","external","direct","target","label","children","focusable","active","icon","iconPosition","disabled","loading","disableOnLoading","withoutTheme","asLink","ariaLabel","onClick","className","iconClassName","labelClassName","refButton"];function Rs(e){var t=e.type,l=void 0===t?"button":t,a=e.theme,n=void 0===a?null:a;e.size;var o=e.href,s=void 0===o?null:o,u=e.external,d=void 0!==u&&u,c=e.direct,m=void 0!==c&&c,g=e.target,y=void 0===g?"_blank":g,f=e.label,p=void 0===f?null:f,b=e.children,x=void 0===b?null:b,A=e.focusable,S=void 0===A||A;e.active;var C=e.icon,w=void 0===C?null:C,k=e.iconPosition,j=void 0===k?"inline":k,M=e.disabled,N=void 0!==M&&M,F=e.loading,T=void 0!==F&&F,R=e.disableOnLoading,z=void 0===R||R;e.withoutTheme;var $=e.asLink,L=void 0!==$&&$,I=e.ariaLabel,P=void 0===I?null:I,B=e.onClick,E=void 0===B?null:B,V=e.className,D=void 0===V?null:V,O=e.iconClassName,H=void 0===O?null:O,Z=e.labelClassName,W=void 0===Z?null:Z,q=e.refButton,_=void 0===q?null:q,G=(0,r.A)(e,Ts),Y=p||x,U=null!==Y?(0,se.jsx)(sa,{children:Y}):null,Q=null!==p&&null!==x,X=null!==w,J=X&&("inline"===j||null===U),K=X&&!J,ee=Jt([Fs.container,Fs["icon-".concat(j)],D,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},Fs.withIcon,X),Fs.withIconColumns,K),Fs.withText,null!==U),Fs.isLink,null!==s),Fs.asLink,L),Fs.isDisabled,N),Fs.isLoading,T)]),te=(n||{}).colors,le=((void 0===te?null:te)||{}).primary,ae=Ee(void 0===le?null:le,"color"),ne=(0,i.A)({},ae),ie=(0,se.jsxs)(se.Fragment,{children:[J?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("span",{className:Jt([Fs.icon,H]),children:w}),null!==U?(0,se.jsx)("span",{className:Jt([Fs.label,W]),children:U}):null]}):null,K?(0,se.jsxs)(se.Fragment,{children:["left"===j?(0,se.jsx)("span",{className:Jt([Fs.icon,Fs.left,(0,h.A)({},H,null!==H&&"left"===j)]),children:w}):null,(0,se.jsx)("span",{className:Jt([Fs.center,Fs.label,W]),children:U}),"right"===j?(0,se.jsx)("span",{className:Jt([Fs.icon,Fs.right,(0,h.A)({},H,null!==H&&"right"===j)]),children:w}):null,Q?x:null]}):null,X?null:U,Q?x:null]});if(null!==s){var oe=Jt([ee,(0,h.A)({disabled:N},Fs.linkDisabled,N)]);return d||m?(0,se.jsx)("a",(0,i.A)((0,i.A)({},G),{},{href:N?null:s,className:oe,style:ne,onClick:E,target:d?y:null,ref:_,tabIndex:S?"":"-1",children:ie})):(0,se.jsx)(v.N_,(0,i.A)((0,i.A)({},G),{},{href:s,className:oe,style:ne,onClick:E,ref:_,tabIndex:S?"":"-1",children:ie}))}return(0,se.jsx)("button",(0,i.A)((0,i.A)({},G),{},{type:l,className:ee,style:ne,onClick:E,disabled:N||z&&T,ref:_,"aria-label":P,tabIndex:S?"0":"-1",children:ie}))}var zs=["iconClassName","className"];function $s(e){var t=e.iconClassName,l=void 0===t?null:t,a=e.className,n=void 0===a?null:a,o=(0,r.A)(e,zs);return(0,se.jsx)(Rs,(0,i.A)({className:Jt(["micromag-viewer-buttons-icon-button-container",n]),labelClassName:"micromag-viewer-buttons-icon-button-label",iconClassName:Jt(["micromag-viewer-buttons-icon-button-icon",l])},o))}var Ls=["single","className"];function Is(e){var t=e.single,l=void 0!==t&&t,a=e.className,n=void 0===a?null:a,o=(0,r.A)(e,Ls),s=(0,Zl.A)();return(0,se.jsx)($s,(0,i.A)({className:Jt([n]),label:s.formatMessage({id:"dIvwcD",defaultMessage:[{type:0,value:"Close"}]}),icon:(0,se.jsxs)("svg",{width:"19",height:"23",viewBox:"0 0 19 23",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[l?null:(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("mask",{id:"path-1-inside-1_560_19911",fill:"currentColor",children:(0,se.jsx)("path",{d:"M0 7C0 4.79086 1.79086 3 4 3H12C14.2091 3 16 4.79086 16 7V19C16 21.2091 14.2091 23 12 23H4C1.79086 23 0 21.2091 0 19V7Z"})}),(0,se.jsx)("path",{d:"M0 3H16H0ZM16 19C16 21.7614 13.7614 24 11 24H4C1.23858 24 -1 21.7614 -1 19H1C1 20.6569 2.34315 22 4 22H12C14.2091 22 16 20.6569 16 19ZM4 24C1.23858 24 -1 21.7614 -1 19V8C-1 5.23858 1.23858 3 4 3C2.34315 3 1 4.79086 1 7V19C1 20.6569 2.34315 22 4 22V24ZM16 3V23V3Z",fill:"currentColor",mask:"url(#path-1-inside-1_560_19911)"})]}),(0,se.jsx)("rect",{x:"3.5",y:"0.5",width:"15",height:"19",rx:"2.5",stroke:"currentColor"}),(0,se.jsx)("path",{d:"M7.35333 6.35333L14.6467 13.6467",stroke:"currentColor",strokeLinejoin:"round"}),(0,se.jsx)("path",{d:"M7.35333 13.6467L14.6467 6.35333",stroke:"currentColor"})]})},o))}var Ps=["className","iconClassName"];function Bs(e){var t=e.className,l=void 0===t?null:t;e.iconClassName;var a=(0,r.A)(e,Ps),n=(0,Zl.A)();return(0,se.jsx)($s,(0,i.A)({className:Jt([l]),label:n.formatMessage({id:"F/gl4b",defaultMessage:[{type:0,value:"Menu"}]}),iconPosition:"right",icon:(0,se.jsxs)("svg",{width:"19",height:"23",viewBox:"0 0 19 23",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,se.jsx)("mask",{id:"path-1-inside-1_572_15622",fill:"currentColor",children:(0,se.jsx)("path",{d:"M0 7C0 4.79086 1.79086 3 4 3H12C14.2091 3 16 4.79086 16 7V19C16 21.2091 14.2091 23 12 23H4C1.79086 23 0 21.2091 0 19V7Z"})}),(0,se.jsx)("path",{d:"M0 3H16H0ZM16 19C16 21.7614 13.7614 24 11 24H4C1.23858 24 -1 21.7614 -1 19H1C1 20.6569 2.34315 22 4 22H12C14.2091 22 16 20.6569 16 19ZM4 24C1.23858 24 -1 21.7614 -1 19V8C-1 5.23858 1.23858 3 4 3C2.34315 3 1 4.79086 1 7V19C1 20.6569 2.34315 22 4 22V24ZM16 3V23V3Z",fill:"currentColor",mask:"url(#path-1-inside-1_572_15622)"}),(0,se.jsx)("rect",{x:"3.5",y:"0.5",width:"15",height:"19",rx:"2.5",stroke:"currentColor"})]})},a))}var Es=["className"];function Vs(e){var t=e.className,l=void 0===t?null:t,a=(0,r.A)(e,Es),n=(0,Zl.A)();return(0,se.jsx)($s,(0,i.A)({className:Jt([l]),label:n.formatMessage({id:"7tw6U2",defaultMessage:[{type:0,value:"Share"}]}),iconPosition:"left",icon:(0,se.jsxs)("svg",{width:"16",height:"22",viewBox:"0 0 16 22",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,se.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7.55806 0.183058C7.80213 -0.0610194 8.19786 -0.0610194 8.44194 0.183058L12.4194 4.16053C12.6635 4.40461 12.6635 4.80034 12.4194 5.04442C12.1753 5.2885 11.7796 5.2885 11.5355 5.04442L8.625 2.13388V11.25H7.375V2.13388L4.46446 5.04442C4.22039 5.2885 3.82466 5.2885 3.58058 5.04442C3.3365 4.80034 3.3365 4.40461 3.58058 4.16053L7.55806 0.183058Z",fill:"currentColor"}),(0,se.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M16 18.25V10.25C16 8.59315 14.6569 7.25 13 7.25C14.1046 7.25 15 8.59315 15 10.25V18.25C15 19.3546 14.1046 20.25 13 20.25H3C1.89543 20.25 1 19.3546 1 18.25V10.25C1 8.59315 1.89543 7.25 3 7.25C1.34315 7.25 0 8.59315 0 10.25V18.25C0 19.9069 1.34315 21.25 3 21.25H13C14.6569 21.25 16 19.9069 16 18.25Z",fill:"currentColor"})]})},a))}function Ds(e){var t=e.className,l=void 0===t?null:t,a=e.progressSpring,n=void 0===a?null:a,i=e.button,o=void 0===i?null:i,r=e.toggledButton,s=void 0===r?null:r,u=e.toggledButtonClassName,d=void 0===u?null:u;return null===o?null:(0,se.jsxs)("div",{className:Jt(["micromag-viewer-buttons-toggle-button-container",l]),children:[(0,se.jsx)(oa.CS.div,{className:"micromag-viewer-buttons-toggle-button-normal",style:{transform:n.to(function(e){return"translateY(".concat(-100*e,"%)")})},children:o}),(0,se.jsx)(oa.CS.div,{className:Jt(["micromag-viewer-buttons-toggle-button-toggled",d]),style:{transform:n.to(function(e){return"translateY(".concat(-100*(e-1),"%)")})},children:s})]})}function Os(e){var t=e.className,l=void 0===t?null:t,a=e.progressSpring,n=void 0===a?null:a,o=e.theme,r=void 0===o?null:o,s=e.children,u=void 0===s?null:s,d=(r||{}).background,c=((void 0===d?null:d)||{}).color,m=Ee(void 0===c?null:c,"backgroundColor");return(0,se.jsxs)("div",{className:Jt(["micromag-viewer-menus-menu-container-container",l]),style:{pointerEvents:"none"},children:[(0,se.jsx)(oa.CS.div,{className:"micromag-viewer-menus-menu-container-heightContainer",style:(0,i.A)({opacity:n,transform:n.to(function(e){return"translateY(".concat(-2*(1-e),"rem)")}),pointerEvents:n.to(function(e){return e<.25?"none":"auto"}),zIndex:n.to(function(e){return Math.round(2+e)})},m),children:u}),(0,se.jsx)(oa.CS.div,{className:"micromag-viewer-menus-menu-container-backdrop",style:{opacity:n.to(function(e){return t=e,1-Math.pow(1-t,5);var t})}})]})}var Hs={container:"micromag-viewer-menus-menu-dot-container",dot:"micromag-viewer-menus-menu-dot-dot",progress:"micromag-viewer-menus-menu-dot-progress",vertical:"micromag-viewer-menus-menu-dot-vertical"};function Zs(e){var t=e.current,l=void 0!==t&&t,n=e.active,o=void 0!==n&&n,r=e.colors,s=void 0===r?null:r,u=e.count,d=void 0===u?1:u,c=e.subIndex,m=void 0===c?0:c,v=e.vertical,g=void 0!==v&&v,y=e.onClick,f=void 0===y?null:y,p=e.className,b=void 0===p?null:p,x=s||{},A=x.primary,S=void 0===A?"rgba(255, 255, 255, 1)":A,C=x.secondary,w=void 0===C?"rgba(255, 255, 255, 0.25)":C,k=(0,Qt.U2)(),j=(0,Qt.zh)(function(){return{ref:k,scaleX:0,config:{tension:200,friction:30}}}),M=(0,R.A)(j,2),N=M[0],F=M[1];return(0,a.useEffect)(function(){var e=d>1&&l?(m+1)/d:o?1:0;F.start({scaleX:e,immediate:!l})},[o,l,m,d,F]),(0,se.jsx)("button",{type:"button",className:Jt([Hs.container,b,(0,h.A)((0,h.A)({},Hs.active,l),Hs.vertical,g)]),onClick:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;null!==e&&e.stopPropagation(),null!==f&&f()},tabIndex:"-1","aria-hidden":"true",children:(0,se.jsx)("div",{className:Hs.dot,style:{backgroundColor:w},children:(0,se.jsx)(oa.CS.div,{className:Hs.progress,style:(0,i.A)((0,i.A)({},N),{},{backgroundColor:S})})})})}var Ws=["direction","items","onClickDot","onClickScreensMenu","colors","closeable","buttons","withItemClick","withoutScreensMenu","onClose","className"],qs=[];function _s(e){var t=e.direction,l=void 0===t?"horizontal":t,a=e.items,n=void 0===a?qs:a,i=e.onClickDot,o=void 0===i?null:i,s=e.onClickScreensMenu,u=void 0===s?null:s,d=e.colors,c=void 0===d?null:d,m=e.closeable,v=void 0!==m&&m,g=e.buttons,y=void 0===g?null:g,f=e.withItemClick,p=void 0!==f&&f,b=e.withoutScreensMenu,x=void 0!==b&&b,A=e.onClose,S=void 0===A?null:A,C=e.className,w=void 0===C?null:C,k=(0,r.A)(e,Ws),j=(c||{}).primary,M=void 0===j?"rgba(255, 255, 255, 1)":j,N=(0,Zl.A)(),F=n.findIndex(function(e){var t=e.current;return void 0!==t&&t}),T=(k||{}).style;return(0,se.jsxs)("nav",{className:Jt(["micromag-viewer-menus-menu-dots-container",(0,h.A)((0,h.A)({},"micromag-viewer-menus-menu-dots-withButtons",v||null!==y),"micromag-viewer-menus-menu-dots-vertical","vertical"===l),w]),"aria-label":N.formatMessage({id:"bLYuuN",defaultMessage:[{type:0,value:"You are on screen "},{type:1,value:"current"},{type:0,value:" of "},{type:1,value:"total"},{type:0,value:"."}]},{current:F+1,total:n.length}),style:T,children:[n.map(function(e,t){var a=e||{},n=a.current,i=void 0!==n&&n,r=a.count,s=void 0===r?1:r,d=a.subIndex,m=void 0===d?0:d;return(0,se.jsx)(Zs,{current:i,active:t<=F,colors:c,count:s,subIndex:m,className:"micromag-viewer-menus-menu-dots-dot",onClick:function(){(p||x)&&null!==o?o(e):p||null===u||u()},vertical:"vertical"===l})}),v?(0,se.jsx)("button",{type:"button",className:"micromag-viewer-menus-menu-dots-closeButton",onClick:S,title:N.formatMessage({id:"dj/p/q",defaultMessage:[{type:0,value:"Close"}]}),"aria-label":N.formatMessage({id:"dj/p/q",defaultMessage:[{type:0,value:"Close"}]}),style:{color:M},children:(0,se.jsx)(ga,{})}):null,null!==y?(0,se.jsx)("div",{className:"micromag-viewer-menus-menu-dots-buttons",children:y}):null]})}function Gs(e){var t=e.color,l=void 0===t?"currentColor":t,a=e.className,n=void 0===a?null:a;return(0,se.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 315.77 56.94",className:n,children:[(0,se.jsx)("path",{fill:l,d:"m34.3.69v55.55h-10.42v-23.82l-4.31,23.82h-4.86l-4.31-23.82v23.82H0V.69h10.42l6.74,32.08L23.89.69h10.42Z"}),(0,se.jsx)("path",{fill:l,d:"m46.8.69v55.55h-10.42V.69h10.42Z"}),(0,se.jsx)("path",{fill:l,d:"m64.57,16.53c0-4.72-.35-6.11-2.64-6.11s-2.64,1.39-2.64,6.11v23.89c0,4.72.35,6.11,2.64,6.11s2.64-1.39,2.64-6.11v-6.74h10.42v7.43c0,11.18-4.65,15.83-13.05,15.83s-13.05-4.65-13.05-15.83V15.83c0-11.18,4.65-15.83,13.05-15.83s13.05,4.65,13.05,15.83v7.43h-10.42v-6.74Z"}),(0,se.jsx)("path",{fill:l,d:"m104.08,56.24h-10.42c-.69-.83-.76-2.85-.76-4.93v-10.69c0-4.03-1.39-4.72-5.42-4.72v20.35h-10.42V.69h10.42c11.87,0,15.83,3.96,15.83,15.14v4.93c0,6.11-1.87,10.07-5.14,12.43,3.54,1.46,5.14,4.31,5.14,9.51v8.61c0,2.08.07,4.1.76,4.93Zm-16.6-45.13v14.37c4.03,0,5.42-.69,5.42-4.72v-4.93c0-4.03-1.39-4.72-5.42-4.72Z"}),(0,se.jsx)("path",{fill:l,d:"m173.63.69v55.55h-10.42v-23.82l-4.31,23.82h-4.86l-4.31-23.82v23.82h-10.42V.69h10.42l6.74,32.08L163.22.69h10.42Z"}),(0,se.jsx)("path",{fill:l,d:"m191.68,46.8h-5.49l-.76,9.44h-10.42L181.82.69h14.23l6.81,55.55h-10.42l-.76-9.44Zm-.83-10.42l-1.87-24.65-1.94,24.65h3.82Z"}),(0,se.jsx)("path",{fill:l,d:"m219.25,23.26v-6.74c0-4.72-.42-6.11-2.64-6.11s-2.64,1.39-2.64,6.11v23.89c0,4.72.35,6.11,2.64,6.11s2.64-1.39,2.64-6.11v-2.57h-2.64v-10.42h13.05v28.82h-4.17l-1.67-3.96c-2.15,2.71-5.07,4.65-8.82,4.65-7.5,0-11.46-4.65-11.46-15.83V15.83c0-11.18,4.65-15.83,13.05-15.83s13.05,4.65,13.05,15.83v7.43h-10.42Z"}),(0,se.jsx)("rect",{fill:l,x:"105.65",y:".69",width:"31.25",height:"55.55",rx:"3",ry:"3"}),(0,se.jsx)("path",{fill:l,d:"m304.96,7.72c-2.02,0-2.55,1.05-2.55,4.29v13.04c0,3.24.52,4.29,2.55,4.29s2.55-1.05,2.55-4.29v-13.04c0-3.24-.52-4.29-2.55-4.29Z"}),(0,se.jsx)("path",{fill:l,d:"m283.9,8.07h-.7v20.93h.7c3.42,0,4.46-.52,4.46-3.94v-13.04c0-3.42-1.05-3.94-4.46-3.94Z"}),(0,se.jsx)("path",{fill:l,d:"m313.68.68h-75.86c-1.15,0-2.08.93-2.08,2.08v31.54c0,1.15.93,2.08,2.08,2.08h75.86c1.15,0,2.08-.93,2.08-2.08V2.76c0-1.15-.93-2.08-2.08-2.08Zm-67,32.15c-4.53,0-6.31-2.34-6.31-9.87h3.49c0,5.34.77,6.38,2.83,6.38,1.64,0,2.27-.84,2.27-3.77s-.98-4.19-3.56-6.21c-2.48-1.92-4.85-3.84-4.85-8.41,0-4.12,1.74-6.73,5.79-6.73s5.93,2.62,5.93,8.48h-3.49c0-4.19-.94-4.99-2.44-4.99s-2.3.8-2.3,3.24,1.22,3.77,3.28,5.34c2.96,2.27,5.13,4.22,5.13,9.28,0,4.6-1.67,7.25-5.75,7.25Zm17.82-24.76h-3.94v24.41h-3.49V8.07h-3.94v-3.49h11.37v3.49Zm13.46,16.99c0,5.62-1.99,7.78-6.03,7.78s-6.03-2.16-6.03-7.78V4.58h3.49v20.47c0,3.24.52,4.29,2.55,4.29s2.55-1.05,2.55-4.29V4.58h3.49v20.47Zm13.88,0c0,6.03-2.34,7.43-7.95,7.43h-4.19V4.58h4.19c5.62,0,7.95,1.33,7.95,7.43v13.04Zm5.33,7.43h-3.49V4.58h3.49v27.9Zm13.81-7.43c0,5.62-1.99,7.78-6.03,7.78s-6.03-2.16-6.03-7.78v-13.04c0-5.62,1.99-7.78,6.03-7.78s6.03,2.16,6.03,7.78v13.04Z"})]})}function Ys(e){var t=e.className,l=void 0===t?null:t;return(0,se.jsx)("div",{className:Jt(["micromag-viewer-partials-micromag-branding-container",l]),children:(0,se.jsxs)("a",{href:"https://micromag.media",target:"_blank",rel:"noopener noreferrer",className:"micromag-viewer-partials-micromag-branding-link",children:[(0,se.jsxs)("span",{className:"micromag-viewer-partials-micromag-branding-text",children:[(0,se.jsx)(Wl.A,{id:"LiMAIC",defaultMessage:[{type:0,value:"This Micromag was"}]}),(0,se.jsx)("br",{}),(0,se.jsx)(Wl.A,{id:"TDAOl2",defaultMessage:[{type:0,value:"created with"}]})]}),(0,se.jsx)(Gs,{className:"micromag-viewer-partials-micromag-branding-icon"})]})})}function Us(e){var t=e.className,l=void 0===t?null:t;return(0,se.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"11.5px",height:"17.5px",viewBox:"0 0 11.5 17.5",className:Jt([l]),children:[(0,se.jsx)("rect",{width:"10",height:"16"}),(0,se.jsx)("polygon",{points:"10.5 1.5 10.5 16.5 1.5 16.5 1.5 17.5 11.5 17.5 11.5 1.5 10.5 1.5"})]})}function Qs(e){var t=e.className,l=void 0===t?null:t,a=e.item,n=void 0===a?null:a,i=e.index,o=void 0===i?0:i,r=e.onClick,s=void 0===r?null:r,u=e.screenSize,d=void 0===u?null:u,c=e.alwaysRender,m=void 0!==c&&c,v=e.focusable,g=void 0===v||v,y=(0,Zl.A)(),f=n||{},p=f.current,b=void 0!==p&&p,x=f.screen,A=f.count,S=void 0===A?1:A,C=d||{},w=C.width,k=C.height,j=bl({rootMargin:"200px",persist:!1}),M=j.ref,N=j.visible,F=void 0!==N&&N,T="".concat(y.formatMessage({id:"LkVfwW",defaultMessage:[{type:0,value:"Screen "},{type:1,value:"index"}]},{index:o+1})).concat(b?" ".concat(y.formatMessage({id:"vmrJ8U",defaultMessage:[{type:0,value:"(current screen)"}]})):"");return(0,se.jsxs)("div",{className:Jt(["micromag-viewer-menus-menu-screen-container",l,(0,h.A)({},"micromag-viewer-menus-menu-screen-isCurrent",b)]),style:{paddingBottom:"".concat(k/w*100,"%")},ref:M,children:[(0,se.jsx)("button",{type:"button",className:"micromag-viewer-menus-menu-screen-button",onClick:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;null!==e&&e.stopPropagation(),null!==s&&s(n)},"aria-label":T,tabIndex:g?"0":"-1"}),(0,se.jsxs)("div",{className:"micromag-viewer-menus-menu-screen-inner",children:[S>1?(0,se.jsxs)("div",{className:"micromag-viewer-menus-menu-screen-subScreenBadge",children:[(0,se.jsx)("span",{className:"micromag-viewer-menus-menu-screen-subScreenCount",children:S}),(0,se.jsx)(Us,{className:"micromag-viewer-menus-menu-screen-subScreenIcon"})]}):null,w>0&&k>0&&(F||m)?(0,se.jsx)(qa,{className:"micromag-viewer-menus-menu-screen-screen",screenWidth:w,screenHeight:k,screen:x,focusable:g,active:g,withSize:!0}):null]})]})}var Xs={container:"micromag-viewer-menus-menu-preview-container",content:"micromag-viewer-menus-menu-preview-content",scroll:"micromag-viewer-menus-menu-preview-scroll",scrollee:"micromag-viewer-menus-menu-preview-scrollee",titleContainer:"micromag-viewer-menus-menu-preview-titleContainer",headerContainer:"micromag-viewer-menus-menu-preview-headerContainer",title:"micromag-viewer-menus-menu-preview-title",nav:"micromag-viewer-menus-menu-preview-nav",items:"micromag-viewer-menus-menu-preview-items",item:"micromag-viewer-menus-menu-preview-item",inner:"micromag-viewer-menus-menu-preview-inner",frame:"micromag-viewer-menus-menu-preview-frame",screen:"micromag-viewer-menus-menu-preview-screen",micromagBrandingSeparator:"micromag-viewer-menus-menu-preview-micromagBrandingSeparator",micromagBrandingContainer:"micromag-viewer-menus-menu-preview-micromagBrandingContainer"},Js=["textAlign"],Ks=[];function eu(e){var t=e.viewerTheme,l=void 0===t?null:t,a=e.header,n=void 0===a?null:a,o=e.footer,s=void 0===o?null:o,u=e.screenSize,d=void 0===u?null:u,c=e.title,m=void 0===c?null:c,v=e.menuWidth,g=void 0===v?null:v,y=e.items,f=void 0===y?Ks:y,p=e.focusable,b=void 0===p||p,x=e.onClickScreen,A=void 0===x?null:x,S=e.maxThumbsWidth,C=void 0===S?140:S,w=e.paddingTop,k=void 0===w?null:w,j=e.scrollDisabled,M=void 0!==j&&j,N=e.withMicromagBranding,F=void 0!==N&&N,T=e.className,R=void 0===T?null:T,z=pl(),$=z.ref,L=z.width,I=void 0===L?0:L,P=Math.max(Math.floor(I/C),3),B=l||{},E=B.background,V=void 0===E?null:E,D=B.textStyles,O=void 0===D?null:D,H=(V||{}).image,Z=((void 0===H?null:H)||{}).url,W=void 0===Z?null:Z,q=null!==W?{backgroundImage:"url(".concat(W,")")}:null,_=(O||{}).title,G=void 0===_?null:_,Y=G||{};Y.textAlign;var U=(0,r.A)(Y,Js),Q=null!==G?He(U):null,X=null!==m,J=k+10;return(0,se.jsx)("div",{className:Jt([Xs.container,R]),style:(0,i.A)((0,i.A)({},q),{},{width:g}),"aria-hidden":b?null:"true",children:(0,se.jsx)("div",{className:Xs.content,ref:$,children:(0,se.jsxs)(ei,{className:Xs.scroll,scrolleeClassName:Xs.scrollee,disabled:M,children:[X&&null===n?(0,se.jsx)("div",{className:Xs.titleContainer,style:{paddingTop:J},children:(0,se.jsx)("h1",{className:Xs.title,style:(0,i.A)({},Q),children:m})}):(0,se.jsx)("div",{className:Xs.headerContainer,style:{paddingTop:J},children:n}),(0,se.jsx)("nav",{className:Xs.nav,style:X?null:{paddingTop:k},children:(0,se.jsx)("ul",{className:Xs.items,children:f.map(function(e,t){var l=(e||{}).screenId,a={width:"".concat(100/P,"%")},n=d||{},i=n.width,o=n.height;return(0,se.jsx)("li",{className:Xs.item,style:a,children:(0,se.jsx)("div",{className:Xs.inner,children:(0,se.jsx)("div",{className:Jt([Xs.frame,(0,h.A)({},Xs.isLoading,!1)]),style:{paddingBottom:"".concat(o/i*100,"%")},children:(0,se.jsx)(Qs,{className:Xs.screen,item:e,index:t,screenSize:d,onClick:A,focusable:b})})})},"item-".concat(l))})})}),s,F?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)("div",{className:Xs.micromagBrandingSeparator}),(0,se.jsx)(Ys,{className:Xs.micromagBrandingContainer})]}):null]})})})}function tu(e){var t=e.screen,l=void 0===t?null:t,a=e.title,n=void 0===a?null:a,i=e.url,o=void 0===i?null:i,r=e.description,s=void 0===r?null:r,u=e.className,d=void 0===u?null:u;return(0,se.jsxs)("div",{className:Jt(["micromag-viewer-partials-micromag-preview-container",d]),children:[(0,se.jsx)("div",{className:"micromag-viewer-partials-micromag-preview-cover",children:(0,se.jsx)(qa,{screen:l,width:100,height:150,withSize:!0})}),(0,se.jsxs)("div",{className:"micromag-viewer-partials-micromag-preview-info",children:[(0,se.jsx)("h3",{className:"micromag-viewer-partials-micromag-preview-title",children:n}),o?(0,se.jsx)("div",{className:"micromag-viewer-partials-micromag-preview-url",children:o}):null,(0,se.jsx)("p",{children:s})]})]})}var lu={container:"micromag-viewer-menus-menu-share-container",content:"micromag-viewer-menus-menu-share-content",scroll:"micromag-viewer-menus-menu-share-scroll",inner:"micromag-viewer-menus-menu-share-inner",header:"micromag-viewer-menus-menu-share-header",mode:"micromag-viewer-menus-menu-share-mode",options:"micromag-viewer-menus-menu-share-options"},au=[];function nu(e){var t=e.viewerTheme,l=void 0===t?null:t,n=e.menuWidth,o=void 0===n?null:n,r=e.title,s=void 0===r?null:r,u=e.description,d=void 0===u?null:u,c=e.items,m=void 0===c?au:c,v=e.shareOptions,g=void 0===v?null:v,y=e.focusable,h=void 0===y||y,f=e.paddingTop,p=void 0===f?null:f,b=e.currentScreenIndex,x=void 0===b?0:b,A=e.shareUrl,S=void 0===A?null:A,C=e.onShare,w=void 0===C?null:C,k=e.className,j=void 0===k?null:k,M=(l||{}).background,N=((void 0===M?null:M)||{}).image,F=((void 0===N?null:N)||{}).url,T=void 0===F?null:F,z=null!==T?{backgroundImage:"url(".concat(T,")")}:null,$=(0,a.useMemo)(function(){var e=(m[0]||{}).screen;return void 0===e?null:e},[m]),L=(0,a.useMemo)(function(){var e=(m.find(function(e){var t=(e||{}).current;return void 0!==t&&t})||{}).screen;return void 0===e?null:e},[m,x,h]),I=(0,a.useState)(!1),P=(0,R.A)(I,2),B=P[0],E=P[1],V=(0,a.useCallback)(function(){E(function(e){return!e})},[E]),D=(0,a.useMemo)(function(){return B&&0!==x?"".concat(S,"/").concat(x+1):S},[S,B,x]);return(0,se.jsx)("div",{className:Jt([lu.container,j]),style:(0,i.A)((0,i.A)({},z),{},{width:o}),"aria-hidden":h?null:"true",children:(0,se.jsx)("div",{className:lu.content,children:(0,se.jsx)(ei,{className:lu.scroll,children:(0,se.jsxs)("div",{className:lu.inner,style:{paddingTop:p},children:[(0,se.jsxs)("div",{className:lu.header,children:[(0,se.jsx)(tu,{className:lu.preview,screen:B?L:$,title:s,url:D,description:d}),0!==x?(0,se.jsx)("div",{className:lu.mode,children:(0,se.jsxs)("label",{children:[(0,se.jsx)("input",{type:"checkbox",name:"currentScreen",value:"currentScreen",onChange:V,checked:B}),(0,se.jsx)(Wl.A,{id:"xuPbeq",defaultMessage:[{type:0,value:"Start from the current screen"}]})]})}):null]}),(0,se.jsx)(Vo,{className:lu.options,itemClassName:lu.optionItem,buttonClassName:lu.optionButton,title:s,options:g,url:D,focusable:h,onShare:w,theme:l,shareCurrentScreen:B})]})})})})}var iu={container:"micromag-viewer-container",landscape:"micromag-viewer-landscape",screensFrame:"micromag-viewer-screensFrame",hideMenu:"micromag-viewer-hideMenu",menuNavContainer:"micromag-viewer-menuNavContainer",menuTopContainer:"micromag-viewer-menuTopContainer",dots:"micromag-viewer-dots",disableMenu:"micromag-viewer-disableMenu",content:"micromag-viewer-content",withoutGestures:"micromag-viewer-withoutGestures",ariaAnnouncement:"micromag-viewer-ariaAnnouncement",accessibilityLinks:"micromag-viewer-accessibilityLinks",accessibilityButton:"micromag-viewer-accessibilityButton",disabled:"micromag-viewer-disabled",tooltip:"micromag-viewer-tooltip",fadeMenu:"micromag-viewer-fadeMenu",withShadow:"micromag-viewer-withShadow",isOpened:"micromag-viewer-isOpened",menuItem:"micromag-viewer-menuItem",menuButton:"micromag-viewer-menuButton",slidingButton:"micromag-viewer-slidingButton",screensMenuButtonToggled:"micromag-viewer-screensMenuButtonToggled",menuContainer:"micromag-viewer-menuContainer",menuShare:"micromag-viewer-menuShare",menuPreview:"micromag-viewer-menuPreview",navButton:"micromag-viewer-navButton",previous:"micromag-viewer-previous",next:"micromag-viewer-next",screenContainer:"micromag-viewer-screenContainer",screen:"micromag-viewer-screen",preload:"micromag-viewer-preload",visible:"micromag-viewer-visible",current:"micromag-viewer-current",playbackControls:"micromag-viewer-playbackControls",navigationHint:"micromag-viewer-navigationHint",webView:"micromag-viewer-webView",shareIncentiveContainer:"micromag-viewer-shareIncentiveContainer",shareIncentive:"micromag-viewer-shareIncentive",shareIncentiveVisible:"micromag-viewer-shareIncentiveVisible"},ou=["share","main"];function ru(e){var t,l=e.story,n=e.menuItems,o=void 0===n?ou:n,r=e.currentScreenIndex,s=void 0===r?0:r,u=e.toggleFullscreen,d=void 0===u?null:u,c=e.fullscreenActive,m=void 0!==c&&c,v=e.fullscreenEnabled,g=void 0!==v&&v,y=e.menuDotsButtons,f=void 0===y?null:y,p=e.closeable,b=void 0!==p&&p,x=e.withShadow,A=void 0!==x&&x,S=e.shareBasePath,C=void 0===S?null:S,w=e.shareOptions,k=void 0===w?null:w,j=e.trackingEnabled,M=void 0!==j&&j,N=e.theme,F=void 0===N?null:N,T=e.screenSize,z=void 0===T?null:T,$=e.menuWidth,L=void 0===$?null:$,I=e.previewHeader,P=void 0===I?null:I,B=e.previewFooter,E=void 0===B?null:B,V=e.afterShareMenuButton,D=void 0===V?null:V,O=e.beforeScreensMenuButton,H=void 0===O?null:O,Z=e.withMicromagBranding,W=void 0!==Z&&Z,q=e.withDotItemClick,_=void 0!==q&&q,G=e.withoutScreensMenu,Y=void 0!==G&&G,U=e.withoutShareMenu,Q=void 0!==U&&U,X=e.onClickScreen,J=void 0===X?null:X,K=e.onChange,ee=void 0===K?null:K,te=e.onClickCloseViewer,le=void 0===te?null:te,ae=e.refDots,ne=void 0===ae?null:ae,ie=l.components,oe=void 0===ie?[]:ie,re=l.title,ue=void 0===re?null:re,de=l.metadata,ce=((void 0===de?null:de)||{}).description,me=void 0===ce?null:ce,ve=null!==oe&&oe[s]||{},ge=ve.id,ye=void 0===ge?null:ge,he=ve.type,fe=void 0===he?null:he,pe=(F||{}).menuTheme,be=void 0===pe?null:pe,xe=((t=Ot()).width,t.height),Ae=(0,a.useState)(!1),Se=(0,R.A)(Ae,2),Ce=Se[0],we=Se[1],ke=(0,a.useState)(!1),je=(0,R.A)(ke,2),Me=je[0],Ne=je[1],Fe=(0,a.useState)(!1),Te=(0,R.A)(Fe,2),Re=Te[0],ze=Te[1],$e=pl(),Le=$e.ref,Ie=$e.height,Pe=void 0===Ie?0:Ie,Be=(0,a.useMemo)(function(){return oe.map(function(e){var t=oe.filter(function(t){return t.parentId===e.id}),l=t.find(function(e){return e.id===ye})||null,a=t.findIndex(function(e){return e.id===ye})+1;return{screen:e,screenId:e.id,current:ye===e.id||null!==l,visible:null===((null==e?void 0:e.parentId)||null),count:t.length+1||1,subIndex:a||0}}).filter(function(e){var t=e.visible;return void 0===t||t})},[oe,ye]),Ee=Il(),Ve=(0,a.useCallback)(function(e,t,l){M&&Ee(e,t,l,{screenId:ye,screenIndex:s,screenType:fe})},[Ee,ye,s,fe]),De=(0,a.useMemo)(function(){var e="undefined"!=typeof window?"".concat(window.location.protocol,"//").concat(window.location.host):"",t=null!==C&&-1!==C.indexOf("http"),l=null!==C?"".concat(e).concat(C):e;return null!==C&&t?C.replace(/\/$/,""):l},[C]),Oe=(0,a.useCallback)(function(){we(!0),Ne(!1),Ve("viewer_menu","open_screens_menu")},[we,Ne,Ve]),He=(0,a.useCallback)(function(){we(!1),Ne(!1),Ve("viewer_menu","close_screens_menu")},[we,Ne,Ve]),Ze=(0,a.useCallback)(function(){Ne(!0),we(!1),Ve("viewer_menu","open_share_menu")},[Ne,we,Ve]),We=(0,a.useCallback)(function(){Ne(!1),we(!1),Ve("viewer_menu","close_share_menu")},[Ne,we,Ve]),qe=(0,a.useCallback)(function(e){we(!1),null!==J&&J(e);var t=Be.findIndex(function(e){return e.id===ye});Ve("viewer_menu","click_screen_change","Screen ".concat(t+1))},[J,we,Be,ye,Ve]);(0,a.useEffect)(function(){null!==ee&&ee({menuOpen:Ce,shareOpen:Me})},[ee,Ce,Me]);var _e=(0,a.useCallback)(function(e){Ve("viewer_menu","shared_story",e)},[Ve]),Ge=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.direction,2)[1],a=(0,R.A)(e.movement,2)[1],n=(0,R.A)(e.velocity,2)[1],i=Math.max(0,a)/(.8*xe),o=(n>.3||Math.abs(i)>.3)&&-1!==l;return t?i:(o&&Ze(),o?1:0)},[Ze,xe]),Ye=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.direction,2)[1],a=(0,R.A)(e.movement,2)[1],n=(0,R.A)(e.velocity,2)[1],i=Math.max(0,a)/(.8*xe),o=(n>.3||Math.abs(i)>.3)&&-1!==l;return t?1-i:(o&&We(),o?0:1)},[We,xe]),Ue=(0,a.useMemo)(function(){return{config:{tension:300,friction:30}}},[]),Qe=dl({progress:Me?1:0,computeProgress:Me?Ye:Ge,springParams:Ue,dragOptions:{axis:"y",pointer:{keys:!1}}}),Xe=Qe.bind,Je=Qe.dragging,Ke=Qe.progress,et=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.direction,2)[1],a=(0,R.A)(e.movement,2)[1],n=(0,R.A)(e.velocity,2)[1],i="undefined"!=typeof window?window.innerHeight:0,o=i>0?Math.max(0,a)/(.8*i):0,r=(n>.3||Math.abs(o)>.3)&&-1!==l;return t?o:(r&&Oe(),r?1:0)},[Oe]),tt=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.direction,2)[1],a=(0,R.A)(e.movement,2)[1],n=(0,R.A)(e.velocity,2)[1],i="undefined"!=typeof window?window.innerHeight:0,o=i>0?Math.max(0,a)/(.8*i):0,r=(n>.3||Math.abs(o)>.3)&&-1!==l;return t?1-o:(r&&He(),r?0:1)},[He]),lt=dl({progress:Ce?1:0,computeProgress:Ce?tt:et,springParams:Ue,drapOptions:{axis:"y",pointer:{keys:!1}}}),at=lt.bind,nt=lt.dragging,it=lt.progress;return ks((0,a.useMemo)(function(){return{m:function(){return Ce?He():Oe()},escape:function(){return He()}}},[Ce,Oe,He])),(0,a.useEffect)(function(){!Ce&&!nt||Re?Ce||nt||!Re||ze(!1):ze(!0)},[Ce,nt,Re,ze]),(0,se.jsxs)(se.Fragment,{children:[(0,se.jsxs)("div",{className:Jt([iu.menuNavContainer,(0,h.A)((0,h.A)({},iu.withShadow,A),iu.isOpened,Ce||Me)]),ref:ne,style:{width:L},children:[(0,se.jsx)("nav",{className:iu.menuTopContainer,ref:Le,children:o.map(function(e){return"share"===e?Q&&null===D?null:(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:iu.menuItem},Xe()),{},{children:[Q?null:(0,se.jsx)(Ds,{className:iu.slidingButton,button:(0,se.jsx)(Vs,{className:iu.menuButton,onClick:Ze,theme:be,iconPosition:"left",focusable:!Me}),toggledButton:(0,se.jsx)(ws.Ay,{group:"share",disabled:!Me,returnFocus:!0,children:(0,se.jsx)(Is,{className:iu.menuButton,onClick:We,theme:be,iconPosition:"left",focusable:Me,single:!0})}),progressSpring:Ke}),D]})):"main"===e?Y&&null===H?null:(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:iu.menuItem},at()),{},{children:[H,Y?null:(0,se.jsx)(Ds,{className:iu.slidingButton,button:(0,se.jsx)(Bs,{className:iu.menuButton,iconClassName:iu.menuButtonIcon,onClick:Oe,theme:be,focusable:!Ce}),toggledButton:(0,se.jsx)(ws.Ay,{group:"screens",disabled:!Ce,returnFocus:!0,children:(0,se.jsx)(Is,{className:iu.menuButton,onClick:He,theme:be,iconPosition:"right",focusable:Ce})}),progressSpring:it,toggledButtonClassName:iu.screensMenuButtonToggled})]})):e||null})}),(0,se.jsx)(_s,(0,i.A)((0,i.A)({},be),{},{direction:"horizontal",items:Be,onClickDot:qe,onClickScreensMenu:Oe,buttons:f,closeable:b,withItemClick:_,withoutScreensMenu:Y,withoutShareMenu:Q,onClose:le,className:iu.dots}))]}),(0,se.jsx)(Os,{className:iu.menuContainer,progressSpring:Ke,theme:F,children:Je||Me?(0,se.jsx)(ws.Ay,{group:"share",disabled:!Me,returnFocus:!0,children:(0,se.jsx)(nu,{viewerTheme:F,className:iu.menuShare,title:ue,description:me,menuWidth:L,paddingTop:Pe,focusable:Me,items:Be,shareOptions:k,currentScreenIndex:s,shareUrl:De,onShare:_e,onClose:We})}):null}),(0,se.jsx)(Os,{className:iu.menuContainer,progressSpring:it,theme:F,children:Re?(0,se.jsx)(ws.Ay,{group:"screens",disabled:!Ce,returnFocus:!0,children:(0,se.jsx)(eu,{viewerTheme:F,header:P,footer:E,title:ue,className:iu.menuPreview,screenSize:z,menuWidth:L,paddingTop:Pe,items:Be,currentScreenIndex:s,shareUrl:De,onShare:_e,onClickScreen:qe,onClose:He,scrollDisabled:nt,toggleFullscreen:d,fullscreenActive:m,fullscreenEnabled:g,withMicromagBranding:W})}):null})]})}function su(e){var t=e.screen,l=void 0===t?null:t,n=e.renderContext,i=void 0===n?null:n,o=e.index,r=void 0===o?null:o,s=e.screenState,u=void 0===s?null:s,d=e.active,c=void 0===d||d,m=e.preload,v=void 0===m||m,g=e.current,y=void 0!==g&&g,h=e.mediaRef,f=void 0===h?null:h,p=e.width,b=void 0===p?null:p,x=e.height,A=void 0===x?null:x,S=e.scale,C=void 0===S?null:S,w=e.className,k=void 0===w?null:w,j=(0,a.useState)(c||y),M=(0,R.A)(j,2),N=M[0],F=M[1];return(0,a.useEffect)(function(){var e=null;return c!==N&&(e=setTimeout(function(){F(c)},200)),function(){null!==e&&clearTimeout(e)}},[c,N,F,r]),N||y?(0,se.jsx)("div",{className:Jt(["micromag-viewer-screen-container",k]),children:(0,se.jsx)("div",{className:"micromag-viewer-screen-inner",style:{width:b,height:A,transform:null!==C?"scale(".concat(C,")"):null,transformOrigin:null!==C?"0 0":null,opacity:N?1:null},children:N||y?(0,se.jsx)(Za,{screen:l,renderContext:i,screenState:u,index:r,active:c,preload:v,current:y,mediaRef:f}):null})}):null}var uu={container:"micromag-viewer-buttons-navigation-button-container",arrow:"micromag-viewer-buttons-navigation-button-arrow",next:"micromag-viewer-buttons-navigation-button-next",previous:"micromag-viewer-buttons-navigation-button-previous"},du=["direction","onClick","className"];function cu(e){var t=e.direction,l=void 0===t?"next":t,a=e.onClick,n=void 0===a?null:a,o=e.className,s=void 0===o?null:o,u=(0,r.A)(e,du);return(0,se.jsx)($s,(0,i.A)({className:Jt([uu.container,uu[l],s]),onClick:function(e){e.stopPropagation(),n()},iconPosition:"next"===l?"right":"left",icon:(0,se.jsx)("svg",{className:uu.arrow,xmlns:"http://www.w3.org/2000/svg",width:"10",height:"16",viewBox:"0 0 10 16",fill:"currentColor",children:(0,se.jsx)("polygon",{points:"9.62 4.62 5 0 0.38 4.62 1.44 5.68 4.25 2.87 4.25 14.39 5.75 14.39 5.75 2.87 8.56 5.68 9.62 4.62"})})},u))}function mu(e){var t=e.withoutShadow,l=void 0!==t&&t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("div",{className:Jt(["micromag-viewer-partials-arrow-hint-container",n,(0,h.A)({},"micromag-viewer-partials-arrow-hint-withoutShadow",l)]),children:(0,se.jsx)("div",{className:"micromag-viewer-partials-arrow-hint-inner",children:(0,se.jsx)(va,{className:"micromag-viewer-partials-arrow-hint-arrow"})})})}function vu(e){var t=e.color,l=void 0===t?"currentColor":t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("svg",{className:n,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 367.24 482.87",children:(0,se.jsx)("path",{d:"M488.84,255.91a44.68,44.68,0,0,0-19.15,4.3A44.77,44.77,0,0,0,406,226.49a44.75,44.75,0,0,0-62.67-32.66V105.4a44.81,44.81,0,1,0-89.61,0V265.17l-1.15-2.7a44.78,44.78,0,1,0-82.84,34.06l64.87,157.76.34.73a156.29,156.29,0,0,0,141.42,88.44c86.7,0,157.24-70.53,157.24-157.26V300.7a44.82,44.82,0,0,0-44.78-44.79ZM507.46,386.2c0,72.3-58.78,131.1-131.07,131.1a130.29,130.29,0,0,1-117.73-73.36L193.93,286.61a18.64,18.64,0,1,1,34.53-14.07L279.91,394V105.4a18.64,18.64,0,1,1,37.28,0v196a13.08,13.08,0,0,0,26.16,0V234.56a18.64,18.64,0,0,1,37.27,0v89.95a13.07,13.07,0,1,0,26.13,0V266.86a18.64,18.64,0,1,1,37.28,0v80.71h0s0,.08,0,.11a13.08,13.08,0,0,0,26.15,0v-47a18.63,18.63,0,1,1,37.26,0v85.5Z",transform:"translate(-166.38 -60.59)",fill:l,fillRule:"evenodd"})})}function gu(e){var t=e.withoutShadow,l=void 0!==t&&t,a=e.className,n=void 0===a?null:a;return(0,se.jsx)("div",{className:Jt(["micromag-viewer-partials-hand-tap-container",n,(0,h.A)({},"micromag-viewer-partials-hand-tap-withoutShadow",l)]),children:(0,se.jsxs)("div",{className:"micromag-viewer-partials-hand-tap-inner",children:[(0,se.jsx)("div",{className:"micromag-viewer-partials-hand-tap-circle"}),(0,se.jsx)(vu,{className:"micromag-viewer-partials-hand-tap-hand"})]})})}var yu={inner:"micromag-viewer-partials-seek-bar-inner",progressBarContainer:"micromag-viewer-partials-seek-bar-progressBarContainer",progressBar:"micromag-viewer-partials-seek-bar-progressBar",progress:"micromag-viewer-partials-seek-bar-progress",track:"micromag-viewer-partials-seek-bar-track",playHead:"micromag-viewer-partials-seek-bar-playHead",withSeekHead:"micromag-viewer-partials-seek-bar-withSeekHead",scrubbedTime:"micromag-viewer-partials-seek-bar-scrubbedTime",showTimestamp:"micromag-viewer-partials-seek-bar-showTimestamp"};function hu(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(null===e||e<=0)return"00:00";var t="".concat(e).split(".")||[],l=(0,R.A)(t,1)[0],a=void 0===l?0:l,n=Math.round(a),i=n%60,o=n-i,r=o>0?o/60:0;return"".concat(String(Math.round(r)).padStart(2,"0"),":").concat(String(Math.round(i)).padStart(2,"0"))}function fu(e){var t=e.media,l=void 0===t?null:t,n=e.playing,o=void 0!==n&&n,s=e.backgroundColor,u=void 0===s?null:s,d=e.progressColor,c=void 0===d?null:d,m=e.onClick,v=void 0===m?null:m,g=e.onSeek,y=void 0===g?null:g,f=e.onSeekStart,p=void 0===f?null:f,b=e.onSeekEnd,x=void 0===b?null:b,A=e.collapsed,S=void 0!==A&&A,C=e.focusable,w=void 0===C||C,k=e.className,j=void 0===k?null:k,M=e.withSeekHead,N=void 0===M||M,F=(0,Zl.A)(),T=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.disabled,n=void 0!==l&&l,o=(0,r.A)(t,wl),s=(0,a.useState)(!n),u=(0,R.A)(s,2),d=u[0],c=u[1],m=Cl(e,(0,i.A)({disabled:n||!d},o)),v=(0,a.useState)(0),g=(0,R.A)(v,2),y=g[0],h=g[1],f=(0,a.useRef)(y),p=(0,a.useRef)(Date.now()/1e3),b=(0,a.useCallback)(function(e){p.current=Date.now()/1e3,f.current=e,h(e)},[h]);return(0,a.useEffect)(function(){if(null!==e){var t=(e.currentTime||0)>0&&e.duration>0?e.currentTime/e.duration:0;b(t),c(!e.paused&&4===e.readyState)}else b(0),c(!1)},[e,n,c]),(0,a.useEffect)(function(){if(null===e)return function(){};function t(t){c(!0);var l=e.currentTime/e.duration;b(l)}function l(t){c(!t.currentTarget.paused&&!t.currentTarget.ended);var l=e.currentTime/e.duration;b(l)}function a(){c(!1);var t=e.currentTime/e.duration;b(t)}return e.addEventListener("play",t),e.addEventListener("playing",t),e.addEventListener("seeked",l),e.addEventListener("pause",a),e.addEventListener("ended",a),e.addEventListener("waiting",a),e.addEventListener("stalled",a),e.addEventListener("seeking",a),e.addEventListener("suspend",l),function(){e.removeEventListener("play",t),e.removeEventListener("seeked",t),e.removeEventListener("playing",t),e.removeEventListener("pause",a),e.removeEventListener("ended",a),e.removeEventListener("waiting",a),e.removeEventListener("stalled",a),e.removeEventListener("seeking",a),e.removeEventListener("suspend",l)}},[e,b,c,d]),(0,a.useEffect)(function(){if(null===e||!d||n)return function(){};var t,l=!1;return function a(){if(!l){var n=(Date.now()/1e3-p.current)/m,i=f.current<.1?e.currentTime/e.duration:f.current+n;b(i),t=al()(a)}}(),function(){l=!0,al().cancel(t)}},[e,d,n,m,b]),f.current}(l,{disabled:!o}),z=(0,a.useState)(!1),$=(0,R.A)(z,2),L=$[0],I=$[1],P=Sl(l,{disabled:!o&&!L}),B=Cl(l,{disabled:!o&&!L}),E=(0,a.useRef)(T),V=(0,a.useCallback)(function(e){var t=(0,R.A)(e.xy,1)[0];(0,R.A)(e.movement,1)[0];var l=e.elapsedTime,a=e.active,n=e.tap,i=e.currentTarget;if(a||!(l>300))if(S)v();else{var o,r=i.getBoundingClientRect(),s=r.width,u=void 0===s?0:s,d=r.x,c=void 0===d?null:d;o=Math.max(0,Math.min(1,(t-c)/u)),null!==y&&y(o,n)}},[y,v,S]),D=(0,a.useCallback)(function(){E.current=T,I(!0),null!==p&&p()},[T,p,I]),O=(0,a.useCallback)(function(){null!==x&&(I(!1),x())},[x,I]),H=(0,Xt.useGesture)({onDrag:V,onDragStart:D,onDragEnd:O},{drag:{axis:"x",filterTaps:!0}});return(0,se.jsx)("div",(0,i.A)((0,i.A)({className:Jt([yu.container,j,(0,h.A)((0,h.A)({},yu.withSeekHead,N),yu.showTimestamp,L)])},Ns),{},{children:(0,se.jsxs)("div",{className:yu.inner,children:[(0,se.jsxs)("div",{className:yu.progressBarContainer,children:[(0,se.jsx)("div",{className:yu.progressBar,style:{backgroundColor:u}}),(0,se.jsx)("div",{className:yu.playHead,style:{left:"".concat(100*T,"%"),backgroundColor:c},children:(0,se.jsx)("div",{className:yu.scrubbedTime,style:{borderColor:c},children:hu(P,B<5)})}),(0,se.jsx)("div",{className:yu.progress,style:{transform:"scaleX(".concat(T,")"),backgroundColor:c}})]}),(0,se.jsx)("button",(0,i.A)((0,i.A)({},H()),{},{type:"button",role:"slider","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":T,"aria-valuetext":F.formatMessage({id:"C1VUEY",defaultMessage:[{type:1,value:"current"},{type:0,value:" of "},{type:1,value:"duration"}]},{current:hu(P,B<5),duration:hu(B,B<5)}),"data-draggable":!0,className:yu.track,title:F.formatMessage({id:"G1Gyjn",defaultMessage:[{type:0,value:"Seek"}]}),"aria-label":F.formatMessage({id:"2prwZ7",defaultMessage:[{type:0,value:"Progress slider"}]}),tabIndex:w?"0":"-1"}))]})}))}var pu="micromag-viewer-partials-playback-controls-icon",bu="micromag-viewer-partials-playback-controls-offset",xu={color:"#FFFFFF",alpha:1},Au={color:"#666",alpha:1};function Su(e){var t=e.defaultColor,l=void 0===t?xu:t,n=e.defaultProgressColor,i=void 0===n?Au:n,o=e.withLoading,r=void 0===o||o,s=e.withoutShadow,u=void 0!==s&&s,d=e.className,c=void 0===d?null:d,m=e.collapsedClassName,v=void 0===m?null:m,g=(0,Zl.A)(),f=jt(),p=f.media,b=void 0===p?null:p,x=f.hasAudio,A=void 0===x?null:x,S=f.playing,C=void 0!==S&&S,w=f.muted,k=void 0===w||w,j=f.setPlaying,M=f.setMuted,N=f.controls,F=f.controlsSuggestPlay,T=f.controlsVisible,z=f.controlsTheme,$=f.showControls,L=(0,a.useState)(!1),I=(0,R.A)(L,2),P=I[0],B=I[1],E=null!==b?b.src:null,V=kl(b,{id:E}),D=null===b||V,O=P&&!D,H=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.playing,n=void 0!==l&&l,i=t.muted,o=void 0!==i&&i,r=(0,a.useMemo)(function(){var t=null!==e&&y()(e.src)&&e.src.split("/")[e.src.split("/").length-1].split("#")[0]||null;return il()(null!==t?"micromag:media:".concat(t):"micromag:media")},[e]),s=(0,a.useState)(n),u=(0,R.A)(s,2),d=u[0],c=u[1],m=(0,a.useState)(!1),v=(0,R.A)(m,2),g=v[0],h=v[1],f=(0,a.useState)(null!==e&&(e.muted||0===e.volume)||o),p=(0,R.A)(f,2),b=p[0],x=p[1];return(0,a.useEffect)(function(){r("State change %o",{playing:d,buffering:g,muted:b})},[d,g,b,r]),(0,a.useEffect)(function(){null===e&&(c(n),h(!1),x(o),r("Unset media: %o",{wantedPlaying:n,wantedMuted:o}))},[e,r,n,o]),(0,a.useEffect)(function(){if(null===e)return function(){};function t(t){e.networkState===e.NETWORK_LOADING&&(r("onBufferingEvent: NETWORK_LOADING"),h(!0)),e.readyState<e.HAVE_FUTURE_DATA&&(r("onBufferingEvent: HAVE_FUTURE_DATA"),h(!0))}function l(){r("onPlay"),c(!0),h(!1)}function a(){r("onPlaying"),c(!0),h(!1)}function n(e){r("onTimeUpdate"),c(!e.currentTarget.paused&&!e.currentTarget.ended),h(!1)}function i(){r("onPause"),c(!1),h(!1)}function o(){r("onEnded"),c(!1),h(!1)}function s(e){r("onSuspend"),c(!e.currentTarget.paused&&!e.currentTarget.ended),h(!1)}function u(){x(e.muted||0===e.volume)}return(e.paused||e.ended)&&c(!1),b!==e.muted&&x(e.muted),e.addEventListener("waiting",t),e.addEventListener("stalled",t),e.addEventListener("timeupdate",n),e.addEventListener("play",l),e.addEventListener("playing",a),e.addEventListener("pause",i),e.addEventListener("suspend",s),e.addEventListener("ended",o),e.addEventListener("volumechange",u),function(){e.removeEventListener("waiting",t),e.removeEventListener("stalled",t),e.removeEventListener("timeupdate",n),e.removeEventListener("play",l),e.removeEventListener("playing",a),e.removeEventListener("pause",i),e.removeEventListener("suspend",s),e.removeEventListener("ended",o),e.removeEventListener("volumechange",u)}},[e,r]),{playing:d,muted:b,buffering:g}}(b,{playing:C,muted:k}),Z=H.buffering,W=H.playing,q=H.muted;(0,a.useEffect)(function(){var e=null;return B(!1),D&&!Z||!r||(e=setTimeout(function(){B(!0)},1e3)),function(){B(!1),clearTimeout(e)}},[D,Z,r,B]);var _=(0,a.useState)({color:ke(l),progressColor:ke(l),seekBarOnly:!1}),G=(0,R.A)(_,2),Y=G[0],U=G[1],Q=(0,a.useState)(!1),X=(0,R.A)(Q,2),J=X[0],K=X[1];(0,a.useEffect)(function(){var e=z||{},t=e.color,a=e.progressColor,n=e.seekBarOnly;U({color:ke(t||l),progressColor:ke(a||i),seekBarOnly:n})},[z,U,l,i]);var ee=(0,a.useCallback)(function(){j(!0),!T&&N&&$()},[j,T,$]),te=(0,a.useCallback)(function(){j(!1),!T&&N&&$()},[j,T,N,$]),le=(0,a.useCallback)(function(){M(!0),!T&&N&&$()},[M,T,$]),ae=(0,a.useCallback)(function(){M(!1),!T&&N&&$()},[M,T,$]),ne=(0,a.useCallback)(function(){K(W),W&&j(!1)},[W,K,j]),ie=(0,a.useCallback)(function(e){null!==b&&(b.currentTime=e*b.duration),!T&&N&&$()},[b,T,N,$]),oe=(0,a.useCallback)(function(){J&&j(!0)},[j,J]),re=(0,a.useCallback)(function(){!T&&N&&$()},[T,N,$]),ue=null!==b,de=ue&&(null===A||!0===A),ce=Y||{},me=ce.color,ve=ce.progressColor,ge=ce.seekBarOnly,ye=N&&!T&&W||!N&&de,he=W?(0,se.jsx)(fa,{className:pu,color:"currentColor"}):(0,se.jsx)(pa,{className:pu,color:"currentColor"});return(0,se.jsxs)("div",{className:Jt(["micromag-viewer-partials-playback-controls-container",c,ye?v:null,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},"micromag-viewer-partials-playback-controls-withPlayPause",N&&!ge),"micromag-viewer-partials-playback-controls-withSuggestPlay",F),"micromag-viewer-partials-playback-controls-withMute",ue||N),"micromag-viewer-partials-playback-controls-withSeekBar",N),"micromag-viewer-partials-playback-controls-withSeekBarOnly",ge),"micromag-viewer-partials-playback-controls-isCollapsed",ye),"micromag-viewer-partials-playback-controls-withoutShadow",u),"micromag-viewer-partials-playback-controls-isMuted",q)]),children:[F&&!O?(0,se.jsx)(ca,{className:Jt(["micromag-viewer-partials-playback-controls-suggest"]),style:{color:me},onClick:W?te:ee,focusable:T,icon:(0,se.jsx)(pa,{className:Jt([pu,bu]),color:"currentColor"}),"aria-pressed":!W,"aria-label":g.formatMessage({id:"mTqcmA",defaultMessage:[{type:0,value:"Pause"}]}),withoutBootstrapStyles:!0}):null,(0,se.jsx)(ca,{className:Jt(["micromag-viewer-partials-playback-controls-playPauseButton",(0,h.A)((0,h.A)({},"micromag-viewer-partials-playback-controls-hidden",F&&!N),"micromag-viewer-partials-playback-controls-loading",O)]),style:{color:me},onClick:W?te:ee,focusable:N&&T&&(!ge||!W),disabled:O,icon:O?(0,se.jsx)(ma,{className:Jt(["micromag-viewer-partials-playback-controls-spinner",bu])}):he,"aria-pressed":!W,"aria-label":O?g.formatMessage({id:"YyYrXp",defaultMessage:[{type:0,value:"Loading"}]}):g.formatMessage({id:"mTqcmA",defaultMessage:[{type:0,value:"Pause"}]}),withoutBootstrapStyles:!0}),(0,se.jsx)(fu,{className:"micromag-viewer-partials-playback-controls-seekBar",media:b,playing:W,onClick:re,onSeek:ie,onSeekStart:ne,onSeekEnd:oe,focusable:N&&T&&!ge,collapsed:ye,withSeekHead:!ye&&!ge,backgroundColor:me,progressColor:ve}),(0,se.jsx)(ca,{className:"micromag-viewer-partials-playback-controls-muteButton",style:{color:me},onClick:q?ae:le,focusable:T||de,icon:q?(0,se.jsx)(ba,{className:pu,color:"currentColor"}):(0,se.jsx)(ha,{className:pu,color:"currentColor"}),"aria-pressed":!q,"aria-label":g.formatMessage({id:"RK/QEY",defaultMessage:[{type:0,value:"Unmute"}]}),withoutBootstrapStyles:!0})]})}var Cu=["opened","close","open","update","url","source"];function wu(e){var t=e.onChange,l=void 0===t?null:t,n=e.trackingEnabled,o=void 0!==n&&n,s=e.className,u=void 0===s?null:s,d=e.style,c=void 0===d?null:d,m=qt(),v=m.opened,g=m.close;m.open,m.update;var y=m.url,f=void 0===y?null:y,p=m.source,b=void 0===p?null:p,x=(0,r.A)(m,Cu),A=Wt(),S=A.disableInteraction,C=A.enableInteraction,w=jt(),k=w.playing,j=w.setPlaying,M=w.hideControls,N=w.showControls,F=Il(),T=(0,a.useRef)(k),z=(0,a.useState)(f),$=(0,R.A)(z,2),L=$[0],I=$[1],P=ct().title,B=(0,a.useRef)(null);(0,a.useEffect)(function(){null!==f&&I(f)},[f,I]);var E=(0,a.useCallback)(function(){null===f&&I(null),null!==l&&l(v)},[f,I,l]);(0,a.useEffect)(function(){v?(S(),M(),T.current=k,k&&j(!1)):(C(),N(),T.current&&!k&&(T.current=!1,j(!0)))},[v,F]),(0,a.useEffect)(function(){o&&null!==L&&F("viewer_webview",v?"open":"close",L,{source:b})},[o,L,v]),ks((0,a.useMemo)(function(){return{escape:function(){g()}}},[g]));var V=f||L,D=(0,a.useMemo)(function(){var e=gr.A.parse(null!==V&&-1!==V.indexOf("?")?V.split("?")[1]:"");return null!==V?"".concat(V.split("?")[0],"?").concat(gr.A.stringify((0,i.A)({utm_source:"Micromag",utm_medium:b||"webview",utm_campaign:P},e))):f},[V,b]);return(0,se.jsx)("div",{className:Jt(["micromag-viewer-partials-web-view-container",u,(0,h.A)({},"micromag-viewer-partials-web-view-opened",v)]),style:c,onTransitionEnd:E,ref:B,children:(0,se.jsx)(Cs,(0,i.A)((0,i.A)({url:D,source:b},x),{},{closeable:v,focusable:v,className:"micromag-viewer-partials-web-view-webView",onClose:g}))})}var ku={tension:300,friction:35},ju=["share","main"];function Mu(e){var t=e.story,n=void 0===t?null:t,s=e.basePath,u=void 0===s?null:s,d=e.theme,c=void 0===d?null:d,m=e.width,v=void 0===m?null:m,g=e.height,y=void 0===g?null:g,f=e.screen,p=void 0===f?null:f,b=e.screenState,x=void 0===b?null:b,A=e.deviceScreens,C=void 0===A?Ne():A,w=e.renderContext,j=void 0===w?"view":w,M=e.tapNextScreenWidthPercent,N=void 0===M?.8:M,F=e.tapMaximumDuration,T=void 0===F?1500:F,z=e.longPressPauseDelay,$=void 0===z?300:z,L=e.storyIsParsed,I=void 0!==L&&L,P=e.neighborScreensActive,B=void 0===P?1:P,E=e.neighborScreenOffset,V=void 0===E?105:E,D=e.neighborScreenScale,O=void 0===D?.8:D,H=e.neighborPreloadDelay,Z=void 0===H?2e3:H,W=e.neighborPreloadBackward,q=void 0===W||W,_=e.neighborPreloadScreens,G=void 0===_?null:_,Y=e.topSafezoneHeight,U=void 0===Y?null:Y,Q=e.bottomSafezoneHeight,X=void 0===Q?null:Q,J=e.menuIsScreenWidth,K=void 0!==J&&J,ee=e.menuHeader,te=void 0===ee?null:ee,le=e.menuFooter,ae=void 0===le?null:le,ie=e.menuItems,oe=void 0===ie?ju:ie,re=e.shareBasePath,ue=void 0===re?null:re,de=e.shareOptions,ce=void 0===de?null:de,me=e.afterShareMenuButton,ve=void 0===me?null:me,ge=e.beforeScreensMenuButton,ye=void 0===ge?null:ge,he=e.backToFirstScreenTimeout,fe=void 0===he?null:he,pe=e.menuDotsButtons,be=void 0===pe?null:pe,xe=e.closeable,Ae=void 0!==xe&&xe,Se=e.readyWithoutSize,Ce=void 0!==Se&&Se,we=e.withMetadata,je=void 0!==we&&we,Me=e.withMicromagBranding,Fe=void 0!==Me&&Me,Te=e.withoutGestures,Re=void 0!==Te&&Te,ze=e.withoutMenu,$e=void 0!==ze&&ze,Le=e.withoutScreensMenu,Ie=void 0!==Le&&Le,Pe=e.withoutShareMenu,Be=void 0!==Pe&&Pe,Ee=e.withoutMenuShadow,Ve=void 0!==Ee&&Ee;e.withoutFullscreen;var De=e.withoutNavigationArrow,Oe=void 0!==De&&De,He=e.withoutTransitions,Ze=void 0!==He&&He,We=e.withNeighborScreens,qe=void 0!==We&&We,_e=e.withFullscreenWebView,Ge=void 0!==_e&&_e,Ye=e.withNavigationHint,Ue=void 0===Ye?"hand":Ye,Qe=e.withoutPlaybackControls,Xe=void 0!==Qe&&Qe,Je=e.withoutAutoUnmute,Ke=void 0!==Je&&Je,et=e.onClose,tt=void 0===et?null:et,lt=e.onInteraction,at=void 0===lt?null:lt,nt=e.onEnd,it=void 0===nt?null:nt,rt=e.onScreenChange,ut=void 0===rt?null:rt,dt=e.onViewModeChange,ct=void 0===dt?null:dt,vt=e.onMenuChange,gt=void 0===vt?null:vt,yt=e.currentScreenMedia,ht=void 0===yt?null:yt,ft=e.screensMedias,pt=void 0===ft?null:ft,bt=e.screenSizeOptions,xt=void 0===bt?null:bt,At=e.className,St=void 0===At?null:At,Ct=(0,Zl.A)(),wt=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=t.disabled,n=void 0!==l&&l,i=t.withTheme,o=void 0===i||i,r=t.withMedias,s=void 0===r||r,u=t.withFonts,d=void 0===u||u,c=t.withMigrations,m=void 0===c||c,v=st(),g=(0,a.useContext)(ot),y=(0,a.useMemo)(function(){return new ne({screensManager:v,fieldsManager:g,fieldsPattern:v.getFieldsPattern()})},[v,g]);return(0,a.useMemo)(function(){return n?e:y.parse(e,{withMedias:s,withTheme:o,withFonts:d,withMigrations:m})},[y,n,s,o,d,e])}(n,{disabled:I})||{},kt=wt.components,Mt=void 0===kt?[]:kt,Nt=wt.title,Ft=void 0===Nt?null:Nt,Tt=wt.metadata,Rt=void 0===Tt?null:Tt,zt=wt.fonts,$t=void 0===zt?null:zt,Lt=Mt.length,It=(0,a.useMemo)(function(){return new k},[wt]),Et=(0,a.useMemo)(function(){return Math.max(0,Mt.findIndex(function(e){return"".concat(e.id)==="".concat(p)}))},[p,Mt]),Vt=Mt[Et]||null,Dt=Vt||{},Ot=Dt.id,Ht=void 0===Ot?Et:Ot,Zt=(Dt.parameters||{}).metadata||{},Wt=Zt.title,qt=void 0===Wt?null:Wt,Gt=Zt.description,Yt=void 0===Gt?null:Gt,Ut=null!==qt?qt:Ft,Qt=(0,a.useMemo)(function(){return null!==Yt?(0,i.A)((0,i.A)({},Rt),{},{description:Yt}):Rt},[Rt,Yt]),Xt=(0,a.useRef)([]);null!==ht&&(ht.current=Xt.current[Et]||null),null!==pt&&(pt.current=Xt.current);var Kt=c||{},el=Kt.textStyles,ll=Kt.colors||{},al=ll.primary,nl=void 0===al?null:al,il=ll.focus,ol=ke((void 0===il?null:il)||nl),rl=(el||{}).title,ul=((void 0===rl?null:rl)||{}).fontFamily,cl=void 0===ul?null:ul,ml=(0,a.useMemo)(function(){return[].concat((0,o.A)($t||[]),[cl]).filter(function(e){return null!==e})},[$t]);(function(e){var t=(0,a.useState)(!1),n=(0,R.A)(t,2),r=n[0],s=n[1];return(0,a.useEffect)(function(){var t=e.reduce(function(e,t){var l=S()(t)?t:{type:"system",name:t},a=l.type,n=l.name,r=l.variants,s=void 0===r?[]:r;return"google"!==a&&"custom"!==a||function(e){return-1!==xl.loading.indexOf(e)}(n)||function(e){return-1!==xl.active.indexOf(e)}(n)?e:(0,i.A)((0,i.A)({},e),{},(0,h.A)({},a,{families:[].concat((0,o.A)(null!==e&&(e[a]||{}).families||[]),["google"===a?[n,(s||[]).filter(function(e){return null!==e}).join(",")].filter(function(e){return null!==e&&e.length>0}).join(":"):[n,(null!==s?[{fvd:"n4"}].concat((0,o.A)(s)):[]).map(function(e){var t=e.fvd,l=void 0===t?null:t,a=e.weight,n=void 0===a?null:a,i=e.style;return l||[void 0===i?null:i,n].filter(function(e){return null!==e}).map(function(e){return"".concat(e).substr(0,1)}).join("")}).filter(function(e){return null!==e&&e.length>0}).join(",")].filter(function(e){return null!==e&&e.length>0}).join(":")])}))},null);null!==t&&"undefined"!=typeof window?l.e(490).then(l.t.bind(l,6490,23)).then(function(e){return e.default.load((0,i.A)((0,i.A)({},t),{},{timeout:3e3,active:function(){return s(!0)},fontloading:function(e){return function(e){xl.active=xl.active.filter(function(t){return t!==e}),xl.loading=[].concat((0,o.A)(xl.loading),[e])}(e)},fontactive:function(e){return function(e){xl.loading=xl.loading.filter(function(t){return t!==e}),xl.active=[].concat((0,o.A)(xl.active),[e])}(e)},fontinactive:function(e){return function(e){xl.loading=xl.loading.filter(function(t){return t!==e})}(e)}}))}):s(!0)},[e,s]),{loaded:r}})(ml).loaded;var vl,gl="view"===j,yl="edit"===j,hl="static"===j||"capture"===j,fl=jt(),bl=fl.playing,Al=fl.setPlaying,Sl=fl.controls,Cl=void 0!==Sl&&Sl,wl=fl.controlsVisible,kl=void 0!==wl&&wl,jl=fl.media,Ml=void 0===jl?null:jl,Rl=fl.completed,$l=void 0!==Rl&&Rl,Ll=fl.isBackground,Il=void 0!==Ll&&Ll,Pl=fl.setMuted,Bl=void 0===Pl?null:Pl,El=(0,a.useMemo)(function(){return Cl&&kl},[Cl,kl]),Vl=pl(),Dl=Vl.ref,Ol=Vl.height,Hl=void 0===Ol?0:Ol,ql=(vl=Bt(),zl(vl)?(0,a.useCallback)(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;null!==e&&null!==t&&vl.trackScreenView(e,t)},[]):function(){}),_l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.width,l=void 0===t?null:t,a=e.height,n=void 0===a?null:a,o=(0,r.A)(e,Nl),s=pl(),u=s.ref,d=s.width,c=void 0===d?0:d,m=s.height,v=void 0===m?0:m,g=Fl(),y=null!==l?l:c,h=null!==n?n:v,f=o||{},p=f.screenWidth,b=void 0===p?320:p,x=f.screenHeight,A=void 0===x?480:x,S=f.withoutMaxSize,C=void 0!==S&&S,w=f.landscapeMinHeight,k=void 0===w?600:w,j=f.menuAlwaysOverScreen,M=void 0===j||j,N=f.landscapeMinRatio,F=void 0===N?2/3:N,T=f.withoutScale,R=void 0!==T&&T,z=b/A,$=h>0&&y/h>(F||z),L=y,I=h,P=!$;$&&!C&&(h<k||M?P=!0:I=h-100,L=Math.round(I*z)),L%2==1&&(L-=1),I%2==1&&(I-=1);var B=L>0?L/b:null;return{ref:u,fullWidth:y,fullHeight:h,screenSize:Tl((0,i.A)({width:R||null===B?L:b,height:R||null===B?I:I/B,landscape:$,menuOverScreen:P,scale:R?null:B},o)),scale:R?null:B,resolution:R?g:B*g}}((0,i.A)({width:v,height:y,screens:C},xt)),Gl=_l.ref,Yl=_l.fullWidth,Ul=_l.fullHeight,Ql=_l.screenSize,Xl=_l.scale,Jl=Ql||{},Kl=Jl.width,ea=void 0===Kl?null:Kl,ta=Jl.height,la=void 0===ta?null:ta,aa=Jl.landscape,na=void 0!==aa&&aa,ia=Jl.menuOverScreen,ra=void 0!==ia&&ia,sa=null!==Xl?ea*Xl:ea,ua=null!==Xl?la*Xl:la,da=ea>0&&la>0||Ce,ca=gl;(0,a.useEffect)(function(){ca&&null!==Vt&&ql(Vt,Et)},[Ht,ql,ca]),(0,a.useEffect)(function(){da&&null!==ct&&ct({landscape:na,menuOverScreen:ra})},[da,na,ra,ct]),(0,a.useEffect)(function(){null!==Gl.current&&null!==ol&&Gl.current.style.setProperty("--micromag-focus-color",ol)},[ol]);var ma=(0,a.useState)(!1),va=(0,R.A)(ma,2),ga=va[0],ya=va[1],ha=na&&qe?"carousel":"stack",fa=(0,a.useCallback)(function(e){e!==Et&&(ya(!1),null!==ht&&(ht.current=Xt.current[e]||null),null!==ut&&ut(Mt[e],e))},[Et,Mt,ut]),pa=(0,a.useCallback)(function(e){var t=e.index,l=e.newIndex,a=e.end,n=e.direction;a&&null!==it&&it(),fa(l),It.emit("navigate",{index:t,newIndex:l,direction:n,end:a}),a?It.emit("navigate_end"):It.emit("navigate_".concat(n),l)},[it,fa]),ba=(0,a.useCallback)(function(){fa(Math.max(0,Et-1))},[fa,Et]),xa=(0,a.useCallback)(function(){fa(Math.min(Mt.length-1,Et+1))},[fa,Et]),Aa=(0,a.useState)(!1),Sa=(0,R.A)(Aa,2),Ca=Sa[0],wa=Sa[1],ka=(0,a.useState)(!1),ja=(0,R.A)(ka,2),Ma=ja[0],Na=ja[1],Ra=(0,a.useCallback)(function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).target,t=void 0===e?null:e;null!==at&&at(),Ca||wa(!0),Ke||Ma||null===Bl||null!==t&&js(t)||(Bl(!1),Na(!0))},[at,Ca,wa,Ke,Bl,Ma]),za=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.screens,l=e.screenIndex,n=e.screenWidth,o=e.disableCurrentScreenNavigation,r=void 0!==o&&o,s=e.clickOnSiblings,u=void 0!==s&&s,d=e.nextScreenWidthPercent,c=void 0===d?.5:d,m=e.onInteract,v=void 0===m?null:m,g=e.onNavigate,y=void 0===g?null:g,f=(0,a.useState)(t.reduce(function(e,t){var l=t.id;return(0,i.A)((0,i.A)({},e),{},(0,h.A)({},l,!0))},{})),p=(0,R.A)(f,2),b=p[0],x=p[1],A=(t[l]||{}).id,S=void 0===A?l:A,C=b[S],w=void 0===C||C,k=(0,a.useCallback)(function(e){var l=b[S];(void 0===l||l)!==e&&x(t.reduce(function(t,l){var a=l.id;return S===a?(0,i.A)((0,i.A)({},t),{},(0,h.A)({},a,e)):(0,i.A)((0,i.A)({},t),{},(0,h.A)({},a,void 0===b[a]||!0===b[a]))},{}))},[t,S,b,x]),j=(0,a.useCallback)(function(){return k(!0)},[k]),M=(0,a.useCallback)(function(){return k(!1)},[k]);return{interact:(0,a.useCallback)(function(e){var a=e.event,i=e.target,o=e.currentTarget,s=e.x,d=e.y,m=e.index;null!==v&&v({event:a,target:i,currentTarget:o,index:m,x:s,y:d});var g=t.length,h=l===m;if(!(r&&h||js(i)||h&&!w)){var f=s<(o.getBoundingClientRect().width-n)/2+n*(1-c)?"previous":"next",p=g-1,b=m;"previous"!==f||u?"next"!==f||u||(b=Math.min(p,l+1)):b=Math.max(0,l-1),null!==y&&y({index:m,newIndex:b,direction:f,end:m===b&&b===p})}},[t,l,b,w,c,r,u,v,y]),currentScreenInteractionEnabled:w,enableInteraction:j,disableInteraction:M}}({screens:Mt,screenIndex:Et,screenWidth:sa,disableCurrentScreenNavigation:!gl,nextScreenWidthPercent:N,onInteract:Ra,onNavigate:pa}),$a=za.interact,La=za.currentScreenInteractionEnabled,Ia=za.enableInteraction,Pa=za.disableInteraction,Ba=(0,a.useState)(null),Ea=(0,R.A)(Ba,2),Va=Ea[0],Da=Ea[1],Oa=(0,a.useState)(!1),Ha=(0,R.A)(Oa,2),Za=Ha[0],Wa=Ha[1];(0,a.useEffect)(function(){Wa(!1),Da(null)},[Et]),(0,a.useEffect)(function(){var e=(Ml||{}).tagName;if(null===Va||!bl||"VIDEO"!==e)return function(){};var t=setTimeout(function(){Al(!1),Wa(!0)},$);return function(){return clearInterval(t)}},[bl,Va,$,Ml]);var qa=(0,a.useCallback)(function(){Da(Date.now())},[]),_a=(0,a.useCallback)(function(e){var t=e.currentTarget,l=e.event,a=e.target,n=(0,R.A)(e.xy,2),i=n[0],o=n[1],r=e.elapsedTime,s=(0,R.A)(e.args,1)[0];Da(null);var u=s||{},d=u.playing,c=void 0!==d&&d,m=u.longPressPaused;if(!c&&void 0!==m&&m)return Al(!0),void Wa(!1);null!==T&&r>T||$a({event:l,target:a,currentTarget:t,index:Et,x:i,y:o})},[$a,Et,T]),Ga=(0,a.useCallback)(function(e){var t=e.active,l=(0,R.A)(e.movement,1)[0],a=(0,R.A)(e.velocity,1)[0],n=l/sa,i=l<0?Et+1:Et-1,o=a>.3||Math.abs(n)>.3,r=i<0||i>=Lt,s=r?.1:1,u=Math.max(-1,Math.min(1,n*s));return t?Et-u:o&&!r?i:Et},[sa,Et]),Ya=(0,a.useCallback)(function(e,t){var l=t.active,a=(0,R.A)(t.args,1)[0]||{},n=a.playing,i=void 0!==n&&n,o=a.longPressPaused;l||i||void 0===o||!o||(Al(!0),Wa(!1));var r=Math.abs(e-Et);l||1!==r||e<0||e>=Lt||pa({index:Et,newIndex:e})},[pa,Et]),Ua=(0,a.useState)(!0),Qa=(0,R.A)(Ua,2),Xa=Qa[0],Ja=Qa[1],Ka=(0,a.useCallback)(function(){Ja(!1)},[Ja]),en=(0,a.useCallback)(function(){Ja(!0)},[Ja]),tn=(0,a.useMemo)(function(){return{config:ku,onStart:Ka,onRest:en}},[Ka,en]),ln=0===Lt||La,an=!1===La,nn=dl({progress:Et,disabled:!gl||Ze,dragDisabled:Re||!La,computeProgress:Ga,onProgress:Ya,onPointerDown:qa,onTap:_a,springParams:tn,dragOptions:{filterTaps:!0,axis:"x",pointer:{keys:!1}}}),on=nn.dragging,rn=nn.transitioning,sn=nn.progress,un=nn.bind,dn=nn.direction,cn=(0,a.useMemo)(function(){for(var e=un({playing:bl,longPressPaused:Za}),t={},l=function(){var e=(0,R.A)(n[a],2),l=e[0],i=e[1];t[l]="function"==typeof i?function(e){if(!js(e.target))return i(e)}:i},a=0,n=Object.entries(e);a<n.length;a++)l();return t},[un,bl,Za]),mn=function(e){var t=tl().isEnabled,l=(0,a.useState)(!1),n=(0,R.A)(l,2),i=n[0],o=n[1],r=(0,a.useCallback)(function(){tl().isEnabled&&(null!=e?tl().request(e):tl().request())},[e]),s=(0,a.useCallback)(function(){tl().isEnabled&&tl().exit()},[]),u=(0,a.useCallback)(function(){i?s():r()},[i,r,s]);return(0,a.useEffect)(function(){var e=function(){o(tl().isFullscreen)};return tl().isEnabled&&tl().on("change",e),function(){tl().isEnabled&&tl().off("change",e)}},[]),{toggle:u,fullscreen:r,unFullscreen:s,active:i,enabled:t}}(Gl.current||null),vn=mn.toggle,gn=mn.active,yn=mn.enabled,hn=pl(),fn=hn.ref,pn=hn.height,bn=void 0===pn?0:pn,xn=(0,a.useCallback)(function(e){var t=e.screenId;Ra();var l=Mt.findIndex(function(e){return e.id===t});fa(l)},[Ra,fa]),An=(0,a.useCallback)(function(e){return!!na||(e.preventDefault(),!1)},[na]),Sn=(0,se.jsx)("style",{type:"text/css",href:"data-viewer-overscroll",precedence:"medium",dangerouslySetInnerHTML:{__html:"body { overscroll-behavior: contain; }"}});ks((0,a.useMemo)(function(){return{f:function(){return vn()},arrowleft:function(){Ms(document.activeElement)||ba()},arrowright:function(){Ms(document.activeElement)||xa()}}},[ba,xa]),{disabled:"view"!==j});var Cn=(0,a.useCallback)(function(){var e=document.getElementById("controls");if(e){var t=e.querySelectorAll("button[tabindex]"),l=Array.from(t).find(function(e){return e.tabIndex>=0});l&&l.focus({preventScroll:!0})}},[]),wn=(0,a.useState)(null),kn=(0,R.A)(wn,2),jn=kn[0],Mn=kn[1],Nn=(0,a.useState)(!1),Fn=(0,R.A)(Nn,2),Tn=Fn[0],Rn=Fn[1],zn=(Vt||{}).header,$n=((void 0===zn?null:zn)||{}).shareIncentive,Ln=void 0===$n?null:$n,In=Ln||{},Pn=In.active,Bn=void 0!==Pn&&Pn,En=In.label,Vn=void 0===En?null:En,Dn=(jn||{}).label,On=void 0===Dn?null:Dn,Hn=(Vn||{}).body,Zn=void 0===Hn?null:Hn,Wn=(On||{}).body,qn=void 0===Wn?null:Wn;(0,a.useEffect)(function(){Rn(!0),Bn&&Vn!==On&&Mn(Ln);var e=setTimeout(function(){gl&&Rn(!1)},6e3);return function(){clearTimeout(e)}},[Vn,Rn,Bn,Zn,qn,Mn,gl]),(0,a.useEffect)(function(){if(ga)return function(){};var e=setTimeout(function(){ya(!0)},Z);return function(){clearTimeout(e)}},[ga]);var _n=0;null!==U?_n=U/Xl:ra&&La&&(_n=bn/Xl);var Gn=0;null!==X?Gn=X/Xl:Cl&&(kl||!bl)&&La&&(Gn=Hl/Xl);var Yn="hand"===Ue?gu:mu,Un=sl({element:Gl.current,disabled:!gl,timeout:2e3}).detected;return(0,a.useEffect)(function(){var e=null;return null!==fe&&gl&&Lt>1&&0!==Et&&(!(null!==Ml&&!Il)||$l)&&!on&&!Un&&(e=setTimeout(function(){fa(0)},fe)),function(){null!==e&&clearTimeout(e)}},[fe,gl,Et,Lt,fa,Ml,$l,on,Un,Il]),(0,se.jsx)(mt,{story:wt,children:(0,se.jsx)(Pt,{size:Ql,children:(0,se.jsxs)(_t,{containerRef:Gl,events:It,menuVisible:ln,menuOverScreen:ra,width:Yl,height:Ul,topHeight:_n,bottomHeight:Gn,bottomSidesWidth:!kl&&bl&&null===Ml||!La?0:60/Xl,gotoPreviousScreen:ba,gotoNextScreen:xa,disableInteraction:Pa,enableInteraction:Ia,children:[je?(0,se.jsx)(Ta,{title:Ut,metadata:Qt,children:Sn}):Sn,(0,se.jsx)(Fa,{fonts:ml}),(0,se.jsxs)("div",{className:Jt([iu.container,Ql.screens.map(function(e){return"story-screen-".concat(e)}),St,(0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)((0,h.A)({},iu.landscape,na),iu.withoutGestures,Re),iu.hideMenu,!ln),iu.disableMenu,an),iu.fadeMenu,bl&&Cl&&!kl),iu.ready,da||hl),iu.hasInteracted,Ca),iu.isDragging,on)]),ref:Gl,onContextMenu:An,children:[(0,se.jsx)("div",{className:iu.ariaAnnouncement,id:"announce","aria-live":"polite",children:(0,se.jsx)(Wl.A,{id:"AIr8rM",defaultMessage:[{type:0,value:"Screen "},{type:1,value:"current"},{type:0,value:" of "},{type:1,value:"length"}],values:{current:Et+1,length:Mt.length}})}),(0,se.jsx)("nav",{"aria-label":Ct.formatMessage({id:"gfZs4J",defaultMessage:[{type:0,value:"Skip Links"}]}),className:iu.accessibilityLinks,children:El?(0,se.jsxs)(se.Fragment,{children:[(0,se.jsx)(Rs,{onClick:Cn,"aria-disabled":Xe||!kl,"aria-describedby":"disabledReason",className:Jt([iu.accessibilityButton,(0,h.A)({},iu.disabled,Xe||!kl)]),children:(0,se.jsx)(Wl.A,{id:"CnVj9r",defaultMessage:[{type:0,value:"Skip to controls"}]})}),Xe||!kl?(0,se.jsx)("div",{role:"tooltip",className:iu.tooltipBox,id:"disabledReason",children:(0,se.jsx)("span",{className:iu.tooltip,children:(0,se.jsx)(Wl.A,{id:"YXhRxW",defaultMessage:[{type:0,value:"No controls available"}]})})}):null]}):null}),$e?null:(0,se.jsx)(ru,{story:wt,currentScreenIndex:Et,withShadow:ra&&!Ve,toggleFullscreen:vn,fullscreenActive:gn,fullscreenEnabled:yn,menuDotsButtons:be,closeable:Ae,shareBasePath:ue||u,shareOptions:ce,screenSize:Ql,menuWidth:K?sa:null,theme:c,previewHeader:te,previewFooter:ae,trackingEnabled:ca,onClickScreen:xn,onClickCloseViewer:tt,onChange:gt,withDotItemClick:sa>400,withoutScreensMenu:Ie,withoutShareMenu:Be,menuItems:oe,afterShareMenuButton:ve,beforeScreensMenuButton:ye,withMicromagBranding:Fe,refDots:fn}),da||hl?(0,se.jsxs)("div",(0,i.A)((0,i.A)({className:iu.content},cn),{},{children:[!Oe&&!qe&&!an&&Et>0&&Mt.length>1?(0,se.jsx)(cu,{direction:"previous",className:Jt([iu.navButton,iu.previous]),onClick:ba,ariaLabel:Ct.formatMessage({id:"zYH/31",defaultMessage:[{type:0,value:"Go to previous screen"}]})}):null,(0,se.jsx)("div",{className:iu.screensFrame,style:{width:sa,height:ua,overflow:qe?null:"hidden"},children:Mt.map(function(e,t){var l,a,n=Et===t,i=t<Et,o=t>Et,r=0!==dn&&t===Et+dn,s=B,u=Math.abs(t-Et)<=s,d=null!==G?G:B,c=Math.abs(t-Et)<=d,m=n||u||r,v=n||ga&&(o&&c||q&&i&&c)||r,g=(l=t,a=sn,"stack"===ha?{zIndex:l,opacity:a.to(function(e){var t=l-e,a=Math.min(1,Math.max(0,-t));return Math.abs(t)>B?0:Math.min(Math.max(0,1-.75*a+(t+1)),1)}),transform:a.to(function(e){var t=l-e,a=Math.min(1,Math.max(0,t)),n=Math.min(1,Math.max(0,-t));return Math.abs(t)>B?"translateX(100%)":"translateX(".concat(100*a,"%) scale(").concat(1-.2*n,")")}),boxShadow:a.to(function(e){var t=l-e;if(Math.abs(t)>B)return null;var a=Math.min(1,Math.max(0,t));return"0 0 ".concat(2*(1-a),"rem ").concat(-.5*(1-a),"rem black")})}:{opacity:a.to(function(e){var t=l-e;return Math.abs(t)>B?0:1-.75*Math.min(1,Math.max(0,Math.abs(t)))}),transform:a.to(function(e){var t=l-e;if(Math.abs(t)>B)return"translate(100%)";var a=Math.min(1,Math.max(0,Math.abs(t)));return"translateX(".concat(t*V,"%) scale(").concat(1-(1-O)*a,")")}),zIndex:Lt-l}),y=n||on&&r||0!==dn&&!on&&t===Et-dn||qe&&m;return(0,se.jsx)(oa.CS.div,{id:n?"content":null,"aria-hidden":!n,style:g,tabIndex:n?0:-1,className:Jt([iu.screenContainer,(0,h.A)((0,h.A)((0,h.A)({},iu.visible,y),iu.preload,v),iu.current,n&&!rn)]),children:null!==e?(0,se.jsx)(su,{className:iu.screen,screen:e,screenState:n?x:null,index:t,current:n,active:m||n,ready:n&&Xa,preload:v||n,mediaRef:function(e){Xt.current[t]=e},renderContext:j,width:ea,height:la,scale:Xl}):null},"screen-viewer-".concat(e.id||"","-").concat(t+1))})}),!Oe&&!qe&&!an&&Et<Mt.length-1?(0,se.jsx)(cu,{direction:"next",className:Jt([iu.navButton,iu.next]),onClick:xa,ariaLabel:Ct.formatMessage({id:"v9bqYj",defaultMessage:[{type:0,value:"Go to next screen"}]})}):null,Xe?null:(0,se.jsx)("div",(0,i.A)((0,i.A)({className:iu.playbackControls,id:"controls",ref:Dl},Ns),{},{children:(0,se.jsx)(Su,{className:iu.controls,withoutShadow:Ve})})),!1===Ue||qe||an||0!==Et||Ca?null:(0,se.jsx)(Yn,{className:iu.navigationHint,withoutShadow:Ve})]})):null,(0,se.jsx)("div",{className:Jt([iu.shareIncentiveContainer,(0,h.A)({},iu.shareIncentiveVisible,Bn&&Tn)]),style:{top:yl?10:bn-10},children:(0,se.jsx)(As,(0,i.A)({className:iu.shareIncentive},jn))}),(0,se.jsx)(wu,{className:iu.webView,trackingEnabled:ca,style:{maxWidth:Ge?null:Math.max(sa,600)}})]})]})})})}var Nu=["story","pathWithIndex","children","onScreenChange"];function Fu(e){var t=e.story,l=void 0===t?null:t,n=e.pathWithIndex,o=void 0!==n&&n;e.children;var u=e.onScreenChange,d=void 0===u?null:u,c=(0,r.A)(e,Nu),m=(0,s.Ye)(),g=(0,s.yP)(),y=(0,v.zy)(),h=(0,R.A)(y,2)[1],f=(l||{}).components,p=void 0===f?[]:f,b=(0,a.useCallback)(function(e){var t=p.findIndex(function(t){return t.id===e.id||t===e});h(g("screen",{screen:o?t+1:e.id})),null!==d&&d(e)},[h,g,o,p,d]);return(0,se.jsxs)(v.dO,{children:[(0,se.jsx)(v.qh,{path:m.screen,children:function(e){var t=e.screen,a=void 0===t?null:t,n=o&&null!==a&&p[parseInt(a,10)-1]||null,r=o?(n||{}).id||null:a;return(0,se.jsx)(Mu,(0,i.A)((0,i.A)({},c),{},{story:l,screen:r,onScreenChange:b}))}}),(0,se.jsx)(v.qh,{children:(0,se.jsx)(Mu,(0,i.A)((0,i.A)({},c),{},{story:l,onScreenChange:b}))})]})}var Tu={home:"/",screen:"/:screen"},Ru=["story","paused","muted","screenComponents","memoryRouter","basePath","routes","withoutRouter","googleApiKey","visitor","locale","locales","translations","pathWithIndex","trackingVariables","trackingDisabled","trackingPaused","settings"],zu={},$u=["fr","en"];function Lu(e){var t=e.story,l=void 0===t?null:t,n=e.paused,d=void 0!==n&&n,m=e.muted,g=void 0===m||m,y=e.screenComponents,h=void 0===y?null:y,f=e.memoryRouter,p=void 0!==f&&f,b=e.basePath,x=void 0===b?null:b,A=e.routes,S=void 0===A?Tu:A,C=e.withoutRouter,w=void 0!==C&&C,k=e.googleApiKey,j=void 0===k?null:k,M=e.visitor,N=void 0===M?null:M,F=e.locale,T=void 0===F?"en":F,z=e.locales,$=void 0===z?$u:z,L=e.translations,I=void 0===L?null:L,P=e.pathWithIndex,B=void 0!==P&&P,E=e.trackingVariables,V=void 0===E?null:E,D=e.trackingDisabled,O=void 0!==D&&D,H=e.trackingPaused,Z=void 0!==H&&H,W=e.settings,q=void 0===W?null:W,_=(0,r.A)(e,Ru),G=(0,a.useMemo)(function(){if(null===l&&null===V)return null;var e=l||{},t=e.id,a=void 0===t?null:t,n=e.document_id,r=e.slug,s=void 0===r?null:r,d=e.title,m=void 0===d?null:d,v=e.components,g=void 0===v?[]:v,y=e.organisation,h=e.settings,f=y||{},p=f.slug,b=(f.tracking||{}).codes,x=void 0===b?[]:b,A=((h||{}).tracking||{}).codes,S=void 0===A?[]:A,C=[].concat((0,o.A)(x||[]),(0,o.A)(S||[])).filter(function(e){var t=e||{},l=t.type,a=t.id;return"ga4"===l&&!u(a)}).map(function(e){return e.id});return(0,i.A)({documentId:n,storyId:a,storySlug:s,storyTitle:m,screensCount:(g||[]).length,organisationSlug:p,googleAnalyticsIds:c(C)},V)},[l,V]),Y=((l||{}).metadata||{}).language,U=void 0===Y?T:Y,Q=function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=(0,a.useState)(e),l=(0,R.A)(t,2),n=l[0],i=l[1];return(0,a.useEffect)(function(){var e=!1;return new Promise(function(e){var t=document.createElement("img");t.onload=function(){e(t.width>0&&t.height>0)},t.onerror=function(){e(!1)},t.src="data:image/webp;base64,UklGRiQAAABXRUJQVlA4IBgAAAAwAQCdASoCAAEAAQAcJaQAA3AA/v3AgAA="}).then(function(t){e||t===n||i(t)}),function(){e=!0}},[]),n}(),X=(0,a.useMemo)(function(){return(0,i.A)({supportsWebp:Q},q)},[q,Q]),J=(0,se.jsx)(ht,{settings:X,children:(0,se.jsx)(Hl,{locale:U,locales:$,extraMessages:I,children:(0,se.jsx)(bt,{apiKey:j,children:(0,se.jsx)(St,{locale:U,children:(0,se.jsx)(bs,{children:(0,se.jsx)(nt,{namespace:et,components:h||zu,children:(0,se.jsx)(Ut,{visitor:N,children:(0,se.jsx)(Nt,{paused:d,muted:g,children:(0,se.jsx)(Et,{variables:G,disabled:O,paused:Z,children:w?(0,se.jsx)(Mu,(0,i.A)({story:l,basePath:x},_)):(0,se.jsx)(Fu,(0,i.A)({story:l,basePath:x,pathWithIndex:B},_))})})})})})})})})}),K=(0,s.yr)(),ee=K.hook,te=K.searchHook,le=(0,a.useMemo)(function(){return{hook:p?ee:null,searchHook:p?te:null,base:p?null:x}},[x,p]);return w?J:(0,se.jsx)(v.Ix,(0,i.A)((0,i.A)({},le),{},{children:(0,se.jsx)(s.yF,{routes:S,children:J})}))}function Iu(e){return Iu="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Iu(e)}function Pu(e,t){var l=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),l.push.apply(l,a)}return l}function Bu(e){for(var t=1;t<arguments.length;t++){var l=null!=arguments[t]?arguments[t]:{};t%2?Pu(Object(l),!0).forEach(function(t){Eu(e,t,l[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(l)):Pu(Object(l)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(l,t))})}return e}function Eu(e,t,l){return(t=function(e){var t=function(e){if("object"!=Iu(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var l=t.call(e,"string");if("object"!=Iu(l))return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Iu(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}l(2185);var Vu=void 0!==window.MICROMAG_STORY?window.MICROMAG_STORY:null,Du=void 0!==window.MICROMAG_VIEWER_PROPS?window.MICROMAG_VIEWER_PROPS:null,Ou=void 0!==window.MICROMAG_ROOT_ELEMENT_ID?window.MICROMAG_ROOT_ELEMENT_ID:"root",Hu=void 0!==window.MICROMAG_ROOT_ELEMENT?window.MICROMAG_ROOT_ELEMENT:document.getElementById(Ou),Zu=void 0!==window.MICROMAG_RENDER_STORY_FNC?window.MICROMAG_RENDER_STORY_FNC:"renderStory",Wu=new WeakMap,qu=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Hu,i=Wu.get(l);i||(i=(0,n.createRoot)(l),Wu.set(l,i)),i.render(a.createElement(Lu,Bu(Bu({},t),{},{story:e})))};null!==Vu&&qu(Vu,Du),null!==Zu&&(window[Zu]=qu)},2185:function(e,t,l){l.p=void 0!==window.MICROMAG_PUBLIC_PATH?window.MICROMAG_PUBLIC_PATH:"/"}},function(e){e.O(0,[239],function(){return e(e.s=1056)}),e.O()}]);
|