@uob-web-and-digital/component-library 2.12.2 → 2.12.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/module.js
CHANGED
|
@@ -20,4 +20,4 @@ object-assign
|
|
|
20
20
|
* focus-trap 7.6.5
|
|
21
21
|
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
|
|
22
22
|
*/
|
|
23
|
-
function Ka(e,c){(null==c||c>e.length)&&(c=e.length);for(var a=0,t=Array(c);a<c;a++)t[a]=e[a];return t}function Ya(e,c,a){return(c=function(e){var c=function(e,c){if("object"!=typeof e||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var t=a.call(e,c);if("object"!=typeof t)return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===c?String:Number)(e)}(e,"string");return"symbol"==typeof c?c:c+""}(c))in e?Object.defineProperty(e,c,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[c]=a,e}function Ja(e,c){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);c&&(t=t.filter(function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable})),a.push.apply(a,t)}return a}function Xa(e){for(var c=1;c<arguments.length;c++){var a=null!=arguments[c]?arguments[c]:{};c%2?Ja(Object(a),!0).forEach(function(c){Ya(e,c,a[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Ja(Object(a)).forEach(function(c){Object.defineProperty(e,c,Object.getOwnPropertyDescriptor(a,c))})}return e}function Qa(e){return function(e){if(Array.isArray(e))return Ka(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,c){if(e){if("string"==typeof e)return Ka(e,c);var a={}.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?Ka(e,c):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var et,ct,at=function(e,c){if(e.length>0){var a=e[e.length-1];a!==c&&a._setPausedState(!0)}var t=e.indexOf(c);-1===t||e.splice(t,1),e.push(c)},tt=function(e,c){var a=e.indexOf(c);-1!==a&&e.splice(a,1),e.length>0&&!e[e.length-1]._isManuallyPaused()&&e[e.length-1]._setPausedState(!1)},lt=function(e){return"Tab"===(null==e?void 0:e.key)||9===(null==e?void 0:e.keyCode)},nt=function(e){return lt(e)&&!e.shiftKey},rt=function(e){return lt(e)&&e.shiftKey},it=function(e){return setTimeout(e,0)},ot=function(e){for(var c=arguments.length,a=new Array(c>1?c-1:0),t=1;t<c;t++)a[t-1]=arguments[t];return"function"==typeof e?e.apply(void 0,a):e},st=function(e){return e.target.shadowRoot&&"function"==typeof e.composedPath?e.composedPath()[0]:e.target},mt=[],ht=Kc(Object.freeze({__proto__:null,createFocusTrap:function(e,c){var a,t=(null==c?void 0:c.document)||document,l=(null==c?void 0:c.trapStack)||mt,n=Xa({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:nt,isKeyBackward:rt},c),r={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},i=function(e,c,a){return e&&void 0!==e[c]?e[c]:n[a||c]},o=function(e,c){var a="function"==typeof(null==c?void 0:c.composedPath)?c.composedPath():void 0;return r.containerGroups.findIndex(function(c){var t=c.container,l=c.tabbableNodes;return t.contains(e)||(null==a?void 0:a.includes(t))||l.find(function(c){return c===e})})},s=function(e){var c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=c.hasFallback,l=void 0!==a&&a,r=c.params,i=void 0===r?[]:r,o=n[e];if("function"==typeof o&&(o=o.apply(void 0,Qa(i))),!0===o&&(o=void 0),!o){if(void 0===o||!1===o)return o;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var s=o;if("string"==typeof o){try{s=t.querySelector(o)}catch(c){throw new Error("`".concat(e,'` appears to be an invalid selector; error="').concat(c.message,'"'))}if(!s&&!l)throw new Error("`".concat(e,"` as selector refers to no known node"))}return s},m=function(){var e=s("initialFocus",{hasFallback:!0});if(!1===e)return!1;if(void 0===e||e&&!Wa(e,n.tabbableOptions))if(o(t.activeElement)>=0)e=t.activeElement;else{var c=r.tabbableGroups[0];e=c&&c.firstTabbableNode||s("fallbackFocus")}else null===e&&(e=s("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},h=function(){if(r.containerGroups=r.containers.map(function(e){var c=$a(e,n.tabbableOptions),a=Ra(e,n.tabbableOptions),t=c.length>0?c[0]:void 0,l=c.length>0?c[c.length-1]:void 0,r=a.find(function(e){return ja(e)}),i=a.slice().reverse().find(function(e){return ja(e)}),o=!!c.find(function(e){return Va(e)>0});return{container:e,tabbableNodes:c,focusableNodes:a,posTabIndexesFound:o,firstTabbableNode:t,lastTabbableNode:l,firstDomTabbableNode:r,lastDomTabbableNode:i,nextTabbableNode:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],l=c.indexOf(e);return l<0?t?a.slice(a.indexOf(e)+1).find(function(e){return ja(e)}):a.slice(0,a.indexOf(e)).reverse().find(function(e){return ja(e)}):c[l+(t?1:-1)]}}}),r.tabbableGroups=r.containerGroups.filter(function(e){return e.tabbableNodes.length>0}),r.tabbableGroups.length<=0&&!s("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(r.containerGroups.find(function(e){return e.posTabIndexesFound})&&r.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},d=function(e){var c=e.activeElement;if(c)return c.shadowRoot&&null!==c.shadowRoot.activeElement?d(c.shadowRoot):c},u=function(e){!1!==e&&e!==d(document)&&(e&&e.focus?(e.focus({preventScroll:!!n.preventScroll}),r.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):u(m()))},v=function(e){var c=s("setReturnFocus",{params:[e]});return c||!1!==c&&e},p=function(e){var c=e.target,a=e.event,t=e.isBackward,l=void 0!==t&&t;c=c||st(a),h();var i=null;if(r.tabbableGroups.length>0){var m=o(c,a),d=m>=0?r.containerGroups[m]:void 0;if(m<0)i=l?r.tabbableGroups[r.tabbableGroups.length-1].lastTabbableNode:r.tabbableGroups[0].firstTabbableNode;else if(l){var u=r.tabbableGroups.findIndex(function(e){var a=e.firstTabbableNode;return c===a});if(u<0&&(d.container===c||Wa(c,n.tabbableOptions)&&!ja(c,n.tabbableOptions)&&!d.nextTabbableNode(c,!1))&&(u=m),u>=0){var v=0===u?r.tabbableGroups.length-1:u-1,p=r.tabbableGroups[v];i=Va(c)>=0?p.lastTabbableNode:p.lastDomTabbableNode}else lt(a)||(i=d.nextTabbableNode(c,!1))}else{var f=r.tabbableGroups.findIndex(function(e){var a=e.lastTabbableNode;return c===a});if(f<0&&(d.container===c||Wa(c,n.tabbableOptions)&&!ja(c,n.tabbableOptions)&&!d.nextTabbableNode(c))&&(f=m),f>=0){var g=f===r.tabbableGroups.length-1?0:f+1,E=r.tabbableGroups[g];i=Va(c)>=0?E.firstTabbableNode:E.firstDomTabbableNode}else lt(a)||(i=d.nextTabbableNode(c))}}else i=s("fallbackFocus");return i},f=function(e){var c=st(e);o(c,e)>=0||(ot(n.clickOutsideDeactivates,e)?a.deactivate({returnFocus:n.returnFocusOnDeactivate}):ot(n.allowOutsideClick,e)||e.preventDefault())},g=function(e){var c=st(e),a=o(c,e)>=0;if(a||c instanceof Document)a&&(r.mostRecentlyFocusedNode=c);else{var t;e.stopImmediatePropagation();var l=!0;if(r.mostRecentlyFocusedNode)if(Va(r.mostRecentlyFocusedNode)>0){var i=o(r.mostRecentlyFocusedNode),s=r.containerGroups[i].tabbableNodes;if(s.length>0){var h=s.findIndex(function(e){return e===r.mostRecentlyFocusedNode});h>=0&&(n.isKeyForward(r.recentNavEvent)?h+1<s.length&&(t=s[h+1],l=!1):h-1>=0&&(t=s[h-1],l=!1))}}else r.containerGroups.some(function(e){return e.tabbableNodes.some(function(e){return Va(e)>0})})||(l=!1);else l=!1;l&&(t=p({target:r.mostRecentlyFocusedNode,isBackward:n.isKeyBackward(r.recentNavEvent)})),u(t||(r.mostRecentlyFocusedNode||m()))}r.recentNavEvent=void 0},E=function(e){(n.isKeyForward(e)||n.isKeyBackward(e))&&function(e){var c=arguments.length>1&&void 0!==arguments[1]&&arguments[1];r.recentNavEvent=e;var a=p({event:e,isBackward:c});a&&(lt(e)&&e.preventDefault(),u(a))}(e,n.isKeyBackward(e))},_=function(e){var c;"Escape"!==(null==(c=e)?void 0:c.key)&&"Esc"!==(null==c?void 0:c.key)&&27!==(null==c?void 0:c.keyCode)||!1===ot(n.escapeDeactivates,e)||(e.preventDefault(),a.deactivate())},b=function(e){var c=st(e);o(c,e)>=0||ot(n.clickOutsideDeactivates,e)||ot(n.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},w=function(){if(r.active)return at(l,a),r.delayInitialFocusTimer=n.delayInitialFocus?it(function(){u(m())}):u(m()),t.addEventListener("focusin",g,!0),t.addEventListener("mousedown",f,{capture:!0,passive:!1}),t.addEventListener("touchstart",f,{capture:!0,passive:!1}),t.addEventListener("click",b,{capture:!0,passive:!1}),t.addEventListener("keydown",E,{capture:!0,passive:!1}),t.addEventListener("keydown",_),a},q=function(){if(r.active)return t.removeEventListener("focusin",g,!0),t.removeEventListener("mousedown",f,!0),t.removeEventListener("touchstart",f,!0),t.removeEventListener("click",b,!0),t.removeEventListener("keydown",E,!0),t.removeEventListener("keydown",_),a},y="undefined"!=typeof window&&"MutationObserver"in window?new MutationObserver(function(e){e.some(function(e){return Array.from(e.removedNodes).some(function(e){return e===r.mostRecentlyFocusedNode})})&&u(m())}):void 0,M=function(){y&&(y.disconnect(),r.active&&!r.paused&&r.containers.map(function(e){y.observe(e,{subtree:!0,childList:!0})}))};return a={get active(){return r.active},get paused(){return r.paused},activate:function(e){if(r.active)return this;var c=i(e,"onActivate"),a=i(e,"onPostActivate"),l=i(e,"checkCanFocusTrap");l||h(),r.active=!0,r.paused=!1,r.nodeFocusedBeforeActivation=d(t),null==c||c();var n=function(){l&&h(),w(),M(),null==a||a()};return l?(l(r.containers.concat()).then(n,n),this):(n(),this)},deactivate:function(e){if(!r.active)return this;var c=Xa({onDeactivate:n.onDeactivate,onPostDeactivate:n.onPostDeactivate,checkCanReturnFocus:n.checkCanReturnFocus},e);clearTimeout(r.delayInitialFocusTimer),r.delayInitialFocusTimer=void 0,q(),r.active=!1,r.paused=!1,M(),tt(l,a);var t=i(c,"onDeactivate"),o=i(c,"onPostDeactivate"),s=i(c,"checkCanReturnFocus"),m=i(c,"returnFocus","returnFocusOnDeactivate");null==t||t();var h=function(){it(function(){m&&u(v(r.nodeFocusedBeforeActivation)),null==o||o()})};return m&&s?(s(v(r.nodeFocusedBeforeActivation)).then(h,h),this):(h(),this)},pause:function(e){return r.active?(r.manuallyPaused=!0,this._setPausedState(!0,e)):this},unpause:function(e){return r.active?(r.manuallyPaused=!1,l[l.length-1]!==this?this:this._setPausedState(!1,e)):this},updateContainerElements:function(e){var c=[].concat(e).filter(Boolean);return r.containers=c.map(function(e){return"string"==typeof e?t.querySelector(e):e}),r.active&&h(),M(),this}},Object.defineProperties(a,{_isManuallyPaused:{value:function(){return r.manuallyPaused}},_setPausedState:{value:function(e,c){if(r.paused===e)return this;if(r.paused=e,e){var a=i(c,"onPause"),t=i(c,"onPostPause");null==a||a(),q(),M(),null==t||t()}else{var l=i(c,"onUnpause"),n=i(c,"onPostUnpause");null==l||l(),h(),w(),M(),null==n||n()}return this}}}),a.updateContainerElements(e),a}})),dt=Kc(Ga);var ut=function(){if(ct)return et;function c(e){return c="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},c(e)}function a(e,c,a){return c&&function(e,c){for(var a=0;a<c.length;a++){var t=c[a];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(e,i(t.key),t)}}(e.prototype,c),Object.defineProperty(e,"prototype",{writable:!1}),e}function t(e,a,t){return a=n(a),function(e,a){if(a&&("object"==c(a)||"function"==typeof a))return a;if(void 0!==a)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,l()?Reflect.construct(a,t||[],n(e).constructor):a.apply(e,t))}function l(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(l=function(){return!!e})()}function n(e){return n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}function r(e,c){return r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,c){return e.__proto__=c,e},r(e,c)}function i(e){var a=function(e,a){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var l=t.call(e,a);if("object"!=c(l))return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===a?String:Number)(e)}(e,"string");return"symbol"==c(a)?a:a+""}ct=1;var o=e,s=ya(),m=ht.createFocusTrap,h=dt.isFocusable,d=function(e){function c(e){var a;!function(e,c){if(!(e instanceof c))throw new TypeError("Cannot call a class as a function")}(this,c),function(e,c,a){(c=i(c))in e?Object.defineProperty(e,c,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[c]=a}(a=t(this,c,[e]),"getNodeForOption",function(e){var c,a=null!==(c=this.internalOptions[e])&&void 0!==c?c:this.originalOptions[e];if("function"==typeof a){for(var t=arguments.length,l=new Array(t>1?t-1:0),n=1;n<t;n++)l[n-1]=arguments[n];a=a.apply(void 0,l)}if(!0===a&&(a=void 0),!a){if(void 0===a||!1===a)return a;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var r,i=a;if("string"==typeof a&&!(i=null===(r=this.getDocument())||void 0===r?void 0:r.querySelector(a)))throw new Error("`".concat(e,"` as selector refers to no known node"));return i}),a.handleDeactivate=a.handleDeactivate.bind(a),a.handlePostDeactivate=a.handlePostDeactivate.bind(a),a.handleClickOutsideDeactivates=a.handleClickOutsideDeactivates.bind(a),a.internalOptions={returnFocusOnDeactivate:!1,checkCanReturnFocus:null,onDeactivate:a.handleDeactivate,onPostDeactivate:a.handlePostDeactivate,clickOutsideDeactivates:a.handleClickOutsideDeactivates},a.originalOptions={returnFocusOnDeactivate:!0,onDeactivate:null,onPostDeactivate:null,checkCanReturnFocus:null,clickOutsideDeactivates:!1};var l=e.focusTrapOptions;for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&("returnFocusOnDeactivate"!==n&&"onDeactivate"!==n&&"onPostDeactivate"!==n&&"checkCanReturnFocus"!==n&&"clickOutsideDeactivates"!==n?a.internalOptions[n]=l[n]:a.originalOptions[n]=l[n]);return a.outsideClick=null,a.focusTrapElements=e.containerElements||[],a.updatePreviousElement(),a}return function(e,c){if("function"!=typeof c&&null!==c)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(c&&c.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),c&&r(e,c)}(c,e),a(c,[{key:"getDocument",value:function(){return this.props.focusTrapOptions.document||("undefined"!=typeof document?document:void 0)}},{key:"getReturnFocusNode",value:function(){var e=this.getNodeForOption("setReturnFocus",this.previouslyFocusedElement);return e||!1!==e&&this.previouslyFocusedElement}},{key:"updatePreviousElement",value:function(){var e=this.getDocument();e&&(this.previouslyFocusedElement=e.activeElement)}},{key:"deactivateTrap",value:function(){this.focusTrap&&this.focusTrap.active&&this.focusTrap.deactivate({returnFocus:!1,checkCanReturnFocus:null,onDeactivate:this.originalOptions.onDeactivate})}},{key:"handleClickOutsideDeactivates",value:function(e){var c="function"==typeof this.originalOptions.clickOutsideDeactivates?this.originalOptions.clickOutsideDeactivates.call(null,e):this.originalOptions.clickOutsideDeactivates;return c&&(this.outsideClick={target:e.target,allowDeactivation:c}),c}},{key:"handleDeactivate",value:function(){this.originalOptions.onDeactivate&&this.originalOptions.onDeactivate.call(null),this.deactivateTrap()}},{key:"handlePostDeactivate",value:function(){var e=this,c=function(){var c=e.getReturnFocusNode(),a=!(!e.originalOptions.returnFocusOnDeactivate||null==c||!c.focus||e.outsideClick&&(!e.outsideClick.allowDeactivation||h(e.outsideClick.target,e.internalOptions.tabbableOptions))),t=e.internalOptions.preventScroll,l=void 0!==t&&t;a&&c.focus({preventScroll:l}),e.originalOptions.onPostDeactivate&&e.originalOptions.onPostDeactivate.call(null),e.outsideClick=null};this.originalOptions.checkCanReturnFocus?this.originalOptions.checkCanReturnFocus.call(null,this.getReturnFocusNode()).then(c,c):c()}},{key:"setupFocusTrap",value:function(){this.focusTrap?this.props.active&&!this.focusTrap.active&&(this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()):this.focusTrapElements.some(Boolean)&&(this.focusTrap=this.props._createFocusTrap(this.focusTrapElements,this.internalOptions),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause())}},{key:"componentDidMount",value:function(){this.props.active&&this.setupFocusTrap()}},{key:"componentDidUpdate",value:function(e){if(this.focusTrap){e.containerElements!==this.props.containerElements&&this.focusTrap.updateContainerElements(this.props.containerElements);var c=!e.active&&this.props.active,a=e.active&&!this.props.active,t=!e.paused&&this.props.paused,l=e.paused&&!this.props.paused;if(c&&(this.updatePreviousElement(),this.focusTrap.activate()),a)return void this.deactivateTrap();t&&this.focusTrap.pause(),l&&this.focusTrap.unpause()}else e.containerElements!==this.props.containerElements&&(this.focusTrapElements=this.props.containerElements),this.props.active&&(this.updatePreviousElement(),this.setupFocusTrap())}},{key:"componentWillUnmount",value:function(){this.deactivateTrap()}},{key:"render",value:function(){var e=this,c=this.props.children?o.Children.only(this.props.children):void 0;if(c){if(c.type&&c.type===o.Fragment)throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");return o.cloneElement(c,{ref:function(a){var t=e.props.containerElements;c&&("function"==typeof c.ref?c.ref(a):c.ref&&(c.ref.current=a)),e.focusTrapElements=t||[a]}})}return null}}])}(o.Component),u="undefined"==typeof Element?Function:Element;return d.propTypes={active:s.bool,paused:s.bool,focusTrapOptions:s.shape({document:s.object,onActivate:s.func,onPostActivate:s.func,checkCanFocusTrap:s.func,onPause:s.func,onPostPause:s.func,onUnpause:s.func,onPostUnpause:s.func,onDeactivate:s.func,onPostDeactivate:s.func,checkCanReturnFocus:s.func,initialFocus:s.oneOfType([s.instanceOf(u),s.string,s.bool,s.func]),fallbackFocus:s.oneOfType([s.instanceOf(u),s.string,s.func]),escapeDeactivates:s.oneOfType([s.bool,s.func]),clickOutsideDeactivates:s.oneOfType([s.bool,s.func]),returnFocusOnDeactivate:s.bool,setReturnFocus:s.oneOfType([s.instanceOf(u),s.string,s.bool,s.func]),allowOutsideClick:s.oneOfType([s.bool,s.func]),preventScroll:s.bool,tabbableOptions:s.shape({displayCheck:s.oneOf(["full","legacy-full","non-zero-area","none"]),getShadowRoot:s.oneOfType([s.bool,s.func])}),trapStack:s.array,isKeyForward:s.func,isKeyBackward:s.func}),containerElements:s.arrayOf(s.instanceOf(u)),children:s.oneOfType([s.element,s.instanceOf(u)])},d.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:m},et=d}(),vt=Gc(ut);h();var pt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.onClick,n=c.label,r=c.level,i=c.autoFocus,o=void 0!==i&&i;return e.createElement("button",{className:p("nav-link",t&&"theme-".concat(t),"nav-link--".concat(r)),onClick:l,autoFocus:o},e.createElement("span",{className:"nav-link__label"},n,e.createElement("span",{className:"nav-link__icon"},e.createElement(_,{icon:"chevron-right",theme:t,ariaHidden:!0}))))};h();var ft=function(c){var a=c.theme,n=void 0===a?"uobmain":a,r=c.url,i=c.label,o=c.level,s=c.autoFocus,m=void 0!==s&&s,h=c.externalLink,d=void 0!==h&&h,u=l(null);return t(function(){m&&u.current&&u.current.focus()},[m]),e.createElement("a",{className:p("page-link",n&&"theme-".concat(n),"page-link--".concat(o)),href:r,ref:u,target:d?"_blank":"_self",rel:d?"noopener noreferrer":""},i)};function gt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.image,i=c.tag,o=c.title,s=c.href,m=c.linkText,h=c.description,u=c.type;return e.createElement("div",{className:p("card-menu",u&&"card-menu--".concat(u),t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("figure",{className:"card-menu__figure"},e.createElement("div",{className:"card-menu__image-wrapper"},e.createElement(L,d({},r,{altText:"",loadingAttr:"lazy"}))),e.createElement("figcaption",{className:"card-menu__text-content"},"secondary"===u&&e.createElement(e.Fragment,null,e.createElement("p",{className:"card-menu__tag card-menu__tag"},i),e.createElement("a",{className:"card-menu__link",href:s},e.createElement("h2",{className:"card-menu__title"},o))),"primary"===u?e.createElement(e.Fragment,null,e.createElement("h2",{className:"card-menu__title"},o),e.createElement("p",{className:"card-menu__description"},h),e.createElement("div",{className:"card-menu__cta"},e.createElement(y,{theme:t,url:s,title:m||o}))):e.createElement("div",{className:"card-menu__arrow"},e.createElement(_,{icon:"arrow-right",theme:t,ariaHidden:!0})))))}h();var Et=function(c){var a=c.primaryLinks,t=c.secondaryLinks,l=c.onClickNavLink,n=c.menuCards,r=c.theme;return e.createElement("div",{className:"header__main-menu"},e.createElement("div",{className:"header__main-menu-menu-wrapper"},e.createElement("ul",{className:"header__main-menu-primary-list"},a.map(function(c,a){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(a)},key:c.label,theme:r,level:"level-one",autoFocus:0===a}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:r,level:"level-one",autoFocus:0===a,externalLink:c.externalLink})})),e.createElement("ul",{className:"header__main-menu-secondary-list"},t.map(function(c,t){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(t+a.length)},key:c.label,theme:r,level:"level-two"}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:r,level:"level-two",externalLink:c.externalLink})}))),e.createElement("ul",{className:"header__main-menu-promo-cards"},n&&n.map(function(c,a){return e.createElement("li",{key:a},e.createElement(gt,{theme:r,image:{src:{small:c.image.src.small,medium:c.image.src.medium,default:c.image.src.default}},description:c.description,tag:c.tag,title:c.title,linkText:c.linkText,href:c.href,type:c.type}))})))};h();var _t=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.label,i=c.onClick;return e.createElement("button",{className:p("reverse-link-with-arrow",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse")),onClick:i},e.createElement("span",{className:"reverse-link-with-arrow__title"},e.createElement("span",{className:"reverse-link-with-arrow__icon"},e.createElement(_,{icon:"arrow-left",theme:t,inverse:n,ariaHidden:!0})),r))},bt=function(c){var a=c.headingLink,t=c.onClickGoBack,l=c.onClickNavLink,n=c.theme,r=c.backLinkLabel;return e.createElement("div",{className:"header__nested-menu"},e.createElement(_t,{label:r,onClick:t,theme:n}),e.createElement("div",{className:"header__heading-link"},e.createElement(ft,{theme:n,url:a.url,label:a.label,level:"level-one",autoFocus:!0})),e.createElement("div",{className:"header__content-wrapper"},a.description&&e.createElement("p",{className:"header__description"},a.description),a.children&&e.createElement("ul",{className:p("header__link-list",a.description&&"header__link-list--with-desc")},a.children.map(function(c,a){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(a)},key:c.label,theme:n,level:"level-two"}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:n,level:"level-two",externalLink:c.externalLink})}))))};h();var wt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.fieldName,i=c.hiddenLabel,o=void 0!==i&&i,s=c.defaultValue,m=c.placeholder,h=c.required,d=void 0!==h&&h,u=c.onChange;return e.createElement("div",{className:p("form-input",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("label",{htmlFor:r,className:p("form-input__label",o&&"sr-only")},"Select ",r),e.createElement("input",{className:"form-input__input",id:r,name:r,type:"text",required:d,defaultValue:s,placeholder:m,onChange:u}))},qt=function(c){var a=c.title,t=void 0===a?"Search":a,l=c.placeholder,n=void 0===l?"Start typing":l,r=c.introText,i=c.handleSearchChange,o=c.handleSearchSubmit,s=c.theme,m=c.inverse,h=c.onClickGoBack,d=c.backLinkLabel,u=c.recommendedLinks,v=c.recommendedLinkTitle;return e.createElement("div",{className:"header-search"},h&&d&&e.createElement("div",{className:"header-search__back-link"},e.createElement(_t,{label:d,onClick:h,theme:s})),e.createElement("div",{className:"header-search__container"},e.createElement("h2",{className:"header-search__title"},t),e.createElement("p",{className:"header-search__intro"},r),e.createElement("form",{className:"header-search__form",method:"post",onSubmit:o},e.createElement("div",{className:"header-search__search-wrapper"},e.createElement(wt,{theme:s,inverse:!1,fieldName:"search",hiddenLabel:!0,placeholder:n,onChange:i}),e.createElement(Oe,{theme:s,inverse:!m,title:"Search",icon:"search",isSubmit:!0})),e.createElement(q,{theme:s,inverse:!m,label:"Search",isSubmit:!0}))),u&&e.createElement("div",{className:"header-search__recommended-links-wrapper"},v&&e.createElement("h3",{className:"header-search__recommended-link-title"},v),e.createElement("ul",{className:"header-search__recommended-links"},u.map(function(c,a){return e.createElement("li",{className:"header-search__recommended-link",key:a},e.createElement(Sc,{theme:s,url:c.url,title:c.label,externalLink:c.externalLink}))}))))};function yt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.label,n=c.url,r=c.externalLink,i=c.active,o=void 0!==i&&i;return e.createElement("a",{className:p("campus-selector-link",t&&"theme-".concat(t),o&&"campus-selector-link--active"),href:n,target:r?"_blank":"_self",rel:"noreferrer"},l)}function Mt(c){var a=c.active,t=c.theme,l=c.ukUrl,n=c.dubaiUrl,r=c.mobile;return e.createElement("div",{className:p("campus-selector",t&&"theme-".concat(t),r&&"campus-selector--mobile",!r&&"campus-selector--desktop")},e.createElement("div",{className:"campus-selector__container"},e.createElement("span",{className:"campus-selector__label"},"Select campus:"),r?e.createElement(e.Fragment,null,e.createElement(q,{label:"UK",theme:t,inverse:!0,url:l,hollow:"uk"!==a}),e.createElement(q,{label:"Dubai",theme:t,inverse:!0,url:n,hollow:"dubai"!==a})):e.createElement(e.Fragment,null,e.createElement(yt,{label:"UK",theme:t,url:l,active:"uk"===a}),e.createElement(yt,{label:"Dubai",theme:t,url:n,active:"dubai"===a}))))}h(),h(),h();var Nt=function(c){var n=c.theme,r=void 0===n?"uobmain":n,o=c.primaryLinks,s=c.secondaryLinks,h=c.menuCards,d=c.dubaiUrl,v=c.ukUrl,f=c.logoTitleTagH1,g=void 0===f||f,E=c.activeCampus,_=void 0===E?"uk":E,b=c.searchProps,w=function(){var e=a(null),c=e[0],l=e[1];return t(function(){var e=window.scrollY,a=function(){var a=window.scrollY,t=a>e?"down":"up";t!==c&&(a-e>3||a-e<-3)&&l(t),e=a>0?a:0};return window.addEventListener("scroll",a),function(){window.removeEventListener("scroll",a)}},[c]),c}(),y=a(!1),M=y[0],N=y[1],C=l(null),k=l(null),x=l(null),T=xe("768px"),L=a(0),z=L[0],H=L[1],V=a(null),S=V[0],P=V[1],O=a(null),Z=O[0],B=O[1],F=a(!1),D=F[0],I=F[1],A=a(!1),$=A[0],R=A[1],j=a(""),U=j[0],W=j[1],G=function(){N(!0),document.body.classList.add("lock-scroll")},K=function(){I(!0),G()},Y=function(){I(!1),R(!1)},J=function(){N(!1),Y(),document.body.classList.remove("lock-scroll"),H(0),P(null),B(null),C.current&&C.current.focus()},X=function(){H(0),P(null),Y()},Q=function(){H(1),B(null),Y()},ee=function(e){"Escape"===e.key&&M&&J()};t(function(){return document.addEventListener("keydown",ee),function(){document.removeEventListener("keydown",ee)}}),t(function(){if(k.current&&"down"===w){var e=k.current.offsetHeight;k.current.style.top="-".concat(e,"px")}else if(k.current&&"up"===w){var c=0;x.current&&k.current&&(c=x.current.offsetHeight),k.current.style.top="-".concat(c,"px")}},[w]);var ce=null,ae=null;null!==S&&(ce=u(u([],o,!0),s,!0)[S],null!==Z&&ce.children&&(ae=ce.children[Z]));var te=e.createElement("div",{className:"header__campus-selector header__campus-selector--mobile"},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!0})),le=e.createElement("div",{className:"header__campus-selector header__campus-selector--desktop",ref:x},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!1})),ne=e.createElement("div",{className:"header__campus-selector header__campus-selector--desktop"},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!1})),re=function(e){W(e.target.value)},ie=function(e){if(e.preventDefault(),"undefined"!=typeof window){var c=b.resultsUrl;window.location.href=U?"".concat(c,"?term=").concat(U):"".concat(c)}};return e.createElement("header",{className:p("header",r&&"theme-".concat(r),!M&&"header--is-closed","header--".concat(_)),id:"header",ref:k},e.createElement("div",{className:"header__closed"},le,e.createElement("div",{className:"header__top-container"},e.createElement("div",{className:"header__logo-wrapper"},e.createElement("div",{className:"header__logo-wrapper"},g?e.createElement("h1",{className:"header__logo-heading"},e.createElement(Zc,{activeCampus:_,imageMode:"light",classNames:"header__logo-link",imageAltText:"uk"===_?"University of Birmingham":"University of Birmingham Dubai"})):e.createElement(Zc,{activeCampus:_,imageMode:"light",classNames:"header__logo-link"},e.createElement("span",{className:"sr-only"},"uk"===_?"University of Birmingham":"University of Birmingham Dubai")))),e.createElement("div",{className:"header__right-wrapper"},e.createElement("div",{className:"header__search-button"},e.createElement(q,{theme:r,label:"Search",onClick:function(){R(!0),K()},hollow:!0})),e.createElement("div",{className:"header__menu-button"},e.createElement("span",null,"Menu"),e.createElement(Oe,{theme:"uobmain",icon:"hamburger",onClick:G,title:"Open menu",ariaControls:"header",ref:C,ariaExpanded:M}))))),e.createElement(m,null,M&&e.createElement(vt,null,e.createElement(i.div,{className:"header__open",initial:{x:"100%"},animate:{x:"0"},exit:{x:"100%"},transition:{type:"tween"},key:"header__open"},ne,e.createElement("div",{className:"header__top-container"},e.createElement("div",{className:"header__logo-wrapper"},e.createElement(Zc,{activeCampus:_,imageMode:"dark",classNames:"header__logo-link"},e.createElement("h1",{className:"sr-only"},"uk"===_?"University of Birmingham":"University of Birmingham Dubai"))),e.createElement("div",{className:"header__right-wrapper"},!T&&!D&&e.createElement("div",{className:"header__search-button-menu"},e.createElement(q,{theme:r,inverse:!0,label:"Search",onClick:K,hollow:!0})),e.createElement("div",{className:"header__menu-button"},e.createElement("span",null,"Menu"),e.createElement(Oe,{theme:"uobmain",inverse:!0,icon:"cross",onClick:J,title:"Close menu",ariaControls:"header"})))),T&&!D&&e.createElement("div",{className:"header__search-button-mobile"},e.createElement(q,{theme:r,inverse:!0,label:"Search",onClick:K,hollow:!0})),0===z&&!D&&e.createElement(Et,{primaryLinks:o,secondaryLinks:s,menuCards:h,onClickNavLink:function(e){H(1),P(e)},theme:r}),0===z&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:$?void 0:X,backLinkLabel:$?"":"Back to menu",recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),1===z&&ce&&!D&&e.createElement(bt,{headingLink:ce,onClickNavLink:function(e){H(2),B(e)},theme:r,onClickGoBack:X,backLinkLabel:"Back to menu"}),1===z&&ce&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:Q,backLinkLabel:"Back to ".concat(ce.label),recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),2===z&&ce&&ae&&!D&&e.createElement(bt,{headingLink:ae,onClickNavLink:function(){},theme:r,onClickGoBack:Q,backLinkLabel:"Back to ".concat(ce.label)}),2===z&&ce&&ae&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:function(){H(2),Y()},backLinkLabel:"Back to ".concat(ae.label),recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),te))))},Ct={mobile:{image:"polygon(0 0, calc(100% - 1px) 0, calc(75% - 1px) calc(70% - 1px), 0 calc(90% - 1px))",background:"polygon(0 0, 100% 0, 75% 70%, 0 90%)"},tablet:{image:"polygon(0 0, 100% 0, 100% calc(70% - 1px), calc(30% + 1px) calc(60% - 1px))",background:"polygon(0 0, 100% 0, 100% 70%, 30% 60%)"},desktop:{image:"polygon(1px 0, 100% 0, 100% calc(95% - 1px), calc(10% + 1px) calc(65% - 1px))",background:"polygon(0 0, 100% 0, 100% 95%, 10% 65%)"}};function kt(c){var a,n,o=c.isMobile,s=c.isTablet,m=c.image,h=o?Ct.mobile:s?Ct.tablet:Ct.desktop,d=l(null),u=r();return t(function(){var e;d.current&&d.current.setAttribute("fetchpriority",null!==(e=m.fetchPriority)&&void 0!==e?e:"auto")}),e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__polygon-image-wrapper"},e.createElement(i.img,{ref:d,className:"hero__image",src:m.src.default,srcSet:"".concat(null!==(a=m.src.small)&&void 0!==a?a:m.src.default," 576w, ").concat(null!==(n=m.src.medium)&&void 0!==n?n:m.src.default," 992w, ").concat(m.src.default," 1440w"),alt:m.alt,fetchPriority:m.fetchPriority,animate:{clipPath:h.image},transition:{type:"tween"}}),e.createElement(i.div,{key:u,className:"hero__polygon-image-background",animate:{opacity:1,clipPath:h.background},transition:{type:"tween"},initial:{opacity:0}})))}h();var xt={initial:{pathLength:0},animate:{pathLength:1},transition:{delay:.5,duration:1}};function Tt(c){var a=c.isMobile,t=c.isTablet;return a?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"75%",bottom:"30%",transform:"rotate(10deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"75%",bottom:"30%",transform:"rotate(-15deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt))))):t?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"calc(30% + 1px)",top:"calc(60% - 3px)",transform:"rotate(161deg)"},initial:!1},e.createElement("svg",{width:"120",height:"2",viewBox:"0 0 120 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"30%",top:"calc(60% - 1px)",transform:"rotate(26deg)"},initial:!1},e.createElement("svg",{width:"120",height:"2",viewBox:"0 0 120 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt))))):e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"10%",top:"calc(65% - 3px)",transform:"rotate(118deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"10%",top:"calc(65% - 3px)",transform:"rotate(41deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))))}h();var Lt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.fieldName,i=c.selectOptions,o=c.defaultValue,s=void 0===o?"all":o,m=c.hiddenLabel,h=void 0!==m&&m,d=c.customLabel,u=c.title,v=c.onChange,f=c.value;return e.createElement("div",{className:p("form-select",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},d?e.createElement("label",{htmlFor:r,className:p("form-select__label",h&&"sr-only")},d):e.createElement("label",{htmlFor:r,className:p("form-select__label",h&&"sr-only")},"Select ",r),e.createElement("div",{className:"form-select__select-wrapper"},e.createElement("select",{className:"form-select__select",defaultValue:s,value:f,id:r,name:r,onChange:v},e.createElement("option",{value:"all"},u),i&&i.map(function(c,a){return e.createElement("option",{value:c.value,key:a},c.label)})),e.createElement("div",{className:"form-select__icon"},e.createElement(_,{icon:"arrow-down",theme:t,inverse:n}))))};function zt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.title,i=c.description,o=c.defaultSearchTerm,s=c.placeholder,m=c.filterTitle,h=c.filterFieldName,d=c.filterOptions,u=c.defaultFilter,v=void 0===u?"all":u,f=c.wrapped,g=void 0!==f&&f,E=c.fullWidth,_=void 0!==E&&E,b=c.onGrid,w=void 0!==b&&b,y=c.titleTag,M=void 0===y?"h2":y,N=c.formSubmitHandler,k=c.filterChangeHandler,x=c.searchTermChangeHandler,T=M;return e.createElement("div",{className:p("search-course",_&&"search-course--full-width",w&&"search-course--on-grid",g&&"search-course--wrapped",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),!h&&"search-course--no-filter")},e.createElement("div",{className:"search-course__container"},r&&e.createElement(T,{className:"search-course__title"},r),i&&e.createElement("div",{className:"search-course__description"},e.createElement(C,{text:i,theme:t,inverse:n})),e.createElement("form",{className:"search-course__form",method:"post",onSubmit:N},e.createElement("div",{className:"search-course__search-wrapper"},e.createElement(wt,{theme:t,inverse:n,fieldName:"search",hiddenLabel:!0,defaultValue:o,placeholder:s,onChange:x}),e.createElement(Oe,{theme:t,inverse:!n,title:"Search",icon:"search",isSubmit:!0}),g&&e.createElement(q,{theme:t,inverse:!n,label:"Search",isSubmit:!0})),h&&m&&d&&e.createElement(Lt,{theme:t,inverse:n,title:m,fieldName:h,selectOptions:d,defaultValue:v,hiddenLabel:!0,onChange:k}),!g&&e.createElement(q,{theme:t,inverse:!n,label:"Search",isSubmit:!0}))))}function Ht(c){var a=c.theme,t=c.inverse,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.description,o=c.image,s=c.links,m=c.courseSearchProps,h=xe("768px"),u=xe("1248px");return e.createElement("div",{className:p("hero",a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"),o&&"hero--with-image"),id:"hero"},o&&"rectangle"===o.style&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--mobile hero__image-wrapper--rectangle"},e.createElement(L,d({},o,{altText:o.alt,fetchPriority:o.fetchPriority}))),o&&"lines-of-intent"===o.style&&h&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--mobile"},e.createElement(kt,{isMobile:!0,isTablet:!1,image:o}),e.createElement(Tt,{isMobile:!0,isTablet:!1})),e.createElement("div",{className:"hero__container"},e.createElement("div",{className:"hero__content"},e.createElement(r,{className:"hero__title"},l),i&&e.createElement("div",{className:"hero__description"},e.createElement(C,{text:i,theme:a,inverse:t})),s&&s.length>0&&e.createElement("div",{className:"hero__buttons"},s.map(function(c,l){return e.createElement(q,{theme:a,key:l,url:c.url,label:c.title,externalLink:c.externalLink,inverse:!t,hollow:1===l})})),m&&e.createElement(zt,d({theme:a,inverse:t,wrapped:!0},m))),o&&"rectangle"===o.style&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--rectangle"},e.createElement(L,d({},o,{altText:o.alt,fetchPriority:o.fetchPriority}))),o&&"lines-of-intent"===o.style&&u&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--polygon"},e.createElement(kt,{isMobile:!1,isTablet:!0,image:o}),e.createElement(Tt,{isMobile:!1,isTablet:!0})),o&&"lines-of-intent"===o.style&&!h&&!u&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--polygon"},e.createElement(kt,{isMobile:!1,isTablet:!1,image:o}),e.createElement(Tt,{isMobile:!1,isTablet:!1}))))}function Vt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.label,r=c.icons;return e.createElement("div",{className:p("share-buttons",t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"))},n&&e.createElement("div",{className:"share-buttons__label"},n),r&&e.createElement("ul",{className:"share-buttons__icon-wrapper"},r.map(function(c,a){return e.createElement("li",{className:"share-buttons__icon",key:a},e.createElement(Oe,{theme:t,title:c.title,icon:c.icon,url:c.url,inverse:l}))})))}function St(c){var a="items"in c?c.items:[c];console.info("props in Paragraph Link",c),console.info("items in Paragraph Link",a);var t=(null!=a?a:[]).filter(function(e){return Boolean(e)});return e.createElement(e.Fragment,null,t.map(function(c,a){var l=c.theme,n=void 0===l?"uobmain":l,r=c.inverse,i=void 0!==r&&r,o=c.label,s=c.url,m=c.externalLink;return e.createElement(e.Fragment,{key:"".concat(s,"-").concat(o,"-").concat(a)},e.createElement("a",{className:p("paragraph-link",n&&"theme-".concat(n),i&&"theme-".concat(n,"--inverse")),href:s,target:m?"_blank":"_self",rel:"noreferrer"},o),a<t.length-1?" ":null)}))}function Pt(c){var a=c.theme,t=c.inverse,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.description,o=c.cardImage,s=c.publishDate,m=c.readTime,h=c.shareButtons,u=c.author,v=Array.isArray(u)?u:[u];return console.info("authors from HeroArticle",v),e.createElement("section",{className:p("hero-article",a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"))},e.createElement("div",{className:"hero-article__container"},e.createElement("div",{className:"hero-article__content"},e.createElement(r,{className:"hero-article__title"},l),e.createElement("p",{className:"hero-article__description"},i),e.createElement("div",{className:"hero-article__meta-data"},s&&e.createElement("span",{className:"hero-article__publish-date"},s),s&&m&&e.createElement("span",{className:"hero-article__separator"},"•"),m&&e.createElement("span",{className:"hero-article__read-time"},m),u&&e.createElement(e.Fragment,null,e.createElement("span",{className:"hero-article__separator"},"•"),e.createElement("span",{className:"hero-article__author"},"by ",e.createElement(St,{items:v})))),e.createElement("div",{className:"hero-article__sharing-buttons"},e.createElement(Vt,{theme:a,label:h.label,icons:h.icons,inverse:t})))),o&&e.createElement("div",{className:"hero-article__image-wrapper"},e.createElement(Ge,d({},o,{inverse:t}))))}function Ot(c){var t=c.theme,l=c.inverse,n=c.buttonLabel,r=c.hollow,i=c.modalChildren,o=a(!1),s=o[0],m=o[1],h=function(){m(!1),document.body.classList.remove("lock-scroll")};return e.createElement("div",{className:p("modal-cta-button",t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"))},e.createElement(q,{inverse:l,label:n,onClick:function(){s?h():(m(!0),document.body.classList.add("lock-scroll"))},theme:t,hollow:r}),s&&e.createElement(Be,{centred:!0,theme:t,closeModal:h,isOpen:s},e.createElement(sc,{className:"modal-cta-button__embed-wrapper"},i)))}function Zt(c){var a=c.title,t=c.value,l=c.link;return e.createElement("article",{className:"course-tile"},e.createElement("div",{className:"course-tile__top"},e.createElement("div",{className:"course-tile__title"},a),e.createElement("div",{className:"course-tile__value"},t)),l&&e.createElement("div",{className:"course-tile__link-wrapper"},e.createElement(Fc,d({},l,{inverse:!0,onClick:function(e){return Dc(e,l.url||"#")}}))))}function Bt(c){var a=c.title,t=c.selectProps;return e.createElement("article",{className:"course-tile-select"},e.createElement("div",{className:"course-tile-select__top"},e.createElement("div",{className:"course-tile-select__title"},a),e.createElement(Lt,d({},t,{inverse:!0}))))}function Ft(c){var a=c.title,t=c.rank,l=c.rankText,n=c.link;return e.createElement("article",{className:"course-tile-ranking"},e.createElement("div",{className:"course-tile-ranking__top"},e.createElement("div",{className:"course-tile-ranking__title"},a),e.createElement("div",{className:"course-tile-ranking__rank"},t),e.createElement("div",{className:"course-tile-ranking__rank-text"},l)),n&&e.createElement("div",{className:"course-tile-ranking__link-wrapper"},e.createElement(Fc,d({},n,{inverse:!0,onClick:function(e){return Dc(e,n.url||"#")}}))))}function Dt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.topPadding,i=void 0!==r&&r,o=c.selectorProps;return e.createElement("div",{className:p("location-selector",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:p("location-selector__container",i&&"location-selector__container--padding-top")},e.createElement(Lt,d({},o,{inverse:n}))))}function It(c){var a,t=c.theme,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.awardShort,o=c.links,s=c.ranking,m=c.award,h=c.campus,u=c.ucas,v=c.duration,f=c.entryRequirements,g=c.startDate,E=c.yearOfEntry,_=c.fees,b=c.deliveryFormat,w=c.locationDetails,y=c.modalCTA;return e.createElement("section",{className:p("hero-courses",t&&"theme-".concat(t)),id:"hero-courses"},e.createElement("div",{className:"hero-courses__container"},e.createElement("div",{className:"hero-courses__content"},e.createElement("div",{className:"hero-courses__title-wrapper"},e.createElement(N,{htmlTag:r,classNames:"hero-courses__title"},l&&l.length>0&&i&&i.length>0?l+" ":l,e.createElement("span",{className:"hero-courses__title-award"},i))),w&&e.createElement("div",{className:"hero-courses__location-wrapper"},e.createElement(Dt,d({},w,{inverse:!1}))),e.createElement("ul",{className:(a="hero-courses__grid--four",s&&(h||b||u)?a="hero-courses__grid--six":(s&&!h&&!b&&!u||!s&&(h||b||u))&&(a="hero-courses__grid--five"),"hero-courses__grid "+a)},s&&e.createElement("li",{className:"hero-courses__column hero-courses__column--ranking"},e.createElement(Ft,d({},s))),(u||h||b)&&e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--award"},u&&e.createElement(Zt,d({},u)),h&&e.createElement(Zt,d({},h)),b&&e.createElement(Zt,d({},b))),v&&E?e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--duration"},e.createElement(Bt,d({},E)),e.createElement(Zt,d({},v))):v&&g?e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--duration"},e.createElement(Zt,d({},g)),e.createElement(Zt,d({},v))):e.createElement("li",{className:"hero-courses__column hero-courses__column--duration"},e.createElement(Zt,d({},v))),m&&e.createElement("li",{className:"hero-courses__column hero-courses__column--delivery-format"},e.createElement(Zt,d({},m))),e.createElement("li",{className:"hero-courses__column hero-courses__column--entry-requirements"},e.createElement(Zt,d({},f))),e.createElement("li",{className:"hero-courses__column hero-courses__column--fees"},e.createElement(Zt,d({},_)))),e.createElement("div",{className:"hero-courses__button-wrapper"},e.createElement("ul",{className:"hero-courses__buttons"},o&&o.map(function(c,a){return c.externalLink?e.createElement("li",{className:"hero-courses__button",key:a},e.createElement(Fe,{theme:t,label:c.label,icon:"external",hollow:a%2!=0,iconPosition:"right",url:c.url,inverse:!0,onClick:c.onClick})):e.createElement("li",{className:"hero-courses__button",key:a},e.createElement(q,{theme:t,label:c.label,hollow:a%2!=0,url:c.url,inverse:!0,onClick:c.onClick}))})),y&&e.createElement(Ot,{theme:t,inverse:!y.inverse,hollow:!0,buttonLabel:y.buttonLabel,modalChildren:y.modalChildren})))))}h(),h(),h(),h(),h(),h(),h();var At={first:{clipPath:"polygon(0 0, 95% 0, 75% 100%, 0 80%)"},second:{clipPath:"polygon(0 0, 100% 0, 75% 70%, 0 90%)"},third:{clipPath:"polygon(0 0, 80% 0, 95% 90%, 0 80%)"},visible:{opacity:1}},$t={first:{clipPath:"polygon(0 0, calc(95% - 1px) 0, calc(75% - 1px) calc(100% - 1px), 0 calc(80% - 1px))"},second:{clipPath:"polygon(0 0, calc(100% - 1px) 0, calc(75% - 1px) calc(70% - 1px), 0 calc(90% - 1px))"},third:{clipPath:"polygon(0 0, calc(80% - 1px) 0, calc(95% - 1px) calc(90% - 1px), 0 calc(80% - 1px))"}},Rt={first:{clipPath:"polygon(0 25%, 100% 5%, 100% 100%, 23% 100%)"},second:{clipPath:"polygon(33% 20%, 100% 5%, 100% 100%, 0 100%)"},third:{clipPath:"polygon(0 3%, 100% 20%, 100% 100%, 23% 100%)"},visible:{opacity:1}},jt={first:{clipPath:"polygon(1px calc(25% + 1px), 100% calc(5% + 1px), 100% 100%, calc(23% + 1px) 100%)"},second:{clipPath:"polygon(calc(33% + 1px) calc(20% + 1px), 100% calc(5% + 1px), 100% 100%, 1px 100%)"},third:{clipPath:"polygon(1px calc(3% + 1px), 100% calc(20% + 1px), 100% 100%, calc(23% + 1px) 100%"}},Ut={first:{clipPath:"polygon(0 33%, 100% 10%, 100% 100%, 23% 100%)"},second:{clipPath:"polygon(33% 30%, 100% 10%, 100% 100%, 0 100%)"},third:{clipPath:"polygon(0 10%, 100% 25%, 100% 100%, 15% 100%)"},visible:{opacity:1}},Wt={first:{clipPath:"polygon(1px calc(33% + 1px), 100% calc(10% + 1px), 100% 100%, calc(23% + 1px) 100%)"},second:{clipPath:"polygon(calc(33% + 1px) calc(30% + 1px), 100% calc(10% + 1px), 100% 100%, 1px 100%)"},third:{clipPath:"polygon(1px calc(10% + 1px), 100% calc(25% + 1px), 100% 100%, calc(15% + 1px) 100%"}},Gt={first:{left:"calc(75% + 1px)",bottom:0,transform:"rotate(-40deg)"},second:{left:"75%",bottom:"30%",transform:"rotate(-15deg)"},third:{left:"95%",bottom:"10%",transform:"rotate(-70deg)"}},Kt={first:{left:"calc(75% + 1px)",bottom:0,transform:"rotate(-15deg)"},second:{left:"75%",bottom:"30%",transform:"rotate(10deg)"},third:{left:"95%",bottom:"10%",transform:"rotate(-30deg)"}},Yt={first:{left:"2px",top:"calc(25% - 1px)",transform:"rotate(-130deg)"},second:{left:"calc(33% + 2px)",top:"calc(20% - 1px)",transform:"rotate(-155deg)"},third:{left:"0",top:"calc(3% - 3px)",transform:"rotate(-170deg)"}},Jt={first:{left:"2px",top:"calc(25% - 1px)",transform:"rotate(-50deg)"},second:{left:"calc(33% + 2px)",top:"calc(20% - 1px)",transform:"rotate(-110deg)"},third:{left:"1px",top:"calc(3% - 1px)",transform:"rotate(-10deg)"}},Xt={first:{left:"2px",top:"calc(33% - 1px)",transform:"rotate(-130deg)"},second:{left:"calc(33% + 1px)",top:"calc(30% - 2px)",transform:"rotate(-160deg)"},third:{left:"1px",top:"calc(10% - 2px)",transform:"rotate(-160deg)"}},Qt={first:{left:"2px",top:"calc(33% - 1px)",transform:"rotate(-45deg)"},second:{left:"calc(33% + 1px)",top:"calc(30% - 2px)",transform:"rotate(-75deg)"},third:{left:"0",top:"calc(10%)",transform:"rotate(-15deg)"}},el={initial:{pathLength:0},animate:{pathLength:1},transition:{delay:.5,duration:1}};function cl(c){var a=c.isMobile,t=c.isTablet,l=c.activeVariant;return a?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Gt,animate:l,initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Kt,animate:l,initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140",stroke:"black"},el))))):t?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Yt,animate:l,initial:!1},e.createElement("svg",{width:"260",height:"2",viewBox:"0 0 260 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H260",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Jt,animate:l,initial:!1},e.createElement("svg",{width:"260",height:"2",viewBox:"0 0 260 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H260",stroke:"black"},el))))):e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Xt,animate:l,initial:!1},e.createElement("svg",{width:"360",height:"2",viewBox:"0 0 360 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H360",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Qt,animate:l,initial:!1},e.createElement("svg",{width:"360",height:"2",viewBox:"0 0 360 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H360",stroke:"black"},el)))))}function al(c){var a,n,o=c.isMobile,s=c.isTablet,h=c.activeVariant,d=c.imageSrc,u=c.imageAlt,v=c.imageFetchPriority,p=l(null),f=r();return t(function(){p.current&&p.current.setAttribute("fetchpriority",null!=v?v:"high")}),e.createElement(e.Fragment,null,e.createElement(m,null,e.createElement(i.div,{className:"hero-carousel__image-wrapper",transition:{delayChildren:1}},e.createElement(i.img,{ref:p,className:"hero-carousel__image",src:d.default,srcSet:"".concat(null!==(a=d.small)&&void 0!==a?a:d.default," 576w, ").concat(null!==(n=d.medium)&&void 0!==n?n:d.default," 992w, ").concat(d.default," 1440w"),alt:u,variants:o?$t:s?jt:Wt,animate:h,initial:{clipPath:"polygon(0 0, 0 0, 0 0, 0 0)"},transition:{type:"tween"}}),e.createElement(i.div,{key:f,className:"hero-carousel__image-background",variants:o?At:s?Rt:Ut,animate:["visible",h],exit:{backgroundColor:"rgba(255, 255, 255, 0)"},transition:{type:"tween"},initial:{opacity:0,clipPath:"polygon(1% 1%, 1% 1%, 1% 1%, 1% 1%)"}}))))}var tl=c(function(c,a){var t=c.theme,l=c.category,n=c.title,r=c.description,i=c.linkUrl,o=c.linkLabel,s=c.onKeyDown;return e.createElement(e.Fragment,null,e.createElement("p",{className:"hero-carousel__category"},l),e.createElement("h2",{className:"hero-carousel__title"},n),e.createElement("p",{className:"hero-carousel__description"},r),e.createElement("div",{className:"hero-carousel__cta"},e.createElement(y,{url:i,title:o,theme:t,inverse:!0,onKeyDown:s,ref:a})))});function ll(c){var t=c.theme,n=c.cards,r=n.length>1,o=a(0),s=o[0],m=o[1],h=n[s],d=l(null),u=xe("768px"),v=xe("1248px"),f="";switch(s){case 0:f="first";break;case 1:f="second";break;case 2:f="third"}var g=r?e.createElement(cc,{theme:t,totalNumber:n.length,currentNumber:s+1,carouselId:"hero-carousel",onClickPrev:function(){m(function(e){return e-1})},onClickNext:function(){m(function(e){return e+1})},prevButtonDisabled:0===s,nextButtonDisabled:s===n.length-1,showNumbers:!0}):e.createElement(e.Fragment,null);return e.createElement("div",{className:p("hero-carousel",t&&"theme-".concat(t)),id:"hero-carousel"},e.createElement("div",{className:"hero-carousel__top"},e.createElement("div",{className:"hero-carousel__content"},u&&e.createElement("div",{className:"hero-carousel__image-container hero-carousel__image-container--mobile"},e.createElement(al,{isMobile:!0,isTablet:!1,activeVariant:f,imageSrc:h.imageSrc,imageAlt:h.imageAlt}),e.createElement(cl,{isMobile:!0,isTablet:!1,activeVariant:f})),e.createElement("div",{className:"hero-carousel__cards"},e.createElement(i.section,{className:"hero-carousel__active-card",key:s,initial:{opacity:0},animate:{opacity:1}},e.createElement(tl,{category:h.category,title:h.title,description:h.description,linkUrl:h.linkUrl,linkLabel:h.linkLabel,theme:t,ref:d})),u&&r&&n.map(function(c,a){return e.createElement("section",{className:"hero-carousel__invisible-card hero-carousel__invisible-card--mobile",key:a,"aria-hidden":!0},e.createElement(tl,{category:c.category,title:c.title,description:c.description,linkUrl:c.linkUrl,linkLabel:c.linkLabel,theme:t}))}),e.createElement("div",{className:"hero-carousel__nav hero-carousel__nav--desktop"},g)),e.createElement("div",{className:"hero-carousel__image-container hero-carousel__image-container--desktop"},e.createElement(al,{isMobile:!1,isTablet:v,activeVariant:f,imageSrc:h.imageSrc,imageAlt:h.imageAlt}),e.createElement(cl,{isMobile:!1,isTablet:v,activeVariant:f}))),!u&&r&&n.map(function(c,a){return e.createElement("div",{className:"hero-carousel__invisible-card hero-carousel__invisible-card--desktop",key:a,"aria-hidden":!0},e.createElement("section",null,e.createElement(tl,{category:c.category,title:c.title,description:c.description,linkUrl:c.linkUrl,linkLabel:c.linkLabel,theme:t})))})),u&&e.createElement("div",{className:"hero-carousel__nav hero-carousel__nav--mobile"},g))}function nl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.title,r=c.description,i=c.linkProps,o=c.fullWidth,s=c.makeHeadingFullWidth,m=c.images,h=c.htmlTag;if(!m||0===m.length)return null;var u=m.length>2?Array.from(m.slice(0,2)):Array.from(m);return e.createElement("div",{className:p("image-block",t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"),o&&"image-block--full-width")},(n||r||i)&&e.createElement(x,{theme:t,inverse:l,title:n,description:r,linkProps:i,fullWidth:!!s,htmlTag:h}),e.createElement("div",{className:"image-block__container"},u&&u.map(function(c,a){var n=p({"image-block__image-container-single-image-full-width-true":1===m.length&&o,"image-block__image-container-single-image-full-width-false":1===m.length&&!o,"image-block__image-container-first-image-full-width-true":m.length>1&&0===a&&o,"image-block__image-container-first-image-full-width-false":m.length>1&&0===a&&!o,"image-block__image-container-second-image-full-width-true":m.length>1&&1===a&&o,"image-block__image-container-second-image-full-width-false":m.length>1&&1===a&&!o});return e.createElement("div",{key:a,className:n},e.createElement(Ge,d({},c,{theme:t,inverse:l})))})))}function rl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.title,i=c.description,o=c.linkProps,s=c.fullWidth,m=void 0!==s&&s,h=c.widerImage,d=c.images,u=c.htmlTag;return e.createElement("section",{className:p("image-carousel",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),m&&"image-carousel--full-width",h&&"image-carousel--wider-image")},(r||i)&&e.createElement(x,{theme:t,htmlTag:u,inverse:n,title:r,description:i,linkProps:o}),e.createElement("div",{className:"image-carousel__grid"},e.createElement(ac,{theme:t,inverse:n,type:"image",cards:d})))}function il(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=void 0===l?"Page contents":l,r=c.links,i=c.buttonLinks,o=c.locationDetails,s=function(e){var c=document.getElementById(e);if(c){var a=c.getBoundingClientRect().top+window.pageYOffset-20;window.scrollTo({top:a,behavior:"smooth"});var t=null,l=null,n=0,r=function(){t&&(t.disconnect(),t=null),l&&(l.disconnect(),l=null),n&&(clearTimeout(n),n=0)},i=function(e){return!!e&&(t=new IntersectionObserver(function(c){c.some(function(e){return e.isIntersecting})&&function(e){try{e.focus({preventScroll:!0})}catch(e){}finally{r()}}(e)},{root:null,threshold:.1,rootMargin:"0px 0px -20% 0px"}),t.observe(e),!0)},o=c.querySelector("h1,h2,h3,h4,h5,h6");i(o)||(l=new MutationObserver(function(){o=c.querySelector("h1,h2,h3,h4,h5,h6"),i(o)&&l&&(l.disconnect(),l=null)})).observe(c,{childList:!0,subtree:!0}),n=window.setTimeout(function(){r();var e=c.querySelector('a, button, input, select, textarea, [tabindex]:not([tabindex="-1"])');if(e){var a=!e.hasAttribute("tabindex");a&&e.setAttribute("tabindex","-1"),e.focus({preventScroll:!0}),a&&e.removeAttribute("tabindex")}},1e3)}},m=function(e,c){e.preventDefault(),s(c.replace("#",""))};return e.createElement("div",{className:p("in-page-navigation-links",t&&"theme-".concat(t))},e.createElement("h2",{className:"in-page-navigation-links__heading"},n),o&&e.createElement(Dt,d({},o,{inverse:!0})),e.createElement("nav",null,e.createElement("ul",{className:"in-page-navigation-links__link-container"},r.map(function(c){return e.createElement("li",{className:p("in-page-navigation-links__link-wrapper",c.active&&"in-page-navigation-links__link-wrapper--active"),key:c.url},e.createElement("a",{className:"in-page-navigation-links__link",href:c.url,onClick:function(e){return m(e,c.url)},onKeyDown:function(e){"Enter"!==e.key&&" "!==e.key||m(e,c.url)}},c.title))}))),e.createElement("ul",null,i&&i.map(function(c,a){return c.externalLink?e.createElement("li",{className:"in-page-navigation-links__link-button",key:a},e.createElement(Fe,{theme:t,label:c.label,icon:"external",hollow:a%2!=0,iconPosition:"right",url:c.url,onClick:c.onClick})):e.createElement("li",{className:"in-page-navigation-links__link-button",key:a},e.createElement(q,{theme:t,label:c.label,hollow:a%2!=0,url:c.url,onClick:c.onClick}))})))}function ol(c){var n,r,o=c.theme,s=void 0===o?"uobmain":o,h=c.inverse,u=void 0!==h&&h,v=c.links,f=c.expandableHeader,g=void 0===f?"Page contents":f,E=a(!1),_=E[0],b=E[1],w=a("not-docked"),q=w[0],y=w[1],M=a(null),N=M[0],C=M[1],k=l(null),x=l(null),T=l(null),L=l(null),z=l(null),H=function(){b(!1)};return t(function(){var e=function(e){!n.current||e.target instanceof HTMLElement&&n.current.contains(e.target)||r()};return document.addEventListener("mousedown",e),document.addEventListener("touchstart",e),function(){document.removeEventListener("mousedown",e),document.removeEventListener("touchstart",e)}},[n=z,r=function(){return H()}]),t(function(){var e;T.current=new IntersectionObserver(function(c){var a;e=null===(a=c.find(function(e){return e.isIntersecting}))||void 0===a?void 0:a.target,y(e?"docked":"not-docked")},{rootMargin:"0px 0px -100%"}),x.current=new IntersectionObserver(function(c){var a,t=null===(a=c.find(function(e){return e.isIntersecting}))||void 0===a?void 0:a.target;t?y("docked-at-bottom"):!t&&e&&y("docked")}),k.current=new IntersectionObserver(function(e){var c,a=null===(c=e.find(function(e){return e.isIntersecting}))||void 0===c?void 0:c.target;a&&C(a.id)},{rootMargin:"0px 0px -".concat(.7*window.innerHeight,"px 0px")});var c=document.querySelectorAll(".anchor-target");c.forEach(function(e){k&&k.current&&k.current.observe(e)});var a=document.querySelectorAll("#footer");a.forEach(function(e){x&&x.current&&x.current.observe(e)});var t=document.querySelectorAll("#sidebar");return t.forEach(function(e){T&&T.current&&T.current.observe(e)}),function(){c.forEach(function(e){k&&k.current&&k.current.unobserve(e)}),t.forEach(function(e){T&&T.current&&T.current.unobserve(e)}),a.forEach(function(e){x&&x.current&&x.current.unobserve(e)})}},[]),v.links.map(function(e){return e.url.substring(1)===N?e.active=!0:e.active=!1}),e.createElement("div",{className:p("in-page-navigation",s&&"theme-".concat(s),u&&"theme-".concat(s,"--inverse"))},e.createElement("div",{className:p("in-page-navigation--mobile",q)},e.createElement("div",{className:"in-page-navigation__closed"},e.createElement("div",{className:"in-page-navigation__top-container"},e.createElement("div",{className:"in-page-navigation__right-wrapper"},e.createElement("div",{className:"in-page-navigation__menu-button"},e.createElement("span",{className:"in-page-navigation__expandable-header"},g),e.createElement(Oe,{theme:"uobmain",icon:"menu",onClick:function(){b(!0)},title:"Open menu",ariaControls:"in-page-navigation",ref:L,ariaExpanded:_})))))),_&&e.createElement("div",{className:"in-page-navigation__overlay"}),e.createElement(m,null,_&&e.createElement(i.div,{className:"in-page-navigation__open",initial:{x:"100%"},animate:{x:"0"},exit:{x:"100%"},transition:{type:"tween"},key:"in-page-navigation__open",ref:z},e.createElement(Ze,null,e.createElement("div",{className:"in-page-navigation__nav"},e.createElement("div",{className:"in-page-navigation__top-container"},e.createElement("div",{className:"in-page-navigation__right-wrapper"},e.createElement("div",{className:"in-page-navigation__close-button"},e.createElement("span",null,"Close"),e.createElement(Oe,{theme:"uobmain",inverse:!0,icon:"cross",onClick:H,title:"Close menu",ariaControls:"in-page-navigation"})))),e.createElement(il,d({},v,{theme:"uobmain"})))))),e.createElement("div",{className:p("in-page-navigation--desktop",q)},e.createElement(il,d({},v,{theme:s}))))}function sl(c){var a=c.text,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=c.fullWidth,i=c.removeBottomPadding,o=void 0!==i&&i,s=c.removeTopPadding,m=void 0!==s&&s;return e.createElement("div",{className:p("intro-text",l&&"theme-".concat(l),n&&"theme-".concat(l,"--inverse"),r&&"intro-text--full-width",o&&"intro-text--no-bottom-padding",m&&"intro-text--no-top-padding")},e.createElement("div",{className:"intro-text__container"},e.createElement("p",{className:"intro-text__text"},a)))}function ml(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=c.cards,r=c.link;return e.createElement("div",{className:p("most-read-news",t&&"theme-".concat(t))},e.createElement("h2",{className:"most-read-news__title"},l),e.createElement("ul",{className:"most-read-news__card-container"},n.map(function(c,a){return e.createElement("li",{className:"most-read-news__card",key:a},e.createElement(Ke,{theme:t,title:c.title,href:c.href,titleTag:"h3",publishDate:c.publishDate}))})),r&&e.createElement(y,{theme:t,inverse:!0,url:r.url,title:r.title}))}function hl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.featuredArticle,n=c.otherLeadArticles,r=c.mostReadNews;return e.createElement("section",{className:p("lead-news-articles",t&&"theme-".concat(t))},e.createElement("div",{className:"lead-news-articles__container"},e.createElement("div",{className:"lead-news-articles__main-container"},e.createElement("div",{className:"lead-news-articles__featured-card"},e.createElement(Ke,d({},l,{isPrimary:!0}))),e.createElement("ul",{className:"lead-news-articles__secondary-card-container"},n.map(function(c,a){return e.createElement("li",{className:"lead-news-articles__secondary-card",key:a},e.createElement(Ke,{theme:t,image:c.image,title:c.title,href:c.href,titleTag:c.titleTag,publishDate:c.publishDate}))}))),e.createElement("div",{className:"lead-news-articles__side-container"},e.createElement(ml,d({},r)))))}function dl(c){var n=c.theme,r=c.showFilterButtonLabel,o=c.numSelected,s=c.filterElement,m=a(!1),h=m[0],d=m[1],u=l(null),v=function(e){"Escape"===e.key&&h&&d(!1)};return t(function(){return document.addEventListener("keydown",v),function(){document.removeEventListener("keydown",v)}}),t(function(){var e,c;h?null===(e=u.current)||void 0===e||e.showModal():null===(c=u.current)||void 0===c||c.close()},[h]),e.createElement(e.Fragment,null,e.createElement("div",{className:p("listing-filter-wrapper","theme-".concat(n))},e.createElement("div",{className:"listing-filter-wrapper__mobile"},e.createElement("button",{className:"listing-filter-wrapper__show-filter-button",onClick:function(){d(!0),document.body.classList.add("lock-scroll")}},e.createElement(_,{theme:"uobmain",icon:"settings"}),r,o&&e.createElement("span",{className:"listing-filter-wrapper__num-selected"},o,e.createElement("span",{className:"sr-only"},o>1?"filters":"filter"," selected"))))),e.createElement(Ze,null,e.createElement(i.dialog,{className:p("listing-filter-wrapper__dialog","theme-".concat(n)),initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},ref:u},e.createElement("div",{className:"listing-filter-wrapper__popup-wrapper"},e.createElement("div",{className:"listing-filter-wrapper__popup"},e.createElement("button",{className:"listing-filter-wrapper__close-button",onClick:function(){d(!1),document.body.classList.remove("lock-scroll")}},e.createElement(_,{icon:"slim-cross",theme:n,ariaHidden:!0}),e.createElement("span",{className:"sr-only"},"Close")),s)))),e.createElement("div",{className:"listing-filter-wrapper__desktop"},s))}function ul(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.details,m=c.showCategory,h=void 0!==m&&m;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},h&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),o&&e.createElement("p",{className:"listing-result-card__description"},o),s.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:s,theme:t}))))}function vl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.titleTag,o=void 0===i?"h2":i,s=c.url,m=c.description,h=c.supervisors,u=c.department,v=c.details,p=c.showCategory,f=void 0!==p&&p;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},f&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement(N,{htmlTag:"h3"===o?"h3":"h2"},e.createElement("a",{className:"listing-result-card__title",href:s},r)),(h||u)&&e.createElement("div",{className:"listing-result-card__course-info"},h&&e.createElement("p",{className:"listing-result-card__supervisors"},"Supervisors: ",h),u&&e.createElement("p",{className:"listing-result-card__department"},u)),m&&e.createElement("p",{className:"listing-result-card__description"},m),v.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:v,theme:t}))))}function pl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.type,i=c.image,o=c.title,s=c.url,m=c.description,h=c.details,u=c.showCategory,v=void 0!==u&&u,p=c.cardDescriptionIsRichText,f=void 0!==p&&p,g=c.titleTag,E=void 0===g?"h2":g,_=c.eventStatus,b=void 0===_?void 0:_;return e.createElement(e.Fragment,null,i&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},i)),b&&e.createElement("div",{className:"listing-result-card__event-graphic"},e.createElement(Ie,{theme:"uobmain",status:b,day:void 0,month:void 0}))),e.createElement("div",{className:"listing-result-card__text"},v&&e.createElement("p",{className:"listing-result-card__category"},r),e.createElement(N,{htmlTag:E},e.createElement("a",{className:"listing-result-card__title",href:s},o)),m&&!f&&e.createElement("p",{className:"listing-result-card__description"},m),m&&f&&e.createElement(C,{theme:t,inverse:n,text:m}),h.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:h,theme:t}))))}function fl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.author,m=c.details,h=c.showCategory,u=void 0!==h&&h;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},u&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),s&&e.createElement("p",{className:"listing-result-card__author"},"by ",s),o&&e.createElement("p",{className:"listing-result-card__description"},o),m.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:m,theme:t}))))}function gl(c){var a=c.image,t=c.title,l=c.url,n=c.description;return e.createElement(e.Fragment,null,a&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},a))),e.createElement("div",{className:"listing-result-card__text"},e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:l},t)),n&&e.createElement("p",{className:"listing-result-card__description"},n)))}function El(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.jobTitle,m=c.department,h=c.details,u=c.showCategory,v=void 0!==u&&u;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},v&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),(s||m)&&e.createElement("div",{className:"listing-result-card__staff-info"},s&&e.createElement("p",{className:"listing-result-card__job-title"},s),m&&e.createElement("p",{className:"listing-result-card__department"},m)),o&&e.createElement("p",{className:"listing-result-card__description"},o),h.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:h,theme:t}))))}function _l(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.image,n=c.title,r=c.url,i=c.description,o=c.jobTitle,s=c.department,m=c.details;return e.createElement(e.Fragment,null,l&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},l))),e.createElement("div",{className:"listing-result-card__text"},e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:r},n)),(o||s)&&e.createElement("div",{className:"listing-result-card__staff-info"},o&&e.createElement("p",{className:"listing-result-card__job-title"},o),s&&e.createElement("p",{className:"listing-result-card__department"},s)),i&&e.createElement("p",{className:"listing-result-card__description"},i.length>120?"".concat(i.slice(0,120),"..."):i),m.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:m,theme:t}))))}function bl(c){return e.createElement("article",{className:p("listing-result-card",c.theme&&"theme-".concat(c.theme))},"page"===c.type&&e.createElement(gl,d({},c)),"course"===c.type&&e.createElement(vl,d({},c)),"accomodation"===c.type&&e.createElement(ul,d({},c)),"event"===c.type&&e.createElement(pl,d({},c)),"news"===c.type&&e.createElement(fl,d({},c)),"staff"===c.type&&e.createElement(El,d({},c)),"profile"===c.type&&e.createElement(_l,d({},c)))}function wl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.showCategory,n=void 0!==l&&l,r=c.cards,i=c.headingInfo;return e.createElement(e.Fragment,null,i&&e.createElement(x,d({},i,{theme:t,fullWidth:!0})),e.createElement("ul",{className:p("listing-results",t&&"theme-".concat(t))},r.map(function(c,a){return e.createElement("li",{className:"listing-results__card",key:a},e.createElement(bl,d({},c,{showCategory:n,theme:t})))})))}function ql(c){var a=c.count,t=c.theme,l=void 0===t?"uobmain":t;return e.createElement("p",{className:p("listing-results-count",l&&"theme-".concat(l))},e.createElement("span",{className:"listing-results-count__number"},a.toLocaleString())," results were found based on your search term")}function yl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.listItems;return e.createElement("div",{className:p("list-table",t&&"theme-".concat(t))},(null==l?void 0:l.length)?e.createElement("ul",{className:"list-table__list"},null==l?void 0:l.map(function(c,a){return e.createElement("li",{key:c+a,className:"list-table__list-item"},e.createElement(C,{inverse:!0,theme:"uobmain",text:c}))})):null)}function Ml(c){var a=c.children;return e.createElement("main",{id:"main"},a)}function Nl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=c.cards,r=c.cardType,i=void 0===r?"featured-news":r;return e.createElement("section",{className:p("news-articles-promo-block",t&&"theme-".concat(t),i&&"news-articles-promo-block--".concat(i))},e.createElement("div",{className:"news-articles-promo-block__heading-container"},l&&e.createElement("h2",{className:"news-articles-promo-block__heading"},l)),e.createElement("div",{className:"news-articles-promo-block__cards news-articles-promo-block__cards--mobile"},"featured-news"===i&&e.createElement(ac,{theme:t,type:"featured-news",cards:n,inverse:!0,cardTitleTag:"h3"}),"promo-video"===i&&e.createElement(ac,{theme:t,type:"promo-video",cards:n,inverse:!0,cardTitleTag:"h3",setCardInverse:"dark"})),e.createElement("ul",{className:"news-articles-promo-block__cards news-articles-promo-block__cards--desktop"},n.map(function(c,a){return e.createElement("li",{key:a},"featured-news"===i&&e.createElement(Ke,d({},c,{inverse:!0,titleTag:"h3"})),"promo-video"===i&&e.createElement(Re,d({},c,{inverse:!1,titleTag:"h3"})))})))}function Cl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.numOfPages,n=c.onClick,r=c.currentPage,i=xe("768px"),o=e.createElement("li",null,e.createElement("span",{className:"pagination__ellipse"},"..."));return i&&l<=4?e.createElement(e.Fragment,null,Array(l).fill(0).map(function(c,a){return e.createElement("li",{className:p("pagination__number",r===a&&"pagination__number--selected"),key:a},e.createElement(q,{label:(a+1).toString(),onClick:function(){return n(a)},hollow:!(r===a),theme:t}))})):i&&l>4?e.createElement(e.Fragment,null,r>0&&e.createElement("li",{key:0,className:"pagination__number"},e.createElement(q,{label:"1",onClick:function(){return n(0)},theme:t,hollow:!0})),r+1>=3&&o,e.createElement("li",{key:r,className:"pagination__number pagination__number--selected"},e.createElement(q,{label:"".concat(r+1," "),onClick:function(){return n(r)},theme:t})),r+1<l-1&&o,r!==l-1&&e.createElement("li",{key:l-1,className:"pagination__number"},e.createElement(q,{label:l.toString(),onClick:function(){return n(l-1)},theme:t,hollow:!0}))):!i&&l<=6?e.createElement(e.Fragment,null,Array(l).fill(0).map(function(c,a){return e.createElement("li",{key:a,className:p("pagination__number",r===a&&"pagination__number--selected","test")},e.createElement(q,{label:(a+1).toString(),onClick:function(){return n(a)},hollow:!(r===a),theme:t}))})):!i&&l>6?e.createElement(e.Fragment,null,r>0&&e.createElement("li",{key:0,className:"pagination__number start"},e.createElement(q,{label:"1",onClick:function(){return n(0)},theme:t,hollow:!0})),r+1>=4&&o,r>1&&e.createElement("li",{key:r-1,className:"pagination__number before"},e.createElement(q,{label:(r>=1?r:r-1).toString(),onClick:function(){return n(r-1)},theme:t,hollow:!0})),e.createElement("li",{key:r,className:"pagination__number pagination__number--selected current"},e.createElement(q,{label:"".concat(r+1),onClick:function(){return n(r)},theme:t})),r+1<l-1&&e.createElement("li",{key:r+1,className:"pagination__number after"},e.createElement(q,{label:"".concat(r+2),onClick:function(){return n(r+1)},theme:t,hollow:!0})),r+1<l-2&&o,r+1!==l&&e.createElement("li",{key:l-1,className:"pagination__number end"},e.createElement(q,{label:"".concat(l),onClick:function(){return n(l-1)},theme:t,hollow:!0}))):e.createElement(e.Fragment,null)}function kl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.numOfPages,n=c.onClick,r=c.currentPage,i=!xe("1248px");return l<=1?e.createElement(e.Fragment,null):e.createElement("div",{className:p("pagination",t&&"theme-".concat(t))},e.createElement("ul",{className:"pagination__container"},e.createElement("li",{className:"pagination__prev",key:"prev"},i?e.createElement(q,{theme:t,label:"Previous",onClick:function(){return n(r-1)},hollow:!0,disabled:r<1}):e.createElement(Oe,{theme:t,icon:"arrow-left",title:"Previous",onClick:function(){return n(r-1)},disabled:r<1,inverse:!0})),e.createElement(Cl,{currentPage:r,onClick:n,theme:t,numOfPages:l}),e.createElement("li",{className:"pagination__next",key:"next"},i?e.createElement(q,{theme:t,label:"Next",onClick:function(){return n(r+1)},hollow:!0,disabled:r+1===l}):e.createElement(Oe,{theme:t,icon:"arrow-right",title:"Next",onClick:function(){return n(r+1)},disabled:r+1===l,inverse:!0}))))}function xl(c){var a,t=c.theme,l=c.inverse,n=c.type,r=c.title,i=c.description,o=c.link,s=c.cards,m=c.imageOrientation,h=void 0===m?"left":m,u=c.titleTag,v=void 0===u?"h2":u,f=c.cardTitleTag,g=void 0===f?"h3":f,_=c.cardCopyIsRichText,b=void 0!==_&&_,w=c.fullWidth,q=void 0!==w&&w,M=c.fullWidthTitle,C=void 0!==M&&M,k=c.showFilters,x=void 0!==k&&k,T=c.firstFilterSelect,L=c.secondFilterSelect,z=!1;xe("768px")?s.length>1&&(z=!0):(q&&s.length>2||s.length>3)&&(z=!0);var H=p(((a={})["promo-block__grid"]=!0,a["promo-block__grid--single"]=1===s.length,a["promo-block__grid--two-cards"]=2===s.length,a["promo-block__grid--three-cards"]=3===s.length,a["promo-block__grid--four-plus-cards"]=s.length>3,a));return e.createElement("div",{className:p("promo-block","promo-block--".concat(n),t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"),q&&"promo-block--full-width")},e.createElement("div",{className:"promo-block__container"},e.createElement("div",{className:p("promo-block__top",C&&"promo-block__top--full-width")},r&&e.createElement(N,{htmlTag:v,classNames:p("promo-block__title","h3"===v&&"promo-block__title--h3")},r),i&&e.createElement(E,{theme:"uobmain",inverse:l,text:i}),o&&e.createElement("div",{className:"promo-block__text-link"},e.createElement(y,{theme:t,inverse:l,url:o.url,title:o.title,externalLink:o.externalLink}))),x&&e.createElement("div",{className:"promo-block__filters"},e.createElement("div",{className:"promo-block__filter-wrapper"},T&&e.createElement(Lt,d({},T))),e.createElement("div",{className:"promo-block__filter-wrapper"},L&&e.createElement(Lt,d({},L)))),e.createElement("div",{className:"promo-block__content"},e.createElement("div",{className:"promo-block__cards"},!z&&e.createElement("ul",{className:H},s.map(function(c,a){return e.createElement("li",{className:"promo-block__card-item",key:a},function(c){var a=d(d({},c),{cardCopyIsRichText:b});switch(n){case"promo":return e.createElement(Ae,d({},a));case"promo-signpost":return e.createElement($e,d({},c));case"promo-video":return e.createElement(Re,d({},c));case"promo-profile":return e.createElement(ec,d({},c));default:return e.createElement(e.Fragment,null)}}(d(d({},c),{inverse:l,isSingle:1===s.length,imageOrientation:h,titleTag:g})))})),z&&e.createElement(ac,{theme:t,inverse:l,type:n,cards:s,cardTitleTag:g,cardCopyIsRichText:b})))))}function Tl(c){var a=c.theme,t=c.inverse,l=c.type,n=c.title,r=c.description,i=c.link,o=c.cards,s=c.imageOrientation,m=void 0===s?"left":s,h=c.fullWidth;return e.createElement("div",{className:p("promo-block-grid","promo-block-grid--".concat(l),a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"),h&&"promo-block-grid--full-width"),id:"promo-block-grid"},e.createElement("div",{className:"promo-block-grid__container"},e.createElement("div",{className:"promo-block-grid__top"},n&&e.createElement("h2",null,n),r&&e.createElement(E,{theme:"uobmain",inverse:t,text:r}),i&&e.createElement("div",{className:"promo-block-grid__text-link"},e.createElement(y,{theme:"uobmain",inverse:t,url:i.url,title:i.title,externalLink:i.externalLink}))),e.createElement("div",{className:"promo-block-grid__content"},e.createElement("div",{className:"promo-block-grid__cards"},o.length>0&&e.createElement("ul",{className:"promo-block-grid__grid"},o.map(function(c,a){return e.createElement("li",{className:"promo-block-grid__card-item",key:a},function(c){switch(l){case"promo":return e.createElement(Ae,d({},c));case"promo-signpost":return e.createElement($e,d({},c));case"promo-video":return e.createElement(Re,d({},c));default:return e.createElement(e.Fragment,null)}}(d(d({},c),{inverse:t,isSingle:1===o.length,imageOrientation:m,titleTag:n?"h3":"h2"})))}))))))}function Ll(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.title,r=c.description,i=c.cite,o=c.role,s=c.quote,m=c.quoteeProfileImage,h=c.quoteeProfileImageAltText,d=c.cta,u=c.fullWidth,v=void 0!==u&&u,f=c.htmlTag;return e.createElement("div",{className:p("quote-block","theme-".concat(t),l&&"theme-".concat(t,"--inverse"),v&&"quote-block--full-width")},(n||r)&&e.createElement(x,{theme:t,inverse:l,htmlTag:f,title:n,description:r}),e.createElement("blockquote",{className:p("quote-block__container",!m&&"quote-block__container--no-image")},e.createElement("div",{className:"quote-block__doublequote quote-block__doublequote--open"},e.createElement(_,{icon:"quote-marks",theme:t})),e.createElement("p",{className:"quote-block__quote"},s),m&&e.createElement("div",{className:"quote-block__quotee-image"},e.createElement(L,{src:{default:m},altText:h})),(i||o)&&e.createElement("footer",{className:"quote-block__cite"},i&&e.createElement("cite",{className:"quote-block__cite-cite"},i),o&&e.createElement("div",{className:"quote-block__cite-role"},o)),e.createElement("div",{className:"quote-block__doublequote quote-block__doublequote--close"},e.createElement(_,{icon:"quote-marks",theme:t})),d&&e.createElement("div",{className:"quote-block__optional-link"},e.createElement(y,{inverse:l,onKeyDown:function(){},theme:t,title:d.title,url:d.url}))))}function zl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.heading,o=c.description,s=c.linkProps,m=c.headingStyle,h=c.fullWidth,u=c.cards,v=xe("768px"),f=v&&u.length>1||!v&&h&&u.length>2||!v&&!h&&u.length>3,g=p(((a={})["related-courses__grid"]=!0,a["related-courses__grid--single"]=1===u.length,a["related-courses__grid--two-cards"]=2===u.length,a["related-courses__grid--three-cards"]=3===u.length,a["related-courses__grid--four-plus-cards"]=u.length>3,a));return e.createElement("section",{className:p("related-courses",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),h&&"related-courses--full-width")},e.createElement("div",{className:"related-courses__container"},e.createElement("h2",{className:p("related-courses__heading",m&&"related-courses__heading--".concat(m))},i),o&&e.createElement("div",{className:"related-courses__description"},o),s&&s.url&&s.title&&e.createElement("div",{className:"related-courses__arrow-link-container"},e.createElement(y,{theme:l,inverse:r,title:s.title,url:s.url})),e.createElement("div",{className:"related-courses__cards"},!f&&e.createElement("ul",{className:g},u.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},e.createElement(We,d({},c)))})),f&&e.createElement(ac,{theme:l,inverse:r,type:"related",cards:u,cardTitleTag:"h3"}))))}function Hl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.headingProps,m=c.cards,h=xe("768px"),u=h&&m.length>1||!h&&m.length>2,v=p(((a={})["scholarship-carousel__grid"]=!0,a["scholarship-carousel__grid--single"]=1===m.length,a["scholarship-carousel__grid--two-cards"]=2===m.length,a["scholarship-carousel__grid--three-plus-cards"]=m.length>3,a));return e.createElement("section",{className:p("scholarship-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"scholarship-carousel--full-width")},e.createElement("div",{className:"scholarship-carousel__container"},s&&e.createElement(x,d({},s,{theme:l,inverse:r,fullWidth:o})),e.createElement("div",{className:"scholarship-carousel__cards"},!u&&e.createElement("ul",{className:v},m.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},e.createElement(Je,d({},c,{inverse:r})))})),u&&e.createElement(ac,{theme:l,inverse:r,type:"scholarship",cards:m,cardTitleTag:"h3"}))))}function Vl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.heading,m=c.headingStyle,h=void 0===m?null:m,u=c.cards,v=c.singleLink,f=c.titleTag,g=void 0===f?"h2":f,E=c.useCarousel,_=void 0===E||E,b=c.cardType,w=void 0===b?"staff":b,q=xe("768px"),M=_&&q&&u.length>1||_&&!q&&u.length>2,C="staff"===w,k=p(((a={})["staff-listing-carousel__grid"]=!0,a["staff-listing-carousel__grid--single"]=1===u.length,a["staff-listing-carousel__grid--two-cards"]=2===u.length,a["staff-listing-carousel__grid--three-plus-cards"]=u.length>3,a));return e.createElement("section",{className:p("staff-listing-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"staff-listing-carousel--full-width",!_&&"staff-listing-carousel--no-carousel")},e.createElement("div",{className:"staff-listing-carousel__container"},s&&e.createElement(N,{htmlTag:g,classNames:p("staff-listing-carousel__heading","staff-listing-carousel__heading--".concat(g),h&&"staff-listing-carousel__heading--".concat(h))},s),e.createElement("div",{className:"staff-listing-carousel__cards"},!M&&e.createElement("ul",{className:k},u.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},C?e.createElement(Ue,d({},c,{theme:l,inverse:r,isSingle:1===u.length})):e.createElement(ec,d({},c,{theme:l,inverse:r})))})),M&&e.createElement(ac,{theme:l,inverse:r,type:w,cards:u,cardTitleTag:"h3"})),1===u.length&&v&&e.createElement(y,{theme:l,url:v.url,title:v.title,inverse:!0})))}function Sl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.sidebarElement,n=c.children;return e.createElement("div",{id:"sidebar",className:p("sidebar-wrapper",t&&"theme-".concat(t),!l&&"sidebar-wrapper--no-side-element")},e.createElement("div",{className:"sidebar-wrapper__grid-container"},l&&e.createElement("div",{className:"sidebar-wrapper__sidebar"},l),e.createElement("div",{className:"sidebar-wrapper__children"},n)))}function Pl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.items,i=c.fullWidth,o=void 0!==i&&i,s=c.htmlTag,m=void 0===s?"h2":s;return e.createElement("div",{className:p("signpost",o&&"signpost--full-width",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:"signpost__container"},e.createElement("div",{className:"signpost__grid"},r.map(function(c){return e.createElement("div",{className:"signpost__item",key:c.title},c.tag&&e.createElement("p",{className:"signpost__tag"},c.tag),e.createElement(N,{htmlTag:m,classNames:"signpost__title"},c.title),e.createElement(y,{url:c.linkUrl,title:c.linkLabel,theme:t,inverse:n,externalLink:c.external}))}))))}function Ol(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.includeIcon,i=c.link,o=c.fullWidth;return e.createElement("div",{className:p("single-button",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),o&&"single-button--full-width")},e.createElement("div",{className:"single-button__container"},r?e.createElement(Fe,d({},i,{inverse:!n})):e.createElement(q,d({},i,{inverse:!n}))))}function Zl(c){var a=c.theme,t=void 0===a?"uobmain":a;return e.createElement("div",{className:p("skip-to-content",t&&"theme-".concat(t))},e.createElement("a",{className:"skip-to-content__link",href:"#main"},"Skip to main content"))}function Bl(e,c){return g("".concat(null!=e?e:""," ").concat(c))}function Fl(c){var a=c.children,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0!==n&&n;return e.createElement("div",{className:p("tabs__list__container",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"))},e.createElement("ul",{className:"tabs__list",role:"tablist"},a))}function Dl(c){var a=c.title,t=c.htmlTag,l=void 0===t?"h3":t,n=c.theme,r=void 0===n?"uobmain":n,i=c.inverse,o=void 0!==i&&i,s=c.isActive,m=c.children,h=c.tabsBlockName;if(!s)return null;var d=Bl(null!=h?h:"",a);return e.createElement("div",{id:h,className:p("tabs__panel",r&&"theme-".concat(r),o&&"theme-".concat(r,"--inverse")),role:"tabpanel","aria-labelledby":"tab_"+d},e.createElement(N,{htmlTag:l,classNames:"tabs__panel-title"},a),m)}function Il(c){var a=c.id,n=c.theme,r=void 0===n?"uobmain":n,i=c.inverse,o=void 0!==i&&i,s=c.tabItem,m=c.isActive,h=c.hasFocus,d=c.tabsBlockName,u=c.handleClick,v=c.handleKeyboardNavigation,f=l(null);t(function(){m&&h&&f.current&&(f.current.focus(),window.matchMedia("min-width: 768px").matches&&f.current.scrollIntoView())});var g=Bl(null!=d?d:"",s.title);return e.createElement("li",{className:"tabs__list-item",role:"presentation"},e.createElement("button",{className:p("tabs__tab",r&&"theme-".concat(r),o&&"theme-".concat(r,"--inverse"),m&&"active"),onClick:function(e){return u(e,a)},onKeyDown:v,ref:f,id:"tab_"+g,role:"tab","aria-controls":g,"aria-selected":m?"true":"false",tabIndex:m?0:-1,type:"button"},s.title))}function Al(c){var r=c.theme,i=void 0===r?"uobmain":r,o=c.inverse,s=void 0!==o&&o,m=c.title,h=c.description,u=c.tabItems,v=c.fullWidth,f=c.htmlTag,g=void 0===f?"h2":f,_=c.removeBottomPadding,b=void 0!==_&&_,w=c.name,N=c.enableHashNavigation,C=void 0!==N&&N,k=l(null),L=n(function(){return u.findIndex(function(e){return Bl(null!=w?w:"",e.title)===window.location.hash.substring(1)})},[u,w]),z=a(0),H=z[0],V=z[1],S=a(-1),P=S[0],O=S[1],Z=xe("1248px");function B(e){if(C){var c=window.location.href.replace(window.location.hash,""),a=Bl(null!=w?w:"",u[e].title);history.pushState(null,"null",c.concat("#",a))}}function F(e,c){e.preventDefault(),V(c),B(c)}t(function(){if(0!==window.location.hash.length){var e=L();e<0||(V(e),O(e))}},[L,V]);var D=function(e){switch(e.key){case"ArrowLeft":case"ArrowUp":case"Left":case"Up":if(0===H)return;V(H-1),O(H-1),B(H-1);break;case"ArrowRight":case"ArrowDown":case"Right":case"Down":if(H>=u.length-1)return;V(H+1),O(H+1),B(H+1);break;case"Home":V(0),O(0),B(0);break;case"End":V(u.length-1),O(u.length-1),B(u.length-1)}};function I(){var e="h3";return m&&"h2"===g?e="h3":m&&"h3"===g&&(e="h4"),e}return t(function(){var e=function(e){if(e.preventDefault(),0!==window.location.hash.length){var c=L();c<0||(V(c),O(c))}};return window.addEventListener("hashchange",e),function(){window.removeEventListener("hashchange",e)}},[H,L]),e.createElement(e.Fragment,null,Z&&e.createElement(T,{heading:{title:m,description:h,fullWidth:v,htmlTag:g},theme:i,inverse:s,fullWidth:v,accordionItems:u.map(function(e,c){return{key:e.title||c,title:e.title,text:e.content,titleTag:e.titleTag?e.titleTag:I(),primaryButton:e.primaryButton,secondaryButton:e.secondaryButton,link:e.link}})}),e.createElement("div",{className:p("tabs",i&&"theme-".concat(i),s&&"theme-".concat(i,"--inverse"),v&&"tabs--full-width",b&&"tabs--no-bottom-padding"),id:"tabs",ref:k},!Z&&e.createElement(e.Fragment,null,e.createElement(x,{theme:i,inverse:s,htmlTag:g,title:m,description:h,fullWidth:v}),e.createElement("div",{className:"tabs__container"},e.createElement("span",null,e.createElement(Fl,{theme:i,inverse:s},u.map(function(c,a){return e.createElement(Il,{key:a,id:a,theme:i,inverse:s,tabItem:c,tabListTopRef:k,isActive:a===H,hasFocus:a===P,enableHashNavigation:C,tabsBlockName:w,handleClick:F,handleKeyboardNavigation:D})})),u.map(function(c,a){return e.createElement(Dl,{key:a,isActive:a===H,inverse:s,theme:i,title:c.title,tabsBlockName:w,htmlTag:c.titleTag?c.titleTag:I()},c.content&&e.createElement(E,{theme:i,inverse:s,text:c.content}),c.accordionItems&&c.accordionItems.map(function(c){return e.createElement(M,d({key:c.key},c,{inverse:s}))}),(c.primaryButton&&c.primaryButton.text||c.secondaryButton&&c.secondaryButton.text)&&e.createElement("div",{className:"tabs__optional-buttons"},c.primaryButton&&c.primaryButton.text&&e.createElement(q,{label:c.primaryButton.text,url:c.primaryButton.url,theme:i,inverse:!s}),c.secondaryButton&&c.secondaryButton.text&&e.createElement(q,{hollow:!0,label:c.secondaryButton.text,url:c.secondaryButton.url,theme:i,inverse:!s})),c.link&&c.link.text&&e.createElement("div",{className:"tabs__optional-link"},e.createElement(y,{theme:i,inverse:s,url:c.link.url,title:c.link.text})))}))))))}function $l(c){var a=c.text,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=c.headingLevel,i=c.headingText,o=c.url,s=c.linkTitle,m=c.externalLink,h=c.linkStyle,d=c.fullWidth,u=c.removeBottomPadding,v=void 0!==u&&u,f=r;return e.createElement("div",{className:p("text-with-background",l&&"theme-".concat(l),n&&"theme-".concat(l,"--inverse"),d&&"text-with-background--full-width",v&&"text-with-background--no-bottom-padding")},i&&e.createElement("div",{className:"text-with-background__heading-wrapper"},e.createElement(f,null,i)),e.createElement(E,{text:a,inverse:n,theme:l}),o&&s&&e.createElement("div",{className:"text-with-background__link-wrapper"},e.createElement("div",{className:"text-with-background__link-inner-wrapper"},("primary"===h||"secondary"===h)&&e.createElement(q,{url:o,theme:l,label:s,externalLink:m,hollow:"secondary"===h,inverse:!n}),"paragraph-link"===h&&e.createElement(St,{url:o,label:s,externalLink:m,theme:l,inverse:n}))))}function Rl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.label,n=c.url,r=c.externalLink;return e.createElement("a",{className:p("pill",t&&"theme-".concat(t)),href:n,target:r?"_blank":"_self",rel:r?"noopener noreferrer":""},l)}function jl(c){var a=c.topics,t=c.theme,l=void 0===t?"uobmain":t,n=c.titleTag,r=c.heading;return e.createElement("section",{className:p("topics-selector",l&&"theme-".concat(l))},e.createElement("div",{className:"topics-selector__container"},"h2"===n?e.createElement("h2",{className:"topics-selector__heading"},r):e.createElement("h3",{className:"topics-selector__heading"},r),e.createElement("ul",{className:"topics-selector__topics-container"},a.map(function(c,a){return e.createElement("li",{className:"topics-selector__topic",key:a},e.createElement(Rl,{theme:l,label:c.label,url:c.url,externalLink:c.externalLink}))}))))}tl.displayName="HeroCardContent",h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h();var Ul,Wl={exports:{}};var Gl,Kl=(Ul||(Ul=1,Gl=Wl,function(e,c){Gl.exports=c()}(0,function(){var e=[],c=[],a={},t={},l={};function n(e){return"string"==typeof e?new RegExp("^"+e+"$","i"):e}function r(e,c){return e===c?c:e===e.toLowerCase()?c.toLowerCase():e===e.toUpperCase()?c.toUpperCase():e[0]===e[0].toUpperCase()?c.charAt(0).toUpperCase()+c.substr(1).toLowerCase():c.toLowerCase()}function i(e,c){return e.replace(c[0],function(a,t){var l,n,i=(l=c[1],n=arguments,l.replace(/\$(\d{1,2})/g,function(e,c){return n[c]||""}));return r(""===a?e[t-1]:a,i)})}function o(e,c,t){if(!e.length||a.hasOwnProperty(e))return c;for(var l=t.length;l--;){var n=t[l];if(n[0].test(c))return i(c,n)}return c}function s(e,c,a){return function(t){var l=t.toLowerCase();return c.hasOwnProperty(l)?r(t,l):e.hasOwnProperty(l)?r(t,e[l]):o(l,t,a)}}function m(e,c,a,t){return function(t){var l=t.toLowerCase();return!!c.hasOwnProperty(l)||!e.hasOwnProperty(l)&&o(l,l,a)===l}}function h(e,c,a){return(a?c+" ":"")+(1===c?h.singular(e):h.plural(e))}return h.plural=s(l,t,e),h.isPlural=m(l,t,e),h.singular=s(t,l,c),h.isSingular=m(t,l,c),h.addPluralRule=function(c,a){e.push([n(c),a])},h.addSingularRule=function(e,a){c.push([n(e),a])},h.addUncountableRule=function(e){"string"!=typeof e?(h.addPluralRule(e,"$0"),h.addSingularRule(e,"$0")):a[e.toLowerCase()]=!0},h.addIrregularRule=function(e,c){c=c.toLowerCase(),e=e.toLowerCase(),l[e]=c,t[c]=e},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach(function(e){return h.addIrregularRule(e[0],e[1])}),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach(function(e){return h.addPluralRule(e[0],e[1])}),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach(function(e){return h.addSingularRule(e[0],e[1])}),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(h.addUncountableRule),h})),Wl.exports),Yl=Gc(Kl);function Jl(c){var t=c.theme,l=c.heading,n=c.selectContent,r=c.defaultIsOpen,i=void 0!==r&&r;n&&(i=!!n.defaultValue||i);var o=a(i),s=o[0],m=o[1];return e.createElement("fieldset",{className:p("filter-accordion-select",s&&"filter-accordion-select--open",t&&"theme-".concat(t))},e.createElement("legend",{className:"filter-accordion-select__legend"},e.createElement("button",{className:"filter-accordion-select__button",onClick:function(){return m(function(e){return!e})},"aria-expanded":s,"aria-controls":l.replace(" ","")},l,e.createElement(_,{icon:"chevron-down",theme:t,inverse:!0,ariaHidden:!0}))),s&&e.createElement("div",{className:"filter-accordion-select__select-wrapper"},e.createElement(Lt,d({theme:t,inverse:!0},n))))}function Xl(c){var a=c.theme,t=c.name,l=c.id,n=c.label,r=c.defaultValue,i=c.onChange;return e.createElement("div",{className:p("date-input",a&&"theme-".concat(a))},e.createElement("label",{htmlFor:l,className:"date-input__label"},n),e.createElement("input",{type:"date",className:"date-input__input",defaultValue:r,onChange:i,name:t,id:l}))}h(),h(),h();var Ql,en=function(e){var c=e.split(" "),a=c[c.length-1];return c[c.length-1]=Yl(a),c.join(" ")};function cn(c){var a=c.theme,t=c.heading,l=c.listingGroups,n=c.onClearFilters,r=c.onViewResults;return e.createElement("div",{className:p("standard-listing-filter",a&&"theme-".concat(a))},e.createElement("p",{className:"standard-listing-filter__heading"},t),e.createElement("ul",{className:"standard-listing-filter__list"},l.map(function(c){var t;return"date"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Xl,d({},c,{theme:a,defaultValue:null!==(t=c.defaultValue)&&void 0!==t?t:"",onChange:c.onChange}))):"radio"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Uc,{type:"radio",heading:c.heading,theme:a,showMoreText:en(c.heading)||"",inputs:c.inputs.map(function(e){return{name:c.name,value:e.value,label:e.label,id:e.id,defaultChecked:!!c.defaultValue&&c.defaultValue===e.value,onChange:c.onChange}})})):"checkbox"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Uc,{type:"checkbox",heading:c.heading,theme:a,showMoreText:en(c.heading)||"",inputs:c.inputs.map(function(e){return{name:c.name,value:e.value,label:e.label,id:e.id,defaultChecked:!!c.defaultValues&&c.defaultValues.includes(e.value),onChange:c.onChange}})})):"select"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Jl,{heading:c.heading,selectContent:c.selectContent,theme:a})):void 0})),r&&e.createElement("div",{className:"standard-listing-filter__results-button"},e.createElement(q,{label:"View selected results",onClick:r,theme:a})),e.createElement("div",{className:"standard-listing-filter__clear-button"},e.createElement(q,{label:"Clear filters",onClick:n,theme:a,hollow:!0})))}function an(c){var a=c.theme,t=c.tag,l=c.title,n=c.linkUrl,r=c.linkText,o=c.externalLink,s=c.cards,m={initial:{opacity:0,y:150},animate:function(e){return{opacity:1,y:0,transition:{duration:.8,type:"spring",bounce:.2,delay:.2*e}}}};return e.createElement("div",{className:p("video-card-component",a&&"theme-".concat(a)),id:"video-card-component"},e.createElement("div",{className:"video-card-component__content"},t&&e.createElement("p",{className:"video-card-component__tag"},t),e.createElement("h2",{className:"video-card-component__title"},l),n&&r&&e.createElement("div",{className:"video-card-component__link"},e.createElement(y,{theme:a,url:n,title:r,inverse:!0,externalLink:o})),e.createElement("div",{className:"video-card-component__carousel"},e.createElement(ac,{theme:a,type:"video",inverse:!0,cards:s,cardTitleTag:"h3"})),e.createElement("ul",{className:p("video-card-component__cards-desktop",(!n||!r)&&"video-card-component__cards-desktop--no-link")},s.map(function(c,t){return e.createElement(i.li,{key:t,variants:m,initial:"initial",whileInView:"animate",viewport:{once:!0,amount:.2},custom:t},t<=1?e.createElement("div",{className:"video-card-component__lines video-card-component__lines--".concat(t)},1===t&&e.createElement("svg",{width:"406",height:"128",viewBox:"0 0 406 128",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("path",{d:"M1 1L123 29L210 127.5",stroke:"black"}),e.createElement("path",{d:"M13 112L123 29L405 51",stroke:"black"}))):"",e.createElement(De,{theme:a,image:{src:{default:c.image.src.default,medium:c.image.src.medium,small:c.image.src.small},altText:""},title:c.title,youtubeId:c.youtubeId,buttonLabel:c.buttonLabel,titleTag:"h3"}))}))))}function tn(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.imageSrc,n=c.onClick;return e.createElement("div",{className:p("video-placeholder",t&&"theme-".concat(t))},e.createElement(L,{src:l,altText:""}),e.createElement("button",{className:"video-placeholder__button",onClick:n},e.createElement("div",{className:"video-placeholder__svg-wrapper"},e.createElement("svg",{width:"11",height:"14",viewBox:"0 0 11 14",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},e.createElement("path",{d:"M0 0V14L11 7L0 0Z",fill:"currentColor"}))),e.createElement("span",{className:"sr-only"},"Watch the video")))}function ln(c){var t=c.theme,l=void 0===t?"uobmain":t,n=c.imageSrc,r=c.videoUrl,i=c.videoId,o=a(!1),s=o[0],m=o[1];return e.createElement("div",{className:p("video-with-placeholder",l&&"theme-".concat(l))},s?e.createElement(Pe,{url:r,id:i,autoPlay:!0,theme:l}):e.createElement(tn,{imageSrc:n,onClick:function(){return m(!0)},theme:l}))}function nn(c){var t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0!==n&&n,i=c.imageSrc,o=c.videoUrl,s=c.videoId,m=c.heading,h=c.audioDescribedVideoId,u=c.audioDescribedVideoUrl,v=c.transcript,f=c.fullWidth,g=void 0!==f&&f,E=c.videoCaption,_=c.videoCredit,b=a(!1),w=b[0],q=b[1];return e.createElement("div",{className:p("video-embed",g&&"video-embed--full-width",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"))},m&&e.createElement(x,d({},m,{theme:l,inverse:r})),e.createElement("div",{className:"video-embed__grid"},e.createElement("div",{className:"video-embed__content-wrapper"},e.createElement(ln,{theme:l,imageSrc:i,videoUrl:w?o:u,videoId:w?h:s}),(E||_)&&e.createElement("div",{className:"video-embed__caption-wrapper"},E&&e.createElement("p",{className:"video-embed__caption"},E),_&&e.createElement("p",{className:"video-embed__credit"},_)),(h||u)&&(w?e.createElement("button",{className:"video-embed__audio-described-button",onClick:function(){return q(!1)}},"Non-audio described version"):e.createElement("button",{className:"video-embed__audio-described-button",onClick:function(){return q(!0)}},"Audio described version")),v&&e.createElement("div",{className:"video-embed__transcript"},e.createElement(M,{titleTag:"h3",theme:l,title:"Transcript",text:v,inverse:r})))))}function rn(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.heading,m=c.description,h=c.cards,u=c.singleLink,v=c.titleTag,f=void 0===v?"h2":v,g=c.cardTitleTag,E=void 0===g?"h3":g,_=xe("768px"),b=_&&h.length>1||!_&&h.length>2,w=p(((a={})["research-story-carousel__grid"]=!0,a["research-story-carousel__grid--single"]=1===h.length,a["research-story-carousel__grid--two-cards"]=2===h.length,a["research-story-carousel__grid--three-plus-cards"]=h.length>3,a));return e.createElement("section",{className:p("research-story-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"research-story-carousel--full-width")},e.createElement("div",{className:"research-story-carousel__container"},(s||m||u)&&e.createElement(x,{theme:l,inverse:!0,htmlTag:f,title:s,description:m,linkProps:u,fullWidth:!0}),e.createElement("div",{className:"research-story-carousel__cards"},!b&&e.createElement("ul",{className:w},h.map(function(c,a){return e.createElement("li",{key:a},e.createElement(Ye,d({},c)))})),b&&e.createElement(ac,{theme:l,inverse:r,type:"research-story",cards:h,cardTitleTag:E}))))}function on(c){var i=c.text,o=c.theme,s=void 0===o?"uobmain":o,m=c.inverse,h=c.fullWidth,d=void 0!==h&&h,u=c.removeBottomPadding,v=void 0!==u&&u,f=c.tableCategory,g=void 0===f?Ql.NotSpecified:f,E=l(null),_=a(!1),b=_[0],w=_[1],q=a(!0),y=q[0],M=q[1],N=a(!1),C=N[0],k=N[1],x=r(),T=function(){var e=E.current;e&&(w(e.scrollLeft>0),M(e.scrollLeft<e.scrollWidth-e.clientWidth))},L=n(function(){var e=E.current;if(e){var c=e.scrollWidth>e.clientWidth;k(c),T()}},[]),z=function(e){var c=E.current;if(c){var a="left"===e?c.scrollLeft-200:c.scrollLeft+200;c.scrollTo({left:a,behavior:"smooth"})}};return t(function(){L();var e=E.current;e&&e.addEventListener("scroll",T);var c=function(){return L()};return window.addEventListener("resize",c),function(){e&&e.removeEventListener("scroll",T),window.removeEventListener("resize",c)}},[L]),e.createElement("div",{className:p("scrollable-table",d&&"scrollable-table--full-width",s&&"theme-".concat(s),m&&"theme-".concat(s,"--inverse"),v&&"scrollable-table--no-bottom-padding")},e.createElement("div",{className:"scrollable-table__container"},e.createElement("span",null,C&&e.createElement("div",{className:"scrollable-table__scroll-button-wrapper"},e.createElement("p",null,"Scroll buttons"),e.createElement(Oe,{key:"iconButtonLeft",theme:s,icon:"arrow-left",onClick:function(){return z("left")},title:"Scroll left",ariaControls:x,disabled:!b,inverse:m}),e.createElement(Oe,{key:"iconButtonRight",theme:s,icon:"arrow-right",onClick:function(){return z("right")},title:"Scroll right",ariaControls:x,disabled:!y,inverse:m})),e.createElement("div",{className:p("scrollable-table__table-wrapper","scrollable-table__".concat(g),m&&"scrollable-table__".concat(g,"--inverse")),ref:E,id:x,tabIndex:0},e.createElement("span",{dangerouslySetInnerHTML:{__html:i}})))))}function sn(c){var t=c.theme,l=c.heading,n=c.inverse,r=c.description,i=c.buttonLabel,o=c.buttonModifier,s=c.modalChildren,m=c.htmlTag,h=void 0===m?"h3":m,d=a(!1),u=d[0],v=d[1],f=function(){v(!1),document.body.classList.remove("lock-scroll")};return e.createElement("div",{className:p("modal-cta",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement(N,{htmlTag:h,classNames:"modal-cta__heading"},l),r&&e.createElement("p",{className:"modal-cta__description"},r),e.createElement("div",{className:p("modal-cta__button",o&&"theme-".concat(t,"--buttonModifier"))},e.createElement(q,{inverse:!n,label:i,onClick:function(){u?f():(v(!0),document.body.classList.add("lock-scroll"))},theme:t,buttonModifier:o})),u&&e.createElement(Be,{centred:!0,theme:t,closeModal:f,isOpen:u},e.createElement(sc,{className:"modal-cta__embed-wrapper"},s)))}function mn(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.cards,i=Array.isArray(r)?r:[r];return e.createElement("div",{className:p("module-card-group",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:"module-card-group__container"},e.createElement("div",{className:"module-card-group__grid"},i.map(function(c,a){return e.createElement(w,d({key:a},c,{theme:t}))}))))}function hn(c){var a=c.theme,t=c.embedChildren,l=c.googleMapLink,n=c.address,r=c.services,i=c.link,o=c.titleTag,s=void 0===o?"h2":o;return e.createElement("section",{className:p("location-section",a&&"theme-".concat(a),(!r||r.length<1)&&"location-section--no-services")},e.createElement("div",{className:"location-section__container"},e.createElement(N,{htmlTag:s,classNames:p("location-section__title","h3"===s&&"location-section__title--h3")},"Location"),e.createElement("div",{className:"location-section__grid-wrapper"},e.createElement("div",{className:"location-section__embed"},e.createElement(sc,null,t)),e.createElement("div",{className:"location-section__address-wrapper"},e.createElement("div",{className:"location-section__address"},e.createElement(Ic,{theme:a,title:"Address",iconType:"slim-location",value:n.map(function(e){return"<span>".concat(e,"</span>")}).join("")})),i&&(null==i?void 0:i.title)&&(null==i?void 0:i.url)&&e.createElement("div",{className:"location-section__link-wrapper"},e.createElement(y,d({},i,{inverse:!0}))),l?e.createElement("div",{className:"location-section__button"},e.createElement(q,{label:"View on Google Maps",theme:a,url:l})):null),(null==r?void 0:r.length)?e.createElement("div",{className:"location-section__services"},null==r?void 0:r.map(function(c,t){return e.createElement(Ic,d({},c,{theme:a,key:t}))})):null)))}function dn(c){var a=c.theme,t=c.studentName,l=c.studentStatus,n=c.courseName,r=c.courseDetails,i=c.studyLevel,o=c.titleTag,s=void 0===o?"h2":o,m=c.homeCountry,h=c.studentIntro,u=c.image,v=c.inverse;return e.createElement("div",{className:p("heroProfile",a&&"theme-".concat(a),v&&"theme-".concat(a,"--inverse")),id:"hero"},e.createElement("div",{className:"heroProfile__container"},e.createElement("div",{className:"heroProfile__details"},t&&e.createElement(s,{className:"heroProfile__title"},t),l&&e.createElement("p",{className:"heroProfile__status"},l),n&&e.createElement("p",{className:"heroProfile__courseName"},n),(i||m||r&&r.length>0)&&e.createElement("ul",{className:"heroProfile__studentDetails"},r&&r.length>0&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"mortar-board",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__courseIconText"},e.createElement("span",null,1===r.length?"Course":"Courses",":"),e.createElement("div",{className:"heroProfile__courseDetails"},r.map(function(c,t){return e.createElement(C,{theme:a,key:t,text:c,inverse:v})}))))),i&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"scroll",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__iconText"},e.createElement("span",null,"Study level:"),e.createElement("span",null,i)))),m&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"flag",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__iconText"},e.createElement("span",null,"Home country:"),e.createElement("span",null,m))))),h&&e.createElement(C,{theme:a,text:h,inverse:v})),e.createElement("div",{className:"heroProfile__image-wrapper"},u&&e.createElement(L,d({},u,{altText:null==u?void 0:u.alt,fetchPriority:u.fetchPriority})))))}function un(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.firstColumn,n=c.secondColumn;return e.createElement("div",{className:p("two-column-wrapper",t&&"theme-".concat(t))},e.createElement("div",{className:"two-column-wrapper__grid-container"},e.createElement("div",{className:p("two-column-wrapper__first-column",!n&&"two-column-wrapper__first-column-centred")},l),n&&e.createElement("div",{className:"two-column-wrapper__second-column"},n)))}function vn(c){var a,t,l=c.theme,n=void 0===l?"uobmain":l,r=c.inverse,i=c.logos,o=null!==(t=null==i?void 0:i.length)&&void 0!==t?t:0,s=i&&i.length%2!=0;return e.createElement("div",{className:p("logo-wall",n&&"theme-".concat(n),r&&"theme-".concat(n,"--inverse"))},e.createElement("div",null,e.createElement("ul",{className:p("logo-wall__container",s&&"logo-wall__container--odd"),style:(a={},a["--logo-wall-cols"]=String(o),a)},i&&i.map(function(c,a){var t;return e.createElement("li",{key:"li-".concat(a)},e.createElement(Ge,d({key:"".concat((null===(t=c.image)||void 0===t?void 0:t.title)||"imageTitle","-").concat(a),theme:n,inverse:r},c)))}))))}h(),h(),h(),h(),h(),h(),function(e){e.NotSpecified="NotSpecified",e.ColumnAndRowHeadings="ColumnAndRowHeadings",e.ColumnHeadingsOnly="ColumnHeadingsOnly"}(Ql||(Ql={})),h(),h(),h(),h(),h(),h();export{T as Accordion,z as AcreditationPromotion,V as AlertBanner,S as AnchorTarget,O as Breadcrumbs,oc as CTAComponent,lc as CardImageAndText,tc as CardProfile,ec as CardPromoProfile,$e as CardPromoSignpost,Ue as CardStaff,ac as Carousel,nc as CentreWrapper,rc as ClearingBanner,ic as CourseDeliveryPills,sc as EmbedWrapper,hc as FactBoxes,dc as FeaturedContent,Lc as FeaturedSignpost,Hc as FeaturedVideo,Vc as FiveArticlesGrid,Bc as Footer,Wc as GeneralSearchFilter,$c as GenericDetailSection,Nt as Header,x as Heading,Ht as Hero,Pt as HeroArticle,ll as HeroCarousel,It as HeroCourses,dn as HeroProfile,nl as ImageBlock,rl as ImageCarousel,ol as InPageNavigation,sl as IntroText,hl as LeadNewsArticles,yl as ListTable,dl as ListingFilterWrapper,wl as ListingResults,ql as ListingResultsCount,hn as LocationSection,Dt as LocationSelector,vn as LogoWall,Ml as MainWrapper,sn as ModalCTA,mn as ModuleCardGroup,Nl as NewsArticlesPromoBlock,kl as Pagination,xl as PromoBlock,Tl as PromoBlockGrid,Ll as QuoteBlock,zl as RelatedCourses,rn as ResearchStoryCarousel,E as RichText,Hl as ScholarshipCarousel,on as ScrollableTable,zt as SearchCourses,Sl as SidebarWrapper,Pl as SignPost,Ol as SingleButton,Zl as SkipToContent,Vl as StaffListingCarousel,cn as StandardListingFilter,Al as TabsBlock,$l as TextWithBackground,jl as TopicSelector,un as TwoColumnWrapper,an as VideoCardComponent,nn as VideoEmbed};
|
|
23
|
+
function Ka(e,c){(null==c||c>e.length)&&(c=e.length);for(var a=0,t=Array(c);a<c;a++)t[a]=e[a];return t}function Ya(e,c,a){return(c=function(e){var c=function(e,c){if("object"!=typeof e||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var t=a.call(e,c);if("object"!=typeof t)return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===c?String:Number)(e)}(e,"string");return"symbol"==typeof c?c:c+""}(c))in e?Object.defineProperty(e,c,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[c]=a,e}function Ja(e,c){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);c&&(t=t.filter(function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable})),a.push.apply(a,t)}return a}function Xa(e){for(var c=1;c<arguments.length;c++){var a=null!=arguments[c]?arguments[c]:{};c%2?Ja(Object(a),!0).forEach(function(c){Ya(e,c,a[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Ja(Object(a)).forEach(function(c){Object.defineProperty(e,c,Object.getOwnPropertyDescriptor(a,c))})}return e}function Qa(e){return function(e){if(Array.isArray(e))return Ka(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,c){if(e){if("string"==typeof e)return Ka(e,c);var a={}.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?Ka(e,c):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var et,ct,at=function(e,c){if(e.length>0){var a=e[e.length-1];a!==c&&a._setPausedState(!0)}var t=e.indexOf(c);-1===t||e.splice(t,1),e.push(c)},tt=function(e,c){var a=e.indexOf(c);-1!==a&&e.splice(a,1),e.length>0&&!e[e.length-1]._isManuallyPaused()&&e[e.length-1]._setPausedState(!1)},lt=function(e){return"Tab"===(null==e?void 0:e.key)||9===(null==e?void 0:e.keyCode)},nt=function(e){return lt(e)&&!e.shiftKey},rt=function(e){return lt(e)&&e.shiftKey},it=function(e){return setTimeout(e,0)},ot=function(e){for(var c=arguments.length,a=new Array(c>1?c-1:0),t=1;t<c;t++)a[t-1]=arguments[t];return"function"==typeof e?e.apply(void 0,a):e},st=function(e){return e.target.shadowRoot&&"function"==typeof e.composedPath?e.composedPath()[0]:e.target},mt=[],ht=Kc(Object.freeze({__proto__:null,createFocusTrap:function(e,c){var a,t=(null==c?void 0:c.document)||document,l=(null==c?void 0:c.trapStack)||mt,n=Xa({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:nt,isKeyBackward:rt},c),r={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},i=function(e,c,a){return e&&void 0!==e[c]?e[c]:n[a||c]},o=function(e,c){var a="function"==typeof(null==c?void 0:c.composedPath)?c.composedPath():void 0;return r.containerGroups.findIndex(function(c){var t=c.container,l=c.tabbableNodes;return t.contains(e)||(null==a?void 0:a.includes(t))||l.find(function(c){return c===e})})},s=function(e){var c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=c.hasFallback,l=void 0!==a&&a,r=c.params,i=void 0===r?[]:r,o=n[e];if("function"==typeof o&&(o=o.apply(void 0,Qa(i))),!0===o&&(o=void 0),!o){if(void 0===o||!1===o)return o;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var s=o;if("string"==typeof o){try{s=t.querySelector(o)}catch(c){throw new Error("`".concat(e,'` appears to be an invalid selector; error="').concat(c.message,'"'))}if(!s&&!l)throw new Error("`".concat(e,"` as selector refers to no known node"))}return s},m=function(){var e=s("initialFocus",{hasFallback:!0});if(!1===e)return!1;if(void 0===e||e&&!Wa(e,n.tabbableOptions))if(o(t.activeElement)>=0)e=t.activeElement;else{var c=r.tabbableGroups[0];e=c&&c.firstTabbableNode||s("fallbackFocus")}else null===e&&(e=s("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},h=function(){if(r.containerGroups=r.containers.map(function(e){var c=$a(e,n.tabbableOptions),a=Ra(e,n.tabbableOptions),t=c.length>0?c[0]:void 0,l=c.length>0?c[c.length-1]:void 0,r=a.find(function(e){return ja(e)}),i=a.slice().reverse().find(function(e){return ja(e)}),o=!!c.find(function(e){return Va(e)>0});return{container:e,tabbableNodes:c,focusableNodes:a,posTabIndexesFound:o,firstTabbableNode:t,lastTabbableNode:l,firstDomTabbableNode:r,lastDomTabbableNode:i,nextTabbableNode:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],l=c.indexOf(e);return l<0?t?a.slice(a.indexOf(e)+1).find(function(e){return ja(e)}):a.slice(0,a.indexOf(e)).reverse().find(function(e){return ja(e)}):c[l+(t?1:-1)]}}}),r.tabbableGroups=r.containerGroups.filter(function(e){return e.tabbableNodes.length>0}),r.tabbableGroups.length<=0&&!s("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(r.containerGroups.find(function(e){return e.posTabIndexesFound})&&r.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},d=function(e){var c=e.activeElement;if(c)return c.shadowRoot&&null!==c.shadowRoot.activeElement?d(c.shadowRoot):c},u=function(e){!1!==e&&e!==d(document)&&(e&&e.focus?(e.focus({preventScroll:!!n.preventScroll}),r.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):u(m()))},v=function(e){var c=s("setReturnFocus",{params:[e]});return c||!1!==c&&e},p=function(e){var c=e.target,a=e.event,t=e.isBackward,l=void 0!==t&&t;c=c||st(a),h();var i=null;if(r.tabbableGroups.length>0){var m=o(c,a),d=m>=0?r.containerGroups[m]:void 0;if(m<0)i=l?r.tabbableGroups[r.tabbableGroups.length-1].lastTabbableNode:r.tabbableGroups[0].firstTabbableNode;else if(l){var u=r.tabbableGroups.findIndex(function(e){var a=e.firstTabbableNode;return c===a});if(u<0&&(d.container===c||Wa(c,n.tabbableOptions)&&!ja(c,n.tabbableOptions)&&!d.nextTabbableNode(c,!1))&&(u=m),u>=0){var v=0===u?r.tabbableGroups.length-1:u-1,p=r.tabbableGroups[v];i=Va(c)>=0?p.lastTabbableNode:p.lastDomTabbableNode}else lt(a)||(i=d.nextTabbableNode(c,!1))}else{var f=r.tabbableGroups.findIndex(function(e){var a=e.lastTabbableNode;return c===a});if(f<0&&(d.container===c||Wa(c,n.tabbableOptions)&&!ja(c,n.tabbableOptions)&&!d.nextTabbableNode(c))&&(f=m),f>=0){var g=f===r.tabbableGroups.length-1?0:f+1,E=r.tabbableGroups[g];i=Va(c)>=0?E.firstTabbableNode:E.firstDomTabbableNode}else lt(a)||(i=d.nextTabbableNode(c))}}else i=s("fallbackFocus");return i},f=function(e){var c=st(e);o(c,e)>=0||(ot(n.clickOutsideDeactivates,e)?a.deactivate({returnFocus:n.returnFocusOnDeactivate}):ot(n.allowOutsideClick,e)||e.preventDefault())},g=function(e){var c=st(e),a=o(c,e)>=0;if(a||c instanceof Document)a&&(r.mostRecentlyFocusedNode=c);else{var t;e.stopImmediatePropagation();var l=!0;if(r.mostRecentlyFocusedNode)if(Va(r.mostRecentlyFocusedNode)>0){var i=o(r.mostRecentlyFocusedNode),s=r.containerGroups[i].tabbableNodes;if(s.length>0){var h=s.findIndex(function(e){return e===r.mostRecentlyFocusedNode});h>=0&&(n.isKeyForward(r.recentNavEvent)?h+1<s.length&&(t=s[h+1],l=!1):h-1>=0&&(t=s[h-1],l=!1))}}else r.containerGroups.some(function(e){return e.tabbableNodes.some(function(e){return Va(e)>0})})||(l=!1);else l=!1;l&&(t=p({target:r.mostRecentlyFocusedNode,isBackward:n.isKeyBackward(r.recentNavEvent)})),u(t||(r.mostRecentlyFocusedNode||m()))}r.recentNavEvent=void 0},E=function(e){(n.isKeyForward(e)||n.isKeyBackward(e))&&function(e){var c=arguments.length>1&&void 0!==arguments[1]&&arguments[1];r.recentNavEvent=e;var a=p({event:e,isBackward:c});a&&(lt(e)&&e.preventDefault(),u(a))}(e,n.isKeyBackward(e))},_=function(e){var c;"Escape"!==(null==(c=e)?void 0:c.key)&&"Esc"!==(null==c?void 0:c.key)&&27!==(null==c?void 0:c.keyCode)||!1===ot(n.escapeDeactivates,e)||(e.preventDefault(),a.deactivate())},b=function(e){var c=st(e);o(c,e)>=0||ot(n.clickOutsideDeactivates,e)||ot(n.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},w=function(){if(r.active)return at(l,a),r.delayInitialFocusTimer=n.delayInitialFocus?it(function(){u(m())}):u(m()),t.addEventListener("focusin",g,!0),t.addEventListener("mousedown",f,{capture:!0,passive:!1}),t.addEventListener("touchstart",f,{capture:!0,passive:!1}),t.addEventListener("click",b,{capture:!0,passive:!1}),t.addEventListener("keydown",E,{capture:!0,passive:!1}),t.addEventListener("keydown",_),a},q=function(){if(r.active)return t.removeEventListener("focusin",g,!0),t.removeEventListener("mousedown",f,!0),t.removeEventListener("touchstart",f,!0),t.removeEventListener("click",b,!0),t.removeEventListener("keydown",E,!0),t.removeEventListener("keydown",_),a},y="undefined"!=typeof window&&"MutationObserver"in window?new MutationObserver(function(e){e.some(function(e){return Array.from(e.removedNodes).some(function(e){return e===r.mostRecentlyFocusedNode})})&&u(m())}):void 0,M=function(){y&&(y.disconnect(),r.active&&!r.paused&&r.containers.map(function(e){y.observe(e,{subtree:!0,childList:!0})}))};return a={get active(){return r.active},get paused(){return r.paused},activate:function(e){if(r.active)return this;var c=i(e,"onActivate"),a=i(e,"onPostActivate"),l=i(e,"checkCanFocusTrap");l||h(),r.active=!0,r.paused=!1,r.nodeFocusedBeforeActivation=d(t),null==c||c();var n=function(){l&&h(),w(),M(),null==a||a()};return l?(l(r.containers.concat()).then(n,n),this):(n(),this)},deactivate:function(e){if(!r.active)return this;var c=Xa({onDeactivate:n.onDeactivate,onPostDeactivate:n.onPostDeactivate,checkCanReturnFocus:n.checkCanReturnFocus},e);clearTimeout(r.delayInitialFocusTimer),r.delayInitialFocusTimer=void 0,q(),r.active=!1,r.paused=!1,M(),tt(l,a);var t=i(c,"onDeactivate"),o=i(c,"onPostDeactivate"),s=i(c,"checkCanReturnFocus"),m=i(c,"returnFocus","returnFocusOnDeactivate");null==t||t();var h=function(){it(function(){m&&u(v(r.nodeFocusedBeforeActivation)),null==o||o()})};return m&&s?(s(v(r.nodeFocusedBeforeActivation)).then(h,h),this):(h(),this)},pause:function(e){return r.active?(r.manuallyPaused=!0,this._setPausedState(!0,e)):this},unpause:function(e){return r.active?(r.manuallyPaused=!1,l[l.length-1]!==this?this:this._setPausedState(!1,e)):this},updateContainerElements:function(e){var c=[].concat(e).filter(Boolean);return r.containers=c.map(function(e){return"string"==typeof e?t.querySelector(e):e}),r.active&&h(),M(),this}},Object.defineProperties(a,{_isManuallyPaused:{value:function(){return r.manuallyPaused}},_setPausedState:{value:function(e,c){if(r.paused===e)return this;if(r.paused=e,e){var a=i(c,"onPause"),t=i(c,"onPostPause");null==a||a(),q(),M(),null==t||t()}else{var l=i(c,"onUnpause"),n=i(c,"onPostUnpause");null==l||l(),h(),w(),M(),null==n||n()}return this}}}),a.updateContainerElements(e),a}})),dt=Kc(Ga);var ut=function(){if(ct)return et;function c(e){return c="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},c(e)}function a(e,c,a){return c&&function(e,c){for(var a=0;a<c.length;a++){var t=c[a];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(e,i(t.key),t)}}(e.prototype,c),Object.defineProperty(e,"prototype",{writable:!1}),e}function t(e,a,t){return a=n(a),function(e,a){if(a&&("object"==c(a)||"function"==typeof a))return a;if(void 0!==a)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,l()?Reflect.construct(a,t||[],n(e).constructor):a.apply(e,t))}function l(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(l=function(){return!!e})()}function n(e){return n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}function r(e,c){return r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,c){return e.__proto__=c,e},r(e,c)}function i(e){var a=function(e,a){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var l=t.call(e,a);if("object"!=c(l))return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===a?String:Number)(e)}(e,"string");return"symbol"==c(a)?a:a+""}ct=1;var o=e,s=ya(),m=ht.createFocusTrap,h=dt.isFocusable,d=function(e){function c(e){var a;!function(e,c){if(!(e instanceof c))throw new TypeError("Cannot call a class as a function")}(this,c),function(e,c,a){(c=i(c))in e?Object.defineProperty(e,c,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[c]=a}(a=t(this,c,[e]),"getNodeForOption",function(e){var c,a=null!==(c=this.internalOptions[e])&&void 0!==c?c:this.originalOptions[e];if("function"==typeof a){for(var t=arguments.length,l=new Array(t>1?t-1:0),n=1;n<t;n++)l[n-1]=arguments[n];a=a.apply(void 0,l)}if(!0===a&&(a=void 0),!a){if(void 0===a||!1===a)return a;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var r,i=a;if("string"==typeof a&&!(i=null===(r=this.getDocument())||void 0===r?void 0:r.querySelector(a)))throw new Error("`".concat(e,"` as selector refers to no known node"));return i}),a.handleDeactivate=a.handleDeactivate.bind(a),a.handlePostDeactivate=a.handlePostDeactivate.bind(a),a.handleClickOutsideDeactivates=a.handleClickOutsideDeactivates.bind(a),a.internalOptions={returnFocusOnDeactivate:!1,checkCanReturnFocus:null,onDeactivate:a.handleDeactivate,onPostDeactivate:a.handlePostDeactivate,clickOutsideDeactivates:a.handleClickOutsideDeactivates},a.originalOptions={returnFocusOnDeactivate:!0,onDeactivate:null,onPostDeactivate:null,checkCanReturnFocus:null,clickOutsideDeactivates:!1};var l=e.focusTrapOptions;for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&("returnFocusOnDeactivate"!==n&&"onDeactivate"!==n&&"onPostDeactivate"!==n&&"checkCanReturnFocus"!==n&&"clickOutsideDeactivates"!==n?a.internalOptions[n]=l[n]:a.originalOptions[n]=l[n]);return a.outsideClick=null,a.focusTrapElements=e.containerElements||[],a.updatePreviousElement(),a}return function(e,c){if("function"!=typeof c&&null!==c)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(c&&c.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),c&&r(e,c)}(c,e),a(c,[{key:"getDocument",value:function(){return this.props.focusTrapOptions.document||("undefined"!=typeof document?document:void 0)}},{key:"getReturnFocusNode",value:function(){var e=this.getNodeForOption("setReturnFocus",this.previouslyFocusedElement);return e||!1!==e&&this.previouslyFocusedElement}},{key:"updatePreviousElement",value:function(){var e=this.getDocument();e&&(this.previouslyFocusedElement=e.activeElement)}},{key:"deactivateTrap",value:function(){this.focusTrap&&this.focusTrap.active&&this.focusTrap.deactivate({returnFocus:!1,checkCanReturnFocus:null,onDeactivate:this.originalOptions.onDeactivate})}},{key:"handleClickOutsideDeactivates",value:function(e){var c="function"==typeof this.originalOptions.clickOutsideDeactivates?this.originalOptions.clickOutsideDeactivates.call(null,e):this.originalOptions.clickOutsideDeactivates;return c&&(this.outsideClick={target:e.target,allowDeactivation:c}),c}},{key:"handleDeactivate",value:function(){this.originalOptions.onDeactivate&&this.originalOptions.onDeactivate.call(null),this.deactivateTrap()}},{key:"handlePostDeactivate",value:function(){var e=this,c=function(){var c=e.getReturnFocusNode(),a=!(!e.originalOptions.returnFocusOnDeactivate||null==c||!c.focus||e.outsideClick&&(!e.outsideClick.allowDeactivation||h(e.outsideClick.target,e.internalOptions.tabbableOptions))),t=e.internalOptions.preventScroll,l=void 0!==t&&t;a&&c.focus({preventScroll:l}),e.originalOptions.onPostDeactivate&&e.originalOptions.onPostDeactivate.call(null),e.outsideClick=null};this.originalOptions.checkCanReturnFocus?this.originalOptions.checkCanReturnFocus.call(null,this.getReturnFocusNode()).then(c,c):c()}},{key:"setupFocusTrap",value:function(){this.focusTrap?this.props.active&&!this.focusTrap.active&&(this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()):this.focusTrapElements.some(Boolean)&&(this.focusTrap=this.props._createFocusTrap(this.focusTrapElements,this.internalOptions),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause())}},{key:"componentDidMount",value:function(){this.props.active&&this.setupFocusTrap()}},{key:"componentDidUpdate",value:function(e){if(this.focusTrap){e.containerElements!==this.props.containerElements&&this.focusTrap.updateContainerElements(this.props.containerElements);var c=!e.active&&this.props.active,a=e.active&&!this.props.active,t=!e.paused&&this.props.paused,l=e.paused&&!this.props.paused;if(c&&(this.updatePreviousElement(),this.focusTrap.activate()),a)return void this.deactivateTrap();t&&this.focusTrap.pause(),l&&this.focusTrap.unpause()}else e.containerElements!==this.props.containerElements&&(this.focusTrapElements=this.props.containerElements),this.props.active&&(this.updatePreviousElement(),this.setupFocusTrap())}},{key:"componentWillUnmount",value:function(){this.deactivateTrap()}},{key:"render",value:function(){var e=this,c=this.props.children?o.Children.only(this.props.children):void 0;if(c){if(c.type&&c.type===o.Fragment)throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");return o.cloneElement(c,{ref:function(a){var t=e.props.containerElements;c&&("function"==typeof c.ref?c.ref(a):c.ref&&(c.ref.current=a)),e.focusTrapElements=t||[a]}})}return null}}])}(o.Component),u="undefined"==typeof Element?Function:Element;return d.propTypes={active:s.bool,paused:s.bool,focusTrapOptions:s.shape({document:s.object,onActivate:s.func,onPostActivate:s.func,checkCanFocusTrap:s.func,onPause:s.func,onPostPause:s.func,onUnpause:s.func,onPostUnpause:s.func,onDeactivate:s.func,onPostDeactivate:s.func,checkCanReturnFocus:s.func,initialFocus:s.oneOfType([s.instanceOf(u),s.string,s.bool,s.func]),fallbackFocus:s.oneOfType([s.instanceOf(u),s.string,s.func]),escapeDeactivates:s.oneOfType([s.bool,s.func]),clickOutsideDeactivates:s.oneOfType([s.bool,s.func]),returnFocusOnDeactivate:s.bool,setReturnFocus:s.oneOfType([s.instanceOf(u),s.string,s.bool,s.func]),allowOutsideClick:s.oneOfType([s.bool,s.func]),preventScroll:s.bool,tabbableOptions:s.shape({displayCheck:s.oneOf(["full","legacy-full","non-zero-area","none"]),getShadowRoot:s.oneOfType([s.bool,s.func])}),trapStack:s.array,isKeyForward:s.func,isKeyBackward:s.func}),containerElements:s.arrayOf(s.instanceOf(u)),children:s.oneOfType([s.element,s.instanceOf(u)])},d.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:m},et=d}(),vt=Gc(ut);h();var pt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.onClick,n=c.label,r=c.level,i=c.autoFocus,o=void 0!==i&&i;return e.createElement("button",{className:p("nav-link",t&&"theme-".concat(t),"nav-link--".concat(r)),onClick:l,autoFocus:o},e.createElement("span",{className:"nav-link__label"},n,e.createElement("span",{className:"nav-link__icon"},e.createElement(_,{icon:"chevron-right",theme:t,ariaHidden:!0}))))};h();var ft=function(c){var a=c.theme,n=void 0===a?"uobmain":a,r=c.url,i=c.label,o=c.level,s=c.autoFocus,m=void 0!==s&&s,h=c.externalLink,d=void 0!==h&&h,u=l(null);return t(function(){m&&u.current&&u.current.focus()},[m]),e.createElement("a",{className:p("page-link",n&&"theme-".concat(n),"page-link--".concat(o)),href:r,ref:u,target:d?"_blank":"_self",rel:d?"noopener noreferrer":""},i)};function gt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.image,i=c.tag,o=c.title,s=c.href,m=c.linkText,h=c.description,u=c.type;return e.createElement("div",{className:p("card-menu",u&&"card-menu--".concat(u),t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("figure",{className:"card-menu__figure"},e.createElement("div",{className:"card-menu__image-wrapper"},e.createElement(L,d({},r,{altText:"",loadingAttr:"lazy"}))),e.createElement("figcaption",{className:"card-menu__text-content"},"secondary"===u&&e.createElement(e.Fragment,null,e.createElement("p",{className:"card-menu__tag card-menu__tag"},i),e.createElement("a",{className:"card-menu__link",href:s},e.createElement("h2",{className:"card-menu__title"},o))),"primary"===u?e.createElement(e.Fragment,null,e.createElement("h2",{className:"card-menu__title"},o),e.createElement("p",{className:"card-menu__description"},h),e.createElement("div",{className:"card-menu__cta"},e.createElement(y,{theme:t,url:s,title:m||o}))):e.createElement("div",{className:"card-menu__arrow"},e.createElement(_,{icon:"arrow-right",theme:t,ariaHidden:!0})))))}h();var Et=function(c){var a=c.primaryLinks,t=c.secondaryLinks,l=c.onClickNavLink,n=c.menuCards,r=c.theme;return e.createElement("div",{className:"header__main-menu"},e.createElement("div",{className:"header__main-menu-menu-wrapper"},e.createElement("ul",{className:"header__main-menu-primary-list"},a.map(function(c,a){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(a)},key:c.label,theme:r,level:"level-one",autoFocus:0===a}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:r,level:"level-one",autoFocus:0===a,externalLink:c.externalLink})})),e.createElement("ul",{className:"header__main-menu-secondary-list"},t.map(function(c,t){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(t+a.length)},key:c.label,theme:r,level:"level-two"}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:r,level:"level-two",externalLink:c.externalLink})}))),e.createElement("ul",{className:"header__main-menu-promo-cards"},n&&n.map(function(c,a){return e.createElement("li",{key:a},e.createElement(gt,{theme:r,image:{src:{small:c.image.src.small,medium:c.image.src.medium,default:c.image.src.default}},description:c.description,tag:c.tag,title:c.title,linkText:c.linkText,href:c.href,type:c.type}))})))};h();var _t=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.label,i=c.onClick;return e.createElement("button",{className:p("reverse-link-with-arrow",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse")),onClick:i},e.createElement("span",{className:"reverse-link-with-arrow__title"},e.createElement("span",{className:"reverse-link-with-arrow__icon"},e.createElement(_,{icon:"arrow-left",theme:t,inverse:n,ariaHidden:!0})),r))},bt=function(c){var a=c.headingLink,t=c.onClickGoBack,l=c.onClickNavLink,n=c.theme,r=c.backLinkLabel;return e.createElement("div",{className:"header__nested-menu"},e.createElement(_t,{label:r,onClick:t,theme:n}),e.createElement("div",{className:"header__heading-link"},e.createElement(ft,{theme:n,url:a.url,label:a.label,level:"level-one",autoFocus:!0})),e.createElement("div",{className:"header__content-wrapper"},a.description&&e.createElement("p",{className:"header__description"},a.description),a.children&&e.createElement("ul",{className:p("header__link-list",a.description&&"header__link-list--with-desc")},a.children.map(function(c,a){return c.children?e.createElement(pt,{label:c.label,onClick:function(){return l(a)},key:c.label,theme:n,level:"level-two"}):e.createElement(ft,{label:c.label,url:c.url,key:c.label,theme:n,level:"level-two",externalLink:c.externalLink})}))))};h();var wt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.fieldName,i=c.hiddenLabel,o=void 0!==i&&i,s=c.defaultValue,m=c.placeholder,h=c.required,d=void 0!==h&&h,u=c.onChange;return e.createElement("div",{className:p("form-input",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("label",{htmlFor:r,className:p("form-input__label",o&&"sr-only")},"Select ",r),e.createElement("input",{className:"form-input__input",id:r,name:r,type:"text",required:d,defaultValue:s,placeholder:m,onChange:u}))},qt=function(c){var a=c.title,t=void 0===a?"Search":a,l=c.placeholder,n=void 0===l?"Start typing":l,r=c.introText,i=c.handleSearchChange,o=c.handleSearchSubmit,s=c.theme,m=c.inverse,h=c.onClickGoBack,d=c.backLinkLabel,u=c.recommendedLinks,v=c.recommendedLinkTitle;return e.createElement("div",{className:"header-search"},h&&d&&e.createElement("div",{className:"header-search__back-link"},e.createElement(_t,{label:d,onClick:h,theme:s})),e.createElement("div",{className:"header-search__container"},e.createElement("h2",{className:"header-search__title"},t),e.createElement("p",{className:"header-search__intro"},r),e.createElement("form",{className:"header-search__form",method:"post",onSubmit:o},e.createElement("div",{className:"header-search__search-wrapper"},e.createElement(wt,{theme:s,inverse:!1,fieldName:"search",hiddenLabel:!0,placeholder:n,onChange:i}),e.createElement(Oe,{theme:s,inverse:!m,title:"Search",icon:"search",isSubmit:!0})),e.createElement(q,{theme:s,inverse:!m,label:"Search",isSubmit:!0}))),u&&e.createElement("div",{className:"header-search__recommended-links-wrapper"},v&&e.createElement("h3",{className:"header-search__recommended-link-title"},v),e.createElement("ul",{className:"header-search__recommended-links"},u.map(function(c,a){return e.createElement("li",{className:"header-search__recommended-link",key:a},e.createElement(Sc,{theme:s,url:c.url,title:c.label,externalLink:c.externalLink}))}))))};function yt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.label,n=c.url,r=c.externalLink,i=c.active,o=void 0!==i&&i;return e.createElement("a",{className:p("campus-selector-link",t&&"theme-".concat(t),o&&"campus-selector-link--active"),href:n,target:r?"_blank":"_self",rel:"noreferrer"},l)}function Mt(c){var a=c.active,t=c.theme,l=c.ukUrl,n=c.dubaiUrl,r=c.mobile;return e.createElement("div",{className:p("campus-selector",t&&"theme-".concat(t),r&&"campus-selector--mobile",!r&&"campus-selector--desktop")},e.createElement("div",{className:"campus-selector__container"},e.createElement("span",{className:"campus-selector__label"},"Select campus:"),r?e.createElement(e.Fragment,null,e.createElement(q,{label:"UK",theme:t,inverse:!0,url:l,hollow:"uk"!==a}),e.createElement(q,{label:"Dubai",theme:t,inverse:!0,url:n,hollow:"dubai"!==a})):e.createElement(e.Fragment,null,e.createElement(yt,{label:"UK",theme:t,url:l,active:"uk"===a}),e.createElement(yt,{label:"Dubai",theme:t,url:n,active:"dubai"===a}))))}h(),h(),h();var Nt=function(c){var n=c.theme,r=void 0===n?"uobmain":n,o=c.primaryLinks,s=c.secondaryLinks,h=c.menuCards,d=c.dubaiUrl,v=c.ukUrl,f=c.logoTitleTagH1,g=void 0===f||f,E=c.activeCampus,_=void 0===E?"uk":E,b=c.searchProps,w=function(){var e=a(null),c=e[0],l=e[1];return t(function(){var e=window.scrollY,a=function(){var a=window.scrollY,t=a>e?"down":"up";t!==c&&(a-e>3||a-e<-3)&&l(t),e=a>0?a:0};return window.addEventListener("scroll",a),function(){window.removeEventListener("scroll",a)}},[c]),c}(),y=a(!1),M=y[0],N=y[1],C=l(null),k=l(null),x=l(null),T=xe("768px"),L=a(0),z=L[0],H=L[1],V=a(null),S=V[0],P=V[1],O=a(null),Z=O[0],B=O[1],F=a(!1),D=F[0],I=F[1],A=a(!1),$=A[0],R=A[1],j=a(""),U=j[0],W=j[1],G=function(){N(!0),document.body.classList.add("lock-scroll")},K=function(){I(!0),G()},Y=function(){I(!1),R(!1)},J=function(){N(!1),Y(),document.body.classList.remove("lock-scroll"),H(0),P(null),B(null),C.current&&C.current.focus()},X=function(){H(0),P(null),Y()},Q=function(){H(1),B(null),Y()},ee=function(e){"Escape"===e.key&&M&&J()};t(function(){return document.addEventListener("keydown",ee),function(){document.removeEventListener("keydown",ee)}}),t(function(){if(k.current&&"down"===w){var e=k.current.offsetHeight;k.current.style.top="-".concat(e,"px")}else if(k.current&&"up"===w){var c=0;x.current&&k.current&&(c=x.current.offsetHeight),k.current.style.top="-".concat(c,"px")}},[w]);var ce=null,ae=null;null!==S&&(ce=u(u([],o,!0),s,!0)[S],null!==Z&&ce.children&&(ae=ce.children[Z]));var te=e.createElement("div",{className:"header__campus-selector header__campus-selector--mobile"},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!0})),le=e.createElement("div",{className:"header__campus-selector header__campus-selector--desktop",ref:x},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!1})),ne=e.createElement("div",{className:"header__campus-selector header__campus-selector--desktop"},e.createElement(Mt,{theme:r,dubaiUrl:d,ukUrl:v,active:_,mobile:!1})),re=function(e){W(e.target.value)},ie=function(e){if(e.preventDefault(),"undefined"!=typeof window){var c=b.resultsUrl;window.location.href=U?"".concat(c,"?term=").concat(U):"".concat(c)}};return e.createElement("header",{className:p("header",r&&"theme-".concat(r),!M&&"header--is-closed","header--".concat(_)),id:"header",ref:k},e.createElement("div",{className:"header__closed"},le,e.createElement("div",{className:"header__top-container"},e.createElement("div",{className:"header__logo-wrapper"},e.createElement("div",{className:"header__logo-wrapper"},g?e.createElement("h1",{className:"header__logo-heading"},e.createElement(Zc,{activeCampus:_,imageMode:"light",classNames:"header__logo-link",imageAltText:"uk"===_?"University of Birmingham":"University of Birmingham Dubai"})):e.createElement(Zc,{activeCampus:_,imageMode:"light",classNames:"header__logo-link"},e.createElement("span",{className:"sr-only"},"uk"===_?"University of Birmingham":"University of Birmingham Dubai")))),e.createElement("div",{className:"header__right-wrapper"},e.createElement("div",{className:"header__search-button"},e.createElement(q,{theme:r,label:"Search",onClick:function(){R(!0),K()},hollow:!0})),e.createElement("div",{className:"header__menu-button"},e.createElement("span",null,"Menu"),e.createElement(Oe,{theme:"uobmain",icon:"hamburger",onClick:G,title:"Open menu",ariaControls:"header",ref:C,ariaExpanded:M}))))),e.createElement(m,null,M&&e.createElement(vt,null,e.createElement(i.div,{className:"header__open",initial:{x:"100%"},animate:{x:"0"},exit:{x:"100%"},transition:{type:"tween"},key:"header__open"},ne,e.createElement("div",{className:"header__top-container"},e.createElement("div",{className:"header__logo-wrapper"},e.createElement(Zc,{activeCampus:_,imageMode:"dark",classNames:"header__logo-link"},e.createElement("h1",{className:"sr-only"},"uk"===_?"University of Birmingham":"University of Birmingham Dubai"))),e.createElement("div",{className:"header__right-wrapper"},!T&&!D&&e.createElement("div",{className:"header__search-button-menu"},e.createElement(q,{theme:r,inverse:!0,label:"Search",onClick:K,hollow:!0})),e.createElement("div",{className:"header__menu-button"},e.createElement("span",null,"Menu"),e.createElement(Oe,{theme:"uobmain",inverse:!0,icon:"cross",onClick:J,title:"Close menu",ariaControls:"header"})))),T&&!D&&e.createElement("div",{className:"header__search-button-mobile"},e.createElement(q,{theme:r,inverse:!0,label:"Search",onClick:K,hollow:!0})),0===z&&!D&&e.createElement(Et,{primaryLinks:o,secondaryLinks:s,menuCards:h,onClickNavLink:function(e){H(1),P(e)},theme:r}),0===z&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:$?void 0:X,backLinkLabel:$?"":"Back to menu",recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),1===z&&ce&&!D&&e.createElement(bt,{headingLink:ce,onClickNavLink:function(e){H(2),B(e)},theme:r,onClickGoBack:X,backLinkLabel:"Back to menu"}),1===z&&ce&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:Q,backLinkLabel:"Back to ".concat(ce.label),recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),2===z&&ce&&ae&&!D&&e.createElement(bt,{headingLink:ae,onClickNavLink:function(){},theme:r,onClickGoBack:Q,backLinkLabel:"Back to ".concat(ce.label)}),2===z&&ce&&ae&&D&&e.createElement(qt,{theme:r,introText:b.introText,placeholder:b.placeholder,title:b.title,handleSearchChange:re,handleSearchSubmit:ie,onClickGoBack:function(){H(2),Y()},backLinkLabel:"Back to ".concat(ae.label),recommendedLinks:b.recommendedLinks,recommendedLinkTitle:b.recommendedLinkTitle}),te))))},Ct={mobile:{image:"polygon(0 0, calc(100% - 1px) 0, calc(75% - 1px) calc(70% - 1px), 0 calc(90% - 1px))",background:"polygon(0 0, 100% 0, 75% 70%, 0 90%)"},tablet:{image:"polygon(0 0, 100% 0, 100% calc(70% - 1px), calc(30% + 1px) calc(60% - 1px))",background:"polygon(0 0, 100% 0, 100% 70%, 30% 60%)"},desktop:{image:"polygon(1px 0, 100% 0, 100% calc(95% - 1px), calc(10% + 1px) calc(65% - 1px))",background:"polygon(0 0, 100% 0, 100% 95%, 10% 65%)"}};function kt(c){var a,n,o=c.isMobile,s=c.isTablet,m=c.image,h=o?Ct.mobile:s?Ct.tablet:Ct.desktop,d=l(null),u=r();return t(function(){var e;d.current&&d.current.setAttribute("fetchpriority",null!==(e=m.fetchPriority)&&void 0!==e?e:"auto")}),e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__polygon-image-wrapper"},e.createElement(i.img,{ref:d,className:"hero__image",src:m.src.default,srcSet:"".concat(null!==(a=m.src.small)&&void 0!==a?a:m.src.default," 576w, ").concat(null!==(n=m.src.medium)&&void 0!==n?n:m.src.default," 992w, ").concat(m.src.default," 1440w"),alt:m.alt,fetchPriority:m.fetchPriority,animate:{clipPath:h.image},transition:{type:"tween"}}),e.createElement(i.div,{key:u,className:"hero__polygon-image-background",animate:{opacity:1,clipPath:h.background},transition:{type:"tween"},initial:{opacity:0}})))}h();var xt={initial:{pathLength:0},animate:{pathLength:1},transition:{delay:.5,duration:1}};function Tt(c){var a=c.isMobile,t=c.isTablet;return a?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"75%",bottom:"30%",transform:"rotate(10deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"75%",bottom:"30%",transform:"rotate(-15deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt))))):t?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"calc(30% + 1px)",top:"calc(60% - 3px)",transform:"rotate(161deg)"},initial:!1},e.createElement("svg",{width:"120",height:"2",viewBox:"0 0 120 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"30%",top:"calc(60% - 1px)",transform:"rotate(26deg)"},initial:!1},e.createElement("svg",{width:"120",height:"2",viewBox:"0 0 120 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt))))):e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero__line",animate:{left:"10%",top:"calc(65% - 3px)",transform:"rotate(118deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))),e.createElement(i.div,{className:"hero__line",animate:{left:"10%",top:"calc(65% - 3px)",transform:"rotate(41deg)"},initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140"},xt)))))}h();var Lt=function(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.fieldName,i=c.selectOptions,o=c.defaultValue,s=void 0===o?"all":o,m=c.hiddenLabel,h=void 0!==m&&m,d=c.customLabel,u=c.title,v=c.onChange,f=c.value;return e.createElement("div",{className:p("form-select",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},d?e.createElement("label",{htmlFor:r,className:p("form-select__label",h&&"sr-only")},d):e.createElement("label",{htmlFor:r,className:p("form-select__label",h&&"sr-only")},"Select ",r),e.createElement("div",{className:"form-select__select-wrapper"},e.createElement("select",{className:"form-select__select",defaultValue:s,value:f,id:r,name:r,onChange:v},e.createElement("option",{value:"all"},u),i&&i.map(function(c,a){return e.createElement("option",{value:c.value,key:a},c.label)})),e.createElement("div",{className:"form-select__icon"},e.createElement(_,{icon:"arrow-down",theme:t,inverse:n}))))};function zt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.title,i=c.description,o=c.defaultSearchTerm,s=c.placeholder,m=c.filterTitle,h=c.filterFieldName,d=c.filterOptions,u=c.defaultFilter,v=void 0===u?"all":u,f=c.wrapped,g=void 0!==f&&f,E=c.fullWidth,_=void 0!==E&&E,b=c.onGrid,w=void 0!==b&&b,y=c.titleTag,M=void 0===y?"h2":y,N=c.formSubmitHandler,k=c.filterChangeHandler,x=c.searchTermChangeHandler,T=M;return e.createElement("div",{className:p("search-course",_&&"search-course--full-width",w&&"search-course--on-grid",g&&"search-course--wrapped",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),!h&&"search-course--no-filter")},e.createElement("div",{className:"search-course__container"},r&&e.createElement(T,{className:"search-course__title"},r),i&&e.createElement("div",{className:"search-course__description"},e.createElement(C,{text:i,theme:t,inverse:n})),e.createElement("form",{className:"search-course__form",method:"post",onSubmit:N},e.createElement("div",{className:"search-course__search-wrapper"},e.createElement(wt,{theme:t,inverse:n,fieldName:"search",hiddenLabel:!0,defaultValue:o,placeholder:s,onChange:x}),e.createElement(Oe,{theme:t,inverse:!n,title:"Search",icon:"search",isSubmit:!0}),g&&e.createElement(q,{theme:t,inverse:!n,label:"Search",isSubmit:!0})),h&&m&&d&&e.createElement(Lt,{theme:t,inverse:n,title:m,fieldName:h,selectOptions:d,defaultValue:v,hiddenLabel:!0,onChange:k}),!g&&e.createElement(q,{theme:t,inverse:!n,label:"Search",isSubmit:!0}))))}function Ht(c){var a=c.theme,t=c.inverse,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.description,o=c.image,s=c.links,m=c.courseSearchProps,h=xe("768px"),u=xe("1248px");return e.createElement("div",{className:p("hero",a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"),o&&"hero--with-image"),id:"hero"},o&&"rectangle"===o.style&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--mobile hero__image-wrapper--rectangle"},e.createElement(L,d({},o,{altText:o.alt,fetchPriority:o.fetchPriority}))),o&&"lines-of-intent"===o.style&&h&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--mobile"},e.createElement(kt,{isMobile:!0,isTablet:!1,image:o}),e.createElement(Tt,{isMobile:!0,isTablet:!1})),e.createElement("div",{className:"hero__container"},e.createElement("div",{className:"hero__content"},e.createElement(r,{className:"hero__title"},l),i&&e.createElement("div",{className:"hero__description"},e.createElement(C,{text:i,theme:a,inverse:t})),s&&s.length>0&&e.createElement("div",{className:"hero__buttons"},s.map(function(c,l){return e.createElement(q,{theme:a,key:l,url:c.url,label:c.title,externalLink:c.externalLink,inverse:!t,hollow:1===l})})),m&&e.createElement(zt,d({theme:a,inverse:t,wrapped:!0},m))),o&&"rectangle"===o.style&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--rectangle"},e.createElement(L,d({},o,{altText:o.alt,fetchPriority:o.fetchPriority}))),o&&"lines-of-intent"===o.style&&u&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--polygon"},e.createElement(kt,{isMobile:!1,isTablet:!0,image:o}),e.createElement(Tt,{isMobile:!1,isTablet:!0})),o&&"lines-of-intent"===o.style&&!h&&!u&&e.createElement("div",{className:"hero__image-wrapper hero__image-wrapper--desktop hero__image-wrapper--polygon"},e.createElement(kt,{isMobile:!1,isTablet:!1,image:o}),e.createElement(Tt,{isMobile:!1,isTablet:!1}))))}function Vt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.label,r=c.icons;return e.createElement("div",{className:p("share-buttons",t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"))},n&&e.createElement("div",{className:"share-buttons__label"},n),r&&e.createElement("ul",{className:"share-buttons__icon-wrapper"},r.map(function(c,a){return e.createElement("li",{className:"share-buttons__icon",key:a},e.createElement(Oe,{theme:t,title:c.title,icon:c.icon,url:c.url,inverse:l}))})))}function St(c){var a="items"in c?c.items:[c],t=(null!=a?a:[]).filter(function(e){return Boolean(e)});return e.createElement(e.Fragment,null,t.map(function(c,a){var l=c.theme,n=void 0===l?"uobmain":l,r=c.inverse,i=void 0!==r&&r,o=c.label,s=c.url,m=c.externalLink;return e.createElement(e.Fragment,{key:"".concat(s,"-").concat(o,"-").concat(a)},e.createElement("a",{className:p("paragraph-link",n&&"theme-".concat(n),i&&"theme-".concat(n,"--inverse")),href:s,target:m?"_blank":"_self",rel:"noreferrer"},o),a<t.length-1?" ":null)}))}function Pt(c){var a=c.theme,t=c.inverse,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.description,o=c.cardImage,s=c.publishDate,m=c.readTime,h=c.shareButtons,u=c.author,v=Array.isArray(u)?u:[u];return e.createElement("section",{className:p("hero-article",a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"))},e.createElement("div",{className:"hero-article__container"},e.createElement("div",{className:"hero-article__content"},e.createElement(r,{className:"hero-article__title"},l),e.createElement("p",{className:"hero-article__description"},i),e.createElement("div",{className:"hero-article__meta-data"},s&&e.createElement("span",{className:"hero-article__publish-date"},s),s&&m&&e.createElement("span",{className:"hero-article__separator"},"•"),m&&e.createElement("span",{className:"hero-article__read-time"},m),u&&e.createElement(e.Fragment,null,e.createElement("span",{className:"hero-article__separator"},"•"),e.createElement("span",{className:"hero-article__author"},"by ",e.createElement(St,{items:v})))),e.createElement("div",{className:"hero-article__sharing-buttons"},e.createElement(Vt,{theme:a,label:h.label,icons:h.icons,inverse:t})))),o&&e.createElement("div",{className:"hero-article__image-wrapper"},e.createElement(Ge,d({},o,{inverse:t}))))}function Ot(c){var t=c.theme,l=c.inverse,n=c.buttonLabel,r=c.hollow,i=c.modalChildren,o=a(!1),s=o[0],m=o[1],h=function(){m(!1),document.body.classList.remove("lock-scroll")};return e.createElement("div",{className:p("modal-cta-button",t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"))},e.createElement(q,{inverse:l,label:n,onClick:function(){s?h():(m(!0),document.body.classList.add("lock-scroll"))},theme:t,hollow:r}),s&&e.createElement(Be,{centred:!0,theme:t,closeModal:h,isOpen:s},e.createElement(sc,{className:"modal-cta-button__embed-wrapper"},i)))}function Zt(c){var a=c.title,t=c.value,l=c.link;return e.createElement("article",{className:"course-tile"},e.createElement("div",{className:"course-tile__top"},e.createElement("div",{className:"course-tile__title"},a),e.createElement("div",{className:"course-tile__value"},t)),l&&e.createElement("div",{className:"course-tile__link-wrapper"},e.createElement(Fc,d({},l,{inverse:!0,onClick:function(e){return Dc(e,l.url||"#")}}))))}function Bt(c){var a=c.title,t=c.selectProps;return e.createElement("article",{className:"course-tile-select"},e.createElement("div",{className:"course-tile-select__top"},e.createElement("div",{className:"course-tile-select__title"},a),e.createElement(Lt,d({},t,{inverse:!0}))))}function Ft(c){var a=c.title,t=c.rank,l=c.rankText,n=c.link;return e.createElement("article",{className:"course-tile-ranking"},e.createElement("div",{className:"course-tile-ranking__top"},e.createElement("div",{className:"course-tile-ranking__title"},a),e.createElement("div",{className:"course-tile-ranking__rank"},t),e.createElement("div",{className:"course-tile-ranking__rank-text"},l)),n&&e.createElement("div",{className:"course-tile-ranking__link-wrapper"},e.createElement(Fc,d({},n,{inverse:!0,onClick:function(e){return Dc(e,n.url||"#")}}))))}function Dt(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.topPadding,i=void 0!==r&&r,o=c.selectorProps;return e.createElement("div",{className:p("location-selector",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:p("location-selector__container",i&&"location-selector__container--padding-top")},e.createElement(Lt,d({},o,{inverse:n}))))}function It(c){var a,t=c.theme,l=c.title,n=c.titleTag,r=void 0===n?"h2":n,i=c.awardShort,o=c.links,s=c.ranking,m=c.award,h=c.campus,u=c.ucas,v=c.duration,f=c.entryRequirements,g=c.startDate,E=c.yearOfEntry,_=c.fees,b=c.deliveryFormat,w=c.locationDetails,y=c.modalCTA;return e.createElement("section",{className:p("hero-courses",t&&"theme-".concat(t)),id:"hero-courses"},e.createElement("div",{className:"hero-courses__container"},e.createElement("div",{className:"hero-courses__content"},e.createElement("div",{className:"hero-courses__title-wrapper"},e.createElement(N,{htmlTag:r,classNames:"hero-courses__title"},l&&l.length>0&&i&&i.length>0?l+" ":l,e.createElement("span",{className:"hero-courses__title-award"},i))),w&&e.createElement("div",{className:"hero-courses__location-wrapper"},e.createElement(Dt,d({},w,{inverse:!1}))),e.createElement("ul",{className:(a="hero-courses__grid--four",s&&(h||b||u)?a="hero-courses__grid--six":(s&&!h&&!b&&!u||!s&&(h||b||u))&&(a="hero-courses__grid--five"),"hero-courses__grid "+a)},s&&e.createElement("li",{className:"hero-courses__column hero-courses__column--ranking"},e.createElement(Ft,d({},s))),(u||h||b)&&e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--award"},u&&e.createElement(Zt,d({},u)),h&&e.createElement(Zt,d({},h)),b&&e.createElement(Zt,d({},b))),v&&E?e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--duration"},e.createElement(Bt,d({},E)),e.createElement(Zt,d({},v))):v&&g?e.createElement("li",{className:"hero-courses__column hero-courses__column--split hero-courses__column--duration"},e.createElement(Zt,d({},g)),e.createElement(Zt,d({},v))):e.createElement("li",{className:"hero-courses__column hero-courses__column--duration"},e.createElement(Zt,d({},v))),m&&e.createElement("li",{className:"hero-courses__column hero-courses__column--delivery-format"},e.createElement(Zt,d({},m))),e.createElement("li",{className:"hero-courses__column hero-courses__column--entry-requirements"},e.createElement(Zt,d({},f))),e.createElement("li",{className:"hero-courses__column hero-courses__column--fees"},e.createElement(Zt,d({},_)))),e.createElement("div",{className:"hero-courses__button-wrapper"},e.createElement("ul",{className:"hero-courses__buttons"},o&&o.map(function(c,a){return c.externalLink?e.createElement("li",{className:"hero-courses__button",key:a},e.createElement(Fe,{theme:t,label:c.label,icon:"external",hollow:a%2!=0,iconPosition:"right",url:c.url,inverse:!0,onClick:c.onClick})):e.createElement("li",{className:"hero-courses__button",key:a},e.createElement(q,{theme:t,label:c.label,hollow:a%2!=0,url:c.url,inverse:!0,onClick:c.onClick}))})),y&&e.createElement(Ot,{theme:t,inverse:!y.inverse,hollow:!0,buttonLabel:y.buttonLabel,modalChildren:y.modalChildren})))))}h(),h(),h(),h(),h(),h(),h();var At={first:{clipPath:"polygon(0 0, 95% 0, 75% 100%, 0 80%)"},second:{clipPath:"polygon(0 0, 100% 0, 75% 70%, 0 90%)"},third:{clipPath:"polygon(0 0, 80% 0, 95% 90%, 0 80%)"},visible:{opacity:1}},$t={first:{clipPath:"polygon(0 0, calc(95% - 1px) 0, calc(75% - 1px) calc(100% - 1px), 0 calc(80% - 1px))"},second:{clipPath:"polygon(0 0, calc(100% - 1px) 0, calc(75% - 1px) calc(70% - 1px), 0 calc(90% - 1px))"},third:{clipPath:"polygon(0 0, calc(80% - 1px) 0, calc(95% - 1px) calc(90% - 1px), 0 calc(80% - 1px))"}},Rt={first:{clipPath:"polygon(0 25%, 100% 5%, 100% 100%, 23% 100%)"},second:{clipPath:"polygon(33% 20%, 100% 5%, 100% 100%, 0 100%)"},third:{clipPath:"polygon(0 3%, 100% 20%, 100% 100%, 23% 100%)"},visible:{opacity:1}},jt={first:{clipPath:"polygon(1px calc(25% + 1px), 100% calc(5% + 1px), 100% 100%, calc(23% + 1px) 100%)"},second:{clipPath:"polygon(calc(33% + 1px) calc(20% + 1px), 100% calc(5% + 1px), 100% 100%, 1px 100%)"},third:{clipPath:"polygon(1px calc(3% + 1px), 100% calc(20% + 1px), 100% 100%, calc(23% + 1px) 100%"}},Ut={first:{clipPath:"polygon(0 33%, 100% 10%, 100% 100%, 23% 100%)"},second:{clipPath:"polygon(33% 30%, 100% 10%, 100% 100%, 0 100%)"},third:{clipPath:"polygon(0 10%, 100% 25%, 100% 100%, 15% 100%)"},visible:{opacity:1}},Wt={first:{clipPath:"polygon(1px calc(33% + 1px), 100% calc(10% + 1px), 100% 100%, calc(23% + 1px) 100%)"},second:{clipPath:"polygon(calc(33% + 1px) calc(30% + 1px), 100% calc(10% + 1px), 100% 100%, 1px 100%)"},third:{clipPath:"polygon(1px calc(10% + 1px), 100% calc(25% + 1px), 100% 100%, calc(15% + 1px) 100%"}},Gt={first:{left:"calc(75% + 1px)",bottom:0,transform:"rotate(-40deg)"},second:{left:"75%",bottom:"30%",transform:"rotate(-15deg)"},third:{left:"95%",bottom:"10%",transform:"rotate(-70deg)"}},Kt={first:{left:"calc(75% + 1px)",bottom:0,transform:"rotate(-15deg)"},second:{left:"75%",bottom:"30%",transform:"rotate(10deg)"},third:{left:"95%",bottom:"10%",transform:"rotate(-30deg)"}},Yt={first:{left:"2px",top:"calc(25% - 1px)",transform:"rotate(-130deg)"},second:{left:"calc(33% + 2px)",top:"calc(20% - 1px)",transform:"rotate(-155deg)"},third:{left:"0",top:"calc(3% - 3px)",transform:"rotate(-170deg)"}},Jt={first:{left:"2px",top:"calc(25% - 1px)",transform:"rotate(-50deg)"},second:{left:"calc(33% + 2px)",top:"calc(20% - 1px)",transform:"rotate(-110deg)"},third:{left:"1px",top:"calc(3% - 1px)",transform:"rotate(-10deg)"}},Xt={first:{left:"2px",top:"calc(33% - 1px)",transform:"rotate(-130deg)"},second:{left:"calc(33% + 1px)",top:"calc(30% - 2px)",transform:"rotate(-160deg)"},third:{left:"1px",top:"calc(10% - 2px)",transform:"rotate(-160deg)"}},Qt={first:{left:"2px",top:"calc(33% - 1px)",transform:"rotate(-45deg)"},second:{left:"calc(33% + 1px)",top:"calc(30% - 2px)",transform:"rotate(-75deg)"},third:{left:"0",top:"calc(10%)",transform:"rotate(-15deg)"}},el={initial:{pathLength:0},animate:{pathLength:1},transition:{delay:.5,duration:1}};function cl(c){var a=c.isMobile,t=c.isTablet,l=c.activeVariant;return a?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Gt,animate:l,initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Kt,animate:l,initial:!1},e.createElement("svg",{width:"140",height:"2",viewBox:"0 0 140 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H140",stroke:"black"},el))))):t?e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Yt,animate:l,initial:!1},e.createElement("svg",{width:"260",height:"2",viewBox:"0 0 260 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H260",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Jt,animate:l,initial:!1},e.createElement("svg",{width:"260",height:"2",viewBox:"0 0 260 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H260",stroke:"black"},el))))):e.createElement(e.Fragment,null,e.createElement(i.div,{className:"hero-carousel__line",variants:Xt,animate:l,initial:!1},e.createElement("svg",{width:"360",height:"2",viewBox:"0 0 360 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H360",stroke:"black"},el)))),e.createElement(i.div,{className:"hero-carousel__line",variants:Qt,animate:l,initial:!1},e.createElement("svg",{width:"360",height:"2",viewBox:"0 0 360 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement(i.path,d({d:"M0 1H360",stroke:"black"},el)))))}function al(c){var a,n,o=c.isMobile,s=c.isTablet,h=c.activeVariant,d=c.imageSrc,u=c.imageAlt,v=c.imageFetchPriority,p=l(null),f=r();return t(function(){p.current&&p.current.setAttribute("fetchpriority",null!=v?v:"high")}),e.createElement(e.Fragment,null,e.createElement(m,null,e.createElement(i.div,{className:"hero-carousel__image-wrapper",transition:{delayChildren:1}},e.createElement(i.img,{ref:p,className:"hero-carousel__image",src:d.default,srcSet:"".concat(null!==(a=d.small)&&void 0!==a?a:d.default," 576w, ").concat(null!==(n=d.medium)&&void 0!==n?n:d.default," 992w, ").concat(d.default," 1440w"),alt:u,variants:o?$t:s?jt:Wt,animate:h,initial:{clipPath:"polygon(0 0, 0 0, 0 0, 0 0)"},transition:{type:"tween"}}),e.createElement(i.div,{key:f,className:"hero-carousel__image-background",variants:o?At:s?Rt:Ut,animate:["visible",h],exit:{backgroundColor:"rgba(255, 255, 255, 0)"},transition:{type:"tween"},initial:{opacity:0,clipPath:"polygon(1% 1%, 1% 1%, 1% 1%, 1% 1%)"}}))))}var tl=c(function(c,a){var t=c.theme,l=c.category,n=c.title,r=c.description,i=c.linkUrl,o=c.linkLabel,s=c.onKeyDown;return e.createElement(e.Fragment,null,e.createElement("p",{className:"hero-carousel__category"},l),e.createElement("h2",{className:"hero-carousel__title"},n),e.createElement("p",{className:"hero-carousel__description"},r),e.createElement("div",{className:"hero-carousel__cta"},e.createElement(y,{url:i,title:o,theme:t,inverse:!0,onKeyDown:s,ref:a})))});function ll(c){var t=c.theme,n=c.cards,r=n.length>1,o=a(0),s=o[0],m=o[1],h=n[s],d=l(null),u=xe("768px"),v=xe("1248px"),f="";switch(s){case 0:f="first";break;case 1:f="second";break;case 2:f="third"}var g=r?e.createElement(cc,{theme:t,totalNumber:n.length,currentNumber:s+1,carouselId:"hero-carousel",onClickPrev:function(){m(function(e){return e-1})},onClickNext:function(){m(function(e){return e+1})},prevButtonDisabled:0===s,nextButtonDisabled:s===n.length-1,showNumbers:!0}):e.createElement(e.Fragment,null);return e.createElement("div",{className:p("hero-carousel",t&&"theme-".concat(t)),id:"hero-carousel"},e.createElement("div",{className:"hero-carousel__top"},e.createElement("div",{className:"hero-carousel__content"},u&&e.createElement("div",{className:"hero-carousel__image-container hero-carousel__image-container--mobile"},e.createElement(al,{isMobile:!0,isTablet:!1,activeVariant:f,imageSrc:h.imageSrc,imageAlt:h.imageAlt}),e.createElement(cl,{isMobile:!0,isTablet:!1,activeVariant:f})),e.createElement("div",{className:"hero-carousel__cards"},e.createElement(i.section,{className:"hero-carousel__active-card",key:s,initial:{opacity:0},animate:{opacity:1}},e.createElement(tl,{category:h.category,title:h.title,description:h.description,linkUrl:h.linkUrl,linkLabel:h.linkLabel,theme:t,ref:d})),u&&r&&n.map(function(c,a){return e.createElement("section",{className:"hero-carousel__invisible-card hero-carousel__invisible-card--mobile",key:a,"aria-hidden":!0},e.createElement(tl,{category:c.category,title:c.title,description:c.description,linkUrl:c.linkUrl,linkLabel:c.linkLabel,theme:t}))}),e.createElement("div",{className:"hero-carousel__nav hero-carousel__nav--desktop"},g)),e.createElement("div",{className:"hero-carousel__image-container hero-carousel__image-container--desktop"},e.createElement(al,{isMobile:!1,isTablet:v,activeVariant:f,imageSrc:h.imageSrc,imageAlt:h.imageAlt}),e.createElement(cl,{isMobile:!1,isTablet:v,activeVariant:f}))),!u&&r&&n.map(function(c,a){return e.createElement("div",{className:"hero-carousel__invisible-card hero-carousel__invisible-card--desktop",key:a,"aria-hidden":!0},e.createElement("section",null,e.createElement(tl,{category:c.category,title:c.title,description:c.description,linkUrl:c.linkUrl,linkLabel:c.linkLabel,theme:t})))})),u&&e.createElement("div",{className:"hero-carousel__nav hero-carousel__nav--mobile"},g))}function nl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.title,r=c.description,i=c.linkProps,o=c.fullWidth,s=c.makeHeadingFullWidth,m=c.images,h=c.htmlTag;if(!m||0===m.length)return null;var u=3===m.length&&!o;return e.createElement("div",{className:p("image-block","theme-".concat(t),l&&"theme-".concat(t,"--inverse"),o?"image-block--full-width":"image-block--standard-width","image-block--count-".concat(m.length))},(n||r||i)&&e.createElement(x,{theme:t,inverse:l,title:n,description:r,linkProps:i,fullWidth:!!s,htmlTag:h}),e.createElement("div",{className:"image-block__container"},u?e.createElement("div",{className:"image-block__inner-grid"},m.map(function(c,a){return e.createElement("div",{key:a,className:"image-block__item"},e.createElement(Ge,d({},c,{theme:t,inverse:l})))})):m.map(function(c,a){return e.createElement("div",{key:a,className:p("image-block__item","image-block__item--index-".concat(a+1))},e.createElement(Ge,d({},c,{theme:t,inverse:l})))})))}function rl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.title,i=c.description,o=c.linkProps,s=c.fullWidth,m=void 0!==s&&s,h=c.widerImage,d=c.images,u=c.htmlTag;return e.createElement("section",{className:p("image-carousel",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),m&&"image-carousel--full-width",h&&"image-carousel--wider-image")},(r||i)&&e.createElement(x,{theme:t,htmlTag:u,inverse:n,title:r,description:i,linkProps:o}),e.createElement("div",{className:"image-carousel__grid"},e.createElement(ac,{theme:t,inverse:n,type:"image",cards:d})))}function il(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=void 0===l?"Page contents":l,r=c.links,i=c.buttonLinks,o=c.locationDetails,s=function(e){var c=document.getElementById(e);if(c){var a=c.getBoundingClientRect().top+window.pageYOffset-20;window.scrollTo({top:a,behavior:"smooth"});var t=null,l=null,n=0,r=function(){t&&(t.disconnect(),t=null),l&&(l.disconnect(),l=null),n&&(clearTimeout(n),n=0)},i=function(e){return!!e&&(t=new IntersectionObserver(function(c){c.some(function(e){return e.isIntersecting})&&function(e){try{e.focus({preventScroll:!0})}catch(e){}finally{r()}}(e)},{root:null,threshold:.1,rootMargin:"0px 0px -20% 0px"}),t.observe(e),!0)},o=c.querySelector("h1,h2,h3,h4,h5,h6");i(o)||(l=new MutationObserver(function(){o=c.querySelector("h1,h2,h3,h4,h5,h6"),i(o)&&l&&(l.disconnect(),l=null)})).observe(c,{childList:!0,subtree:!0}),n=window.setTimeout(function(){r();var e=c.querySelector('a, button, input, select, textarea, [tabindex]:not([tabindex="-1"])');if(e){var a=!e.hasAttribute("tabindex");a&&e.setAttribute("tabindex","-1"),e.focus({preventScroll:!0}),a&&e.removeAttribute("tabindex")}},1e3)}},m=function(e,c){e.preventDefault(),s(c.replace("#",""))};return e.createElement("div",{className:p("in-page-navigation-links",t&&"theme-".concat(t))},e.createElement("h2",{className:"in-page-navigation-links__heading"},n),o&&e.createElement(Dt,d({},o,{inverse:!0})),e.createElement("nav",null,e.createElement("ul",{className:"in-page-navigation-links__link-container"},r.map(function(c){return e.createElement("li",{className:p("in-page-navigation-links__link-wrapper",c.active&&"in-page-navigation-links__link-wrapper--active"),key:c.url},e.createElement("a",{className:"in-page-navigation-links__link",href:c.url,onClick:function(e){return m(e,c.url)},onKeyDown:function(e){"Enter"!==e.key&&" "!==e.key||m(e,c.url)}},c.title))}))),e.createElement("ul",null,i&&i.map(function(c,a){return c.externalLink?e.createElement("li",{className:"in-page-navigation-links__link-button",key:a},e.createElement(Fe,{theme:t,label:c.label,icon:"external",hollow:a%2!=0,iconPosition:"right",url:c.url,onClick:c.onClick})):e.createElement("li",{className:"in-page-navigation-links__link-button",key:a},e.createElement(q,{theme:t,label:c.label,hollow:a%2!=0,url:c.url,onClick:c.onClick}))})))}function ol(c){var n,r,o=c.theme,s=void 0===o?"uobmain":o,h=c.inverse,u=void 0!==h&&h,v=c.links,f=c.expandableHeader,g=void 0===f?"Page contents":f,E=a(!1),_=E[0],b=E[1],w=a("not-docked"),q=w[0],y=w[1],M=a(null),N=M[0],C=M[1],k=l(null),x=l(null),T=l(null),L=l(null),z=l(null),H=function(){b(!1)};return t(function(){var e=function(e){!n.current||e.target instanceof HTMLElement&&n.current.contains(e.target)||r()};return document.addEventListener("mousedown",e),document.addEventListener("touchstart",e),function(){document.removeEventListener("mousedown",e),document.removeEventListener("touchstart",e)}},[n=z,r=function(){return H()}]),t(function(){var e;T.current=new IntersectionObserver(function(c){var a;e=null===(a=c.find(function(e){return e.isIntersecting}))||void 0===a?void 0:a.target,y(e?"docked":"not-docked")},{rootMargin:"0px 0px -100%"}),x.current=new IntersectionObserver(function(c){var a,t=null===(a=c.find(function(e){return e.isIntersecting}))||void 0===a?void 0:a.target;t?y("docked-at-bottom"):!t&&e&&y("docked")}),k.current=new IntersectionObserver(function(e){var c,a=null===(c=e.find(function(e){return e.isIntersecting}))||void 0===c?void 0:c.target;a&&C(a.id)},{rootMargin:"0px 0px -".concat(.7*window.innerHeight,"px 0px")});var c=document.querySelectorAll(".anchor-target");c.forEach(function(e){k&&k.current&&k.current.observe(e)});var a=document.querySelectorAll("#footer");a.forEach(function(e){x&&x.current&&x.current.observe(e)});var t=document.querySelectorAll("#sidebar");return t.forEach(function(e){T&&T.current&&T.current.observe(e)}),function(){c.forEach(function(e){k&&k.current&&k.current.unobserve(e)}),t.forEach(function(e){T&&T.current&&T.current.unobserve(e)}),a.forEach(function(e){x&&x.current&&x.current.unobserve(e)})}},[]),v.links.map(function(e){return e.url.substring(1)===N?e.active=!0:e.active=!1}),e.createElement("div",{className:p("in-page-navigation",s&&"theme-".concat(s),u&&"theme-".concat(s,"--inverse"))},e.createElement("div",{className:p("in-page-navigation--mobile",q)},e.createElement("div",{className:"in-page-navigation__closed"},e.createElement("div",{className:"in-page-navigation__top-container"},e.createElement("div",{className:"in-page-navigation__right-wrapper"},e.createElement("div",{className:"in-page-navigation__menu-button"},e.createElement("span",{className:"in-page-navigation__expandable-header"},g),e.createElement(Oe,{theme:"uobmain",icon:"menu",onClick:function(){b(!0)},title:"Open menu",ariaControls:"in-page-navigation",ref:L,ariaExpanded:_})))))),_&&e.createElement("div",{className:"in-page-navigation__overlay"}),e.createElement(m,null,_&&e.createElement(i.div,{className:"in-page-navigation__open",initial:{x:"100%"},animate:{x:"0"},exit:{x:"100%"},transition:{type:"tween"},key:"in-page-navigation__open",ref:z},e.createElement(Ze,null,e.createElement("div",{className:"in-page-navigation__nav"},e.createElement("div",{className:"in-page-navigation__top-container"},e.createElement("div",{className:"in-page-navigation__right-wrapper"},e.createElement("div",{className:"in-page-navigation__close-button"},e.createElement("span",null,"Close"),e.createElement(Oe,{theme:"uobmain",inverse:!0,icon:"cross",onClick:H,title:"Close menu",ariaControls:"in-page-navigation"})))),e.createElement(il,d({},v,{theme:"uobmain"})))))),e.createElement("div",{className:p("in-page-navigation--desktop",q)},e.createElement(il,d({},v,{theme:s}))))}function sl(c){var a=c.text,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=c.fullWidth,i=c.removeBottomPadding,o=void 0!==i&&i,s=c.removeTopPadding,m=void 0!==s&&s;return e.createElement("div",{className:p("intro-text",l&&"theme-".concat(l),n&&"theme-".concat(l,"--inverse"),r&&"intro-text--full-width",o&&"intro-text--no-bottom-padding",m&&"intro-text--no-top-padding")},e.createElement("div",{className:"intro-text__container"},e.createElement("p",{className:"intro-text__text"},a)))}function ml(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=c.cards,r=c.link;return e.createElement("div",{className:p("most-read-news",t&&"theme-".concat(t))},e.createElement("h2",{className:"most-read-news__title"},l),e.createElement("ul",{className:"most-read-news__card-container"},n.map(function(c,a){return e.createElement("li",{className:"most-read-news__card",key:a},e.createElement(Ke,{theme:t,title:c.title,href:c.href,titleTag:"h3",publishDate:c.publishDate}))})),r&&e.createElement(y,{theme:t,inverse:!0,url:r.url,title:r.title}))}function hl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.featuredArticle,n=c.otherLeadArticles,r=c.mostReadNews;return e.createElement("section",{className:p("lead-news-articles",t&&"theme-".concat(t))},e.createElement("div",{className:"lead-news-articles__container"},e.createElement("div",{className:"lead-news-articles__main-container"},e.createElement("div",{className:"lead-news-articles__featured-card"},e.createElement(Ke,d({},l,{isPrimary:!0}))),e.createElement("ul",{className:"lead-news-articles__secondary-card-container"},n.map(function(c,a){return e.createElement("li",{className:"lead-news-articles__secondary-card",key:a},e.createElement(Ke,{theme:t,image:c.image,title:c.title,href:c.href,titleTag:c.titleTag,publishDate:c.publishDate}))}))),e.createElement("div",{className:"lead-news-articles__side-container"},e.createElement(ml,d({},r)))))}function dl(c){var n=c.theme,r=c.showFilterButtonLabel,o=c.numSelected,s=c.filterElement,m=a(!1),h=m[0],d=m[1],u=l(null),v=function(e){"Escape"===e.key&&h&&d(!1)};return t(function(){return document.addEventListener("keydown",v),function(){document.removeEventListener("keydown",v)}}),t(function(){var e,c;h?null===(e=u.current)||void 0===e||e.showModal():null===(c=u.current)||void 0===c||c.close()},[h]),e.createElement(e.Fragment,null,e.createElement("div",{className:p("listing-filter-wrapper","theme-".concat(n))},e.createElement("div",{className:"listing-filter-wrapper__mobile"},e.createElement("button",{className:"listing-filter-wrapper__show-filter-button",onClick:function(){d(!0),document.body.classList.add("lock-scroll")}},e.createElement(_,{theme:"uobmain",icon:"settings"}),r,o&&e.createElement("span",{className:"listing-filter-wrapper__num-selected"},o,e.createElement("span",{className:"sr-only"},o>1?"filters":"filter"," selected"))))),e.createElement(Ze,null,e.createElement(i.dialog,{className:p("listing-filter-wrapper__dialog","theme-".concat(n)),initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},ref:u},e.createElement("div",{className:"listing-filter-wrapper__popup-wrapper"},e.createElement("div",{className:"listing-filter-wrapper__popup"},e.createElement("button",{className:"listing-filter-wrapper__close-button",onClick:function(){d(!1),document.body.classList.remove("lock-scroll")}},e.createElement(_,{icon:"slim-cross",theme:n,ariaHidden:!0}),e.createElement("span",{className:"sr-only"},"Close")),s)))),e.createElement("div",{className:"listing-filter-wrapper__desktop"},s))}function ul(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.details,m=c.showCategory,h=void 0!==m&&m;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},h&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),o&&e.createElement("p",{className:"listing-result-card__description"},o),s.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:s,theme:t}))))}function vl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.titleTag,o=void 0===i?"h2":i,s=c.url,m=c.description,h=c.supervisors,u=c.department,v=c.details,p=c.showCategory,f=void 0!==p&&p;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},f&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement(N,{htmlTag:"h3"===o?"h3":"h2"},e.createElement("a",{className:"listing-result-card__title",href:s},r)),(h||u)&&e.createElement("div",{className:"listing-result-card__course-info"},h&&e.createElement("p",{className:"listing-result-card__supervisors"},"Supervisors: ",h),u&&e.createElement("p",{className:"listing-result-card__department"},u)),m&&e.createElement("p",{className:"listing-result-card__description"},m),v.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:v,theme:t}))))}function pl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.type,i=c.image,o=c.title,s=c.url,m=c.description,h=c.details,u=c.showCategory,v=void 0!==u&&u,p=c.cardDescriptionIsRichText,f=void 0!==p&&p,g=c.titleTag,E=void 0===g?"h2":g,_=c.eventStatus,b=void 0===_?void 0:_;return e.createElement(e.Fragment,null,i&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},i)),b&&e.createElement("div",{className:"listing-result-card__event-graphic"},e.createElement(Ie,{theme:"uobmain",status:b,day:void 0,month:void 0}))),e.createElement("div",{className:"listing-result-card__text"},v&&e.createElement("p",{className:"listing-result-card__category"},r),e.createElement(N,{htmlTag:E},e.createElement("a",{className:"listing-result-card__title",href:s},o)),m&&!f&&e.createElement("p",{className:"listing-result-card__description"},m),m&&f&&e.createElement(C,{theme:t,inverse:n,text:m}),h.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:h,theme:t}))))}function fl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.author,m=c.details,h=c.showCategory,u=void 0!==h&&h;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},u&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),s&&e.createElement("p",{className:"listing-result-card__author"},"by ",s),o&&e.createElement("p",{className:"listing-result-card__description"},o),m.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:m,theme:t}))))}function gl(c){var a=c.image,t=c.title,l=c.url,n=c.description;return e.createElement(e.Fragment,null,a&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},a))),e.createElement("div",{className:"listing-result-card__text"},e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:l},t)),n&&e.createElement("p",{className:"listing-result-card__description"},n)))}function El(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.type,n=c.image,r=c.title,i=c.url,o=c.description,s=c.jobTitle,m=c.department,h=c.details,u=c.showCategory,v=void 0!==u&&u;return e.createElement(e.Fragment,null,n&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},n))),e.createElement("div",{className:"listing-result-card__text"},v&&e.createElement("p",{className:"listing-result-card__category"},l),e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:i},r)),(s||m)&&e.createElement("div",{className:"listing-result-card__staff-info"},s&&e.createElement("p",{className:"listing-result-card__job-title"},s),m&&e.createElement("p",{className:"listing-result-card__department"},m)),o&&e.createElement("p",{className:"listing-result-card__description"},o),h.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:h,theme:t}))))}function _l(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.image,n=c.title,r=c.url,i=c.description,o=c.jobTitle,s=c.department,m=c.details;return e.createElement(e.Fragment,null,l&&e.createElement("div",{className:"listing-result-card__image"},e.createElement(L,d({},l))),e.createElement("div",{className:"listing-result-card__text"},e.createElement("h2",null,e.createElement("a",{className:"listing-result-card__title",href:r},n)),(o||s)&&e.createElement("div",{className:"listing-result-card__staff-info"},o&&e.createElement("p",{className:"listing-result-card__job-title"},o),s&&e.createElement("p",{className:"listing-result-card__department"},s)),i&&e.createElement("p",{className:"listing-result-card__description"},i.length>120?"".concat(i.slice(0,120),"..."):i),m.length>0&&e.createElement("div",{className:"listing-result-card__details"},e.createElement(Qe,{details:m,theme:t}))))}function bl(c){return e.createElement("article",{className:p("listing-result-card",c.theme&&"theme-".concat(c.theme))},"page"===c.type&&e.createElement(gl,d({},c)),"course"===c.type&&e.createElement(vl,d({},c)),"accomodation"===c.type&&e.createElement(ul,d({},c)),"event"===c.type&&e.createElement(pl,d({},c)),"news"===c.type&&e.createElement(fl,d({},c)),"staff"===c.type&&e.createElement(El,d({},c)),"profile"===c.type&&e.createElement(_l,d({},c)))}function wl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.showCategory,n=void 0!==l&&l,r=c.cards,i=c.headingInfo;return e.createElement(e.Fragment,null,i&&e.createElement(x,d({},i,{theme:t,fullWidth:!0})),e.createElement("ul",{className:p("listing-results",t&&"theme-".concat(t))},r.map(function(c,a){return e.createElement("li",{className:"listing-results__card",key:a},e.createElement(bl,d({},c,{showCategory:n,theme:t})))})))}function ql(c){var a=c.count,t=c.theme,l=void 0===t?"uobmain":t;return e.createElement("p",{className:p("listing-results-count",l&&"theme-".concat(l))},e.createElement("span",{className:"listing-results-count__number"},a.toLocaleString())," results were found based on your search term")}function yl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.listItems;return e.createElement("div",{className:p("list-table",t&&"theme-".concat(t))},(null==l?void 0:l.length)?e.createElement("ul",{className:"list-table__list"},null==l?void 0:l.map(function(c,a){return e.createElement("li",{key:c+a,className:"list-table__list-item"},e.createElement(C,{inverse:!0,theme:"uobmain",text:c}))})):null)}function Ml(c){var a=c.children;return e.createElement("main",{id:"main"},a)}function Nl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.heading,n=c.cards,r=c.cardType,i=void 0===r?"featured-news":r;return e.createElement("section",{className:p("news-articles-promo-block",t&&"theme-".concat(t),i&&"news-articles-promo-block--".concat(i))},e.createElement("div",{className:"news-articles-promo-block__heading-container"},l&&e.createElement("h2",{className:"news-articles-promo-block__heading"},l)),e.createElement("div",{className:"news-articles-promo-block__cards news-articles-promo-block__cards--mobile"},"featured-news"===i&&e.createElement(ac,{theme:t,type:"featured-news",cards:n,inverse:!0,cardTitleTag:"h3"}),"promo-video"===i&&e.createElement(ac,{theme:t,type:"promo-video",cards:n,inverse:!0,cardTitleTag:"h3",setCardInverse:"dark"})),e.createElement("ul",{className:"news-articles-promo-block__cards news-articles-promo-block__cards--desktop"},n.map(function(c,a){return e.createElement("li",{key:a},"featured-news"===i&&e.createElement(Ke,d({},c,{inverse:!0,titleTag:"h3"})),"promo-video"===i&&e.createElement(Re,d({},c,{inverse:!1,titleTag:"h3"})))})))}function Cl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.numOfPages,n=c.onClick,r=c.currentPage,i=xe("768px"),o=e.createElement("li",null,e.createElement("span",{className:"pagination__ellipse"},"..."));return i&&l<=4?e.createElement(e.Fragment,null,Array(l).fill(0).map(function(c,a){return e.createElement("li",{className:p("pagination__number",r===a&&"pagination__number--selected"),key:a},e.createElement(q,{label:(a+1).toString(),onClick:function(){return n(a)},hollow:!(r===a),theme:t}))})):i&&l>4?e.createElement(e.Fragment,null,r>0&&e.createElement("li",{key:0,className:"pagination__number"},e.createElement(q,{label:"1",onClick:function(){return n(0)},theme:t,hollow:!0})),r+1>=3&&o,e.createElement("li",{key:r,className:"pagination__number pagination__number--selected"},e.createElement(q,{label:"".concat(r+1," "),onClick:function(){return n(r)},theme:t})),r+1<l-1&&o,r!==l-1&&e.createElement("li",{key:l-1,className:"pagination__number"},e.createElement(q,{label:l.toString(),onClick:function(){return n(l-1)},theme:t,hollow:!0}))):!i&&l<=6?e.createElement(e.Fragment,null,Array(l).fill(0).map(function(c,a){return e.createElement("li",{key:a,className:p("pagination__number",r===a&&"pagination__number--selected","test")},e.createElement(q,{label:(a+1).toString(),onClick:function(){return n(a)},hollow:!(r===a),theme:t}))})):!i&&l>6?e.createElement(e.Fragment,null,r>0&&e.createElement("li",{key:0,className:"pagination__number start"},e.createElement(q,{label:"1",onClick:function(){return n(0)},theme:t,hollow:!0})),r+1>=4&&o,r>1&&e.createElement("li",{key:r-1,className:"pagination__number before"},e.createElement(q,{label:(r>=1?r:r-1).toString(),onClick:function(){return n(r-1)},theme:t,hollow:!0})),e.createElement("li",{key:r,className:"pagination__number pagination__number--selected current"},e.createElement(q,{label:"".concat(r+1),onClick:function(){return n(r)},theme:t})),r+1<l-1&&e.createElement("li",{key:r+1,className:"pagination__number after"},e.createElement(q,{label:"".concat(r+2),onClick:function(){return n(r+1)},theme:t,hollow:!0})),r+1<l-2&&o,r+1!==l&&e.createElement("li",{key:l-1,className:"pagination__number end"},e.createElement(q,{label:"".concat(l),onClick:function(){return n(l-1)},theme:t,hollow:!0}))):e.createElement(e.Fragment,null)}function kl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.numOfPages,n=c.onClick,r=c.currentPage,i=!xe("1248px");return l<=1?e.createElement(e.Fragment,null):e.createElement("div",{className:p("pagination",t&&"theme-".concat(t))},e.createElement("ul",{className:"pagination__container"},e.createElement("li",{className:"pagination__prev",key:"prev"},i?e.createElement(q,{theme:t,label:"Previous",onClick:function(){return n(r-1)},hollow:!0,disabled:r<1}):e.createElement(Oe,{theme:t,icon:"arrow-left",title:"Previous",onClick:function(){return n(r-1)},disabled:r<1,inverse:!0})),e.createElement(Cl,{currentPage:r,onClick:n,theme:t,numOfPages:l}),e.createElement("li",{className:"pagination__next",key:"next"},i?e.createElement(q,{theme:t,label:"Next",onClick:function(){return n(r+1)},hollow:!0,disabled:r+1===l}):e.createElement(Oe,{theme:t,icon:"arrow-right",title:"Next",onClick:function(){return n(r+1)},disabled:r+1===l,inverse:!0}))))}function xl(c){var a,t=c.theme,l=c.inverse,n=c.type,r=c.title,i=c.description,o=c.link,s=c.cards,m=c.imageOrientation,h=void 0===m?"left":m,u=c.titleTag,v=void 0===u?"h2":u,f=c.cardTitleTag,g=void 0===f?"h3":f,_=c.cardCopyIsRichText,b=void 0!==_&&_,w=c.fullWidth,q=void 0!==w&&w,M=c.fullWidthTitle,C=void 0!==M&&M,k=c.showFilters,x=void 0!==k&&k,T=c.firstFilterSelect,L=c.secondFilterSelect,z=!1;xe("768px")?s.length>1&&(z=!0):(q&&s.length>2||s.length>3)&&(z=!0);var H=p(((a={})["promo-block__grid"]=!0,a["promo-block__grid--single"]=1===s.length,a["promo-block__grid--two-cards"]=2===s.length,a["promo-block__grid--three-cards"]=3===s.length,a["promo-block__grid--four-plus-cards"]=s.length>3,a));return e.createElement("div",{className:p("promo-block","promo-block--".concat(n),t&&"theme-".concat(t),l&&"theme-".concat(t,"--inverse"),q&&"promo-block--full-width")},e.createElement("div",{className:"promo-block__container"},e.createElement("div",{className:p("promo-block__top",C&&"promo-block__top--full-width")},r&&e.createElement(N,{htmlTag:v,classNames:p("promo-block__title","h3"===v&&"promo-block__title--h3")},r),i&&e.createElement(E,{theme:"uobmain",inverse:l,text:i}),o&&e.createElement("div",{className:"promo-block__text-link"},e.createElement(y,{theme:t,inverse:l,url:o.url,title:o.title,externalLink:o.externalLink}))),x&&e.createElement("div",{className:"promo-block__filters"},e.createElement("div",{className:"promo-block__filter-wrapper"},T&&e.createElement(Lt,d({},T))),e.createElement("div",{className:"promo-block__filter-wrapper"},L&&e.createElement(Lt,d({},L)))),e.createElement("div",{className:"promo-block__content"},e.createElement("div",{className:"promo-block__cards"},!z&&e.createElement("ul",{className:H},s.map(function(c,a){return e.createElement("li",{className:"promo-block__card-item",key:a},function(c){var a=d(d({},c),{cardCopyIsRichText:b});switch(n){case"promo":return e.createElement(Ae,d({},a));case"promo-signpost":return e.createElement($e,d({},c));case"promo-video":return e.createElement(Re,d({},c));case"promo-profile":return e.createElement(ec,d({},c));default:return e.createElement(e.Fragment,null)}}(d(d({},c),{inverse:l,isSingle:1===s.length,imageOrientation:h,titleTag:g})))})),z&&e.createElement(ac,{theme:t,inverse:l,type:n,cards:s,cardTitleTag:g,cardCopyIsRichText:b})))))}function Tl(c){var a=c.theme,t=c.inverse,l=c.type,n=c.title,r=c.description,i=c.link,o=c.cards,s=c.imageOrientation,m=void 0===s?"left":s,h=c.fullWidth;return e.createElement("div",{className:p("promo-block-grid","promo-block-grid--".concat(l),a&&"theme-".concat(a),t&&"theme-".concat(a,"--inverse"),h&&"promo-block-grid--full-width"),id:"promo-block-grid"},e.createElement("div",{className:"promo-block-grid__container"},e.createElement("div",{className:"promo-block-grid__top"},n&&e.createElement("h2",null,n),r&&e.createElement(E,{theme:"uobmain",inverse:t,text:r}),i&&e.createElement("div",{className:"promo-block-grid__text-link"},e.createElement(y,{theme:"uobmain",inverse:t,url:i.url,title:i.title,externalLink:i.externalLink}))),e.createElement("div",{className:"promo-block-grid__content"},e.createElement("div",{className:"promo-block-grid__cards"},o.length>0&&e.createElement("ul",{className:"promo-block-grid__grid"},o.map(function(c,a){return e.createElement("li",{className:"promo-block-grid__card-item",key:a},function(c){switch(l){case"promo":return e.createElement(Ae,d({},c));case"promo-signpost":return e.createElement($e,d({},c));case"promo-video":return e.createElement(Re,d({},c));default:return e.createElement(e.Fragment,null)}}(d(d({},c),{inverse:t,isSingle:1===o.length,imageOrientation:m,titleTag:n?"h3":"h2"})))}))))))}function Ll(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=c.title,r=c.description,i=c.cite,o=c.role,s=c.quote,m=c.quoteeProfileImage,h=c.quoteeProfileImageAltText,d=c.cta,u=c.fullWidth,v=void 0!==u&&u,f=c.htmlTag;return e.createElement("div",{className:p("quote-block","theme-".concat(t),l&&"theme-".concat(t,"--inverse"),v&&"quote-block--full-width")},(n||r)&&e.createElement(x,{theme:t,inverse:l,htmlTag:f,title:n,description:r}),e.createElement("blockquote",{className:p("quote-block__container",!m&&"quote-block__container--no-image")},e.createElement("div",{className:"quote-block__doublequote quote-block__doublequote--open"},e.createElement(_,{icon:"quote-marks",theme:t})),e.createElement("p",{className:"quote-block__quote"},s),m&&e.createElement("div",{className:"quote-block__quotee-image"},e.createElement(L,{src:{default:m},altText:h})),(i||o)&&e.createElement("footer",{className:"quote-block__cite"},i&&e.createElement("cite",{className:"quote-block__cite-cite"},i),o&&e.createElement("div",{className:"quote-block__cite-role"},o)),e.createElement("div",{className:"quote-block__doublequote quote-block__doublequote--close"},e.createElement(_,{icon:"quote-marks",theme:t})),d&&e.createElement("div",{className:"quote-block__optional-link"},e.createElement(y,{inverse:l,onKeyDown:function(){},theme:t,title:d.title,url:d.url}))))}function zl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.heading,o=c.description,s=c.linkProps,m=c.headingStyle,h=c.fullWidth,u=c.cards,v=xe("768px"),f=v&&u.length>1||!v&&h&&u.length>2||!v&&!h&&u.length>3,g=p(((a={})["related-courses__grid"]=!0,a["related-courses__grid--single"]=1===u.length,a["related-courses__grid--two-cards"]=2===u.length,a["related-courses__grid--three-cards"]=3===u.length,a["related-courses__grid--four-plus-cards"]=u.length>3,a));return e.createElement("section",{className:p("related-courses",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),h&&"related-courses--full-width")},e.createElement("div",{className:"related-courses__container"},e.createElement("h2",{className:p("related-courses__heading",m&&"related-courses__heading--".concat(m))},i),o&&e.createElement("div",{className:"related-courses__description"},o),s&&s.url&&s.title&&e.createElement("div",{className:"related-courses__arrow-link-container"},e.createElement(y,{theme:l,inverse:r,title:s.title,url:s.url})),e.createElement("div",{className:"related-courses__cards"},!f&&e.createElement("ul",{className:g},u.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},e.createElement(We,d({},c)))})),f&&e.createElement(ac,{theme:l,inverse:r,type:"related",cards:u,cardTitleTag:"h3"}))))}function Hl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.headingProps,m=c.cards,h=xe("768px"),u=h&&m.length>1||!h&&m.length>2,v=p(((a={})["scholarship-carousel__grid"]=!0,a["scholarship-carousel__grid--single"]=1===m.length,a["scholarship-carousel__grid--two-cards"]=2===m.length,a["scholarship-carousel__grid--three-plus-cards"]=m.length>3,a));return e.createElement("section",{className:p("scholarship-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"scholarship-carousel--full-width")},e.createElement("div",{className:"scholarship-carousel__container"},s&&e.createElement(x,d({},s,{theme:l,inverse:r,fullWidth:o})),e.createElement("div",{className:"scholarship-carousel__cards"},!u&&e.createElement("ul",{className:v},m.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},e.createElement(Je,d({},c,{inverse:r})))})),u&&e.createElement(ac,{theme:l,inverse:r,type:"scholarship",cards:m,cardTitleTag:"h3"}))))}function Vl(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.heading,m=c.headingStyle,h=void 0===m?null:m,u=c.cards,v=c.singleLink,f=c.titleTag,g=void 0===f?"h2":f,E=c.useCarousel,_=void 0===E||E,b=c.cardType,w=void 0===b?"staff":b,q=xe("768px"),M=_&&q&&u.length>1||_&&!q&&u.length>2,C="staff"===w,k=p(((a={})["staff-listing-carousel__grid"]=!0,a["staff-listing-carousel__grid--single"]=1===u.length,a["staff-listing-carousel__grid--two-cards"]=2===u.length,a["staff-listing-carousel__grid--three-plus-cards"]=u.length>3,a));return e.createElement("section",{className:p("staff-listing-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"staff-listing-carousel--full-width",!_&&"staff-listing-carousel--no-carousel")},e.createElement("div",{className:"staff-listing-carousel__container"},s&&e.createElement(N,{htmlTag:g,classNames:p("staff-listing-carousel__heading","staff-listing-carousel__heading--".concat(g),h&&"staff-listing-carousel__heading--".concat(h))},s),e.createElement("div",{className:"staff-listing-carousel__cards"},!M&&e.createElement("ul",{className:k},u.map(function(c,a){return e.createElement("li",{className:"related-courses__card-item",key:a},C?e.createElement(Ue,d({},c,{theme:l,inverse:r,isSingle:1===u.length})):e.createElement(ec,d({},c,{theme:l,inverse:r})))})),M&&e.createElement(ac,{theme:l,inverse:r,type:w,cards:u,cardTitleTag:"h3"})),1===u.length&&v&&e.createElement(y,{theme:l,url:v.url,title:v.title,inverse:!0})))}function Sl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.sidebarElement,n=c.children;return e.createElement("div",{id:"sidebar",className:p("sidebar-wrapper",t&&"theme-".concat(t),!l&&"sidebar-wrapper--no-side-element")},e.createElement("div",{className:"sidebar-wrapper__grid-container"},l&&e.createElement("div",{className:"sidebar-wrapper__sidebar"},l),e.createElement("div",{className:"sidebar-wrapper__children"},n)))}function Pl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.items,i=c.fullWidth,o=void 0!==i&&i,s=c.htmlTag,m=void 0===s?"h2":s;return e.createElement("div",{className:p("signpost",o&&"signpost--full-width",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:"signpost__container"},e.createElement("div",{className:"signpost__grid"},r.map(function(c){return e.createElement("div",{className:"signpost__item",key:c.title},c.tag&&e.createElement("p",{className:"signpost__tag"},c.tag),e.createElement(N,{htmlTag:m,classNames:"signpost__title"},c.title),e.createElement(y,{url:c.linkUrl,title:c.linkLabel,theme:t,inverse:n,externalLink:c.external}))}))))}function Ol(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0!==l&&l,r=c.includeIcon,i=c.link,o=c.fullWidth;return e.createElement("div",{className:p("single-button",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"),o&&"single-button--full-width")},e.createElement("div",{className:"single-button__container"},r?e.createElement(Fe,d({},i,{inverse:!n})):e.createElement(q,d({},i,{inverse:!n}))))}function Zl(c){var a=c.theme,t=void 0===a?"uobmain":a;return e.createElement("div",{className:p("skip-to-content",t&&"theme-".concat(t))},e.createElement("a",{className:"skip-to-content__link",href:"#main"},"Skip to main content"))}function Bl(e,c){return g("".concat(null!=e?e:""," ").concat(c))}function Fl(c){var a=c.children,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0!==n&&n;return e.createElement("div",{className:p("tabs__list__container",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"))},e.createElement("ul",{className:"tabs__list",role:"tablist"},a))}function Dl(c){var a=c.title,t=c.htmlTag,l=void 0===t?"h3":t,n=c.theme,r=void 0===n?"uobmain":n,i=c.inverse,o=void 0!==i&&i,s=c.isActive,m=c.children,h=c.tabsBlockName;if(!s)return null;var d=Bl(null!=h?h:"",a);return e.createElement("div",{id:h,className:p("tabs__panel",r&&"theme-".concat(r),o&&"theme-".concat(r,"--inverse")),role:"tabpanel","aria-labelledby":"tab_"+d},e.createElement(N,{htmlTag:l,classNames:"tabs__panel-title"},a),m)}function Il(c){var a=c.id,n=c.theme,r=void 0===n?"uobmain":n,i=c.inverse,o=void 0!==i&&i,s=c.tabItem,m=c.isActive,h=c.hasFocus,d=c.tabsBlockName,u=c.handleClick,v=c.handleKeyboardNavigation,f=l(null);t(function(){m&&h&&f.current&&(f.current.focus(),window.matchMedia("min-width: 768px").matches&&f.current.scrollIntoView())});var g=Bl(null!=d?d:"",s.title);return e.createElement("li",{className:"tabs__list-item",role:"presentation"},e.createElement("button",{className:p("tabs__tab",r&&"theme-".concat(r),o&&"theme-".concat(r,"--inverse"),m&&"active"),onClick:function(e){return u(e,a)},onKeyDown:v,ref:f,id:"tab_"+g,role:"tab","aria-controls":g,"aria-selected":m?"true":"false",tabIndex:m?0:-1,type:"button"},s.title))}function Al(c){var r=c.theme,i=void 0===r?"uobmain":r,o=c.inverse,s=void 0!==o&&o,m=c.title,h=c.description,u=c.tabItems,v=c.fullWidth,f=c.htmlTag,g=void 0===f?"h2":f,_=c.removeBottomPadding,b=void 0!==_&&_,w=c.name,N=c.enableHashNavigation,C=void 0!==N&&N,k=l(null),L=n(function(){return u.findIndex(function(e){return Bl(null!=w?w:"",e.title)===window.location.hash.substring(1)})},[u,w]),z=a(0),H=z[0],V=z[1],S=a(-1),P=S[0],O=S[1],Z=xe("1248px");function B(e){if(C){var c=window.location.href.replace(window.location.hash,""),a=Bl(null!=w?w:"",u[e].title);history.pushState(null,"null",c.concat("#",a))}}function F(e,c){e.preventDefault(),V(c),B(c)}t(function(){if(0!==window.location.hash.length){var e=L();e<0||(V(e),O(e))}},[L,V]);var D=function(e){switch(e.key){case"ArrowLeft":case"ArrowUp":case"Left":case"Up":if(0===H)return;V(H-1),O(H-1),B(H-1);break;case"ArrowRight":case"ArrowDown":case"Right":case"Down":if(H>=u.length-1)return;V(H+1),O(H+1),B(H+1);break;case"Home":V(0),O(0),B(0);break;case"End":V(u.length-1),O(u.length-1),B(u.length-1)}};function I(){var e="h3";return m&&"h2"===g?e="h3":m&&"h3"===g&&(e="h4"),e}return t(function(){var e=function(e){if(e.preventDefault(),0!==window.location.hash.length){var c=L();c<0||(V(c),O(c))}};return window.addEventListener("hashchange",e),function(){window.removeEventListener("hashchange",e)}},[H,L]),e.createElement(e.Fragment,null,Z&&e.createElement(T,{heading:{title:m,description:h,fullWidth:v,htmlTag:g},theme:i,inverse:s,fullWidth:v,accordionItems:u.map(function(e,c){return{key:e.title||c,title:e.title,text:e.content,titleTag:e.titleTag?e.titleTag:I(),primaryButton:e.primaryButton,secondaryButton:e.secondaryButton,link:e.link}})}),e.createElement("div",{className:p("tabs",i&&"theme-".concat(i),s&&"theme-".concat(i,"--inverse"),v&&"tabs--full-width",b&&"tabs--no-bottom-padding"),id:"tabs",ref:k},!Z&&e.createElement(e.Fragment,null,e.createElement(x,{theme:i,inverse:s,htmlTag:g,title:m,description:h,fullWidth:v}),e.createElement("div",{className:"tabs__container"},e.createElement("span",null,e.createElement(Fl,{theme:i,inverse:s},u.map(function(c,a){return e.createElement(Il,{key:a,id:a,theme:i,inverse:s,tabItem:c,tabListTopRef:k,isActive:a===H,hasFocus:a===P,enableHashNavigation:C,tabsBlockName:w,handleClick:F,handleKeyboardNavigation:D})})),u.map(function(c,a){return e.createElement(Dl,{key:a,isActive:a===H,inverse:s,theme:i,title:c.title,tabsBlockName:w,htmlTag:c.titleTag?c.titleTag:I()},c.content&&e.createElement(E,{theme:i,inverse:s,text:c.content}),c.accordionItems&&c.accordionItems.map(function(c){return e.createElement(M,d({key:c.key},c,{inverse:s}))}),(c.primaryButton&&c.primaryButton.text||c.secondaryButton&&c.secondaryButton.text)&&e.createElement("div",{className:"tabs__optional-buttons"},c.primaryButton&&c.primaryButton.text&&e.createElement(q,{label:c.primaryButton.text,url:c.primaryButton.url,theme:i,inverse:!s}),c.secondaryButton&&c.secondaryButton.text&&e.createElement(q,{hollow:!0,label:c.secondaryButton.text,url:c.secondaryButton.url,theme:i,inverse:!s})),c.link&&c.link.text&&e.createElement("div",{className:"tabs__optional-link"},e.createElement(y,{theme:i,inverse:s,url:c.link.url,title:c.link.text})))}))))))}function $l(c){var a=c.text,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=c.headingLevel,i=c.headingText,o=c.url,s=c.linkTitle,m=c.externalLink,h=c.linkStyle,d=c.fullWidth,u=c.removeBottomPadding,v=void 0!==u&&u,f=r;return e.createElement("div",{className:p("text-with-background",l&&"theme-".concat(l),n&&"theme-".concat(l,"--inverse"),d&&"text-with-background--full-width",v&&"text-with-background--no-bottom-padding")},i&&e.createElement("div",{className:"text-with-background__heading-wrapper"},e.createElement(f,null,i)),e.createElement(E,{text:a,inverse:n,theme:l}),o&&s&&e.createElement("div",{className:"text-with-background__link-wrapper"},e.createElement("div",{className:"text-with-background__link-inner-wrapper"},("primary"===h||"secondary"===h)&&e.createElement(q,{url:o,theme:l,label:s,externalLink:m,hollow:"secondary"===h,inverse:!n}),"paragraph-link"===h&&e.createElement(St,{url:o,label:s,externalLink:m,theme:l,inverse:n}))))}function Rl(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.label,n=c.url,r=c.externalLink;return e.createElement("a",{className:p("pill",t&&"theme-".concat(t)),href:n,target:r?"_blank":"_self",rel:r?"noopener noreferrer":""},l)}function jl(c){var a=c.topics,t=c.theme,l=void 0===t?"uobmain":t,n=c.titleTag,r=c.heading;return e.createElement("section",{className:p("topics-selector",l&&"theme-".concat(l))},e.createElement("div",{className:"topics-selector__container"},"h2"===n?e.createElement("h2",{className:"topics-selector__heading"},r):e.createElement("h3",{className:"topics-selector__heading"},r),e.createElement("ul",{className:"topics-selector__topics-container"},a.map(function(c,a){return e.createElement("li",{className:"topics-selector__topic",key:a},e.createElement(Rl,{theme:l,label:c.label,url:c.url,externalLink:c.externalLink}))}))))}tl.displayName="HeroCardContent",h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h(),h();var Ul,Wl={exports:{}};var Gl,Kl=(Ul||(Ul=1,Gl=Wl,function(e,c){Gl.exports=c()}(0,function(){var e=[],c=[],a={},t={},l={};function n(e){return"string"==typeof e?new RegExp("^"+e+"$","i"):e}function r(e,c){return e===c?c:e===e.toLowerCase()?c.toLowerCase():e===e.toUpperCase()?c.toUpperCase():e[0]===e[0].toUpperCase()?c.charAt(0).toUpperCase()+c.substr(1).toLowerCase():c.toLowerCase()}function i(e,c){return e.replace(c[0],function(a,t){var l,n,i=(l=c[1],n=arguments,l.replace(/\$(\d{1,2})/g,function(e,c){return n[c]||""}));return r(""===a?e[t-1]:a,i)})}function o(e,c,t){if(!e.length||a.hasOwnProperty(e))return c;for(var l=t.length;l--;){var n=t[l];if(n[0].test(c))return i(c,n)}return c}function s(e,c,a){return function(t){var l=t.toLowerCase();return c.hasOwnProperty(l)?r(t,l):e.hasOwnProperty(l)?r(t,e[l]):o(l,t,a)}}function m(e,c,a,t){return function(t){var l=t.toLowerCase();return!!c.hasOwnProperty(l)||!e.hasOwnProperty(l)&&o(l,l,a)===l}}function h(e,c,a){return(a?c+" ":"")+(1===c?h.singular(e):h.plural(e))}return h.plural=s(l,t,e),h.isPlural=m(l,t,e),h.singular=s(t,l,c),h.isSingular=m(t,l,c),h.addPluralRule=function(c,a){e.push([n(c),a])},h.addSingularRule=function(e,a){c.push([n(e),a])},h.addUncountableRule=function(e){"string"!=typeof e?(h.addPluralRule(e,"$0"),h.addSingularRule(e,"$0")):a[e.toLowerCase()]=!0},h.addIrregularRule=function(e,c){c=c.toLowerCase(),e=e.toLowerCase(),l[e]=c,t[c]=e},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach(function(e){return h.addIrregularRule(e[0],e[1])}),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach(function(e){return h.addPluralRule(e[0],e[1])}),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach(function(e){return h.addSingularRule(e[0],e[1])}),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(h.addUncountableRule),h})),Wl.exports),Yl=Gc(Kl);function Jl(c){var t=c.theme,l=c.heading,n=c.selectContent,r=c.defaultIsOpen,i=void 0!==r&&r;n&&(i=!!n.defaultValue||i);var o=a(i),s=o[0],m=o[1];return e.createElement("fieldset",{className:p("filter-accordion-select",s&&"filter-accordion-select--open",t&&"theme-".concat(t))},e.createElement("legend",{className:"filter-accordion-select__legend"},e.createElement("button",{className:"filter-accordion-select__button",onClick:function(){return m(function(e){return!e})},"aria-expanded":s,"aria-controls":l.replace(" ","")},l,e.createElement(_,{icon:"chevron-down",theme:t,inverse:!0,ariaHidden:!0}))),s&&e.createElement("div",{className:"filter-accordion-select__select-wrapper"},e.createElement(Lt,d({theme:t,inverse:!0},n))))}function Xl(c){var a=c.theme,t=c.name,l=c.id,n=c.label,r=c.defaultValue,i=c.onChange;return e.createElement("div",{className:p("date-input",a&&"theme-".concat(a))},e.createElement("label",{htmlFor:l,className:"date-input__label"},n),e.createElement("input",{type:"date",className:"date-input__input",defaultValue:r,onChange:i,name:t,id:l}))}h(),h(),h();var Ql,en=function(e){var c=e.split(" "),a=c[c.length-1];return c[c.length-1]=Yl(a),c.join(" ")};function cn(c){var a=c.theme,t=c.heading,l=c.listingGroups,n=c.onClearFilters,r=c.onViewResults;return e.createElement("div",{className:p("standard-listing-filter",a&&"theme-".concat(a))},e.createElement("p",{className:"standard-listing-filter__heading"},t),e.createElement("ul",{className:"standard-listing-filter__list"},l.map(function(c){var t;return"date"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Xl,d({},c,{theme:a,defaultValue:null!==(t=c.defaultValue)&&void 0!==t?t:"",onChange:c.onChange}))):"radio"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Uc,{type:"radio",heading:c.heading,theme:a,showMoreText:en(c.heading)||"",inputs:c.inputs.map(function(e){return{name:c.name,value:e.value,label:e.label,id:e.id,defaultChecked:!!c.defaultValue&&c.defaultValue===e.value,onChange:c.onChange}})})):"checkbox"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Uc,{type:"checkbox",heading:c.heading,theme:a,showMoreText:en(c.heading)||"",inputs:c.inputs.map(function(e){return{name:c.name,value:e.value,label:e.label,id:e.id,defaultChecked:!!c.defaultValues&&c.defaultValues.includes(e.value),onChange:c.onChange}})})):"select"===c.type?e.createElement("li",{className:"standard-listing-filter__item",key:c.name},e.createElement(Jl,{heading:c.heading,selectContent:c.selectContent,theme:a})):void 0})),r&&e.createElement("div",{className:"standard-listing-filter__results-button"},e.createElement(q,{label:"View selected results",onClick:r,theme:a})),e.createElement("div",{className:"standard-listing-filter__clear-button"},e.createElement(q,{label:"Clear filters",onClick:n,theme:a,hollow:!0})))}function an(c){var a=c.theme,t=c.tag,l=c.title,n=c.linkUrl,r=c.linkText,o=c.externalLink,s=c.cards,m={initial:{opacity:0,y:150},animate:function(e){return{opacity:1,y:0,transition:{duration:.8,type:"spring",bounce:.2,delay:.2*e}}}};return e.createElement("div",{className:p("video-card-component",a&&"theme-".concat(a)),id:"video-card-component"},e.createElement("div",{className:"video-card-component__content"},t&&e.createElement("p",{className:"video-card-component__tag"},t),e.createElement("h2",{className:"video-card-component__title"},l),n&&r&&e.createElement("div",{className:"video-card-component__link"},e.createElement(y,{theme:a,url:n,title:r,inverse:!0,externalLink:o})),e.createElement("div",{className:"video-card-component__carousel"},e.createElement(ac,{theme:a,type:"video",inverse:!0,cards:s,cardTitleTag:"h3"})),e.createElement("ul",{className:p("video-card-component__cards-desktop",(!n||!r)&&"video-card-component__cards-desktop--no-link")},s.map(function(c,t){return e.createElement(i.li,{key:t,variants:m,initial:"initial",whileInView:"animate",viewport:{once:!0,amount:.2},custom:t},t<=1?e.createElement("div",{className:"video-card-component__lines video-card-component__lines--".concat(t)},1===t&&e.createElement("svg",{width:"406",height:"128",viewBox:"0 0 406 128",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("path",{d:"M1 1L123 29L210 127.5",stroke:"black"}),e.createElement("path",{d:"M13 112L123 29L405 51",stroke:"black"}))):"",e.createElement(De,{theme:a,image:{src:{default:c.image.src.default,medium:c.image.src.medium,small:c.image.src.small},altText:""},title:c.title,youtubeId:c.youtubeId,buttonLabel:c.buttonLabel,titleTag:"h3"}))}))))}function tn(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.imageSrc,n=c.onClick;return e.createElement("div",{className:p("video-placeholder",t&&"theme-".concat(t))},e.createElement(L,{src:l,altText:""}),e.createElement("button",{className:"video-placeholder__button",onClick:n},e.createElement("div",{className:"video-placeholder__svg-wrapper"},e.createElement("svg",{width:"11",height:"14",viewBox:"0 0 11 14",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},e.createElement("path",{d:"M0 0V14L11 7L0 0Z",fill:"currentColor"}))),e.createElement("span",{className:"sr-only"},"Watch the video")))}function ln(c){var t=c.theme,l=void 0===t?"uobmain":t,n=c.imageSrc,r=c.videoUrl,i=c.videoId,o=a(!1),s=o[0],m=o[1];return e.createElement("div",{className:p("video-with-placeholder",l&&"theme-".concat(l))},s?e.createElement(Pe,{url:r,id:i,autoPlay:!0,theme:l}):e.createElement(tn,{imageSrc:n,onClick:function(){return m(!0)},theme:l}))}function nn(c){var t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0!==n&&n,i=c.imageSrc,o=c.videoUrl,s=c.videoId,m=c.heading,h=c.audioDescribedVideoId,u=c.audioDescribedVideoUrl,v=c.transcript,f=c.fullWidth,g=void 0!==f&&f,E=c.videoCaption,_=c.videoCredit,b=a(!1),w=b[0],q=b[1];return e.createElement("div",{className:p("video-embed",g&&"video-embed--full-width",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"))},m&&e.createElement(x,d({},m,{theme:l,inverse:r})),e.createElement("div",{className:"video-embed__grid"},e.createElement("div",{className:"video-embed__content-wrapper"},e.createElement(ln,{theme:l,imageSrc:i,videoUrl:w?o:u,videoId:w?h:s}),(E||_)&&e.createElement("div",{className:"video-embed__caption-wrapper"},E&&e.createElement("p",{className:"video-embed__caption"},E),_&&e.createElement("p",{className:"video-embed__credit"},_)),(h||u)&&(w?e.createElement("button",{className:"video-embed__audio-described-button",onClick:function(){return q(!1)}},"Non-audio described version"):e.createElement("button",{className:"video-embed__audio-described-button",onClick:function(){return q(!0)}},"Audio described version")),v&&e.createElement("div",{className:"video-embed__transcript"},e.createElement(M,{titleTag:"h3",theme:l,title:"Transcript",text:v,inverse:r})))))}function rn(c){var a,t=c.theme,l=void 0===t?"uobmain":t,n=c.inverse,r=void 0===n||n,i=c.fullWidth,o=void 0!==i&&i,s=c.heading,m=c.description,h=c.cards,u=c.singleLink,v=c.titleTag,f=void 0===v?"h2":v,g=c.cardTitleTag,E=void 0===g?"h3":g,_=xe("768px"),b=_&&h.length>1||!_&&h.length>2,w=p(((a={})["research-story-carousel__grid"]=!0,a["research-story-carousel__grid--single"]=1===h.length,a["research-story-carousel__grid--two-cards"]=2===h.length,a["research-story-carousel__grid--three-plus-cards"]=h.length>3,a));return e.createElement("section",{className:p("research-story-carousel",l&&"theme-".concat(l),r&&"theme-".concat(l,"--inverse"),o&&"research-story-carousel--full-width")},e.createElement("div",{className:"research-story-carousel__container"},(s||m||u)&&e.createElement(x,{theme:l,inverse:!0,htmlTag:f,title:s,description:m,linkProps:u,fullWidth:!0}),e.createElement("div",{className:"research-story-carousel__cards"},!b&&e.createElement("ul",{className:w},h.map(function(c,a){return e.createElement("li",{key:a},e.createElement(Ye,d({},c)))})),b&&e.createElement(ac,{theme:l,inverse:r,type:"research-story",cards:h,cardTitleTag:E}))))}function on(c){var i=c.text,o=c.theme,s=void 0===o?"uobmain":o,m=c.inverse,h=c.fullWidth,d=void 0!==h&&h,u=c.removeBottomPadding,v=void 0!==u&&u,f=c.tableCategory,g=void 0===f?Ql.NotSpecified:f,E=l(null),_=a(!1),b=_[0],w=_[1],q=a(!0),y=q[0],M=q[1],N=a(!1),C=N[0],k=N[1],x=r(),T=function(){var e=E.current;e&&(w(e.scrollLeft>0),M(e.scrollLeft<e.scrollWidth-e.clientWidth))},L=n(function(){var e=E.current;if(e){var c=e.scrollWidth>e.clientWidth;k(c),T()}},[]),z=function(e){var c=E.current;if(c){var a="left"===e?c.scrollLeft-200:c.scrollLeft+200;c.scrollTo({left:a,behavior:"smooth"})}};return t(function(){L();var e=E.current;e&&e.addEventListener("scroll",T);var c=function(){return L()};return window.addEventListener("resize",c),function(){e&&e.removeEventListener("scroll",T),window.removeEventListener("resize",c)}},[L]),e.createElement("div",{className:p("scrollable-table",d&&"scrollable-table--full-width",s&&"theme-".concat(s),m&&"theme-".concat(s,"--inverse"),v&&"scrollable-table--no-bottom-padding")},e.createElement("div",{className:"scrollable-table__container"},e.createElement("span",null,C&&e.createElement("div",{className:"scrollable-table__scroll-button-wrapper"},e.createElement("p",null,"Scroll buttons"),e.createElement(Oe,{key:"iconButtonLeft",theme:s,icon:"arrow-left",onClick:function(){return z("left")},title:"Scroll left",ariaControls:x,disabled:!b,inverse:m}),e.createElement(Oe,{key:"iconButtonRight",theme:s,icon:"arrow-right",onClick:function(){return z("right")},title:"Scroll right",ariaControls:x,disabled:!y,inverse:m})),e.createElement("div",{className:p("scrollable-table__table-wrapper","scrollable-table__".concat(g),m&&"scrollable-table__".concat(g,"--inverse")),ref:E,id:x,tabIndex:0},e.createElement("span",{dangerouslySetInnerHTML:{__html:i}})))))}function sn(c){var t=c.theme,l=c.heading,n=c.inverse,r=c.description,i=c.buttonLabel,o=c.buttonModifier,s=c.modalChildren,m=c.htmlTag,h=void 0===m?"h3":m,d=a(!1),u=d[0],v=d[1],f=function(){v(!1),document.body.classList.remove("lock-scroll")};return e.createElement("div",{className:p("modal-cta",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement(N,{htmlTag:h,classNames:"modal-cta__heading"},l),r&&e.createElement("p",{className:"modal-cta__description"},r),e.createElement("div",{className:p("modal-cta__button",o&&"theme-".concat(t,"--buttonModifier"))},e.createElement(q,{inverse:!n,label:i,onClick:function(){u?f():(v(!0),document.body.classList.add("lock-scroll"))},theme:t,buttonModifier:o})),u&&e.createElement(Be,{centred:!0,theme:t,closeModal:f,isOpen:u},e.createElement(sc,{className:"modal-cta__embed-wrapper"},s)))}function mn(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.inverse,n=void 0===l||l,r=c.cards,i=Array.isArray(r)?r:[r];return e.createElement("div",{className:p("module-card-group",t&&"theme-".concat(t),n&&"theme-".concat(t,"--inverse"))},e.createElement("div",{className:"module-card-group__container"},e.createElement("div",{className:"module-card-group__grid"},i.map(function(c,a){return e.createElement(w,d({key:a},c,{theme:t}))}))))}function hn(c){var a=c.theme,t=c.embedChildren,l=c.googleMapLink,n=c.address,r=c.services,i=c.link,o=c.titleTag,s=void 0===o?"h2":o;return e.createElement("section",{className:p("location-section",a&&"theme-".concat(a),(!r||r.length<1)&&"location-section--no-services")},e.createElement("div",{className:"location-section__container"},e.createElement(N,{htmlTag:s,classNames:p("location-section__title","h3"===s&&"location-section__title--h3")},"Location"),e.createElement("div",{className:"location-section__grid-wrapper"},e.createElement("div",{className:"location-section__embed"},e.createElement(sc,null,t)),e.createElement("div",{className:"location-section__address-wrapper"},e.createElement("div",{className:"location-section__address"},e.createElement(Ic,{theme:a,title:"Address",iconType:"slim-location",value:n.map(function(e){return"<span>".concat(e,"</span>")}).join("")})),i&&(null==i?void 0:i.title)&&(null==i?void 0:i.url)&&e.createElement("div",{className:"location-section__link-wrapper"},e.createElement(y,d({},i,{inverse:!0}))),l?e.createElement("div",{className:"location-section__button"},e.createElement(q,{label:"View on Google Maps",theme:a,url:l})):null),(null==r?void 0:r.length)?e.createElement("div",{className:"location-section__services"},null==r?void 0:r.map(function(c,t){return e.createElement(Ic,d({},c,{theme:a,key:t}))})):null)))}function dn(c){var a=c.theme,t=c.studentName,l=c.studentStatus,n=c.courseName,r=c.courseDetails,i=c.studyLevel,o=c.titleTag,s=void 0===o?"h2":o,m=c.homeCountry,h=c.studentIntro,u=c.image,v=c.inverse;return e.createElement("div",{className:p("heroProfile",a&&"theme-".concat(a),v&&"theme-".concat(a,"--inverse")),id:"hero"},e.createElement("div",{className:"heroProfile__container"},e.createElement("div",{className:"heroProfile__details"},t&&e.createElement(s,{className:"heroProfile__title"},t),l&&e.createElement("p",{className:"heroProfile__status"},l),n&&e.createElement("p",{className:"heroProfile__courseName"},n),(i||m||r&&r.length>0)&&e.createElement("ul",{className:"heroProfile__studentDetails"},r&&r.length>0&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"mortar-board",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__courseIconText"},e.createElement("span",null,1===r.length?"Course":"Courses",":"),e.createElement("div",{className:"heroProfile__courseDetails"},r.map(function(c,t){return e.createElement(C,{theme:a,key:t,text:c,inverse:v})}))))),i&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"scroll",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__iconText"},e.createElement("span",null,"Study level:"),e.createElement("span",null,i)))),m&&e.createElement("li",null,e.createElement("div",{className:"heroProfile__iconContainer"},e.createElement(je,{icon:"flag",theme:a,backgroundColor:"pale"}),e.createElement("div",{className:"heroProfile__iconText"},e.createElement("span",null,"Home country:"),e.createElement("span",null,m))))),h&&e.createElement(C,{theme:a,text:h,inverse:v})),e.createElement("div",{className:"heroProfile__image-wrapper"},u&&e.createElement(L,d({},u,{altText:null==u?void 0:u.alt,fetchPriority:u.fetchPriority})))))}function un(c){var a=c.theme,t=void 0===a?"uobmain":a,l=c.firstColumn,n=c.secondColumn;return e.createElement("div",{className:p("two-column-wrapper",t&&"theme-".concat(t))},e.createElement("div",{className:"two-column-wrapper__grid-container"},e.createElement("div",{className:p("two-column-wrapper__first-column",!n&&"two-column-wrapper__first-column-centred")},l),n&&e.createElement("div",{className:"two-column-wrapper__second-column"},n)))}function vn(c){var a,t,l=c.theme,n=void 0===l?"uobmain":l,r=c.inverse,i=c.logos,o=null!==(t=null==i?void 0:i.length)&&void 0!==t?t:0,s=i&&i.length%2!=0;return e.createElement("div",{className:p("logo-wall",n&&"theme-".concat(n),r&&"theme-".concat(n,"--inverse"))},e.createElement("div",null,e.createElement("ul",{className:p("logo-wall__container",s&&"logo-wall__container--odd"),style:(a={},a["--logo-wall-cols"]=String(o),a)},i&&i.map(function(c,a){var t;return e.createElement("li",{key:"li-".concat(a)},e.createElement(Ge,d({key:"".concat((null===(t=c.image)||void 0===t?void 0:t.title)||"imageTitle","-").concat(a),theme:n,inverse:r},c)))}))))}h(),h(),h(),h(),h(),h(),function(e){e.NotSpecified="NotSpecified",e.ColumnAndRowHeadings="ColumnAndRowHeadings",e.ColumnHeadingsOnly="ColumnHeadingsOnly"}(Ql||(Ql={})),h(),h(),h(),h(),h(),h();export{T as Accordion,z as AcreditationPromotion,V as AlertBanner,S as AnchorTarget,O as Breadcrumbs,oc as CTAComponent,lc as CardImageAndText,tc as CardProfile,ec as CardPromoProfile,$e as CardPromoSignpost,Ue as CardStaff,ac as Carousel,nc as CentreWrapper,rc as ClearingBanner,ic as CourseDeliveryPills,sc as EmbedWrapper,hc as FactBoxes,dc as FeaturedContent,Lc as FeaturedSignpost,Hc as FeaturedVideo,Vc as FiveArticlesGrid,Bc as Footer,Wc as GeneralSearchFilter,$c as GenericDetailSection,Nt as Header,x as Heading,Ht as Hero,Pt as HeroArticle,ll as HeroCarousel,It as HeroCourses,dn as HeroProfile,nl as ImageBlock,rl as ImageCarousel,ol as InPageNavigation,sl as IntroText,hl as LeadNewsArticles,yl as ListTable,dl as ListingFilterWrapper,wl as ListingResults,ql as ListingResultsCount,hn as LocationSection,Dt as LocationSelector,vn as LogoWall,Ml as MainWrapper,sn as ModalCTA,mn as ModuleCardGroup,Nl as NewsArticlesPromoBlock,kl as Pagination,xl as PromoBlock,Tl as PromoBlockGrid,Ll as QuoteBlock,zl as RelatedCourses,rn as ResearchStoryCarousel,E as RichText,Hl as ScholarshipCarousel,on as ScrollableTable,zt as SearchCourses,Sl as SidebarWrapper,Pl as SignPost,Ol as SingleButton,Zl as SkipToContent,Vl as StaffListingCarousel,cn as StandardListingFilter,Al as TabsBlock,$l as TextWithBackground,jl as TopicSelector,un as TwoColumnWrapper,an as VideoCardComponent,nn as VideoEmbed};
|