PageSourceSearch

https://growithjane.com/_next/static/chunks/app/%5Blocale%5D/(fron…/explore/page-1977a5ee97098edf.js

js growithjane.com collected 2026-10-01 16:31:41 UTC 12,750 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9435],{14538:(e,t,l)=>{"use strict";l.d(t,{A:()=>u});var a=l(95155),i=l(12115),o=l(85005),n=l(9713),s=l(67382),c=l(86599),r=l(15305),d=l(20193),g=l(34105);function u(e){let{className:t="",items:l,name:u,link:m,collection:p,campaign:h,loadFromCollection:x}=e,[v,f]=(0,i.useState)(l),[b,j]=(0,i.useState)(x&&(!l||0===l.length)),w={align:"start",slidesToScroll:2,containScroll:"trimSnaps",loop:(null==v?void 0:v.length)>3},[N,y]=(0,o.A)(w),k=(null==p?void 0:p._id)||"collection-".concat(null==u?void 0:u.toLowerCase().replace(/\s+/g,"-")),{trackCarouselInteraction:S,trackItemClick:_,carouselRef:C}=(0,d.A)({carouselId:k,carouselName:u||"Unnamed Collection",itemCount:(null==v?void 0:v.length)||0,breederId:null==h?void 0:h.breederId,collectionId:null==p?void 0:p._id,campaignId:null==h?void 0:h._id,campaignType:null==h?void 0:h.type}),E=(0,i.useCallback)(()=>{y&&(y.scrollPrev(),S("Previous"))},[y,S]),P=(0,i.useCallback)(()=>{y&&(y.scrollNext(),S("Next"))},[y,S]);(0,i.useEffect)(()=>{x&&(!l||0===l.length)&&(async()=>{try{j(!0);let e={};p.pageSize&&(e.pageSize=p.pageSize),p.page&&(e.page=p.page),(null==p?void 0:p.slug)&&(e.slug=p.slug),(null==p?void 0:p._id)&&(e.id=p._id);let t=await s.f.getCollection(e);f(t.growlogs)}catch(e){console.error("Failed to load collection:",e)}finally{j(!1)}})()},[x,null==p?void 0:p.slug,l]);let A=(0,a.jsxs)("h2",{id:"category-heading",className:"text-lg tracking-tight text-secondary font-semibold gap-2 inline-flex items-center","data-testid":"collection-carousel-title",children:[u,(0,a.jsx)(c.A,{})]});return b?(0,a.jsxs)("section",{"aria-labelledby":"category-heading",className:"xl:mx-auto xl:max-w-7xl "+t,"data-testid":"collection-carousel",children:[(0,a.jsx)("div",{className:"flex items-center justify-between mb-2","data-testid":"collection-carousel-title-container",children:m?(0,a.jsx)(g.N_,{href:m,children:A}):A}),(0,a.jsx)("div",{className:"flex scrollbar-width-0 w-full overflow-x-auto pb-2","data-testid":"collection-carousel-loading",children:[1,2,3,4,5,6].map(e=>(0,a.jsx)("div",{className:"flex-[0_0_auto] mx-2 my-4 w-[min(44vw,220px)] sm:w-[220px] aspect-[6/10] flex-shrink-0 bg-surface-container animate-pulse rounded-lg"},e))})]}):(0,a.jsxs)("section",{"aria-labelledby":"category-heading",className:"xl:mx-auto xl:max-w-7xl "+t,"data-testid":"collection-carousel",children:[(0,a.jsx)("div",{className:"flex items-center justify-between mb-2","data-testid":"collection-carousel-title-container",children:m?(0,a.jsx)(g.N_,{href:m,children:A}):A}),(0,a.jsxs)("div",{className:"relative group/carousel",ref:C,children:[(0,a.jsx)("div",{ref:N,className:"overflow-hidden",children:(0,a.jsx)("div",{className:"flex -mx-2",children:null==v?void 0:v.map((e,t)=>(0,a.jsx)("div",{className:"flex-[0_0_auto] px-2 py-4 w-[min(44vw,220px)] sm:w-[220px]","data-testid":"collection-carousel-slide",children:(0,a.jsx)(n.A,{growlog:e,className:"",onClick:()=>{var l;return _(e.id||e._id||e.slug,(null===(l=e.tree)||void 0===l?void 0:l.name)||e.name||"Unnamed Growlog",t)}})},t))})}),(0,a.jsx)("button",{onClick:E,className:" absolute hidden lg:flex items-center left-0 group-hover/carousel:opacity-100 opacity-0 top-4 bottom-4 transition py-4 bg-gradient-to-r from-[rgba(0,0,0,0.7)] via-[rgba(0,0,0,0.5)] to-[rgba(0,0,0,0)] px-4 text-white stroke-4 z-10 ","data-testid":"collection-carousel-prev-button",children:(0,a.jsx)(r.Y5o,{className:"font-bold"})}),(0,a.jsx)("button",{onClick:P,className:" absolute hidden lg:flex items-center right-0 top-4 bottom-4 group-hover/carousel:opacity-100 transition opacity-0 bg-gradient-to-r from-[rgba(0,0,0,0)] via-[rgba(0,0,0,0.5)] to-[rgba(0,0,0,0.7)] text-white px-4 py-4 border-gray-700 text-sm z-10 ","data-testid":"collection-carousel-next-button",children:(0,a.jsx)(r.xyO,{})})]}),(0,a.jsx)("div",{className:"mt-6 px-4 hidden","data-testid":"collection-carousel-see-all-link",children:(0,a.jsxs)("a",{className:"block text-sm font-semibold text-primary",children:["See All",(0,a.jsx)("span",{"aria-hidden":"true",children:" →"})]})})]})}},18295:(e,t,l)=>{Promise.resolve().then(l.bind(l,20827)),Promise.resolve().then(l.bind(l,27426)),Promise.resolve().then(l.bind(l,58992))},20827:(e,t,l)=>{"use strict";l.d(t,{default:()=>m});var a=l(95155),i=l(12115),o=l(21513),n=l(34105),s=l(31441),c=l(72152),r=l(88891),d=l(45741),g=l(92607),u=l(17652);function m(){let e=(0,n.rd)(),{searchValue:t,setSearchValue:l}=(0,o.S)(""),m=(0,s.A)(t,500),[p,h]=(0,i.useState)(!1),{user:x,loading:v}=(0,r.A)(),[f,b]=(0,i.useState)(null),[j,w]=(0,i.useState)(!1),N=(0,u.c)("explore");return((0,i.useEffect)(()=>(l(""),h(!0),()=>h(!1)),[]),(0,i.useEffect)(()=>{p&&t&&(e.push("/growlogs/search/"+t),(0,c.H5)({category:"Search",action:"Explore Search",label:t,value:t,page:"explore"}))},[m,p]),(0,i.useEffect)(()=>{let e=()=>{l("")};return window.addEventListener("popstate",e),()=>{window.removeEventListener("popstate",e)}},[l]),(0,i.useEffect)(()=>{x&&(w(!0),(0,g.j)(16,0).then(e=>b(e)).catch(()=>b([])).finally(()=>w(!1)))},[x]),v||!x||j||null===f)?(0,a.jsx)(a.Fragment,{}):0===f.length?(0,a.jsx)(a.Fragment,{}):(0,a.jsx)("div",{className:"mb-8",children:(0,a.jsx)(d.A,{title:N("fromFollowedGrowers"),url:"/account/connections",initialGrowlogs:f,emptyText:N("followGrowersEmpty")})})}},27426:(e,t,l)=>{"use strict";l.d(t,{default:()=>s});var a=l(95155),i=l(12115),o=l(8005),n=l(14538);
1function s(e){let{contentBlocks:t,children:l}=e,s=(0,i.useMemo)(()=>t.filter(e=>{var t;return(null===(t=e.campaign)||void 0===t?void 0:t.type)!=="collection-article"}).sort((e,t)=>e.weight===t.weight?Math.random()-.5:t.weight-e.weight),[t]);return(0,a.jsxs)(a.Fragment,{children:[s.map((e,t)=>{var l,s,c,r;let d=(null===(s=e.collections)||void 0===s?void 0:null===(l=s[0])||void 0===l?void 0:l.slug)?"/collection/"+e.collections[0].slug:"";return(null===(c=e.campaign)||void 0===c?void 0:c.linkType)==="breederPage"?d="/breeder/"+(e.breederSlug||e.campaign.breederId):(null===(r=e.campaign)||void 0===r?void 0:r.linkType)==="collectionPage"&&(d="/collection/"+e.campaign.slug),(0,a.jsxs)(i.Fragment,{children:[e.collections&&e.collections.length>0&&(0,a.jsx)(n.A,{loadFromCollection:!1,collection:e.collections[0],campaign:e.campaign,items:e.growlogs||[],name:e.collections[0].title,link:d}),(1===t||4===t||7===t||10===t)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"hidden md:block [&:not(:empty)]:my-8 [&:empty]:absolute justify-center",children:(0,a.jsx)(o.u,{placement:"explore.in-feed-desktop-"+(t-1)/3})}),(0,a.jsx)("div",{className:"md:hidden [&:not(:empty)]:my-8 [&:empty]:absolute flex justify-center",children:(0,a.jsx)(o.u,{placement:"explore.in-feed-mobile-"+(t-1)/3})})]})]},e.name)}),l]})}},58992:(e,t,l)=>{"use strict";l.d(t,{default:()=>r});var a=l(95155),i=l(12115),o=l(85005),n=l(15305),s=l(20193),c=l(34105);function r(e){var t,l;let{articles:r}=e,d=r.length>1,g=1===r.length?r[0]:null,u=2===r.length?"flex-[0_0_100%] md:flex-[0_0_50%]":"flex-[0_0_100%] md:flex-[0_0_50%] lg:flex-[0_0_33.333%]",m={align:"start",slidesToScroll:1,containScroll:"trimSnaps",loop:r.length>3},[p,h]=(0,o.A)(m),{trackCarouselInteraction:x,trackItemClick:v,trackSlideVisibility:f,carouselRef:b}=(0,s.A)({carouselId:"collection-articles-carousel",carouselName:"Collection Articles Carousel",itemCount:r.length,campaignId:null===(l=r[0])||void 0===l?void 0:null===(t=l.campaign)||void 0===t?void 0:t._id}),j=(0,i.useCallback)(()=>{if(h){let e=h.selectedScrollSnap(),t=r[e];f({breederId:t.campaign.breederId,campaignId:t.campaign._id,campaignTitle:t.campaign.title,position:e})}},[h,r,f]);i.useEffect(()=>(h&&(h.on("select",j),j()),()=>{h&&h.off("select",j)}),[h,j]);let w=(0,i.useCallback)(()=>{h&&(h.scrollPrev(),x("Previous"))},[h,x]),N=(0,i.useCallback)(()=>{h&&(h.scrollNext(),x("Next"))},[h,x]);return g?(0,a.jsx)("div",{className:"relative group/carousel",ref:b,"data-testid":"collection-articles-carousel",children:(0,a.jsxs)(c.N_,{href:"/collection/".concat(g.campaign.slug),className:"block group mb-4",onClick:()=>v(g.campaign.id||g.id||"0",g.campaign.title||"Unnamed Article",0),"data-testid":"collection-articles-carousel-slide-link",children:[(0,a.jsx)("div",{className:"overflow-hidden rounded-2xl bg-surface-container-low","data-testid":"collection-articles-carousel-slide-image",children:(0,a.jsxs)("picture",{children:[g.campaign.landscapeImage&&(0,a.jsx)("source",{media:"(min-width: 768px)",srcSet:g.campaign.landscapeImage}),(0,a.jsx)("img",{src:g.campaign.image||g.campaign.landscapeImage,alt:g.campaign.title,className:"w-full h-64 md:h-80 object-cover transition-transform duration-300 group-hover:scale-105"})]})}),(0,a.jsx)("div",{className:"pt-3 px-1","data-testid":"collection-articles-carousel-slide-title",children:(0,a.jsx)("h3",{className:"text-on-surface text-lg font-medium line-clamp-2",children:g.campaign.title})})]})}):(0,a.jsxs)("div",{className:"relative group/carousel",ref:b,"data-testid":"collection-articles-carousel",children:[(0,a.jsx)("div",{ref:p,className:"overflow-hidden mb-4",children:(0,a.jsx)("div",{className:"flex -mx-2","data-testid":"collection-articles-carousel-slides",children:r.map((e,t)=>(0,a.jsx)("div",{className:"".concat(u," px-2"),"data-testid":"collection-articles-carousel-slide",children:(0,a.jsxs)(c.N_,{href:"/collection/".concat(e.campaign.slug),className:"block group",onClick:()=>v(e.campaign.id||e.id||t.toString(),e.campaign.title||"Unnamed Article",t),"data-testid":"collection-articles-carousel-slide-link",children:[(0,a.jsx)("div",{className:"overflow-hidden rounded-2xl bg-surface-container-low","data-testid":"collection-articles-carousel-slide-image",children:(0,a.jsx)("img",{src:e.campaign.image,alt:e.campaign.title,className:"w-full h-64 object-cover transition-transform duration-300 group-hover:scale-105"})}),(0,a.jsx)("div",{className:"pt-3 px-1","data-testid":"collection-articles-carousel-slide-title",children:(0,a.jsx)("h3",{className:"text-on-surface text-lg font-medium line-clamp-2",children:e.campaign.title})})]})},t))})}),d&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{onClick:w,className:"absolute rounded-2xl left-0 top-0 h-64 group-hover/carousel:opacity-100 opacity-0 transition bg-gradient-to-r from-[rgba(0,0,0,0.5)] to-[rgba(0,0,0,0)] px-4 text-white z-10 flex items-center","data-testid":"collection-articles-carousel-prev-button",children:(0,a.jsx)(n.Y5o,{className:"font-bold"})}),(0,a.jsx)("button",{onClick:N,className:"absolute rounded-2xl right-0 top-0 h-64 group-hover/carousel:opacity-100 opacity-0 transition bg-gradient-to-r from-[rgba(0,0,0,0)] to-[rgba(0,0,0,0.5)] px-4 text-white z-10 flex items-center","data-testid":"collection-articles-carousel-next-button",children:(0,a.jsx)(n.xyO,{})})]})]})}},67382:(e,t,l)=>{"use strict";l.d(t,{f:()=>a});
1class a{static async getRegionContent(e){let{page:t,region:l="default"}=e,a={page:t.toString(),region:l.toString(),apiVersion:"2"};t&&(a.pageId=t),l&&(a.regionId=l);let i=new URL(this.getRegionContentPath,this.baseUrl);Object.keys(a).forEach(e=>i.searchParams.append(e,a[e]));let o=await fetch(i.toString(),{next:{revalidate:300}});if(o.ok){let e=await o.json();if(e.contentBlocks){let t=e.contentBlocks.map(async e=>{if(e.collections&&e.collections.length>0){let t=e.collections[0];try{let l={pageSize:(t.pageSize||24).toString(),page:(t.page||1).toString()};t.slug&&(l.slug=t.slug),t._id&&(l.id=t._id),e.growlogs=(await this.getCollection(l)).growlogs||[]}catch(l){console.error("Failed to fetch growlogs for collection ".concat(t._id||t.slug,":"),l),e.growlogs=[]}}return e});e.contentBlocks=await Promise.all(t)}return e}throw Error("Error fetching content")}static async getCollection(e){let{slug:t,id:l,page:a=1,pageSize:i=24}=e,o={page:a.toString(),pageSize:i.toString()};t&&(o.slug=t.toString()),l&&(o.id=l.toString());let n=new URL(this.getCollectionPath,this.baseUrl);Object.keys(o).forEach(e=>n.searchParams.append(e,o[e]));let s=await fetch(n.toString(),{next:{revalidate:300}});if(s.ok){let e=await s.json();return e.growlogs=e.growlogs.map(e=>{var t,l,a;return e.tree=e.tree||(null==e?void 0:null===(t=e.data)||void 0===t?void 0:t.tree)||null,e.environment=e.environment||(null==e?void 0:null===(l=e.data)||void 0===l?void 0:l.environment)||null,e.strain=e.strain||(null==e?void 0:null===(a=e.data)||void 0===a?void 0:a.strain)||null,e}),e.hasMore=e.growlogs.length===i,e}throw Error("Error fetching collection")}}a.baseUrl="https://api.growithjane.com/",a.getRegionContentPath="/public/regionBlocks/getRegionContent",a.getCollectionPath="/public/collections/getCollectionContent"}},e=>{var t=t=>e(e.s=t);e.O(0,[7138,8087,586,6711,2992,9292,6874,6990,9641,3932,8096,5753,1313,2306,2156,3877,8441,1684,7358],()=>t(18295)),_N_E=e.O()}]);

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.