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.

93 lines
2.7 KiB

5 months ago
  1. import { defineMixin } from '../../libs/vue'
  2. import defProps from '../../libs/config/props.js'
  3. export const props = defineMixin({
  4. props: {
  5. // 标识符
  6. name: {
  7. type: String,
  8. default: () => defProps.checkboxGroup.name
  9. },
  10. // #ifdef VUE3
  11. // 绑定的值
  12. modelValue: {
  13. type: Array,
  14. default: () => defProps.checkboxGroup.value
  15. },
  16. // #endif
  17. // #ifdef VUE2
  18. // 绑定的值
  19. value: {
  20. type: Array,
  21. default: () => defProps.checkboxGroup.value
  22. },
  23. // #endif
  24. // 形状,circle-圆形,square-方形
  25. shape: {
  26. type: String,
  27. default: () => defProps.checkboxGroup.shape
  28. },
  29. // 是否禁用全部checkbox
  30. disabled: {
  31. type: Boolean,
  32. default: () => defProps.checkboxGroup.disabled
  33. },
  34. // 选中状态下的颜色,如设置此值,将会覆盖parent的activeColor值
  35. activeColor: {
  36. type: String,
  37. default: () => defProps.checkboxGroup.activeColor
  38. },
  39. // 未选中的颜色
  40. inactiveColor: {
  41. type: String,
  42. default: () => defProps.checkboxGroup.inactiveColor
  43. },
  44. // 整个组件的尺寸,默认px
  45. size: {
  46. type: [String, Number],
  47. default: () => defProps.checkboxGroup.size
  48. },
  49. // 布局方式,row-横向,column-纵向
  50. placement: {
  51. type: String,
  52. default: () => defProps.checkboxGroup.placement
  53. },
  54. // label的字体大小,px单位
  55. labelSize: {
  56. type: [String, Number],
  57. default: () => defProps.checkboxGroup.labelSize
  58. },
  59. // label的字体颜色
  60. labelColor: {
  61. type: [String],
  62. default: () => defProps.checkboxGroup.labelColor
  63. },
  64. // 是否禁止点击文本操作
  65. labelDisabled: {
  66. type: Boolean,
  67. default: () => defProps.checkboxGroup.labelDisabled
  68. },
  69. // 图标颜色
  70. iconColor: {
  71. type: String,
  72. default: () => defProps.checkboxGroup.iconColor
  73. },
  74. // 图标的大小,单位px
  75. iconSize: {
  76. type: [String, Number],
  77. default: () => defProps.checkboxGroup.iconSize
  78. },
  79. // 勾选图标的对齐方式,left-左边,right-右边
  80. iconPlacement: {
  81. type: String,
  82. default: () => defProps.checkboxGroup.iconPlacement
  83. },
  84. // 竖向配列时,是否显示下划线
  85. borderBottom: {
  86. type: Boolean,
  87. default: () => defProps.checkboxGroup.borderBottom
  88. }
  89. }
  90. })