mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
git pull made
This commit is contained in:
@@ -26,6 +26,7 @@ import { Haptics, ImpactStyle } from '@capacitor/haptics';
|
||||
import { PreviewCameraPage } from 'src/app/modals/preview-camera/preview-camera.page';
|
||||
import { SqliteService } from 'src/app/services/sqlite.service';
|
||||
import { elementAt } from 'rxjs-compat/operator/elementAt';
|
||||
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
|
||||
|
||||
const IMAGE_DIR = 'stored-images';
|
||||
|
||||
@@ -667,7 +668,7 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy {
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
sliderOpts = {
|
||||
zoom: false,
|
||||
slidesPerView: 1.5,
|
||||
@@ -676,7 +677,7 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy {
|
||||
};
|
||||
zoomActive = false;
|
||||
zoomScale = 1;
|
||||
|
||||
|
||||
sliderZoomOpts = {
|
||||
allowSlidePrev: false,
|
||||
allowSlideNext: false,
|
||||
@@ -684,27 +685,27 @@ sliderZoomOpts = {
|
||||
maxRatio: 5
|
||||
},
|
||||
on: {
|
||||
zoomChange: (scale, imageEl, slideEl) => {
|
||||
zoomChange: (scale, imageEl, slideEl) => {
|
||||
this.zoomActive = true;
|
||||
this.zoomScale = scale/5;
|
||||
this.changeDetectorRef.detectChanges();
|
||||
this.changeDetectorRef.detectChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
async touchEnd(zoomslides: IonSlides, card) {
|
||||
// Zoom back to normal
|
||||
const slider = await zoomslides.getSwiper();
|
||||
const zoom = slider.zoom;
|
||||
zoom.out();
|
||||
|
||||
|
||||
// Card back to normal
|
||||
card.el.style['z-index'] = 9;
|
||||
|
||||
|
||||
this.zoomActive = false;
|
||||
this.changeDetectorRef.detectChanges();
|
||||
}
|
||||
|
||||
|
||||
touchStart(card) {
|
||||
// Make card appear above backdrop
|
||||
card.el.style['z-index'] = 11;
|
||||
@@ -713,15 +714,13 @@ touchStart(card) {
|
||||
|
||||
async openPreview(msg) {
|
||||
const modal = await this.modalController.create({
|
||||
component: PreviewCameraPage,
|
||||
component: ViewMediaPage,
|
||||
cssClass: 'modal modal-desktop',
|
||||
componentProps: {
|
||||
image: msg.attachments[0].image_url,
|
||||
username: msg.u.name,
|
||||
_updatedAt: msg._updatedAt,
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
modal.present();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user