PageSourceSearch

https://whizco.in/_next/static/chunks/pages/blogs/admin-4c7f4d16f7dcca98.js

js whizco.in collected 2026-10-02 12:12:38 UTC 6,140 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2345],{59372:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/blogs/admin",function(){return s(55861)}])},55861:function(e,t,s){"use strict";s.r(t),s.d(t,{__N_SSP:function(){return j},default:function(){return y}});var a=s(85893),r=s(26728),n=s(11163),l=s(67294),c=s(58533),i=s(88767),o=s(41169),d=s(41664),u=s.n(d),m=s(37986),h=s(86501),x=s(22463),p=s(25675),g=s.n(p);const f=()=>{const[e,t]=(0,l.useState)(""),[s,d]=(0,l.useState)(null),p=(0,n.useRouter)(),{data:f,fetchNextPage:j,hasNextPage:y,refetch:b}=(0,i.useInfiniteQuery)(["Blog",e],(async t=>{let{pageParam:s=0}=t;const a=await(0,r._Z)(s,"15",e,!0);return{results:a.results,next:a.next}}),{getNextPageParam:(e,t)=>{if(e.next)return t.length}});return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(m.Z,{deletingList:async e=>{if(e){if((await(0,r.mL)(s)).status)return b(),void h.Am.success("Deleted Successfully");h.Am.error("Something went wrong")}}}),(0,a.jsx)(o.E,{setSearchKeyword:t,searchKeyword:e}),f?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"container mt-4",children:(0,a.jsx)(u(),{href:"/blogs/add?admin=true",children:(0,a.jsx)("a",{children:(0,a.jsxs)("button",{className:"btn btnGreen my-lg-2 my-md-0",children:[(0,a.jsx)(x.wEH,{className:"me-2"}),"Add Blog"]})})})}),(0,a.jsx)("div",{className:"container mt-5 px-4",children:(0,a.jsx)(c.Z,{dataLength:f?15*f.pages.length:15,next:j,hasMore:y,loader:(0,a.jsx)("p",{children:"loading..."}),children:(0,a.jsx)("div",{className:"row",children:null===f||void 0===f?void 0:f.pages.map((e=>e.results&&e.results.map(((e,t)=>(0,a.jsx)("div",{className:"col-md-3",children:(0,a.jsxs)("div",{className:"blogsmallcard",children:[(0,a.jsx)("div",{className:"relative",style:{height:"10.62rem"},children:(0,a.jsx)(g(),{src:e.image,quality:30,layout:"fill",objectFit:"cover",alt:e.title})}),(0,a.jsx)("p",{className:"bigcardh mb-1 mt-2 line2",children:e.title}),(0,a.jsx)("p",{className:"fsize12 gray mb-1",children:new Date(e.created_at).toLocaleDateString("en-us",{day:"numeric",month:"long",year:"numeric"})}),(0,a.jsx)("p",{className:"gray mb-1 line3",children:e.summary}),(0,a.jsxs)("div",{className:"d-flex justify-content-between mt-2",children:[(0,a.jsx)(x.fmQ,{style:{cursor:"pointer"},onClick:()=>p.push("/blogs/update/".concat(e.id,"?admin=true"))}),(0,a.jsx)(x.AMf,{style:{cursor:"pointer"},"data-bs-toggle":"modal","data-bs-target":"#exampleModal",onClick:()=>d(e.id)}),(0,a.jsx)(x.dSq,{style:{cursor:"pointer"},onClick:()=>p.push("blogs/".concat(e.slug))})]})]})},t)))))})})})]}):(0,a.jsx)("center",{children:(0,a.jsx)("img",{src:"/adminGif.gif",alt:"admin gif"})})]})};var j=!0,y=()=>(0,a.jsx)(f,{})},37986:function(e,t,s){"use strict";var a=s(85893),r=s(67294),n=s(73935);t.Z=e=>{let{deletingList:t,message:s,btnMessage:l,id:c}=e;const[i,o]=(0,r.useState)(!1);return(0,r.useEffect)((()=>(o(!0),()=>o(!1))),[]),i?(0,n.createPortal)((0,a.jsx)("div",{className:"modal fade notificationPopUp",id:c||"exampleModal","aria-labelledby":"exampleModalLabel","aria-hidden":"true",children:(0,a.jsx)("div",{className:"modal-dialog",children:(0,a.jsx)("div",{className:"modal-content",children:(0,a.jsxs)("div",{className:"modal-body",children:[(0,a.jsx)("p",{children:s||"Are you sure! You want to delete this?"}),(0,a.jsx)("div",{className:"d-flex flex-row justify-content-around mt-4",children:(0,a.jsxs)("div",{children:[(0,a.jsx)("button",{type:"button",className:"btn btnBorder me-2","data-bs-dismiss":"modal",onClick:()=>t(!1),children:"Close"}),(0,a.jsx)("button",{type:"button",className:"btn btnGreen","data-bs-dismiss":"modal",onClick:()=>t(!0),children:l||"Delete"})]})})]})})})}),document.querySelector("#myportal")):null}},41169:function(e,t,s){"use strict";s.d(t,{E:function(){return l}});var a=s(85893),r=s(67294),n=s(22463);const l=e=>{let{setSearchKeyword:t,searchKeyword:s}=e;const[l,c]=(0,r.useState)(s),i=(0,r.useRef)(null);return(0,a.jsx)("div",{className:"container",children:(0,a.jsx)("div",{className:"col-md-7 pl0",children:(0,a.jsxs)("div",{className:"flex align-center",children:[(0,a.jsxs)("div",{className:"input-group mb-3 borderCSS borderCSS2 mb-4",style:{height:"auto"},children:[(0,a.jsx)("div",{className:"input-group-prepend h43",children:(0,a.jsx)("span",{className:"input-group-text addon borderRadius10 h43",children:(0,a.jsx)(n.U41,{className:"gray"})})}),(0,a.jsx)("input",{type:"text",style:{color:"black"},className:"form-control searchInput borderRadius10 h43 w400 border0",onChange:e=>{""===e.target.value?t(""):c(e.target.value)},ref:i,placeholder:"Explore",defaultValue:s}),(0,a.jsx)("div",{className:"input-group-append",children:(0,a.jsx)("span",{className:"input-group-text searchAddon",style:{cursor:"pointer"},onClick:()=>t(l),children:"Search"})})]}),s&&(0,a.jsx)("span",{style:{color:"blue",textDecoration:"underline",cursor:"pointer",marginLeft:"1rem"},onClick:()=>{t(null),i.current.value=""},children:"clear"})]})})})}},26728:function(e,t,s){"use strict";s.d(t,{In:function(){return d},_Z:function(){return i},mL:function(){return o},nK:function(){return u},uX:function(){return m}});var a=s(9669),r=s.n(a),n=s(93679),l=s(88846),c=s(87427);const i=async(e,t,s,a,l)=>{try{const{data:i}=await(a?n.Z:r()).get(c.RM,{params:{limit:t,offset:e*t,title:s,slug:l,country:"India"}});return i}catch(i){return[]}},o=async e=>{try{const{data:t,status:s}=await n.Z.delete(c.RM+e+"/");return{status:(0,l.l)(s),data:t}}catch(t){return{error:t,status:(0,l.l)(t.response.status)}}},d=async e=>{try{const{data:t,status:s}=await n.Z.get(c.RM+e+"/");return{status:(0,l.l)(s),data:t}}catch(t){return{error:t.response.data,status:(0,l.l)(t.response.status)}}},u=async(e,t)=>{try{const{data:s,status:a}=await n.Z.patch(c.RM+e+"/",t);return{status:(0,l.l)(a),data:s}}catch(s){return{error:s.response.data,status:(0,l.l)(s.response.status)}}},m=async e=>{try{const{data:t,status:s}=await n.Z.post(c.RM,e);return{status:(0,l.l)(s),data:t}}catch(t){return{error:t.response.data,status:(0,l.l)(t.response.status)}}}}},function(e){e.O(0,[2888,9774,179],(function(){return t=59372,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

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.