pages.config.ts 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378
  1. import { defineUniPages } from '@uni-helper/vite-plugin-uni-pages'
  2. export default defineUniPages({
  3. globalStyle: {
  4. 'navigationStyle': 'default',
  5. 'navigationBarTitleText': 'BandhuBuy',
  6. 'navigationBarBackgroundColor': '#f8f8f8',
  7. 'navigationBarTextStyle': 'black',
  8. 'backgroundColor': '#FFFFFF',
  9. 'pageOrientation': 'auto',
  10. 'app-plus': {
  11. scrollIndicator: 'none',
  12. screenOrientation: [
  13. 'portrait-primary', // 可选,字符串类型,支持竖屏
  14. 'portrait-secondary', // 可选,字符串类型,支持反向竖屏
  15. 'landscape-primary', // 可选,字符串类型,支持横屏
  16. 'landscape-secondary', // 可选,字符串类型,支持反向横屏
  17. ],
  18. },
  19. },
  20. easycom: {
  21. autoscan: true,
  22. custom: {
  23. '^fg-(.*)': '@/components/fg-$1/fg-$1.vue',
  24. '^wd-(.*)': 'wot-design-uni/components/wd-$1/wd-$1.vue',
  25. '^(?!z-paging-refresh|z-paging-load-more)z-paging(.*)': 'z-paging/components/z-paging$1/z-paging$1.vue',
  26. },
  27. },
  28. /**
  29. * 2025-06-25 v3.3.0版(重新梳理tabbar配置)
  30. *
  31. * 1)原生tabbar,不需要关心 `layouts/fg-tabbar` 文件夹里面的内容。(这是默认配置)
  32. * 2)自定义tabbar(带缓存),保留下面的配置和修改 `/layouts/fg-tabbar/tabbarList.ts` 对应的代码。
  33. * 3)自定义tabbar(不带缓存),删除下面的配置和修改 `/layouts/fg-tabbar/tabbarList.ts` 对应的代码。
  34. * 4)无tabbar,直接删除下面的tabBar配置即可。
  35. *
  36. * 温馨提示:本文件的任何代码更改了之后,都需要重新运行,否则 pages.json 还是旧的,导致不是预期效果。
  37. */
  38. tabBar: {
  39. color: '#999999',
  40. selectedColor: '#e61b28',
  41. backgroundColor: '#ffffff',
  42. // backgroundColor: 'rgba(255, 255, 255, 0.6)',
  43. // blurEffect: 'extralight',
  44. borderStyle: '#c1c1c1',
  45. height: '50px',
  46. fontSize: '10px',
  47. iconWidth: '24px',
  48. spacing: '3px',
  49. list: [
  50. {
  51. iconPath: 'static/tabbar/home.png',
  52. selectedIconPath: 'static/tabbar/homeHL.png',
  53. pagePath: 'pages/index/index',
  54. },
  55. {
  56. iconPath: 'static/tabbar/income.png',
  57. selectedIconPath: 'static/tabbar/incomeHL.png',
  58. pagePath: 'pages/income/income',
  59. },
  60. {
  61. iconPath: 'static/tabbar/mine.png',
  62. selectedIconPath: 'static/tabbar/mineHL.png',
  63. pagePath: 'pages/mine/mine',
  64. },
  65. ],
  66. },
  67. pages: [
  68. {
  69. path: 'pages/index/index',
  70. type: 'home',
  71. layout: 'tabbar',
  72. style: {
  73. navigationStyle: 'custom',
  74. },
  75. },
  76. {
  77. path: 'pages/bestSellers/bestSellers',
  78. type: 'page',
  79. layout: 'default',
  80. style: {
  81. navigationStyle: 'custom',
  82. },
  83. },
  84. {
  85. path: 'pages/forgotPassword/forgotPassword',
  86. type: 'page',
  87. layout: 'default',
  88. style: {
  89. navigationStyle: 'custom',
  90. },
  91. },
  92. {
  93. path: 'pages/income/income',
  94. type: 'page',
  95. layout: 'tabbar',
  96. style: {
  97. navigationBarTitleText: '%income.title%',
  98. navigationBarBackgroundColor: '#fff',
  99. },
  100. },
  101. {
  102. path: 'pages/login/login',
  103. type: 'page',
  104. layout: 'default',
  105. style: {
  106. navigationStyle: 'custom',
  107. },
  108. },
  109. {
  110. path: 'pages/mine/addressBook',
  111. type: 'page',
  112. layout: 'default',
  113. style: {
  114. navigationBarTitleText: '%addressBook.title%',
  115. navigationBarBackgroundColor: '#fff',
  116. },
  117. },
  118. {
  119. path: 'pages/mine/addressBookOperate',
  120. type: 'page',
  121. layout: 'default',
  122. style: {
  123. navigationBarTitleText: '%addressBook.title%',
  124. navigationBarBackgroundColor: '#fff',
  125. },
  126. },
  127. {
  128. path: 'pages/mine/helpCenter',
  129. type: 'page',
  130. layout: 'default',
  131. style: {
  132. navigationBarTitleText: '%helpCenter.title%',
  133. navigationBarBackgroundColor: '#fff',
  134. },
  135. },
  136. {
  137. path: 'pages/mine/helpCenterDetail',
  138. type: 'page',
  139. layout: 'default',
  140. style: {
  141. navigationBarTitleText: '%helpCenter.detail.title%',
  142. navigationBarBackgroundColor: '#fff',
  143. },
  144. },
  145. {
  146. path: 'pages/mine/mine',
  147. type: 'page',
  148. layout: 'tabbar',
  149. style: {
  150. navigationStyle: 'custom',
  151. },
  152. },
  153. {
  154. path: 'pages/mine/myFavorite',
  155. type: 'page',
  156. layout: 'default',
  157. style: {
  158. navigationBarTitleText: '%mine.pages.myFavorite.title%',
  159. navigationBarBackgroundColor: '#fff',
  160. },
  161. },
  162. {
  163. path: 'pages/mine/myProfile',
  164. type: 'page',
  165. layout: 'default',
  166. style: {
  167. navigationBarTitleText: '%myProfile.title%',
  168. navigationBarBackgroundColor: '#fff',
  169. },
  170. },
  171. {
  172. path: 'pages/mine/setting',
  173. type: 'page',
  174. layout: 'default',
  175. style: {
  176. navigationBarTitleText: '%setting.title%',
  177. navigationBarBackgroundColor: '#fff',
  178. },
  179. },
  180. {
  181. path: 'pages/mine/share',
  182. type: 'page',
  183. layout: 'default',
  184. style: {
  185. navigationStyle: 'custom',
  186. navigationBarTitleText: '%mine.pages.share.title%',
  187. },
  188. },
  189. {
  190. path: 'pages/missionCenter/missionCenter',
  191. type: 'page',
  192. layout: 'default',
  193. needLogin: true,
  194. style: {
  195. navigationBarTitleText: '%missionCenter.title%',
  196. navigationBarBackgroundColor: '#fff',
  197. },
  198. },
  199. {
  200. path: 'pages/myOrders/myOrders',
  201. type: 'page',
  202. layout: 'default',
  203. style: {
  204. navigationBarTitleText: '%myOrders.title%',
  205. navigationBarBackgroundColor: '#fff',
  206. },
  207. },
  208. {
  209. path: 'pages/myOrders/orderDetail',
  210. type: 'page',
  211. layout: 'default',
  212. style: {
  213. navigationBarTitleText: '%orderDetail.title%',
  214. navigationBarBackgroundColor: '#fff',
  215. },
  216. },
  217. {
  218. path: 'pages/notifications/notifications',
  219. type: 'page',
  220. layout: 'default',
  221. needLogin: true,
  222. style: {
  223. navigationStyle: 'custom',
  224. },
  225. },
  226. {
  227. path: 'pages/productDetail/checkOut',
  228. type: 'page',
  229. layout: 'default',
  230. needLogin: true,
  231. style: {
  232. navigationBarTitleText: '%checkout.title%',
  233. navigationBarBackgroundColor: '#fff',
  234. },
  235. },
  236. {
  237. path: 'pages/productDetail/productDetail',
  238. type: 'page',
  239. layout: 'default',
  240. style: {
  241. navigationStyle: 'custom',
  242. },
  243. },
  244. {
  245. path: 'pages/referEarn/referEarn',
  246. type: 'page',
  247. layout: 'default',
  248. style: {
  249. navigationStyle: 'custom',
  250. },
  251. },
  252. {
  253. path: 'pages/register/register',
  254. type: 'page',
  255. layout: 'default',
  256. style: {
  257. navigationStyle: 'custom',
  258. },
  259. },
  260. {
  261. path: 'pages/search/search',
  262. type: 'page',
  263. layout: 'default',
  264. style: {
  265. navigationStyle: 'custom',
  266. },
  267. },
  268. {
  269. path: 'pages/topChampions/topChampions',
  270. type: 'page',
  271. layout: 'default',
  272. style: {
  273. navigationStyle: 'custom',
  274. },
  275. },
  276. {
  277. path: 'pages/vipMembership/vipMembership',
  278. type: 'page',
  279. layout: 'default',
  280. needLogin: true,
  281. style: {
  282. navigationBarTitleText: '%vipMembership.title%',
  283. navigationBarBackgroundColor: '#FFFFFF',
  284. },
  285. },
  286. {
  287. path: 'pages/wallet/frozenRecord',
  288. type: 'page',
  289. layout: 'default',
  290. style: {
  291. navigationBarTitleText: '%wallet.frozenRecord.title%',
  292. navigationBarBackgroundColor: '#fff',
  293. },
  294. },
  295. {
  296. path: 'pages/wallet/myWallet',
  297. type: 'page',
  298. layout: 'default',
  299. needLogin: true,
  300. style: {
  301. navigationBarTitleText: '%wallet.myWallet.title%',
  302. navigationBarBackgroundColor: '#fff',
  303. },
  304. },
  305. {
  306. path: 'pages/wallet/recharge',
  307. type: 'page',
  308. layout: 'default',
  309. style: {
  310. 'navigationBarTitleText': '%wallet.recharge.title%',
  311. 'navigationBarBackgroundColor': '#fff',
  312. 'app-plus': {
  313. titleNView: {
  314. buttons: [
  315. {
  316. text: 'Record',
  317. fontSize: '28rpx',
  318. width: '85px',
  319. },
  320. ],
  321. },
  322. },
  323. },
  324. },
  325. {
  326. path: 'pages/wallet/rechargeRecord',
  327. type: 'page',
  328. layout: 'default',
  329. style: {
  330. navigationBarTitleText: '%wallet.rechargeRecord.title%',
  331. navigationBarBackgroundColor: '#fff',
  332. },
  333. },
  334. {
  335. path: 'pages/wallet/withdraw',
  336. type: 'page',
  337. layout: 'default',
  338. style: {
  339. navigationStyle: 'custom',
  340. navigationBarTitleText: '%wallet.withdraw.title%',
  341. },
  342. },
  343. {
  344. path: 'pages/wallet/withdrawRecord',
  345. type: 'page',
  346. layout: 'default',
  347. style: {
  348. navigationBarTitleText: '%wallet.withdrawRecord.title%',
  349. navigationBarBackgroundColor: '#fff',
  350. },
  351. },
  352. {
  353. path: 'pages/webLink/webLink',
  354. type: 'page',
  355. layout: 'default',
  356. style: {
  357. navigationBarTitleText: '',
  358. navigationBarBackgroundColor: '#fff',
  359. },
  360. },
  361. {
  362. path: 'uni_modules/uni-upgrade-center-app/pages/upgrade-popup',
  363. style: {
  364. 'disableScroll': true,
  365. 'app-plus': {
  366. backgroundColorTop: 'transparent',
  367. background: 'transparent',
  368. titleNView: false,
  369. scrollIndicator: false,
  370. popGesture: 'none',
  371. animationType: 'fade-in',
  372. animationDuration: 200,
  373. },
  374. },
  375. },
  376. ],
  377. })