Files
004_comission/_utils/_comment_backup/louis coding's Reviews on Carousell Hong Kong_files/43011902b53e0308.min.js.download
louiscklaw 6c60a73f30 update,
2025-01-31 19:15:17 +08:00

6 lines
4.1 KiB
Plaintext

"use strict";
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},n=(new Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="5909b57a-6a8a-524b-8a8f-8cf161889798")}catch(e){}}();
(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[15],{2428:(e,t,i)=>{i.d(t,{YD:()=>u,df:()=>d});var r=i(0),n=Object.defineProperty,s=(e,t,i)=>(((e,t,i)=>{t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i})(e,"symbol"!=typeof t?t+"":t,i),i),o=new Map,h=new WeakMap,l=0,a=void 0;function c(e,t,i={},r=a){if(void 0===window.IntersectionObserver&&void 0!==r){const n=e.getBoundingClientRect();return t(r,{isIntersecting:r,target:e,intersectionRatio:"number"==typeof i.threshold?i.threshold:0,time:0,boundingClientRect:n,intersectionRect:n,rootBounds:n}),()=>{}}const{id:n,observer:s,elements:c}=function(e){let t=function(e){return Object.keys(e).sort().filter((t=>void 0!==e[t])).map((t=>{return`${t}_${"root"===t?(i=e.root,i?(h.has(i)||(l+=1,h.set(i,l.toString())),h.get(i)):"0"):e[t]}`;var i})).toString()}(e),i=o.get(t);if(!i){const r=new Map;let n;const s=new IntersectionObserver((t=>{t.forEach((t=>{var i;const s=t.isIntersecting&&n.some((e=>t.intersectionRatio>=e));e.trackVisibility&&void 0===t.isVisible&&(t.isVisible=s),null==(i=r.get(t.target))||i.forEach((e=>{e(s,t)}))}))}),e);n=s.thresholds||(Array.isArray(e.threshold)?e.threshold:[e.threshold||0]),i={id:t,observer:s,elements:r},o.set(t,i)}return i}(i);let d=c.get(e)||[];return c.has(e)||c.set(e,d),d.push(t),s.observe(e),function(){d.splice(d.indexOf(t),1),0===d.length&&(c.delete(e),s.unobserve(e)),0===c.size&&(s.disconnect(),o.delete(n))}}var d=class extends r.Component{constructor(e){super(e),s(this,"node",null),s(this,"_unobserveCb",null),s(this,"handleNode",(e=>{this.node&&(this.unobserve(),e||this.props.triggerOnce||this.props.skip||this.setState({inView:!!this.props.initialInView,entry:void 0})),this.node=e||null,this.observeNode()})),s(this,"handleChange",((e,t)=>{e&&this.props.triggerOnce&&this.unobserve(),function(e){return"function"!=typeof e.children}(this.props)||this.setState({inView:e,entry:t}),this.props.onChange&&this.props.onChange(e,t)})),this.state={inView:!!e.initialInView,entry:void 0}}componentDidUpdate(e){e.rootMargin===this.props.rootMargin&&e.root===this.props.root&&e.threshold===this.props.threshold&&e.skip===this.props.skip&&e.trackVisibility===this.props.trackVisibility&&e.delay===this.props.delay||(this.unobserve(),this.observeNode())}componentWillUnmount(){this.unobserve(),this.node=null}observeNode(){if(!this.node||this.props.skip)return;const{threshold:e,root:t,rootMargin:i,trackVisibility:r,delay:n,fallbackInView:s}=this.props;this._unobserveCb=c(this.node,this.handleChange,{threshold:e,root:t,rootMargin:i,trackVisibility:r,delay:n},s)}unobserve(){this._unobserveCb&&(this._unobserveCb(),this._unobserveCb=null)}render(){const{children:e}=this.props;if("function"==typeof e){const{inView:t,entry:i}=this.state;return e({inView:t,entry:i,ref:this.handleNode})}const{as:t,triggerOnce:i,threshold:n,root:s,rootMargin:o,onChange:h,skip:l,trackVisibility:a,delay:c,initialInView:d,fallbackInView:u,...p}=this.props;return r.createElement(t||"div",{ref:this.handleNode,...p},e)}};function u({threshold:e,delay:t,trackVisibility:i,rootMargin:n,root:s,triggerOnce:o,skip:h,initialInView:l,fallbackInView:a,onChange:d}={}){var u;const[p,b]=r.useState(null),g=r.useRef(),[v,y]=r.useState({inView:!!l,entry:void 0});g.current=d,r.useEffect((()=>{if(h||!p)return;let r;return r=c(p,((e,t)=>{y({inView:e,entry:t}),g.current&&g.current(e,t),t.isIntersecting&&o&&r&&(r(),r=void 0)}),{root:s,rootMargin:n,threshold:e,trackVisibility:i,delay:t},a),()=>{r&&r()}}),[Array.isArray(e)?e.toString():e,p,s,n,o,h,i,a,t]);const f=null==(u=v.entry)?void 0:u.target,V=r.useRef();p||!f||o||h||V.current===f||(V.current=f,y({inView:!!l,entry:void 0}));const w=[b,v.inView,v.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}}}]);
//# sourceMappingURL=https://mdev.llesuorac.com/6c92b51985b2424a01cb9bab4fdb342b9927ade5/43011902b53e0308.min.js.map
//# debugId=5909b57a-6a8a-524b-8a8f-8cf161889798