import { Loading } from 'element-ui';

var loading = {
  //打开Loading
  openLoading:function () {
    return Loading.service({
      //target: document.querySelector('.page'),
      lock: true,
      text: 'Loading',
      //fullscreen: true,
      spinner: 'el-icon-loading',
      background: 'rgba(0, 0, 0, 0.7)'
    });
  },

  //关闭Loading
  closeLoading:function (loadingInstance) {
    loadingInstance.close()
  },
}

export default loading
