wl-design-mobile 0.0.2 → 0.0.4

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/README.md ADDED
@@ -0,0 +1,6 @@
1
+ # wl-design-mobile
2
+
3
+ ## Setup
4
+ ```
5
+ npm i wl-design-mobile
6
+ ```
@@ -1,9 +1,9 @@
1
1
  <template>
2
2
  <div class="btns">
3
- <ul class="lambobigbutton-ul">
3
+ <ul class="big-btn-ul">
4
4
  <van-button :disabled="disabled" :icon="icon" :icon-position="position" :loading="loading" :plain="plain"
5
- :type="type" class="LamboBigButton" size="large" @click="handleClick"> {{ title }}
6
- <slot name="icon"></slot>
5
+ :type="type" class="big-btn" size="large" @click="handleClick"> {{ text }}
6
+ <slot name="extend"></slot>
7
7
  </van-button>
8
8
 
9
9
  </ul>
@@ -28,7 +28,7 @@ export default {
28
28
  type: Boolean,
29
29
  default: false
30
30
  },
31
- title: {
31
+ text: {
32
32
  type: String,
33
33
  default: '大号按钮'
34
34
  },
@@ -68,19 +68,19 @@ export default {
68
68
  <style scoped>
69
69
  @import "../styles/index.less";
70
70
 
71
- .LamboBigButton {
71
+ .big-btn {
72
72
  height: 38px;
73
73
  border-radius: 3px;
74
74
  }
75
75
 
76
76
  /*填充按钮primary类型按钮样式 */
77
- /deep/ .lambobigbutton-ul .van-button--primary {
77
+ /deep/ .big-btn-ul .van-button--primary {
78
78
  background: var(--scl-blue);
79
79
  border: 1px solid var(--scl-blue);
80
80
  }
81
81
 
82
82
  /*填充按钮primary类型不可用按钮样式 */
83
- /deep/ .lambobigbutton-ul .van-button--disabled {
83
+ /deep/ .big-btn-ul .van-button--disabled {
84
84
  cursor: not-allowed;
85
85
  opacity: 1;
86
86
  background-color: var(--scl-gray-6);
@@ -89,34 +89,34 @@ export default {
89
89
  }
90
90
 
91
91
  /*按钮文字样式*/
92
- /deep/ .lambobigbutton-ul .van-button__text {
92
+ /deep/ .big-btn-ul .van-button__text {
93
93
  font-size: 14px;
94
94
  padding: 10px 0px;
95
95
  font-family: 微软雅黑, serif Regular;
96
96
  }
97
97
 
98
98
  /*线框按钮按钮样式*/
99
- /deep/ .lambobigbutton-ul .van-button--plain.van-button--info {
99
+ /deep/ .big-btn-ul .van-button--plain.van-button--info {
100
100
  color: var(--scl-blue);
101
101
  border: 1px solid var(--scl-blue);
102
102
  }
103
103
 
104
104
  /*线框按钮不可用按钮样式*/
105
- /deep/ .lambobigbutton-ul .van-button--plain.van-button--info.van-button--disabled {
105
+ /deep/ .big-btn-ul .van-button--plain.van-button--info.van-button--disabled {
106
106
  color: #000000;
107
107
  border: 1px solid var(--scl-gray-6);
108
108
  background-color: #ffffff;
109
109
  }
110
110
 
111
111
  /*无框类型按钮样式 */
112
- /deep/ .lambobigbutton-ul .van-button--default {
112
+ /deep/ .big-btn-ul .van-button--default {
113
113
  background: var(--scl-white-1);
114
114
  border: 1px solid var(--scl-white-1);
115
115
  color: var(--scl-blue);
116
116
  }
117
117
 
118
118
  /*无框按钮不可用按钮样式*/
119
- /deep/ .lambobigbutton-ul .van-button--default.van-button--disabled {
119
+ /deep/ .big-btn-ul .van-button--default.van-button--disabled {
120
120
  color: #000000;
121
121
  border: 1px solid var(--scl-white-1);
122
122
  background-color: var(--scl-white-1);
@@ -1,8 +1,9 @@
1
1
  <template>
2
2
  <div class="btns">
3
- <ul class="lambomediumbutton-ul">
3
+ <ul class="mid-btn-ul">
4
4
  <van-button :disabled="disabled" :icon="icon" :icon-position="position" :loading="loading" :plain="plain"
5
- :type="type" class="LamboMediumButton" size="normal" @click="handleClick"> {{ text }}
5
+ :type="type" class="mid-btn" size="normal" @click="handleClick"> {{ text }}
6
+ <slot name="extend"></slot>
6
7
  </van-button>
7
8
  </ul>
8
9
  </div>
@@ -66,19 +67,19 @@ export default {
66
67
  <style scoped>
67
68
  @import "../styles/index.less";
68
69
 
69
- .LamboMediumButton {
70
+ .mid-btn {
70
71
  height: 30px;
71
72
  border-radius: 3px;
72
73
  }
73
74
 
74
75
  /*填充按钮primary类型按钮样式 */
75
- /deep/ .lambomediumbutton-ul .van-button--primary {
76
+ /deep/ .mid-btn-ul .van-button--primary {
76
77
  background: var(--scl-blue);
77
78
  border: 1px solid var(--scl-blue);
78
79
  }
79
80
 
80
81
  /*填充按钮primary类型不可用按钮样式 */
81
- /deep/ .lambomediumbutton-ul .van-button--disabled {
82
+ /deep/ .mid-btn-ul .van-button--disabled {
82
83
  cursor: not-allowed;
83
84
  opacity: 1;
84
85
  background-color: var(--scl-gray-6);
@@ -87,34 +88,34 @@ export default {
87
88
  }
88
89
 
89
90
  /*按钮文字样式*/
90
- /deep/ .lambomediumbutton-ul .van-button__text {
91
- font-size: 11px;
91
+ /deep/ .mid-btn-ul .van-button__text {
92
+ font-size: 12px;
92
93
  padding: 10px 0px;
93
94
  font-family: 微软雅黑, serif Regular;
94
95
  }
95
96
 
96
97
  /*线框按钮按钮样式*/
97
- /deep/ .lambomediumbutton-ul .van-button--plain.van-button--info {
98
+ /deep/ .mid-btn-ul .van-button--plain.van-button--info {
98
99
  color: var(--scl-blue);
99
100
  border: 1px solid var(--scl-blue);
100
101
  }
101
102
 
102
103
  /*线框按钮不可用按钮样式*/
103
- /deep/ .lambomediumbutton-ul .van-button--plain.van-button--info.van-button--disabled {
104
+ /deep/ .mid-btn-ul .van-button--plain.van-button--info.van-button--disabled {
104
105
  color: #000000;
105
106
  border: 1px solid var(--scl-gray-6);
106
107
  background-color: #ffffff;
107
108
  }
108
109
 
109
110
  /*无框类型按钮样式 */
110
- /deep/ .lambomediumbutton-ul .van-button--default {
111
+ /deep/ .mid-btn-ul .van-button--default {
111
112
  background: var(--scl-white-1);
112
113
  border: 1px solid var(--scl-white-1);
113
114
  color: var(--scl-blue);
114
115
  }
115
116
 
116
117
  /*无框按钮不可用按钮样式*/
117
- /deep/ .lambomediumbutton-ul .van-button--default.van-button--disabled {
118
+ /deep/ .mid-btn-ul .van-button--default.van-button--disabled {
118
119
  color: #000000;
119
120
  border: 1px solid var(--scl-white-1);
120
121
  background-color: var(--scl-white-1);
@@ -1,8 +1,8 @@
1
1
  <template>
2
2
  <div class="btns">
3
- <ul class="lambomediumbutton-ul">
3
+ <ul class="small-button-ul">
4
4
  <van-button :disabled="disabled" :icon="icon" :icon-position="position" :loading="loading" :plain="plain"
5
- :type="type" class="LamboMediumButton" size="small" @click="handleClick"> {{ text }}
5
+ :type="type" class="small-button" size="small" @click="handleClick"> {{ text }}
6
6
  </van-button>
7
7
  </ul>
8
8
  </div>
@@ -66,19 +66,19 @@ export default {
66
66
  <style scoped>
67
67
  @import "../styles/index.less";
68
68
 
69
- .LamboMediumButton {
69
+ .small-button {
70
70
  height: 27px;
71
71
  border-radius: 3px;
72
72
  }
73
73
 
74
74
  /*填充按钮primary类型按钮样式 */
75
- /deep/ .lambomediumbutton-ul .van-button--primary {
75
+ /deep/ .small-button-ul .van-button--primary {
76
76
  background: var(--scl-blue);
77
77
  border: 1px solid var(--scl-blue);
78
78
  }
79
79
 
80
80
  /*填充按钮primary类型不可用按钮样式 */
81
- /deep/ .lambomediumbutton-ul .van-button--disabled {
81
+ /deep/ .small-button-ul .van-button--disabled {
82
82
  cursor: not-allowed;
83
83
  opacity: 1;
84
84
  background-color: var(--scl-gray-6);
@@ -87,34 +87,34 @@ export default {
87
87
  }
88
88
 
89
89
  /*按钮文字样式*/
90
- /deep/ .lambomediumbutton-ul .van-button__text {
90
+ /deep/ .small-button-ul .van-button__text {
91
91
  font-size: 11px;
92
92
  padding: 10px 0px;
93
93
  font-family: 微软雅黑, serif Regular;
94
94
  }
95
95
 
96
96
  /*线框按钮按钮样式*/
97
- /deep/ .lambomediumbutton-ul .van-button--plain.van-button--info {
97
+ /deep/ .small-button-ul .van-button--plain.van-button--info {
98
98
  color: var(--scl-blue);
99
99
  border: 1px solid var(--scl-blue);
100
100
  }
101
101
 
102
102
  /*线框按钮不可用按钮样式*/
103
- /deep/ .lambomediumbutton-ul .van-button--plain.van-button--info.van-button--disabled {
103
+ /deep/ .small-button-ul .van-button--plain.van-button--info.van-button--disabled {
104
104
  color: #000000;
105
105
  border: 1px solid var(--scl-gray-6);
106
106
  background-color: #ffffff;
107
107
  }
108
108
 
109
109
  /*无框类型按钮样式 */
110
- /deep/ .lambomediumbutton-ul .van-button--default {
110
+ /deep/ .small-button-ul .van-button--default {
111
111
  background: var(--scl-white-1);
112
112
  border: 1px solid var(--scl-white-1);
113
113
  color: var(--scl-blue);
114
114
  }
115
115
 
116
116
  /*无框按钮不可用按钮样式*/
117
- /deep/ .lambomediumbutton-ul .van-button--default.van-button--disabled {
117
+ /deep/ .small-button-ul .van-button--default.van-button--disabled {
118
118
  color: #000000;
119
119
  border: 1px solid var(--scl-white-1);
120
120
  background-color: var(--scl-white-1);
@@ -25,6 +25,8 @@ export default {
25
25
  }
26
26
  },
27
27
  created() {
28
+ },
29
+ mounted() {
28
30
  console.log("LamboDetailGrid -- created -- data:", this.data)
29
31
  this.initData()
30
32
  },
@@ -37,14 +37,16 @@ export default {
37
37
  }
38
38
 
39
39
  .detail-row-box {
40
- height: 70px;
40
+ min-height: 60px;
41
+ height: auto;
41
42
  margin: 0 14px;
42
43
  padding: 12px 0;
43
44
  border-bottom: 1px solid var(--scl-white-2);
44
45
  }
45
46
 
46
47
  .detail-row-title {
47
- height: 16px;
48
+ min-height: 16px;
49
+ height: auto;
48
50
  margin-bottom: 12px;
49
51
  font-size: 12px;
50
52
  font-family: Regular;
@@ -52,7 +54,8 @@ export default {
52
54
  }
53
55
 
54
56
  .detail-row-val {
55
- height: 18px;
57
+ min-height: 18px;
58
+ height: auto;
56
59
  font-size: 14px;
57
60
  color: var(--scl-lucency-1);
58
61
  }
@@ -1,98 +1,98 @@
1
- .imgUplodaContainer {
2
- padding: 12px 14px;
3
- background: var(--scl-white-1);
4
- }
5
-
6
- .imgUplodaTitle {
7
- /*margin-bottom: 18px;*/
8
- display: flex;
9
- justify-content: space-between;
10
- }
11
-
12
- .imgUplodaTitle p {
13
- width: 100%;
14
- color: var(--scl-gray-3);
15
- font-size: 14px;
16
- position: absolute;
17
- top: -2px;
18
- }
19
-
20
- .imgUplodaTitle img {
21
- width: 20px;
22
- height: 20px;
23
- display: block;
24
- }
25
-
26
- /*右上角上传按钮样式*/
27
- /deep/ .van-button--primary {
28
- background: none;
29
- border: none;
30
- height: auto;
31
- }
32
-
33
- /*右上角上传按钮位置*/
34
- /deep/ .van-uploader__input-wrapper, .van-uploader {
35
- width: 100%;
36
- position: static;
37
- }
38
-
39
- /*上传按钮首次进页面控制图标大小*/
40
- /deep/ .van-icon__image {
41
- width: 1em;
42
- }
43
-
44
- /*图片上传区域及右上角上传按钮*/
45
- /deep/ .setUploader {
46
- position: relative;
47
- margin-bottom: 10px;
48
- }
49
-
50
- /*图片整体位置*/
51
- /deep/ .van-uploader__wrapper {
52
- margin-top: 30px;
53
- display: grid;
54
- justify-content: space-between;
55
- grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
56
- gap: 10px;
57
- }
58
-
59
- /*右上角上传按钮位置*/
60
- /deep/ .van-button--normal {
61
- width: 20px;
62
- position: absolute;
63
- top: -1px;
64
- right: -8px;
65
- }
66
-
67
- /*/deep/ .van-uploader__preview {*/
68
- /* width: 23%;*/
69
- /* height: auto;*/
70
- /* padding-left: 8px;*/
71
- /* margin: 8px 0 0 0;*/
72
- /*}*/
73
-
74
- /*预览图片样式*/
75
- /*/deep/ .van-uploader__preview-image {*/
76
- /* display: block;*/
77
- /* width: auto;*/
78
- /* height: 100px;*/
79
- /* overflow: hidden;*/
80
- /* border: 1px solid #515a6e38;*/
81
- /*}*/
82
-
83
- /*控制上传功能覆盖区域*/
84
- /deep/ .van-uploader__input {
85
- height: 20px;
86
- width: 20px;
87
- position: absolute;
88
- left: 95%;
89
- }
90
-
91
- /deep/ .van-uploader__preview {
92
- margin: 0;
93
- }
94
-
95
- /deep/ .van-uploader__preview-image {
96
- width: auto;
97
- height: 95px;
1
+ .imgUplodaContainer {
2
+ padding: 12px 14px;
3
+ background: var(--scl-white-1);
4
+ }
5
+
6
+ .imgUplodaTitle {
7
+ /*margin-bottom: 18px;*/
8
+ display: flex;
9
+ justify-content: space-between;
10
+ }
11
+
12
+ .imgUplodaTitle p {
13
+ width: 100%;
14
+ color: var(--scl-gray-3);
15
+ font-size: 14px;
16
+ position: absolute;
17
+ top: -2px;
18
+ }
19
+
20
+ .imgUplodaTitle img {
21
+ width: 20px;
22
+ height: 20px;
23
+ display: block;
24
+ }
25
+
26
+ /*右上角上传按钮样式*/
27
+ /deep/ .van-button--primary {
28
+ background: none;
29
+ border: none;
30
+ height: auto;
31
+ }
32
+
33
+ /*右上角上传按钮位置*/
34
+ /deep/ .van-uploader__input-wrapper, .van-uploader {
35
+ width: 100%;
36
+ position: static;
37
+ }
38
+
39
+ /*上传按钮首次进页面控制图标大小*/
40
+ /deep/ .van-icon__image {
41
+ width: 1em;
42
+ }
43
+
44
+ /*图片上传区域及右上角上传按钮*/
45
+ /deep/ .setUploader {
46
+ position: relative;
47
+ margin-bottom: 10px;
48
+ }
49
+
50
+ /*图片整体位置*/
51
+ /deep/ .van-uploader__wrapper {
52
+ margin-top: 30px;
53
+ display: grid;
54
+ justify-content: space-between;
55
+ grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
56
+ gap: 10px;
57
+ }
58
+
59
+ /*右上角上传按钮位置*/
60
+ /deep/ .van-button--normal {
61
+ width: 20px;
62
+ position: absolute;
63
+ top: -1px;
64
+ right: -8px;
65
+ }
66
+
67
+ /*/deep/ .van-uploader__preview {*/
68
+ /* width: 23%;*/
69
+ /* height: auto;*/
70
+ /* padding-left: 8px;*/
71
+ /* margin: 8px 0 0 0;*/
72
+ /*}*/
73
+
74
+ /*预览图片样式*/
75
+ /*/deep/ .van-uploader__preview-image {*/
76
+ /* display: block;*/
77
+ /* width: auto;*/
78
+ /* height: 100px;*/
79
+ /* overflow: hidden;*/
80
+ /* border: 1px solid #515a6e38;*/
81
+ /*}*/
82
+
83
+ /*控制上传功能覆盖区域*/
84
+ /deep/ .van-uploader__input {
85
+ height: 20px;
86
+ width: 20px;
87
+ position: absolute;
88
+ left: 95%;
89
+ }
90
+
91
+ /deep/ .van-uploader__preview {
92
+ margin: 0;
93
+ }
94
+
95
+ /deep/ .van-uploader__preview-image {
96
+ width: auto;
97
+ height: 95px;
98
98
  }
@@ -1,39 +1,39 @@
1
- .coll-div {
2
- margin-bottom: 8px;
3
- }
4
-
5
- .indicator-title {
6
- display: flex;
7
- align-items: center;
8
- color: var(--scl-blue);
9
- font-size: 14px;
10
- font-family: 微软雅黑, serif Regular;
11
- }
12
-
13
- .indicator-title .color-line {
14
- width: 3px;
15
- height: 14px;
16
- margin-right: 8px;
17
- }
18
-
19
- .coll-title-icon {
20
- justify-content: center;
21
- align-items: center;
22
- align-content: center;
23
- }
24
-
25
- /* 覆盖折叠面板的标题的padding */
26
- /deep/ .van-cell {
27
- padding: 12px 10px;
28
- }
29
-
30
- /* 覆盖去掉折叠面板的标题下面的线 */
31
- /deep/ .van-cell::after {
32
- border: none;
33
- }
34
-
35
- /* 覆盖折叠面板的内容的padding */
36
- /deep/ .van-collapse-item__content {
37
- padding: 0px 0px 0px 0px;
38
- }
39
-
1
+ .coll-div {
2
+ margin-bottom: 8px;
3
+ }
4
+
5
+ .indicator-title {
6
+ display: flex;
7
+ align-items: center;
8
+ color: var(--scl-blue);
9
+ font-size: 14px;
10
+ font-family: 微软雅黑, serif Regular;
11
+ }
12
+
13
+ .indicator-title .color-line {
14
+ width: 3px;
15
+ height: 14px;
16
+ margin-right: 8px;
17
+ }
18
+
19
+ .coll-title-icon {
20
+ justify-content: center;
21
+ align-items: center;
22
+ align-content: center;
23
+ }
24
+
25
+ /* 覆盖折叠面板的标题的padding */
26
+ /deep/ .van-cell {
27
+ padding: 12px 10px;
28
+ }
29
+
30
+ /* 覆盖去掉折叠面板的标题下面的线 */
31
+ /deep/ .van-cell::after {
32
+ border: none;
33
+ }
34
+
35
+ /* 覆盖折叠面板的内容的padding */
36
+ /deep/ .van-collapse-item__content {
37
+ padding: 0px 0px 0px 0px;
38
+ }
39
+
@@ -16,7 +16,7 @@
16
16
  </div>
17
17
  </div>
18
18
  <div>
19
- <van-popup v-model:show="showBottom" :style="{ height: '33%' }" position="bottom">
19
+ <van-popup v-model="showBottom" :style="{ height: '33%' }" position="bottom">
20
20
  <van-checkbox-group v-model="selectItem.K">
21
21
  <div class="edit-top-div">
22
22
  <van-button class="edit-cancel-btn" size="normal" @click="cancel">取消</van-button>
@@ -137,6 +137,7 @@ export default {
137
137
  changeColor() {
138
138
  let searchRows = document.querySelectorAll('.edit-box')
139
139
  Array.from(searchRows).forEach(function (row, index) {
140
+ console.log(index)
140
141
  row.addEventListener('click', function () {
141
142
  Array.from(searchRows).forEach(function (row) {
142
143
  row.style.borderBottom = '1px solid var(--scl-white-2)'
@@ -1,124 +1,127 @@
1
- .edit-box {
2
- min-height: 70px;
3
- display: flex;
4
- justify-content: space-between;
5
- padding: 12px 14px;
6
- border-bottom: 1px solid var(--scl-white-2);
7
- background-color: var(--scl-white-1);
8
- }
9
-
10
- .edit-left-box {
11
- width: 100%;
12
- }
13
-
14
- /* 覆盖value的padding */
15
- .edit-left-box /deep/ .van-cell {
16
- padding: 0;
17
- }
18
-
19
- .edit-left-top {
20
- display: flex;
21
- align-items: center;
22
- height: 16px;
23
- margin-bottom: 12px
24
- }
25
-
26
- .edit-red-icon {
27
- margin-right: 4px
28
- }
29
-
30
- .edit-title {
31
- font-size: 12px;
32
- font-family: Regular;
33
- color: var(--scl-gray-2)
34
- }
35
-
36
- .edit-lambo-input {
37
- border: none;
38
- outline: none;
39
- background: none;
40
- height: 18px;
41
- font-size: 14px;
42
- color: var(--scl-gray-5);
43
- display: flex;
44
- justify-content: flex-start;
45
- align-items: center;
46
- flex: 1;
47
- }
48
-
49
- .edit-lambo-input-textarea {
50
- border: none;
51
- outline: none;
52
- background: none;
53
- font-size: 14px;
54
- color: var(--scl-gray-5);
55
- display: flex;
56
- justify-content: flex-start;
57
- align-items: center;
58
- flex: 1;
59
- }
60
-
61
- .edit-right-icon {
62
- display: flex;
63
- align-items: center
64
- }
65
-
66
-
67
- .edit-top-div {
68
- display: flex;
69
- justify-content: space-between;
70
- height: 44px;
71
- line-height: 44px;
72
- width: 100%;
73
- position: fixed;
74
- z-index: 300;
75
- }
76
-
77
- .edit-cancel-btn {
78
- border: none;
79
- color: var(--scl-gray-3);
80
- }
81
-
82
- .edit-confirm-btn {
83
- border: none;
84
- color: var(--scl-blue);
85
- }
86
-
87
- .edit-select-title {
88
- font-size: 16px;
89
- font-weight: bold;
90
- }
91
-
92
- /*修改单选多选的滚动条样式*/
93
- /deep/ .van-radio-group {
94
- position: relative;
95
- }
96
-
97
- /*修改单选多选的滚动条样式*/
98
- /deep/ .van-cell-group {
99
- padding-top: 44px;
100
- }
101
-
102
- /*修改单选多选的滚动条样式*/
103
- /deep/ .van-cell:first-child {
104
- padding-top: 10px;
105
- }
106
-
107
-
108
- /*滚动条样式*/
109
- /deep/ ::-webkit-scrollbar {
110
- width: 6px;
111
- }
112
-
113
- /*滚动条样式*/
114
- /deep/ ::-webkit-scrollbar-thumb {
115
- border-radius: var(--ind-border-radius-xl);
116
- background: rgba(45, 140, 240, 0.6);
117
- }
118
-
119
- /*滚动条样式*/
120
- /deep/ ::-webkit-scrollbar-track {
121
- -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.1);
122
- border-radius: var(--ind-border-radius-xl);
123
- background: rgba(231, 242, 250, 0.4);
124
- }
1
+ .edit-box {
2
+ min-height: 50px;
3
+ height: auto;
4
+ display: flex;
5
+ justify-content: space-between;
6
+ padding: 12px 0;
7
+ border-bottom: 1px solid var(--scl-white-2);
8
+ background-color: var(--scl-white-1);
9
+ }
10
+
11
+ .edit-left-box {
12
+ width: 100%;
13
+ }
14
+
15
+ /* 覆盖value的padding */
16
+ .edit-left-box /deep/ .van-cell {
17
+ padding: 0;
18
+ }
19
+
20
+ .edit-left-top {
21
+ display: flex;
22
+ align-items: center;
23
+ height: 16px;
24
+ padding: 0 15px;
25
+ margin-bottom: 12px
26
+ }
27
+
28
+ .edit-red-icon {
29
+ margin-right: 4px
30
+ }
31
+
32
+ .edit-title {
33
+ font-size: 12px;
34
+ font-family: Regular;
35
+ color: var(--scl-gray-2)
36
+ }
37
+
38
+ .edit-lambo-input {
39
+ border: none;
40
+ outline: none;
41
+ background: none;
42
+ height: 18px;
43
+ font-size: 14px;
44
+ color: var(--scl-gray-5);
45
+ display: flex;
46
+ justify-content: flex-start;
47
+ align-items: center;
48
+ flex: 1;
49
+ margin-right: 8px;
50
+ }
51
+
52
+ .edit-lambo-input-textarea {
53
+ border: none;
54
+ outline: none;
55
+ background: none;
56
+ font-size: 14px;
57
+ color: var(--scl-gray-5);
58
+ display: flex;
59
+ justify-content: flex-start;
60
+ align-items: center;
61
+ flex: 1;
62
+ }
63
+
64
+ .edit-right-icon {
65
+ display: flex;
66
+ align-items: center
67
+ }
68
+
69
+
70
+ .edit-top-div {
71
+ display: flex;
72
+ justify-content: space-between;
73
+ height: 44px;
74
+ line-height: 44px;
75
+ width: 100%;
76
+ position: fixed;
77
+ z-index: 300;
78
+ }
79
+
80
+ .edit-cancel-btn {
81
+ border: none;
82
+ color: var(--scl-gray-3);
83
+ }
84
+
85
+ .edit-confirm-btn {
86
+ border: none;
87
+ color: var(--scl-blue);
88
+ }
89
+
90
+ .edit-select-title {
91
+ font-size: 16px;
92
+ font-weight: bold;
93
+ }
94
+
95
+ /*修改单选多选的滚动条样式*/
96
+ /deep/ .van-radio-group {
97
+ position: relative;
98
+ }
99
+
100
+ /*修改单选多选的滚动条样式*/
101
+ /deep/ .van-cell-group {
102
+ padding-top: 44px;
103
+ }
104
+
105
+ /*修改单选多选的滚动条样式*/
106
+ /deep/ .van-cell:first-child {
107
+ padding-top: 10px;
108
+ }
109
+
110
+
111
+ /*滚动条样式*/
112
+ /deep/ ::-webkit-scrollbar {
113
+ width: 6px;
114
+ }
115
+
116
+ /*滚动条样式*/
117
+ /deep/ ::-webkit-scrollbar-thumb {
118
+ border-radius: var(--ind-border-radius-xl);
119
+ background: rgba(45, 140, 240, 0.6);
120
+ }
121
+
122
+ /*滚动条样式*/
123
+ /deep/ ::-webkit-scrollbar-track {
124
+ -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.1);
125
+ border-radius: var(--ind-border-radius-xl);
126
+ background: rgba(231, 242, 250, 0.4);
127
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wl-design-mobile",
3
- "version": "0.0.2",
3
+ "version": "0.0.4",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "author": "finch",
@@ -0,0 +1,123 @@
1
+ <template>
2
+ <div>
3
+ <div class="opt-btn">
4
+ <div>
5
+ <slot name="optBtn"></slot>
6
+ </div>
7
+ <div v-if="showFilter">
8
+ <lambo-icon-button :icon="'order.png'" @click="showOrderPop"></lambo-icon-button>
9
+ <lambo-icon-button :icon="'filter.png'" @click="showFilterPop"></lambo-icon-button>
10
+ </div>
11
+ </div>
12
+ <div v-if="showFilter">
13
+ <filtrate-row :name="'降序'"></filtrate-row>
14
+ <filtrate-row :name="'筛选范围'"></filtrate-row>
15
+ </div>
16
+ <van-popup
17
+ ref="orderPopup"
18
+ v-model="orderPop"
19
+ position="bottom"
20
+ round
21
+ @close="closeOrderPop"
22
+ class="van-popup">
23
+ <template v-slot:default>
24
+ <van-checkbox-group class="popup-item" v-model="orderChecked" shape="square">
25
+ <div class="opt-btn" v-for="(item) in orderColumns" :key="item.K">
26
+ <van-checkbox :name="item.K">{{item.V}}</van-checkbox>
27
+ <van-radio-group v-model="item.type" direction="horizontal">
28
+ <van-radio name="asc">升序</van-radio>
29
+ <van-radio name="desc">降序</van-radio>
30
+ </van-radio-group>
31
+ </div>
32
+ </van-checkbox-group>
33
+ </template>
34
+ </van-popup>
35
+ <van-popup
36
+ ref="filterPopup"
37
+ v-model="filterPop"
38
+ position="bottom"
39
+ round
40
+ @close="closeFilterPop"
41
+ class="van-popup">
42
+ <div class="popup-item">
43
+ <slot name="filter" ></slot>
44
+ </div>
45
+ </van-popup>
46
+ </div>
47
+ </template>
48
+ <script>
49
+ import LamboIconButton from "@/components/lambo/btn/lambo-icon-button.vue";
50
+ import FiltrateRow from "@/components/lambo/card-item/filtrate-row.vue";
51
+
52
+ export default {
53
+ name: "LamboListFilter",
54
+ components: {
55
+ FiltrateRow,
56
+ LamboIconButton
57
+ },
58
+ props: {
59
+ showFilter: {
60
+ type: [Boolean, String],
61
+ default: true
62
+ },
63
+ orderColumns: {
64
+ type: Array,
65
+ default: () => ([
66
+ {
67
+ K: 'a',
68
+ V: '复选框 a'
69
+ },
70
+ {
71
+ K: 'b',
72
+ V: '复选框 b'
73
+ }
74
+ ])
75
+ }
76
+ },
77
+ data() {
78
+ return {
79
+ orderPop: false,
80
+ filterPop: false,
81
+ orderChecked: [],
82
+ orderData: []
83
+ }
84
+ },
85
+ methods: {
86
+ showOrderPop() {
87
+ this.orderPop = true
88
+ },
89
+ showFilterPop() {
90
+ this.filterPop = true
91
+ },
92
+ closeOrderPop() {
93
+ this.orderData = []
94
+ this.orderChecked.forEach((key) => {
95
+ const order = this.orderColumns.find(item => item.K === key)
96
+ const data = {
97
+ K: order.K,
98
+ type: order.type
99
+ }
100
+ this.orderData.push(data)
101
+ })
102
+ this.$emit('order-on-ok', this.orderData)
103
+ },
104
+ closeFilterPop() {
105
+ }
106
+ }
107
+ }
108
+ </script>
109
+ <style scoped>
110
+ .opt-btn {
111
+ display: flex;
112
+ justify-content: space-between;
113
+ margin-bottom: 10px;
114
+ }
115
+ .popup-item {
116
+ margin-top: 20px;
117
+ padding: 0 15px;
118
+ }
119
+ .van-popup {
120
+ min-height: 25%;
121
+ height: auto;
122
+ }
123
+ </style>
@@ -1,126 +1,126 @@
1
- .search-top-pop {
2
- min-height: 145px;
3
- max-height: 320px;
4
- background-color: var(--scl-white-1)
5
- }
6
-
7
- .search-body {
8
- border-top: none;
9
- min-height: 70px;
10
- max-height: 245px;
11
- overflow: auto;
12
- }
13
-
14
- .search-bottom-btn {
15
- padding: 18px 14px 14px 14px;
16
- }
17
-
18
-
19
- /*日期选择*/
20
- .search-row {
21
- display: flex;
22
- flex-direction: row;
23
- justify-content: flex-start;
24
- flex-wrap: nowrap;
25
- align-items: center;
26
- align-content: center;
27
- height: 70px;
28
- padding: 18px 0;
29
- margin: 0 14px;
30
- border-bottom: 1px solid var(--scl-white-2);
31
- border-top: none;
32
- }
33
-
34
- .search-input-title {
35
- height: 16px;
36
- font-size: 12px;
37
- color: var(--scl-gray-2);
38
- display: flex;
39
- justify-content: flex-start;
40
- align-items: center;
41
- margin-left: 12px;
42
- width: 76px;
43
- }
44
-
45
- .search-lambo-input {
46
- border: none;
47
- outline: none;
48
- background: none;
49
- height: 16px;
50
- font-size: 12px;
51
- color: var(--scl-gray-1);
52
- display: flex;
53
- justify-content: flex-start;
54
- align-items: center;
55
- margin-left: 8px;
56
- flex: 1;
57
- }
58
-
59
-
60
- /*输入框*/
61
-
62
- .search-lambo-input .van-cell {
63
- padding: 10px 0;
64
- }
65
-
66
-
67
- /*多选*/
68
-
69
- .search-top-div {
70
- display: flex;
71
- justify-content: space-between;
72
- height: 44px;
73
- line-height: 44px;
74
- width: 100%;
75
- position: fixed;
76
- z-index: 300;
77
- }
78
-
79
- .search-cancel-btn {
80
- border: none;
81
- color: var(--scl-gray-3);
82
- }
83
-
84
- .search-confirm-btn {
85
- border: none;
86
- color: var(--scl-blue);
87
- }
88
-
89
- .search-select-title {
90
- font-size: 16px;
91
- font-weight: bold;
92
- }
93
-
94
- /*修改单选多选的滚动条样式*/
95
- /deep/ .van-radio-group {
96
- position: relative;
97
- }
98
-
99
- /*修改单选多选的滚动条样式*/
100
- /deep/ .van-cell-group {
101
- padding-top: 44px;
102
- }
103
-
104
- /*修改单选多选的滚动条样式*/
105
- /deep/ .van-cell:first-child {
106
- padding-top: 10px;
107
- }
108
-
109
-
110
- /*滚动条样式*/
111
- /deep/ ::-webkit-scrollbar {
112
- width: 6px;
113
- }
114
-
115
- /*滚动条样式*/
116
- /deep/ ::-webkit-scrollbar-thumb {
117
- border-radius: var(--ind-border-radius-xl);
118
- background: rgba(45, 140, 240, 0.6);
119
- }
120
-
121
- /*滚动条样式*/
122
- /deep/ ::-webkit-scrollbar-track {
123
- -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.1);
124
- border-radius: var(--ind-border-radius-xl);
125
- background: rgba(231, 242, 250, 0.4);
1
+ .search-top-pop {
2
+ min-height: 145px;
3
+ max-height: 320px;
4
+ background-color: var(--scl-white-1)
5
+ }
6
+
7
+ .search-body {
8
+ border-top: none;
9
+ min-height: 70px;
10
+ max-height: 245px;
11
+ overflow: auto;
12
+ }
13
+
14
+ .search-bottom-btn {
15
+ padding: 18px 14px 14px 14px;
16
+ }
17
+
18
+
19
+ /*日期选择*/
20
+ .search-row {
21
+ display: flex;
22
+ flex-direction: row;
23
+ justify-content: flex-start;
24
+ flex-wrap: nowrap;
25
+ align-items: center;
26
+ align-content: center;
27
+ height: 70px;
28
+ padding: 18px 0;
29
+ margin: 0 14px;
30
+ border-bottom: 1px solid var(--scl-white-2);
31
+ border-top: none;
32
+ }
33
+
34
+ .search-input-title {
35
+ height: 16px;
36
+ font-size: 12px;
37
+ color: var(--scl-gray-2);
38
+ display: flex;
39
+ justify-content: flex-start;
40
+ align-items: center;
41
+ margin-left: 12px;
42
+ width: 76px;
43
+ }
44
+
45
+ .search-lambo-input {
46
+ border: none;
47
+ outline: none;
48
+ background: none;
49
+ height: 16px;
50
+ font-size: 12px;
51
+ color: var(--scl-gray-1);
52
+ display: flex;
53
+ justify-content: flex-start;
54
+ align-items: center;
55
+ margin-left: 8px;
56
+ flex: 1;
57
+ }
58
+
59
+
60
+ /*输入框*/
61
+
62
+ .search-lambo-input .van-cell {
63
+ padding: 10px 0;
64
+ }
65
+
66
+
67
+ /*多选*/
68
+
69
+ .search-top-div {
70
+ display: flex;
71
+ justify-content: space-between;
72
+ height: 44px;
73
+ line-height: 44px;
74
+ width: 100%;
75
+ position: fixed;
76
+ z-index: 300;
77
+ }
78
+
79
+ .search-cancel-btn {
80
+ border: none;
81
+ color: var(--scl-gray-3);
82
+ }
83
+
84
+ .search-confirm-btn {
85
+ border: none;
86
+ color: var(--scl-blue);
87
+ }
88
+
89
+ .search-select-title {
90
+ font-size: 16px;
91
+ font-weight: bold;
92
+ }
93
+
94
+ /*修改单选多选的滚动条样式*/
95
+ /deep/ .van-radio-group {
96
+ position: relative;
97
+ }
98
+
99
+ /*修改单选多选的滚动条样式*/
100
+ /deep/ .van-cell-group {
101
+ padding-top: 44px;
102
+ }
103
+
104
+ /*修改单选多选的滚动条样式*/
105
+ /deep/ .van-cell:first-child {
106
+ padding-top: 10px;
107
+ }
108
+
109
+
110
+ /*滚动条样式*/
111
+ /deep/ ::-webkit-scrollbar {
112
+ width: 6px;
113
+ }
114
+
115
+ /*滚动条样式*/
116
+ /deep/ ::-webkit-scrollbar-thumb {
117
+ border-radius: var(--ind-border-radius-xl);
118
+ background: rgba(45, 140, 240, 0.6);
119
+ }
120
+
121
+ /*滚动条样式*/
122
+ /deep/ ::-webkit-scrollbar-track {
123
+ -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.1);
124
+ border-radius: var(--ind-border-radius-xl);
125
+ background: rgba(231, 242, 250, 0.4);
126
126
  }
package/util/assist.js CHANGED
@@ -1,43 +1,43 @@
1
- // 深拷贝
2
- export function deepCopy(data) {
3
- let i;
4
- const t = typeOf(data);
5
- let o;
6
-
7
- if (t === 'array') {
8
- o = [];
9
- } else if (t === 'object') {
10
- o = {};
11
- } else {
12
- return data;
13
- }
14
-
15
- if (t === 'array') {
16
- for (i = 0; i < data.length; i++) {
17
- o.push(deepCopy(data[i]));
18
- }
19
- } else if (t === 'object') {
20
- for (i in data) {
21
- o[i] = deepCopy(data[i]);
22
- }
23
- }
24
- return o;
25
- }
26
-
27
- // 判断对象类型
28
- export function typeOf(obj) {
29
- const toString = Object.prototype.toString;
30
- const map = {
31
- '[object Boolean]': 'boolean',
32
- '[object Number]': 'number',
33
- '[object String]': 'string',
34
- '[object Function]': 'function',
35
- '[object Array]': 'array',
36
- '[object Date]': 'date',
37
- '[object RegExp]': 'regExp',
38
- '[object Undefined]': 'undefined',
39
- '[object Null]': 'null',
40
- '[object Object]': 'object'
41
- };
42
- return map[toString.call(obj)];
43
- }
1
+ // 深拷贝
2
+ export function deepCopy(data) {
3
+ let i;
4
+ const t = typeOf(data);
5
+ let o;
6
+
7
+ if (t === 'array') {
8
+ o = [];
9
+ } else if (t === 'object') {
10
+ o = {};
11
+ } else {
12
+ return data;
13
+ }
14
+
15
+ if (t === 'array') {
16
+ for (i = 0; i < data.length; i++) {
17
+ o.push(deepCopy(data[i]));
18
+ }
19
+ } else if (t === 'object') {
20
+ for (i in data) {
21
+ o[i] = deepCopy(data[i]);
22
+ }
23
+ }
24
+ return o;
25
+ }
26
+
27
+ // 判断对象类型
28
+ export function typeOf(obj) {
29
+ const toString = Object.prototype.toString;
30
+ const map = {
31
+ '[object Boolean]': 'boolean',
32
+ '[object Number]': 'number',
33
+ '[object String]': 'string',
34
+ '[object Function]': 'function',
35
+ '[object Array]': 'array',
36
+ '[object Date]': 'date',
37
+ '[object RegExp]': 'regExp',
38
+ '[object Undefined]': 'undefined',
39
+ '[object Null]': 'null',
40
+ '[object Object]': 'object'
41
+ };
42
+ return map[toString.call(obj)];
43
+ }
package/util/bus.js CHANGED
@@ -1,4 +1,4 @@
1
- import Vue from 'vue'
2
-
3
- const Bus = new Vue();
4
- export default Bus;
1
+ import Vue from 'vue'
2
+
3
+ const Bus = new Vue();
4
+ export default Bus;