You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

65 lines
1.8 KiB

  1. import { defineMixin } from '../../libs/vue'
  2. import EmptyDefaultProps from './empty'
  3. import { registerComponentProps } from '../../libs/config/props.js'
  4. const defProps = registerComponentProps(EmptyDefaultProps)
  5. export const props = defineMixin({
  6. props: {
  7. // 内置图标名称,或图片路径,建议绝对路径
  8. icon: {
  9. type: String,
  10. default: () => defProps.empty.icon
  11. },
  12. // 提示文字
  13. text: {
  14. type: String,
  15. default: () => defProps.empty.text
  16. },
  17. // 文字颜色
  18. textColor: {
  19. type: String,
  20. default: () => defProps.empty.textColor
  21. },
  22. // 文字大小
  23. textSize: {
  24. type: [String, Number],
  25. default: () => defProps.empty.textSize
  26. },
  27. // 图标的颜色
  28. iconColor: {
  29. type: String,
  30. default: () => defProps.empty.iconColor
  31. },
  32. // 图标的大小
  33. iconSize: {
  34. type: [String, Number],
  35. default: () => defProps.empty.iconSize
  36. },
  37. // 选择预置的图标类型
  38. mode: {
  39. type: String,
  40. default: () => defProps.empty.mode
  41. },
  42. // 图标宽度,单位px
  43. width: {
  44. type: [String, Number],
  45. default: () => defProps.empty.width
  46. },
  47. // 图标高度,单位px
  48. height: {
  49. type: [String, Number],
  50. default: () => defProps.empty.height
  51. },
  52. // 是否显示组件
  53. show: {
  54. type: Boolean,
  55. default: () => defProps.empty.show
  56. },
  57. // 组件距离上一个元素之间的距离,默认px单位
  58. marginTop: {
  59. type: [String, Number],
  60. default: () => defProps.empty.marginTop
  61. }
  62. }
  63. })