1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5038,344],{3692:function(t,a,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/animals/list",function(){return n(2791)}])},8969:function(t,a,n){"use strict";n.d(a,{Z3:function(){return b},y8:function(){return w},wf:function(){return x},tG:function(){return A},XW:function(){return y},Of:function(){return p},jZ:function(){return _},TG:function(){return h},R:function(){return g}});var e=n(5121);let l={main:"/animals",images:"/animals/images",profile:"/animals/profile-pic"};var i=n(862);async function s(){var t,a,n;let s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",o=null,r="",d=null,c="";try{let n=await e.Z.get(i.API_BASE_PATH+l.main+"?"+s);if(c=n.status,!n.data)return;o=(null===(t=n.data)||void 0===t?void 0:t.data)||[],d=(null===(a=n.data)||void 0===a?void 0:a.pagination)||null}catch(t){r=t.message,c=null==t?void 0:null===(n=t.response)||void 0===n?void 0:n.status}return{data:o,error:r,pagination:d,status:c}}async function o(t,a){var n,s;let o=null,r="",d="";try{let s=await e.Z.post(i.API_BASE_PATH+l.main,{asal:t.asal||"",habitat:t.habitat||"",lama_hidup:t.lama_hidup||"",link_referensi:t.link_referensi||"",nama_latin:t.nama_latin||"",name:t.name||"",pakan:t.pakan||"",sifat_alami:t.sifat_alami||"",status_konservasi:t.status_konservasi||"",type:t.type||""},{headers:{Authorization:"Bearer "+a}});if(d=s.status,!s.data)return;o=null===(n=s.data)||void 0===n?void 0:n.data}catch(t){r=t.message,d=null==t?void 0:null===(s=t.response)||void 0===s?void 0:s.status}return{data:o,error:r,status:d}}async function r(t,a,n){var s,o;let r=null,d="",c="";try{let o=await e.Z.put(i.API_BASE_PATH+l.main+"/"+a,{asal:t.asal,habitat:t.habitat,lama_hidup:t.lama_hidup,link_referensi:t.link_referensi,nama_latin:t.nama_latin,name:t.name,pakan:t.pakan,sifat_alami:t.sifat_alami,status_konservasi:t.status_konservasi,type:t.type},{headers:{Authorization:"Bearer "+n}});if(c=o.status,!o.data)return;r=null===(s=o.data)||void 0===s?void 0:s.data}catch(t){d=t.message,c=null==t?void 0:null===(o=t.response)||void 0===o?void 0:o.status}return{data:r,error:d,status:c}}async function d(t,a){var n,s;let o=null,r="",d="";try{let s=await e.Z.delete(i.API_BASE_PATH+l.main+"/"+t,{headers:{Authorization:"Bearer "+a}});if(d=s.status,!s.data)return;o=null===(n=s.data)||void 0===n?void 0:n.data}catch(t){r=t.message,d=null==t?void 0:null===(s=t.response)||void 0===s?void 0:s.status}return{data:o,error:r,status:d}}async function c(t){var a,n;let s=null,o="",r="";try{let n=await e.Z.get(i.API_BASE_PATH+l.main+"/"+t);if(r=n.status,!n.data)return;s=null===(a=n.data)||void 0===a?void 0:a.data}catch(t){o=t.message,r=null==t?void 0:null===(n=t.response)||void 0===n?void 0:n.status}return{data:s,error:o,status:r}}async function u(t,a,n){var s,o;let r=null,d="",c="",u=new FormData;u.append("animal_id",t),u.append("image",a);try{let t=await e.Z.post(i.API_BASE_PATH+l.images,u,{headers:{Authorization:"Bearer "+n}});if(c=t.status,!t.data)return;r=null===(s=t.data)||void 0===s?void 0:s.data}catch(t){d=t.message,c=null==t?void 0:null===(o=t.response)||void 0===o?void 0:o.status}return{data:r,error:d,status:c}}async function m(t,a){var n,s;let o=null,r="",d="";try{let s=await e.Z.delete(i.API_BASE_PATH+l.images+"/"+t,{headers:{Authorization:"Bearer "+a}});if(d=s.status,!s.data)return;o=null===(n=s.data)||void 0===n?void 0:n.data}catch(t){r=t.message,d=null==t?void 0:null===(s=t.response)||void 0===s?void 0:s.status}return{data:o,error:r,status:d}}async function f(t,a,n){var s,o;let r=null,d="",c="",u=new FormData;u.append("animal_id",t),u.append("profile_pic",a);try{let t=await e.Z.post(i.API_BASE_PATH+l.profile,u,{headers:{Authorization:"Bearer "+n}});if(c=t.status,!t.data)return;r=null===(s=t.data)||void 0===s?void 0:s.data}catch(t){d=t.message,c=null==t?void 0:null===(o=t.response)||void 0===o?void 0:o.status}return{data:r,error:d,status:c}}async function v(t,a){var n,s;let o=null,r="",d="";try{let s=await e.Z.delete(i.API_BASE_PATH+l.profile+"/"+t,{headers:{Authorization:"Bearer "+a}});if(d=s.status,!s.data)return;o=null===(n=s.data)||void 0===n?void 0:n.data}catch(t){r=t.message,d=null==t?void 0:null===(s=t.response)||void 0===s?void 0:s.status}return{data:o,error:r,status:d}}async function _(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{},n=await s(t);a&&a(n)}async function h(t,a){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{},e=await o(t,a);n&&n(e)}async function g(t,a,n){let e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:()=>{},l=await r(t,a,n);e&&e(l)}async function p(t){let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{},n=await c(t);a&&a(n)}async function x(t,a){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{},e=await d(t,a);n&&n(e)}async function b(t,a,n){let e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:()=>{},l=await u(t,a,n);e&&e(l)}async function A(t,a){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{},e=await m(t,a);n&&n(e)}async function w(t,a,n){let e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:()=>{},l=await f(t,a,n);e&&e(l)}async function y(t,a){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{},e=await v(t,a);n&&n(e)}},8907:function(t,a,n){"use strict";n.d(a,{f:function(){return o},P:function(){return r}});var e=n(5121),l=n(862);let i={login:"/login"};async function s(t,a){let n=null,s="",o="";try{let s=await (0,e.Z)({baseURL:l.API_BASE_PATH,url:i.login,method:"POST",data:JSON.stringify({username:t,password:a})});if(o=s.status,!s.data)return;n=s.data}catch(t){var r;s=t.message,o=null==t?void 0:null===(r=t.response)||void 0===r?void 0:r.status}return{data:n,error:s,status:o}}async function o(t,a){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{},e=await s(t,a);n&&n(e)}async function r(){localStorage.removeItem("auth")}},862:function(t,a,n){"use strict";n.r(a),n.d(a,{API_BASE_PATH:function(){return e}});let e="https://lembangparkzoo-api.cloud"},694:function(t,a,n){"use strict";function e(){if("undefined"==typeof window)return;let t=localStorage.getItem("auth")?JSON.parse(localStorage.getItem("auth")):{};return(null==t?void 0:t.token)||""}n.r(a),n.d(a,{getToken:function(){return e}})},9717:function(t,a,n){"use strict";function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"success";return{severity:a,message:t}}n.d(a,{Y:function(){return e}})},5658:function(t,a,n){"use strict";n.d(a,{Z:function(){return i}});var e=n(5893);n(7294);var l=n(8973);function i(t){let{image:a,title:n}=t;return(0,e.jsxs)("section",{className:"w-full h-screen max-h-[94vh] lg:max-h-[90vh] overflow-hidden relative",children:[(0,e.jsx)("img",{src:a,alt:"banner",className:"absolute inset-0 w-full h-full object-cover object-center",loading:"lazy"}),(0,e.jsx)("div",{className:"absolute bottom-0 left-0 right-0 h-1/2 opacity-80 bg-gradient-to-t from-black to-transparent"}),(0,e.jsx)("div",{className:"flex flex-col items-center justify-end w-full h-full p-12 lg:p-16",children:(0,e.jsx)(l.Z,{variant:"h1",className:"relative text-center text-white uppercase",children:n})})]})}}
1,7752:function(t,a,n){"use strict";n.d(a,{Z:function(){return c}});var e=n(5893);n(7294);var l=n(3665),i=n.n(l),s=n(3990),o=n(5089),r=n(1664),d=n.n(r);function c(t){let{children:a,className:n="",color:l,variant:r,disabled:c,onClick:u,loading:m,active:f,activeColor:v,rounded:_,size:h,href:g,target:p}=t,x=["primary","secondary","gray","danger"],b=["filled","outlined","text"],A=x.find(t=>t===(f&&v||l))||x[0],w=b.find(t=>t===r)?r:b[0],y=["xs","sm","md","lg"].find(t=>t===h)?h:"md",N=["normal","full"].find(t=>t===_)?_:"normal",j=(0,o.y)(i(),["btn","btn--".concat(A),"btn--".concat(w),"btn--".concat(y),"btn--rounded","btn--rounded--".concat(N)]),B=g?d():"button";return m||c?(0,e.jsx)("div",{className:"".concat(j," ").concat(n),disabled:m||c,children:m?(0,e.jsx)(s.Cd,{className:"text-lg animate-spin"}):a}):(0,e.jsx)(B,{href:g,target:p,className:"".concat(j," ").concat(n),disabled:c,onClick:t=>{!c&&u&&u(t)},"aria-label":f?"active":"",children:a})}},1075:function(t,a,n){"use strict";n.d(a,{F:function(){return o},Z:function(){return s}});var e=n(5893);n(7294);var l=n(3258),i=n.n(l);function s(t){let{id:a,children:n,className:l="",shadow:s,thisRef:o,loading:r,style:d}=t,c=["sm","default","md","lg","xl","2xl","none"].find(t=>t===s)?s:"default",u="".concat(i().card," ").concat(i()["card--shadow-".concat(c)]," ").concat(l);return(0,e.jsxs)("div",{id:a,ref:o,className:u,style:d,children:[r&&(0,e.jsx)("div",{className:"absolute inset-0 w-full h-full rounded bg-slate-300"}),n]})}let o=i()},4101:function(t,a,n){"use strict";n.d(a,{Z:function(){return o}});var e=n(5893),l=n(5675),i=n.n(l);n(7294);var s={src:"/_next/static/media/logo_white.b4835e87.png",height:2481,width:3509,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAGCAMAAADJ2y/JAAAAKlBMVEX///////////////9MaXH///////////////////////////////////+my4i1AAAADnRSTlMCMGyOABiCrl0NQlIMvsNr1k8AAAAJcEhZcwAALiMAAC4jAXilP3YAAAAwSURBVHicBcGJAcAwCAOxwxjI1/3XrQSAaxvb+JS5a92eDmIm1RKRytSXvG1XnPgBFi4A3ryh4lYAAAAASUVORK5CYII=",blurWidth:8,blurHeight:6};function o(t){let{className:a="",size:n}=t,l=[{size:"sm",logo:s,height:23.04,width:112.41*72/100},{size:"md",logo:s,height:64,width:112.41},{size:"lg",logo:s,height:80,width:140.5125}],o=l.find(t=>t.size===n)||l[0];return(0,e.jsx)(i(),{className:a,src:o.logo,alt:"logo-".concat(o.size),height:o.height,width:o.width})}},8309:function(t,a,n){"use strict";n.d(a,{Z:function(){return _}});var e=n(5893),l=n(7294),i=n(155),s=n(1075),o=n(3209),r=n(8007),d=n(1664),c=n.n(d);function u(t){let{className:a="",children:n,color:l,href:i,active:s,activeColor:r,onClick:d,viewMode:u,target:m}=t,f=["default","primary"],v=f.find(t=>t===l)?l:f[0],_=f.find(t=>t===r)?r:f[0],h=u?"div":i?c():"button";return(0,e.jsx)(h,{href:i,className:"".concat(o.Z.styles.list__item__btn," ").concat(o.Z.styles["list__item__btn--".concat(v)]," ").concat(a),onClick:d,"aria-label":s?"active-".concat(_):"",target:m,children:n})}var m=n(8973);
1function f(t){let{className:a="",subtitle:n,subtitleTypographyProps:l={},secondSubtitle:i,secondSubtitleTypographyProps:s={},title:o,titleTypographyProps:r={}}=t;return(0,e.jsxs)("div",{className:"".concat(a),children:[o&&(0,e.jsx)(m.Z,{...r,children:o}),n&&(0,e.jsx)(m.Z,{...l,children:n}),i&&(0,e.jsx)(m.Z,{...s,children:i})]})}let v=(t,a,n)=>{(0,l.useEffect)(()=>{let e=e=>{a&&t.current&&!t.current.contains(e.target)&&n(!1)};return document.addEventListener("mousedown",e),document.addEventListener("touchstart",e),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("touchstart",e)}},[t,n,a])};var _=function(t){let{containerClassName:a="",value:n,options:d=[],onChange:c=()=>{},label:m,required:_}=t,h=(0,l.useRef)(),[g,p]=(0,l.useState)(!1),x=t=>{p(!1),c(t)};return v(h,g,p),(0,e.jsxs)("div",{ref:h,className:"relative space-y-1 "+a,children:[m&&(0,e.jsxs)("div",{className:"text-xs font-semibold",children:[m,_&&(0,e.jsx)("span",{className:"text-danger",children:"*"})]}),(0,e.jsxs)("button",{className:"flex items-center w-full h-12 bg-white border rounded focus:outline-none ",onClick:()=>p(t=>!t),children:[(0,e.jsx)("div",{className:"flex items-center w-full px-3 py-2 text-left rounded focus:outline-none",children:(0,e.jsx)("span",{className:"w-full",children:null==n?void 0:n.label})}),(0,e.jsx)("div",{className:"flex items-center px-3 py-2 text-sm rounded focus:outline-none",children:(0,e.jsx)(i.CgR,{className:"transition-all duration-150 ".concat(g?"-rotate-180":"rotate-0")})})]}),g&&(0,e.jsx)(s.Z,{className:"absolute z-10 w-full top-12",children:(0,e.jsx)(o.Z,{children:d.map((t,a)=>(0,e.jsx)(r.Z,{variant:"noPadding",className:"text-sm",children:(0,e.jsx)(u,{onClick:()=>x(t),active:n.value===(null==t?void 0:t.value),children:(0,e.jsx)(f,{title:null==t?void 0:t.label})})},a))})})]})}},8973:function(t,a,n){"use strict";n.d(a,{Z:function(){return o}});var e=n(5893),l=n(5337),i=n.n(l),s=n(7294);function o(t){let{children:a,className:n="",variant:l,component:o,loading:r,font:d}=t,c=[{variant:"h1",component:"h1",className:"text-4xl lg:text-6xl ".concat("global"===d?"":i().className)},{variant:"h2",component:"h2",className:"text-3xl lg:text-5xl ".concat("global"===d?"":i().className)},{variant:"h3",component:"h3",className:"text-2xl lg:text-4xl ".concat("global"===d?"":i().className)},{variant:"h4",component:"h4",className:"text-xl lg:text-3xl ".concat("global"===d?"":i().className)},{variant:"h5",component:"h5",className:"text-lg lg:text-2xl ".concat("global"===d?"":i().className)},{variant:"h6",component:"h6",className:"text-base lg:text-xl ".concat("global"===d?"":i().className)},{variant:"subtitle1",component:"h6",className:"text-base"},{variant:"subtitle2",component:"h6",className:"text-sm font-medium opacity-90"},{variant:"subtitle3",component:"h6",className:"text-xs font-medium opacity-90"},{variant:"body1",component:"p",className:"text-base"},{variant:"body2",component:"p",className:"text-base opacity-80"},{variant:"caption",component:"span",className:"text-xs opacity-80"}],u=c.find(t=>t.variant===l)||c.find(t=>"body1"===t.variant),m=o||u.component||"div";return(0,e.jsxs)(t=>{let{children:a}=t;return r?(0,e.jsx)("div",{className:"relative",children:a}):(0,e.jsx)(s.Fragment,{children:a})},{children:[r&&(0,e.jsx)("div",{className:"absolute inset-0 z-10 rounded bg-slate-100"}),(0,e.jsx)(m,{className:"".concat(u.className," ").concat(n),children:a})]})}},5089:function(t,a,n){"use strict";n.d(a,{y:function(){return e}});let e=function(t){let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[];for(let e=0;e<a.length;e++){let l=a[e];""!==l&&n.push(t[l])}return n.join(" ")}},2791:function(t,a,n){"use strict";n.r(a),n.d(a,{default:function(){return f}});var e=n(5893),l=n(8969),i=n(5658),s=n(3922);n(8309);var o=n(8973),r=n(6587),d=n(5174);n(5675);var c=n(1664),u=n.n(c),m=n(7294);function f(){var t;d.Z.animals.submenu.find(t=>"meet-the-animals"===t.name);let a={category:[{id:0,label:"Category",value:""},{id:1,label:"Mammals",value:"mammals"}],conservation:[{id:0,label:"Conservation Status",value:""},{id:1,label:"Endangered",value:"endangered"}]},[n,c]=(0,m.useState)({data:null,pagination:null}
1),[f,v]=(0,m.useState)(a.category[0]),[_,h]=(0,m.useState)(a.conservation[0]);(0,m.useEffect)(()=>{(0,l.jZ)("",t=>{200===t.status&&c({data:null==t?void 0:t.data,pagination:null==t?void 0:t.pagination})})},[]);let[g,p]=(0,m.useState)(null);return(0,e.jsxs)(s.Z,{banner:t=>{let a=(0,s.T)(t,"animal_list");p(a)},children:[g&&(0,e.jsx)(i.Z,{image:g,title:"MEET THE ANIMALS"}),(0,e.jsx)("div",{className:"flex flex-wrap",children:null===(t=n.data)||void 0===t?void 0:t.map((t,a)=>{var n,l,i,s,d;return(0,e.jsxs)(u(),{href:r.DK+"/"+(null==t?void 0:t.id),className:"relative w-full overflow-hidden aspect-square bg-slate-200 group md:w-1/2 lg:w-1/4",children:[((null==t?void 0:null===(n=t.images)||void 0===n?void 0:n.length)>0||(null==t?void 0:null===(l=t.profile_pic)||void 0===l?void 0:l.profile_pic))&&(0,e.jsx)("img",{src:(null==t?void 0:null===(i=t.profile_pic)||void 0===i?void 0:i.profile_pic)||(null==t?void 0:null===(s=t.images)||void 0===s?void 0:s.length)>0&&(null===(d=t.images[0])||void 0===d?void 0:d.image),alt:t.name,loading:"lazy",className:"absolute inset-0 w-full h-full object-cover object-center transition-all duration-300 ease-in-out lg:group-hover:scale-110"}),(0,e.jsx)("div",{className:"absolute bottom-0 flex flex-col justify-end w-full p-5 bg-gradient-to-t h-full transition-all duration-300 from-[#00000090] to-transparent max-h-[30%] ",children:(0,e.jsx)(o.Z,{className:"font-bold text-white",variant:"h4",font:"global",children:t.name})})]},a)})})]})}},6268:function(){},2299:function(t){t.exports={style:{fontFamily:"'__Poppins_9b9fd1', '__Poppins_Fallback_9b9fd1'",fontStyle:"normal"},className:"__className_9b9fd1"}},3665:function(t){t.exports={btn:"Button_btn__alSGT","btn--primary":"Button_btn--primary__0LLrL","btn--filled":"Button_btn--filled__JkSz0","btn--outlined":"Button_btn--outlined__uNYJP","btn--text":"Button_btn--text__8ux5v","btn--secondary":"Button_btn--secondary__3T18W","btn--danger":"Button_btn--danger__yTYjm","btn--gray":"Button_btn--gray__h6spw","btn--rounded":"Button_btn--rounded__bp4X5","btn--rounded--full":"Button_btn--rounded--full__dRpq1","btn--xs":"Button_btn--xs__5K_EG","btn--sm":"Button_btn--sm___WQfW","btn--md":"Button_btn--md__0LVns","btn--lg":"Button_btn--lg__UZGY7"}},3258:function(t){t.exports={card:"Card_card__YWHGX","card--shadow-none":"Card_card--shadow-none__jt1p2","card--shadow-sm":"Card_card--shadow-sm__fjtV_","card--shadow-default":"Card_card--shadow-default__Icl0y","card--shadow-md":"Card_card--shadow-md__O__Zp","card--shadow-lg":"Card_card--shadow-lg___A1qV","card--shadow-xl":"Card_card--shadow-xl__U1O4w","card--shadow-2xl":"Card_card--shadow-2xl__KQjR1",card__content:"Card_card__content__bYNbc","padding--sm":"Card_padding--sm__cllFR","padding--md":"Card_padding--md__wALOj","padding--lg":"Card_padding--lg__aXsif","padding--xl":"Card_padding--xl__SavYx","padding--2xl":"Card_padding--2xl__2PbZt"}},1163:function(t,a,n){t.exports=n(6885)}},function(t){t.O(0,[3609,260,1228,4949,6028,5675,3922,9774,2888,179],function(){return t(t.s=3692)}),_N_E=t.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.