mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
1 line
7.8 KiB
JSON
1 line
7.8 KiB
JSON
{"ast":null,"code":"import { r as registerInstance, e as createEvent, h, H as Host, i as getElement } from './index-7a8b7a1c.js';\nimport { b as getIonMode } from './ionic-global-63a97a32.js';\nconst imgCss = \":host{display:block;-o-object-fit:contain;object-fit:contain}img{display:block;width:100%;height:100%;-o-object-fit:inherit;object-fit:inherit;-o-object-position:inherit;object-position:inherit}\";\nconst Img = class {\n constructor(hostRef) {\n registerInstance(this, hostRef);\n this.ionImgWillLoad = createEvent(this, \"ionImgWillLoad\", 7);\n this.ionImgDidLoad = createEvent(this, \"ionImgDidLoad\", 7);\n this.ionError = createEvent(this, \"ionError\", 7);\n this.onLoad = () => {\n this.ionImgDidLoad.emit();\n };\n this.onError = () => {\n this.ionError.emit();\n };\n }\n srcChanged() {\n this.addIO();\n }\n componentDidLoad() {\n this.addIO();\n }\n addIO() {\n if (this.src === undefined) {\n return;\n }\n if (typeof window !== 'undefined' && 'IntersectionObserver' in window && 'IntersectionObserverEntry' in window && 'isIntersecting' in window.IntersectionObserverEntry.prototype) {\n this.removeIO();\n this.io = new IntersectionObserver(data => {\n /**\n * On slower devices, it is possible for an intersection observer entry to contain multiple\n * objects in the array. This happens when quickly scrolling an image into view and then out of\n * view. In this case, the last object represents the current state of the component.\n */\n if (data[data.length - 1].isIntersecting) {\n this.load();\n this.removeIO();\n }\n });\n this.io.observe(this.el);\n } else {\n // fall back to setTimeout for Safari and IE\n setTimeout(() => this.load(), 200);\n }\n }\n load() {\n this.loadError = this.onError;\n this.loadSrc = this.src;\n this.ionImgWillLoad.emit();\n }\n removeIO() {\n if (this.io) {\n this.io.disconnect();\n this.io = undefined;\n }\n }\n render() {\n return h(Host, {\n class: getIonMode(this)\n }, h(\"img\", {\n decoding: \"async\",\n src: this.loadSrc,\n alt: this.alt,\n onLoad: this.onLoad,\n onError: this.loadError,\n part: \"image\"\n }));\n }\n get el() {\n return getElement(this);\n }\n static get watchers() {\n return {\n \"src\": [\"srcChanged\"]\n };\n }\n};\nImg.style = imgCss;\nexport { Img as ion_img };","map":{"version":3,"names":["r","registerInstance","e","createEvent","h","H","Host","i","getElement","b","getIonMode","imgCss","Img","constructor","hostRef","ionImgWillLoad","ionImgDidLoad","ionError","onLoad","emit","onError","srcChanged","addIO","componentDidLoad","src","undefined","window","IntersectionObserverEntry","prototype","removeIO","io","IntersectionObserver","data","length","isIntersecting","load","observe","el","setTimeout","loadError","loadSrc","disconnect","render","class","decoding","alt","part","watchers","style","ion_img"],"sources":["C:/Users/eudes.inacio/GabineteDigital/gabinete-digital-fo/node_modules/@ionic/core/dist/esm/ion-img.entry.js"],"sourcesContent":["import { r as registerInstance, e as createEvent, h, H as Host, i as getElement } from './index-7a8b7a1c.js';\nimport { b as getIonMode } from './ionic-global-63a97a32.js';\n\nconst imgCss = \":host{display:block;-o-object-fit:contain;object-fit:contain}img{display:block;width:100%;height:100%;-o-object-fit:inherit;object-fit:inherit;-o-object-position:inherit;object-position:inherit}\";\n\nconst Img = class {\n constructor(hostRef) {\n registerInstance(this, hostRef);\n this.ionImgWillLoad = createEvent(this, \"ionImgWillLoad\", 7);\n this.ionImgDidLoad = createEvent(this, \"ionImgDidLoad\", 7);\n this.ionError = createEvent(this, \"ionError\", 7);\n this.onLoad = () => {\n this.ionImgDidLoad.emit();\n };\n this.onError = () => {\n this.ionError.emit();\n };\n }\n srcChanged() {\n this.addIO();\n }\n componentDidLoad() {\n this.addIO();\n }\n addIO() {\n if (this.src === undefined) {\n return;\n }\n if (typeof window !== 'undefined' &&\n 'IntersectionObserver' in window &&\n 'IntersectionObserverEntry' in window &&\n 'isIntersecting' in window.IntersectionObserverEntry.prototype) {\n this.removeIO();\n this.io = new IntersectionObserver(data => {\n /**\n * On slower devices, it is possible for an intersection observer entry to contain multiple\n * objects in the array. This happens when quickly scrolling an image into view and then out of\n * view. In this case, the last object represents the current state of the component.\n */\n if (data[data.length - 1].isIntersecting) {\n this.load();\n this.removeIO();\n }\n });\n this.io.observe(this.el);\n }\n else {\n // fall back to setTimeout for Safari and IE\n setTimeout(() => this.load(), 200);\n }\n }\n load() {\n this.loadError = this.onError;\n this.loadSrc = this.src;\n this.ionImgWillLoad.emit();\n }\n removeIO() {\n if (this.io) {\n this.io.disconnect();\n this.io = undefined;\n }\n }\n render() {\n return (h(Host, { class: getIonMode(this) }, h(\"img\", { decoding: \"async\", src: this.loadSrc, alt: this.alt, onLoad: this.onLoad, onError: this.loadError, part: \"image\" })));\n }\n get el() { return getElement(this); }\n static get watchers() { return {\n \"src\": [\"srcChanged\"]\n }; }\n};\nImg.style = imgCss;\n\nexport { Img as ion_img };\n"],"mappings":"AAAA,SAASA,CAAC,IAAIC,gBAAgB,EAAEC,CAAC,IAAIC,WAAW,EAAEC,CAAC,EAAEC,CAAC,IAAIC,IAAI,EAAEC,CAAC,IAAIC,UAAU,QAAQ,qBAAqB;AAC5G,SAASC,CAAC,IAAIC,UAAU,QAAQ,4BAA4B;AAE5D,MAAMC,MAAM,GAAG,oMAAoM;AAEnN,MAAMC,GAAG,GAAG,MAAM;EAChBC,WAAWA,CAACC,OAAO,EAAE;IACnBb,gBAAgB,CAAC,IAAI,EAAEa,OAAO,CAAC;IAC/B,IAAI,CAACC,cAAc,GAAGZ,WAAW,CAAC,IAAI,EAAE,gBAAgB,EAAE,CAAC,CAAC;IAC5D,IAAI,CAACa,aAAa,GAAGb,WAAW,CAAC,IAAI,EAAE,eAAe,EAAE,CAAC,CAAC;IAC1D,IAAI,CAACc,QAAQ,GAAGd,WAAW,CAAC,IAAI,EAAE,UAAU,EAAE,CAAC,CAAC;IAChD,IAAI,CAACe,MAAM,GAAG,MAAM;MAClB,IAAI,CAACF,aAAa,CAACG,IAAI,CAAC,CAAC;IAC3B,CAAC;IACD,IAAI,CAACC,OAAO,GAAG,MAAM;MACnB,IAAI,CAACH,QAAQ,CAACE,IAAI,CAAC,CAAC;IACtB,CAAC;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