feat: 添加引导内容,第一步引导

This commit is contained in:
2025-06-17 17:31:33 +08:00
parent 02df74f35f
commit c0c55fb4f1
15 changed files with 373 additions and 8 deletions
+25
View File
@@ -13,6 +13,26 @@ Page({
showColorPopup: false,
currentKey: 0,
currentColor: '',
showIntroductionPopup: false,
},
onLoad() {
const hasShowIntroduction =
wx.getStorageSync('hasShowIntroduction') || false;
if (!hasShowIntroduction) {
this.setData({
cardList: [
{ color: '#FF0000', word: '涂' },
{ color: '#00FF00', word: '欢' },
{ color: '#FF7F00', word: '鸦' },
{ color: '#00FFFF', word: '迎' },
{ color: '#FFFF00', word: '丫' },
{ color: '#8A2BE2', word: '你' },
],
showIntroductionPopup: true,
});
}
},
onReady() {
@@ -151,4 +171,9 @@ Page({
cardList,
});
},
onCloseIntroductionPopup() {
this.setData({ showIntroductionPopup: false });
wx.setStorageSync('hasShowIntroduction', true);
},
});