import {
	observable,
	action,
} from 'mobx';

export default class DialogStore {
	title;

	get staticDialogProps() {
		return {
			icon: 'icon-coms-hrm',
			iconBgcolor: '#217346',
			onCancel: () => this.closeDialog && this.closeDialog(),
			hasScroll: true,
			moreBtn: {
				datas: []
			},
		}
	};

	@observable buttons = [];

	@observable visible = false;

	@action openDialog = () => {
		this.visible = true;
	}

	@action closeDialog = () => {
		this.visible = false;
	}

	@action setDialogButtons = (buttons) => {
		this.buttons = buttons;
	}

	setDialogTitle = (title) => {
		this.title = title;
	}
}