PageSourceSearch

https://projectforawesome.com/static/js/990.cb4eafa5.chunk.js

js projectforawesome.com collected 2026-10-02 03:34:36 UTC 2,250 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunkp4a_react_frontend=self.webpackChunkp4a_react_frontend||[]).push([[990],{990:(e,a,r)=>{r.r(a),r.d(a,{default:()=>p});var s=r(5043),t=r(9981),n=r(3519),i=r(1719),o=r(7417),c=r(9082),u=r(579);function p(){const[e]=(0,t.ok)(),a=(0,t.Zp)(),[r,p]=(0,s.useState)(null),g=(0,s.useMemo)(()=>function(e){const a=String(e||"").toLowerCase();return a?"home"===a||"homepage"===a||"api::homepage.homepage"===a?"homepage":"faq"===a||"faq-page"===a||a.includes("faq-page")?"faq-page":a.includes("videos-takeover-page")?"videos-takeover-page":"current-year"===a||"current-year-page"===a||a.includes("current-year-page")?"current-year-page":"previous-year"===a||a.includes("previous-year")?"previous-year":"who-we-are"===a||a.includes("who-we-are")?"who-we-are":a.includes("submission-confirmation-page")?"submission-confirmation-page":"submission"===a||a.includes("submission")?"submission":"page"===a||a.includes("page")?"page":a:""}(e.get("type")||e.get("contentType")),[e]),d=e.get("secret")||"";return(0,s.useEffect)(()=>{const r="07d4ada883f58a2e407d2d8fba0dc864";if(!d||d!==r)return void p("Invalid preview secret.");console.log("Enabling preview mode"),(0,c.ud)();try{const a={type:g,slug:e.get("slug")||e.get("Slug")||null};sessionStorage.setItem("p4a_preview_target",JSON.stringify(a))}catch{}const s=function(e,a){const r=a.get("slug")||a.get("Slug")||"";switch(e){case"homepage":default:return"/";case"faq-page":return"/faq";case"videos-takeover-page":return"/videos";case"current-year-page":return"/schedule";case"previous-year":return"/recap";case"who-we-are":return"/who-we-are";case"submission-confirmation-page":return"/nominate-a-charity?preview=success";case"submission":return r?`/videos/${r}`:"/videos";case"page":return r?`/${r}`:"/"}}(g,e)||"/";try{sessionStorage.setItem("p4a_preview_path",s)}catch{}const t=new URL(window.location.origin+s);t.searchParams.set("preview","1");const n=setTimeout(()=>{a(t.pathname+t.search,{replace:!0})},10);return()=>clearTimeout(n)},[g,d,a,e]),r?(0,u.jsx)(n.A,{className:"mt-4",children:(0,u.jsx)(i.A,{variant:"danger",children:r})}):(0,u.jsx)(n.A,{className:"mt-4 text-center",children:(0,u.jsx)(o.A,{animation:"border"})})}}}]);
2//# sourceMappingURL=990.cb4eafa5.chunk.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.