javascript - Blueimp Gallery with Angular 2+ -


i integrated blueimp js gallery angular 2 (running angular-cli) application. installed through npm (npm install blueimp-gallery --save) , imported via .angular-cli.json:

"styles": [   "../node_modules/blueimp-gallery/css/blueimp-gallery.css",   "../node_modules/blueimp-gallery/css/blueimp-gallery-indicator.css" ], "scripts": [   "../node_modules/blueimp-gallery/js/blueimp-helper.js",   "../node_modules/blueimp-gallery/js/blueimp-gallery.js",   "../node_modules/blueimp-gallery/js/blueimp-gallery-indicator.js" ] 

from there, use in angular components:

//from .angular-cli.json declare const blueimp: any;  public show(event: any, images: any[]) {     const options = {         event: event || window.event,     };      blueimp.gallery(images, options); }; 

so far, good: works fine, can use gallery. i've been receiving crash reports customers on mobile devices. wanted open github issue, seems it's not possible on blueimp/gallery github repo.

here crash that's seen lot on android devices:

typeerror: cannot read property 'style' of undefined     @ gallery.translate (eval @ p+fo.t.exports (/scripts.46c7e72cc98882b84ae5.bundle.js:1:18074), <anonymous>:492:37)     @ gallery.translatex (eval @ p+fo.t.exports (/scripts.46c7e72cc98882b84ae5.bundle.js:1:18074), <anonymous>:501:12)     @ gallery.move (eval @ p+fo.t.exports (/scripts.46c7e72cc98882b84ae5.bundle.js:1:18074), <anonymous>:487:12)     @ gallery.slide (eval @ p+fo.t.exports (/scripts.46c7e72cc98882b84ae5.bundle.js:1:18074), <anonymous>:339:14)     @ eval (eval @ p+fo.t.exports (/scripts.46c7e72cc98882b84ae5.bundle.js:1:18074), <anonymous>:384:22)     @ n.invoketask (/polyfills.0a60947aabdcee7751c0.bundle.js:36:7074)     @ object.oninvoketask (/vendor.7a5c4da3f678e71e26f9.bundle.js:261:2558)     @ n.invoketask (/polyfills.0a60947aabdcee7751c0.bundle.js:36:7010)     @ t.runtask (/polyfills.0a60947aabdcee7751c0.bundle.js:36:4427)     @ invoke (/polyfills.0a60947aabdcee7751c0.bundle.js:36:8187)     @ t.args.(anonymous function) (/polyfills.0a60947aabdcee7751c0.bundle.js:15:85) 

and 1 happens exclusively on ios devices:

exception: undefined not object (evaluating 'this.slides[index].style')     translate     translatex     move     slide  invoketask@/polyfills.0a60947aabdcee7751c0.bundle.js:36:7079 oninvoketask@/vendor.7a5c4da3f678e71e26f9.bundle.js:261:2568 invoketask@/polyfills.0a60947aabdcee7751c0.bundle.js:36:7022 runtask@/polyfills.0a60947aabdcee7751c0.bundle.js:36:4437 invoke@/polyfills.0a60947aabdcee7751c0.bundle.js:36:8194 

both crashes in same part of blueimp code. can't seem reproduce certainty crashes , struggling fix them.

has been using blueimp angular 2+ ? has seen similar issues blueimp gallery ?


Comments

Popular posts from this blog

python Tkinter Capturing keyboard events save as one single string -

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

javascript - Z-index in d3.js -