props.js 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. export default {
  2. props: {
  3. // 滑块的移动过渡时间,单位ms
  4. duration: {
  5. type: Number,
  6. default: uni.$u.props.tabs.duration
  7. },
  8. // tabs标签数组
  9. list: {
  10. type: Array,
  11. default: uni.$u.props.tabs.list
  12. },
  13. // 滑块颜色
  14. lineColor: {
  15. type: String,
  16. default: uni.$u.props.tabs.lineColor
  17. },
  18. // 菜单选择中时的样式
  19. activeStyle: {
  20. type: [String, Object],
  21. default: uni.$u.props.tabs.activeStyle
  22. },
  23. // 菜单非选中时的样式
  24. inactiveStyle: {
  25. type: [String, Object],
  26. default: uni.$u.props.tabs.inactiveStyle
  27. },
  28. // 滑块长度
  29. lineWidth: {
  30. type: [String, Number],
  31. default: uni.$u.props.tabs.lineWidth
  32. },
  33. // 滑块高度
  34. lineHeight: {
  35. type: [String, Number],
  36. default: uni.$u.props.tabs.lineHeight
  37. },
  38. // 滑块背景显示大小,当滑块背景设置为图片时使用
  39. lineBgSize: {
  40. type: String,
  41. default: uni.$u.props.tabs.lineBgSize
  42. },
  43. // 菜单item的样式
  44. itemStyle: {
  45. type: [String, Object],
  46. default: uni.$u.props.tabs.itemStyle
  47. },
  48. // 菜单是否可滚动
  49. scrollable: {
  50. type: Boolean,
  51. default: uni.$u.props.tabs.scrollable
  52. },
  53. // 当前选中标签的索引
  54. current: {
  55. type: [Number, String],
  56. default: uni.$u.props.tabs.current
  57. },
  58. // 默认读取的键名
  59. keyName: {
  60. type: String,
  61. default: uni.$u.props.tabs.keyName
  62. }
  63. }
  64. }