Skip to content

Commit bb88950

Browse files
committed
v2.1.2
1 parent 89817a8 commit bb88950

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

108 files changed

+3350
-3986
lines changed

demo/.gitattributes

Lines changed: 0 additions & 2 deletions
This file was deleted.

demo/app.json

Lines changed: 3 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"pages": [
3+
"pages/index/index",
34
"pages/basics/home/home",
45
"pages/basics/layout/layout",
56
"pages/basics/button/button",
@@ -33,7 +34,6 @@
3334
"pages/about/test/list",
3435
"pages/about/test/filter",
3536
"pages/about/home/home",
36-
"custom-tab-bar/index",
3737
"pages/plugin/drawer/drawer",
3838
"pages/plugin/verticalnav/verticalnav"
3939
],
@@ -43,38 +43,7 @@
4343
"navigationStyle": "custom",
4444
"navigationBarTextStyle": "white"
4545
},
46-
"usingComponents": {},
47-
"tabBar": {
48-
"custom": true,
49-
"color": "#aaa",
50-
"selectedColor": "#39b54a",
51-
"borderStyle": "black",
52-
"backgroundColor": "#ffffff",
53-
"list": [
54-
{
55-
"pagePath": "pages/basics/home/home",
56-
"iconPath": "/images/tabbar/basics.png",
57-
"selectedIconPath": "/images/tabbar/basics_cur.png",
58-
"text": "基础"
59-
},
60-
{
61-
"pagePath": "pages/component/home/home",
62-
"iconPath": "/images/tabbar/component.png",
63-
"selectedIconPath": "/images/tabbar/component_cur.png",
64-
"text": "组件"
65-
},
66-
{
67-
"pagePath": "pages/plugin/home/home",
68-
"iconPath": "/images/tabbar/plugin.png",
69-
"selectedIconPath": "/images/tabbar/plugin_cur.png",
70-
"text": "扩展"
71-
},
72-
{
73-
"pagePath": "pages/about/home/home",
74-
"iconPath": "/images/tabbar/about.png",
75-
"selectedIconPath": "/images/tabbar/about_cur.png",
76-
"text": "关于"
77-
}
78-
]
46+
"usingComponents": {
47+
"cu-custom":"/colorui/components/cu-custom"
7948
}
8049
}

demo/app.wxss

Lines changed: 4 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
@import "icon.wxss";
2-
@import "colorui.wxss";
1+
@import "colorui/main.wxss";
2+
@import "colorui/icon.wxss";
33

