feat: maidian

This commit is contained in:
zzc
2026-02-12 17:22:47 +08:00
parent 54e8581b81
commit 313435d13f
13 changed files with 142 additions and 32 deletions

View File

@@ -20,7 +20,7 @@
/>
</view>
<view class="status-info">
<view class="status-title">当前正在使用</view>
<view class="status-title">头像效果预览</view>
<view class="decor-name">
<text class="star-icon"></text>
<text>{{ currentAvatar.decorName || "金马贺岁挂饰" }}</text>
@@ -93,6 +93,7 @@ import { onPullDownRefresh, onReachBottom } from "@dcloudio/uni-app";
import { getMyAvatar, userAvatarChange } from "@/api/mine.js";
import { useUserStore } from "@/stores/user";
import NavBar from "@/components/NavBar/NavBar.vue";
import { trackRecord } from "@/utils/common.js";
const userStore = useUserStore();
const list = ref([]);
@@ -115,6 +116,10 @@ const names = [
onMounted(() => {
fetchList(true);
trackRecord({
eventName: "avatar_record_page_visit",
eventType: `visit`,
});
});
onPullDownRefresh(() => {
@@ -174,6 +179,7 @@ const changeUserAvatar = async (imageUrl) => {
title: "头像更换成功",
icon: "success",
});
// userStore.fetchUserInfo();
}
};

View File

@@ -102,7 +102,7 @@ import {
} from "@dcloudio/uni-app";
import { getMyCard } from "@/api/mine.js";
import NavBar from "@/components/NavBar/NavBar.vue";
import { getShareToken } from "@/utils/common.js";
import { getShareToken, trackRecord } from "@/utils/common.js";
const list = ref([]);
const page = ref(1);
@@ -112,6 +112,10 @@ const totalCount = ref(0);
onMounted(() => {
fetchList(true);
trackRecord({
eventName: "greeting_page_visit",
eventType: `visit`,
});
});
onPullDownRefresh(() => {

View File

@@ -1,5 +1,5 @@
<template>
<view class="help-page" >
<view class="help-page">
<NavBar title="帮助中心" />
<!-- Search Bar -->
@@ -133,6 +133,14 @@
<script setup>
import { ref } from "vue";
import NavBar from "@/components/NavBar/NavBar.vue";
import { trackRecord } from "@/utils/common.js";
onMounted(() => {
trackRecord({
eventName: "help_page_visit",
eventType: `visit`,
});
});
const faqList = ref([
{
@@ -157,7 +165,7 @@ const faqList = ref([
items: [
{
q: "如何更换新的头像",
a: "在头像定制页面,首先选择地图是微信头像或系统头像,左边选择您喜欢的边框样式,右边选择头像挂饰,可移动位置,缩放大小,点击保存即可。",
a: "在头像定制页面,首先选择上传头像或系统头像,左边选择您喜欢的边框样式,右边选择头像挂饰,可移动位置,缩放大小,点击保存即可。",
},
],
},

View File

@@ -137,7 +137,7 @@
import { ref, computed, onMounted } from "vue";
import { useUserStore } from "@/stores/user";
import { onShareAppMessage } from "@dcloudio/uni-app";
import { getShareToken } from "@/utils/common";
import { getShareToken, trackRecord } from "@/utils/common";
import LoginPopup from "@/components/LoginPopup/LoginPopup.vue";
const userStore = useUserStore();
@@ -166,6 +166,10 @@ onMounted(() => {
navBarTop.value = sysInfo.statusBarHeight;
// Assuming standard nav bar height
navBarHeight.value = 44;
trackRecord({
eventName: "mine_page_visit",
eventType: `visit`,
});
});
onShareAppMessage(async () => {

View File

@@ -1,5 +1,5 @@
<template>
<view class="wallpaper-page" >
<view class="wallpaper-page">
<NavBar title="我的壁纸" />
<!-- Header Stats -->
@@ -24,7 +24,12 @@
<!-- List Section -->
<view class="list-section">
<view class="list-container">
<view v-for="item in list" :key="item.id" class="grid-item" @tap="onPreview(item)">
<view
v-for="item in list"
:key="item.id"
class="grid-item"
@tap="onPreview(item)"
>
<image :src="item.imageUrl" mode="aspectFill" class="wallpaper-img" />
<view class="date-badge">
<text>{{ formatDate(item.createdAt) }}</text>
@@ -51,6 +56,7 @@ import { ref, onMounted } from "vue";
import { onPullDownRefresh, onReachBottom } from "@dcloudio/uni-app";
import { getMyWallpaper } from "@/api/mine.js";
import NavBar from "@/components/NavBar/NavBar.vue";
import { trackRecord } from "@/utils/common.js";
const list = ref([]);
const page = ref(1);
@@ -61,6 +67,10 @@ const totalCount = ref(0);
onMounted(() => {
fetchList(true);
trackRecord({
eventName: "wallpaper_record_page_visit",
eventType: `visit`,
});
});
onPullDownRefresh(() => {
@@ -125,7 +135,7 @@ const formatDate = (dateStr) => {
const onPreview = (item) => {
uni.previewImage({
urls: [item.imageUrl],
current: item.imageUrl
current: item.imageUrl,
});
};
</script>
@@ -166,7 +176,7 @@ const onPreview = (item) => {
.value-wrap {
display: flex;
align-items: baseline;
.prefix {
font-size: 16px;
color: #333;
@@ -198,7 +208,7 @@ const onPreview = (item) => {
display: flex;
align-items: center;
justify-content: center;
text {
font-size: 24px;
}
@@ -217,7 +227,7 @@ const onPreview = (item) => {
gap: 12px;
padding-bottom: 40px;
}
.grid-item {
position: relative;
border-radius: 16px;
@@ -225,13 +235,13 @@ const onPreview = (item) => {
background: #fff;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
aspect-ratio: 9/16; // Standard wallpaper ratio
.wallpaper-img {
width: 100%;
height: 100%;
display: block;
}
.date-badge {
position: absolute;
bottom: 8px;
@@ -240,7 +250,7 @@ const onPreview = (item) => {
padding: 2px 6px;
border-radius: 4px;
backdrop-filter: blur(4px);
text {
color: #fff;
font-size: 10px;
@@ -258,4 +268,4 @@ const onPreview = (item) => {
color: #999;
font-size: 12px;
}
</style>
</style>