k.zhang 4 lat temu
rodzic
commit
85e127e204

Plik diff jest za duży
+ 1 - 0
dist/avatar/index.js


+ 1 - 0
dist/avatar/index.json

@@ -0,0 +1 @@
+{"component":true,"usingComponents":{"l-icon":"../icon/index"}  }

+ 12 - 0
dist/avatar/index.wxml

@@ -0,0 +1,12 @@
+
+<view class="l-avatar {{text||_isHaveUserNickName?'l-placement-'+placement:''}}" mut-bind:tap="tapAvatar">
+    <view class="l-avatar-image {{shape?'l-'+shape:''}} l-class" wx:if="{{_isHaveUserAvatarUrl||icon||src}}" style="width:{{size}}rpx;height:{{size}}rpx;min-width:{{size}}rpx;min-height:{{size}}rpx;">
+        <open-data class="open-data" wx:if="{{_isHaveUserAvatarUrl}}" type="userAvatarUrl"/>
+        <l-icon wx:elif="{{icon}}" size="{{iconSize || size*0.6}}" color="{{iconColor||'#ffffff'}}" name="{{icon}}"/>
+        <image wx:elif="{{src}}" src="{{src}}" mode="{{mode}}" style="width:{{size}}rpx;height:{{size}}rpx"/>
+    </view>
+    <view class="l-avatar-text l-class-text l-text-class" wx:if="{{text||_isHaveUserNickName}}">
+        <open-data class="open-data" wx:if="{{_isHaveUserNickName}}" type="userNickName"/>
+        <text class="l-avatar-text-text" wx:elif="{{text}}">{{text}}</text>
+    </view>
+</view>

Plik diff jest za duży
+ 1 - 0
dist/avatar/index.wxss


+ 6 - 1
pages/index/index.json

@@ -1,3 +1,8 @@
 {
-  "usingComponents": {}
+ 
+  "usingComponents": {
+    "content-title": "/components/content-title/index",
+    "content-card": "/components/content-card/index",
+    "l-avatar": "/dist/avatar/index"
+  }
 }

+ 13 - 2
pages/index/index.wxml

@@ -1,5 +1,5 @@
 <!--index.wxml-->
-<view class="container">
+<!-- <view class="container">
   <view class="userinfo">
     <block wx:if="{{canIUseOpenData}}" calss="userinfo-opendata">
       <view class="userinfo-avatar" bindtap="bindViewTap">
@@ -20,4 +20,15 @@
   <view class="usermotto">
     <text class="user-motto">{{motto}}</text>
   </view>
-</view>
+</view> -->
+
+<!-- <content-card l-content="content" name="">
+      <view class="content-item">
+        <l-avatar open-data="{{['userAvatarUrl','userNickName']}}" />
+        <text>总金额</text>
+      </view>
+      <view class="content-item">
+      
+      </view>
+    </content-card> -->
+    <l-avatar open-data="{{['userAvatarUrl','userNickName']}}" />

+ 33 - 0
pages/index/index.wxss

@@ -16,4 +16,37 @@
 
 .usermotto {
   margin-top: 200px;
+}
+
+.logo-container {
+  width           : 690rpx;
+  margin          : 30rpx auto;
+  background-color: #fff;
+  display         : flex;
+  flex-direction  : column;
+  align-items     : center;
+  padding         : 40rpx 0;
+  box-sizing      : border-box;
+  margin-bottom   : 30rpx;
+}
+
+.logo-img {
+  width : 220rpx;
+  height: 100rpx;
+}
+
+.logo-txt {
+  color    : #596c8e;
+  font-size: 28rpx;
+}
+
+.version-container {
+  display   : flex;
+  margin-top: 15rpx;
+}
+
+.container {
+  display       : flex;
+  flex-direction: column;
+  align-items   : center;
 }

+ 1 - 1
project.config.json

@@ -23,7 +23,7 @@
     "compileHotReLoad": false,
     "useMultiFrameRuntime": true,
     "useApiHook": true,
-    "useApiHostProcess": true,
+    "useApiHostProcess": false,
     "babelSetting": {
       "ignore": [],
       "disablePlugins": [],