mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 21:35:50 +00:00
save
This commit is contained in:
@@ -277,20 +277,41 @@ export class PublicationsPage implements OnInit {
|
||||
}
|
||||
}
|
||||
|
||||
async openOptions(taskAction?: any) {
|
||||
|
||||
const popover = await this.modalController.create({
|
||||
async openOptions(id?: string) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: ActionsOptionsPage,
|
||||
cssClass: 'model aside-modal',
|
||||
cssClass: 'model profile-modal search-submodal',
|
||||
componentProps: {
|
||||
/* task: this.task,
|
||||
fulltask: this.fulltask, */
|
||||
taskAction: taskAction,
|
||||
showEnviarPendentes: false
|
||||
id: id,
|
||||
},
|
||||
//translucent: true
|
||||
});
|
||||
return await popover.present();
|
||||
return await modal.present();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user