PageSourceSearch

https://www.imagic.co.nz/_next/static/chunks/pages/components/elem…/chunks/homeHeroBlock-a47a35053cf4e3df.js

js imagic.co.nz collected 2026-10-08 19:34:42 UTC 15,601 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1436],{2506:function(e,t,o){(window.__NEXT_P=window.__NEXT_P||[]).push(["/components/elements/chunks/homeHeroBlock",function(){return o(10159)}])},92168:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var o in t)Object.defineProperty(e,o,{enumerable:!0,get:t[o]})}(t,{default:function(){return a},noSSR:function(){return l}});let r=o(38754);o(85893),o(67294);let n=r._(o(58440));function i(e){return{default:(null==e?void 0:e.default)||e}}function l(e,t){return delete t.webpack,delete t.modules,e(t)}function a(e,t){let o=n.default,r={loading:e=>{let{error:t,isLoading:o,pastDelay:r}=e;return null}};e instanceof Promise?r.loader=()=>e:"function"==typeof e?r.loader=e:"object"==typeof e&&(r={...r,...e});let a=(r={...r,...t}).loader;return(r.loadableGenerated&&(r={...r,...r.loadableGenerated},delete r.loadableGenerated),"boolean"!=typeof r.ssr||r.ssr)?o({...r,loader:()=>null!=a?a().then(i):Promise.resolve(i(()=>null))}):(delete r.webpack,delete r.modules,l(o,r))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},34130:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"LoadableContext",{enumerable:!0,get:function(){return r}});let r=o(38754)._(o(67294)).default.createContext(null)},58440:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return h}});let r=o(38754)._(o(67294)),n=o(34130),i=[],l=[],a=!1;function s(e){let t=e(),o={loading:!0,loaded:null,error:null};return o.promise=t.then(e=>(o.loading=!1,o.loaded=e,e)).catch(e=>{throw o.loading=!1,o.error=e,e}),o}class d{promise(){return this._res.promise}retry(){this._clearTimeouts(),this._res=this._loadFn(this._opts.loader),this._state={pastDelay:!1,timedOut:!1};let{_res:e,_opts:t}=this;e.loading&&("number"==typeof t.delay&&(0===t.delay?this._state.pastDelay=!0:this._delay=setTimeout(()=>{this._update({pastDelay:!0})},t.delay)),"number"==typeof t.timeout&&(this._timeout=setTimeout(()=>{this._update({timedOut:!0})},t.timeout))),this._res.promise.then(()=>{this._update({}),this._clearTimeouts()}).catch(e=>{this._update({}),this._clearTimeouts()}),this._update({})}_update(e){this._state={...this._state,error:this._res.error,loaded:this._res.loaded,loading:this._res.loading,...e},this._callbacks.forEach(e=>e())}_clearTimeouts(){clearTimeout(this._delay),clearTimeout(this._timeout)}getCurrentValue(){return this._state}subscribe(e){return this._callbacks.add(e),()=>{this._callbacks.delete(e)}}constructor(e,t){this._loadFn=e,this._opts=t,this._callbacks=new Set,this._delay=null,this._timeout=null,this.retry()}}function u(e){return function(e,t){let o=Object.assign({loader:null,loading:null,delay:200,timeout:null,webpack:null,modules:null},t),i=null;function s(){if(!i){let t=new d(e,o);i={getCurrentValue:t.getCurrentValue.bind(t),subscribe:t.subscribe.bind(t),retry:t.retry.bind(t),promise:t.promise.bind(t)}}return i.promise()}if(!a){let e=o.webpack?o.webpack():o.modules;e&&l.push(t=>{for(let o of e)if(t.includes(o))return s()})}function u(e,t){!function(){s();let e=r.default.useContext(n.LoadableContext);e&&Array.isArray(o.modules)&&o.modules.forEach(t=>{e(t)})}();let l=r.default.useSyncExternalStore(i.subscribe,i.getCurrentValue,i.getCurrentValue);return r.default.useImperativeHandle(t,()=>({retry:i.retry}),[]),r.default.useMemo(()=>{var t;return l.loading||l.error?r.default.createElement(o.loading,{isLoading:l.loading,pastDelay:l.pastDelay,timedOut:l.timedOut,error:l.error,retry:i.retry}):l.loaded?r.default.createElement((t=l.loaded)&&t.default?t.default:t,e):null},[e,l])}return u.preload=()=>s(),u.displayName="LoadableComponent",r.default.forwardRef(u)}(s,e)}function c(e,t){let o=[];for(;e.length;){let r=e.pop();o.push(r(t))}return Promise.all(o).then(()=>{if(e.length)return c(e,t)})}u.preloadAll=()=>new Promise((e,t)=>
1{c(i).then(e,t)}),u.preloadReady=e=>(void 0===e&&(e=[]),new Promise(t=>{let o=()=>(a=!0,t());c(l,e).then(o,o)})),window.__NEXT_PRELOADREADY=u.preloadReady;let h=u},84555:function(e,t,o){"use strict";o.r(t),o.d(t,{default:function(){return l}});var r=o(85893),n=o(93041),i=o(67294);function l(e){let{playbackId:t,onReady:o,onPlaying:l,onLoadedMetadata:a,className:s,style:d,loopFromSeconds:u=0}=e,c=(0,i.useRef)(null),h="https://stream.mux.com/".concat(t,".m3u8?min_resolution=1080p");return(0,i.useEffect)(()=>{let e;let t=c.current;if(!t)return;o&&t.addEventListener("loadeddata",o),l&&t.addEventListener("playing",l);let r=()=>{a&&t.videoWidth&&t.videoHeight&&a({width:t.videoWidth,height:t.videoHeight})};a&&t.addEventListener("loadedmetadata",r);let i=()=>{t.currentTime=u,t.play()};return u>0&&t.addEventListener("ended",i),n.ZP.isSupported()?((e=new n.ZP).loadSource(h),e.attachMedia(t),e.on(n.ZP.Events.MANIFEST_PARSED,()=>t.play())):t.canPlayType("application/vnd.apple.mpegurl")&&(t.src=h),()=>{e&&e.destroy(),o&&t.removeEventListener("loadeddata",o),l&&t.removeEventListener("playing",l),a&&t.removeEventListener("loadedmetadata",r),u>0&&t.removeEventListener("ended",i)}},[h,u]),(0,r.jsx)("video",{ref:c,muted:!0,loop:u<=0,playsInline:!0,className:s,style:{width:"100%",height:"100%",objectFit:"cover",...d}})}},10159:function(e,t,o){"use strict";o.r(t),o.d(t,{default:function(){return h}});var r=o(85893),n=o(25675),i=o.n(n),l=o(28058),a=o(67294),s=o(94111),d=o(84555),u=o(5152);let c=o.n(u)()(()=>Promise.all([o.e(296),o.e(9260)]).then(o.t.bind(o,69260,23)),{loadableGenerated:{webpack:()=>[69260]},ssr:!1});function h(e){let{entry:t,index:n}=e;if(!t)return null;var u,h,p,m,f,_,b,v,g,y=!1,j=!1,k=t.thumbnailOptions2,w=null!==(m=t.image[0])&&void 0!==m&&m;if(t.lottieFile[0])var f="https://cms.imagic.co.nz/json?assetId="+t.lottieFile[0].id;var j=null!==(_=t.vimeoId)&&void 0!==_&&_,E=null!==(b=null===(u=t.video[0])||void 0===u?void 0:u.url)&&void 0!==b?b:"",P=null!==(v=t.urlField)&&void 0!==v&&v;let[x,M]=(0,a.useState)(null),[S,O]=(0,a.useState)(!1),[B,C]=(0,a.useState)(null),N=(0,a.useRef)(null),[I,D]=(0,a.useState)(null);if((0,a.useEffect)(()=>{O(!0),f&&fetch(f).then(e=>e.json()).then(e=>{M(e),O(!1)})},[f,j,E]),(0,a.useEffect)(()=>{P&&"blob"==k&&o(47317)("./".concat(P)).then(e=>D(e.default)).catch(e=>console.error("Error loading video:",e))},[P]),x)var y=x;
1return(0,r.jsxs)("div",{className:"media-block","data-block":n,children:["image"==k&&w&&(0,r.jsxs)("div",{className:"image-block",children:[(0,r.jsxs)("picture",{children:[(0,r.jsx)("source",{srcSet:w.desktop,type:"image/webp"}),(0,r.jsx)("source",{srcSet:w.desktop,type:"image/avif"}),(0,r.jsx)(i(),{src:"https://cms.imagic.co.nz"+w.url,width:798,height:484,alt:null!==(g=w.alt)&&void 0!==g?g:w.title})]}),w.blurhash&&w.blurhash.length&&(0,r.jsx)(l.E,{className:"blurhash",hash:w.blurhash,width:798,height:484})]}),"lottie"==k&&y&&(0,r.jsx)("div",{className:"lottie-block",children:y&&(0,r.jsx)(c,{className:"lottie",animationData:y,rendererSettings:{preserveAspectRatio:"xMidYMid slice",width:"100%",height:"100%"}})}),"vimeo"==k&&j&&(0,r.jsx)("div",{className:"video-container",style:{backgroundImage:B?"url(".concat(B,")"):"none",backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat"},children:(0,r.jsx)(s.Z,{width:"16",height:"9",video:j,autoplay:!0,background:!0,muted:!0,loop:!0})}),"video"==k&&E&&(0,r.jsx)("div",{className:"video-container",children:(0,r.jsxs)("video",{ref:N,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,preload:"metadata",children:[(0,r.jsx)("source",{src:E,type:"video/mp4"}),"Your browser does not support the video tag."]})}),"blob"==k&&(null==I?void 0:null===(p=I.providerMetadata)||void 0===p?void 0:null===(h=p.mux)||void 0===h?void 0:h.playbackId)&&(0,r.jsx)("div",{className:"video-container",children:(0,r.jsx)(d.default,{playbackId:I.providerMetadata.mux.playbackId})})]})}},5152:function(e,t,o){e.exports=o(92168)},28058:function(e,t,o){"use strict";o.d(t,{E:function(){return M}});var r=o(67294),n=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","#","$","%","*","+",",","-",".",":",";","=","?","@","[","]","^","_","{","|","}","~"],i=e=>{let t=0;for(let o=0;o<e.length;o++){let r=e[o];t=83*t+n.indexOf(r)}return t},l=e=>{let t=e/255;return t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},a=e=>{let t=Math.max(0,Math.min(1,e));return t<=.0031308?Math.trunc(3294.6*t+.5):Math.trunc((1.055*Math.pow(t,.4166666666666667)-.055)*255+.5)},s=e=>e<0?-1:1,d=(e,t)=>s(e)*Math.pow(Math.abs(e),t),u=class extends Error{constructor(e){super(e),this.name="ValidationError",this.message=e}},c=e=>{if(!e||e.length<6)throw new u("The blurhash string must be at least 6 characters");let t=i(e[0]),o=Math.floor(t/9)+1,r=t%9+1;if(e.length!==4+2*r*o)throw new u(`blurhash length mismatch: length is ${e.length} but it should be ${4+2*r*o}`)},h=e=>[l(e>>16),l(e>>8&255),l(255&e)],p=(e,t)=>[d((Math.floor(e/361)-9)/9,2)*t,d((Math.floor(e/19)%19-9)/9,2)*t,d((e%19-9)/9,2)*t],m=(e,t,o,r)=>{c(e),r|=1;let n=i(e[0]),l=Math.floor(n/9)+1,s=n%9+1,d=(i(e[1])+1)/166,u=Array(s*l);for(let t=0;t<u.length;t++)if(0===t){let o=i(e.substring(2,6));u[t]=h(o)}else{let o=i(e.substring(4+2*t,6+2*t));u[t]=p(o,d*r)}let m=4*t,f=new Uint8ClampedArray(m*o);for(let e=0;e<o;e++)for(let r=0;r<t;r++){let n=0,i=0,d=0;for(let a=0;a<l;a++)for(let l=0;l<s;l++){let c=Math.cos(Math.PI*r*l/t)*Math.cos(Math.PI*e*a/o),h=u[l+a*s];n+=h[0]*c,i+=h[1]*c,d+=h[2]*c}let c=a(n),h=a(i),p=a(d);f[4*r+0+e*m]=c,f[4*r+1+e*m]=h,f[4*r+2+e*m]=p,f[4*r+3+e*m]=255}return f},f=Object.defineProperty,_=Object.defineProperties,b=Object.getOwnPropertyDescriptors,v=Object.getOwnPropertySymbols,g=Object.prototype.hasOwnProperty,y=Object.prototype.propertyIsEnumerable,j=(e,t,o)=>t in e?f(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,k=(e,t)=>{for(var o in t||(t={}))g.call(t,o)&&j(e,o,t[o]);if(v)for(var o of v(t))y.call(t,o)&&j(e,o,t[o]);return e},w=(e,t)=>_(e,b(t)),E=(e,t)=>{var o={};for(var r in e)g.call(e,r)&&0>t.indexOf(r)&&(o[r]=e[r]);if(null!=e&&v)for(var r of v(e))0>t.indexOf(r)&&y.call(e,r)&&(o[r]=e[r]);return o},P=class extends r.PureComponent{constructor(){super(...arguments),this.canvas=null,this.handleRef=e=>{this.canvas=e,this.draw()},this.draw=()=>{let{hash:e,height:t,punch:o,width:r}=this.props;if(this.canvas){let n=m(e,r,t,o),i=this.canvas.getContext("2d"),l=i.createImageData(r,t);l.data.set(n),i.putImageData(l,0,0)}}}componentDidUpdate(){this.draw()}render(){let e=this.props,{hash:t,height:o,width:n}=e,i=E(e,["hash","height","width"]);return r.createElement("canvas",w(k({},i),{height:o,width:n,ref:this.handleRef}))}};P.defaultProps={height:128,width:128};var x={position:"absolute",top:0,bottom:0,left:0,right:0,width:"100%",height:"100%"},M=class extends r.PureComponent{componentDidUpdate(){if(this.props.resolutionX<=0)throw Error("resolutionX must be larger than zero");if(this.props.resolutionY<=0)throw Error("resolutionY must be larger than zero")}render(){let e=this.props,{hash:t,height:o,width:n,punch:i,resolutionX:l,resolutionY:a,style:s}=e,d=E(e,["hash","height","width","punch","resolutionX","resolutionY","style"]);return r.createElement("div",w(k({}
1,d),{style:w(k({display:"inline-block",height:o,width:n},s),{position:"relative"})}),r.createElement(P,{hash:t,height:a,width:l,punch:i,style:x}))}};M.defaultProps={height:128,width:128,resolutionX:32,resolutionY:32}},47317:function(e,t,o){var r={"./10881636-cut-version.mp4":[92918,2918],"./10881636-cut-version.mp4.json":[92918,2918],"./10881636-hd_1920_1080_25fps.mp4":[2517,2517],"./10881636-hd_1920_1080_25fps.mp4.json":[2517,2517],"./10881636-hd_2560_1440_25fps.mp4":[44288,4288],"./10881636-hd_2560_1440_25fps.mp4.json":[44288,4288],"./3 Blocks.mp4":[94167,4167],"./3 Blocks.mp4.json":[94167,4167],"./Bubble Stream V2.mp4":[61569,3280],"./Bubble Stream V2.mp4.json":[61569,3280],"./Bubble Stream V3.mp4":[35146,5146],"./Bubble Stream V3.mp4.json":[35146,5146],"./Bubble Stream.mp4":[82768,2768],"./Bubble Stream.mp4.json":[82768,2768],"./Eye Iris - Block.mp4":[71452,1452],"./Eye Iris - Block.mp4.json":[71452,1452],"./Flower - Block.mp4":[50858,858],"./Flower - Block.mp4.json":[50858,858],"./Full Video - No Cards.mp4":[30777,777],"./Full Video - No Cards.mp4.json":[30777,777],"./Hairy Eye - Block.mp4":[39854,9854],"./Hairy Eye - Block.mp4.json":[39854,9854],"./Men Around Car.mp4":[13905,3905],"./Men Around Car.mp4.json":[13905,3905],"./Metal Stick - Block.mp4":[75278,5278],"./Metal Stick - Block.mp4.json":[75278,5278],"./We Make It Ezi.mp4":[19970,9970],"./We Make It Ezi.mp4.json":[19970,9970],"./art_slide_1080p.mp4":[93125,3125],"./art_slide_1080p.mp4.json":[93125,3125],"./emotion_slide.mp4":[74588,4588],"./emotion_slide.mp4.json":[74588,4588],"./emotion_slide_2160p.mp4":[97132,7132],"./emotion_slide_2160p.mp4.json":[97132,7132],"./featuredProjectsStackBlock1.mp4":[40506,506],"./featuredProjectsStackBlock1.mp4.json":[40506,506],"./featuredProjectsStackBlock2.mp4":[50104,104],"./featuredProjectsStackBlock2.mp4.json":[50104,104],"./featuredProjectsStackBlock4.mp4":[68515,8515],"./featuredProjectsStackBlock4.mp4.json":[68515,8515],"./herovid-brand-strategy-identity.mp4":[94693,434],"./herovid-brand-strategy-identity.mp4.json":[94693,434],"./herovid-creative-content.mp4":[1180,1180],"./herovid-creative-content.mp4.json":[1180,1180],"./herovid-digitalmarketing.mp4":[3250,3250],"./herovid-digitalmarketing.mp4.json":[3250,3250],"./herovid-tech-digital-products.mp4":[69361,9361],"./herovid-tech-digital-products.mp4.json":[69361,9361],"./hierarchy1.mp4":[34350,4350],"./hierarchy1.mp4.json":[34350,4350],"./hierarchy2.mp4":[61255,1255],"./hierarchy2.mp4.json":[61255,1255],"./homeHeroBlock1.mp4":[39600,9600],"./homeHeroBlock1.mp4.json":[39600,9600],"./homeHeroBlock2.mp4":[64593,4593],"./homeHeroBlock2.mp4.json":[64593,4593],"./homeHeroBlock4.mp4":[66640,6640],"./homeHeroBlock4.mp4.json":[66640,6640],"./hq_brand_strategy_identity.mp4":[645,645],"./hq_brand_strategy_identity.mp4.json":[645,645],"./hq_creative_content.mp4":[88056,8056],"./hq_creative_content.mp4.json":[88056,8056],"./hq_digital_marketing.mp4":[30427,427],"./hq_digital_marketing.mp4.json":[30427,427],"./hq_tech_digital_products.mp4":[70452,452],"./hq_tech_digital_products.mp4.json":[70452,452],"./imagic30-footer-vidloop.mp4":[57517,751
17],"./imagic30-footer-vidloop.mp4.json":[57517,7517],"./intro_slide_2160p.mp4":[48212,8212],"./intro_slide_2160p.mp4.json":[48212,8212],"./projectSA.mp4":[51728,1728],"./projectSA.mp4.json":[51728,1728],"./projectsFaringdon.mp4":[26084,6084],"./projectsFaringdon.mp4.json":[26084,6084],"./stockvideo1.mp4":[84164,4164],"./stockvideo1.mp4.json":[84164,4164],"./stockvideo2.mp4":[91301,1301],"./stockvideo2.mp4.json":[91301,1301],"./tepaenew2.mp4":[59117,9117],"./tepaenew2.mp4.json":[59117,9117],"./tepaenew3.mp4":[53403,3403],"./tepaenew3.mp4.json":[53403,3403]};function n(e){if(!o.o(r,e))return Promise.resolve().then(function(){var t=Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t});var t=r[e],n=t[0];return o.e(t[1]).then(function(){return o.t(n,19)})}n.keys=function(){return Object.keys(r)},n.id=47317,e.exports=n}},function(e){e.O(0,[9412,5675,4111,2888,9774,179],function(){return e(e.s=2506)}),_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.