import TyComponent from '../common/component'

TyComponent({
  /**
   * 组件的属性列表
   */
  properties: {

    icon: {
      type: String
    },
    title: {
      type: [String, Number]
    },
    titleWidth: {
      type: String
    },
    value: {
      type: [String, Number]
    },
    label: {
      type: String
    },
    size: {
      type: String
    },
    border: {
      type: Boolean,
      value: true
    },
    center: {
      type: Boolean,
      value: false
    },
    url: {
      type: String
    },
    linkType: {
      type: String,
      value: 'navigateTo'
    },
    clickable: {
      type: Boolean,
      value: false
    },
    isLink: {
      type: Boolean,
      value: false
    },
    required: {
      type: Boolean,
      value: false
    },
    arrowDirection: {
      type: String
    },
    useLabelSlot: {
      type: Boolean,
      value: false
    },
    customClass: {
      type: String
    },
    titleClass: {
      type: String
    },
    labelClass: {
      type: String
    },
    valueClass: {
      type: String
    }

  },

  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    handleClick({detail}) {
      this.triggerEvent('click', detail)
    },
  }
})
