props.js 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. import defprops from '../../libs/config/props';
  2. export default {
  3. props: {
  4. // 是否开启顶部安全区适配
  5. safeAreaInsetTop: {
  6. type: Boolean,
  7. default: defprops.navbar.safeAreaInsetTop
  8. },
  9. // 固定在顶部时,是否生成一个等高元素,以防止塌陷
  10. placeholder: {
  11. type: Boolean,
  12. default: defprops.navbar.placeholder
  13. },
  14. // 是否固定在顶部
  15. fixed: {
  16. type: Boolean,
  17. default: defprops.navbar.fixed
  18. },
  19. // 是否显示下边框
  20. border: {
  21. type: Boolean,
  22. default: defprops.navbar.border
  23. },
  24. // 左边的图标
  25. leftIcon: {
  26. type: String,
  27. default: defprops.navbar.leftIcon
  28. },
  29. // 左边的提示文字
  30. leftText: {
  31. type: String,
  32. default: defprops.navbar.leftText
  33. },
  34. // 左右的提示文字
  35. rightText: {
  36. type: String,
  37. default: defprops.navbar.rightText
  38. },
  39. // 右边的图标
  40. rightIcon: {
  41. type: String,
  42. default: defprops.navbar.rightIcon
  43. },
  44. // 标题
  45. title: {
  46. type: [String, Number],
  47. default: defprops.navbar.title
  48. },
  49. // 背景颜色
  50. bgColor: {
  51. type: String,
  52. default: defprops.navbar.bgColor
  53. },
  54. // 标题的宽度
  55. titleWidth: {
  56. type: [String, Number],
  57. default: defprops.navbar.titleWidth
  58. },
  59. // 导航栏高度
  60. height: {
  61. type: [String, Number],
  62. default: defprops.navbar.height
  63. },
  64. // 左侧返回图标的大小
  65. leftIconSize: {
  66. type: [String, Number],
  67. default: defprops.navbar.leftIconSize
  68. },
  69. // 左侧返回图标的颜色
  70. leftIconColor: {
  71. type: String,
  72. default: defprops.navbar.leftIconColor
  73. },
  74. // 点击左侧区域(返回图标),是否自动返回上一页
  75. autoBack: {
  76. type: Boolean,
  77. default: defprops.navbar.autoBack
  78. },
  79. // 标题的样式,对象或字符串
  80. titleStyle: {
  81. type: [String, Object],
  82. default: defprops.navbar.titleStyle
  83. }
  84. }
  85. }