diff --git a/src/components/global-toast/index.scss b/src/components/global-toast/index.scss index 23e50e4..a36ccd1 100644 --- a/src/components/global-toast/index.scss +++ b/src/components/global-toast/index.scss @@ -27,40 +27,51 @@ } .popup3 { - padding: 136rpx 44rpx 0; - width: 622rpx; - height: 632rpx; - box-sizing: border-box; - background: linear-gradient(180deg, #e7f8ff 0%, #ffffff 100%); - border-radius: 36rpx 36rpx 36rpx 36rpx; - .title { - font-size: 48rpx; - color: #222222; - font-weight: bold; - text-align: center; - } - .tip { - margin-top: 24rpx; - font-size: 36rpx; - color: #65686c; - line-height: 56rpx; - } - .btn1 { - margin-top: 44rpx; - font-size: 36rpx; - color: #ffffff; - height: 88rpx; - display: flex; - align-items: center; - justify-content: center; - background: #3795f7; - border-radius: 96rpx 96rpx 96rpx 96rpx; + .badge { + position: relative; + z-index: 1; + display: block; + margin: 0 auto; + width: 264rpx; + height: 264rpx; } - .btn2 { - margin-top: 16rpx; - padding: 16rpx 32rpx; - font-size: 32rpx; - color: #3795f7; - text-align: center; + .container { + margin-top: -130rpx; + padding: 136rpx 44rpx 0; + width: 622rpx; + height: 632rpx; + box-sizing: border-box; + background: linear-gradient(180deg, #e7f8ff 0%, #ffffff 100%); + border-radius: 36rpx 36rpx 36rpx 36rpx; + .title { + font-size: 48rpx; + color: #222222; + font-weight: bold; + text-align: center; + } + .tip { + margin-top: 24rpx; + font-size: 36rpx; + color: #65686c; + line-height: 56rpx; + } + .btn1 { + margin-top: 44rpx; + font-size: 36rpx; + color: #ffffff; + height: 88rpx; + display: flex; + align-items: center; + justify-content: center; + background: #3795f7; + border-radius: 96rpx 96rpx 96rpx 96rpx; + } + .btn2 { + margin-top: 16rpx; + padding: 16rpx 32rpx; + font-size: 32rpx; + color: #3795f7; + text-align: center; + } } } diff --git a/src/components/global-toast/index.wxml b/src/components/global-toast/index.wxml index 643dbd8..6e32296 100644 --- a/src/components/global-toast/index.wxml +++ b/src/components/global-toast/index.wxml @@ -1,48 +1,27 @@ - + 关注适中健康微信公众号 - + 长按识别二维码关注 - + 添加我的企业微信 - + 长按识别二维码添加 - - + - 该账号未开通阅读权益 - 此小程序暂时仅供经邀请的企业用户使用,请换个手机号登录以完成身份验证。 - 换个手机号登录 - 取消 + + + 该账号未开通阅读权益 + 此小程序暂时仅供经邀请的企业用户使用,请换个手机号登录以完成身份验证。 + 换个手机号登录 + 取消 + diff --git a/src/images/badge.png b/src/images/badge.png new file mode 100644 index 0000000..1a9d042 Binary files /dev/null and b/src/images/badge.png differ diff --git a/src/images/home-logo.png b/src/images/home-logo.png index 8127dbd..3b40316 100644 Binary files a/src/images/home-logo.png and b/src/images/home-logo.png differ diff --git a/src/pages/article/index.scss b/src/pages/article/index.scss index 7fab90e..c61819d 100644 --- a/src/pages/article/index.scss +++ b/src/pages/article/index.scss @@ -133,6 +133,7 @@ font-size: 32rpx; color: #999999; .icon { + margin-left: 10rpx; width: 24rpx; height: 24rpx; } diff --git a/src/pages/article/index.wxml b/src/pages/article/index.wxml index 5e30097..9f5f3d0 100644 --- a/src/pages/article/index.wxml +++ b/src/pages/article/index.wxml @@ -1,3 +1,4 @@ + {{chapter.ChapterName}} {{book.PublishDate}} @@ -86,9 +87,9 @@ 分类 {{chapter.CateName}} - + {{index+1}}.{{item.ChapterName}} - + diff --git a/src/pages/classify/index.scss b/src/pages/classify/index.scss index ab0684d..28ee06f 100644 --- a/src/pages/classify/index.scss +++ b/src/pages/classify/index.scss @@ -17,7 +17,7 @@ page { .nav-item { flex-shrink: 0; padding: 32rpx 16rpx; - font-size: 32rpx; + font-size: 36rpx; color: #222222; line-height: 36rpx; &.active { @@ -48,7 +48,7 @@ page { min-width: 160rpx; padding: 8rpx 10rpx; box-sizing: border-box; - font-size: 28rpx; + font-size: 32rpx; color: #65686c; line-height: 40rpx; background-color: #fff; @@ -88,7 +88,7 @@ page { flex-direction: column; justify-content: space-between; .title { - font-size: 32rpx; + font-size: 36rpx; color: #222222; font-weight: bold; line-height: 48rpx; @@ -96,7 +96,7 @@ page { .type { margin-top: 16rpx; flex: 1; - font-size: 28rpx; + font-size: 32rpx; color: #999999; line-height: 28rpx; } @@ -113,8 +113,8 @@ page { font-size: 28rpx; color: #999999; .icon { - width: 28rpx; - height: 28rpx; + width: 32rpx; + height: 32rpx; } &.active { color: #3795f7; diff --git a/src/pages/collection/index.scss b/src/pages/collection/index.scss index 11cb175..813bd7c 100644 --- a/src/pages/collection/index.scss +++ b/src/pages/collection/index.scss @@ -23,7 +23,7 @@ page { flex-direction: column; justify-content: space-between; .title { - font-size: 32rpx; + font-size: 36rpx; color: #222222; font-weight: bold; line-height: 48rpx; @@ -31,7 +31,7 @@ page { .type { flex: 1; margin-top: 16rpx; - font-size: 28rpx; + font-size: 32rpx; color: #999999; line-height: 28rpx; } @@ -48,8 +48,8 @@ page { font-size: 28rpx; color: #999999; .icon { - width: 28rpx; - height: 28rpx; + width: 32rpx; + height: 32rpx; } &.active { color: #3795f7; diff --git a/src/pages/collection/index.wxml b/src/pages/collection/index.wxml index 9be2f43..b2b75e3 100644 --- a/src/pages/collection/index.wxml +++ b/src/pages/collection/index.wxml @@ -9,7 +9,7 @@ - + {{item.BookName}} diff --git a/src/pages/home/index.json b/src/pages/home/index.json index a97367d..69181e7 100644 --- a/src/pages/home/index.json +++ b/src/pages/home/index.json @@ -1,3 +1,5 @@ { - "usingComponents": {} + "usingComponents": { + "van-popup": "@vant/weapp/popup/index" + } } diff --git a/src/pages/home/index.scss b/src/pages/home/index.scss index be467ef..f502740 100644 --- a/src/pages/home/index.scss +++ b/src/pages/home/index.scss @@ -6,8 +6,8 @@ page { min-height: 100vh; .logo { margin-left: 32rpx; - width: 216rpx; - height: 70rpx; + width: 327rpx; + max-height: 100rpx; } .page-title { margin: 50rpx 0 0 32rpx; @@ -156,11 +156,11 @@ page { margin: 28rpx auto 0; width: 236rpx; height: 70rpx; - font-size: 28rpx; + font-size: 32rpx; color: #fff; text-align: center; line-height: 70rpx; - background: linear-gradient(90deg, #134df6 36%, #3795f7 100%); + background: linear-gradient( 90deg, #2674F6 0%, #3795F7 100%); border-radius: 112rpx 112rpx 112rpx 112rpx; } .not-submit { @@ -168,3 +168,51 @@ page { } } } + +.popup { + padding: 33rpx 0 0; + + .popup-container { + padding: 280rpx 48rpx 0; + width: 622rpx; + height: 490rpx; + box-sizing: border-box; + background: linear-gradient(180deg, #e7f8ff 0%, #ffffff 100%); + border-radius: 32rpx; + position: relative; + + .badge { + position: absolute; + left: 0; + top: -33px; + width: 246rpx; + height: 286rpx; + } + + .title { + position: absolute; + top: 50rpx; + right: 28rpx; + width: 338rpx; + height: 164rpx; + } + + .conform { + height: 88rpx; + text-align: center; + background: #3795f7; + line-height: 88rpx; + font-size: 36rpx; + color: #ffffff; + border-radius: 96rpx 96rpx 96rpx 96rpx; + } + + .cancel { + margin-top: 10rpx; + font-size: 32rpx; + color: #999999; + text-align: center; + line-height: 88rpx; + } + } +} diff --git a/src/pages/home/index.ts b/src/pages/home/index.ts index 1d92814..ac115cd 100644 --- a/src/pages/home/index.ts +++ b/src/pages/home/index.ts @@ -2,6 +2,8 @@ const app = getApp(); Page({ data: { + show: false, + cateList: [] as any, remark: '', @@ -103,6 +105,17 @@ Page({ title: '今日留言次数已达上限,欢迎明天再来留言吧', }); }, + handleTopic() { + wx.navigateTo({ + url: '/pages/topic/index?back=1', + }); + this.handleCancelTopic(); + }, + handleCancelTopic() { + this.setData({ + show: false, + }); + }, }); export {}; diff --git a/src/pages/home/index.wxml b/src/pages/home/index.wxml index 4bfdcec..a6dba53 100644 --- a/src/pages/home/index.wxml +++ b/src/pages/home/index.wxml @@ -2,7 +2,7 @@ class="page" style="background: url('{{imageUrl}}home-bg.png?t={{Timestamp}}') no-repeat top center/100% 580rpx;padding-top:{{menuButtonInfo.top}}px;" > - + 人人都是家庭健康师,让生活更有质量 @@ -53,3 +53,14 @@ 提交 + + + + + + + 开始 + 关闭 + + + diff --git a/src/pages/login/index.scss b/src/pages/login/index.scss index e0813cc..945f2e8 100644 --- a/src/pages/login/index.scss +++ b/src/pages/login/index.scss @@ -116,46 +116,38 @@ padding: 33rpx 0 0; .popup-container { - padding: 280rpx 48rpx 0; + padding: 64rpx 44rpx 10rpx; width: 622rpx; - height: 490rpx; box-sizing: border-box; background: linear-gradient(180deg, #e7f8ff 0%, #ffffff 100%); border-radius: 32rpx; position: relative; - .badge { - position: absolute; - left: 0; - top: -33px; - width: 246rpx; - height: 286rpx; - } - - .title { - position: absolute; - top: 50rpx; - right: 28rpx; - width: 338rpx; - height: 164rpx; + .content { + font-size: 36rpx; + color: #65686c; + text-align: center; + .link { + color: #3795f7; + } } .conform { + margin-top: 48rpx; height: 88rpx; text-align: center; background: #3795f7; - line-height: 88rpx; + line-height: 86rpx; font-size: 36rpx; - color: #FFFFFF; + color: #ffffff; border-radius: 96rpx 96rpx 96rpx 96rpx; } - .cancel{ - margin-top: 10rpx; + .cancel { + padding: 32rpx 0; font-size: 32rpx; - color: #999999; + color: #3795F7; text-align: center; - line-height: 88rpx; } } } diff --git a/src/pages/login/index.ts b/src/pages/login/index.ts index 87c2742..270e915 100644 --- a/src/pages/login/index.ts +++ b/src/pages/login/index.ts @@ -3,8 +3,6 @@ let timer: number | null = 0; Page({ data: { - show: false, - menuButtonInfo: {}, mobile: '', code: '', @@ -12,6 +10,9 @@ Page({ codeText: '发送验证码', back: false, + + type: '', + show: false, }, onLoad(options) { this.setData({ @@ -64,13 +65,17 @@ Page({ }); }, handleSubmit() { - const { mobile, code, protool } = this.data; - if (!protool) { - wx.showToast({ - icon: 'none', - title: '请先同意用户隐私协议', + const { show, mobile, code, protool } = this.data; + if (!protool && !show) { + this.setData({ + type: 'login', + show: true, }); return; + } else { + this.setData({ + show: false, + }); } if (!mobile) { wx.showToast({ @@ -98,13 +103,17 @@ Page({ }); }, handleWxSubmit(e: any) { - const { protool } = this.data; - if (!protool) { - wx.showToast({ - icon: 'none', - title: '请先同意用户隐私协议', + const { show, protool } = this.data; + if (!protool && !show) { + this.setData({ + type: 'phone', + show: true, }); return; + } else { + this.setData({ + show: false, + }); } const { iv, encryptedData } = e.detail; if (iv && encryptedData) { @@ -122,16 +131,7 @@ Page({ }, submitCallback() { app.globalData.isLogin = 1; - app.getUserInfo(null, (res) => { - app.globalData.isAnswer = res.isAnswer; - if (res.isAnswer === '0') { - this.setData({ - show: true, - }); - } else { - wx.reLaunch({ url: '/pages/home/index' }); - } - }); + wx.reLaunch({ url: '/pages/home/index' }); }, handleProtool() { this.setData({ @@ -141,23 +141,17 @@ Page({ handleNavProtool() { wx.navigateTo({ url: `/pages/protocol/index` }); }, - handleTopic() { - wx.reLaunch({ - url: '/pages/topic/index', - }); - }, - handleCancelTopic() { - app.globalData.isAnswer = '1'; - wx.reLaunch({ - url: '/pages/home/index', - }); - }, handleVisitor() { app.globalData.isLogin = 999; wx.reLaunch({ url: '/pages/home/index', }); }, + handleCancel() { + this.setData({ + show: false, + }); + }, handleBack() { wx.navigateBack(); }, diff --git a/src/pages/login/index.wxml b/src/pages/login/index.wxml index ae7162b..413178e 100644 --- a/src/pages/login/index.wxml +++ b/src/pages/login/index.wxml @@ -1,4 +1,11 @@ - + - - - 开始 - 跳过 +
+ 已阅读并同意 + 《用户隐私协议》 +
+ + + 取消
diff --git a/src/pages/my/index.scss b/src/pages/my/index.scss index f2b7df5..1607fc4 100644 --- a/src/pages/my/index.scss +++ b/src/pages/my/index.scss @@ -16,6 +16,7 @@ page { } } .user { + padding-top: 10rpx; flex: 1; .name { font-size: 40rpx; @@ -42,6 +43,8 @@ page { } } .switch { + display: flex; + align-items: center; font-size: 28rpx; color: #999999; } diff --git a/src/pages/search/index.scss b/src/pages/search/index.scss index 9fc5c04..14b671b 100644 --- a/src/pages/search/index.scss +++ b/src/pages/search/index.scss @@ -51,7 +51,7 @@ page { flex-direction: column; justify-content: space-between; .title { - font-size: 32rpx; + font-size: 36rpx; color: #222222; font-weight: bold; line-height: 48rpx; @@ -59,7 +59,7 @@ page { .book-name { flex: 1; padding-top: 20rpx; - font-size: 28rpx; + font-size: 32rpx; color: #999999; } .c-footer { @@ -68,7 +68,7 @@ page { justify-content: space-between; gap: 20rpx; .type { - font-size: 28rpx; + font-size: 32rpx; color: #999999; line-height: 28rpx; } @@ -81,8 +81,8 @@ page { font-size: 28rpx; color: #999999; .icon { - width: 28rpx; - height: 28rpx; + width: 32rpx; + height: 32rpx; } } } diff --git a/src/pages/topic/index.ts b/src/pages/topic/index.ts index 65d1b83..04d3f8c 100644 --- a/src/pages/topic/index.ts +++ b/src/pages/topic/index.ts @@ -75,6 +75,9 @@ Page({ nav: this.data.nav, }); }, + catchTouchMove() { + return false; + }, handleBack() { wx.showModal({ title: '确认退出?', diff --git a/src/pages/topic/index.wxml b/src/pages/topic/index.wxml index 7357140..d013155 100644 --- a/src/pages/topic/index.wxml +++ b/src/pages/topic/index.wxml @@ -11,7 +11,7 @@ bindtransition="bindtransition" style="margin-top:{{menuButtonInfo.bottom+73}}px;" > - +