props.js 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. import { defineMixin } from '../../libs/vue'
  2. import defProps from '../../libs/config/props.js'
  3. export const props = defineMixin({
  4. props: {
  5. // 显示文字
  6. title: {
  7. type: String,
  8. default: () => defProps.alert.title
  9. },
  10. // 主题,success/warning/info/error
  11. type: {
  12. type: String,
  13. default: () => defProps.alert.type
  14. },
  15. // 辅助性文字
  16. description: {
  17. type: String,
  18. default: () => defProps.alert.description
  19. },
  20. // 是否可关闭
  21. closable: {
  22. type: Boolean,
  23. default: () => defProps.alert.closable
  24. },
  25. // 是否显示图标
  26. showIcon: {
  27. type: Boolean,
  28. default: () => defProps.alert.showIcon
  29. },
  30. // 浅或深色调,light-浅色,dark-深色
  31. effect: {
  32. type: String,
  33. default: () => defProps.alert.effect
  34. },
  35. // 文字是否居中
  36. center: {
  37. type: Boolean,
  38. default: () => defProps.alert.center
  39. },
  40. // 字体大小
  41. fontSize: {
  42. type: [String, Number],
  43. default: () => defProps.alert.fontSize
  44. }
  45. }
  46. })