wl-design-mobile 0.0.1 → 0.0.2

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.
Files changed (53) hide show
  1. package/api/doc.js +25 -0
  2. package/api/x1.js +56 -0
  3. package/btn/lambo-big-button.vue +125 -121
  4. package/btn/lambo-button-group.vue +47 -47
  5. package/btn/lambo-medium-button.vue +123 -121
  6. package/btn/lambo-small-button-group.vue +31 -31
  7. package/btn/lambo-small-button-select.vue +53 -53
  8. package/btn/lambo-small-button.vue +123 -121
  9. package/card-item/card-row-icon.vue +0 -1
  10. package/card-item/filtrate-row.vue +1 -0
  11. package/collapse/lambo-collapse.vue +80 -80
  12. package/config/config.js +14 -0
  13. package/detail/lambo-detail-grid.vue +87 -57
  14. package/detail/lambo-detail-row.vue +59 -59
  15. package/doc/file/lambo-file-upload.vue +176 -179
  16. package/doc/file/styles/css/index.css +118 -118
  17. package/doc/img/lambo-img-upload.vue +109 -109
  18. package/edit/list/Lambo-edit-list.vue +90 -90
  19. package/edit/list/lambo-edit-card-group.vue +103 -103
  20. package/edit/select/lambo-edit-date-range.vue +135 -135
  21. package/edit/select/lambo-edit-date-time.vue +105 -0
  22. package/edit/select/lambo-edit-date.vue +108 -108
  23. package/edit/select/lambo-edit-input-textarea.vue +92 -92
  24. package/edit/select/lambo-edit-input.vue +92 -92
  25. package/edit/select/lambo-edit-multi-select.vue +160 -160
  26. package/edit/select/lambo-edit-single-select.vue +153 -153
  27. package/flow/lambo-flow-detail.vue +30 -30
  28. package/flow/lambo-flow-edit.vue +30 -30
  29. package/icon/lambo-required-red-star.vue +47 -47
  30. package/list/lambo-list.vue +1 -1
  31. package/nav/lambo-top-nav.vue +89 -89
  32. package/package.json +4 -2
  33. package/search/lambo-date-range-page.vue +191 -191
  34. package/search/lambo-date-range.vue +107 -107
  35. package/search/lambo-input.vue +74 -74
  36. package/search/lambo-multi-select.vue +125 -125
  37. package/search/lambo-org-select-page.vue +109 -109
  38. package/search/lambo-search-box.vue +55 -55
  39. package/search/lambo-single-select.vue +119 -119
  40. package/styles/base.less +75 -75
  41. package/styles/components/btn.less +7 -7
  42. package/styles/components/search.less +33 -33
  43. package/styles/components/tag.less +181 -181
  44. package/styles/index.less +4 -4
  45. package/tag/lambo-tag.vue +25 -0
  46. package/title/lambo-title1.vue +129 -129
  47. package/title/lambo-title2.vue +37 -37
  48. package/util/assist.js +43 -0
  49. package/util/axios/cacheconf.js +19 -0
  50. package/util/axios/index.js +11 -0
  51. package/util/axios/interceptors.js +101 -0
  52. package/util/bus.js +4 -0
  53. package/util/token.js +36 -0
