1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[678],{71234:function(e,t,n){n.d(t,{Z:function(){return a}});var r=n(85893);const a=e=>{let{className:t="",children:n,size:a="large",corner:s="rounded"}=e;return(0,r.jsx)("div",{className:"bg-white text-ivoryBlack transition-shadow duration-300 ease-in-out overflow-hidden mb-1 ".concat((()=>{switch(s){case"square":default:return"";case"rounded":return"rounded-[10px] "}})()," ").concat((()=>{switch(a){case"small":return"p-4";case"medium":return"p-7";case"large":return"p-5 md:p-10";default:return""}})()," ").concat(t),children:n})}},33441:function(e,t,n){n.d(t,{F:function(){return l}});var r=n(85893),a=n(20373),s=n(7515);const l=()=>(0,r.jsx)(s.T3,{title:"Redirecting...",children:(0,r.jsx)(a.Z,{cssOverride:{display:"block"},className:"m-auto"})})},58750:function(e,t,n){n.d(t,{m:function(){return u}});var r=n(85893),a=n(29171),s=(n(39713),n(49336)),l=n(67294),i=n(50788),o=n(82999),c=n(44156);const u=e=>{let{ButtonComponent:t=o.B,actions:n,buttonComponentProps:u,children:d,className:p="",dropdownTrigger:m="click",linkProps:f,hideChevron:x=!1}=e;const[h,b]=(0,l.useState)(!1);return(0,r.jsx)(a.Z,{animation:"slide-up",onVisibleChange:()=>b(!h),placement:"bottomRight",trigger:m,visible:h,overlay:(0,r.jsx)(s.ZP,{children:n.map(((e,t)=>{return a=t,(n=e).isSeperator?(0,r.jsx)(s.ZP.Divider,{},"divider-".concat(a)):n.href?(0,r.jsx)(s.ck,{disabled:n.disabled,className:"".concat(n.disabled?"":"hover:bg-limeBright/20!"," ").concat(n.style||""),children:n.disabled?(0,r.jsxs)("span",{className:"text-cloudGrey font-medium cursor-default",children:[n.text,n.icon]}):(0,r.jsxs)(c.h$,{color:"none",className:"flex flex-row justify-between items-center w-full text-forestDeep",href:n.href,...f,children:[n.avatar?(0,r.jsx)("span",{className:"mr-2 h-6",children:n.avatar}):null,n.text,n.icon]})},n.text):(0,r.jsx)(s.ck,{className:"".concat(n.disabled?"":"hover:bg-limeBright/20!"," ").concat(n.style||""),disabled:n.disabled,children:n.disabled?(0,r.jsxs)("span",{className:"text-cloudGrey font-medium cursor-default",children:[n.text,n.icon]}):(0,r.jsxs)(c.Hp,{color:"forestDeep",className:"flex flex-row justify-between items-center w-full",onClick:n.onClick,...f,children:[n.avatar?(0,r.jsx)("span",{className:"mr-2 h-6",children:n.avatar}):null,n.text,n.icon]})},n.text);var n,a}))}),children:(0,r.jsx)("div",{className:p,children:(0,r.jsx)(t,{...u,children:(0,r.jsxs)("div",{className:"flex items-center",children:[d,!x&&(0,r.jsx)("span",{className:"ml-1 mr[-4px]",children:h?(0,r.jsx)(i.rWj,{size:"20px"}):(0,r.jsx)(i.Ix0,{size:"20px"})})]})})})})}},11872:function(e,t,n){n.d(t,{m:function(){return l}});var r=n(85893),a=n(67294);const s=e=>{let{isActive:t,label:n,onClick:s,value:l,disabled:i}=e;const{scrollIntoView:o,ref:c}=function(){const[e,t]=(0,a.useState)(!1),[n,r]=(0,a.useState)(null),[s,l]=(0,a.useState)(!1),i=(0,a.useCallback)((e=>{null!==e&&r(e)}),[]);(0,a.useEffect)((()=>{if(n&&!e){const e=new IntersectionObserver((e=>{let[n]=e;t((null===n||void 0===n?void 0:n.isIntersecting)||!1),l(!0)}));return e.observe(n),()=>{e.disconnect()}}}),[e,n]);const o=(0,a.useCallback)((()=>{if(!e&&n&&s){const e=n.closest(".no-scrollbar");
1if(e){const t=e.getBoundingClientRect(),r=n.getBoundingClientRect(),a=r.left+r.width/2-(t.left+t.width/2);e.scrollBy({left:a,behavior:"smooth"})}}}),[e,n,s]);return{isInViewport:e,scrollIntoView:o,ref:i}}();return(0,a.useEffect)((()=>{t&&o()}),[t,o]),(0,r.jsx)("button",{ref:c,disabled:i,className:"text-base font-bold inline-flex items-center justify-center box-border bg-transparent outline-current outline-none outline-0 m-0 cursor-pointer select-none align-middle appearance-none no-underline font-body uppercase max-w-[360px] min-w-[90px] relative min-h-[48px] shrink-0 py-3 px-4 overflow-hidden whitespace-normal text-center flex-direction-column ".concat(t?"text-forestDeep border-b-2 border-b-forestDeep pb-2.5":"text-forestDeep/80 border-0"," ").concat(i?"text-iron! pointer-events-none":""),onClick:()=>s(l),role:"tab","aria-selected":t,type:"button",children:n})},l=e=>{let{activeTab:t,ariaLabel:n,className:a="",onChange:l,tabs:i}=e;return(0,r.jsx)("div",{"aria-label":n,className:"w-full overflow-x-auto no-scrollbar min-h-[48px] ".concat(a),children:(0,r.jsx)("div",{className:"inline-block relative flex-auto whitespace-nowrap",children:(0,r.jsx)("div",{className:"flex",children:i.map((e=>(0,r.jsx)(s,{isActive:t===e.value,label:e.label,value:e.value,onClick:l,disabled:e.disabled,path:e.path},e.value)))})})})}},50173:function(e,t,n){n.d(t,{lB:function(){return j},u1:function(){return h}});var r=n(85893),a=n(11163),s=n(71234),l=n(23065),i=n(11872),o=n(89827),c=n(67294),u=n(55346),d=n(13508),p=n(70090),m=n(58750),f=n(27518);const x=e=>{let{projectId:t,publicPage:n,projectUri:a,className:s="",featuredOn:l}=e;const{openModal:i}=(0,p.dd)(),{isStaff:o}=(0,d.a)(),x=(0,c.useMemo)((()=>{const e=n&&a?(0,f.Il)({routeParams:{uri:a}}):(0,f.Yn)({routeParams:{projectId:t}}),s=[{text:"Edit project",href:(0,f.Nv)({routeParams:{projectId:t}})},{text:"",isSeperator:!0},{text:"Change website visibility",icon:n?(0,r.jsx)(u.dSq,{className:"ml-2"}):(0,r.jsx)(u.tgn,{className:"ml-2"}),onClick:()=>i(p.w8.UpdateProjectVisibility,{projectId:t,publicPage:n,isAdmin:!0})},{text:"Feature project",icon:l?(0,r.jsx)(u.VF9,{className:"ml-2"}):(0,r.jsx)(u.mCg,{}),onClick:()=>i(p.w8.FeatureProject,{projectId:t,featuredOn:l})},{text:"",isSeperator:!0},{text:"View project page",icon:(0,r.jsx)(u.CkN,{className:"ml-2"}),onClick:()=>window.open(e,"_blank","noopener,noreferrer")}],c=[{text:"Add a field note",href:(0,f.i_)({routeParams:{projectId:t}})}];return o?s.concat(c):c}),[l,i,t,a,n,o]);return x.length?(0,r.jsx)(m.m,{actions:x,className:s,buttonComponentProps:{variant:"outline"},children:"Actions"}):null};var h;
1!function(e){e.Project="details",e.Experience="experience",e.Applications="applications",e.Plantings="plantings",e.Gallery="gallery",e.Funders="funders",e.Map="map",e.Notes="notes"}(h||(h={}));const b=e=>{let{activeTab:t,children:n,project:o,tabs:c,isEdit:u}=e;const d=(0,a.useRouter)();return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(l.nL,{children:o.Name}),(0,r.jsxs)(s.Z,{size:"small",className:"overflow-x-scroll",children:[(0,r.jsxs)("div",{className:"flex justify-between items-center pr-4",children:[(0,r.jsx)(i.m,{className:"mx-4 mt-2",tabs:c,onChange:e=>{if(e===t)return;const n=c.find((t=>t.value===e));n&&d.push(null===n||void 0===n?void 0:n.path)},activeTab:t,ariaLabel:"Application navigation"}),u?null:(0,r.jsx)(x,{projectId:o.Id,projectUri:o.Uri,className:"ml-4",publicPage:o.PublicPage,featuredOn:o.FeaturedOn})]}),(0,r.jsx)("div",{className:"p-4",children:n})]})]})},j=e=>{const t=(0,a.useRouter)(),{projectId:n}=t.query,{data:s}=(0,o.bno)({variables:{id:n}}),l=null===s||void 0===s?void 0:s.Project;if(!l)return null;const i=function(e){return[{label:"Detail",value:h.Project,path:(0,f.L$)({routeParams:{projectId:e.Id}})},{label:"Requests",value:h.Applications,path:(0,f.a3)({routeParams:{projectId:e.Id}})},{label:"Reports",value:h.Plantings,path:(0,f.lC)({routeParams:{projectId:e.Id}})},{label:"Gallery",value:h.Gallery,path:(0,f.m)({routeParams:{projectId:e.Id}})},{label:"Map",value:h.Map,path:(0,f.cl)({routeParams:{projectId:e.Id}})},{label:"Notes",value:h.Notes,path:(0,f.kc)({routeParams:{projectId:e.Id}})}]}(l);return(0,r.jsx)(b,{...e,project:l,tabs:i})}},92251:function(e,t,n){n.d(t,{l:function(){return r.lB},u:function(){return r.u1}});var r=n(50173)},33712:function(e,t,n){n.d(t,{Wb:function(){return d},hN:function(){return m},j_:function(){return f},mL:function(){return p}});var r=n(85893),a=n(88100),s=n(11163),l=n(67294),i=n(13508),o=n(53719),c=n(33441),u=n(27518);const d=e=>function(){const{isLoading:t,isStaff:n}=(0,i.a)(),o=(0,s.useRouter)();(0,l.useEffect)((()=>{t||n||o.replace(u.$x)}),[n,t]);const d=(0,a.u3)(e,{onRedirecting:c.F});return(0,r.jsx)(d,{})},p=e=>function(){const{isLoading:t,isAdvisor:n,isStaff:o}=(0,i.a)(),d=(0,s.useRouter)();(0,l.useEffect)((()=>{t||n||o||d.replace(u.$x)}),[n,o,t]);const p=(0,a.u3)(e,{onRedirecting:c.F});return(0,r.jsx)(p,{})},m=(e,t)=>(0,a.u3)(e,{onRedirecting:c.F,...t}),f=e=>function(){const{user:t,isLoading:n}=(0,o.a)(),a=(0,s.useRouter)(),i=(0,l.useMemo)((()=>!n&&t&&!(null===t||void 0===t?void 0:t.Account)),[t,n]);return(0,l.useEffect)((()=>{i&&a.replace({pathname:(0,u.Yh)(),query:{returnTo:a.asPath}})}),[i,a]),n||i?null:(0,r.jsx)(e,{})}}}]); 2//# sourceMappingURL=678-f07150b6d57da37f.js.map
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.