调整
This commit is contained in:
parent
cacbf6a010
commit
8bd0fec9d0
@ -24,7 +24,7 @@ function isCurrent(index) {
|
|||||||
<view class="w-1/4 h-full bg-gray-100">
|
<view class="w-1/4 h-full bg-gray-100">
|
||||||
<scroll-view class="h-full bg-gray-100">
|
<scroll-view class="h-full bg-gray-100">
|
||||||
<view v-for="(category, index) in props.categories" :key="index"
|
<view v-for="(category, index) in props.categories" :key="index"
|
||||||
@click="switchCategory(index)"
|
@tap="switchCategory(index)"
|
||||||
:class="{'bg-white': isCurrent(index), 'bg-gray-100': !isCurrent(index), 'rounded': !isCurrent(index)}"
|
:class="{'bg-white': isCurrent(index), 'bg-gray-100': !isCurrent(index), 'rounded': !isCurrent(index)}"
|
||||||
class="text-center p-4">
|
class="text-center p-4">
|
||||||
<text>{{ category.name }}</text>
|
<text>{{ category.name }}</text>
|
||||||
|
@ -56,7 +56,7 @@ onLoad((q) => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
onReady(()=>{
|
onReady(()=>{
|
||||||
tabRef.value.changeCurrent(query?.index || 0)
|
tabRef.value?.changeCurrent(query?.index || 0)
|
||||||
})
|
})
|
||||||
|
|
||||||
const ctx = reactive({
|
const ctx = reactive({
|
||||||
|
@ -13,8 +13,8 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="warp">
|
<view class="warp">
|
||||||
<button type="warn" @click="toTestPage">{{ t("my.toTestPage") }}</button>
|
<button type="warn" @tap="toTestPage">{{ t("my.toTestPage") }}</button>
|
||||||
<button class="button" type="primary" @click="getLocation">{{ t('my.getLocation') }}</button>
|
<button class="button" type="primary" @tap="getLocation">{{ t('my.getLocation') }}</button>
|
||||||
|
|
||||||
<navigator url="/sub-packages/test-page/pages/test-crypto">
|
<navigator url="/sub-packages/test-page/pages/test-crypto">
|
||||||
<button>{{ t('my.cryptoTestPage') }}</button>
|
<button>{{ t('my.cryptoTestPage') }}</button>
|
||||||
@ -24,7 +24,7 @@
|
|||||||
<button>{{ t('my.openCameraTestPage') }}</button>
|
<button>{{ t('my.openCameraTestPage') }}</button>
|
||||||
</navigator>
|
</navigator>
|
||||||
|
|
||||||
<button class="button" @click="switchLanguage">{{t('language.switch')}} {{t(ctx.lang.switchTo)}}</button>
|
<button class="button" @tap="switchLanguage">{{t('language.switch')}} {{t(ctx.lang.switchTo)}}</button>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user