1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,409600,(e,t,a)=>{var r,n;r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t.exports=n={rotl:function(e,t){return e<<t|e>>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 0xff00ff&n.rotl(e,8)|0xff00ff00&n.rotl(e,24);for(var t=0;t<e.length;t++)e[t]=n.endian(e[t]);return e},randomBytes:function(e){for(var t=[];e>0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],a=0,r=0;a<e.length;a++,r+=8)t[r>>>5]|=e[a]<<24-r%32;return t},wordsToBytes:function(e){for(var t=[],a=0;a<32*e.length;a+=8)t.push(e[a>>>5]>>>24-a%32&255);return t},bytesToHex:function(e){for(var t=[],a=0;a<e.length;a++)t.push((e[a]>>>4).toString(16)),t.push((15&e[a]).toString(16));return t.join("")},hexToBytes:function(e){for(var t=[],a=0;a<e.length;a+=2)t.push(parseInt(e.substr(a,2),16));return t},bytesToBase64:function(e){for(var t=[],a=0;a<e.length;a+=3)for(var n=e[a]<<16|e[a+1]<<8|e[a+2],i=0;i<4;i++)8*a+6*i<=8*e.length?t.push(r.charAt(n>>>6*(3-i)&63)):t.push("=");return t.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/ig,"");for(var t=[],a=0,n=0;a<e.length;n=++a%4)0!=n&&t.push((r.indexOf(e.charAt(a-1))&Math.pow(2,-2*n+8)-1)<<2*n|r.indexOf(e.charAt(a))>>>6-2*n);return t}}},873326,(e,t,a)=>{var r={utf8:{stringToBytes:function(e){return r.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(r.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],a=0;a<e.length;a++)t.push(255&e.charCodeAt(a));return t},bytesToString:function(e){for(var t=[],a=0;a<e.length;a++)t.push(String.fromCharCode(e[a]));return t.join("")}}};t.exports=r},894779,(e,t,a)=>{function r(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}t.exports=function(e){var t;return null!=e&&(r(e)||"function"==typeof(t=e).readFloatLE&&"function"==typeof t.slice&&r(t.slice(0,0))||!!e._isBuffer)}},560439,(e,t,a)=>{var r,n,i,s,l;r=e.r(409600),n=e.r(873326).utf8,i=e.r(894779),s=e.r(873326).bin,(l=function(e,t){e.constructor==String?e=t&&"binary"===t.encoding?s.stringToBytes(e):n.stringToBytes(e):i(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var a=r.bytesToWords(e),o=8*e.length,d=0x67452301,c=-0x10325477,u=-0x67452302,m=0x10325476,f=0;f<a.length;f++)a[f]=(a[f]<<8|a[f]>>>24)&0xff00ff|(a[f]<<24|a[f]>>>8)&0xff00ff00;a[o>>>5]|=128<<o%32,a[(o+64>>>9<<4)+14]=o;for(var h=l._ff,p=l._gg,g=l._hh,x=l._ii,f=0;f<a.length;f+=16){var y=d,w=c,b=u,v=m;d=h(d,c,u,m,a[f+0],7,-0x28955b88),m=h(m,d,c,u,a[f+1],12,-0x173848aa),u=h(u,m,d,c,a[f+2],17,0x242070db),c=h(c,u,m,d,a[f+3],22,-0x3e423112),d=h(d,c,u,m,a[f+4],7,-0xa83f051),m=h(m,d,c,u,a[f+5],12,0x4787c62a),u=h(u,m,d,c,a[f+6],17,-0x57cfb9ed),c=h(c,u,m,d,a[f+7],22,-0x2b96aff),d=h(d,c,u,m,a[f+8],7,0x698098d8),m=h(m,d,c,u,a[f+9],12,-0x74bb0851),u=h(u,m,d,c,a[f+10],17,-42063),c=h(c,u,m,d,a[f+11],22,-0x76a32842),d=h(d,c,u,m,a[f+12],7,0x6b901122),m=h(m,d,c,u,a[f+13],12,-0x2678e6d),u=h(u,m,d,c,a[f+14],17,-0x5986bc72),c=h(c,u,m,d,a[f+15],22,0x49b40821),d=p(d,c,u,m,a[f+1],5,-0x9e1da9e),m=p(m,d,c,u,a[f+6],9,-0x3fbf4cc0),u=p(u,m,d,c,a[f+11],14,0x265e5a51),c=p(c,u,m,d,a[f+0],20,-0x16493856),d=p(d,c,u,m,a[f+5],5,-0x29d0efa3),m=p(m,d,c,u,a[f+10],9,0x2441453),u=p(u,m,d,c,a[f+15],14,-0x275e197f),c=p(c,u,m,d,a[f+4],20,-0x182c0438),d=p(d,c,u,m,a[f+9],5,0x21e1cde6),m=p(m,d,c,u,a[f+14],9,-0x3cc8f82a),u=p(u,m,d,c,a[f+3],14,-0xb2af279),c=p(c,u,m,d,a[f+8],20,0x455a14ed),d=p(d,c,u,m,a[f+13],5,-0x561c16fb),m=p(m,d,c,u,a[f+2],9,-0x3105c08),u=p(u,m,d,c,a[f+7],14,0x676f02d9),c=p(c,u,m,d,a[f+12],20,-0x72d5b376),d=g(d,c,u,m,a[f+5],4,-378558),m=g(m,d,c,u,a[f+8],11,-0x788e097f),u=g(u,m,d,c,a[f+11],16,0x6d9d6122),c=g(c,u,m,d,a[f+14],23,-0x21ac7f4),d=g(d,c,u,m,a[f+1],4,-0x5b4115bc),m=g(m,d,c,u,a[f+4],11,0x4bdecfa9),u=g(u,m,d,c,a[f+7],16,-0x944b4a0),c=g(c,u,m,d,a[f+10],23,-0x41404390),d=g(d,c,u,m,a[f+13],4,0x289b7ec6),m=g(m,d,c,u,a[f+0],11,-0x155ed806),u=g(u,m,d,c,a[f+3],16,-0x2b10cf7b),c=g(c,u,m,d,a[f+6],23,0x4881d05
1),d=g(d,c,u,m,a[f+9],4,-0x262b2fc7),m=g(m,d,c,u,a[f+12],11,-0x1924661b),u=g(u,m,d,c,a[f+15],16,0x1fa27cf8),c=g(c,u,m,d,a[f+2],23,-0x3b53a99b),d=x(d,c,u,m,a[f+0],6,-0xbd6ddbc),m=x(m,d,c,u,a[f+7],10,0x432aff97),u=x(u,m,d,c,a[f+14],15,-0x546bdc59),c=x(c,u,m,d,a[f+5],21,-0x36c5fc7),d=x(d,c,u,m,a[f+12],6,0x655b59c3),m=x(m,d,c,u,a[f+3],10,-0x70f3336e),u=x(u,m,d,c,a[f+10],15,-1051523),c=x(c,u,m,d,a[f+1],21,-0x7a7ba22f),d=x(d,c,u,m,a[f+8],6,0x6fa87e4f),m=x(m,d,c,u,a[f+15],10,-0x1d31920),u=x(u,m,d,c,a[f+6],15,-0x5cfebcec),c=x(c,u,m,d,a[f+13],21,0x4e0811a1),d=x(d,c,u,m,a[f+4],6,-0x8ac817e),m=x(m,d,c,u,a[f+11],10,-0x42c50dcb),u=x(u,m,d,c,a[f+2],15,0x2ad7d2bb),c=x(c,u,m,d,a[f+9],21,-0x14792c6f),d=d+y>>>0,c=c+w>>>0,u=u+b>>>0,m=m+v>>>0}return r.endian([d,c,u,m])})._ff=function(e,t,a,r,n,i,s){var l=e+(t&a|~t&r)+(n>>>0)+s;return(l<<i|l>>>32-i)+t},l._gg=function(e,t,a,r,n,i,s){var l=e+(t&r|a&~r)+(n>>>0)+s;return(l<<i|l>>>32-i)+t},l._hh=function(e,t,a,r,n,i,s){var l=e+(t^a^r)+(n>>>0)+s;return(l<<i|l>>>32-i)+t},l._ii=function(e,t,a,r,n,i,s){var l=e+(a^(t|~r))+(n>>>0)+s;return(l<<i|l>>>32-i)+t},l._blocksize=16,l._digestsize=16,t.exports=function(e,t){if(null==e)throw Error("Illegal argument "+e);var a=r.wordsToBytes(l(e,t));return t&&t.asBytes?a:t&&t.asString?s.bytesToString(a):r.bytesToHex(a)}},722333,65614,e=>{"use strict";var t=e.i(391398),a=e.i(191788),r=e.i(830746),n=e.i(272043);e.i(855242);var i=e.i(185072),s=e.i(802488),l=e.i(830498);e.i(406059);var o=e.i(764811);e.i(305735);var d=e.i(364597);e.i(230901);var c=e.i(512370);e.i(245714);var u=e.i(899641);let m=({audioPlayer:e})=>{let[r,n]=(0,a.useState)(1);return(0,t.jsx)("div",{className:"tw-ml-auto",children:(0,t.jsxs)(c.default,{className:"-tw-mr-wdsSpacing050 tw-p-wdsSpacing050 tw-text-wdsF-3",onClick:()=>{let t,a;(a=(t=[1,1.5,2,.5]).indexOf(r)+1)>t.length-1?(n(t[0]),e.playbackRate=t[0]):(n(t[a]),e.playbackRate=t[a])},variant:"unstyled",children:[(0,t.jsx)(u.default,{children:"Playback speed:"}),r,(0,t.jsx)("span",{"aria-hidden":"true",children:"x"})]})})},f=e=>{let t=Math.floor(e/60),a=Math.floor(e%60),r=e=>e<10?`0${e}`:`${e}`;return`${r(t)}:${r(a)}`},h=(0,a.forwardRef)(({currentTime:e,duration:a,onChange:r,title:n},i)=>{let s=n.trim().toLowerCase().slice(0,15).replaceAll(" ","-");return(0,t.jsx)("div",{className:"c-scrubber__container",children:(0,t.jsxs)("div",{className:"c-scrubber__range",children:[(0,t.jsx)("label",{className:"tw-sr-only",htmlFor:`scrubber-${s}`,children:`Audio time scrubber ${f(e)} / ${f(a)}`}),(0,t.jsx)("input",{"aria-valuetext":`Elapsed time: ${f(e)}`,className:"c-scrubber__progress-bar",defaultValue:"0",id:`scrubber-${s}`,min:0,onChange:r,ref:i,step:"any",type:"range"})]})})});h.displayName="Scrubber";let p=({buttonClassName:e,className:a,iconPause:r="iconActionPause",iconPlay:i="iconActionPlay",id:s,isPlaying:l,onClick:o,textPause:d="Pause",textPlay:u="Play"})=>{let m={container:(0,n.default)({[a]:a}),button:(0,n.default)("tw-rounded-full tw-h-[2.75rem] tw-w-[2.75rem]",{[e]:e})};return(0,t.jsx)("div",{className:m.container,children:l?(0,t.jsx)(c.default,{className:m.button,"data-gtm":s,icon:r,iconClassName:"tw-mx-0",onClick:o,variant:"primary",textClassName:"tw-sr-only",children:d}):(0,t.jsx)(c.default,{className:m.button,"data-gtm":s,icon:i,iconClassName:"tw-mx-0",onClick:o,variant:"primary",textClassName:"tw-sr-only",children:u})})};e.i(605253);var g=e.i(432226);let x=({audioFile:e,title:r})=>{let[n,i]=(0,a.useState)(0),[s,l]=(0,a.useState)(0),[c,x]=(0,a.useState)(!1),[y,w]=(0,a.useState)(!1),b=(0,a.useRef)(null),v=(0,a.useRef)(null),j=(0,a.useRef)(null);(0,a.useEffect)(()=>{let e=Math.floor(v.current.duration);l(e),j.current.max=e},[v.current?.loadedmetadata,v.current?.readyState]),(0,a.useEffect)(()=>()=>{cancelAnimationFrame(b.current)},[]);let N=()=>{j.current.style.setProperty("--seek-before-width",`${j.current.value/s*100}%`),i(j.current.value)},T=()=>{j.current.value=v.current.currentTime,N(),b.current=requestAnimationFrame(T)};return(0,t.jsxs)("div",{className:"tw-border-b tw-border-wdsNeutral-20 tw-bg-wdsNeutral-10 tw-p-wdsSpacing200 tw-text-black",children:[(0,t.jsx)("div",{className:"tw-mb-wdsSpacing050",children:(0,t.jsx)(d.default,{labelClassName:"tw-text-wdsF-3 tw-text-black",label:"Listen to this article"})}),(0,t.jsxs)("figure",{children:[(0,t.jsx)("figcaption",{className:"tw-sr-only tw-mb-wdsSpacing200 tw-text-wdsF-1 tw-font-medium tw-tracking-spacious md:tw-not-sr-only",children:r}),(0,t.jsxs)("div",{className:"tw-flex md:tw-mt-wdsSpacing200",children:[(0,t.jsx)(p,{className:"tw-mr-wdsSpacing200",buttonClassName:"tw-bg-wdsIndigo-30 focus:tw-bg-wdsIndigo-30 hover:tw-bg-wdsIndigo-30",id:"audio-player-control
1s",isPlaying:c,onClick:()=>{x(!c),c?(v.current.pause(),cancelAnimationFrame(b.current)):(v.current.play(),b.current=requestAnimationFrame(T))}}),(0,t.jsxs)("div",{className:"tw-flex-1",children:[(0,t.jsx)(h,{currentTime:n,duration:s,title:r,onChange:()=>{v.current.currentTime=j.current.value,N()},ref:j}),(0,t.jsxs)("div",{className:"tw-flex tw-items-center",children:[(0,t.jsxs)("div",{className:"tw-text-wdsF-3 tw-text-wdsNeutral-60",children:[(0,t.jsxs)("span",{children:[(0,t.jsx)(u.default,{children:"Elapsed time:"}),f(n)]}),(0,t.jsx)(g.default,{}),!Number.isNaN(s)&&(0,t.jsxs)("span",{children:[(0,t.jsx)(u.default,{children:"Total time:"}),f(s)]})]}),(0,t.jsx)(m,{audioPlayer:v.current})]})]}),(0,t.jsx)(p,{className:"tw-relative -tw-top-wdsSpacing050 tw-ml-wdsSpacing200",buttonClassName:"tw-bg-transparent focus:tw-bg-transparent hover:tw-bg-transparent",iconPause:"iconActionMute",iconPlay:"iconActionVolume",id:"audio-player-mute-toggle",isPlaying:y,onClick:()=>{w(!y),v.current.muted=!y},textPause:"Un-mute",textPlay:"Mute"})]}),(0,t.jsx)("audio",{onLoadedMetadata:()=>{l(Math.floor(v.current.duration))},onPlay:()=>x(!0),onPause:()=>x(!1),onTimeUpdate:()=>{i(Math.floor(v.current.currentTime))},preload:"metadata",ref:v,src:e,children:(0,t.jsxs)("p",{children:["Your browser does not support the ",(0,t.jsx)("code",{children:"audio"})," element.",(0,t.jsx)(o.default,{className:"o-animated-link",href:e,children:"Download the audio"}),"instead."]})})]})]})};e.i(194769);var y=e.i(688152),w=e.i(126019);let b=({className:e,imageHeight:a=80,imageSrc:r,imageWidth:i=80,jobTitle:s,links:l,name:d,organisation:c,profileLink:u,titleAs:m})=>{let f=m||"h2",h=(0,n.default)("c-contributor",{[e]:e});return(0,t.jsxs)("div",{className:h,itemScope:!0,itemType:"http://schema.org/Person",children:[r&&(0,t.jsx)("figure",{className:"c-contributor__image",children:(0,t.jsx)(w.default,{alt:"",className:"o-image o-image--responsive",height:a,itemProp:"image",priority:!0,sizes:"(min-width: 768px) 80px, 60px",src:r,width:i})}),(0,t.jsxs)("div",{className:"c-contributor__body",children:[u?.url?(0,t.jsx)(f,{className:"c-contributor__name",children:(0,t.jsx)(o.default,{className:"o-animated-link",href:u.url,itemProp:"name",children:d})}):(0,t.jsx)(f,{className:"c-contributor__name",itemProp:"name",children:d}),(s||c)&&(0,t.jsxs)("p",{className:"c-contributor__byline",children:[s&&(0,t.jsx)("span",{className:"sm:tw-block",itemProp:"jobTitle",children:s}),s&&c&&(0,t.jsx)("span",{className:"sm:tw-hidden",children:", "}),c&&(0,t.jsx)("span",{className:"c-contributor__organisation sm:tw-block",itemProp:"memberOf",children:c})]}),l?.length>0&&(0,t.jsx)("ul",{className:"c-contributor__links tw-list-none",children:l.map(e=>(0,t.jsx)("li",{className:"c-contributor__link-item",children:(0,t.jsx)(o.default,{"aria-label":`${e.title} ${d}`,className:"o-animated-link",href:e.url,children:e.title})},`${d}-link-${e.url}`))})]})]})};e.i(876546);var v=e.i(911328);e.i(988987);var j=e.i(529839),N=e.i(558021),T=e.i(426778),S=e.i(203828),k=e.i(218183);e.i(122334);var E=e.i(842905);e.i(500663);var _=e.i(472648);e.i(853400);var C=e.i(388555);e.i(324098);var A=e.i(967609);let R={funding:"/who-we-are/contact-us/funding-enquiry",grants:"/who-we-are/contact-us/online-grant-enquiry",general:"/who-we-are/contact-us/general-enquiry"};var F=e.i(859896),L=e.i(837393),O=e.i(258641);let P=()=>{let[e,t]=(0,a.useState)(null),[r,n]=(0,a.useState)(null);return(0,a.useEffect)(()=>{document.referrer&&t(new URL(document.referrer).pathname)},[]),(0,a.useEffect)(()=>{e&&(async()=>{try{let{NEXT_PUBLIC_API_DOMAIN:t}=(0,O.getPublicConfig)(),a=await (0,L.default)(`${t}/router/translate-path?path=${encodeURI(e)}`);if("funding_scheme"!==a.entity.bundle)throw Error();n(a.label)}catch{n(null)}})()},[e]),r};var D=e.i(106317),q=e.i(535947);e.i(512367);var I=e.i(452752);e.i(160305);var G=e.i(8351);e.i(521347);var B=e.i(581091);e.i(399755);var U=e.i(585322);e.i(71898);var $=e.i(85544);e.i(534733);var H=e.i(294243);let M=({defaultValues:e={},emailHint:r,isSubmitting:n,isSuccessful:i,messageHint:s,onSubmit:l,selectTopicOptions:o,submissionErrors:d,formType:u})=>{let[m,f]=(0,a.useState)(""),h=(0,a.useMemo)(()=>(0,T.object)({captchaTimestamp:(0,T.string)().required("The answer you entered for the CAPTCHA was not correct. Please try again"),"g-recaptcha-response":(0,T.string)().required("The response you entered for the CAPTCHA was not correct. Please try again"),topic:(0,T.string)().required("Please select a topic."),description:(0,T.string)().trim().required("Please write a message"),grantReferenceNumber:(0,T.string)().trim(),name:(0,T.string)().trim().required("Please write your name"),email:(0,T.string)().email("Enter an email address in the correct format, like [email protected]").required("Please provide a valid email address"),phone:(0,T.string)().matches(/^[0-9/(),+\-\s]*$/,"Please provide a valid phone number.")}),[]),p=(0,k.useYupValidationResolver)({schema:h}),{NEXT_PUBLIC_GOOGLE_RECAPTCHA_SITE_KEY:g}=(0,O.getBuildTimeConfig)(),{control:x,handleSubmit:y,register:w,setValue:b,formState:{errors:v}}=(0,N.useForm)({defaultValues:e,mode:"onTouched",resolver:p});return(0,t.jsxs)("form",{noValidate:!0,onSubmit:y(l),className:"c-form",children:[(0,t.jsx)(N.Controller,{c
1ontrol:x,name:"captchaTimestamp",defaultValue:"",render:({field:{onBlur:e,onChange:a}})=>(0,t.jsx)(H.default,{name:"captchaTimestamp",id:"captchaTimestamp",type:"hidden",size:20,maxLength:20,spellCheck:"false",value:m,onChange:a,onBlur:e})}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"topic",text:"Topic"}),(0,t.jsx)(B.default,{describedBy:v.topic&&"topicErrors",id:"topic",isInvalid:!!v.topic,isRequired:!0,options:o,...w("topic")}),v.topic&&(0,t.jsx)(_.default,{errors:v.topic.types,id:"topicErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"description",text:"Your message"}),s&&(0,t.jsx)(G.default,{id:"messageHint",children:(0,t.jsx)("p",{children:s})}),(0,t.jsx)($.default,{describedBy:`${v.description?"descriptionErrors ":""} messageHint`,name:"description",id:"description",isRequired:!0,...w("description")}),v.description&&(0,t.jsx)(_.default,{errors:v.description.types,id:"descriptionErrors"})]}),"fundingSupport"===u&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"grantReferenceNumber",text:"Grant reference number (optional)"}),(0,t.jsx)(H.default,{name:"grantReferenceNumber",id:"grantReferenceNumber",type:"text",size:20,maxLength:20,spellCheck:"false",...w("grantReferenceNumber")}),v.grantReferenceNumber&&(0,t.jsx)(_.default,{errors:v.grantReferenceNumber.types,id:"grantReferenceNumberErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"name",text:"Your name"}),(0,t.jsx)(H.default,{id:"name",name:"name",type:"text",maxLength:80,spellCheck:"false",...w("name")}),v.name&&(0,t.jsx)(_.default,{errors:v.name.types,id:"nameErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"email",text:"Your email address "}),r&&(0,t.jsx)(G.default,{id:"emailHint",children:(0,t.jsx)("p",{children:r})}),(0,t.jsx)(H.default,{id:"email",name:"email",type:"text",maxLength:80,spellCheck:"false",...w("email")}),v.email&&(0,t.jsx)(_.default,{errors:v.email.types,id:"nameErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"phone",text:"Your phone number (optional)"}),(0,t.jsx)(H.default,{id:"phone",name:"phone",type:"text",maxLength:40,spellCheck:"false",...w("phone")}),v.phone&&(0,t.jsx)(_.default,{errors:v.phone.types,id:"phoneErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsxs)("p",{className:"tw-mb-static-md",children:["We respect your privacy and will only share personal data for purposes as described in our"," ",(0,t.jsx)(I.default,{href:"/who-we-are/privacy-and-terms",children:"terms and conditions"}),"."]}),(0,t.jsxs)("p",{children:["We use reCAPTCHA to block fraudulent activity. If this prevents you from sending your message successfully, we provide"," ",(0,t.jsx)(I.default,{href:"/who-we-are/problems-submitting-our-contact-form",children:"alternative contact methods"}),"."]})]}),(0,t.jsxs)(E.default,{className:"c-form-field--captcha",children:[g&&(0,t.jsx)(N.Controller,{control:x,defaultValue:"",name:"g-recaptcha-response",render:({field:{onBlur:e,onChange:a}})=>(0,t.jsx)(q.default,{onBlur:e,onChange:e=>{let t=new Date().getTime().toString();f(t),b("captchaTimestamp",t,{shouldValidate:!0}),a(e)},onExpired:()=>a(""),sitekey:g})}),v["g-recaptcha-response"]&&(0,t.jsx)(_.default,{errors:v["g-recaptcha-response"].types,id:"captchaErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{variant:"primary",type:"submit",children:n?"Submitting...":"Submit"})}),!i&&d?.length>0&&(0,t.jsx)(E.default,{children:(0,t.jsx)(_.default,{errors:d,id:"submissionErrors"})})]})};e.i(855448);var W=e.i(502665);e.i(441984);var Y=e.i(9041);e.i(216576);var K=e.i(288698);let z=({email:e,message:a,shouldShowMessage:r})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{role:"status",children:r&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Y.default,{title:"Thank you"}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"You'll get an email confirming that we've received your message."})]})}),r&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("p",{className:"tw-mb-wdsSpacing200",children:["We usually respond to queries by email within"," ",(0,t.jsx)("strong",{children:"3 working days"}),". If we're very busy, it can take up to ",(0,t.jsx)("strong",{children:"5 working days"}),"."]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"We prioritise queries about funding schemes with upcoming deadlines."}),(0,t.jsxs)("p",{className:"tw-mb-wdsSpacing300",children:["Meanwhile, all the basic
1information you need to apply for funding is on our"," ",(0,t.jsx)(o.default,{className:"o-animated-link tw-font-medium",href:"/research-funding/schemes",children:"scheme pages"}),"."]}),(0,t.jsxs)(W.default,{children:[(0,t.jsx)(K.default,{className:"tw-mb-wdsSpacingXs",title:"Your email address:",variant:"text-snippet",children:`<p>${e}</p>`}),(0,t.jsx)(K.default,{title:"Your message:",variant:"text-snippet",children:`<p>${a}</p>`})]})]})]});e.i(673734);var V=e.i(327630),X=e.i(536893);let Q=()=>{let[e,t]=(0,a.useState)(null),[r,n]=(0,a.useState)(null),[i,s]=(0,a.useState)(null),[l,o]=(0,a.useState)(null),[d,c]=(0,a.useState)(null),[u,m]=(0,a.useState)(!1),[f,h]=(0,a.useState)(!1),[p,g]=(0,a.useState)("");return(0,a.useEffect)(()=>{f&&(m(!1),g(""),(async()=>{try{let t=await (0,X.default)("/api/email/send",{body:JSON.stringify({content:d,subject:e,subType:r,to:i,type:l}),headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST"}),a=await t.json();if(200!==t.status||a.error)throw Error(a.error.message||"There was an error when attempting to send an email receipt, please try again. If this issue persists, and you have not received an email from us within 24 hours, please get in touch.");m(!0)}catch(e){g(e.message)}finally{h(!1)}})())},[f]),{hasSent:u,sendEmail:e=>{c(e.content),t(e.subject),s(e.to),o(e.type),n(e.subType),h(!0)},submissionEmailErrors:p}};e.i(536692);var J=e.i(191202),Z=e.i(562868),ee=e.i(933947);let et=(0,a.forwardRef)(({className:e,describedBy:a,id:r,isDisabled:i,isInvalid:s,isRequired:l,name:o,onBlur:d,onChange:c,pattern:u},m)=>{let f=(0,n.default)("c-date-input",{"c-date-input--is-invalid":s,[e]:e});return(0,t.jsx)("input",{"aria-describedby":a,"aria-invalid":s,"aria-required":l,className:f,disabled:i,id:r,name:o,onBlur:d,onChange:c,pattern:u,ref:m,type:"date"})});et.displayName="DateInput";let ea=({shouldShowMessage:e})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{role:"status",children:e&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Y.default,{title:"Thank you"}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Youâll get an automated email confirming that weâve received your form."})]})}),e&&(0,t.jsxs)("div",{className:"tw-mb-wdsSpacingXl",children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Weâll contact you within five working days to confirm the information youâve given us. If weâre very busy, it may take up to 10 working days."}),(0,t.jsxs)("p",{children:["If you have any questions, contact"," ",(0,t.jsx)(o.default,{className:"o-animated-link",href:"mailto:[email protected]",children:"[email protected]"}),"."]})]})]});var er=e.i(662603),er=er,en=e.i(661174);function ei(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}function es(e,t){var a="u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!a){if(Array.isArray(e)||(a=function(e){if(e){if("string"==typeof e)return ei(e,void 0);var t=({}).toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?ei(e,void 0):void 0}}(e))||t&&e&&"number"==typeof e.length){a&&(e=a);var r=0,n=function(){};return{s:n,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:n}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,l=!1;return{s:function(){a=a.call(e)},n:function(){var e=a.next();return s=e.done,e},e:function(e){l=!0,i=e},f:function(){try{s||null==a.return||a.return()}finally{if(l)throw i}}}}var el=e.i(67708),eo=e.i(785501),ed=e.i(623886),ec=e.i(337048),eu=e.i(736641),em=e.i(382202),ef=e.i(799306),eh=e.i(699213);function ep(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function eg(e,t){return(eg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function ex(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&eg(e,t)}
1function ey(e){return(ey=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function ew(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(ew=function(){return!!e})()}function eb(e){var t=ew();return function(){var a,r=ey(e);a=t?Reflect.construct(r,arguments,ey(this).constructor):r.apply(this,arguments);if(a&&("object"==(0,en.default)(a)||"function"==typeof a))return a;if(void 0!==a)throw TypeError("Derived constructors may only return object or undefined");return ep(this)}}function ev(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function ej(e){var t=function(e,t){if("object"!=(0,en.default)(e)||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var r=a.call(e,t||"default");if("object"!=(0,en.default)(r))return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==(0,en.default)(t)?t:t+""}function eN(e,t){for(var a=0;a<t.length;a++){var r=t[a];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ej(r.key),r)}}function eT(e,t,a){return t&&eN(e.prototype,t),a&&eN(e,a),Object.defineProperty(e,"prototype",{writable:!1}),e}function eS(e,t,a){return(t=ej(t))in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}var ek=function(){function e(){ev(this,e),eS(this,"priority",void 0),eS(this,"subPriority",0)}return eT(e,[{key:"validate",value:function(e,t){return!0}}]),e}(),eE=function(e){ex(a,e);var t=eb(a);function a(e,r,n,i,s){var l;return ev(this,a),(l=t.call(this)).value=e,l.validateValue=r,l.setValue=n,l.priority=i,s&&(l.subPriority=s),l}return eT(a,[{key:"validate",value:function(e,t){return this.validateValue(e,this.value,t)}},{key:"set",value:function(e,t,a){return this.setValue(e,t,this.value,a)}}]),a}(ek),e_=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",10),eS(ep(e),"subPriority",-1),e}return eT(a,[{key:"set",value:function(e,t){if(t.timestampIsSet)return e;var a=new Date(0);return a.setFullYear(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()),a.setHours(e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()),a}}]),a}(ek),eC=function(){function e(){ev(this,e),eS(this,"incompatibleTokens",void 0),eS(this,"priority",void 0),eS(this,"subPriority",void 0)}return eT(e,[{key:"run",value:function(e,t,a,r){var n=this.parse(e,t,a,r);return n?{setter:new eE(n.value,this.validate,this.set,this.priority,this.subPriority),rest:n.rest}:null}},{key:"validate",value:function(e,t,a){return!0}}]),e}(),eA=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",140),eS(ep(e),"incompatibleTokens",["R","u","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"G":case"GG":case"GGG":return a.era(e,{width:"abbreviated"})||a.era(e,{width:"narrow"});case"GGGGG":return a.era(e,{width:"narrow"});default:return a.era(e,{width:"wide"})||a.era(e,{width:"abbreviated"})||a.era(e,{width:"narrow"})}}},{key:"set",value:function(e,t,a){return t.era=a,e.setUTCFullYear(a,0,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),eR=e.i(926638),eF=/^(1[0-2]|0?\d)/,eL=/^(3[0-1]|[0-2]?\d)/,eO=/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,eP=/^(5[0-3]|[0-4]?\d)/,eD=/^(2[0-3]|[0-1]?\d)/,eq=/^(2[0-4]|[0-1]?\d)/,eI=/^(1[0-1]|0?\d)/,eG=/^(1[0-2]|0?\d)/,eB=/^[0-5]?\d/,eU=/^[0-5]?\d/,e$=/^\d/,eH=/^\d{1,2}/,eM=/^\d{1,3}/,eW=/^\d{1,4}/,eY=/^-?\d+/,eK=/^-?\d/,ez=/^-?\d{1,2}/,eV=/^-?\d{1,3}/,eX=/^-?\d{1,4}/,eQ=/^([+-])(\d{2})(\d{2})?|Z/,eJ=/^([+-])(\d{2})(\d{2})|Z/,eZ=/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,e0=/^([+-])(\d{2}):(\d{2})|Z/,e1=/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/;function e2(e,t){return e?{value:t(e.value),rest:e.rest}:e}function e3(e,t){var a=t.match(e);return a?{value:parseInt(a[0],10),rest:t.slice(a[0].length)}:null}function e5(e,t){var a=t.match(e);if(!a)return null;if("Z"===a[0])return{value:0,rest:t.slice(1)};var r="+"===a[1]?1:-1,n=a[2]?parseInt(a[2],10):0,i=a[3]?parseInt(a[3],10):0,s=a[5]?parseInt(a[5],10):0;return{value:r*(n*eR.millisecondsInHour+i*eR.millisecondsInMinute+s*eR.millisecondsInSecond),rest:t.slice(a[0].length)}}function e4(e,t){switch(e){case 1:return e3(e$,t);case 2:return e3(eH,t);case 3:return e3(eM,t);case 4:return e3(eW,t);default:return e3(RegExp("^\\d{1,"+e+"}"),t)}}function e6(e,t){switch(e){case 1:return e3(eK,t);case 2:return e3(ez,t);case 3:return e3(eV,t);case 4:return e3(eX,t);default:return e3(RegExp("^-?\\d{1,"+e+"}"),t)}}function e8(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;default:return 0}}function e7(e,t){var a,r=t>0,n=r?t:1-t;if(n<=50)a=e||100;else{var i=n+50;a=e+100*Math.floor(i/100)-100*(e>=i%100)}return r?a:1-a}function e9(e){return e%400==0||e%4==0&&e%100!=0}var te=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",130),eS(ep(e),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){var r=function(e){return{year:e,isTwoDigitYear:"yy"===t}};switch(t){case"y":return e2(e4(4,e),r);case"yo":return e2(a.ordinalNumber(e,{unit:"year"}),r);default:return e2(e4(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,a){var r=e.getUTCFullYear();if(a.isTwoDigitYear){var n=e7(a.year,r);return e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}var i="era"in t&&1!==t.era?1-a.year:a.year;return e.setUTCFullYear(i,0,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),tt=e.i(906621),ta=e.i(452975),tr=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",130),eS(ep(e),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){var r=function(e){return{year:e,isTwoDigitYear:"YY"===t}};switch(t){case"Y":return e2(e4(4,e),r);case"Yo":return e2(a.ordinalNumber(e,{unit:"year"}),r);default:return e2(e4(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,a,r){var n=(0,tt.default)(e,r);if(a.isTwoDigitYear){var i=e7(a.year,n);return e.setUTCFullYear(i,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,ta.default)(e,r)}var s="era"in t&&1!==t.era?1-a.year:a.year;return e.setUTCFullYear(s,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,ta.default)(e,r)}}]),a}(eC),tn=e.i(302592),ti=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",130),eS(ep(e),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t){return"R"===t?e6(4,e):e6(t.length,e)}},{key:"set",value:function(e,t,a){var r=new Date(0);return r.setUTCFullYear(a,0,4),r.setUTCHours(0,0,0,0),(0,tn.default)(r)}}]),a}(eC),ts=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",130),eS(ep(e),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t){return"u"===t?e6(4,e):e6(t.length,e)}},{key:"set",value:function(e,t,a){return e.setUTCFullYear(a,0,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),tl=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",120),eS(ep(e),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"Q":case"QQ":return e4(t.length,e);case"Qo":return a.ordinalNumber(e,{unit:"quarter"});case"QQQ":return a.quarter(e,{width:"abbreviated",context:"formatting"})||a.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(e,{width:"narrow",context:"formatting"});default:return a.quarter(e,{width:"wide",context:"formatting"})||a.quarter(e,{width:"abbreviated",context:"formatting"})||a.quarter(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,a){return e.setUTCMonth((a-1)*3,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),to=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",120),eS(ep(e),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"q":case"qq":return e4(t.length,e);case"qo":return a.ordinalNumber(e,{unit:"quarter"});case"qqq":return a.quarter(e,{width:"abbreviated",context:"standalone"})||a.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(e,{width:"narrow",context:"standalone"});default:return a.quarter(e,{width:"wide",context:"standalone"})||a.quarter(e,{width:"abbreviated",context:"standalone"})||a.quarter(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,a){return e.setUTCMonth((a-1)*3,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),td=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),eS(ep(e),"priority",110),e}return eT(a,[{key:"parse",value:function(e,t,a){var r=function(e){return e-1};switch(t){case"M":return e2(e3(eF,e),r);case"MM":return e2(e4(2,e),r);case"Mo":return e2(a.ordinalNumber(e,{unit:"month"}),r);case"MMM":return a.month(e,{width:"abbreviated",context:"formatting"})||a.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(e,{width:"narrow",context:"formatting"});default:return a.month(e,{width:"wide",context:"formatting"})||a.month(e,{width:"abbreviated",context:"formatting"})||a.month(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,a){return e.setUTCMonth(a,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),tc=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",110),eS(ep(e),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){var r=function(e){return e-1};switch(t){case"L":return e2(e3(eF,e),r);case"LL":return e2(e4(2,e),r);case"Lo":return e2(a.ordinalNumber(e,{unit:"month"}),r);case"LLL":return a.month(e,{width:"abbreviated",context:"standalone"})||a.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(e,{width:"narrow",context:"standalone"});default:return a.month(e,{width:"wide",context:"standalone"})||a.month(e,{width:"abbreviated",context:"standalone"})||a.month(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,a){return e.setUTCMonth(a,1),e.setUTCHours(0,0,0,0),e}}]),a}(eC),tu=e.i(51627),tm=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",100),eS(ep(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"w":return e3(eP,e);case"wo":return a.ordinalNumber(e,{unit:"week"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,a,r){return(0,ta.default)(function(e,t,a){(0,eh.default)(2,arguments);var r=(0,ed.default)(e),n=(0,ef.default)(t),i=(0,tu.default)(r,a)-n;return r.setUTCDate(r.getUTCDate()-7*i),r}(e,a,r),r)}}]),a}(eC),tf=e.i(799436),th=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",100),eS(ep(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"I":return e3(eP,e);case"Io":return a.ordinalNumber(e,{unit:"week"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,a){return(0,tn.default)(function(e,t){(0,eh.default)(2,arguments);var a=(0,ed.default)(e),r=(0,ef.default)(t),n=(0,tf.default)(a)-r;
1return a.setUTCDate(a.getUTCDate()-7*n),a}(e,a))}}]),a}(eC),tp=[31,28,31,30,31,30,31,31,30,31,30,31],tg=[31,29,31,30,31,30,31,31,30,31,30,31],tx=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"subPriority",1),eS(ep(e),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"d":return e3(eL,e);case"do":return a.ordinalNumber(e,{unit:"date"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){var a=e9(e.getUTCFullYear()),r=e.getUTCMonth();return a?t>=1&&t<=tg[r]:t>=1&&t<=tp[r]}},{key:"set",value:function(e,t,a){return e.setUTCDate(a),e.setUTCHours(0,0,0,0),e}}]),a}(eC),ty=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"subpriority",1),eS(ep(e),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"D":case"DD":return e3(eO,e);case"Do":return a.ordinalNumber(e,{unit:"date"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return e9(e.getUTCFullYear())?t>=1&&t<=366:t>=1&&t<=365}},{key:"set",value:function(e,t,a){return e.setUTCMonth(0,a),e.setUTCHours(0,0,0,0),e}}]),a}(eC),tw=e.i(871944);function tb(e,t,a){(0,eh.default)(2,arguments);var r,n,i,s,l,o,d,c,u=(0,tw.getDefaultOptions)(),m=(0,ef.default)(null!=(r=null!=(n=null!=(i=null!=(s=null==a?void 0:a.weekStartsOn)?s:null==a||null==(l=a.locale)||null==(o=l.options)?void 0:o.weekStartsOn)?i:u.weekStartsOn)?n:null==(d=u.locale)||null==(c=d.options)?void 0:c.weekStartsOn)?r:0);if(!(m>=0&&m<=6))throw RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=(0,ed.default)(e),h=(0,ef.default)(t),p=7*((h%7+7)%7<m)+h-f.getUTCDay();return f.setUTCDate(f.getUTCDate()+p),f}var tv=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"incompatibleTokens",["D","i","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"E":case"EE":case"EEE":return a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});default:return a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,a,r){return(e=tb(e,a,r)).setUTCHours(0,0,0,0),e}}]),a}(eC),tj=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a,r){var n=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"e":case"ee":return e2(e4(t.length,e),n);case"eo":return e2(a.ordinalNumber(e,{unit:"day"}),n);case"eee":return a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"eeeee":return a.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});default:return a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,a,r){return(e=tb(e,a,r)).setUTCHours(0,0,0,0),e}}]),a}(eC),tN=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a,r){var n=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"c":case"cc":return e2(e4(t.length,e),n);case"co":return e2(a.ordinalNumber(e,{unit:"day"}),n);case"ccc":return a.day(e,{width:"abbreviated",context:"standalone"})||a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"});case"ccccc":return a.day(e,{width:"narrow",context:"standalone"});case"cccccc":return a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"});default:return a.day(e,{width:"wide",context:"standalone"})||a.day(e,{width:"abbreviated",context:"standalone"})||a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,a,r){return(e=tb(e,a,r)).setUTCHours(0,0,0,0),e}}]),a}(eC),tT=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",90),eS(ep(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){var r=function(e){return 0===e?7:e};switch(t){case"i":case"ii":return e4(t.length,e);case"io":return a.ordinalNumber(e,{unit:"day"});case"iii":return e2(a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),r);case"iiiii":return e2(a.day(e,{width:"narrow",context:"formatting"}),r);case"iiiiii":return e2(a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),r);default:return e2(a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),r)}}},{key:"validate",value:function(e,t){return t>=1&&t<=7}},{key:"set",value:function(e,t,a){return(e=function(e,t){(0,eh.default)(2,arguments);var a=(0,ef.default)(t);a%7==0&&(a-=7);var r=(0,ed.default)(e),n=7*((a%7+7)%7<1)+a-r.getUTCDay();return r.setUTCDate(r.getUTCDate()+n),r}(e,a)).setUTCHours(0,0,0,0),e}}]),a}(eC),tS=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",80),eS(ep(e),"incompatibleTokens",["b","B","H","k","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"a":case"aa":case"aaa":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(e,{width:"narrow",context:"formatting"});default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,a){return e.setUTCHours(e8(a),0,0,0),e}}]),a}(eC),tk=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",80),eS(ep(e),"incompatibleTokens",["a","B","H","k","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"b":case"bb"
vendor: 7,092 bytes, line 1
1:case"bbb":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(e,{width:"narrow",context:"formatting"});default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,a){return e.setUTCHours(e8(a),0,0,0),e}}]),a}(eC),tE=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",80),eS(ep(e),"incompatibleTokens",["a","b","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"B":case"BB":case"BBB":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(e,{width:"narrow",context:"formatting"});default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,a){return e.setUTCHours(e8(a),0,0,0),e}}]),a}(eC),t_=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",70),eS(ep(e),"incompatibleTokens",["H","K","k","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"h":return e3(eG,e);case"ho":return a.ordinalNumber(e,{unit:"hour"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=12}},{key:"set",value:function(e,t,a){var r=e.getUTCHours()>=12;return r&&a<12?e.setUTCHours(a+12,0,0,0):r||12!==a?e.setUTCHours(a,0,0,0):e.setUTCHours(0,0,0,0),e}}]),a}(eC),tC=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",70),eS(ep(e),"incompatibleTokens",["a","b","h","K","k","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"H":return e3(eD,e);case"Ho":return a.ordinalNumber(e,{unit:"hour"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=23}},{key:"set",value:function(e,t,a){return e.setUTCHours(a,0,0,0),e}}]),a}(eC),tA=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",70),eS(ep(e),"incompatibleTokens",["h","H","k","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"K":return e3(eI,e);case"Ko":return a.ordinalNumber(e,{unit:"hour"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,a){return e.getUTCHours()>=12&&a<12?e.setUTCHours(a+12,0,0,0):e.setUTCHours(a,0,0,0),e}}]),a}(eC),tR=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",70),eS(ep(e),"incompatibleTokens",["a","b","h","H","K","t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"k":return e3(eq,e);case"ko":return a.ordinalNumber(e,{unit:"hour"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=24}},{key:"set",value:function(e,t,a){return e.setUTCHours(a<=24?a%24:a,0,0,0),e}}]),a}(eC),tF=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",60),eS(ep(e),"incompatibleTokens",["t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"m":return e3(eB,e);case"mo":return a.ordinalNumber(e,{unit:"minute"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,a){return e.setUTCMinutes(a,0,0),e}}]),a}(eC),tL=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",50),eS(ep(e),"incompatibleTokens",["t","T"]),e}return eT(a,[{key:"parse",value:function(e,t,a){switch(t){case"s":return e3(eU,e);case"so":return a.ordinalNumber(e,{unit:"second"});default:return e4(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,a){return e.setUTCSeconds(a,0),e}}]),a}(eC),tO=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",30),eS(ep(e),"incompatibleTokens",["t","T"]),e}return eT(a,[{key:"parse",value:function(e,t){return e2(e4(t.length,e),function(e){return Math.floor(e*Math.pow(10,-t.length+3))})}},{key:"set",value:function(e,t,a){return e.setUTCMilliseconds(a),e}}]),a}(eC),tP=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",10),eS(ep(e),"incompatibleTokens",["t","T","x"]),e}return eT(a,[{key:"parse",value:function(e,t){switch(t){case"X":return e5(eQ,e);case"XX":return e5(eJ,e);case"XXXX":return e5(eZ,e);case"XXXXX":return e5(e1,e);default:return e5(e0,e)}}},{key:"set",value:function(e,t,a){return t.timestampIsSet?e:new Date(e.getTime()-a)}}]),a}(eC),tD=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",10),eS(ep(e),"incompatibleTokens",["t","T","X"]),e}return eT(a,[{key:"parse",value:function(e,t){switch(t){case"x":return e5(eQ,e);case"xx":return e5(eJ,e);case"xxxx":return e5(eZ,e);case"xxxxx":return e5(e1,e);default:return e5(e0,e)}}},{key:"set",value:function(e,t,a){return t.timestampIsSet?e:new Date(e.getTime()-a)}}]),a}(eC),tq=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",40),eS(ep(e),"incompatibleTokens","*"),e}return eT(a,[{key:"parse",value:function(e){return e3(eY,e)}},{key:"set",value:function(e,t,a){return[new Date(1e3*a),{timestampIsSet:!0}]}}]),a}(eC),tI=function(e){ex(a,e);var t=eb(a);function a(){var e;ev(this,a);for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];return eS(ep(e=t.call.apply(t,[this].concat(n))),"priority",20),eS(ep(e),"incompatibleTokens","*"),e}return eT(a,[{key:"parse",value:function(e){return e3(eY,e)}},{key:"set",value:function(e,t,a){return[new Date(a),{timestampIsSet:!0}]}}]),a}(eC),tG={G:new eA,y:new te,Y:new tr,R:new ti,u:new ts,Q:new tl,q:new to,M:new td,L:new tc,w:new tm,I:new th,d:new tx,D:new ty,E:new tv,e:ne
1w tj,c:new tN,i:new tT,a:new tS,b:new tk,B:new tE,h:new t_,H:new tC,K:new tA,k:new tR,m:new tF,s:new tL,S:new tO,X:new tP,x:new tD,t:new tq,T:new tI},tB=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,tU=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,t$=/^'([^]*?)'?$/,tH=/''/g,tM=/\S/,tW=/[a-zA-Z]/;let tY=(e,t)=>{if(!t)return;let a=ee.DATE_FORMAT_REGEX.test(t)?"dd/MM/yyyy":"yyyy-MM-dd";return(0,er.default)(t)?t:function(e,t,a,r){(0,eh.default)(3,arguments);var n=String(e),i=String(t),s=(0,tw.getDefaultOptions)(),l=null!=(c=null!=(u=null==r?void 0:r.locale)?u:s.locale)?c:el.default;if(!l.match)throw RangeError("locale must contain match property");var o=(0,ef.default)(null!=(m=null!=(f=null!=(h=null!=(p=null==r?void 0:r.firstWeekContainsDate)?p:null==r||null==(g=r.locale)||null==(x=g.options)?void 0:x.firstWeekContainsDate)?h:s.firstWeekContainsDate)?f:null==(y=s.locale)||null==(w=y.options)?void 0:w.firstWeekContainsDate)?m:1);if(!(o>=1&&o<=7))throw RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var d=(0,ef.default)(null!=(b=null!=(v=null!=(j=null!=(N=null==r?void 0:r.weekStartsOn)?N:null==r||null==(T=r.locale)||null==(S=T.options)?void 0:S.weekStartsOn)?j:s.weekStartsOn)?v:null==(k=s.locale)||null==(E=k.options)?void 0:E.weekStartsOn)?b:0);if(!(d>=0&&d<=6))throw RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===i)if(""===n)return(0,ed.default)(a);else return new Date(NaN);var c,u,m,f,h,p,g,x,y,w,b,v,j,N,T,S,k,E,_,C={firstWeekContainsDate:o,weekStartsOn:d,locale:l},A=[new e_],R=i.match(tU).map(function(e){var t=e[0];return t in ec.default?(0,ec.default[t])(e,l.formatLong):e}).join("").match(tB),F=[],L=es(R);try{for(L.s();!(_=L.n()).done;){var O=function(){var t=_.value;!(null!=r&&r.useAdditionalWeekYearTokens)&&(0,em.isProtectedWeekYearToken)(t)&&(0,em.throwProtectedError)(t,i,e),!(null!=r&&r.useAdditionalDayOfYearTokens)&&(0,em.isProtectedDayOfYearToken)(t)&&(0,em.throwProtectedError)(t,i,e);var a=t[0],s=tG[a];if(s){var o=s.incompatibleTokens;if(Array.isArray(o)){var d=F.find(function(e){return o.includes(e.token)||e.token===a});if(d)throw RangeError("The format string mustn't contain `".concat(d.fullToken,"` and `").concat(t,"` at the same time"))}else if("*"===s.incompatibleTokens&&F.length>0)throw RangeError("The format string mustn't contain `".concat(t,"` and any other token at the same time"));F.push({token:a,fullToken:t});var c=s.run(n,t,l.match,C);if(!c)return{v:new Date(NaN)};A.push(c.setter),n=c.rest}else{if(a.match(tW))throw RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");if("''"===t?t="'":"'"===a&&(t=t.match(t$)[1].replace(tH,"'")),0!==n.indexOf(t))return{v:new Date(NaN)};n=n.slice(t.length)}}();if("object"===(0,en.default)(O))return O.v}}catch(e){L.e(e)}finally{L.f()}if(n.length>0&&tM.test(n))return new Date(NaN);var P=A.map(function(e){return e.priority}).sort(function(e,t){return t-e}).filter(function(e,t,a){return a.indexOf(e)===t}).map(function(e){return A.filter(function(t){return t.priority===e}).sort(function(e,t){return t.subPriority-e.subPriority})}).map(function(e){return e[0]}),D=(0,ed.default)(a);if(isNaN(D.getTime()))return new Date(NaN);var q,I=(0,eo.default)(D,(0,eu.default)(D)),G={},B=es(P);try{for(B.s();!(q=B.n()).done;){var U=q.value;if(!U.validate(I,C))return new Date(NaN);var $=U.set(I,G,C);Array.isArray($)?(I=$[0],function(e,t){if(null==e)throw TypeError("assign requires that input parameter not be null or undefined");for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a])}(G,$[1])):I=$}}catch(e){B.e(e)}finally{B.f()}return I}(t,a,new Date)};e.i(979037);var tK=e.i(585084),tz=e.i(348967);let tV=({focus:e,id:r,index:i,label:s,onKeyDown:l,onSelect:o,setFocus:d})=>{let c=(0,a.useRef)(null),u=(0,n.default)("c-dropdown-search__list-item",{"is-selected":e});(0,a.useEffect)(()=>{e&&c.current.focus()},[e]);let m=e=>{d(i),o(e)};return(0,t.jsx)("li",{"aria-selected":!!e||null,className:u,id:r,onClick:m,onKeyDown:e=>{l(e),((0,tz.isKeyValueSupported)(tz.default.SPACEBAR,e)||e.key===tz.default.ENTER)&&(e.preventDefault(),m(e))},onKeyUp:e=>{(0,tz.isKeyValueSupported)(tz.default.ARROW_UP,e)&&d(i),(0,tz.isKeyValueSupported)(tz.default.ARROW_DOWN,e)&&d(i)},ref:c,role:"option",tabIndex:e?0:-1,children:s})};var tX=e.i(89242),tQ=e.i(76605),tJ=e.i(971475);let tZ=({hint:e,id:r,initialValue:n="",items:i,label:s,labelClassName:l,onCh
1ange:o,onClick:d,resetOption:u,urlPattern:m})=>{let[f,h]=(0,a.useState)(""),[p,g]=(0,a.useState)(null),[x,y]=(0,a.useState)([]),[w,b]=(0,a.useState)(!1),v=x.filter(e=>!e.isDisabled),j=u?v.length+1:v.length,N=(0,a.useRef)(null),T=(0,a.useRef)(null),S=(0,a.useRef)(null),[k,E]=(0,tJ.default)(N?.current,{childSelectors:"li",direction:"vertical"});(0,tQ.default)(N,()=>{b(!1),E(null)}),(0,a.useEffect)(()=>{y(i),g(i.filter(e=>e.isActive)[0]?.label||n),E(null)},[i]);let _=()=>{b(!1),E(null),h(""),y(i)},C=e=>{e.key===tz.default.TAB&&_(),(0,tz.isKeyValueSupported)(tz.default.ESCAPE,e)&&(_(),T.current.focus())},A=(e,t,a)=>{d&&d(e),o&&o(t),h(t),g(t),b(!1),((0,tz.isKeyValueSupported)(tz.default.SPACEBAR,a)||a.key===tz.default.ENTER)&&T.current.focus()};return(0,t.jsxs)("div",{className:"c-dropdown-search",children:[(0,t.jsx)(U.default,{className:l,htmlFor:`dropdown-input-${r}`,text:s}),(0,t.jsxs)("div",{className:"c-dropdown-search__wrapper",ref:N,children:[(0,t.jsx)("div",{"aria-controls":`dropdown-${r}`,"aria-expanded":w,"aria-haspopup":"listbox","aria-label":s,className:"c-select",onClick:()=>{b(!w),h(""),y(i)},onKeyDown:e=>{((0,tz.isKeyValueSupported)(tz.default.SPACEBAR,e)||(0,tz.isKeyValueSupported)(tz.default.ARROW_DOWN,e)||(0,tz.isKeyValueSupported)(tz.default.ARROW_UP,e)||e.key===tz.default.ENTER)&&(e.preventDefault(),e.stopPropagation(),b(!0),h(""),E(null),setTimeout(()=>S.current.focus())),C(e)},ref:T,role:"combobox",tabIndex:0,children:(0,t.jsx)("span",{className:"c-dropdown-search__result",children:p})}),(0,t.jsxs)("div",{className:`c-dropdown-search__list-wrapper ${w?"is-open":""}`,id:`dropdown-${r}`,children:[(0,t.jsx)("input",{"aria-activedescendant":null!==k?`option-${r}-${k}`:null,"aria-autocomplete":"list","aria-describedby":e?`dropdown-hint-${r}`:null,"aria-owns":`dropdown-list-${r}`,autoComplete:"off",className:"c-text-input c-dropdown-search__input",id:`dropdown-input-${r}`,onChange:e=>{let t=e.target.value,a=RegExp(t,"gi");h(t),y(i.filter(e=>e.label.match(a)))},onKeyDown:C,ref:S,value:f}),(0,t.jsx)(c.default,{className:"c-dropdown-search__button",icon:"iconSmallActionSearch",iconClassName:"tw-mr-0",textClassName:"tw-sr-only",variant:"unstyled",tabIndex:-1,children:"Search"}),(0,t.jsx)(tX.default,{length:j,queryLength:f.length}),(0,t.jsxs)("ul",{"aria-label":n,className:"c-dropdown-search__list tw-list-none",id:`dropdown-list-${r}`,role:"listbox",children:[u&&(0,t.jsx)(tV,{focus:0===k,id:`option-${r}-0`,index:0,label:u,onKeyDown:C,onSelect:e=>A(m?e=>void 0===e?"":e.replace(ee.REGEX_PAGINATION_QUERY,"").replace(RegExp(`&?${m}`),""):"",u,e),setFocus:()=>E(0)},r),x.filter(e=>!e.isDisabled).map((e,a)=>(0,t.jsx)(tV,{focus:k===a+1,id:`option-${r}-${a+1}`,index:a+1,label:e.label,onKeyDown:C,onSelect:t=>A(e.value?e.value:"",e.label,t),setFocus:E},`${e.id}-${a+1}`))]})]})]}),e&&(0,t.jsx)(G.default,{id:`dropdown-hint-${r}`,children:(0,t.jsx)("p",{children:e})})]})};e.i(947819);var t0=e.i(644853);let t1=(0,a.forwardRef)(({accept:e,children:a,className:r,describedBy:i,icon:s,iconClassName:l,iconPlacementSwitch:o,id:d,isDisabled:c,isInvalid:u,isRequired:m,multiple:f,name:h,handleChange:p,tabIndex:g,textClassName:x,variant:y="secondary"},w)=>{let b="unstyled"===y,v=(0,n.default)({"c-btn":!b,[`c-btn--${y}`]:!b,"c-file-input__btn":!b,"c-label":b,[r]:r}),j=(0,n.default)({"c-file-input":!b}),N=(0,n.default)("c-btn__icon",{"c-btn__icon--left":!o,"c-btn__icon--right":o,[l]:l}),T=(0,n.default)("c-btn__text",{[x]:x}),S=e?e.join(", "):"";return(0,t.jsxs)(t.Fragment,{children:[b&&(0,t.jsx)("label",{className:v,htmlFor:d,tabIndex:g,children:(0,t.jsx)("span",{className:T,children:a})}),(0,t.jsx)("input",{accept:S,"aria-describedby":i,"aria-invalid":u,"aria-required":m,className:j,disabled:c,id:d,multiple:f,name:h,onChange:p,ref:w,type:"file"}),!b&&(0,t.jsxs)("label",{className:v,htmlFor:d,tabIndex:g,children:[s&&!o&&(0,t.jsx)(t0.default,{name:s,className:N}),(0,t.jsx)("span",{className:T,children:a}),s&&o&&(0,t.jsx)(t0.default,{name:s,className:N})]})]})});t1.displayName="FileInput";let t2=e.r(560439);var t3=e.i(957382),t5=e.i(55261);let t4=e=>{if(!e)return;let t=e.toString();switch(t){case"true":return"Yes";case"false":return"No";default:return t}},t6=[{label:"Biomedical Resources",type:"grant"},{label:"Career Re-Entry Fellowship",type:"fellowship"},{label:"Clinical Research Career Development Fellowship",type:"fellowship"},{label:"Collaborative Award in HSS",type:"grant"},{label:"Collaborative Award in Science",type:"grant"},{label:"Doctoral Studentships",type:"fellowship"},{label:"International Intermediate Fellowships",type:"fellowship"},{label:"International Masters Fellowship",type:"fellowship"},{label:"International Training Fellowship",type:"fellowship"},{label:"Investigator Award in HSS",type:"grant"},{label:"Investigator Award in Science",type:"grant"},{label:"Longitudinal Population Studies",type:"grant"},{label:"Principal Research Fellowship",type:"fellowship"},{label:"Research Career Development Fellowship",type:"fellowship"},{label:"Research Fellowships for Health Professionals",type:"fellowship"},{label:"Research Fellowships in HSS",type:"fellowship"},{label:"Seed Award in HSS",type:"grant"},{label:"Seed Award in Science",type:"grant"},{label:"Senior Research Fellowship",type:"fellowship"},{label:"Sir Henry Dale Fellowship",type:"fellowship"},{label:"Sir Henry Wellcome Postdoctoral Fellowship",type:"fellowship"},{label:"Technology Development Grant",type:"grant"}],t8=e=>{if(e)return t6.find(t=>t.label===e)?.type},t7={1:(0,t.jsx)(()=>{let e=(0,S.useRouter)(),{ref:r}=e.query,[n,i]=(0,a.useState)(!1),s=(0,a.useMemo)(()=>(0,T.object)({formType:(0,T.string)().required("Please select one of the options").oneOf(["funding","grants","general"],"Please select one of the options")}),[]),l=(0,k.useYupValidationResolver)({schema:s}),{handleSubmit:o,register:d,formState:{errors:u}}=(0,N.useForm)({mode:"onTouched",resolver:l}),m=async t=>{try{i(!0);let a=`${R[t.formType]}${r?`?ref=${r.toString()}`:""}`;e.push(a)}catch(e){throw i(!1),Error(e.message)}};return(0,t.jsxs)("form",{className:"js-non-tracking-form c-form",onSubmit:o(m),children:[(0,t.jsxs)(C.default,{legend:"What's your message about?",children:[(0,t.jsx)(A.default,{describedBy:u.formType&&"formTypeErrors",id:"formType[funding]",label:"Funding",value:"funding",...d("formType")}),(0,t.jsx)(A.default,{describedBy:u.formType&&"formTypeErrors",id:"formType[grants]",label:"Using our online grants system",value:"grants",...d("formType")}),(0,t.jsx)(A.default,{describedBy:u.formType&&"formTypeErrors",id:"formType[general]",label:"Something else",value:"general",...d("formType")}),u.formType&&(0,t.jsx)(_.default,{errors:u.formType.types,id:"formTypeErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{disabled:n,type:"submit",children:n?"Loading...":"Next"})})]})},{}),2:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)(""),[n,i]=(0,a.useState)(""),s=(0,a.useRef)(null),l=P(),{isSubmitting:o,isSuccessful:d,submissionErrors:c,createTicket:u}=(0,F.useSubmitToSalesforce)();return(0,a.useEffect)(()=>{!o&&d&&(0,D.default)(s)},[d,o]),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:s}),(0,t.jsx)(z,{email:e,message:n,shouldShowMessage:d}
1),!d&&(0,t.jsx)(M,{emailHint:"Please provide a valid email address.",isSubmitting:o,isSuccessful:d,messageHint:"If you have a query about a science proposal, please include your research area so that your message reaches the relevant team.",onSubmit:e=>{r(e.email),i(e.description),u({captchaTimestamp:e.captchaTimestamp,"g-recaptcha-response":e["g-recaptcha-response"],topic:`${e.topic} - ${l??"General query"}`,description:e.description,grantReferenceNumber:e.grantReferenceNumber,name:e.name,email:e.email,phone:e.phone,formType:"fundingInformation"})},selectTopicOptions:["Personal / organisational eligibility","Funding offered","Application process","Managing your grant","Support for disabled applicants","Other"],submissionErrors:c,formType:"fundingInformation"})]})},{}),3:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)(""),[n,i]=(0,a.useState)(""),s=(0,a.useRef)(null),l=P(),{isSubmitting:o,isSuccessful:d,submissionErrors:c,createTicket:u}=(0,F.useSubmitToSalesforce)();return(0,a.useEffect)(()=>{!o&&d&&(0,D.default)(s)},[d,o]),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:s}),(0,t.jsx)(z,{email:e,message:n,shouldShowMessage:d}),!d&&(0,t.jsx)(M,{emailHint:"You'll get a quicker response if you provide the email address you use to access the system.",isSubmitting:o,isSuccessful:d,messageHint:"If you have a grant reference number or error message ID, please include it as part of your message.",onSubmit:e=>{r(e.email),i(e.description),u({"g-recaptcha-response":e["g-recaptcha-response"],captchaTimestamp:e.captchaTimestamp,topic:`${e.topic} - ${l??"General query"}`,description:e.description,grantReferenceNumber:e.grantReferenceNumber,name:e.name,email:e.email,phone:e.phone,formType:"fundingSupport"})},selectTopicOptions:["Authorised organisation approval","Grant acceptance record","Password reset","Adding participants","Support for disabled applicants","Website feedback","Other"],submissionErrors:c,formType:"fundingSupport"})]})},{}),4:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)(!1),[n,i]=(0,a.useState)(""),[s,l]=(0,a.useState)(""),o=(0,a.useRef)(null),d={"Job, graduate scheme or internship":"[email protected]","Journalist enquiry":"[email protected]","Filming request":"[email protected]",Complaint:"[email protected]","Personal data access request":"[email protected]","Venue hire":"[email protected]","Wellcome Collection (museum and library)":"[email protected]","Website feedback":"[email protected]","Website accessibility":"[email protected]","General enquiry":"[email protected]"},c=Object.keys(d),{hasSent:u,sendEmail:m,submissionEmailErrors:f}=Q(),{hasSent:h,sendEmail:p,submissionEmailErrors:g}=Q();(0,a.useEffect)(()=>{h&&u&&(r(!1),(0,D.default)(o))},[h,u]),(0,a.useEffect)(()=>{(g||f)&&r(!1)},[g,f]);let x=async e=>{r(!0),i(e.email),l(e.description),m({content:e,subject:e.topic,to:e.email,type:"generalEnquiryReceipt"}),p({content:e,subject:e.topic,to:d[e.topic],type:"generalEnquiryNotification"})};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:o}),(0,t.jsx)(z,{email:n,message:s,shouldShowMessage:h&&u}),!h&&!u&&(0,t.jsx)(M,{isSuccessful:h&&u,isSubmitting:e,onSubmit:x,selectTopicOptions:c,submissionErrors:g||f,formType:"generalEnquiry"})]})},{}),5:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)(""),n=(0,a.useMemo)(()=>(0,T.object)({grantReferenceNumber:(0,T.string)().trim().required("Enter a grant reference number in the correct format"),amountToBeSupplemented:(0,T.string)().required("Enter the amount to be supplemented"),fullNameGrantholder:(0,T.string)().required("Enter the grantholder's full name"),isPersonWhoTookLeave:(0,T.string)().required("Select yes if this is the person who took leave"),fullNameLeaveTaker:(0,T.string)().when("isPersonWhoTookLeave",{is:"no",then:e=>e.required("Enter the full name of the person who took leave")}),firstDayOfLeave:(0,T.date)().transform(tY).typeError("This does not look like a valid date").required("Enter the first day of leave"),lastDayOfLeave:(0,T.date)().transform(tY).min((0,T.ref)("firstDayOfLeave"),"Enter a date which is after the first day of leave").required("Enter the last day of leave").typeError("This does not look like a valid date"),shouldExtendGrant:(0,T.string)().required("Select yes if the grantholder needs to extend the grant"),hoursOnReturnToWork:(0,T.string)().when("isPersonWhoTookLeave",{is:"yes",then:e=>e.required("Please select one of the options")}),fullTimeEquivalent:(0,T.string)().when(["hoursOnReturnToWork","isPersonWhoTookLeave"],{is:(e,t)=>"part"===e&&"yes"===t,then:e=>e.required("Enter the full-time equivalent (FTE)")}),lengthOfExtension:(0,T.string)().when(["shouldExtendGrant"],{is:e=>"yes"===e,then:e=>e.required("Enter how long they need to extend the grant")}),justificationForExtension:(0,T.string)().when(["shouldExtendGrant"],{is:e=>"yes"===e,then:e=>e.required("Enter details to justify why the need to extend the grant")}),fullNameSubmitter:(0,T.string)().trim().required("Enter your full name"),emailAddressSubmitter:(0,T.string)().email("Enter an email address in the correct format, like [email protected]").required("Enter your email address"),captchaTimestamp:(0,T.string)().required("The answer you entered for the CAPTCHA was not correct. Please try again."),"g-recaptcha-response":(0,T.string)().required("The response you entered for the CAPTCHA was not correct. Please try again")}),[]),i=(0,k.useYupValidationResolver)({schema:n}),{NEXT_PUBLIC_GOOGLE_RECAPTCHA_SITE_KEY:s}=(0,O.getBuildTimeConfig)(),l=(0,a.useRef)(null),{clearErrors:o,control:d,handleSubmit:m,register:f,watch:h,setValue:p,formState:{errors:g}}=(0,N.useForm)({mode:"onTouched",resolver:i}),x=h("isPersonWhoTookLeave"),y=h("hoursOnReturnToWork"),w=h("shouldExtendGrant"),{isSubmitting:b,isSuccessful:v,submissionErrors:j,createTicket:S}=(0,F.useSubmitToSalesforce)();(0,a.useEffect)(()=>{b||(0,D.default)(l)},[b]);let R=async e=>{o();let t=(({grantReferenceNumber:e,fullNameGrantholder:t,amountToBeSupplemented:a,isPersonWhoTookLeave:r,fullNameLeaveTaker:n,firstDayOfLeave:i,lastDayOfLeave:s,shouldExtendGrant:l,hoursOnReturnToWork:o,fullTimeEquivalent:d,lengthOfExtension:c,justificationForExtension:u,fullNameSubmitter:m,emailAddressSubmitter:f})=>` 2Grant Reference Number: 3${e??""} 4 5Amount to be supplemented: 6${a??""} 7 8Grantholder's full name: 9${t??""} 10 11Is this the person who took leave?: 12${r??""} 13 14Full name of the person who took leave: 15${"yes"===r?t??"":n??""} 16 17First day of leave: 18${i??""} 19 20Last day of leave: 21${s??""} 22 23Does the grantholder need to extend the grant?: 24${l??""} 25 26Hours on return to work: 27${o??""} 28 29Full-time equivalent (FTE): 30${d??""} 31 32For how long do they need to extend the grant?: 33${c??""} 34 35Justify why they need to extend the grant: 36${u??""} 37 38Full name of the person filling in this form: 39${m??""} 40 41Email address for the person filling in this form: 42${f??""} 43 `)({grantReferenceNumber:e.grantReferenceNumber,amountToBeSupplemented:e.amountToBeSupplemented,fullNameGrantholder:e.fullNameGrantholder,isPersonWhoTookLeave:e.isPersonWhoTookLeave,fullNameLeaveTaker:e.fullNameLeaveTaker,firstDayOfLeave:e.firstDayOfLeave,lastDayOfLeave:e.lastDayOfLeave,shouldExtendGrant:e.shouldExtendGrant,hoursOnReturnToWork:e.hoursOnReturnToWork,fullTimeEquivalent:e.fullTimeEquivalent,lengthOfExtension:e.lengthOfExtension,justificationForExtension:e.justificationForExtension,fullNameSubmitter:e.fullNameSubmitter,emailAddressSubmitter:e.emailAddressSubmitter});S({captchaTimestamp:e.captchaTimestamp,"g-recaptcha-response":e["g-recaptcha-response"],topic:"Return from sick leave",description:t,grantReferenceNumber:e.grantReferenceNumber,name:e.fullNameSubmitter,email:e.emailAddressSubmitter,formType:"fundingInformation"})};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:l}),(0,t.jsx)(ea,{shouldShowMessage:v}),!v&&(0,t.jsxs)("form",{noValidate:!0,onSubmit:m(R),className:"c-form",children:[(0,t.jsx)(N.Controller,{c
43ontrol:d,name:"captchaTimestamp",defaultValue:"",render:({field:{onBlur:a,onChange:r}})=>(0,t.jsx)(H.default,{name:"captchaTimestamp",id:"captchaTimestamp",type:"hidden",size:20,maxLength:20,spellCheck:"false",value:e,onChange:r,onBlur:a})}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"This is for the research office to complete when someone comes back from sick leave."}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"You must complete all the fields."}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"grantReferenceNumber",text:"Grant Reference Number"}),(0,t.jsx)(H.default,{describedBy:g.grantReferenceNumber?"grantReferenceNumberHint grantReferenceNumberErrors":"grantReferenceNumberHint",id:"grantReferenceNumber",isInvalid:!!g.grantReferenceNumber,isRequired:!0,...f("grantReferenceNumber")}),(0,t.jsx)(G.default,{id:"grantReferenceNumberHint",children:(0,t.jsx)("p",{children:"For example 012345/Z/19/Z"})}),g.grantReferenceNumber&&(0,t.jsx)(_.default,{errors:g.grantReferenceNumber.types,id:"grantReferenceNumberErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{className:"tw-mb-wdsSpacing200",htmlFor:"amountToBeSupplemented",text:"Amount to be supplemented"}),(0,t.jsxs)("div",{id:"amountToBeSupplementedHint1",children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"This is the amount your organisation has incurred paying the salary of the person who has been on leave. This must be in line with their terms and conditions of employment."}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"To calculate this, you must add up:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"the basic salary"}),(0,t.jsx)("li",{children:"any employerâs contributions, such as National Insurance and pension contributions"}),(0,t.jsx)("li",{children:"any additional incremental progression up the salary scale"}),(0,t.jsx)("li",{children:"any costs to continue contractual benefits during their leave."})]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"The total must not include:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"any recoverable statutory sick pay"}),(0,t.jsx)("li",{children:"research costs (we automatically provide these if eligible)."})]})]}),(0,t.jsx)("br",{}),(0,t.jsx)(H.default,{describedBy:g.amountToBeSupplemented?"amountToBeSupplementedHint1 amountToBeSupplementedHint2 amountToBeSupplementedErrors":"amountToBeSupplementedHint1 amountToBeSupplementedHint2",id:"amountToBeSupplemented",isInvalid:!!g.amountToBeSupplemented,isRequired:!0,...f("amountToBeSupplemented")}),(0,t.jsxs)(G.default,{id:"amountToBeSupplementedHint2",children:[(0,t.jsx)("p",{children:"Enter the amount and currency."}),(0,t.jsx)("p",{children:"If you need help completing this form, contact [email protected]."})]}),g.amountToBeSupplemented&&(0,t.jsx)(_.default,{errors:g.amountToBeSupplemented.types,id:"amountToBeSupplementedErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullNameGrantholder",text:"Grantholder's full name"}),(0,t.jsx)(H.default,{describedBy:g.fullNameGrantholder&&"fullNameGrantholderErrors",id:"fullNameGrantholder",isInvalid:!!g.fullNameGrantholder,isRequired:!0,spellCheck:"false",...f("fullNameGrantholder")}),g.fullNameGrantholder&&(0,t.jsx)(_.default,{errors:g.fullNameGrantholder.types,id:"fullNameGrantholderErrors"})]}),(0,t.jsxs)(C.default,{legend:"Is this the person who took leave?",children:[(0,t.jsx)(A.default,{describedBy:g.isPersonWhoTookLeave&&"isPersonWhoTookLeaveErrors",id:"isPersonWhoTookLeaveYes",label:"Yes",value:"yes",...f("isPersonWhoTookLeave")}),(0,t.jsx)(A.default,{describedBy:g.isPersonWhoTookLeave&&"isPersonWhoTookLeaveErrors",id:"isPersonWhoTookLeaveNo",label:"No",value:"no",...f("isPersonWhoTookLeave")}),g.isPersonWhoTookLeave&&(0,t.jsx)(_.default,{errors:g.isPersonWhoTookLeave.types,id:"isPersonWhoTookLeaveErrors"})]}),"no"===x&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{text:"Full name of the person who took leave",htmlFor:"fullNameLeaveTaker"}),(0,t.jsx)(H.default,{describedBy:g.fullNameLeaveTaker&&"fullNameLeaveTakerErrors",id:"fullNameLeaveTaker",isInvalid:!!g.fullNameLeaveTaker,isRequired:!0,spellCheck:"false",...f("fullNameLeaveTaker")}),g.fullNameLeaveTaker&&(0,t.jsx)(_.default,{errors:g.fullNameLeaveTaker.types,id:"fullNameLeaveTakerErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"firstDayOfLeave",text:"First day of leave"}),(0,t.jsx)(et,{describedBy:g.firstDayOfLeave?"firstDayOfLeaveHint firstDayOfLeaveErrors":"firstDayOfLeaveHint",id:"firstDayOfLeave",isInvalid:!!g.firstDayOfLeave,isRequired:!0,pattern:`${ee.DATE_FORMAT_REGEX}`,...f("firstDayOfLeave")}),(0,t.jsx)(G.default,{id:"firstDayOfLeaveHint",children:(0,t.jsxs)("p",{children:[(0,t.jsx)(u.default,{children:"Use the format "}),"dd/mm/yyyy"]})}),g.firstDayOfLeave&&(0,t.jsx)(_.default,{errors:g.firstDayOfLeave.types,id:"firstDayOfLeaveErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"lastDayOfLeave",text:"Last day of leave"}),(0,t.jsx)(et,{describedBy:g.lastDayOfLeave?"lastDayOfLeaveHint lastDayOfLeaveErrors":"lastDayOfLeaveHint",id:"lastDayOfLeave",isInvalid:!!g.lastDayOfLeave,isRequired:!0,pattern:`${ee.DATE_FORMAT_REGEX}`,...f("lastDayOfLeave")}),(0,t.jsx)(G.default,{id:"lastDayOfLeaveHint",children:(0,t.jsxs)("p",{children:[(0,t.jsx)(u.default,{children:"Use the format "}),"dd/mm/yyyy"]})}),g.lastDayOfLeave&&(0,t.jsx)(_.default,{errors:g.lastDayOfLeave.types,id:"lastDayOfLeaveErrors"})]}),(0,t.jsxs)(C.default,{legend:"Does the grantholder need to extend the grant?",children:[(0,t.jsx)(A.default,{describedBy:g.shouldExtendGrant&&"shouldExtendGrantErrors",id:"shouldExtendGrantYes",label:"Yes",value:"yes",...f("shouldExtendGrant")}),(0,t.jsx)(A.default,{describedBy:g.shouldExtendGrant&&"shouldExtendGrantErrors",id:"shouldExtendGrantNo",label:"No",value:"no",...f("shouldExtendGrant")}),g.shouldExtendGrant&&(0,t.jsx)(_.default,{errors:g.shouldExtendGrant.types,id:"shouldExtendGrantErrors"})]}),"yes"===x&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(C.default,{legend:"Hours on return to work:",children:[(0,t.jsx)(A.default,{describedBy:g.hoursOnReturnToWork&&"hoursOnReturnToWorkErrors",id:"hoursOnReturnToWorkFull",label:"Full-time",value:"full",...f("hoursOnReturnToWork")}),(0,t.jsx)(A.default,{describedBy:g.hoursOnReturnToWork&&"hoursOnReturnToWorkErrors",id:"hoursOnReturnToWorkPart",label:"Part-time",value:"part",...f("hoursOnReturnToWork")}),g.hoursOnReturnToWork&&(0,t.jsx)(_.default,{errors:g.hoursOnReturnToWork.types,id:"hoursOnReturnWorkErrors"})]}),"part"===y&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullTimeEquivalent",text:"Tell us the full-time equivalent (FTE)"}),(0,t.jsx)(H.default,{describedBy:g.fullTimeEquivalent?"fullTimeEquivalentHint fullTimeEquivalentErrors":"fullTimeEquivalentHint",id:"fullTimeEquivalent",isInvalid:!!g.fullTimeEquivalent,isRequired:!0,...f("fullTimeEquivalent")}),(0,t.jsx)(G.default,{id:"fullTimeEquivalentHint",children:(0,t.jsx)("p",{children:"For example 0.8 FTE until July 2021, then 1.0 FTE."})}),g.fullTimeEquivalent&&(0,t.jsx)(_.default,{errors:g.fullTimeEquivalent.types,id:"fullTimeEquivalentErrors"})]})]}),"yes"===w&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"lengthOfExtension",text:"For how long do they need to extend the grant"}),(0,t.jsx)(H.default,{describedBy:g.lengthOfExtension&&"lengthOfExtensionErrors",id:"lengthOfExtension",isInvalid:!!g.lengthOfExtension,isRequired:!0,...f("lengthOfExtension")}),g.lengthOfExtension&&(0,t.jsx)(_.default,{errors:g.lengthOfExtension.types,id:"lengthOfExtensionErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"justificationForExtension",text:"Justify why they need to extend the grant"}),(0,t.jsx)($.default,{describedBy:g.justificationForExtension&&"justificationForExtensionErrors",id:"justificationForExtension",isInvalid:!!g.justificationForExtension,isRequired:!0,...f("justificationForExtension")}),g.justificationForExtension&&(0,t.jsx)(_.default,{errors:g.justificationForExtension.types,id:"justificationForExtensionErrors"})]})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullNameSubmitter",text:"Full name of the person filling in this form"}),(0,t.jsx)(H.default,{autoComplete:"name",describedBy:g.fullNameSubmitter&&"fullNameSubmitterErrors",id:"fullNameSubmitter",isInvalid:!!g.fullNameSubmitter,isRequired:!0,spellCheck:"false",...f("fullNameSubmitter")}),g.fullNameSubmitter&&(0,t.jsx)(_.default,{errors:g.fullNameSubmitter.types,id:"fullNameSubmitterErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"emailAddressSubmitter",text:"Email address for the person filling in this form"}),(0,t.jsx)(H.default,{autoComplete:"email",describedBy:g.emailAddressSubmitter?"emailAddressSubmitterHint emailAddressSubmitterErrors":"emailAddressSubmitterHint",id:"emailAddressSubmitter",isInvalid:!!g.emailAddressSubmitter,isRequired:!0,spellCheck:"false",type:"email",...f("emailAddressSubmitter")}),(0,t.jsx)(G.default,{id:"emailAddressSubmitterHint",children:(0,t.jsx)("p",{children:"Weâll use this to contact you."})}),g.emailAddressSubmitter&&(0,t.jsx)(_.default,{errors:g.emailAddressSubmitter.types,id:"emailAddressSubmitterErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsxs)("p",{children:["We respect your privacy and will only share personal data for purposes as described
43in our"," ",(0,t.jsx)(I.default,{href:"/who-we-are/privacy-and-terms",children:"terms and conditions"}),"."]})}),(0,t.jsxs)(E.default,{className:"c-form-field--captcha",children:[s&&(0,t.jsx)(N.Controller,{control:d,defaultValue:"",name:"g-recaptcha-response",render:({field:{onBlur:e,onChange:a}})=>(0,t.jsx)(q.default,{onBlur:e,onChange:e=>{let t=new Date().getTime().toString();r(t),p("captchaTimestamp",t,{shouldValidate:!0}),a(e)},onExpired:()=>a(""),sitekey:s})}),g["g-recaptcha-response"]&&(0,t.jsx)(_.default,{errors:g["g-recaptcha-response"].types,id:"captchaErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{type:"submit",disabled:b,children:b?"Submitting...":"Submit"})}),!v&&j?.length>0&&(0,t.jsx)(E.default,{children:(0,t.jsx)(_.default,{errors:j,id:"webToCaseSubmissionErrors"})}),(0,t.jsx)("p",{children:"Youâll receive an email confirming the information youâve given us."})]})]})},{}),6:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)(""),n=(0,a.useMemo)(()=>(0,T.object)({grantReferenceNumber:(0,T.str
43ing)().trim().required("Enter a grant reference number in the correct format"),amountToBeSupplemented:(0,T.string)().required("Enter the amount to be supplemented"),fullNameGrantholder:(0,T.string)().required("Enter the grantholder's full name"),isPersonWhoTookLeave:(0,T.string)().required("Select yes if this is the person who took leave"),fullNameLeaveTaker:(0,T.string)().when("isPersonWhoTookLeave",{is:"no",then:e=>e.required("Enter the full name of the person who took leave")}),firstDayOfLeave:(0,T.date)().transform(tY).required("Enter the first day of leave").typeError("This does not look like a valid date"),lastDayOfLeave:(0,T.date)().transform(tY).min((0,T.ref)("firstDayOfLeave"),"Enter a date which is after the first day of leave").required("Enter the last day of leave").typeError("This does not look like a valid date"),annualLeaveDays:(0,T.string)().matches(/^\d+(\.\d+)?$/,{message:"Days of annual leave must be a number, for example 14 or 20.5",excludeEmptyString:!0}).required("Enter number of days of annual leave accrued during this period of parental leave"),wasSharedParentalLeave:(0,T.string)().required("Select yes if this was shared parental leave"),shouldExtendGrant:(0,T.string)().required("Select yes if the grantholder needs to extend the grant"),hoursOnReturnToWork:(0,T.string)().when("isPersonWhoTookLeave",{is:"yes",then:e=>e.required("Please select one of the options")}),fullTimeEquivalent:(0,T.string)().when(["hoursOnReturnToWork","isPersonWhoTookLeave"],{is:(e,t)=>"part"===e&&"yes"===t,then:e=>e.required("Enter the full-time equivalent (FTE)")}),lengthOfExtension:(0,T.string)().when(["shouldExtendGrant"],{is:e=>"yes"===e,then:e=>e.required("Enter how long they need to extend the grant")}),justificationForExtension:(0,T.string)().when(["shouldExtendGrant"],{is:e=>"yes"===e,then:e=>e.required("Enter details to justify why the need to extend the grant")}),fullNameSubmitter:(0,T.string)().trim().required("Enter your full name"),emailAddressSubmitter:(0,T.string)().email("Enter an email address in the correct format, like [email protected]").required("Enter your email address"),captchaTimestamp:(0,T.string)().required("The answer you entered for the CAPTCHA was not correct. Please try again"),"g-recaptcha-response":(0,T.string)().required("The response you entered for the CAPTCHA was not correct. Please try again")}),[]),i=(0,k.useYupValidationResolver)({schema:n}),{NEXT_PUBLIC_GOOGLE_RECAPTCHA_SITE_KEY:s}=(0,O.getBuildTimeConfig)(),l=(0,a.useRef)(null),{clearErrors:o,control:d,handleSubmit:m,register:f,watch:h,setValue:p,formState:{errors:g}}=(0,N.useForm)({mode:"onTouched",resolver:i}),x=h("isPersonWhoTookLeave"),y=h("hoursOnReturnToWork"),w=h("shouldExtendGrant"),{isSubmitting:b,isSuccessful:v,submissionErrors:j,createTicket:S}=(0,F.useSubmitToSalesforce)();(0,a.useEffect)(()=>{b||(0,D.default)(l)},[b]);let R=async e=>{o();let t=(({grantReferenceNumber:e,fullNameGrantholder:t,amountToBeSupplemented:a,isPersonWhoTookLeave:r,fullNameLeaveTaker:n,firstDayOfLeave:i,lastDayOfLeave:s,annualLeaveDays:l,wasSharedParentalLeave:o,shouldExtendGrant:d,hoursOnReturnToWork:c,fullTimeEquivalent:u,lengthOfExtension:m,justificationForExtension:f,fullNameSubmitter:h,emailAddressSubmitter:p})=>` 44Grant Reference Number: 45${e??""} 46 47Amount to be supplemented: 48${a??""} 49 50Grantholder's full name: 51${t??""} 52 53Is this the person who took leave?: 54${r??""} 55 56Full name of the person who took leave: 57${"yes"===r?t??"":n??""} 58 59First day of leave: 60${i??""} 61 62Last day of leave: 63${s??""} 64 65Number of days of annual leave accrued during this period of parental leave: 66${l??""} 67 68Was this shared parental leave?: 69${o??""} 70 71Does the grantholder need to extend the grant?: 72${d??""} 73 74Hours on return to work: 75${c??""} 76 77Full-time equivalent (FTE): 78${u??""} 79 80For how long do they need to extend the grant?: 81${m??""} 82 83Justify why they need to extend the grant: 84${f??""} 85 86Full name of the person filling in this form: 87${h??""} 88 89Email address for the person filling in this form: 90${p??""} 91 `)({grantReferenceNumber:e.grantReferenceNumber,amountToBeSupplemented:e.amountToBeSupplemented,fullNameGrantholder:e.fullNameGrantholder,isPersonWhoTookLeave:e.isPersonWhoTookLeave,fullNameLeaveTaker:e.fullNameLeaveTaker,firstDayOfLeave:e.firstDayOfLeave,lastDayOfLeave:e.lastDayOfLeave,annualLeaveDays:e.annualLeaveDays,wasSharedParentalLeave:e.wasSharedParentalLeave,shouldExtendGrant:e.shouldExtendGrant,hoursOnReturnToWork:e.hoursOnReturnToWork,fullTimeEquivalent:e.fullTimeEquivalent,lengthOfExtension:e.lengthOfExtension,justificationForExtension:e.justificationForExtension,fullNameSubmitter:e.fullNameSubmitter,emailAddressSubmitter:e.emailAddressSubmitter});S({captchaTimestamp:e.captchaTimestamp,"g-recaptcha-response":e["g-recaptcha-response"],topic:"Return from parental leave",description:t,grantReferenceNumber:e.grantReferenceNumber,name:e.fullNameSubmitter,email:e.emailAddressSubmitter,formType:"fundingInformation"})};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:l}),(0,t.jsx)(ea,{shouldShowMessage:v}),!v&&(0,t.jsxs)("form",{noValidate:!0,onSubmit:m(R),className:"c-form",children:[(0,t.jsx)(N.Controller,{c
91ontrol:d,name:"captchaTimestamp",defaultValue:"",render:({field:{onBlur:a,onChange:r}})=>(0,t.jsx)(H.default,{name:"captchaTimestamp",id:"captchaTimestamp",type:"hidden",size:20,maxLength:20,spellCheck:"false",value:e,onChange:r,onBlur:a})}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"This is for the research office to complete when someone comes back from maternity, paternity, adoption or shared parental leave."}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"You must complete all the fields."}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"grantReferenceNumber",text:"Grant Reference Number"}),(0,t.jsx)(H.default,{describedBy:g.grantReferenceNumber?"grantReferenceNumberHint grantReferenceNumberErrors":"grantReferenceNumberHint",id:"grantReferenceNumber",isInvalid:!!g.grantReferenceNumber,isRequired:!0,...f("grantReferenceNumber")}),(0,t.jsx)(G.default,{id:"grantReferenceNumberHint",children:(0,t.jsx)("p",{children:"For example 012345/Z/19/Z"})}),g.grantReferenceNumber&&(0,t.jsx)(_.default,{errors:g.grantReferenceNumber.types,id:"grantReferenceNumberErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{className:"tw-mb-wdsSpacing200",htmlFor:"amountToBeSupplemented",text:"Amount to be supplemented"}),(0,t.jsxs)("div",{id:"amountToBeSupplementedHint1",children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"This is the amount your organisation has incurred paying the salary of the person who has been on leave."}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"To calculate this, you must add up:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"the basic salary"}),(0,t.jsx)("li",{children:"any employerâs contributions, such as National Insurance and pension contributions"}),(0,t.jsx)("li",{children:"any additional incremental progression up the salary scale"}),(0,t.jsx)("li",{children:"any costs to continue contractual benefits during their leave, for example childcare vouchers"}),(0,t.jsx)("li",{children:"accrued paid leave"}),(0,t.jsx)("li",{children:"keeping in touch days."})]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"The total must not include:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsxs)("li",{children:["any"," ",(0,t.jsx)(I.default,{href:"https://www.gov.uk/recover-statutory-payments",children:"recoverable statutory pay"})]}),(0,t.jsx)("li",{children:"research costs (we automatically provide these)."})]})]}),(0,t.jsx)("br",{}),(0,t.jsx)(H.default,{describedBy:g.amountToBeSupplemented?"amountToBeSupplementedHint1 amountToBeSupplementedHint2 amountToBeSupplementedErrors":"amountToBeSupplementedHint1 amountToBeSupplementedHint2",id:"amountToBeSupplemented",isInvalid:!!g.amountToBeSupplemented,isRequired:!0,...f("amountToBeSupplemented")}),(0,t.jsxs)(G.default,{id:"amountToBeSupplementedHint2",children:[(0,t.jsx)("p",{children:"Enter the amount and currency."}),(0,t.jsx)("p",{children:"If you need help completing this form, contact [email protected]."})]}),g.amountToBeSupplemented&&(0,t.jsx)(_.default,{errors:g.amountToBeSupplemented.types,id:"amountToBeSupplementedErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullNameGrantholder",text:"Grantholder's full name"}),(0,t.jsx)(H.default,{describedBy:g.fullNameGrantholder&&"fullNameGrantholderErrors",id:"fullNameGrantholder",isInvalid:!!g.fullNameGrantholder,isRequired:!0,spellCheck:"false",...f("fullNameGrantholder")}),g.fullNameGrantholder&&(0,t.jsx)(_.default,{errors:g.fullNameGrantholder.types,id:"fullNameGrantholderErrors"})]}),(0,t.jsxs)(C.default,{legend:"Is this the person who took leave?",children:[(0,t.jsx)(A.default,{describedBy:g.isPersonWhoTookLeave&&"isPersonWhoTookLeaveErrors",id:"isPersonWhoTookLeaveYes",label:"Yes",value:"yes",...f("isPersonWhoTookLeave")}),(0,t.jsx)(A.default,{describedBy:g.isPersonWhoTookLeave&&"isPersonWhoTookLeaveErrors",id:"isPersonWhoTookLeaveNo",label:"No",value:"no",...f("isPersonWhoTookLeave")}),g.isPersonWhoTookLeave&&(0,t.jsx)(_.default,{errors:g.isPersonWhoTookLeave.types,id:"isPersonWhoTookLeaveErrors"})]}),"no"===x&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullNameLeaveTaker",text:"Full name of the person who took leave"}),(0,t.jsx)(H.default,{describedBy:g.fullNameLeaveTaker&&"fullNameLeaveTakerErrors",id:"fullNameLeaveTaker",isInvalid:!!g.fullNameLeaveTaker,isRequired:!0,spellCheck:"false",...f("fullNameLeaveTaker")}),g.fullNameLeaveTaker&&(0,t.jsx)(_.default,{errors:g.fullNameLeaveTaker.types,id:"fullNameLeaveTakerErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"firstDayOfLeave",text:"First day of leave"}),(0,t.jsx)(et,{describedBy:g.firstDayOfLeave?"firstDayOfLeaveHint firstDayOfLeaveErrors":"firstDayOfLeaveHint",id:"firstDayOfLeave",isInvalid:!!g.firstDayOfLeave,isRequired:!0,pattern:`${ee.DATE_FORMAT_REGEX}`,...f("firstDayOfLeave")}),(0,t.jsx)(G.default,{id:"firstDayOfLeaveHint",children:(0,t.jsxs)("p",{children:[(0,t.jsx)(u.default,{children:"Use the format "}),"dd/mm/yyyy"]})}),g.firstDayOfLeave&&(0,t.jsx)(_.default,{errors:g.firstDayOfLeave.types,id:"firstDayOfLeaveErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"lastDayOfLeave",text:"Last day of leave"}),(0,t.jsx)(et,{describedBy:g.lastDayOfLeave?"lastDayOfLeaveHint lastDayOfLeaveErrors":"lastDayOfLeaveHint",id:"lastDayOfLeave",isInvalid:!!g.lastDayOfLeave,isRequired:!0,pattern:`${ee.DATE_FORMAT_REGEX}`,...f("lastDayOfLeave")}),(0,t.jsx)(G.default,{id:"lastDayOfLeaveHint",children:(0,t.jsxs)("p",{children:[(0,t.jsx)(u.default,{children:"Use the format "}),"dd/mm/yyyy"]})}),g.lastDayOfLeave&&(0,t.jsx)(_.default,{errors:g.lastDayOfLeave.types,id:"lastDayOfLeaveErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"annualLeaveDays",text:"Number of days of annual leave accrued during this period of parental leave"}),(0,t.jsx)(H.default,{describedBy:g.annualLeaveDays&&"annualLeaveDaysErrors",id:"annualLeaveDays",isInvalid:!!g.annualLeaveDays,isRequired:!0,...f("annualLeaveDays")}),g.annualLeaveDays&&(0,t.jsx)(_.default,{errors:g.annualLeaveDays.types,id:"annualLeaveDaysErrors"})]}),(0,t.jsxs)(C.default,{legend:"Was this shared parental leave?",children:[(0,t.jsx)(A.default,{describedBy:g.wasSharedParentalLeave&&"wasSharedParentalLeaveErrors",id:"wasSharedParentalLeaveYes",label:"Yes",value:"yes",...f("wasSharedParentalLeave")}),(0,t.jsx)(A.default,{describedBy:g.wasSharedParentalLeave&&"wasSharedParentalLeaveErrors",id:"wasSharedParentalLeaveNo",label:"No",value:"no",...f("wasSharedParentalLeave")}),g.wasSharedParentalLeave&&(0,t.jsx)(_.default,{errors:g.wasSharedParentalLeave.types,id:"wasSharedParentalLeaveErrors"})]}),(0,t.jsxs)(C.default,{legend:"Does the grantholder need to extend the grant?",children:[(0,t.jsx)(A.default,{describedBy:g.shouldExtendGrant&&"shouldExtendGrantErrors",id:"shouldExtendGrantYes",label:"Yes",value:"yes",...f("shouldExtendGrant")}),(0,t.jsx)(A.default,{describedBy:g.shouldExtendGrant&&"shouldExtendGrantErrors",id:"shouldExtendGrantNo",label:"No",value:"no",...f("shouldExtendGrant")}),g.shouldExtendGrant&&(0,t.jsx)(_.default,{errors:g.shouldExtendGrant.types,id:"shouldExtendGrantErrors"})]}),"yes"===x&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(C.default,{legend:"Hours on return to work:",children:[(0,t.jsx)(A.default,{describedBy:g.hoursOnReturnToWork&&"hoursOnReturnToWorkErrors",id:"hoursOnReturnToWorkFull",label:"Full-time",value:"full",...f("hoursOnReturnToWork")}),(0,t.jsx)(A.default,{describedBy:g.hoursOnReturnToWork&&"hoursOnReturnToWorkErrors",id:"hoursOnReturnToWorkPart",label:"Part-time",value:"part",...f("hoursOnReturnToWork")}),g.hoursOnReturnToWork&&(0,t.jsx)(_.default,{errors:g.hoursOnReturnToWork.types,id:"hoursOnReturnWorkErrors"})]}),"part"===y&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullTimeEquivalent",text:"Tell us the full-time equivalent (FTE)"}),(0,t.jsx)(H.default,{describedBy:g.fullTimeEquivalent&&"fullTimeEquivalentErrors",id:"fullTimeEquivalent",isInvalid:!!g.fullTimeEquivalent,isRequired:!0,...f("fullTimeEquivalent")}),g.fullTimeEquivalent&&(0,t.jsx)(_.default,{errors:g.fullTimeEquivalent.types,id:"fullTimeEquivalentErrors"})]})]}),"yes"===w&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"lengthOfExtension",text:"For how long do they need to extend the grant"}),(0,t.jsx)(H.default,{describedBy:g.lengthOfExtension&&"lengthOfExtensionErrors",id:"lengthOfExtension",isInvalid:!!g.lengthOfExtension,isRequired:!0,...f("lengthOfExtension")}),g.lengthOfExtension&&(0,t.jsx)(_.default,{errors:g.lengthOfExtension.types,id:"lengthOfExtensionErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"justificationForExtension",text:"Justify why they need to extend the grant"}),(0,t.jsx)($.default,{describedBy:g.justificationForExtension&&"justificationForExtensionErrors",id:"justificationForExtension",isInvalid:!!g.justificationForExtension,isRequired:!0,...f("justificationForExtension")}),g.justificationForExtension&&(0,t.jsx)(_.default,{errors:g.justificationForExtension.types,id:"justificationForExtensionErrors"})]})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullNameSubmitter",text:"Full name of the person filling in this form"}),(0,t.jsx)(H.default,{autoComplete:"name",describedBy:g.fullNameSubmitter&&"fullNameSubmitterErrors",id:"fullNameSubmitter",isInvalid:!!g.fullNameSubmitter,isRequired:!0,spellCheck:"false",...f("fullNameSubmitter")}),g.fullNameSubmitter&&(0,t.jsx)(_.default,{errors:g.fullNameSubmitter.types,id:"fullNameSubmitterErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"emailAddressSubmitter",text:"Email address for the person filling in this form"}),(0,t.jsx)(H.default,{autoComplete:"email",describedBy:g.emailAddressSubmitter?"emailAddressSubmitterHint emailAddressSubmitterErrors":"emailAddressSubmitterHint",id:"emailAddressSubmitter",isInvalid:!!g.emailAddressSubmitter,isRequired:!0,spellCheck:"false",type:"email",...f("emailAddressSubmitter")}),(0,t.jsx)(G.default,{id:"emailAddressSubmitterHint",children:(0,t.jsx)("p",{children:"Weâll use this to contact you."})}),g.emailAddressSubmitter&&(0,t.jsx)(_.default,{errors:g.emailAddressSubmitter.types,id:"emailAddressSubmitterErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsxs)("p",{children:["We respect your privacy and will only share personal data for purposes as described
91in our"," ",(0,t.jsx)(I.default,{href:"/who-we-are/privacy-and-terms",children:"terms and conditions"}),"."]})}),(0,t.jsxs)(E.default,{className:"c-form-field--captcha",children:[s&&(0,t.jsx)(N.Controller,{control:d,defaultValue:"",name:"g-recaptcha-response",render:({field:{onBlur:e,onChange:a}})=>(0,t.jsx)(q.default,{onBlur:e,onChange:e=>{let t=new Date().getTime().toString();r(t),p("captchaTimestamp",t,{shouldValidate:!0}),a(e)},onExpired:()=>a(""),sitekey:s})}),g["g-recaptcha-response"]&&(0,t.jsx)(_.default,{errors:g["g-recaptcha-response"].types,id:"captchaErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{type:"submit",disabled:b,children:b?"Submitting...":"Submit"})}),!v&&j?.length>0&&(0,t.jsx)(E.default,{children:(0,t.jsx)(_.default,{errors:j,id:"webToCaseSubmissionErrors"})}),(0,t.jsx)("p",{children:"Youâll receive an email confirming the information youâve given us."})]})]})},{}),7:(0,t.jsx)(()=>{let e=(0,a.useMemo)(()=>(0,T.object)({articleTitle:(0,T.string)().required("Enter an article title for which you are seeking the ND exception"),captcha:(0,T.string)().required("The answer you entered for the CAPTCHA was not correct. Please try again"),emailAddress:(0,T.string)().email("Enter an email address in the correct format, like [email protected]").required("Please provide a valid email address"),exceptionReason:(0,T.string)().required("Enter why you are seeking this exception"),fullName:(0,T.string)().trim().required("Please write your name"),grantRefNumber:(0,T.string)().required("Enter a grant reference number in the correct format"),journalName:(0,T.string)().required("Enter a name of journal which is considering publishing this research"),otherFunders:(0,T.string)().required("Enter the name of the other funder(s) and the relevant grant numbers")}),[]),r=(0,k.useYupValidationResolver)({schema:e}),{NEXT_PUBLIC_GOOGLE_RECAPTCHA_SITE_KEY:n}=(0,O.getBuildTimeConfig)(),i=(0,a.useRef)(null),{clearErrors:s,control:l,handleSubmit:o,register:d,formState:{errors:u}}=(0,N.useForm)({mode:"onTouched",resolver:r}),{hasSent:m,sendEmail:f,submissionEmailErrors:h}=Q();(0,a.useEffect)(()=>{m&&(0,D.default)(i)},[m]);let p=async e=>{s(),f({content:e,subject:`Applying for an No-Derivatives (ND) Licence exception - ${e.fullName}`,to:"[email protected]",type:"openAccessNoDerivativesEmail"})};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:i}),(0,t.jsx)("div",{role:"status",children:m&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Y.default,{title:"Thank you"}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacingXl",children:"Your form has been submitted. A member of the Open Access team will respond within 5 working days."})]})}),!m&&(0,t.jsxs)("form",{noValidate:!0,onSubmit:o(p),className:"c-form",children:[(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullName",text:"Name"}),(0,t.jsx)(H.default,{autoComplete:"name",describedBy:u.fullName&&"fullNameErrors",id:"fullName",isInvalid:!!u.fullName,isRequired:!0,spellCheck:"false",...d("fullName")}),u.fullName&&(0,t.jsx)(_.default,{errors:u.fullName.types,id:"fullNameErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"emailAddress",text:"Email address"}),(0,t.jsx)(H.default,{autoComplete:"email",describedBy:u.emailAddress&&"emailAddressErrors",id:"emailAddress",isInvalid:!!u.emailAddress,isRequired:!0,spellCheck:"false",type:"email",...d("emailAddress")}),u.emailAddress&&(0,t.jsx)(_.default,{errors:u.emailAddress.types,id:"emailAddressErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"grantRefNumber",text:"Wellcome grant number"}),(0,t.jsx)(H.default,{describedBy:u.grantRefNumber&&"grantRefNumberErrors",id:"grantRefNumber",isInvalid:!!u.grantRefNumber,isRequired:!0,...d("grantRefNumber")}),u.grantRefNumber&&(0,t.jsx)(_.default,{errors:u.grantRefNumber.types,id:"grantRefNumberErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"articleTitle",text:"Article title for which you are seeking the ND exception"}),(0,t.jsx)(H.default,{describedBy:u.articleTitle&&"articleTitleErrors",id:"articleTitle",isInvalid:!!u.articleTitle,isRequired:!0,...d("articleTitle")}),u.articleTitle&&(0,t.jsx)(_.default,{errors:u.articleTitle.types,id:"articleTitleErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"journalName",text:"Name of journal which is considering publishing this research"}),(0,t.jsx)(H.default,{describedBy:u.journalName&&"journalNameErrors",id:"journalName",isInvalid:!!u.j
91ournalName,isRequired:!0,...d("journalName")}),u.journalName&&(0,t.jsx)(_.default,{errors:u.journalName.types,id:"journalNameErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"exceptionReason",text:"Please tell us why you are seeking this exception"}),(0,t.jsx)(H.default,{describedBy:u.exceptionReason&&"exceptionReasonErrors",id:"exceptionReason",isInvalid:!!u.exceptionReason,isRequired:!0,...d("exceptionReason")}),u.exceptionReason&&(0,t.jsx)(_.default,{errors:u.exceptionReason.types,id:"exceptionReasonErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"otherFunders",text:"If this work is co-funded, please let us know the name of the other funder(s) and the relevant grant numbers"}),(0,t.jsx)(G.default,{id:"otherFundersHint",children:(0,t.jsx)("p",{children:"If any of the funders are part of cOAlition S you agree to us passing this information to the funder stated to support their compliance monitoring."})}),(0,t.jsx)(H.default,{describedBy:u.otherFunders?"otherFundersHint otherFundersErrors":"otherFundersHint",id:"otherFunders",isInvalid:!!u.otherFunders,isRequired:!0,...d("otherFunders")}),u.otherFunders&&(0,t.jsx)(_.default,{errors:u.otherFunders.types,id:"otherFundersErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Wellcome collects your personal information (name, email address and grant number(s)) via this form solely for the purposes of considering this request and annotating your grant record when a No-Derivatives Licence has been granted. We may notify repositories such as Europe PMC that such a No-Derivatives Licence can be applied to any manuscripts you submit via the Europe PMC submission system."}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"This information is collected and processed in accordance with applicable data protection laws."}),(0,t.jsxs)("p",{className:"tw-mb-wdsSpacing200",children:["For further information on how your information is processed, please see our"," ",(0,t.jsx)(I.default,{href:"/who-we-are/privacy-and-terms",children:"Privacy Notice"}),"."]}),(0,t.jsxs)("p",{className:"tw-mb-wdsSpacing200",children:["If you have any questions, please contact"," ",(0,t.jsx)(I.default,{href:"mailto:[email protected]",children:"[email protected]"}),"."]})]}),(0,t.jsxs)(E.default,{className:"c-form-field--captcha",children:[n&&(0,t.jsx)(N.Controller,{control:l,defaultValue:"",name:"captcha",render:({field:{onBlur:e,onChange:a}})=>(0,t.jsx)(q.default,{onBlur:e,onChange:a,onExpired:()=>a(""),sitekey:n})}),u.captcha&&(0,t.jsx)(_.default,{errors:u.captcha.types,id:"captchaErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{type:"submit",disabled:m,children:m?"Submitting...":"Submit"})}),h?.length>0&&(0,t.jsx)(E.default,{children:(0,t.jsx)(_.default,{errors:h,id:"submissionEmailErrors"})})]})]})},{}),8:(0,t.jsx)(()=>{let[e,r]=(0,a.useState)([]),n=/^[^\d]*$/,i=/^[0-9]{6}\/[a-zA-Z]\/[0-9]{2}\/[a-zA-Z]$/,s=(0,a.useMemo)(()=>(0,T.object)({grantType:(0,T.string)().required("Select grant type."),isJointGrant:(0,T.string)().required("Select no if your grant is only funded by Wellcome."),isNonUKOrg:(0,T.string)(),fullName:(0,T.string)().trim().matches(n,"The full name must only include letters a to z, hyphens, spaces and apostrophes.").required("Enter your full name."),emailAddress:(0,T.string)().trim().email("Enter an email address in the correct format, like [email protected].").required("Enter your email address."),grantRefNumber:(0,T.string)().trim().required("Enter the grant reference number.").matches(i,{message:"The grant reference number must be in the correct format, like 012345/Z/19/Z.",excludeEmptyString:!0}),dayOfTransfer:(0,T.date)().transform(tY).typeError("This does not look like a valid date.").required("Enter the date when you would like to transfer."),proposedOrganisation:(0,T.string)().trim().required("Enter the organisation you would like to transfer to."),isUsingAnimals:(0,T.string)().required("Select yes if your project uses non-human primates, cats, dogs or equidae."),isContinueUsingAnimals:(0,T.string)().when("isUsingAnimals",{is:"true",then:e=>
91e.required("Select yes if you will continue to use animals at your proposed organisation.")}),hasSalariedPosition:(0,T.bool)(),needsSalarySupplementation:(0,T.bool)(),hasChangedCurrency:(0,T.string)().required("Select yes if you need to change the currency in which we award your grant."),currency:(0,T.string)().when("hasChangedCurrency",{is:"true",then:e=>e.matches(n,"The requested currency must only include letters or symbols.").required("Enter the currency you would like to use.")}),localCurrency:(0,T.string)().when("hasChangedCurrency",{is:"true",then:e=>e.required("Select yes if this is the standard currency used in the country of your proposed organisation.")}),currencyExplanation:(0,T.string)().trim().when("localCurrency",{is:"false",then:e=>e.required("Enter the reason for the choice of currency.")}),completeResearchExplanation:(0,T.string)().trim().required("Enter explanation on how you can complete your research at the proposed organisation."),fileUploads:(0,T.array)().when("grantType",{is:e=>"fellowship"===t8(e),then:e=>e.required("Please upload four letters of support agreeing to your transfer."),otherwise:e=>e.required("Please upload two letters of support agreeing to your transfer.")}),wasOrganisationNotified:(0,T.bool)().isTrue("Please confirm that your current organisation has been notified.").required("Please confirm that your current organisation has been notified.")}),[]),l=(0,k.useYupValidationResolver)({schema:s}),d=(0,a.useRef)(null),{control:m,handleSubmit:f,register:h,watch:p,formState:{errors:g}}=(0,N.useForm)({mode:"onTouched",resolver:l}),x=p("grantType"),y=p("isJointGrant"),w=p("isNonUKOrg"),b=p("isUsingAnimals"),v=p("isContinueUsingAnimals"),j=p("needsSalarySupplementation"),S=p("hasChangedCurrency"),R=p("localCurrency"),F="Sir Henry Dale Fellowship"===x,L=F&&"true"===y,O=L&&"false"===w,P="fellowship"===t8(x)||F,q="None of these"===x,I=!x,{isSubmitting:B,isSuccessful:M,submissionErrors:W,createTicket:Y}=(()=>{let[e,t]=(0,a.useState)(void 0),[r,n]=(0,a.useState)(!1),[i,s]=(0,a.useState)(!1),[l,o]=(0,a.useState)("");return(0,a.useEffect)(()=>{r&&(async()=>{try{s(!1),o("");let t=await (0,X.default)("/api/crm/create-ticket",{body:JSON.stringify({ticket:e}),headers:{"Content-Type":"application/json",Accept:"application/json"},method:"POST"}),a=await t.json();if(a.error||201!==t.status){if(a.error?.type==="rate-limit")throw Error(a.error.message);throw Error("Error when submitting the form. Please ensure you have correctly filled in all the fields. If the problem persists, please try again later or contact us.")}s(!0)}catch(e){s(!1),o(e.message)}finally{n(!1)}})()},[r]),{isSubmitting:r,isSuccessful:i,createTicket:e=>{t(e),n(!0)},submissionErrors:l}})(),{isRemoving:K,isUploading:z,removeFile:Q,triggeringFileInput:J,uploadFile:Z,uploadedFileData:er,uploadErrors:en}=(()=>{let[e,t]=(0,a.useState)(void 0),[r,n]=(0,a.useState)(void 0),[i,s]=(0,a.useState)(""),[l,o]=(0,a.useState)(!1),[d,c]=(0,a.useState)(!1),[u,m]=(0,a.useState)(!1),[f,h]=(0,a.useState)(""),[p,g]=(0,a.useState)(""),[x,y]=(0,a.useState)(void 0);return(0,a.useEffect)(()=>{d&&(async()=>{try{let t=e.get("file");if(t.size>3e6)throw Error("Uploaded files must be smaller than 3MB.");let a=await new Promise(e=>{let a=new FileReader;a.onloadend=()=>e(t2(a.result)),a.readAsBinaryString(t)});r.length>0&&r.forEach(e=>{if(e.hash===a)throw Error("You have already attached this file to the form.")}),m(!1),g(""),y({fileName:t.name,hash:a,hasCompletedUpload:!1,size:t.size,triggeringFileInput:f,uploadFailed:!1});let n=await (0,X.default)("/api/crm/upload-file",{body:e,headers:{Accept:"application/json"},method:"POST"}),i=await n.json();if(i.error||201!==n.status){if(i.error?.type==="rate-limit")throw Error(i.error.message);if(y({fileName:t.name,hash:a,hasCompletedUpload:!1,size:t.size,uploadFailed:!0}),0===t.size)throw Error("This file appears to contain no data. Please check the file and try again.");if(i.error?.message==="AttachmentUnprocessable")throw Error("Could not upload this file.");throw Error("Error when uploading the file. If the problem persists, please try again later or contact us.")}y({deleted:i.upload.deleted,expiresAt:i.upload.expiresAt,fileName:t.name,hash:a,hasCompletedUpload:!0,id:i.upload.id,size:t.size,token:i.upload.token,triggeringFileInput:f,uploadFailed:!1}),m(!0)}catch(e){m(!1),g(e.message)}finally{c(!1)}})()},[d,f]),(0,a.useEffect)(()=>{l&&(async()=>{try{await (0,X.default)(`/api/crm/remove-file/${i}`,{method:"DELETE"}),g(null)}catch(e){g(e.message)}finally{o(!1)}})()},[l]),{isRemoving:l,isUploading:d,isUploadSuccessful:u,removeFile:e=>{s(e),o(!0)},triggeringFileInput:f,uploadFile:(e,a,r)=>{n(a),h(r),t(e),c(!0)},uploadedFileData:x,uploadErrors:p}})();(0,a.useEffect)(()=>{!B&&M&&(0,D.default)(d)},[B,M]);let ei=async e=>{Y({recipient:"[email protected]",subject:`${e.grantType} - Organisational Transfers Form`,comment:{body:` 92 Grant type: ${e.grantType} 93 94 95 Is grant jointly funded by Wellcome and another organisation: ${t4(e.isJointGrant)} 96 97 98 ${e.isNonUKOrg?`Is the proposed organisation based outside the UK: ${t4(e.isNonUKOrg)} 99 100`:"\n\n"} 101 Full name: ${e.fullName} 102 103 104 Email address: ${e.emailAddress} 105 106 107 Grant reference number: ${e.grantRefNumber} 108 109 110 Proposed date of transfer: ${((e,t="dd-MM-yyyy")=>(0,t5.format)(new Date(e),t))(e.dayOfTransfer)} 111 112 113 Proposed organisation: ${e.proposedOrganisation} 114 115 116 Project uses animals: ${t4(e.isUsingAnimals)} 117 118 119 ${e.isContinueUsingAnimals?`Animals will still be used at proposed organisation: ${t4(e.isContinueUsingAnimals)} 120 121`:"\n\n"} 122 ${t4(e.hasSalariedPosition)?`Have a permanent salaried position at the proposed host organisation: ${t4(e.hasSalariedPosition)} 123 124`:"\n\n"} 125 ${t4(e.needsSalarySupplementation)?`Needs salary supplementation following transfer: ${t4(e.needsSalarySupplementation)} 126 127`:"\n\n"} 128 Need to change the currency in which we award this grant: ${t4(e.hasChangedCurrency)} 129 130\ 131 ${e.currency?`Requested currency: ${e.currency} 132 133`:"\n\n"}
134 ${e.localCurrency?`Local currency for country of organisation: ${t4(e.localCurrency)} 135 136`:"\n\n"} 137 ${e.currencyExplanation?`Explanation for the currency request: ${e.currencyExplanation} 138 139`:"\n\n"} 140 Explanation on how can complete research: ${e.completeResearchExplanation} 141 142 143 Current organisation has been notified: ${t4(e.wasOrganisationNotified)} 144 `,uploads:e.fileUploads},requester:{name:e.fullName,email:e.emailAddress}})},es=(0,a.useRef)(null),el=t=>{let a=t.target.files;if(a[0]){let r=new FormData;r.append("file",a[0]),Z(r,e,t.target.name),g.fileUploads=null}t.target.value=null},eo=t=>{let{hash:a}=t.currentTarget.closest("button").dataset,n=e.slice(0),i=n.findIndex(e=>e.hash===a);i>-1&&(Q(n[i].token),n.splice(i,1),r(n))};(0,a.useEffect)(()=>{if(er){let t=e.slice(0),a=t.findIndex(e=>e.hash===er.hash);a>-1?er.uploadFailed?t.splice(a,1):t[a]=er:t.push(er),r(t)}},[er]);let ed=t=>e.filter(e=>e.triggeringFileInput===t).length,ec=ed("uploadLetters"),eu=ed("uploadSalaryLetters"),em=e.length>0?"Upload another letter":"Upload letter";return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(V.default,{ref:d}),(0,t.jsx)(ea,{shouldShowMessage:M}),!M&&(0,t.jsxs)("form",{className:"c-form",onSubmit:f(ei),noValidate:!0,children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"All fields are mandatory."}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(N.Controller,{control:m,defaultValue:"",name:"grantType",render:({field:{value:e,onChange:a}})=>(0,t.jsx)(tZ,{id:"grantType",items:t6,label:"Grant type",onChange:e=>a(e),resetOption:"None of these",value:e})}),g.grantType&&(0,t.jsx)(_.default,{errors:g.grantType.types,id:"grantTypeErrors"})]}),!q&&(0,t.jsxs)(C.default,{isDisabled:!x,legend:"Is your grant jointly funded by Wellcome and another organisation?",children:[(0,t.jsx)(A.default,{describedBy:g.isJointGrant&&"isJointGrantErrors",id:"isJointGrantYes",isDisabled:!x,label:"Yes",value:"true",...h("isJointGrant")}),(0,t.jsx)(A.default,{describedBy:g.isJointGrant&&"isJointGrantErrors",id:"isJointGrantNo",isDisabled:!x,label:"No",value:"false",...h("isJointGrant")}),g.isJointGrant&&(0,t.jsx)(_.default,{errors:g.isJointGrant.types,id:"isJointGrantErrors"})]}),L&&(0,t.jsxs)(C.default,{legend:"Is the proposed organisation based outside the UK?",children:[(0,t.jsx)(A.default,{describedBy:g.isNonUKOrg&&"isNonUKOrgErrors",id:"isNonUKOrgYes",label:"Yes",value:"true",...h("isNonUKOrg")}),(0,t.jsx)(A.default,{describedBy:g.isNonUKOrg&&"isNonUKOrgErrors",id:"isNonUKOrgNo",label:"No",value:"false",...h("isNonUKOrg")}),g.isNonUKOrg&&(0,t.jsx)(_.default,{errors:g.isNonUKOrg.types,id:"isNonUKOrgErrors"})]}),q||"true"===w||"true"===y&&!F?(0,t.jsx)(E.default,{children:(0,t.jsx)("div",{"aria-live":"polite",children:"true"===w?(0,t.jsxs)("p",{children:["For this type of organisation transfer please"," ",(0,t.jsx)(o.default,{href:"/who-we-are/contact-us/funding-enquiry",children:"contact us"}),"."]}):(0,t.jsxs)("p",{children:["Rules are different for"," ",q?"others":"jointly funded"," grants so please"," ",(0,t.jsx)(o.default,{href:"/who-we-are/contact-us/funding-enquiry",children:"contact us"}),"."]})})}):(O||"false"===y||!F)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(E.default,{children:[(0,t.jsxs)("div",{className:x?"c-file-input__text":"c-file-input__text is-disabled",children:[I&&(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"If your grant is a fellowship, you will need to upload four letters of support agreeing to the transfer from the following people:"}),P&&(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Upload four letters of support agreeing to the transfer from the following people:"}),(I||P)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"head of department at your current organisation"}),(0,t.jsx)("li",{children:"head of department at your proposed organisation"}),(0,t.jsx)("li",{children:"sponsor or supervisor at your current organisation"}),(0,t.jsx)("li",{children:"sponsor or supervisor at your proposed organisation."})]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"If your head of department is also your sponsor or supervisor, you only need to upload one letter from them rather than two."})]}),I&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"If your salary is going to increase due to a promotion or regrading, you will also need to upload a letter from the research office at the proposed organisation confirming:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"your proposed salary, including a breakdown of costs, for example basic salary, employerâs contributions and pension scheme costs"}),(0,t.jsx)("li",{children:"that the organisationâs standard process was followed for determining the salary."})]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"If your grant is not a fellowship, you will need to upload two letters of support agreeing to your transfer from the following people:"})]}),!P&&(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Upload two letters of support agreeing to your transfer from the following people:"}),(I||!P)&&(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"head of department at your current organisation"}),(0,t.jsx)("li",{children:"head of department at your proposed organisation."})]})]}),(0,t.jsx)(t1,{accept:[".doc",".docx","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document",".pdf","application/pdf",".txt","text/plain","image/*","zip","application/zip","application/x-zip","application/x-zip-compressed"],describedBy:`uploadLettersHint ${g.fileUploads?"zendeskFileUploadErrors":""}`,icon:"iconActionUpload",iconPlacementSwitch:!0,id:"uploadLetters",isInvalid:!!g.fileUploads,isRequired:!1,multiple:!1,name:"uploadLetters",handleChange:el,ref:es,variant:"secondary",isDisabled:!x||z||ec>=10,children:z?"Uploading...":em}),(0,t.jsx)(G.default,{id:"uploadLettersHint",children:(0,t.jsxs)("ul",{className:"tw-list-none",children:[(0,t.jsx)("li",{children:"You can upload .doc, .pdf, .zip, text or image files."}),(0,t.jsx)("li",{children:"The maximum file size for each uploaded item is 3MB."}),(0,t.jsx)("li",{children:"You can upload up to 10 separate files."})]})}),("uploadLetters"===J&&en?.length>0||g.fileUploads)&&(0,t.jsx)(_.default,{errors:g.fileUploads?.types||en,id:"zendeskFileUploadErrors"}),(0,t.jsx)(u.default,{role:"status",wrapperAs:"div",children:e&&(0,t.jsx)("p",{children:`You have ${ec} file${1===ec?"":"s"} uploaded.`})}),!!e?.length&&(0,t.jsx)("ul",{className:"c-files-uploaded-feedback tw-list-none",children:e.map((e,r)=>(0,t.jsx)(a.Fragment,{children:"uploadLetters"===e.triggeringFileInput&&(0,t.jsxs)("li",{className:"c-files-uploaded-feedback__file",children:[e.hasCompletedUpload?(0,t.jsx)(t0.default,{className:"c-files-uploaded-feedback__icon",name:"iconActionTickCircle"}):(0,t.jsx)(t0.default,{className:"c-files-uploaded-feedback__icon c-files-uploaded-feedback__icon--animated",name:"iconActionUpdate"}),(0,t.jsxs)("span",{className:"c-files-uploaded-feedback__text",children:[e.fileName,(0,t.jsx)("span",{className:"c-files-uploaded-feedback__text--filesize",children:(0,t3.default)(parseInt(e.size,10))}),e.hasCompletedUpload&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(c.default,{className:"c-files-uploaded-feedback__remove",type:"button",variant:"link",onClick:eo,"data-hash":e.hash,children:["Remove",(0,t.jsx)(u.default,{children:e.fileName})]}),(0,t.jsx)("input",{id:`fileUploads[${r}]`,type:"hidden",defaultValue:e.token,...h(`fileUploads[${r}]`)},e.token)]})]})]})},e.hash))})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"fullName",isDisabled:!x,text:"Full name"}),(0,t.jsx)(H.default,{autoComplete:"name",describedBy:g.fullName&&"fullNameErrors",id:"fullName",isDisabled:!x,isInvalid:!!g.fullName,isRequired:!0,spellCheck:"false",...h("fullName")}
144),g.fullName&&(0,t.jsx)(_.default,{errors:g.fullName.types,id:"fullNameErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"emailAddress",isDisabled:!x,text:"Email address"}),(0,t.jsx)(H.default,{autoComplete:"email",describedBy:g.emailAddress&&"emailAddressErrors",id:"emailAddress",isDisabled:!x,isInvalid:!!g.emailAddress,isRequired:!0,spellCheck:"false",type:"email",...h("emailAddress")}),g.emailAddress&&(0,t.jsx)(_.default,{errors:g.emailAddress.types,id:"emailAddressErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"grantRefNumber",isDisabled:!x,text:"Grant reference number"}),(0,t.jsx)(H.default,{describedBy:g.grantRefNumber?"grantRefNumberHint grantRefNumberErrors":"grantRefNumberHint",id:"grantRefNumber",isDisabled:!x,isInvalid:!!g.grantRefNumber,isRequired:!0,...h("grantRefNumber")}),(0,t.jsx)(G.default,{id:"grantRefNumberHint",children:(0,t.jsx)("p",{children:"For example 012345/Z/19/Z"})}),g.grantRefNumber&&(0,t.jsx)(_.default,{errors:g.grantRefNumber.types,id:"grantRefNumberErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"dayOfTransfer",isDisabled:!x,text:"Proposed date of transfer"}),(0,t.jsx)(et,{describedBy:g.dayOfTransfer?"dayOfTransferHint dayOfTransferErrors":"dayOfTransferHint",id:"dayOfTransfer",isDisabled:!x,isInvalid:!!g.dayOfTransfer,isRequired:!0,pattern:`${ee.DATE_FORMAT_REGEX}`,...h("dayOfTransfer")}),(0,t.jsx)(G.default,{id:"dayOfTransferHint",children:(0,t.jsxs)("p",{children:[(0,t.jsx)(u.default,{children:"Use the format "}),"dd/mm/yyyy"]})}),g.dayOfTransfer&&(0,t.jsx)(_.default,{errors:g.dayOfTransfer.types,id:"dayOfTransferErrors"})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"proposedOrganisation",isDisabled:!x,text:"Proposed organisation"}),(0,t.jsx)(H.default,{describedBy:g.proposedOrganisation&&"proposedOrganisationErrors",id:"proposedOrganisation",isDisabled:!x,isInvalid:!!g.proposedOrganisation,isRequired:!0,...h("proposedOrganisation")}),g.proposedOrganisation&&(0,t.jsx)(_.default,{errors:g.proposedOrganisation.types,id:"proposedOrganisationErrors"})]}),(0,t.jsxs)(C.default,{isDisabled:!x,legend:"Does your project use non-human primates, cats, dogs or equidae?",children:[(0,t.jsx)(A.default,{describedBy:g.isUsingAnimals&&"isUsingAnimalsErrors",id:"isUsingAnimalsYes",isDisabled:!x,label:"Yes",value:"true",...h("isUsingAnimals")}),(0,t.jsx)(A.default,{describedBy:g.isUsingAnimals&&"isUsingAnimalsErrors",id:"isUsingAnimalsNo",isDisabled:!x,label:"No",value:"false",...h("isUsingAnimals")}),g.isUsingAnimals&&(0,t.jsx)(_.default,{errors:g.isUsingAnimals.types,id:"isUsingAnimalsErrors"})]}),"true"===b&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)(C.default,{legend:"Will you continue to use these at your proposed organisation?",children:[(0,t.jsx)(A.default,{describedBy:g.isContinueUsingAnimals?"isContinueUsingAnimalsHint isContinueUsingAnimalsErrors":"isContinueUsingAnimalsHint",id:"isContinueUsingAnimalsYes",label:"Yes, animals are still being used",value:"true",...h("isContinueUsingAnimals")}),(0,t.jsx)(A.default,{describedBy:g.isContinueUsingAnimals&&"isContinueUsingAnimalsErrors",id:"isContinueUsingAnimalsNo",label:"No, all animal work has been completed",value:"false",...h("isContinueUsingAnimals")}),"true"===v&&(0,t.jsx)("div",{className:"tw-mt-wdsSpacing200",id:"isContinueUsingAnimalsHint",children:(0,t.jsx)("p",{children:"Your request will need to be assessed by the NC3Rs before we can finalise your transfer."})}),g.isContinueUsingAnimals&&(0,t.jsx)(_.default,{errors:g.isContinueUsingAnimals.types,id:"isContinueUsingAnimalsErrors"})]})}),P&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(E.default,{children:(0,t.jsx)(tK.default,{id:"hasSalariedPosition",label:"I will have a permanent salaried position at the proposed host organisation",...h("hasSalariedPosition")})}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(tK.default,{id:"needsSalarySupplementation",label:"I will need salary supplementation following transfer",...h("needsSalarySupplementation")}),j&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("p",{className:"tw-my-wdsSpacing200",children:["Requests will be granted at Wellcome's discretion and will only be considered if a fellow's salary has increased due to promotion or regrading."," "]}),(0,t.jsx)("p",{className:"tw-mb-wdsSpacing200",children:"Upload a letter from the research office at the proposed organisation confirming:"}),(0,t.jsxs)("ul",{className:"tw-mb-wdsSpacing200 tw-ml-wdsSpacing400",children:[(0,t.jsx)("li",{children:"your proposed salary, including a breakdown of costs, for example basic salary, employerâs contributions and pension scheme costs"}),(0,t.jsx)("li",{children:"that the organisationâs standard process was followed for determining the salary."})]})]})]})]}),j&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(t1,{accept:[".doc",".docx","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document",".pdf","application/pdf",".txt","text/plain","image/*","zip","application/zip","application/x-zip","application/x-zip-compressed"],describedBy:`uploadSalaryLettersHint ${g.fileUploads?"zendeskSalaryFileUploadErrors":""}`,icon:"iconActionUpload",iconPlacementSwitch:!0,id:"uploadSalaryLetters",isInvalid:!!g.fileUploads,isRequired:!1,multiple:!1,name:"uploadSalaryLetters",handleChange:el,ref:es,variant:"secondary",isDisabled:!x||z||eu>=3,children:z?"Uploading...":em}),(0,t.jsx)(G.default,{id:"uploadSalaryLettersHint",children:(0,t.jsxs)("ul",{className:"tw-list-none",children:[(0,t.jsx)("li",{children:"You can upload .doc, .pdf, .zip, text or image files."}),(0,t.jsx)("li",{children:"The maximum file size for each uploaded item is 3MB."}),(0,t.jsx)("li",{role:"status",children:eu>=3&&(0,t.jsx)(t.Fragment,{children:"You can upload up to 3 separate files."})})]})}),("uploadSalaryLetters"===J&&en?.length>0||g.fileUploads)&&(0,t.jsx)(_.default,{errors:g.fileUploads?.types||en,id:"zendeskSalaryFileUploadErrors"}),(0,t.jsx)(u.default,{role:"status",wrapperAs:"div",children:e&&(0,t.jsx)("p",{children:`You have ${eu} file${1===eu?"":"s"} uploaded.`})}),!!e?.length&&(0,t.jsx)("ul",{className:"c-files-uploaded-feedback tw-list-none",children:e.map((e,r)=>(0,t.jsx)(a.Fragment,{children:"uploadSalaryLetters"===e.triggeringFileInput&&(0,t.jsxs)("li",{className:"c-files-uploaded-feedback__file",children:[e.hasCompletedUpload?(0,t.jsx)(t0.default,{className:"c-files-uploaded-feedback__icon",name:"iconActionTickCircle"}):(0,t.jsx)(t0.default,{className:"c-files-uploaded-feedback__icon c-files-uploaded-feedback__icon--animated",name:"iconActionUpdate"}),(0,t.jsxs)("span",{className:"c-files-uploaded-feedback__text",children:[e.fileName,(0,t.jsx)("span",{className:"c-files-uploaded-feedback__text--filesize",children:(0,t3.default)(parseInt(e.size,10))}),e.hasCompletedUpload&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(c.default,{type:"button",variant:"link",onClick:eo,"data-hash":e.hash,children:["Remove",(0,t.jsx)(u.default,{children:e.fileName})]}),(0,t.jsx)("input",{id:`fileUploads[${r}]`,type:"hidden",defaultValue:e.token,...h(`fileUploads[${r}]`)},e.token)]})]})]})},e.hash))})]}),(0,t.jsxs)(C.default,{isDisabled:!x,legend:"Do you need to change the currency in which we award your grant?",children:[(0,t.jsx)(A.default,{describedBy:g.hasChangedCurrency&&"hasChangedCurrencyErrors",id:"hasChangedCurrencyYes",isDisabled:!x,label:"Yes",value:"true",...h("hasChangedCurrency")}),(0,t.jsx)(A.default,{describedBy:g.hasChangedCurrency&&"hasChangedCurrencyErrors",id:"hasChangedCurrencyNo",isDisabled:!x,label:"No",value:"false",...h("hasChangedCurrency")}),g.hasChangedCurrency&&(0,t.jsx)(_.default,{errors:g.hasChangedCurrency.types,id:"hasChangedCurrencyErrors"})]}),"true"===S&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"currency",text:"Requested currency"}),(0,t.jsx)(H.default,{describedBy:g.currency&&"currencyErrors",id:"currency",isInvalid:!!g.currency,isRequired:!0,...h("currency")}),g.currency&&(0,t.jsx)(_.default,{errors:g.currency.types,id:"currencyErrors"})]}),(0,t.jsxs)(C.default,{isDisabled:!x,legend:"Is this the local currency for your proposed organisation?",children:[(0,t.jsx)(A.default,{describedBy:g.localCurrency&&"localCurrencyErrors",id:"localCurrencyYes",isDisabled:!x,label:"Yes, itâs the local currency",value:"true",...h("localCurrency")}),(0,t.jsx)(A.default,{describedBy:g.localCurrency&&"localCurrencyErrors",id:"localCurrencyNo",isDisabled:!x,label:"No, itâs not the local currency",value:"false",...h("localCurrency")}),g.localCurrency&&(0,t.jsx)(_.default,{errors:g.localCurrency.types,id:"localCurrencyErrors"})]}),"true"===S&&"false"===R&&(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"currencyExplanation",text:"Please explain why youâre asking for a different currency from what is standard in the country of your proposed organisation:"}),(0,t.jsx)($.default,{describedBy:g.currencyExplanation&&"currencyExplanationErrors",id:"currencyExplanation",isInvalid:!!g.currencyExplanation,isRequired:!0,...h("currencyExplanation")}),g.currencyExplanation&&(0,t.jsx)(_.default,{errors:g.currencyExplanation.types,id:"currencyExplanationErrors"})]})]}),(0,t.jsxs)(E.default,{children:[(0,t.jsx)(U.default,{htmlFor:"completeResearchExplanation",isDisabled:!x,text:"Explain how you can complete your research as well, or more effectively, at the proposed organisation (300 words maximum):"}),(0,t.jsx)($.default,{describedBy:g.completeResearchExplanation&&"completeResearchExplanationErrors",id:"completeResearchExplanation",isDisabled:!x,isInvalid:!!g.completeResearchExplanation,isRequired:!0,...h("completeResearchExplanation")}),g.completeResearchExplanation&&(0,t.jsx)(_.default,{errors:g.completeResearchExplanation.types,id:"completeResearchExplanationErrors"})]}),(0,t.jsxs)(C.default,{className:"c-form-field",isDisabled:!x,legend:"Current organisation has been notified",children:[(0,t.jsx)(tK.default,{describedBy:g.wasOrganisationNotified&&"wasOrganisationNotifiedErrors",id:"wasOrganisationNotified",isDisabled:!x,isInvalid:!!g.wasOrganisationNotified,isRequired:!0,label:"I confirm that I have discussed this transfer with the research office at my current organisation",...h("wasOrganisationNotified")}),g.wasOrganisationNotified&&(0,t.jsx)(_.default,{errors:g.wasOrganisationNotified.types,id:"wasOrganisationNotifiedErrors"})]}),(0,t.jsx)(E.default,{children:(0,t.jsx)(c.default,{type:"submit",disabled:!x||B||z||K,children:B?"Submitting...":"Submit"})}),!M&&W?.length>0&&(0,t.jsx)(E.default,{children:(0,t.jsx)(_.default,{errors:W,id:"zendeskTicketSubmissionErrors"})})]})]})]})},{})},t9=({variant:e})=>(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:t7[e]})});e.i(130593);var ae=e.i(248347),at=e.i(528657);let aa=({className:e,country:a,institution:r,name:i,titleAs:s})=>{let l=(0,n.default)({[e]:e});return(0,t.jsxs)("div",{className:l,itemScope:!0,itemType:"http://schema.org/Person",children:[i&&(0,t.jsx)(ae.default,{itemProp:"name",spacing:"tw-mb-0",titleAs:s,variant:"large",children:(0,t.jsx)("span",{dangerouslySetInnerHTML:{__html:(0,at.default)(i)}})}),(r||a)&&(0,t.jsxs)("p",{className:"tw-text-wdsNeutral-60",itemProp:"worksFor",children:[r&&(0,t.jsx)("span",{dangerouslySetInnerHTML:{__html:(0,at.default)(r)}}),r&&a&&(0,t.jsx)("span",{children:", "}),a&&(0,t.jsx)("span",{dangerouslySetInnerHTML:{__html:(0,at.default)(a)}})]})]})};e.i(687275);var ar=e.i(306414),an=e.i(892850);e.i(978861);var ai=e.i(715832);e.i(180589);var as=e.i(444962),al=e.i(891236),ao=e.i(50053);let ad=({data:e})=>(0,t.jsx)(as.default,{galleryId:e[0].id,hasFixedWidth:!0,children:e?.map((a,r)=>
144{if(a?.__typename==="ParagraphSectionInfo")return(0,t.jsx)(al.CarouselItem,{styleVariant:"opaque",children:(0,t.jsxs)(W.default,{variant:a?.infoBoxStyling==="reports_carousel"?"reports_carousel":"carousel",children:[(0,ao.default)(a.contentSlicesRef),(0,t.jsx)("span",{className:"c-info-box--carousel__counter tw-mt-wdsSpacingSm tw-text-wdsF-3 tw-font-bold print:!tw-mt-0 print:!tw-hidden",children:`${r+1} of ${e.length}`})]})},a.id)})});e.i(248621);var ac=e.i(658596);e.i(193834);var au=e.i(274743);let am=function(e){let t=(0,a.useRef)(null);return(0,a.useEffect)(()=>{t.current=e},[e]),t.current};var af=e.i(636296);let ah="On this page",ap=({backToTopHref:e="#top",backToTopText:r="Back to top",hasScrollyStory:s,isMinimal:l,links:d})=>{let{active:u}=(0,au.useActiveLinkContext)(),{inpageNavFocus:m,isInpageNavOpen:f,setInpageNavFocus:h,toggleInpageNav:p}=(0,au.useInpageNavContext)(),{minHeight:g,mediumMin:x}=(0,i.useBreakpointContext)(),y=(0,af.default)(),w=(0,a.useRef)(null),b=(0,a.useRef)(null),[v,j]=(0,a.useState)(u),N=am(v);(0,a.useEffect)(()=>{"inpage-btn-mobile"===m&&w?.current?.focus()},[m]),(0,a.useEffect)(()=>{let e=setTimeout(()=>{j(u)},500);return()=>{clearTimeout(e)}},[u]);let T=e=>{l&&g&&f&&(0,tz.isKeyValueSupported)(tz.default.ESCAPE,e)&&(p(!1),h("mobile-inpage-content-btn"))},S=({childLinks:e,id:a,title:r})=>{let i=(0,n.default)("c-inpage-nav__link",{"is-active":a===u,"o-animated-link-nested":x});return(0,t.jsxs)("li",{className:"c-inpage-nav__item",children:[(0,t.jsx)(o.default,{className:i,href:`#${a}`,onClick:()=>l&&p(!f),onKeyDown:T,children:(0,t.jsx)("span",{className:"c-inpage-nav__link-text o-animated-link-nested__child",children:r})}),e?.length>0&&(0,t.jsx)("ul",{className:"c-inpage-nav__list tw-list-none",children:e.map(S)})]},`anchor-link-${a}`)},k=(0,t.jsxs)(t.Fragment,{children:[s&&(0,t.jsxs)("div",{className:"tw-flex tw-items-center tw-border-t tw-border-wdsNeutral-20 tw-py-wdsSpacing050 md:tw-hidden",children:[(0,t.jsx)("span",{className:"tw-pr-wdsSpacing100 tw-font-semibold tw-text-wdsNeutral-70",children:"Read as"}),(0,t.jsx)(ac.default,{})]}),(0,t.jsxs)("ul",{className:"c-inpage-nav__list tw-list-none",children:[d.map(S),(0,t.jsx)("li",{className:"c-inpage-nav__item",children:(0,t.jsxs)(o.default,{className:(0,n.default)("c-inpage-nav__link c-inpage-nav__link--top",{"o-animated-link-nested":x}),href:e,onClick:()=>l&&p(!f),onKeyDown:e=>{l&&g&&!e.shiftKey&&"Tab"===e.key&&(e.preventDefault(),w?.current?.focus()),T(e)},ref:b,children:[(0,t.jsx)("span",{className:"c-inpage-nav__link-text o-animated-link-nested__child",children:r}),(0,t.jsx)(t0.default,{className:"c-btn__icon--right md:tw-hidden",name:"iconSmallDirectionalArrowUp"})]})})]})]});return(0,t.jsx)("nav",{"aria-label":"On this page",className:"c-inpage-nav",children:l?(0,t.jsxs)("div",{"aria-labelledby":"mobile-inpage-content-btn",className:"c-inpage-nav__accordion",id:"mobile-inpage-nav",children:[(0,t.jsx)("h2",{className:"tw-my-0",children:(0,t.jsx)(c.default,{"aria-expanded":f,className:"c-inpage-nav__button",icon:"iconActionPlus",iconPlacementSwitch:!0,id:"inpage-btn-mobile",onClick:()=>{p(!f),h("")},onKeyDown:e=>{l&&g&&e.shiftKey&&"Tab"===e.key&&(e.preventDefault(),f&&b.current?.focus()),T(e)},ref:w,variant:"unstyled",children:f?ah:u?d?.map(({id:e,title:a})=>(0,t.jsx)("span",{"aria-hidden":e!==u,className:(0,n.default)("c-inpage-nav__button-text",{"is-active":e===u,"is-prev":e===N&&N!==u,"is-scrolling-up":"up"===y&&e!==u,"is-scrolling-down":"down"===y&&e!==u}),children:a},e)):(0,t.jsx)(t.Fragment,{children:ah})})}),(0,t.jsx)("div",{"aria-labelledby":"inpage-btn-mobile",hidden:!f,children:k})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("h2",{className:"c-inpage-nav__title",children:ah}),k]})})},ag=({isVisible:e,title:r})=>{let{inpageNavFocus:n,isInpageNavOpen:i,setInpageNavFocus:s,setIsInPageNavVisible:l,toggleInpageNav:o}=(0,au.useInpageNavContext)(),d=(0,a.useRef)(null);return((0,a.useEffect)(()=>{"mobile-inpage-content-btn"===n&&d.current?.focus()},[n]),e)?(0,t.jsx)(c.default,{"aria-expanded":i,className:"c-inpage-mobile-btn c-accordion__button c-accordion__button--plus",icon:"iconActionPlus",iconPlacementSwitch:!0,id:"mobile-inpage-content-btn",onClick:()=>{o(e=>!e),l(!0),s("inpage-btn-mobile")},ref:d,variant:"unstyled",children:r||ah}):null};var ax=e.i(870270);
144e.i(695021);var ay=e.i(816499);e.i(548657);var aw=e.i(648962),ab=e.i(768705);e.i(690529);var av=e.i(382437);e.i(399833);var aj=e.i(634467);let aN={agree:"Agree",cancel:"Cancel",link:"Back"},aT=({body:e,buttons:r=[],className:i,onAccept:s,title:l})=>{let[o,d]=(0,a.useState)(!1),u=(0,n.default)("c-info-box c-modal",{[i]:i}),m=()=>{"function"==typeof s&&s(),d(!0)};return!o&&(0,t.jsx)(aj.default,{className:u,children:(0,t.jsx)(J.default,{children:(0,t.jsxs)(Z.GridColumn,{spanGroup:"center",children:[(0,t.jsx)(ae.default,{titleAs:"h2",variant:"large",children:l}),(0,t.jsx)(av.default,{children:e}),(0,t.jsx)("div",{className:"cookie-message__buttons",children:r&&r.map(({text:e,type:a,variant:r,href:n})=>(0,t.jsx)(c.default,{className:"c-modal__button",href:n||null,onClick:"agree"===a&&m,type:"button",variant:r,children:e||aN[a]},`modal-button-${a}`))})]})})})};e.i(828571);var aS=e.i(651837);e.i(768521);var ak=e.i(167595);e.i(930389);var aE=e.i(43338);e.i(419082);var a_=e.i(866175),aC=e.i(880769);e.i(517782);var aA=e.i(182925);let aR=({imageAlt:e="",imageCaption:a,imageCaptionLocation:r="bottom",imageCredit:i,imageModifications:s,imageLicence:l,imageTitle:o,imageSrc:d,metaLabel:c,standfirst:u,title:m,variant:f="light"})=>{let h=d&&(a||i||l||o||s),p=(0,n.default)({"tw-overflow-visible":"left"===r,"tw-overflow-hidden":"bottom"===r}),g=(0,n.default)("c-page-header tw-overflow-hidden",{"c-background--indigo-orange tw-pb-wdsSpacing2Xl md:tw-pb-[6.5em]":"dark"===f,"c-background--teal-green tw-pb-wdsSpacing2Xl md:tw-pb-[6.5rem]":"light"===f,"c-background--shaded":"shaded"===f}),x=(0,n.default)("tw-relative tw-z-low tw-grid tw-grid-cols-6 tw-gap-x-gutter sm:tw-grid-cols-12 md:tw-mx-[5%] md:tw-max-w-[84rem] xxl:tw-mx-auto print:tw-block",{"tw-pb-wdsSpacingLg md:tw-py-wdsSpacingLg":"left"===r,"md:tw-pt-wdsSpacingXl":"bottom"===r}),y=(0,n.default)("tw-pt-spacingXl tw-order-2 tw-col-span-full tw-mx-[5%] md:tw-order-1 md:tw-col-span-6 md:tw-mx-0 tw-mt-0",{"tw-flex tw-flex-col tw-justify-between":"left"===r,"tw-mb-wdsSpacingLg":"bottom"===r}),b=(0,n.default)("tw-col-span-full md:tw-col-span-6",{"tw-order-2 md:tw-order-1 md:tw-pt-wdsSpacingMd":"left"===r,"tw-pt-wdsSpacingXl md:tw-pt-0":!h}),v=(0,n.default)("tw-contents md:tw-order-2 md:tw-block",{"md:tw-col-span-6":"left"===r,"md:tw-col-span-5 md:tw-col-start-8":"bottom"===r});return(0,t.jsx)(an.GridOuterArea,{gridArea:"banner",className:p,children:(0,t.jsxs)("header",{className:g,children:[(0,t.jsxs)("div",{className:x,children:[(0,t.jsxs)("div",{className:y,children:[(0,t.jsxs)("div",{className:b,children:[c,(0,t.jsx)(a_.default,{title:m}),(0,t.jsx)(av.default,{className:"tw-mb-wdsSpacingLg tw-text-wdsF0",variant:"brandtext",children:u})]}),h&&"left"===r&&(0,t.jsx)("aside",{className:(0,n.default)("tw-order-1 tw-mb-wdsSpacing150 tw-justify-self-end md:tw-order-2 md:tw-mx-0 md:tw-mb-0"),id:"page-header-caption",children:(0,t.jsx)(aC.ImageBannerCaption,{caption:a,captionAs:"div",credit:i,modifications:s,licence:l,title:o,isGridExcluded:!0})})]}),(0,t.jsx)("div",{className:v,children:(0,t.jsxs)("div",{className:"tw-order-1 tw-col-span-full tw-w-full",children:[(0,t.jsx)("figure",{className:"tw-relative tw-aspect-5/3 tw-h-auto tw-w-full tw-overflow-hidden tw-bg-wdsNeutral-10 md:tw-aspect-3/2 md:tw-rounded-md","aria-describedby":"page-header-caption",children:(0,t.jsx)(w.default,{alt:e,className:"tw-h-full tw-w-full tw-object-cover tw-object-center",priority:!0,src:d,width:1440,height:600,sizes:"(min-width: 1024px) 50vw, 100vw"})}),h&&"bottom"===r&&(0,t.jsx)("div",{className:(0,n.default)("tw-mx-[5%] tw-my-wdsSpacingSm md:tw-mx-0"),id:"page-header-caption",children:(0,t.jsx)(aC.ImageBannerCaption,{caption:a,credit:i,modifications:s,title:o,licence:l,isGridExcluded:!0,hasKeyLine:!0})})]})})]}),("light"===f||"dark"===f)&&(0,t.jsx)(aA.EvergreenPageBannerWCrop,{className:"tw-absolute tw-bottom-0 tw-right-0 tw-w-[1600px] tw-translate-y-[925px] md:tw-left-1/2 md:tw-translate-x-[-55%]"})]})})},aF=({isShownWithTertiaryNavigation:e,title:a,standfirst:r})=>{let i=(0,n.default)("tw-relative tw-bg-wdsNeutral-10",{"tw-mb-wdsSpacing200 md:tw-mb-wdsSpacing800":!e});return(0,t.jsx)("header",{className:i,children:(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{className:"sm:tw-col-span-8",children:(0,t.jsxs)("div",{className:"tw-py-wdsSpacing200 sm:tw-py-wdsSpacing600 md:tw-py-wdsSpacing800",children:[(0,t.jsxs)("div",{className:"tw-flex tw-items-center tw-pb-wdsSpacing150 tw-text-wdsF-2 tw-font-medium tw-text-wdsNeutral-60",children:[(0,t.jsx)(t0.default,{className:"tw-mr-wdsSpacingXs",name:"iconSmallContentStackedGroup"}),(0,t.jsx)("span",{children:"Collection"})]}),(0,t.jsx)(a_.default,{title:a}),(0,t.jsx)(av.default,{variant:"brandtext",className:"tw-text-wdsF0",children:r})]})})})})},aL=({imageAlt:e="",imageHeight:a,imageCaption:r,imageCredit:n,imageModifications:s,imageLicence:l,imageTitle:o,imageSizes:d="(min-width: 1494px) 648px, (min-width: 1024px) 45vw, (min-width: 768px) 90vw, 100vw",imageSrc:c,imageWidth:u,metaLabel:m,standfirst:f,title:h})=>{let{mediumMax:p}
144=(0,i.useBreakpointContext)();return(0,t.jsx)("header",{className:"tw-mt-wdsSpacingXl",children:(0,t.jsxs)(J.default,{children:[(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("div",{className:"tw-mb-wdsSpacing400",children:[m,(0,t.jsx)(a_.default,{title:h}),(0,t.jsx)(av.default,{variant:"brandtext",children:f})]})}),c&&(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("figure",{className:"c-page-header-compact__image tw-mx-[-5.5%] tw-mb-wdsSpacing400 sm:tw-mx-0",children:[(0,t.jsx)(w.default,{alt:e,className:"o-image o-image--responsive sm:tw-rounded-md",height:a,itemProp:"image",priority:!0,sizes:d,src:c,width:u}),(r||n||l||s)&&(0,t.jsx)("div",{className:"tw-mx-[5%] tw-mt-wdsSpacing150 sm:tw-mx-0",children:(0,t.jsx)(aC.ImageBannerCaption,{caption:r,credit:n,modifications:s,title:o,licence:l,isGridExcluded:!0})})]})})]})})};var aO=e.i(106517);let aP=({fillColour:e=aO.theme.color.white,className:a})=>(0,t.jsx)("div",{className:(0,n.default)("tw-w-full tw-overflow-hidden",a),style:{height:"clamp(25px, 6vw, 90px)"},children:(0,t.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1530",height:"798",fill:"none",viewBox:"30 0 1530 798",className:"tw-w-full",preserveAspectRatio:"xMinYMin meet",children:(0,t.jsx)("path",{style:{fill:e},d:"M301.893 44.228c30.932-1.561 61.289-3.136 91.646-4.69 53.539-2.74 107.077-5.507 160.619-8.186 40.216-2.013 80.44-3.863 120.656-5.863 52.722-2.622 105.44-5.325 158.16-7.983 27.9-1.406 55.801-2.78 83.701-4.188 53.948-2.724 107.895-5.505 161.845-8.18 35.91-1.78 71.81-3.778 107.74-4.963 17.61-.581 35.28.441 52.93.81 2.22.046 4.43.53 6.82.834 1.14 19.052 2.26 37.762 3.44 57.349 11.06-.325 21.85-.551 32.63-.974 29.15-1.142 58.29-2.387 87.44-3.548 9.04-.36 18.07-.578 27.11-.866 1.23-.039 2.54-.413 3.67-.11 4.36 1.166 9.73 1.413 12.67 4.194 2.42 2.288 2.36 7.645 2.67 11.699.8 10.476 1.21 20.983 1.82 32.406 7.73-.388 15.16-.859 22.6-1.117 23-.797 45.99-1.701 68.99-2.044 3.18-.047 6.44 2.776 9.6 4.383 9.91 5.036 12.19 12.326 11.03 23.852-7.26 71.981-13.44 144.071-19.97 216.127-6.32 69.79-12.62 139.583-18.94 209.373-2.88 31.703-5.29 63.459-8.82 95.089-2.89 25.849-7.55 51.404-18.16 75.5-6.54 14.844-19.03 24.611-29.07 36.508-3.58 4.256-7.36 4.621-12.28 4.218-23.34-1.915-46.71-3.499-70.06-5.293-14.48-1.111-28.95-2.342-43.41-3.622-3.18-.281-4.7 1.045-6.89 3.505-10.64 11.991-21.88 23.449-32.9 35.11-3.42 3.621-7.53 3.955-12.27 3.508-34.77-3.28-69.56-6.367-104.35-9.484-65.08-5.831-130.16-11.624-195.233-17.465-66.917-6.006-133.83-12.068-200.748-18.072-84.721-7.601-169.445-15.166-254.168-22.749-77.765-6.961-155.528-13.946-233.295-20.883-54.847-4.892-109.693-9.797-164.559-14.461-5.404-.459-7.444-2.03-8.295-7.746-8.78-58.968-17.909-117.884-27-176.804-13.307-86.231-26.703-172.446-39.984-258.68-8.604-55.868-17.07-111.757-25.603-167.636C2.495 75.356 1.282 67.63 0 59.359c10.74-.632 20.933-1.325 31.137-1.818C72.79 55.53 114.45 53.643 156.1 51.588c48.409-2.388 96.811-4.904 145.792-7.36"})})}),aD=({standfirst:e,title:a})=>(0,t.jsxs)("header",{className:"c-background--pink-dark-pink tw-pt-wdsSpacingLg",children:[(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("div",{className:"tw-mb-wdsSpacing400 tw-text-white",children:[(0,t.jsx)(a_.default,{title:a}),(0,t.jsx)(av.default,{variant:"brandtext",children:e})]})})}),(0,t.jsx)(aP,{})]}),aq=({className:e,isShownWithTertiaryNavigation:a,standfirst:r,title:i})=>{let s=(0,n.default)("c-background--teal-indigo tw-py-wdsSpacing200 sm:tw-py-wdsSpacing600 md:tw-py-wdsSpacing800 tw-relative",{"md:tw-pb-wdsSpacingLg":!r,"md:tw-mb-wdsSpacingXl":!a,[e]:e});return(0,t.jsx)("header",{className:s,children:(0,t.jsxs)("div",{className:"tw-relative tw-z-low",children:[(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"extendedLeft",children:(0,t.jsx)(a_.default,{title:i})})}),r&&(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"extendedLeft",children:(0,t.jsx)("div",{className:"c-page-header-standard__standfirst tw-text-wdsF0",children:(0,t.jsx)(av.default,{variant:"brandtext",children:r})})})})]})})},aI=({className:e,imageSrc:a,isShownWithTertiaryNavigation:r,standfirst:i,title:s})=>{let l=(0,n.default)("c-page-header-impact c-background--neutral-teal tw-flex tw-relative tw-items-stretch tw-overflow-hidden tw-py-wdsSpacing200 sm:tw-py-wdsSpacing600 md:tw-py-wdsSpacing800",{"md:tw-pb-wdsSpacingLg":!i,"md:tw-mb-wdsSpacingXl":!r,[e]:e});return(0,t.jsxs)("header",{className:l,children:[a&&(0,t.jsx)("div",{className:"tw-absolute tw-inset-0 tw-z-0 tw-hidden sm:tw-block",children:(0,t.jsx)("figure",{className:"tw-absolute tw-inset-y-0 tw-right-0 tw-h-full tw-w-1/2 tw-overflow-hidden",children:(0,t.jsx)("div",{"aria-hidden":!0,
144className:"c-full-width-impact-banner__maskimage",children:(0,t.jsx)(w.default,{alt:"",className:"tw-h-full tw-w-full tw-object-cover tw-object-center",priority:!0,src:a,width:1440,height:600,sizes:"(min-width: 1024px) 50vw, 100vw"})})})}),(0,t.jsx)(J.default,{className:"tw-relative",children:(0,t.jsxs)(Z.GridColumn,{className:"sm:tw-col-start-1 sm:tw-col-end-7",children:[(0,t.jsx)(a_.default,{title:s}),i&&(0,t.jsx)(av.default,{variant:"brandtext",children:i})]})})]})},aG=({imageCaption:e,imageCredit:a,imageModifications:r,imageLicence:i,imageTitle:s,metaLabel:l,standfirst:o,title:d})=>(0,t.jsx)("header",{className:"c-page-header-notch",children:(0,t.jsx)(J.default,{children:(0,t.jsx)("div",{className:"c-page-header-notch__container c-page-header-notch__grid-item",children:(0,t.jsxs)("div",{className:(0,n.default)("tw-relative tw-z-low tw-mb-wdsSpacingMd sm:tw-mb-0",{"sm:tw-pt-wdsSpacingXl md:tw-pt-wdsSpacingLg":!l}),children:[l,(0,t.jsx)(a_.default,{title:d}),(0,t.jsx)(av.default,{variant:"brandtext",children:o}),(e||a||i)&&(0,t.jsx)("div",{className:"c-page-header-notch__tablet-caption",children:(0,t.jsx)(J.default,{as:"div",className:"c-image-banner__caption-container",children:(0,t.jsx)(Z.GridColumn,{spanGroup:"sidebarRight",children:(0,t.jsx)("div",{className:"c-media__caption c-image-banner__caption tw-mb-wdsSpacing100",children:(0,t.jsx)(aC.ImageBannerCaption,{caption:e,credit:a,modifications:r,licence:i,title:s})})})})})]})})})});var aB=e.i(282247),aU=e.i(204838);let a$=({standfirst:e,title:a,videoSrc:r,videoTitle:n})=>{let i=r?(0,aU.getYoutubeEmbedUrl)(r):null;return(0,t.jsx)("header",{className:"c-page-header-video",children:(0,t.jsxs)(J.default,{children:[(0,t.jsxs)(Z.GridColumn,{spanGroup:"center",children:[(0,t.jsx)(a_.default,{title:a}),(0,t.jsx)("div",{className:"c-page-header-video__standfirst",children:(0,t.jsx)(av.default,{variant:"brandtext",children:e})})]}),i&&(0,t.jsx)(Z.GridColumn,{className:"md:tw-col-start-2 md:tw-col-end-12",children:(0,t.jsx)("div",{className:"c-video",children:(0,t.jsx)("div",{className:"c-video__inner",children:(0,t.jsx)("iframe",{allowFullScreen:!0,className:"c-video__iframe",src:i,title:n})})})})]})})},aH=({imageSrc:e,jobTitle:r,links:i,namePrefix:s,nameSuffix:l,standfirst:d,title:c})=>{let m=!!i?.length&&i?.filter(e=>/(mailto:|tel:|twitter|linkedin)/.test(e.url)),f=c.split(" ")[0];return(0,t.jsx)("header",{className:"c-person-header tw-relative tw-mb-wdsSpacingMd tw-mt-wdsSpacingXl",itemScope:!0,itemType:"http://schema.org/Person",children:(0,t.jsxs)(J.default,{children:[e&&(0,t.jsx)(Z.GridColumn,{className:"md:tw-col-span-3",children:(0,t.jsx)("div",{className:"sm:tw-absolute",children:(0,t.jsx)("figure",{className:"tw-mb-wdsSpacingSm tw-h-[--person-header-img-size] tw-w-[--person-header-img-size] tw-overflow-hidden tw-rounded-full tw-bg-wdsIndigo-10 sm:tw-mb-0",children:(0,t.jsx)(w.default,{alt:"",className:"o-image o-image--cover",height:270,itemProp:"image",priority:!0,sizes:"(min-width: 1344px) 270px, (min-width: 1024px) 200px, (min-width: 768px) 160px, 140px",src:e,width:270})})})}),(0,t.jsxs)(Z.GridColumn,{spanGroup:"center",children:[(0,t.jsxs)(a_.default,{className:(0,n.default)("tw-mb-wdsSpacingSm",{"sm-to-md:tw-ml-[--person-header-offset] sm-to-md:tw-min-h-[--person-header-img-size]":e}),children:[s&&(0,t.jsxs)("span",{itemProp:"honorificPrefix",children:[s," "]}),(0,t.jsx)("span",{itemProp:"name",children:c}),l&&(0,t.jsxs)("span",{itemProp:"honorificSuffix",children:[" ",l]}),r&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(u.default,{children:", "}),(0,t.jsx)("span",{className:"tw-block",itemProp:"jobTitle",children:r})]})]}),(d||!!m?.length)&&(0,t.jsxs)("div",{children:[d&&(0,t.jsx)(av.default,{variant:"brandtext",className:"tw-text-wdsF0",children:d}),!!m?.length&&(0,t.jsxs)("p",{className:"tw-mt-wdsSpacing400 tw-text-wdsF-1 tw-font-bold",children:["Connect with ",f," on"," ",m?.map(e=>{let r=m.length>1&&e!==m[m.length-1];return(0,t.jsxs)(a.Fragment,{children:[(0,t.jsx)(o.default,{className:"o-animated-link tw-font-normal",href:e.url,children:e.title}),r&&(0,t.jsx)(t.Fragment,{children:" or "})]},`link-${e.url}`)})]})]})]})]})})},aM=({imageAlt:e="",imageCaption:r,imageCredit:i,imageModifications:s,imageHeight:l,imageLicence:o,imageSrc:d,imageTitle:c,imageWidth:u,jobTitle:m,links:f,metaLabel:h,namePrefix:p,nameSuffix:g,isShownWithTertiaryNavigation:x,standfirst:y,title:w,variant:b,videoSrc:v,videoTitle:j})=>{let N={banner_styling_variant_1:"banner",banner_styling_variant_2:"banner",banner_styling_variant_4:"banner",banner_styling_variant_5:"banner",banner_styling_variant_6:"banner",banner_styling_variant_7:"banner",banner_styling_variant_8:"banner",banner_styling_variant_9:"banner",lead_with_text:"banner",banner_styling_variant_3:"header",compact:"header",homepage_banner:"header",lead_with_image:"header",person:"header",shaded_background:"header",null:"header"},T=b??"null",S=Object.hasOwn(N,T)?T:"banner_styling_variant_1",k={banner_styling_variant_1:aR,banner_styling_variant_2:aF,banner_styling_variant_3:aG,banner_styling_variant_4:aR,banner_styling_variant_5:aR,banner_styling_variant_6:a$,banner_styling_variant_7:aq,banner_styling_variant_8:aI,banner_styling_variant_9:aD,compact:aL,lead_with_image:aB.default,lead_with_text:aB.default,shaded_background:aB.default,homepage_banner:a.Fragment,null:aB.default,person:aH}[S],E=d&&(0,t.jsx)("div",{className:(0,n.default)({"c-outer-grid__banner":"lead_with_text"!==S,"tw-mb-wdsSpacingMd":"lead_with_text"===S}),children:(0,t.jsx)(aE.default,{alt:e,brandCropVariant:"banner_styling_variant_3"===S?"
144notch":void 0,caption:r,modifications:s,className:(0,n.default)({"c-page-header-notch__image-banner":"banner_styling_variant_3"===b}),credit:i,height:l,licence:o,src:d,title:c,width:u})});return(0,t.jsxs)(t.Fragment,{children:[("lead_with_image"===S||"banner_styling_variant_3"===S)&&E,(0,t.jsx)(an.GridOuterArea,{className:"tw-relative",gridArea:N[S],children:(0,t.jsx)(k,{imageElement:E,imageLocation:"lead_with_image"===S?"top":"bottom",imageAlt:e,imageCaption:r,imageCaptionLocation:"bottom",imageCredit:i,imageHeight:l,imageLicence:o,imageModifications:s,imageSrc:d,imageWidth:u,imageTitle:c,jobTitle:m,links:f,metaLabel:h,namePrefix:p,nameSuffix:g,isShownWithTertiaryNavigation:x,standfirst:y,title:w,variant:{banner_styling_variant_1:"shaded",banner_styling_variant_4:"light",banner_styling_variant_5:"dark"}[S],videoSrc:v,videoTitle:j})})]})};e.i(652576);var aW=e.i(634115),aY=e.i(505126);e.i(806249);var aK=e.i(859438);let az=({date:e,duration:a,pageType:r,reviewDate:i,updatedDate:s})=>{let l="article"===r,o="standard"===r;return(0,t.jsxs)(t.Fragment,{children:[o&&(s&&!i||!s&&i)&&(0,t.jsx)("div",{className:"c-page-header-tray tw-py-wdsSpacing150 md:-tw-mt-wdsSpacing400",children:(0,t.jsx)(aK.default,{date:i||s,dateLabel:i?"Next review":"Last updated",dateType:i?"dateReview":"dateUpdated"})}),l&&!s&&!i&&(0,t.jsx)("div",{className:"c-page-header-tray tw-py-wdsSpacing150",children:(0,t.jsx)(aK.default,{date:e,duration:a,dateType:"datePublished"})}),l&&!s&&i&&(0,t.jsx)(aW.default,{variant:"tray",className:"tw-pb-wdsSpacing050",hasBorders:!0,children:(0,t.jsx)(aY.AccordionItem,{id:"content-updated-date",className:"tw-pt-0",title:(0,t.jsx)(aK.default,{date:e,duration:a,dateType:"datePublished"}),variant:"plus",children:(0,t.jsx)("span",{className:"tw-block tw-text-wdsF-2 tw-text-meta sm:tw-inline-block",children:(0,t.jsx)("span",{className:"tw-flex tw-flex-row tw-text-meta sm:tw-pt-wdsSpacing050",children:i&&(0,t.jsx)("span",{className:"tw-flex tw-flex-row sm:tw-inline-block",children:(0,t.jsx)(aK.default,{date:i,dateFormat:"monthYear",dateLabel:"Next review",dateType:"dateReview"})})})})})}),(o&&s&&i||l&&s)&&(0,t.jsx)(aW.default,{variant:"tray",className:(0,n.default)("tw-py-wdsSpacing050",{"md:-tw-mt-wdsSpacing400":o}),hasBorders:!0,children:(0,t.jsx)(aY.AccordionItem,{id:"content-updated-date",className:"tw-pb-wdsSpacing150 tw-pt-0 sm:tw-pt-wdsSpacing050",title:(0,t.jsx)(aK.default,{date:s,dataLabelClassName:"tw-hidden sm:tw-inline-block",duration:l?a:null,dateLabel:"Last updated",dateType:"dateUpdated"}),variant:"plus",children:(0,t.jsxs)("span",{className:"tw-block tw-text-wdsF-2 tw-text-meta sm:tw-flex sm:tw-flex-row",children:[l&&(0,t.jsx)("span",{className:"tw-flex tw-flex-row",children:(0,t.jsx)(aK.default,{date:e,dateLabel:"First published",dateType:"datePublished"})}),(0,t.jsx)("span",{className:"tw-flex tw-flex-row tw-pt-wdsSpacing150 tw-text-wdsF-2 tw-text-meta sm:tw-pt-0",children:i&&(0,t.jsxs)(t.Fragment,{children:[l&&(0,t.jsx)(g.default,{className:"tw-hidden sm:tw-block"}),(0,t.jsx)("span",{className:"tw-flex tw-flex-row",children:(0,t.jsx)(aK.default,{date:i,dateFormat:"monthYear",dateLabel:"Next review",dateType:"dateReview"})})]})})]})})})]})};e.i(376261);var aV=e.i(370043);e.i(141472);var aX=e.i(50270);let aQ=({children:e,datePublished:a,dateUpdated:r,stickySidebar:i,variant:s})=>{let l=(0,af.default)(),o="banner_styling_variant_1"===s||"banner_styling_variant_2"===s||"banner_styling_variant_7"===s||"banner_styling_variant_8"===s,d=(0,n.default)("c-page-sidebar",{"c-page-sidebar--compact":"compact"===s,"c-page-sidebar--notch":"banner_styling_variant_3"===s,"c-page-sidebar--standard":"lead_with_image"===s||"shaded_background"===s||null===s,"c-page-sidebar--compact-centred":"banner_styling_variant_9"===s}),c=(0,n.default)(d,"tw-relative"),u=(0,n.default)(d,{"c-page-sidebar--sticky":!o,"c-page-sidebar--sticky-tertiary":o,"c-page-nav-trigger-as-tray":"banner_styling_variant_7"===s||"banner_styling_variant_2"===s||"banner_styling_variant_8"===s,"is-scrolling-up":"up"===l&&o});return(0,t.jsxs)(t.Fragment,{children:[e&&(0,t.jsx)("div",{className:c,children:e}),(a||r)&&(0,t.jsx)("div",{className:c,children:(a||r)&&(0,t.jsxs)("dl",{className:"c-page-sidebar__dates",children:[a&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("dt",{className:"c-page-sidebar__date-label",children:"Published"}),(0,t.jsx)("dd",{className:"c-page-sidebar__date",children:(0,t.jsx)("time",{dateTime:a,children:(0,t.jsx)(aX.default,{dateString:a})})})]}),r&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("dt",{className:"c-page-sidebar__date-label",children:"Last updated"}),(0,t.jsx)("dd",{className:"c-page-sidebar__date",children:(0,t.jsx)("time",{dateTime:r,children:(0,t.jsx)(aX.default,{dateString:r})})})]})]})}),i&&(0,t.jsx)("div",{className:u,children:i})]})},aJ=({links:e})=>{let a={Gaana:"iconSocialPodcastGaana",Spotify:"iconSocialPodcastSpotify","Apple podcasts":"iconSocialPodcastApple","Google podcasts":"iconSocialPodcastGoogle"};return(0,t.jsx)("ul",{className:"tw-mb-wdsSpacingMd tw-list-none",children:e?.map(({id:e,title:r,url:n})=>(0,t.jsx)("li",{children:(0,t.jsxs)(o.default,{className:"c-podcast-list__link o-animated-link-nested",href:n,children:[(0,t.jsx)(t0.default,{className:"c-podcast-list__icon",isDisplayedAsSmall:!0,name:a[r]}),(0,t.jsx)("span",{className:"o-animated-link-nested__child",children:`Listen on ${r}`}),(0,t.jsx)(t0.default,{className:"c-podcast-list__icon-arrow md:tw-hidden",name:"iconDirectionalArrowRight"})]})},`podcast-list-${e}`))})},aZ=({links:e})=>{let{mediumMax:a}
144=(0,i.useBreakpointContext)();return(0,t.jsx)(t.Fragment,{children:a?(0,t.jsx)(aW.default,{className:"c-podcast-list",hasBorders:!0,children:(0,t.jsx)(aY.AccordionItem,{id:"podcast-list",title:"More ways to listen",titleAs:"h2",variant:"plus",children:(0,t.jsx)(aJ,{links:e})})}):(0,t.jsxs)("div",{"aria-labelledby":"podcast-list-title",className:"c-podcast-list",role:"region",children:[(0,t.jsx)("p",{className:"c-podcast-list__title",id:"podcast-list-title",children:(0,t.jsx)("strong",{className:"tw-font-medium",children:"More ways to listen"})}),(0,t.jsx)(aJ,{links:e})]})})};e.i(984947);var a0=e.i(8782);let a1=({target:e,startingPoint:r=0})=>{var n;let i,s,l,[o,d]=(0,a.useState)(r);return n=()=>{if(!e.current)return;let t=e.current,a=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0,n=t.clientHeight-t.offsetTop-window.innerHeight;if(a>=n)return d(100);d(a/n*100+r)},i=(0,a.useRef)(null),s=(0,a.useRef)(null),l=e=>{void 0!==s.current&&n(s.current),s.current=e,i.current=requestAnimationFrame(l)},(0,a.useEffect)(()=>(i.current=requestAnimationFrame(l),()=>cancelAnimationFrame(i.current)),[]),(0,t.jsx)("div",{"aria-hidden":"true",className:"c-progress-bar",children:(0,t.jsx)("div",{className:"c-progress-bar__bar",style:{width:`${o}%`}})})};e.i(318367);var a2=e.i(462092);let a3=function({defaultTitle:e,isMinimal:r,items:s}){let{active:l}=(0,au.useActiveLinkContext)(),{inpageNavFocus:o,isInpageNavOpen:d,setInpageNavFocus:c,toggleInpageNav:u}=(0,au.useInpageNavContext)(),{minHeight:m}=(0,i.useBreakpointContext)(),f=(0,af.default)(),h=(0,a.useRef)(null),p=(0,a.useRef)(null),[g,x]=(0,a.useState)(l),y=am(g);(0,a.useEffect)(()=>{"inpage-btn-mobile"===o&&h?.current?.focus()},[o]),(0,a.useEffect)(()=>{let e=setTimeout(()=>{x(l)},500);return()=>{clearTimeout(e)}},[l]);let w=e=>{r&&m&&d&&(0,tz.isKeyValueSupported)(tz.default.ESCAPE,e)&&(u(!1),c("mobile-inpage-content-btn"))};return{accordionBtnRef:h,closeMobileNav:()=>{r&&u(!1)},handleEsc:w,handleMobileButtonClick:()=>{u(!d),c("")},handleMobileButtonKeyDown:e=>{r&&m&&e.shiftKey&&"Tab"===e.key&&(e.preventDefault(),d&&p?.current?.focus()),w(e)},handleTrapEndKeyDown:e=>{r&&m&&!e.shiftKey&&"Tab"===e.key&&(e.preventDefault(),h?.current?.focus())},isInpageNavOpen:d,lastItemsRef:p,renderActiveTitles:()=>l?s.filter(e=>e.id&&e.title).map(({id:e,title:a})=>(0,t.jsx)("span",{"aria-hidden":e!==l,className:(0,n.default)("c-inpage-nav__button-text",{"is-active":e===l,"is-prev":e===y&&y!==l,"is-scrolling-up":"up"===f&&e!==l,"is-scrolling-down":"down"===f&&e!==l}),children:a},e)):(0,t.jsx)(t.Fragment,{children:e})}},a5="Contents",a4=function({activeTab:e,isMinimal:a,tabGroups:r,onSelectTab:i}){let{active:s}=(0,au.useActiveLinkContext)(),l=function(e,t,a){if(t){let a=e.findIndex(e=>e.sections.some(e=>e.anchorId===t));if(a>=0)return a}let r=e.findIndex(e=>e.tabName===a);return r>=0?r:0}(r,s,e),{accordionBtnRef:d,closeMobileNav:u,handleEsc:m,handleMobileButtonClick:f,handleMobileButtonKeyDown:h,handleTrapEndKeyDown:p,isInpageNavOpen:g,lastItemsRef:x,renderActiveTitles:y}=a3({defaultTitle:a5,isMinimal:a,items:r.flatMap(e=>e.sections.map(t=>({id:t.anchorId,groupTitle:e.tabName,title:t.title||t.sectionTitle})).filter(e=>!!e.id&&!!e.title)).map(({id:e,title:t})=>({id:e,title:t}))}),w=(0,t.jsx)(t.Fragment,{children:r.map((e,a)=>(0,t.jsx)(aW.default,{hasBorders:!0,activeIndex:a===l?0:-1,variant:"filter",children:(0,t.jsx)(aY.AccordionItem,{contentInnerClassName:"md:tw-mb-wdsSpacingSm",id:`scheme-tab-${a}`,title:e.tabName,variant:"chevronSimplified",children:(0,t.jsx)("ul",{className:"c-inpage-nav__list tw-list-none md:tw-space-y-wdsSpacingSm",children:e.sections.map((l,d)=>{let c=l.title||l.sectionTitle;if(!l.anchorId||!c)return null;let f=l.anchorId===s,h=a===r.length-1&&d===e.sections.length-1;return(0,t.jsx)("li",{className:"c-inpage-nav__item",children:(0,t.jsx)(o.default,{className:(0,n.default)("c-inpage-nav__link md:o-animated-link-nested tw-mt-0",{"is-active":f}),href:`#${l.anchorId}`,onClick:t=>{var a,r;return a=e.tabName,r=l.anchorId,void(t.preventDefault(),i(a),window.history.pushState(null,"",`#${r}`),requestAnimationFrame(()=>{requestAnimationFrame(()=>{let e=document.getElementById(r);e&&e.scrollIntoView({behavior:"smooth",block:"start"})})}
144),u())},onKeyDown:e=>{h&&p(e),m(e)},ref:h?x:void 0,children:(0,t.jsx)("span",{className:"c-inpage-nav__link-text o-animated-link-nested__child",children:c})})},l.id)})})})},e.id))});return(0,t.jsx)("nav",{"aria-label":a5,className:"c-inpage-nav",children:a?(0,t.jsxs)("div",{"aria-labelledby":"mobile-inpage-content-btn",className:"c-inpage-nav__accordion tw-py-wdsSpacing100",id:"mobile-inpage-nav",children:[(0,t.jsx)("h2",{className:"tw-my-0",children:(0,t.jsx)(c.default,{"aria-expanded":g,className:"c-inpage-nav__button",icon:"iconActionPlus",iconPlacementSwitch:!0,id:"inpage-btn-mobile",onClick:f,onKeyDown:h,ref:d,variant:"unstyled",children:g?a5:y()})}),(0,t.jsx)("div",{"aria-labelledby":"inpage-btn-mobile",hidden:!g,children:w})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("h2",{id:"scheme-contents",className:"tw-text-wdsF0 tw-font-bold md:tw-mb-wdsSpacingSm",children:a5}),w]})})};e.i(867933);var a6=e.i(989235);e.i(321802);var a8=e.i(415827);e.i(102772);var a7=e.i(726690),a9=e.i(677373);e.i(577136);var re=e.i(489774);let rt=({pageHasBreadcrumbs:e,links:r,skipLinkHref:i="#page-sections"})=>{let{active:s}=(0,au.useActiveLinkContext)(),[l,o]=(0,a.useState)(!1),d=(0,a.useRef)(null),c=(0,af.default)(),m=e?80:120;return(0,a9.useScrollPosition)(({currPos:e})=>{o(e.y<=m)},[m],d),(0,t.jsx)("div",{className:"c-nav-tertiary-container",ref:d,children:(0,t.jsxs)("div",{className:(0,n.default)("c-nav-tertiary",{"is-sticky":l,"is-scrolling-up":"up"===c,"is-scrolling-down":"down"===c}),children:[(0,t.jsx)(a6.default,{href:i,variant:"float",children:"Skip to contents"}),(0,t.jsxs)("nav",{className:"tw-ml-[var(--grid-margin)] xxl:tw-ml-[calc((100%-var(--container-width))/2)]","aria-label":"In page",children:[(0,t.jsx)(u.default,{wrapperAs:"h2",children:"Contents"}),(0,t.jsx)("ul",{className:"u-no-scrollbar tw-relative tw-z-low tw-flex tw-min-h-[3.125rem] tw-list-none tw-overflow-x-scroll",children:r?.map(({id:e,title:a})=>(0,t.jsx)("li",{className:"tw-mr-wdsSpacingMd tw-inline-block tw-shrink-0 tw-content-end tw-p-wdsSpacingXs",children:(0,t.jsx)("a",{href:`#${e}`,className:(0,n.default)("c-nav-tertiary__link tw-inline-block tw-flex tw-self-end tw-px-0",{"is-active":e===s}),children:(0,t.jsx)(re.default,{className:"c-nav-tertiary__link-text tw-whitespace-nowrap",variant:"dark",children:a})})},`tertiary-link-${e}`))})]})]})})},ra={previous:{label:"Previous",icon:"iconDirectionalArrowLeft",iconClass:"c-btn__icon--left",buttonAlign:"tw-text-left",contentAlign:"",iconFirst:!0},next:{label:"Next",icon:"iconDirectionalArrowRight",iconClass:"c-btn__icon--right",buttonAlign:"tw-text-right",contentAlign:"tw-justify-end",iconFirst:!1}},rr=({direction:e,tabName:a,pageTitle:r,onClick:n})=>{let{label:i,icon:s,iconClass:l,buttonAlign:o,contentAlign:d,iconFirst:u}=ra[e],m=(0,t.jsx)(t0.default,{name:s,className:l}),f=(0,t.jsx)("span",{className:"c-fancy-link__text",children:i});return(0,t.jsxs)(c.default,{className:`c-fancy-link ${o}`,onClick:n,variant:"unstyled",children:[(0,t.jsx)("span",{className:`tw-flex ${d}`,children:u?(0,t.jsxs)(t.Fragment,{children:[m,f]}):(0,t.jsxs)(t.Fragment,{children:[f,m]})}),(0,t.jsx)("span",{className:"tw-block tw-font-bold",children:r}),(0,t.jsx)("span",{children:a})]})},rn=({tabGroups:e,currentTab:a,onSelectTab:r,pageTitle:i})=>{let s=e.findIndex(({tabName:e})=>e===a);if(-1===s)return null;let l=e[s-1]?.tabName,o=e[s+1]?.tabName;if(!l&&!o)return null;let d=()=>{document.getElementById("page-sections")?.scrollIntoView({behavior:"smooth",block:"start"})},c=t=>{r(t);let a=e.findIndex(({tabName:e})=>e===t),n=e[a]?.sections?.[0];n?.anchorId&&window.history.pushState(null,"",`#${n.anchorId}`),requestAnimationFrame(()=>requestAnimationFrame(d))};return(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("nav",{"aria-label":"Previous and next tab",className:"tw-flex tw-items-start tw-justify-between tw-py-wdsSpacing300 print:tw-hidden",children:[l&&(0,t.jsx)("div",{className:"tw-mr-auto tw-w-1/2 tw-pr-wdsSpacingSm",children:(0,t.jsx)(rr,{direction:"previous",tabName:l,pageTitle:i,onClick:()=>c(l)})}),(0,t.jsx)("div",{className:(0,n.default)("tw-ml-auto tw-w-1/2 tw-border-l-1 tw-border-black tw-pl-wdsSpacingSm",{"tw-self-center":!o}),children:o?(0,t.jsx)(rr,{direction:"next",tabName:o,pageTitle:i,onClick:()=>c(o)}):(0,t.jsxs)("p",{className:"tw-text-right tw-text-wdsNeutral-50",children:[(0,t.jsx)("span",{className:"tw-block tw-font-bold",children:i}),(0,t.jsx)("span",{children:"There are no more sections"})]})})]})})})},ri=function({activeTab:e,onSelectTab:r,tabGroups:n,pageTitle:i,renderSection:s}){let l=(0,a.useRef)({});return((0,a.useEffect)(()=>
144{n.forEach(t=>{let a=l.current[t.tabName];a&&(t.tabName===e?a.removeAttribute("hidden"):a.setAttribute("hidden","until-found"))})},[e,n]),(0,a.useEffect)(()=>{let e=[];return n.forEach(t=>{let a=l.current[t.tabName];if(!a)return;let i=()=>{n.forEach(e=>{e.tabName!==t.tabName&&l.current[e.tabName]?.setAttribute("hidden","until-found")}),r(t.tabName)};a.addEventListener("beforematch",i),e.push(()=>a.removeEventListener("beforematch",i))}),()=>e.forEach(e=>e())},[n,r]),0===n.length)?null:(0,t.jsx)(t.Fragment,{children:n.map(e=>(0,t.jsxs)("div",{ref:t=>{l.current[e.tabName]=t},className:"c-tabbed-content__panel",role:"region","aria-label":e.tabName,children:[(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)("p",{className:"tw-mb-wdsSpacingMd tw-font-primary tw-text-wdsF-2 tw-font-semibold tw-text-wdsNeutral-50",children:e.tabName})})}),e.sections.map(s),(0,t.jsx)("div",{className:"tw-mb-wdsSpacingXl",children:(0,t.jsx)(rn,{tabGroups:n,currentTab:e.tabName,onSelectTab:r,pageTitle:i})})]},e.id))})};var rs=e.i(555575);e.i(534996);var rl=e.i(903959);let ro=({slice:e})=>(0,t.jsx)(t.Fragment,{children:e?.map(e=>"ParagraphText"===e.__typename?(0,t.jsx)("div",{className:"tw-mb-wdsSpacingMd",children:(0,t.jsx)(K.default,{children:e.body?.processed})},e.id):"ParagraphLandingPageElement"===e.__typename?(0,t.jsx)("div",{className:"c-card-listing--two-column tw-mb-wdsSpacingMd",children:e.contentSlicesRef?.map(e=>(0,t.jsx)(rl.default,{className:"c-fact-card--two-column",description:e.body?.processed,href:e.optionalLink?.url,linkText:e.optionalLink?.title,title:e.title},e.id))},e.id):"ParagraphCallToAction"===e.__typename?(0,t.jsx)("div",{className:"tw-mb-wdsSpacingMd",children:(0,rs.default)(e,"left")},e.id):e?.__typename==="ParagraphSectionInfo"?(0,t.jsx)("div",{className:"tw-mb-wdsSpacingMd",children:(0,t.jsx)(W.default,{citationText:(0,ao.getCitationText)(e.contentSlicesRef,e.infoBoxStyling),title:e.title,variant:e.infoBoxStyling,children:(0,ao.default)(e.contentSlicesRef,e.infoBoxStyling,"center")})},e.id):void 0)});var rd=e.i(586064);let rc=function(e){if(e)return{additionalDeadline:e.additionalDeadlineText?e.additionalDeadlineText:null,administeringOrganisationLocation:e.locationRef?e.locationRef?.map(e=>({id:e.id,name:e.name,weight:e.weight,explanationUrl:e.explanationUrl?.url})):null,coapplicantsAccepted:e.coapplicantsAccepted?e.coapplicantsAccepted:null,fundingAmount:e.levelOfFunding?e.levelOfFunding.processed:null,fundingDuration:e.durationOfFunding?e.durationOfFunding.processed:null,id:e.id,leadApplicantCareerStage:e.careerStageRef?e.careerStageRef?.map(e=>({id:e.id,name:e.name,weight:e.weight,explanationUrl:e.explanationUrl?.url})):null,multipleDeadlineDates:e.multipleDeadlineDates?e.multipleDeadlineDates:null,schemeAbbreviation:e.schemeAbbreviation?e.schemeAbbreviation:null,schemeAcceptingApplications:e.schemeAcceptingApplications?e.schemeAcceptingApplications:null,schemeClosesForApplications:e.schemeClosesForApplications?e.schemeClosesForApplications.time:null,schemeFrequency:e.schemeFrequencyRef?{id:e.schemeFrequencyRef.id,name:e.schemeFrequencyRef.name}:{},schemeOpensForApplications:e.schemeOpensForApplications?e.schemeOpensForApplications.time:null,schemeStatus:e.schemeStatus?e.schemeStatus:null,strategicProgramme:e.challengeAreaRef?e.challengeAreaRef?.map(e=>({id:e.id,name:e.name})):null}},ru=function(e){if(e)return e.challengeAreaRef?e.challengeAreaRef?.map(e=>({id:e.id,title:e.name})):null},rm=function(e){let t=e.buttonsRef?.map(({buttonType:e,link:t,linkStyle:a})=>{let{url:r,title:n}=t??{};return{href:r??null,text:n??null,type:e,variant:a}});return{body:e.body?.processed,buttons:t,id:e.id,title:e.title}};var rf=e.i(921251),rh=e.i(939933),rp=e.i(60850),rg=e.i(799512),rx=e.i(221168),ry=e.i(886996);e.s(["default",0,function(e){let{authors:o,bannerImage:m,bannerVariant:f,contactLinks:h,contributors:p,frontendSchemeName:g,grantAwardHolders:w,grantFundingScheme:N,grantProjectSummary:T,grantYearOfAward:S,hasFullyRestrictedPageContent:k,inpageNavLinks:E,isPreview:_,newsletterFooter:C,nodeId:A,page:R,pageContent:F,pageId:L,pageMetaIcon:O,pageMetaLabel:P,pageMetaSubLabel:D,pageType:q,pageUrl:I,podcastLanding:G,profileImage:B,relatedContent:U,schemeTabGroups:$=[],schemaImages:H,schemaSocialLinks:M,siblingNavigation:Y,socialImage:z,topics:V}=e;{(0,a.useEffect)(()=>{},[F]);let{mediumMax:e}
144=(0,i.useBreakpointContext)(),{userHasAcceptedModal:A,shouldHideAllPageContent:L,setUserHasAcceptedModal:X}=(e=>{let[t,r]=(0,a.useState)(!1),[n,i]=(0,a.useState)(e);return(0,a.useEffect)(()=>{t&&i(!1)},[t]),{userHasAcceptedModal:t,shouldHideAllPageContent:n,setUserHasAcceptedModal:r}})(k);(0,l.default)({authors:o,contributors:p,dateModified:R?.dateModified?.time,datePublished:R?.datePublished?.time,id:R?.id,disabled:_,pageMetaLabel:P,strategicProgrammes:ru(R),tags:V});let Q=!1,ee=A||!L&&!Q,et=a.default.useRef(null),ea="article"===q,er="funding_scheme"===q,en="landing"===q,ei="person"===q,es="report_summary"===q,el="standard"===q,eo="podcast"===q,ed=en&&R?.bannerStyling==="banner_styling_variant_1",ec=en&&R?.bannerStyling==="banner_styling_variant_7",eu=en&&R?.bannerStyling==="banner_styling_variant_8",em=R?.bannerStyling==="banner_styling_variant_2",ef=er?rc(R):null,eh=er&&F?.some(e=>"ParagraphVerticalTab"===e.__typename),ep=eh?(0,ry.getContentTabs)(F):[],eg=eh&&$.length>0,[ex,ey]=(0,a.useState)(ep[0]||""),ew=e=>ey(e),eb=!R?.excludeBreadcrumbs,ev=ea||eo||el&&R?.standardPageType?.name==="Funding guidance"&&(R?.dateLastUpdated?.time||R?.dateNextReview?.time),ej=ea&&R?.interactiveToggle,eN=R?.socialShare,eT=R?.callToAction&&es,eS="primary",ek=E?.length>0&&(ed||ec||eu||em),eE={centre_align:"center",left_align:"extendedLeft",null:"center"}[R.contentAlignment],e_=R?.path||null,eC=F?.[F.length-1],eA=F?.[0],eR=eA?.stylingOptions==="neutral_light"||eA?.stylingOptions==="neutral_dark"||eA?.stylingOptions==="neutral_blue",eF=eC?.stylingOptions==="neutral_light"||eC?.stylingOptions==="neutral_dark"||eC?.stylingOptions==="neutral_blue",eL=R?.bannerStyling==="banner_styling_variant_1"&&!eR,eO=!!C?.length,{setHasFinalTintedPanel:eP,setLayoutContext:eD}=(0,s.useLayoutContext)();(0,a.useEffect)(()=>{eD(eE),eP(eO||eF||eR)},[eO,eF,eR,eE,eP,eD]);let eq=R.showPrintPageLink,eI=(0,a.useRef)($);eI.current=$,(0,a.useEffect)(()=>{if(!eh)return;let e=()=>{let e=eI.current;if(!e)return;let t=window.location.hash.slice(1);if(!t)return;let a=e.find(e=>e.sections.some(e=>e.anchorId===t));a&&ey(a.tabName)};return window.addEventListener("popstate",e),()=>window.removeEventListener("popstate",e)},[eh,ey]),(0,a.useEffect)(()=>{r.default.dataLayer({dataLayer:{event:"custom.event.editorial.user.need",editorialUserNeed:R?.editorialUserNeed}})},[R?.editorialUserNeed]);let eG=eb&&(0,t.jsx)(y.default,{pageTitle:R?.title}),eB=(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)(az,{date:R?.datePublished?.time,duration:(0,rd.default)(null,R?.readTime),pageType:q,updatedDate:R?.dateLastUpdated?.time,reviewDate:R?.dateNextReview?.time})}),eU=G?.podcastLinks?.length>0&&(0,t.jsx)(aZ,{links:G.podcastLinks}),e$=((e,t)=>{if(e)return{id:e.id,title:e.name,podcastLinks:e[t]?.map(e=>({id:e.id,url:e.podcastLink,title:e.podcastServiceRef?.name??null}))}})(R,"podcastEpisodeLinksRef"),eH=e$&&(0,t.jsx)(aZ,{links:e$.podcastLinks}),eM=ea&&(0,t.jsx)(a1,{target:et,startingPoint:2}),eW=E?.length>0&&!ek||E?.length>0&&ec||E?.length>0&&eu||E?.length>0&&em,eY=eg?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(a6.default,{href:"#page-sections",children:"Skip to contents"}),(0,t.jsx)(a4,{activeTab:ex,isMinimal:e,tabGroups:$,onSelectTab:ew})]}):eW&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(a6.default,{href:"#page-sections",children:"Skip to contents"}),(0,t.jsx)(ap,{hasScrollyStory:ej,isMinimal:e,links:E})]}),eK=o&&(0,t.jsx)("div",{className:(0,n.default)("c-page-sidebar__contributors",{"tw-mb-wdsSpacing200 sm:tw-mb-wdsSpacing300 md:tw-mb-0":p,"tw-mb-wdsSpacing400 sm:tw-mb-0":!p}),children:o?.map(e=>{let a=e.linksList?e.linksList:[],{profileLink:r}=(0,rh.default)(a),n=e.listingImageRef?.image;return(0,t.jsx)(b,{className:"c-page-sidebar__contributor",imageSrc:n?.variations[0]?.url,jobTitle:e.jobTitle,name:e.title,organisation:e?.organisationRef?.map(({name:e})=>e).join(", "),profileLink:r},`author-${e.id}`)})}),ez=R.podcastGuestsRef?.length>0,eV=R.podcastHostsRef?.length>0,eX=eV&&(0,t.jsx)("div",{className:"c-page-sidebar__podcast-hosts",children:R.podcastHostsRef?.map(e=>{let a=e.listingImageRef?.image;return(0,t.jsx)(b,{className:"c-page-sidebar__author",imageSrc:a?.variations[0]?.url,jobTitle:G?.title?`${G?.title} host`:"host",name:`${e.title}`},`host-${e.id}`)})}),eQ=ez&&(0,t.jsx)("div",{className:"c-page-sidebar__podcast-guests",children:R.podcastGuestsRef?.map(e=>{let a=e.listingImageRef?.image;return(0,t.jsx)(b,{className:"c-page-sidebar__author",imageSrc:a?.variations[0]?.url,jobTitle:"Guest",name:`${e.title}`},`guest-${e.id}`)})}),eJ=p&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("h2",{className:"tw-font-weight-heading tw-mb-wdsSpacing100 tw-font-medium sm:tw-mb-wdsSpacing150 md:tw-mb-wdsSpacing200",children:"Contributions from:"}),(0,t.jsx)("div",{className:"c-page-sidebar__contributors tw-mb-wdsSpacing400 sm:tw-mb-0",children:p?.map(e=>{let a=e.linksList?e.linksList:[],{profileLink:r}=(0,rh.default)(a);return(0,t.jsx)(b,{className:"c-page-sidebar__contributor",jobTitle:e.jobTitle,name:e.title,organisation:e?.organisationRef?.map(({name:e})=>e).join(", "),profileLink:r},e.id)})})]}),{bannerVideoRef:eZ}=R,e0=P&&(0,t.jsx)(d.default,{className:"c-meta-label--page-header",icon:O,hasSeparator:eo,label:P,subLabel:D}),e1=(0,t.jsx)("div",{className:(0,n.default)("tw-mt-wdsSpacingMd",{"tw-hidden md:tw-block":ea||eo,"tw-mb-wdsSpacingMd":!ea}),children:(0,t.jsx)(a8.default,{body:R?.standfirst?.processed,title:R?.title,url:I})}),e2=(0,t.jsxs)(t.Fragment,{children:[eN&&er&&e1,eT&&(0,t.jsx)("div",{className:"tw-mb-wdsSpacingMd tw-hidden md:tw-block",children:(0,t.jsx)(v.default,{buttonStyle:eS,text:R?.callToAction.title,href:R?.callToAction.url})}),ej&&(0,t.jsxs)("div",{className:"tw-mb-wdsSpacingMd tw-hidden md:tw-block",children:[(0,t.jsx)("h2",{className:"tw-mb-wdsSpacing150 tw-block tw-text-wdsF-2 tw-font-normal",children:"Read as"}),(0,t.jsx)(ac.default,{buttonClassName:"c-toggle-view__btn--custom-padding"})]}),(0,t.jsx)(ag,{isVisible:(eW||eg)&&e,title:eg?a5:ah}),eT&&(0,t.jsx)("div",{className:"c-cta-mobile-container tw-my-wdsSpacingMd md:tw-hidden",children:(0,t.jsx)(v.default,{buttonStyle:eS,text:R?.callToAction.title,href:R?.callToAction.url})}),eW&&!e&&!en&&!eh&&(0,t.jsx)(t.Fragment,{children:eY}),eh&&!e&&eg&&(0,t.jsx)(a4,{activeTab:ex,tabGroups:$,onSelectTab:ew}),eq&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(c.default,{className:"tw-mt-wdsSpacingLg",icon:"iconActionPrint",onClick:()=>{r.default.dataLayer({dataLayer:{event:"custom.event.printThisPage",pagePath:e_}}),window.print()},variant:"link",children:"Print this page"}),eh&&(0,t.jsx)("p",{className:"tw-text-wdsF-2 tw-text-wdsNeutral-50",children:"This will print all the content across all of the different sections"})]}),(eN&&!er||eo)&&e1]});return(0,t.jsxs)(ay.default,{breadcrumb:eG,hasDarkMode:R?.greyBackgroun
144d,inpageNav:eY,progressBar:eM,children:[_&&(0,t.jsx)(a0.default,{}),(0,t.jsx)(aV.default,{abstract:R?.standfirst?.processed,authors:o,contributors:p,dateModified:R?.dateModified?.time,datePublished:R?.datePublished?.time,description:R.metaDescription,imageUrl:z,jobTitle:R.jobTitle,metaTitle:R.metaTitle,pageTitle:R.title,pathname:R.path,profileImage:B,pageType:q,schema:R.includeSchema,schemaImages:H,shouldNoIndex:R.noindex,socialLinks:M,url:R.path}),(0,t.jsxs)(ar.default,{className:(0,n.default)({"has-breadcrumbs":eb}),id:"content",ref:et,children:[(0,t.jsx)(aM,{imageAlt:m?.alt,imageCaption:m?.caption,imageCredit:m?.credit,imageModifications:m?.modifications,imageHeight:m?.height,imageLicence:m?.licence,imageSrc:m?.src,imageTitle:m?.title,imageWidth:m?.width,jobTitle:R.jobTitle,links:h,metaLabel:e0,namePrefix:R.namePrefix?.name,nameSuffix:R.nameSuffix,isShownWithTertiaryNavigation:ek,standfirst:R?.standfirst?.processed,title:R?.title,variant:f,videoSrc:eZ?.mediaOembedVideo,videoTitle:eZ?.name||R?.title}),ek&&(0,t.jsx)(an.GridOuterArea,{className:(0,n.default)({"md:tw-mb-wdsSpacingXl":R?.bannerStyling!=="banner_styling_variant_1"&&!eR,"has-tinted-first-slice":eR}),gridArea:"nav",children:(0,t.jsx)(rt,{links:E,pageHasBreadcrumbs:eb})}),eL&&(0,t.jsx)(an.GridOuterArea,{gridArea:"brandCrop",children:(0,t.jsx)(ax.default,{})}),ev&&(0,t.jsx)("div",{className:(0,n.default)("md:tw-hidden",{"tw-mb-wdsSpacingMd":!E}),children:(0,t.jsxs)(J.default,{children:[(eK||eX||eQ)&&(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("div",{className:(0,n.default)({"tw-mt-wdsSpacingMd":R?.bannerStyling==="banner_styling_variant_3"}),children:[!eo&&eK&&(0,t.jsx)(t.Fragment,{children:eK}),eo&&eV&&(0,t.jsx)(t.Fragment,{children:eX}),eo&&ez&&(0,t.jsx)(t.Fragment,{children:eQ})]})}),eJ&&(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)("div",{className:(0,n.default)({"tw-mt-wdsSpacingMd":R?.bannerStyling==="banner_styling_variant_3"}),children:eJ})}),eB]})}),!ei&&(0,t.jsx)(an.GridOuterArea,{gridArea:"sidebar",children:(0,t.jsxs)(aQ,{datePublished:es?R?.datePublished?.time:null,stickySidebar:e2,variant:f,children:[ea?(0,t.jsxs)(t.Fragment,{children:[eK&&(0,t.jsx)("div",{className:"tw-hidden md:tw-block",children:eK}),eJ&&(0,t.jsx)("div",{className:"tw-hidden md:tw-block",children:eJ}),V?.length>0&&(0,t.jsx)("div",{className:"c-page-sidebar__topics tw-hidden md:tw-block",children:(0,t.jsx)(a7.default,{tags:V})})]}):null,eo?(0,t.jsxs)(t.Fragment,{children:[eV&&(0,t.jsx)("div",{className:"tw-hidden md:tw-block",children:eX}),ez&&(0,t.jsx)("div",{className:"tw-hidden md:tw-block",children:eQ})]}):null,eo?eH:eU]})}),(0,t.jsx)(an.GridOuterArea,{className:"c-sections-container",gridArea:"content",children:(0,t.jsxs)("div",{id:"page-sections",className:(0,n.default)("o-scroll-offset",{"_u-offset-tertiary":ek}),children:[ev&&(0,t.jsx)(J.default,{className:"tw-mb-wdsSpacingMd tw-hidden md:tw-grid",children:eB}),R?.includeAudioPlayer&&R?.audioFilename&&(0,t.jsx)(J.default,{className:"tw-pb-scaffold",children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)(x,{audioFile:R?.audioFilename,title:R.title})})}),ej&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(J.default,{children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)(W.default,{className:"tw-pl-0 tw-text-wdsInformation-dark",variant:"notification",children:(0,t.jsx)("p",{children:"This article contains dynamic scrolling. You can switch it off at any time."})})})}),(0,t.jsx)(J.default,{className:"tw-mb-wdsSpacing400 md:tw-hidden",children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)("div",{className:"tw-flex tw-items-center",children:[(0,t.jsx)("h2",{className:"tw-mr-wdsSpacing100 tw-block tw-text-wdsF-2 tw-font-normal",children:"Read as"}),(0,t.jsx)(ac.default,{})]})})})]}),F?.map(e=>{if("ParagraphHeroStatement"===e.__typename)return(0,t.jsx)(aS.default,{className:"tw-mb-wdsSpacingXl",id:e.anchorId,title:e.sectionTitle,children:(0,t.jsxs)(J.default,{children:[(0,t.jsx)(Z.GridColumn,{spanGroup:"extendedLeft",children:(0,t.jsx)(ai.default,{href:e.link?.url,linkText:e.link?.title,text:e.statement?.processed})}),e.quickLinks?.length>0&&(0,t.jsx)(Z.GridColumn,{className:"md:tw-col-span-4",children:(0,t.jsx)(aw.default,{as:"ul",children:e.quickLinks?.map((e,a)=>(0,t.jsx)(ab.ListingLink,{href:e.url,title:e.title},`quick-links-item-${a+1}`))})})]})},e.id);if("ParagraphModal"===e.__typename){let a=rm(e);return Q=!0,(0,t.jsx)(aT,{body:a.body,buttons:a.buttons,onAccept:()=>X(!0),title:a.title},a.id)}if("ParagraphMarkup"===e.__typename)return(0,t.jsx)(a2.default,{type:"markup",children:(0,t.jsx)(j.default,{markupToEmbed:e.embeddedMarkup?.processed})},e.id);if("ParagraphForms"===e.__typename)return ee&&(0,t.jsx)(t9,{variant:e.formType},e.id);if("ParagraphNewsletter"===e.__typename)return(0,t.jsx)(ak.default,{inpageId:e.anchorId,intro:e.body?.processed,title:e.title,type:e.newsletterSignupType,variant:e.newsletterStyle},e.id);
144if("ParagraphTwoColumnGroup"===e.__typename)return(0,t.jsx)(aS.default,{className:"tw-mb-wdsSpacingMd",id:e.anchorId,layoutVariant:"fullWidth",title:e.sectionTitle,children:(0,t.jsxs)(J.default,{children:[(0,t.jsx)(Z.GridColumn,{className:"sm:tw-col-start-2 sm:tw-col-end-12 md:tw-col-span-6",children:(0,t.jsx)(ro,{slice:e.leftAlignedContent})}),(0,t.jsx)(Z.GridColumn,{className:"sm:tw-col-start-2 sm:tw-col-end-12 md:tw-col-span-6",children:(0,t.jsx)(ro,{slice:e.rightAlignedContent})})]})},e.id);if("ParagraphVerticalTab"===e.__typename)return null;if("ParagraphSection"===e.__typename&&e.carouselData)return(0,t.jsx)(aS.default,{className:"tw-mb-wdsSpacingMd",id:e.anchorId,title:e.sectionTitle,children:(0,t.jsx)(ad,{data:e.carouselData})},e.id);if("ParagraphSection"!==e.__typename&&"ParagraphSectionLanding"!==e.__typename)return null;{let a=(0,rf.default)(F,er);return ee&&(0,t.jsx)(aS.default,{className:(0,n.default)({"c-section--tint-bg c-section--neutral-light tw-pb-wdsSpacingMd":"neutral_light"===e.stylingOptions,"c-section--tint-bg c-section--neutral-dark tw-pb-wdsSpacingMd":"neutral_dark"===e.stylingOptions,"c-section--tint-bg c-section--neutral-blue tw-pb-wdsSpacingMd":"neutral_blue"===e.stylingOptions}),id:e.anchorId,title:e.sectionTitle,children:(0,rg.default)({slice:e.contentSlicesRef,parentAnchorId:e.anchorId,timelineSlices:a,pageType:q,fundingScheme:ef})},e.id)}}),eh&&$.length>0&&(0,t.jsx)(ri,{activeTab:ex,onSelectTab:ew,pageTitle:R?.title,tabGroups:$,renderSection:e=>(0,t.jsx)(aS.default,{id:e.anchorId,title:e.title||e.sectionTitle,children:(0,rg.default)({slice:e.contentSlicesRef,parentAnchorId:e.anchorId,timelineSlices:(0,rf.default)(F,er),pageType:q,fundingScheme:ef})},e.id)}),Y&&(0,t.jsx)(aS.default,{id:Y.id,title:Y.sectionTitle,children:(0,t.jsx)(a2.default,{type:"link_list",children:(0,t.jsx)(aw.default,{children:Y.items.map(e=>(0,t.jsx)(ab.ListingLink,{href:e.path,title:(0,at.default)(e.label)},`Sibling Navigation: ${e.label}`))})})},Y.id),(N||w||T)&&(0,t.jsx)(aj.default,{className:"tw-mb-wdsSpacingXl",children:(0,t.jsxs)(J.default,{children:[(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsxs)(W.default,{children:[N&&(0,t.jsx)(aw.default,{as:"ul",children:(0,t.jsx)(ab.ListingLink,{href:N.href,title:g||N.title})}),S&&(0,t.jsxs)("p",{children:["Year of award: ",(0,t.jsx)("strong",{children:S})]})]})}),w&&(0,t.jsxs)(Z.GridColumn,{spanGroup:"center",children:[(0,t.jsx)(u.default,{wrapperAs:"h2",children:"Grantholders"}),(0,t.jsx)("div",{className:"tw-mb-wdsSpacingMd",children:(0,t.jsx)("ul",{className:"tw-list-none",children:w?.map(e=>(0,t.jsx)("li",{children:(0,t.jsx)(aa,{className:"tw-mb-wdsSpacingSm",country:e.country,institution:e.institution,name:e.name})},e.id))})})]}),T&&(0,t.jsxs)(Z.GridColumn,{spanGroup:"center",children:[(0,t.jsx)(u.default,{wrapperAs:"h2",children:"Project summary"}),(0,t.jsx)("div",{dangerouslySetInnerHTML:{__html:(0,at.default)(T)}})]})]})})]})}),(U||C)&&(0,t.jsxs)(an.GridOuterArea,{gridArea:"footer",children:[V?.length>0&&(0,t.jsx)(J.default,{className:"tw-pb-scaffold md:tw-hidden print:tw-hidden",children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)(a7.default,{isPlainList:!0,tags:V})})}),U?.map(e=>(0,t.jsx)(aS.default,{className:"print:tw-hidden",id:e.anchorId,title:e.sectionTitle,children:e?.contentSlicesRef?.map(e=>{if("ParagraphText"===e.__typename)return(0,t.jsx)(a2.default,{type:"text",children:(0,t.jsx)(K.default,{children:e.body?.processed})},e.id);return(0,rp.default)(e)})},e.id)),(ea||eo)&&(0,t.jsx)(J.default,{className:"tw-pb-scaffold md:tw-hidden",children:(0,t.jsx)(Z.GridColumn,{spanGroup:"center",children:(0,t.jsx)(a8.default,{body:R?.standfirst,isCollapsible:!0,title:R?.title,url:I})})}),C?.map(e=>(0,t.jsx)(ak.default,{intro:e.body?.processed,title:e.title,type:e.newsletterSignupType,variant:"footer"},e.id))]})]}),!1]})}}],65614),e.s([],722333)}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.