index.ts 1.0 KB
Newer Older
Y
yangxiaolu3 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
import { NutComponent } from './../../common/component.ts'

NutComponent({
  props: {
    show: {
      type: Boolean,
      value: false
    },
    zIndex: {
      type: [Number, String],
      value: 2000
    },
    duration: {
      type: [Number, String],
      value: 300
    },
    popStyle: String,
    popClass: {
      type: String,
      value: ''
    },
    round: {
      type: Boolean,
      value: false
    },
    overlay: {
      type: Boolean,
      value: true
    },
Y
yangxiaolu3 已提交
30 31 32 33 34
    position: {
      type: String,
      value: 'center'
    },
    overlayStyle: String,
Y
yangxiaolu3 已提交
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49

    closeable: {
      type: Boolean,
      value: false
    },
    closeIconPosition: {
      type: String,
      value: 'top-right'
    },
    closeIcon: {
      type: String,
      value: 'close'
    },

    // lockScroll:{}
Y
yangxiaolu3 已提交
50 51 52
  },

  methods: {
Y
yangxiaolu3 已提交
53 54 55 56
    onClickOverlay(){
      console.log('点击')

      this.$emit('clickOverlay')
Y
yangxiaolu3 已提交
57 58 59 60
    },

    onClickCloseIcon(){
      this.$emit('clickCloseIcon')
Y
yangxiaolu3 已提交
61 62 63
    }
  },
});