1
0
mirror of https://github.com/ialley-workshop-open/uni-halo.git synced 2026-06-12 21:29:31 +08:00

feat: 优化返回顶部按钮大小

This commit is contained in:
小莫唐尼
2025-07-19 23:59:56 +08:00
parent 4611932ad8
commit c17e668afe
4 changed files with 23 additions and 7 deletions
+19 -3
View File
@@ -43,12 +43,18 @@
</tm-translate> </tm-translate>
</block> </block>
<tm-flotbutton @click="fnToTopPage" color="light-blue" size="m" icon="icon-angle-up"></tm-flotbutton>
<view class="load-text">{{ loadMoreText }}</view> <view class="load-text">{{ loadMoreText }}</view>
</block> </block>
</k-touch-listen> </k-touch-listen>
</view> </view>
</view>
<view v-if="!calcAuditModeEnabled" class="flot-buttons">
<tm-button v-if="loading == 'error'" @click="fnGetCategory" size="m" :fab="true" theme="light-blue"
icon="icon-sync-alt"></tm-button>
<tm-button @click="fnToTopPage" size="m" :fab="true" theme="light-blue"
icon="icon-angle-up"></tm-button>
</view>
</view>
</template> </template>
<script> <script>
@@ -238,7 +244,7 @@ export default {
.getPhotoListByGroupName(this.queryParams) .getPhotoListByGroupName(this.queryParams)
.then(res => { .then(res => {
this.hasNext = res.hasNext; this.hasNext = res.hasNext;
this.loading = 'success'; this.loading = 'error';
if (res.items.length !== 0) { if (res.items.length !== 0) {
const _list = res.items.map((item, index) => { const _list = res.items.map((item, index) => {
item.spec.url = this.$utils.checkImageUrl(item.spec.url || item.spec.cover); item.spec.url = this.$utils.checkImageUrl(item.spec.url || item.spec.cover);
@@ -342,4 +348,14 @@ export default {
width: 100%; width: 100%;
text-align: center; text-align: center;
} }
.flot-buttons {
position: fixed;
bottom: 100rpx;
right: 32rpx;
flex-direction: column;
display: flex;
gap: 6rpx;
z-index: 999;
}
</style> </style>
+1 -1
View File
@@ -84,7 +84,7 @@
</tm-translate> </tm-translate>
</view> </view>
<view class="load-text mt-12">{{ loadMoreText }}</view> <view class="load-text mt-12">{{ loadMoreText }}</view>
<tm-flotbutton v-if="articleList.length > 10" color="light-blue" @click="fnToTopPage" size="m" <tm-flotbutton v-if="articleList.length > 10" :width="90" color="light-blue" @click="fnToTopPage" size="s"
icon="icon-angle-up"></tm-flotbutton> icon="icon-angle-up"></tm-flotbutton>
</block> </block>
</block> </block>
+1 -1
View File
@@ -76,7 +76,7 @@
</view> </view>
</tm-translate> </tm-translate>
</block> </block>
<tm-flotbutton @click="fnToTopPage" size="m" color="light-blue" icon="icon-angle-up"></tm-flotbutton> <tm-flotbutton @click="fnToTopPage" :width="90" size="xs" color="light-blue" :icon-size="24" icon="icon-angle-up"></tm-flotbutton>
<view class="load-text">{{ loadMoreText }}</view> <view class="load-text">{{ loadMoreText }}</view>
</block> </block>
</view> </view>
+2 -2
View File
@@ -152,9 +152,9 @@
<!-- 弹幕效果 --> <!-- 弹幕效果 -->
<barrage ref="barrage" :maxTop="240" :type="globalAppSettings.barrage.type"></barrage> <barrage ref="barrage" :maxTop="240" :type="globalAppSettings.barrage.type"></barrage>
<!-- 返回顶部 --> <!-- 返回顶部 -->
<tm-flotbutton :offset="[16, 80]" icon="icon-angle-up" color="bg-gradient-light-blue-accent" <tm-flotbutton :width="90" :offset="[16, 80]" icon="icon-angle-up" color="bg-gradient-light-blue-accent"
@click="fnToTopPage()"></tm-flotbutton> @click="fnToTopPage()"></tm-flotbutton>
<tm-flotbutton :actions="flotButtonActions" :click-actions-hiden="false" actions-pos="left" <tm-flotbutton :width="90" :actions="flotButtonActions" :click-actions-hiden="false" actions-pos="left"
:show-text="true" color="bg-gradient-orange-accent" @change="fnOnFlotButtonChange"></tm-flotbutton> :show-text="true" color="bg-gradient-orange-accent" @change="fnOnFlotButtonChange"></tm-flotbutton>
</block> </block>