resizingChatPhotos

This commit is contained in:
ivan gomes
2021-11-18 13:01:53 +01:00
parent 4262597360
commit e622acc98e
332 changed files with 6194 additions and 45009 deletions
@@ -7,12 +7,14 @@ import { IonicModule } from '@ionic/angular';
import { PreviewCameraPageRoutingModule } from './preview-camera-routing.module';
import { PreviewCameraPage } from './preview-camera.page';
import { ImageCropperModule } from 'ngx-image-cropper';
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
ImageCropperModule,
PreviewCameraPageRoutingModule
],
declarations: [PreviewCameraPage]
@@ -3,21 +3,25 @@
<ion-card-content >
<ion-card-header >
<ion-toolbar>
<ion-title>{{username}} <span>{{_updatedAt}}</span> </ion-title>
{{username}} <span>{{_updatedAt}}</span>
</ion-toolbar>
</ion-card-header>
<img src="{{image}}" />
<!-- <ion-slides #slider [options]="slideOpts">
<ion-slide >
<div class="swiper-zoom-container">
</div>
</ion-slide>
</ion-slides> -->
</ion-card-content>
<!-- <image-cropper [imageBase64]="myimage"
[maintainAspectRatio]="true"
[aspectRatio]="4 / 3"
outputType = "base64"
format="png"
[resizeToWidth]="true"
(imageCropped)="imageCropped($event)"
></image-cropper> -->
<ion-footer>
<ion-row>
@@ -1,5 +1,7 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { IonSlides, ModalController, NavParams } from '@ionic/angular';
import { ImageCroppedEvent } from 'ngx-image-cropper';
import { GroupIconsPage } from '../group-icons/group-icons.page';
@Component({
selector: 'app-preview-camera',
@@ -17,6 +19,10 @@ export class PreviewCameraPage implements OnInit {
username: string
_updatedAt: string
// myimage: null
// croppedImageBase64: any
// @Input('img') img: any
// @Input() username: string;
// @Input() date: string;
@@ -31,6 +37,7 @@ ngOnInit() {
this.username = this.navParams.get('username')
this._updatedAt = this.navParams.get('_updatedAt')
console.log(this.image)
// this.image = this.myimage
}
ionViewDidEnter(){
@@ -46,6 +53,20 @@ async zoom(zoomIn: boolean){
close(){
this.modalController.dismiss()
}
// imageCropped(ev: ImageCroppedEvent){
// this.croppedImageBase64 = ev.base64
// }
// async grupo(){
// const modal = await this.modalController.create({
// component: GroupIconsPage,
// cssClass: 'transparent-modal',
// });
// modal.present();
// }
}