

declare const RF;

@RF.decorateComponent({
    name: 'app-alert-dialog',
    template: require('./alertDialog.html')
})
export class AlertDialog {

    message = '';

    constructor(){
        (window as any).alertEx = (message)=>{
            RF.getComponentById('alertDialog').open(message);
        }
    }

    open(message){
        RF.getComponentById('alertModal').open();
        this.message = message;
    }
    close(){
        RF.getComponentById('alertModal').close();
        this.message = null;
    }

}