mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
Added styles to Expediente Module
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { LoadingController } from '@ionic/angular';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class LoadingService {
|
||||
|
||||
constructor(public loadingController: LoadingController) { }
|
||||
|
||||
async simpleLoading(message:string) {
|
||||
const loading = await this.loadingController.create({
|
||||
cssClass: 'my-custom-class',
|
||||
message:message,
|
||||
duration: 2000
|
||||
});
|
||||
await loading.present();
|
||||
|
||||
const { role, data } = await loading.onDidDismiss();
|
||||
console.log('Loading dismissed!');
|
||||
}
|
||||
|
||||
async customizedLoading() {
|
||||
const loading = await this.loadingController.create({
|
||||
cssClass: 'my-custom-class',
|
||||
spinner: null,
|
||||
duration: 5000,
|
||||
message: 'Click the backdrop to dismiss early...',
|
||||
translucent: true,
|
||||
backdropDismiss: true
|
||||
});
|
||||
await loading.present();
|
||||
|
||||
const { role, data } = await loading.onDidDismiss();
|
||||
console.log('Loading dismissed with role:', role);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user