props.js 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. import defprops from '../../libs/config/props';
  2. export default {
  3. props: {
  4. // tab的数据
  5. list: {
  6. type: Array,
  7. default: defprops.subsection.list
  8. },
  9. // 当前活动的tab的index
  10. current: {
  11. type: [String, Number],
  12. default: defprops.subsection.current
  13. },
  14. // 激活的颜色
  15. activeColor: {
  16. type: String,
  17. default: defprops.subsection.activeColor
  18. },
  19. // 未激活的颜色
  20. inactiveColor: {
  21. type: String,
  22. default: defprops.subsection.inactiveColor
  23. },
  24. // 模式选择,mode=button为按钮形式,mode=subsection时为分段模式
  25. mode: {
  26. type: String,
  27. default: defprops.subsection.mode
  28. },
  29. // 字体大小
  30. fontSize: {
  31. type: [String, Number],
  32. default: defprops.subsection.fontSize
  33. },
  34. // 激活tab的字体是否加粗
  35. bold: {
  36. type: Boolean,
  37. default: defprops.subsection.bold
  38. },
  39. // mode = button时,组件背景颜色
  40. bgColor: {
  41. type: String,
  42. default: defprops.subsection.bgColor
  43. },
  44. // 从list元素对象中读取的键名
  45. keyName: {
  46. type: String,
  47. default: defprops.subsection.keyName
  48. }
  49. }
  50. }