4-
.cu-modal.show {
5-
z-index: 99999;
4+
.scrollPage {
5+
height: 100vh;
66
}
77

88
.nav-list {
@@ -105,31 +105,3 @@
105105
.text-light {
106106
font-weight: 300;
107107
}
108-
109-
@keyframes show {
110-
0% {
111-
transform: translateY(-50px);
112-
}
113-
114-
60% {
115-
transform: translateY(40rpx);
116-
}
117-
118-
100% {
119-
transform: translateY(0px);
120-
}
121-
}
122-
123-
@-webkit-keyframes show {
124-
0% {
125-
transform: translateY(-50px);
126-
}
127-
128-
60% {
129-
transform: translateY(40rpx);
130-
}
131-
132-
100% {
133-
transform: translateY(0px);
134-
}
135-
}

demo/colorui/animation.wxss

Lines changed: 184 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,184 @@
1+
/*
2+
Animation 微动画
3+
基于ColorUI组建库的动画模块 by 文晓港 2019年3月26日19:52:28
4+
*/
5+
6+
/* css 滤镜 控制黑白底色gif的 */
7+
.gif-black{
8+
mix-blend-mode: screen;
9+
}
10+
.gif-white{
11+
mix-blend-mode: multiply;
12+
}
13+
14+
15+
/* Animation css */
16+
[class*=animation-] {
17+
animation-duration: .5s;
18+
animation-timing-function: ease-out;
19+
animation-fill-mode: both
20+
}
21+
22+
.animation-fade {
23+
animation-name: fade;
24+
animation-duration: .8s;
25+
animation-timing-function: linear
26+
}
27+
28+
.animation-scale-up {
29+
animation-name: scale-up
30+
}
31+
32+
.animation-scale-down {
33+
animation-name: scale-down
34+
}
35+
36+
.animation-slide-top {
37+
animation-name: slide-top
38+
}
39+
40+
.animation-slide-bottom {
41+
animation-name: slide-bottom
42+
}
43+
44+
.animation-slide-left {
45+
animation-name: slide-left
46+
}
47+
48+
.animation-slide-right {
49+
animation-name: slide-right
50+
}
51+
52+
.animation-shake {
53+
animation-name: shake
54+
}
55+
56+
.animation-reverse {
57+
animation-direction: reverse
58+
}
59+
60+
@keyframes fade {
61+
0% {
62+
opacity: 0
63+
}
64+
65+
100% {
66+
opacity: 1
67+
}
68+
}
69+
70+
@keyframes scale-up {
71+
0% {
72+
opacity: 0;
73+
transform: scale(.2)
74+
}
75+
76+
100% {
77+
opacity: 1;
78+
transform: scale(1)
79+
}
80+
}
81+
82+
@keyframes scale-down {
83+
0% {
84+
opacity: 0;
85+
transform: scale(1.8)
86+
}
87+
88+
100% {
89+
opacity: 1;
90+
transform: scale(1)
91+
}
92+
}
93+
94+
@keyframes slide-top {
95+
0% {
96+
opacity: 0;
97+
transform: translateY(-100%)
98+
}
99+
100+
100% {
101+
opacity: 1;
102+
transform: translateY(0)
103+
}
104+
}
105+
106+
@keyframes slide-bottom {
107+
0% {
108+
opacity: 0;
109+
transform: translateY(100%)
110+
}
111+
112+
100% {
113+
opacity: 1;
114+
transform: translateY(0)
115+
}
116+
}
117+
118+
@keyframes shake {
119+
120+
0%,
121+
100% {
122+
transform: translateX(0)
123+
}
124+
125+
10% {
126+
transform: translateX(-9px)
127+
}
128+
129+
20% {
130+
transform: translateX(8px)
131+
}
132+
133+
30% {
134+
transform: translateX(-7px)
135+
}
136+
137+
40% {
138+
transform: translateX(6px)
139+
}
140+
141+
50% {
142+
transform: translateX(-5px)
143+
}
144+
145+
60% {
146+
transform: translateX(4px)
147+
}
148+
149+
70% {
150+
transform: translateX(-3px)
151+
}
152+
153+
80% {
154+
transform: translateX(2px)
155+
}
156+
157+
90% {
158+
transform: translateX(-1px)
159+
}
160+
}
161+
162+
@keyframes slide-left {
163+
0% {
164+
opacity: 0;
165+
transform: translateX(-100%)
166+
}
167+
168+
100% {
169+
opacity: 1;
170+
transform: translateX(0)
171+
}
172+
}
173+
174+
@keyframes slide-right {
175+
0% {
176+
opacity: 0;
177+
transform: translateX(100%)
178+
}
179+
180+
100% {
181+
opacity: 1;
182+
transform: translateX(0)
183+
}
184+
}
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
const app = getApp();
2+
Component({
3+
/**
4+
* 组件的一些选项
5+
*/
6+
options: {
7+
addGlobalClass: true,
8+
multipleSlots: true
9+
},
10+
/**
11+
* 组件的对外属性
12+
*/
13+
properties: {
14+
bgColor: {
15+
type: String,
16+
default: ''
17+
},
18+
isCustom: {
19+
type: [Boolean, String],
20+
default: false
21+
},
22+
isBack: {
23+
type: [Boolean, String],
24+
default: false
25+
},
26+
bgImage: {
27+
type: String,
28+
default: ''
29+
},
30+
},
31+
/**
32+
* 组件的初始数据
33+
*/
34+
data: {
35+
StatusBar: app.globalData.StatusBar,
36+
CustomBar: app.globalData.CustomBar,
37+
Custom: app.globalData.Custom
38+
},
39+
/**
40+
* 组件的方法列表
41+
*/
42+
methods: {
43+
BackPage() {
44+
wx.navigateBack({
45+
delta: 1
46+
});
47+
},
48+
toHome(){
49+
wx.reLaunch({
50+
url: '/pages/index/index',
51+
})
52+
}
53+
}
54+
})
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"component": true,
3+
"usingComponents": {}
4+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<view class="cu-custom" style="height:{{CustomBar}}px">
2+
<view class="cu-bar fixed {{bgImage!=''?'none-bg text-white bg-img':''}} {{bgColor}}" style="height:{{CustomBar}}px;padding-top:{{StatusBar}}px;{{bgImage?'background-image:url(' + bgImage+')':''}}">
3+
<view class="action" bindtap="BackPage" wx:if="{{isBack}}">
4+
<text class="icon-back"></text>
5+
<slot name="backText"></slot>
6+
</view>
7+
<view class="action border-custom" wx:if="{{isCustom}}" style="width:{{Custom.width}}px;height:{{Custom.height}}px;margin-left:calc(750rpx - {{Custom.right}}px)">
8+
<text class="icon-back" bindtap="BackPage"></text>
9+
<text class="icon-homefill" bindtap="toHome"></text>
10+
</view>
11+
<view class="content" style="top:{{StatusBar}}px">
12+
<slot name="content"></slot>
13+
</view>
14+
<slot name="right"></slot>
15+
</view>
16+
</view>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/* colorui/components/cu-custom.wxss */

demo/icon.wxss renamed to demo/colorui/icon.wxss

Lines changed: 5 additions & 3 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)