Ver Fonte

fix(a): ...

EvilDragon há 7 meses atrás
pai
commit
c5525309c9

+ 3 - 3
pages.config.ts

@@ -33,9 +33,9 @@ export default defineUniPages({
       {
         pagePath: 'pages/material/index',
       },
-      {
-        pagePath: 'pages/publish/index',
-      },
+      // {
+      //   pagePath: 'pages/publish/index',
+      // },
       {
         pagePath: 'pages/messages/index',
       },

Diff do ficheiro suprimidas por serem muito extensas
+ 569 - 10
pnpm-lock.yaml


+ 2 - 0
src/components/data-form.vue

@@ -39,9 +39,11 @@ const defaultProps = {
         >
           {{ label || prop }}
         </label>
+        <!-- #ifdef H5 -->
         <component :is="types[type]" :name="prop" v-bind="defaultProps[type]">
           <span v-if="type === 'Submit'">提交</span>
         </component>
+        <!-- #endif -->
       </div>
     </template>
   </div>

+ 4 - 4
src/components/section-heading.vue

@@ -27,18 +27,18 @@ const handleMore = async () => {
 <template>
   <view class="flex justify-between items-center" :class="[customClass]">
     <div
-      class="font-normal font-['PingFang SC']"
+      class="font-normal"
       :class="[`text-${size}`, { base: 'text-black/90', xl: 'text-black' }[size]]"
     >
       {{ title }}
     </div>
-    <div
+    <!-- <div
       v-if="path"
-      class="text-right text-black/30 text-sm font-normal font-['PingFang SC'] leading-tight"
+      class="text-right text-black/30 text-sm font-normal leading-tight"
       @click="handleMore"
     >
       查看全部
       <wd-img :src="right" width="10" height="10"></wd-img>
-    </div>
+    </div> -->
   </view>
 </template>

+ 1 - 1
src/components/tabbar-evo.vue

@@ -78,7 +78,7 @@ onMounted(async () => {
               :src="currentPath === path ? selectedIconPath : iconPath"
             ></wd-img>
             <span
-              class="mt-1 text-center text-[10px] font-normal font-['PingFang SC'] leading-none"
+              class="mt-1 text-center text-[10px] font-normal leading-none"
               :class="[currentPath === path ? 'text-black' : 'text-[#8c8c8c]']"
               v-if="!hiddenTitle"
             >

+ 1 - 1
src/types/uni-pages.d.ts

@@ -30,7 +30,7 @@ interface NavigateToOptions {
 interface RedirectToOptions extends NavigateToOptions {}
 
 interface SwitchTabOptions {
-  url: "/pages/home/index" | "/pages/material/index" | "/pages/publish/index" | "/pages/messages/index" | "/pages/mine/index"
+  url: "/pages/home/index" | "/pages/material/index" | "/pages/messages/index" | "/pages/mine/index"
 }
 
 type ReLaunchOptions = NavigateToOptions | SwitchTabOptions;

+ 9 - 1
src/utils/index.ts

@@ -1,4 +1,5 @@
 import { pages, subPackages, tabBar } from '@/pages.json'
+import { path } from 'node:path'
 const getLastPage = () => {
   // getCurrentPages() 至少有1个元素,所以不再额外判断
   // const lastPage = getCurrentPages().at(-1)
@@ -34,11 +35,18 @@ export const currRoute = () => {
   // console.log('lastPage.$page.options:', currRoute.options)
   // console.log('lastPage.options:', (lastPage as any).options)
   // 经过多端测试,只有 fullPath 靠谱,其他都不靠谱
+  let path = ''
+  // #ifndef MP-WEIXIN
   const { fullPath } = currRoute as { fullPath: string }
+  path = fullPath
+  // #endif
+  // #ifdef MP-WEIXIN
+  path = lastPage.route
+  // #endif
   // console.log(fullPath)
   // eg: /pages/login/index?redirect=%2Fpages%2Fdemo%2Fbase%2Froute-interceptor (小程序)
   // eg: /pages/login/index?redirect=%2Fpages%2Froute-interceptor%2Findex%3Fname%3Dfeige%26age%3D30(h5)
-  return getUrlObj(fullPath)
+  return getUrlObj(path)
 }
 
 const ensureDecodeURIComponent = (url: string) => {

Alguns ficheiros não foram mostrados porque muitos ficheiros mudaram neste diff