xyvcard-wechat-auth 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/common/{choose-avatar → auth-avatar/avatar-edit}/index.js +2 -2
- package/dist/components/common/{choose-avatar → auth-avatar/avatar-edit}/index.wxml +1 -1
- package/dist/components/common/auth-avatar/avatar-edit/index.wxss +1 -0
- package/dist/components/common/{btn/footer-double-btn → auth-btn/double-btn}/index.wxml +1 -1
- package/dist/components/common/auth-btn/double-btn/index.wxss +1 -0
- package/dist/components/common/{btn/footer-btn → auth-btn/single-btn}/index.wxml +1 -1
- package/dist/components/common/auth-btn/single-btn/index.wxss +1 -0
- package/dist/components/common/{none-data → auth-none-data/none-data-image}/index.js +1 -1
- package/dist/components/common/{none-data → auth-none-data/none-data-image}/index.wxml +1 -1
- package/dist/components/common/auth-none-data/none-data-image/index.wxss +1 -0
- package/dist/components/common/{popup → auth-popup}/index.wxml +2 -2
- package/dist/components/common/auth-popup/index.wxss +1 -0
- package/dist/components/common/{search → auth-search}/index.wxml +1 -1
- package/dist/components/common/auth-search/index.wxss +1 -0
- package/dist/components/common/{top-navigation → auth-top-navigation}/index.wxml +1 -1
- package/dist/components/common/auth-top-navigation/index.wxss +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -1
- package/dist/utils/auth.js +13 -0
- package/dist/utils/config.d.ts +2 -0
- package/dist/utils/config.js +2 -0
- package/package.json +1 -1
- package/dist/components/common/btn/footer-btn/index.wxss +0 -1
- package/dist/components/common/btn/footer-double-btn/index.wxss +0 -1
- package/dist/components/common/choose-avatar/index.wxss +0 -1
- package/dist/components/common/none-data/index.wxss +0 -1
- package/dist/components/common/popup/index.wxss +0 -1
- package/dist/components/common/search/index.wxss +0 -1
- package/dist/components/common/top-navigation/index.wxss +0 -1
- /package/dist/components/common/{choose-avatar → auth-avatar/avatar-edit}/index.d.ts +0 -0
- /package/dist/components/common/{btn/footer-btn → auth-avatar/avatar-edit}/index.json +0 -0
- /package/dist/components/common/{btn/footer-btn → auth-btn/double-btn}/index.d.ts +0 -0
- /package/dist/components/common/{btn/footer-double-btn → auth-btn/double-btn}/index.js +0 -0
- /package/dist/components/common/{btn/footer-double-btn → auth-btn/double-btn}/index.json +0 -0
- /package/dist/components/common/{btn/footer-double-btn → auth-btn/single-btn}/index.d.ts +0 -0
- /package/dist/components/common/{btn/footer-btn → auth-btn/single-btn}/index.js +0 -0
- /package/dist/components/common/{choose-avatar → auth-btn/single-btn}/index.json +0 -0
- /package/dist/components/common/{none-data → auth-none-data/none-data-image}/index.d.ts +0 -0
- /package/dist/components/common/{none-data → auth-none-data/none-data-image}/index.json +0 -0
- /package/dist/components/common/{popup → auth-popup}/index.d.ts +0 -0
- /package/dist/components/common/{popup → auth-popup}/index.js +0 -0
- /package/dist/components/common/{popup → auth-popup}/index.json +0 -0
- /package/dist/components/common/{search → auth-search}/index.d.ts +0 -0
- /package/dist/components/common/{search → auth-search}/index.js +0 -0
- /package/dist/components/common/{search → auth-search}/index.json +0 -0
- /package/dist/components/common/{top-navigation → auth-top-navigation}/index.d.ts +0 -0
- /package/dist/components/common/{top-navigation → auth-top-navigation}/index.js +0 -0
- /package/dist/components/common/{top-navigation → auth-top-navigation}/index.json +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<!-- 创建卡片选择头像 样式组件 -->
|
|
2
2
|
<!-- 头像背景盒子 -->
|
|
3
|
-
<button plain class="image-box-bgc" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
|
|
3
|
+
<button plain class="auth-image-box-bgc" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
|
|
4
4
|
<!-- 显示的头像 -->
|
|
5
5
|
<image class="image-box-show" src="{{ avatar }}" mode="widthFix" />
|
|
6
6
|
<!-- 提示选择头像图片 -->
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-image-box-bgc{position:relative;display:flex;align-items:center;justify-content:center;width:80px !important;height:80px;border:none;border-radius:10px;padding:0}.auth-image-box-bgc .image-box-show{width:80px;height:80px}.auth-image-box-bgc .select-image{position:absolute;width:24px;height:24px;bottom:0;right:0}.image-box-bgc[plain]{border:1px solid #e0e0e0}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<view class="btn-box">
|
|
1
|
+
<view class="auth-btn-box">
|
|
2
2
|
<button class="btn-left" style="background-color: {{ leftBgColor }}; color: {{ leftColor }}; border-radius: {{ btnRadius }}; border: {{ leftBorder }};" bind:tap="handleLeft">{{ leftText }}</button>
|
|
3
3
|
<button class="btn-right" style="background-color: {{ rightBgColor }}; color: {{ rightColor }}; border-radius: {{ btnRadius }}; border: {{ rightBorder }};" bind:tap="handleRight">{{ rightText }}</button>
|
|
4
4
|
</view>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-btn-box{display:flex;align-items:center;justify-content:space-between;width:100%}.auth-btn-box .btn-left{width:33%;margin-right:3%;height:48px;font-size:16px;line-height:48px}.auth-btn-box .btn-right{height:48px;font-size:16px;width:64%;line-height:48px}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-btn{font-size:16px;width:100% !important}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<view class="none-data" style="margin-top: {{ marginTop }}rpx; padding-top: {{ paddingTop }}rpx;">
|
|
1
|
+
<view class="auth-none-data" style="margin-top: {{ marginTop }}rpx; padding-top: {{ paddingTop }}rpx;">
|
|
2
2
|
<image class="holder-image" src="{{ resourceUrl + imgUrl }}" mode="heightFix" style="width: {{ imgWidth }};height: {{ imgHeight }};" />
|
|
3
3
|
<view class="holder-text" style="color: {{ contentColor }};">{{ content }}</view>
|
|
4
4
|
</view>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-none-data{display:flex;align-items:center;justify-content:center;flex-direction:column}.auth-none-data .holder-text{font-size:14px}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
<view class="mask-box" wx:if="{{ show }}"></view>
|
|
2
|
-
<view class="mask-popup" wx:if="{{ show }}" style="height: {{ height }}; background-color: {{ backColor }};">
|
|
1
|
+
<view class="auth-mask-box" wx:if="{{ show }}"></view>
|
|
2
|
+
<view class="auth-mask-popup" wx:if="{{ show }}" style="height: {{ height }}; background-color: {{ backColor }};">
|
|
3
3
|
<view class="popup-title" titleShow="{{ titleShow }}">
|
|
4
4
|
{{ title }}
|
|
5
5
|
<image mode="widthFix" src="{{ resourceUrl + '/icon_image/close_circle2x.png' }}" class="close-icon" bind:tap="closePopup"></image>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-mask-box{position:fixed;left:0;top:0;bottom:0;right:0;width:100%;background-color:rgba(0,0,0,.5);z-index:99999}.auth-mask-popup{position:fixed;bottom:0;left:0;border-top-left-radius:25px;border-top-right-radius:25px;padding:10px 4% 30px 4%;width:92%;z-index:99999}.auth-mask-popup .popup-title{color:#333;font-size:14px;padding:10px 0;font-weight:bold;display:flex;align-items:center;justify-content:space-between}.auth-mask-popup .popup-title .close-icon{width:20px}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<view class="search-box" style="box-shadow: {{ isBoxShadow ? '0px 3px 3px 0px rgba(40, 65, 91, 0.1);' : '0px' }}">
|
|
1
|
+
<view class="auth-search-box" style="box-shadow: {{ isBoxShadow ? '0px 3px 3px 0px rgba(40, 65, 91, 0.1);' : '0px' }}">
|
|
2
2
|
<image src="{{ resourceUrl + '/icon_image/icon_search.png' }}" class="search-icon"></image>
|
|
3
3
|
<input class="search-input" style="background-color: {{ backColor }}; width: {{ isSearchBtn ? '60%' : '100%' }}; {{ isSearchBtn ? '' : 'padding-right: 20px' }}" placeholder="{{ placeholder }}" disabled="{{ disabled }}" value="{{ likeName }}" bindinput="handleInput" bind:tap="handleTap" />
|
|
4
4
|
<view class="search-btn" wx:if="{{ isSearchBtn }}">
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-search-box{position:relative;width:100%;border-radius:25px;background-color:#fff;display:flex;justify-content:space-between;align-items:center;height:35px;box-sizing:border-box;overflow:hidden}.auth-search-box .search-input{height:35px;color:#6b7280;font-size:14px;padding-left:40px}.auth-search-box .search-icon{width:20px;height:20px;position:absolute;left:10px;transform:translate(0, -50%);top:50%}.auth-search-box .search-btn{padding-right:3%}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<view style="background-color: {{ style.color }};">
|
|
2
|
-
<view class="top-navigation" style="padding-top: {{ style.paddingTop }}px; height: {{ style.height }}px;">
|
|
2
|
+
<view class="auth-top-navigation" style="padding-top: {{ style.paddingTop }}px; height: {{ style.height }}px;">
|
|
3
3
|
<image src="{{ resourceUrl + '/member/arrow-left.png' }}" class="back-icon" wx:if="{{ isLeftIcon }}" bind:tap="handleBack"></image>
|
|
4
4
|
<text class="title">{{ title }}</text>
|
|
5
5
|
</view>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.auth-top-navigation{display:flex;align-items:center;padding:0 10px}.auth-top-navigation .back-icon{width:13px;height:21px}.auth-top-navigation .title{flex:1;text-align:center;font-size:14px}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { clearEmpty, request, sendRequest } from "./utils/request";
|
|
2
|
-
export { config } from "./utils/config";
|
|
2
|
+
export { config, initconfig } from "./utils/config";
|
|
3
3
|
export { auth } from "./utils/auth";
|
|
4
4
|
export { db } from "./utils/db";
|
|
5
5
|
export type { BaseConfig } from "./utils/config";
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { clearEmpty, request, sendRequest } from "./utils/request.js";
|
|
2
|
-
import { config } from "./utils/config.js";
|
|
2
|
+
import { config, initconfig } from "./utils/config.js";
|
|
3
3
|
import { auth } from "./utils/auth.js";
|
|
4
4
|
import { db } from "./utils/db.js";
|
|
5
5
|
import { convertToISOString, formatDateTime, getHeight, kbToMb, validateRequired, validateRules } from "./utils/common.js";
|
|
@@ -22,6 +22,7 @@ export {
|
|
|
22
22
|
fileApi,
|
|
23
23
|
formatDateTime,
|
|
24
24
|
getHeight,
|
|
25
|
+
initconfig,
|
|
25
26
|
kbToMb,
|
|
26
27
|
request,
|
|
27
28
|
sendRequest,
|
package/dist/utils/auth.js
CHANGED
|
@@ -9,6 +9,10 @@ class Auth {
|
|
|
9
9
|
resolve(true);
|
|
10
10
|
return;
|
|
11
11
|
}
|
|
12
|
+
if (config.dev && config.testNewUser) {
|
|
13
|
+
reject(false);
|
|
14
|
+
return;
|
|
15
|
+
}
|
|
12
16
|
this.silentLogin().then((res) => {
|
|
13
17
|
if (res.status) {
|
|
14
18
|
resolve(true);
|
|
@@ -25,6 +29,15 @@ class Auth {
|
|
|
25
29
|
resolve(true);
|
|
26
30
|
return;
|
|
27
31
|
}
|
|
32
|
+
if (config.dev && config.testNewUser) {
|
|
33
|
+
reject(false);
|
|
34
|
+
let toUrl = loginurl + "?tabbar=" + (tabbar ? "true" : "false");
|
|
35
|
+
toUrl += "&backurl=" + backurl;
|
|
36
|
+
wx.navigateTo({
|
|
37
|
+
url: toUrl
|
|
38
|
+
});
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
28
41
|
this.silentLogin().then((res) => {
|
|
29
42
|
if (res.status) {
|
|
30
43
|
resolve(true);
|
package/dist/utils/config.d.ts
CHANGED
package/dist/utils/config.js
CHANGED
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.btn{font-size:16px;width:100% !important}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.btn-box{display:flex;align-items:center;justify-content:space-between;width:100%}.btn-box .btn-left{width:33%;margin-right:3%;height:48px;font-size:16px;line-height:48px}.btn-box .btn-right{height:48px;font-size:16px;width:64%;line-height:48px}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.image-box-bgc{position:relative;display:flex;align-items:center;justify-content:center;width:80px !important;height:80px;border:none;border-radius:10px;padding:0}.image-box-bgc .image-box-show{width:80px;height:80px}.image-box-bgc .select-image{position:absolute;width:24px;height:24px;bottom:0;right:0}.image-box-bgc[plain]{border:1px solid #e0e0e0}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.none-data{display:flex;align-items:center;justify-content:center;flex-direction:column}.none-data .holder-text{font-size:14px}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.mask-box{position:fixed;left:0;top:0;bottom:0;right:0;width:100%;background-color:rgba(0,0,0,.5);z-index:99999}.mask-popup{position:fixed;bottom:0;left:0;border-top-left-radius:25px;border-top-right-radius:25px;padding:10px 4% 30px 4%;width:92%;z-index:99999}.mask-popup .popup-title{color:#333;font-size:14px;padding:10px 0;font-weight:bold;display:flex;align-items:center;justify-content:space-between}.mask-popup .popup-title .close-icon{width:20px}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.search-box{position:relative;width:100%;border-radius:25px;background-color:#fff;display:flex;justify-content:space-between;align-items:center;height:35px;box-sizing:border-box;overflow:hidden}.search-box .search-input{height:35px;color:#6b7280;font-size:14px;padding-left:40px}.search-box .search-icon{width:20px;height:20px;position:absolute;left:10px;transform:translate(0, -50%);top:50%}.search-box .search-btn{padding-right:3%}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.top-navigation{display:flex;align-items:center;padding:0 10px}.top-navigation .back-icon{width:13px;height:21px}.top-navigation .title{flex:1;text-align:center;font-size:14px}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|