@@ -1,55 +1,55 @@
1
- <template>
2
- <div @click="change">
3
- <van-popup v-model:show="popShow" class="search-top-pop" position="top" :safe-area-inset-bottom="true">
4
- <div class="search-body">
5
- <slot name="content"></slot>
6
- </div>
7
- <div class="search-bottom-btn">
8
- <slot name="btn"></slot>
9
- </div>
10
- </van-popup>
11
- </div>
12
- </template>
13
- <script>
14
-
15
- export default {
16
- name: "LamboTopSearchPop",
17
- components: {},
18
- props: {
19
- show: {
20
- type: Boolean,
21
- default: false
22
- }
23
- },
24
- data() {
25
- return {
26
- popShow: false,
27
- }
28
- },
29
- watch: {
30
- show: function (newVal) {
31
- this.popShow = newVal
32
- },
33
- popShow: function (newVal) {
34
- this.$emit("on-close", newVal)
35
- },
36
- },
37
- methods: {
38
- change() {
39
- let searchRows = document.querySelectorAll('.search-row')
40
- Array.from(searchRows).forEach(function (row, index) {
41
- row.addEventListener('click', function () {
42
- Array.from(searchRows).forEach(function (row) {
43
- row.style.borderBottom = '1px solid var(--scl-white-2)'
44
- })
45
- row.style.borderBottom = '1px solid var(--scl-blue)'
46
- })
47
- })
48
- }
49
- }
50
- }
51
- </script>
52
- <style scoped>
53
- @import "../styles/index.less";
54
- @import "./styles/css/index.css";
55
- </style>
1
+ <template>
2
+ <div @click="change">
3
+ <van-popup v-model:show="popShow" class="search-top-pop" position="top" :safe-area-inset-bottom="true">
4
+ <div class="search-body">
5
+ <slot name="content"></slot>
6
+ </div>
7
+ <div class="search-bottom-btn">
8
+ <slot name="btn"></slot>
9
+ </div>
10
+ </van-popup>
11
+ </div>
12
+ </template>
13
+ <script>
14
+
15
+ export default {
16
+ name: "LamboTopSearchPop",
17
+ components: {},
18
+ props: {
19
+ show: {
20
+ type: Boolean,
21
+ default: false
22
+ }
23
+ },
24
+ data() {
25
+ return {
26
+ popShow: false,
27
+ }
28
+ },
29
+ watch: {
30
+ show: function (newVal) {
31
+ this.popShow = newVal
32
+ },
33
+ popShow: function (newVal) {
34
+ this.$emit("on-close", newVal)
35
+ },
36
+ },
37
+ methods: {
38
+ change() {
39
+ let searchRows = document.querySelectorAll('.search-row')
40
+ Array.from(searchRows).forEach(function (row, index) {
41
+ row.addEventListener('click', function () {
42
+ Array.from(searchRows).forEach(function (row) {
43
+ row.style.borderBottom = '1px solid var(--scl-white-2)'
44
+ })
45
+ row.style.borderBottom = '1px solid var(--scl-blue)'
46
+ })
47
+ })
48
+ }
49
+ }
50
+ }
51
+ </script>
52
+ <style scoped>
53
+ @import "../styles/index.less";
54
+ @import "./styles/css/index.css";
55
+ </style>
@@ -1,119 +1,119 @@
1
- <template>
2
- <div>
3
- <div class="search-row">
4
- <lambo-required-red-star :required="required"></lambo-required-red-star>
5
- <div class="search-input-title">{{ title }}</div>
6
- <div class="search-lambo-input">{{ valName }}</div>
7
- <lambo-vector-icon v-if="icon" :icon="icon" @click="onOpen"></lambo-vector-icon>
8
- </div>
9
- <div>
10
- <van-popup v-model:show="showBottom" :style="{ height: '31%' }" position="bottom">
11
- <van-radio-group v-model="selectItem.K">
12
- <div class="search-top-div">
13
- <van-button class="search-cancel-btn" size="normal" @click="cancel">取消</van-button>
14
- <span class="search-select-title">请选择</span>
15
- <van-button class="search-confirm-btn" size="normal" @click="onConfirm">确认</van-button>
16
- </div>
17
- <van-cell-group>
18
- <van-cell v-for="(c, index) in data" :key="index" :title="`${c.V}`" clickable @click="radioClick(c)">
19
- <template #right-icon>
20
- <van-radio :name="c.K" checked-color="#0070D2"/>
21
- </template>
22
- </van-cell>
23
- </van-cell-group>
24
- </van-radio-group>
25
- </van-popup>
26
- </div>
27
- </div>
28
- </template>
29
- <script>
30
- import {Toast} from 'vant'
31
- import LamboVectorIcon from '@/components/lambo/icon/lambo-vector-icon.vue'
32
- import LamboRequiredRedStar from '@/components/lambo/icon/lambo-required-red-star.vue'
33
-
34
- export default {
35
- name: "LamboSingleSelect",
36
- components: {LamboRequiredRedStar, LamboVectorIcon},
37
- props: {
38
- required: {
39
- type: Boolean,
40
- default: false
41
- },
42
- icon: {
43
- type: String,
44
- default: 'arrow-right-big.png'
45
- },
46
- title: {
47
- type: String,
48
- default: false
49
- },
50
- data: {
51
- type: Array,
52
- default: () => ([])
53
- },
54
- defaultItem: {
55
- type: Object
56
- }
57
- },
58
- data() {
59
- return {
60
- showBottom: false,
61
- val: '',
62
- valName: '',
63
- selectItem: {
64
- K: '',
65
- V: ''
66
- },
67
- firstLoad: true
68
- }
69
- },
70
- watch: {
71
- defaultItem: {
72
- handler: function (val, oldVal) {
73
- console.log("single-select -- defaultItem -- val,oldVal,firstLoad:", {val, oldVal, "firstLoad": this.firstLoad})
74
- if (val && val.K && this.firstLoad === true) {
75
- this.val = val.K
76
- this.valName = val.V
77
- this.selectItem.K = val.K
78
- this.selectItem.V = val.V
79
- this.firstLoad = false
80
- }
81
- },
82
- deep: true,
83
- immediate: true,
84
- }
85
- },
86
- methods: {
87
- onOpen() {
88
- this.showBottom = true
89
- },
90
- cancel() {
91
- this.showBottom = false
92
- },
93
- onConfirm() {
94
- if (this.selectItem && this.selectItem.K) {
95
- this.val = this.selectItem.K
96
- this.valName = this.selectItem.V
97
- this.$emit("on-ok", this.selectItem)
98
- } else {
99
- Toast.fail("查询条件选择失败,请联系管理员");
100
- console.error("single-select -- 查询条件选择失败,this.selectItem:", this.selectItem)
101
- this.val = ''
102
- this.valName = ''
103
- this.$emit("on-ok", {K: '', V: ''})
104
- }
105
- this.showBottom = false
106
- },
107
- radioClick(data) {
108
- if (data && data.K) {
109
- this.selectItem.K = data.K
110
- this.selectItem.V = data.V
111
- }
112
- }
113
- }
114
- }
115
- </script>
116
- <style scoped>
117
- @import "../styles/index.less";
118
- @import "./styles/css/index.css";
119
- </style>
1
+ <template>
2
+ <div>
3
+ <div class="search-row">
4
+ <lambo-required-red-star :required="required"></lambo-required-red-star>
5
+ <div class="search-input-title">{{ title }}</div>
6
+ <div class="search-lambo-input">{{ valName }}</div>
7
+ <lambo-vector-icon v-if="icon" :icon="icon" @click="onOpen"></lambo-vector-icon>
8
+ </div>
9
+ <div>
10
+ <van-popup v-model:show="showBottom" :style="{ height: '31%' }" position="bottom">
11
+ <van-radio-group v-model="selectItem.K">
12
+ <div class="search-top-div">
13
+ <van-button class="search-cancel-btn" size="normal" @click="cancel">取消</van-button>
14
+ <span class="search-select-title">请选择</span>
15
+ <van-button class="search-confirm-btn" size="normal" @click="onConfirm">确认</van-button>
16
+ </div>
17
+ <van-cell-group>
18
+ <van-cell v-for="(c, index) in data" :key="index" :title="`${c.V}`" clickable @click="radioClick(c)">
19
+ <template #right-icon>
20
+ <van-radio :name="c.K" checked-color="#0070D2"/>
21
+ </template>
22
+ </van-cell>
23
+ </van-cell-group>
24
+ </van-radio-group>
25
+ </van-popup>
26
+ </div>
27
+ </div>
28
+ </template>
29
+ <script>
30
+ import {Toast} from 'vant'
31
+ import LamboVectorIcon from '../icon/lambo-vector-icon.vue'
32
+ import LamboRequiredRedStar from '../icon/lambo-required-red-star.vue'
33
+
34
+ export default {
35
+ name: "LamboSingleSelect",
36
+ components: {LamboRequiredRedStar, LamboVectorIcon},
37
+ props: {
38
+ required: {
39
+ type: Boolean,
40
+ default: false
41
+ },
42
+ icon: {
43
+ type: String,
44
+ default: 'arrow-right-big.png'
45
+ },
46
+ title: {
47
+ type: String,
48
+ default: false
49
+ },
50
+ data: {
51
+ type: Array,
52
+ default: () => ([])
53
+ },
54
+ defaultItem: {
55
+ type: Object
56
+ }
57
+ },
58
+ data() {
59
+ return {
60
+ showBottom: false,
61
+ val: '',
62
+ valName: '',
63
+ selectItem: {
64
+ K: '',
65
+ V: ''
66
+ },
67
+ firstLoad: true
68
+ }
69
+ },
70
+ watch: {
71
+ defaultItem: {
72
+ handler: function (val, oldVal) {
73
+ console.log("single-select -- defaultItem -- val,oldVal,firstLoad:", {val, oldVal, "firstLoad": this.firstLoad})
74
+ if (val && val.K && this.firstLoad === true) {
75
+ this.val = val.K
76
+ this.valName = val.V
77
+ this.selectItem.K = val.K
78
+ this.selectItem.V = val.V
79
+ this.firstLoad = false
80
+ }
81
+ },
82
+ deep: true,
83
+ immediate: true,
84
+ }
85
+ },
86
+ methods: {
87
+ onOpen() {
88
+ this.showBottom = true
89
+ },
90
+ cancel() {
91
+ this.showBottom = false
92
+ },
93
+ onConfirm() {
94
+ if (this.selectItem && this.selectItem.K) {
95
+ this.val = this.selectItem.K
96
+ this.valName = this.selectItem.V
97
+ this.$emit("on-ok", this.selectItem)
98
+ } else {
99
+ Toast.fail("查询条件选择失败,请联系管理员");
100
+ console.error("single-select -- 查询条件选择失败,this.selectItem:", this.selectItem)
101
+ this.val = ''
102
+ this.valName = ''
103
+ this.$emit("on-ok", {K: '', V: ''})
104
+ }
105
+ this.showBottom = false
106
+ },
107
+ radioClick(data) {
108
+ if (data && data.K) {
109
+ this.selectItem.K = data.K
110
+ this.selectItem.V = data.V
111
+ }
112
+ }
113
+ }
114
+ }
115
+ </script>
116
+ <style scoped>
117
+ @import "../styles/index.less";
118
+ @import "./styles/css/index.css";
119
+ </style>
package/styles/base.less CHANGED
@@ -1,75 +1,75 @@
1
- :root {
2
- --scl-blue: #0070D2;
3
- --scl-blue-1: #0062FB;
4
- --scl-blue-2: #448AFF;
5
- --scl-blue-3: #338DDB;
6
- --scl-blue-4: #CBE2FB;
7
- --scl-blue-5: #e6efff;
8
-
9
- --scl-green-1: #129456;
10
- --scl-green-2: #CFEEDB;
11
- --scl-green-3: #e9f6ed;
12
-
13
- --scl-orange: #FF9A22;
14
- --scl-orange-1: #EB6821;
15
- --scl-orange-2: #FBE1D0;
16
- --scl-orange-3: #FDF0E8;
17
-
18
- --scl-purple-1: #695AC0;
19
- --scl-purple-2: #5760C4;
20
- --scl-purple-3: #8C77F7;
21
- --scl-purple-4: #EFECFD;
22
-
23
- --scl-white-1: #FFFFFF;
24
- --scl-white-2: #E5E5E5;
25
- --scl-white-3: #e9eaec;
26
- --scl-white-4: #F5F5F5FF;
27
- --scl-white-5: #EDEDEDFF;
28
- --scl-white-6: #D7D7D7;
29
-
30
- --scl-gray-1: #333333;
31
- --scl-gray-2: #666666;
32
- --scl-gray-3: #797979;
33
- --scl-gray-4: #999999;
34
- --scl-gray-5: #CCCCCC;
35
- --scl-gray-6: #DDDDDD;
36
-
37
- --scl-red-1: #e84c6b;
38
- --scl-red-2: #fb6d5f;
39
-
40
- --scl-lucency: #FFFFFF00;
41
- --scl-lucency-1: #323233;
42
-
43
- --ind-padding-base: 4px;
44
- --ind-padding-tiny: 6px;
45
- --ind-padding-xs: 8px;
46
- --ind-padding-xs-extra: 10px;
47
- --ind-padding-sm-minus: 12px;
48
- --ind-padding-sm-small: 14px;
49
- --ind-padding-sm: 16px;
50
- --ind-padding-md: 24px;
51
- --ind-padding-lg: 32px;
52
- --ind-padding-xl: 48px;
53
- --ind-padding-xxl: 56px;
54
-
55
- --ind-font-size-xs: 10px;
56
- --ind-font-size-sm: 12px;
57
- --ind-font-size-md: 14px;
58
- --ind-font-size-lg: 16px;
59
- --ind-font-size-xl: 18px;
60
- --ind-font-size-xxl: 20px;
61
- --ind-font-weight-normal: 400;
62
- --ind-font-weight-bold: 600;
63
- --ind-font-weight-bolder: 900;
64
-
65
- --ind-border-width-base: 1px;
66
- --ind-border-radius-xs: 2px;
67
- --ind-border-radius-sm: 4px;
68
- --ind-border-radius-md: 8px;
69
- --ind-border-radius-lg: 14px;
70
- --ind-border-radius-xl: 20px;
71
- --ind-border-radius-xxl: 32px;
72
- --ind-border-radius-max: 999px;
73
- --ind-border-radius-round: 50%;
74
-
75
- }
1
+ :root {
2
+ --scl-blue: #0070D2;
3
+ --scl-blue-1: #0062FB;
4
+ --scl-blue-2: #448AFF;
5
+ --scl-blue-3: #338DDB;
6
+ --scl-blue-4: #CBE2FB;
7
+ --scl-blue-5: #e6efff;
8
+
9
+ --scl-green-1: #129456;
10
+ --scl-green-2: #CFEEDB;
11
+ --scl-green-3: #e9f6ed;
12
+
13
+ --scl-orange: #FF9A22;
14
+ --scl-orange-1: #EB6821;
15
+ --scl-orange-2: #FBE1D0;
16
+ --scl-orange-3: #FDF0E8;
17
+
18
+ --scl-purple-1: #695AC0;
19
+ --scl-purple-2: #5760C4;
20
+ --scl-purple-3: #8C77F7;
21
+ --scl-purple-4: #EFECFD;
22
+
23
+ --scl-white-1: #FFFFFF;
24
+ --scl-white-2: #E5E5E5;
25
+ --scl-white-3: #e9eaec;
26
+ --scl-white-4: #F5F5F5FF;
27
+ --scl-white-5: #EDEDEDFF;
28
+ --scl-white-6: #D7D7D7;
29
+
30
+ --scl-gray-1: #333333;
31
+ --scl-gray-2: #666666;
32
+ --scl-gray-3: #797979;
33
+ --scl-gray-4: #999999;
34
+ --scl-gray-5: #CCCCCC;
35
+ --scl-gray-6: #DDDDDD;
36
+
37
+ --scl-red-1: #e84c6b;
38
+ --scl-red-2: #fb6d5f;
39
+
40
+ --scl-lucency: #FFFFFF00;
41
+ --scl-lucency-1: #323233;
42
+
43
+ --ind-padding-base: 4px;
44
+ --ind-padding-tiny: 6px;
45
+ --ind-padding-xs: 8px;
46
+ --ind-padding-xs-extra: 10px;
47
+ --ind-padding-sm-minus: 12px;
48
+ --ind-padding-sm-small: 14px;
49
+ --ind-padding-sm: 16px;
50
+ --ind-padding-md: 24px;
51
+ --ind-padding-lg: 32px;
52
+ --ind-padding-xl: 48px;
53
+ --ind-padding-xxl: 56px;
54
+
55
+ --ind-font-size-xs: 10px;
56
+ --ind-font-size-sm: 12px;
57
+ --ind-font-size-md: 14px;
58
+ --ind-font-size-lg: 16px;
59
+ --ind-font-size-xl: 18px;
60
+ --ind-font-size-xxl: 20px;
61
+ --ind-font-weight-normal: 400;
62
+ --ind-font-weight-bold: 600;
63
+ --ind-font-weight-bolder: 900;
64
+
65
+ --ind-border-width-base: 1px;
66
+ --ind-border-radius-xs: 2px;
67
+ --ind-border-radius-sm: 4px;
68
+ --ind-border-radius-md: 8px;
69
+ --ind-border-radius-lg: 14px;
70
+ --ind-border-radius-xl: 20px;
71
+ --ind-border-radius-xxl: 32px;
72
+ --ind-border-radius-max: 999px;
73
+ --ind-border-radius-round: 50%;
74
+
75
+ }
@@ -1,7 +1,7 @@
1
- .btn {
2
- border: none;
3
- min-width: 60px;
4
- height: 30px;
5
- font-size: 11px;
6
- border-radius: 3px;
7
- }
1
+ .btn {
2
+ border: none;
3
+ min-width: 60px;
4
+ height: 30px;
5
+ font-size: 11px;
6
+ border-radius: 3px;
7
+ }
@@ -1,33 +1,33 @@
1
- .btn-bg-search {
2
- width: 49%;
3
- padding-top: 10px;
4
- padding-bottom: 10px;
5
- margin-left: 1%;
6
- font-size: 14px;
7
- color: var(--scl-white-1);
8
- border-radius: 6px;
9
- background-color: var(--scl-blue);
10
- border: none;
11
- }
12
-
13
- .btn-bg-search:active {
14
- background-color: #EDEDED;
15
- box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
16
- }
17
-
18
- .btn-white-search {
19
- width: 49%;
20
- padding-top: 10px;
21
- padding-bottom: 10px;
22
- margin-right: 1%;
23
- font-size: 14px;
24
- color: var(--scl-blue);
25
- border-radius: 6px;
26
- background-color: var(--scl-white-4);
27
- border: 1px solid var(--scl-blue);
28
- }
29
-
30
- .btn-white-search:active {
31
- background-color: #2279D6;
32
- box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.2);
33
- }
1
+ .btn-bg-search {
2
+ width: 49%;
3
+ padding-top: 10px;
4
+ padding-bottom: 10px;
5
+ margin-left: 1%;
6
+ font-size: 14px;
7
+ color: var(--scl-white-1);
8
+ border-radius: 6px;
9
+ background-color: var(--scl-blue);
10
+ border: none;
11
+ }
12
+
13
+ .btn-bg-search:active {
14
+ background-color: #EDEDED;
15
+ box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
16
+ }
17
+
18
+ .btn-white-search {
19
+ width: 49%;
20
+ padding-top: 10px;
21
+ padding-bottom: 10px;
22
+ margin-right: 1%;
23
+ font-size: 14px;
24
+ color: var(--scl-blue);
25
+ border-radius: 6px;
26
+ background-color: var(--scl-white-4);
27
+ border: 1px solid var(--scl-blue);
28
+ }
29
+
30
+ .btn-white-search:active {
31
+ background-color: #2279D6;
32
+ box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.2);
33
+ }