kolkov / ngx-gallery

A simple responsive native gallery component for Angular 8+.
https://ngx-gallery.kolkov.ru/
MIT License
115 stars 55 forks source link

base64 working example #17

Closed gmareater closed 4 years ago

gmareater commented 4 years ago

hi thanx for you work, currently i'm trying to show images with base64, but i doesn't work (and i almost tried all suggestion from lukasz-galka repo

so, could you provide a working example so i could get what's wrong here?

i used : this.sanitizer.bypassSecurityTrustUrl and bypassSecurityTrustResourceUrl , none of them worked

cyrilinho commented 4 years ago

Hi, I don't know if it will help you, but this is what I did :

base64 : string var imageUrl : string = 'data:image/jpeg;base64,' + base64; var img : NgxGalleryImage; img = {
small : imageUrl, medium: imageUrl, big: imageUrl } this.galleryImages.push(img);

kolkov commented 4 years ago

Now we can put URL by URL.createObjectURL(blob)as addition feature