PageSourceSearch

https://projectforawesome.com/static/js/2227.8ac20f73.chunk.js

js projectforawesome.com collected 2026-10-02 03:34:46 UTC 5,197 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunkp4a_react_frontend=self.webpackChunkp4a_react_frontend||[]).push([[2227],{2227:(e,t,a)=>{a.r(t),a.d(t,{default:()=>l});var n=a(5043),r=a(579);const l=e=>{let{votes:t,raised:a,raisedLoading:l=!1,livestreamStartTime:i,livestreamTimeZone:s,livestreamDefaultMessage:o,showCountdown:d,displayLivestreamButton:c=!1,livestreamButtonLabel:m="Watch P4A Livestream",livestreamButtonUrl:v="/live",visible:u=!0,eventBannerEnabled:x=!1,eventConfig:h}=e;const[b,f]=(0,n.useState)("");(0,n.useEffect)(()=>{if(!d||!i)return;const e=()=>{const e=new Date,t=new Date(i).getTime()-e.getTime();if(t<=0)return void f("00 Days: 00 Hours: 00 Minutes");const a=Math.floor(t/864e5),n=Math.floor(t/36e5%24),r=Math.floor(t/6e4%60);f(`${a.toString().padStart(2,"0")} Days: ${n.toString().padStart(2,"0")} Hours: ${r.toString().padStart(2,"0")} Minutes`)};e();const t=setInterval(e,6e4);return()=>clearInterval(t)},[i,d]);const[g,p]=(0,n.useState)(""),w=(null===h||void 0===h?void 0:h.eventEndsAt)||"",N=x;if((0,n.useEffect)(()=>{if(!w)return void p("");const e=()=>{const e=new Date,t=new Date(w).getTime()-e.getTime();if(t<=6e4)return void p("00 DAYS: 00 HOURS: 00 MINUTES");const a=Math.floor(t/864e5),n=Math.floor(t/36e5%24),r=Math.floor(t/6e4%60);p(`${a.toString().padStart(2,"0")} DAYS: ${n.toString().padStart(2,"0")} HOURS: ${r.toString().padStart(2,"0")} MINUTES`)};e();const t=setInterval(e,1e3);return()=>clearInterval(t)},[w]),!u)return null;const j=e=>!!e&&/^(https?:)?\/\//i.test(e),y=!!(null!==h&&void 0!==h&&h.showPrimaryCta&&null!==h&&void 0!==h&&h.primaryCtaLabel&&null!==h&&void 0!==h&&h.primaryCtaUrl),S=!!(null!==h&&void 0!==h&&h.showSecondaryCta&&null!==h&&void 0!==h&&h.secondaryCtaLabel&&null!==h&&void 0!==h&&h.secondaryCtaUrl);return(0,r.jsxs)("div",{className:"banner-container text-theme-white fw-bold",children:[(0,r.jsx)("div",{className:"bg-theme-extend1 countdown-banner",children:(0,r.jsx)("div",{className:"global-content-wrapper",children:(0,r.jsxs)("div",{className:"px-4 py-2 d-flex justify-content-between align-items-center banner-stats-row",children:[(0,r.jsx)("div",{className:"d-flex flex-column gap-1",children:(0,r.jsxs)("div",{className:"d-flex flex-row gap-3 gap-md-4",children:[(0,r.jsxs)("div",{className:"d-flex flex-column align-items-center text-center",children:[(0,r.jsx)("div",{className:"banner-countdown-text",children:"number"===typeof t?t.toLocaleString():""}),(0,r.jsx)("div",{className:"banner-countdown-label mt-1",children:"Votes"})]}),(0,r.jsxs)("div",{className:"d-flex flex-column align-items-center text-center",children:[(0,r.jsx)("div",{className:"banner-countdown-text",children:"number"===typeof a?`$${a.toLocaleString(void 0,{minimumFractionDigits:2,maximumFractionDigits:2})}`:l?(0,r.jsx)("span",{className:"banner-stat-skeleton","aria-label":"Loading raised amount"}):""}),(0,r.jsx)("div",{className:"banner-countdown-label mt-1",children:"Raised"})]})]})}),c?(0,r.jsx)("div",{className:"text-end",children:(0,r.jsxs)("a",{href:v,target:j(v)?"_blank":void 0,rel:j(v)?"noopener noreferrer":void 0,className:"btn bg-theme-secondary text-white",children:[m,j(v)&&(0,r.jsx)("i",{className:"bi bi-box-arrow-up-right ms-2","aria-hidden":"true"})]})}):(0,r.jsxs)("div",{className:"text-end small livestream-content",children:[(0,r.jsx)("div",{className:"mt-1 banner-countdown-text",children:d&&i?b:o}),(0,r.jsx)("div",{className:"banner-countdown-label",children:"Next livestream"})]})]})})}),N&&(0,r.jsx)("div",{className:"bg-theme-secondary text-white",role:"region","aria-label":"Event countdown",children:(0,r.jsx)("div",{className:"global-content-wrapper",children:(0,r.jsx)("div",{className:"py-3 px-3 rounded",children:(0,r.jsxs)("div",{className:"d-flex flex-column flex-md-row align-items-stretch align-items-md-center justify-content-between gap-2 gap-md-3",children:[(0,r.jsxs)("div",{className:"me-md-3 event-hgroup",children:[(0,r.jsx)("p",{className:"m-0 banner-event-label",children:null===h||void 0===h?void 0:h.eventMessage}),(0,r.jsx)("div",{"aria-live":"polite",className:"banner-event-countdown fw-bold",children:g})]}),(0,r.jsxs)("div",{className:"d-flex flex-column flex-md-row align-items-stretch align-items-md-center gap-2 ms-md-auto",children:[S&&(0,r.jsxs)("a",{href:null===h||void 0===h?void 0:h.secondaryCtaUrl,className:"link-light text-decoration-none",target:j(null===h||void 0===h?void 0:h.secondaryCtaUrl)?"_blank":void 0,rel:j(null===h||void 0===h?void 0:h.secondaryCtaUrl)?"noopener noreferrer":void 0,children:[(0,r.jsx)("span",{className:"me-1",children:null===h||void 0===h?void 0:h.secondaryCtaLabel}),(0,r.jsx)("i",{className:"bi bi-box-arrow-up-right","aria-hidden":"true"})]}),y&&(0,r.jsxs)("a",{href:null===h||void 0===h?void 0:h.primaryCtaUrl,target:j(null===h||void 0===h?void 0:h.primaryCtaUrl)?"_blank":void 0,rel:j(null===h||void 0===h?void 0:h.primaryCtaUrl)?"noopener noreferrer":void 0,className:"btn btn-light text-dark",children:[null===h||void 0===h?void 0:h.primaryCtaLabel,j(null===h||void 0===h?void 0:h.primaryCtaUrl)&&(0,r.jsx)("i",{className:"bi bi-box-arrow-up-right ms-2","aria-hidden":"true"})]})]})]})})})})]})}}}]);
2//# sourceMappingURL=2227.8ac20f73.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.