@lambo-design/shared 1.0.0-beta.83 → 1.0.0-beta.85

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.
@@ -1,4 +1,4 @@
1
- @primary-color : #0091FF;
1
+ @primary-color :#306BE3;
2
2
  @primary-color-tint-20 : tint(@primary-color,20%);
3
3
  @primary-color-tint-90 : tint(@primary-color,90%);
4
4
  @primary-color-tint-80 : tint(@primary-color,80%);
@@ -72,7 +72,7 @@
72
72
  @component-background : #fff;
73
73
  @font-family : "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;
74
74
  @code-family : Consolas,Menlo,Courier,monospace;
75
- @title-color : #17233d;
75
+ @title-color : rgb(2, 35, 76);
76
76
  @text-color : #666666;
77
77
  @text-color-secondary: fade(@black, 45%);
78
78
  @heading-color: fade(#000, 85%);
@@ -107,19 +107,25 @@
107
107
  @table-td-stripe-bg : #f2fafe;
108
108
  @table-td-hover-bg : #eaf4fe;
109
109
  @table-td-highlight-bg : #b5def3;
110
- @menu-dark-title : #333333;
111
- @menu-dark-active-bg : #363e4f;
110
+ @menu-dark-title : #306BE3;
111
+ @menu-dark-active-bg : rgb(0, 44, 107);
112
112
  @menu-dark-subsidiary-color : rgba(255,255,255,.7);
113
113
  @menu-dark-group-title-color : rgba(255,255,255,.36);
114
+ @menu-dark-item-selected-bg: rgb(2, 35, 76);
115
+ @menu-dark-bg: @menu-dark-active-bg ; // 侧边栏背景色
116
+ @menu-dark-item-active-bg: @menu-dark-bg; // 激活的一级菜单背景色
117
+ @menu-dark-submenu-bg: #0E356E; // 二级菜单背景色
118
+ @menu-dark-item-selected-bg: @menu-dark-bg; // 最内部的菜单背景色
114
119
  @date-picker-cell-hover-bg : #e1f0fe;
120
+ @menu-item-hover-bg: darken(@menu-dark-bg, 5%); // 鼠标悬停时稍暗一些的颜色
115
121
 
116
122
  // Shadow
117
- @shadow-color : rgba(0, 0, 0, .2);
123
+ @shadow-color : rgb(2, 35, 76);
118
124
  @shadow-base : @shadow-down;
119
- @shadow-card : 0 1px 1px 0 rgba(0,0,0,.1);
125
+ @shadow-card : 0 1px 1px 0 rgb(14, 53, 110);
120
126
  @shadow-up : 0 -1px 6px @shadow-color;
121
127
  @shadow-down : 0 1px 6px @shadow-color;
122
- @shadow-left : -1px 0 6px @shadow-color;
128
+ @shadow-left : -1px 0 6px rgb(2, 35, 76);
123
129
  @shadow-right : 1px 0 6px @shadow-color;
124
130
 
125
131
  // Button
@@ -189,12 +195,13 @@
189
195
  @grid-columns : 24;
190
196
  @grid-gutter-width : 0;
191
197
  @layout-body-background : #f5f7f9;
192
- @layout-header-background : #333333;
198
+ @layout-header-background : @primary-color;
199
+ @layout-header-selected-background: @primary-color; // 选中的顶部菜单背景颜色稍亮
193
200
  @layout-header-height : 64px;
194
201
  @layout-header-padding : 0 50px;
195
202
  @layout-footer-padding : 24px 50px;
196
203
  @layout-footer-background : @layout-body-background;
197
- @layout-sider-background : @layout-header-background;
204
+ @layout-sider-background : #002C6B;
198
205
  @layout-sider-background-tint-10 : tint(@layout-sider-background, 10%);
199
206
  @layout-trigger-height : 48px;
200
207
  @layout-trigger-color : #fff;
@@ -474,7 +481,7 @@ vxe-table
474
481
  @vxe-table-checkbox-range-border-color : #006af1;
475
482
  @vxe-table-checkbox-range-background-color : rgba(50, 128, 252, 0.2);
476
483
 
477
- @vxe-table-fixed-left-scrolling-box-shadow : 8px 0px 10px -5px rgba(0, 0, 0, 0.12);
484
+ @vxe-table-fixed-left-scrolling-box-shadow : 8px 0px 10px -5px rgb(14, 53, 110);
478
485
  @vxe-table-fixed-right-scrolling-box-shadow : -8px 0px 10px -5px rgba(0, 0, 0, 0.12);
479
486
 
480
487
  /*filter*/
@@ -621,8 +628,11 @@ vxe-table
621
628
  @vxe-switch-font-color : #fff;
622
629
  @vxe-switch-icon-background-color : #fff;
623
630
  @vxe-switch-open-background-color : @vxe-primary-color;
624
- @vxe-switch-close-background-color : rgba(0, 0, 0, 0.35);
625
- @vxe-switch-disabled-background-color : rgba(0, 0, 0, 0.15);
631
+ @vxe-switch-close-background-color : rgb(14, 53, 110);
632
+ @vxe-switch-disabled-background-color : rgb(14, 53, 120);
626
633
 
627
634
  /*pulldown*/
628
635
  @vxe-pulldown-panel-background-color : #fff;
636
+
637
+
638
+
@@ -60,7 +60,7 @@ export default {
60
60
  --component-background: #fff;
61
61
  --font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
62
62
  --code-family: Consolas, Menlo, Courier, monospace;
63
- --title-color: #17233d;
63
+ --title-color: fade(@black, 45%);
64
64
  --text-color: #515a6e;
65
65
  --text-color-secondary: rgba(0, 0, 0, 0.45);
66
66
  --heading-color: rgba(0, 0, 0, 0.85);
@@ -90,7 +90,7 @@ export default {
90
90
  --table-td-hover-bg: #ebf7ff;
91
91
  --table-td-highlight-bg: #ebf7ff;
92
92
  --menu-dark-title: #333333;
93
- --menu-dark-active-bg: #363e4f;
93
+ --menu-dark-active-bg:fade(#000, 85%);
94
94
  --menu-dark-subsidiary-color: rgba(255, 255, 255, 0.7);
95
95
  --menu-dark-group-title-color: rgba(255, 255, 255, 0.36);
96
96
  --date-picker-cell-hover-bg: #e1f0fe;
@@ -1,9 +1,9 @@
1
1
  export default {
2
2
  key: "eap",
3
3
  title: "深邃蓝",
4
- primaryColor: "#0091FF",
4
+ primaryColor: "#306BE3",
5
5
  vars: `
6
- --primary-color: #0091FF;
6
+ --primary-color: #306BE3;
7
7
  --primary-color-tint-20: #33a7ff;
8
8
  --primary-color-tint-90: #e6f4ff;
9
9
  --primary-color-tint-80: #cce9ff;
@@ -60,7 +60,7 @@ export default {
60
60
  --component-background: #fff;
61
61
  --font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
62
62
  --code-family: Consolas, Menlo, Courier, monospace;
63
- --title-color: #17233d;
63
+ --title-color: rgb(2, 35, 76);
64
64
  --text-color: #666666;
65
65
  --text-color-secondary: rgba(0, 0, 0, 0.45);
66
66
  --heading-color: rgba(0, 0, 0, 0.85);
@@ -89,18 +89,23 @@ export default {
89
89
  --table-td-stripe-bg: #f2fafe;
90
90
  --table-td-hover-bg: #eaf4fe;
91
91
  --table-td-highlight-bg: #b5def3;
92
- --menu-dark-title: #333333;
93
- --menu-dark-active-bg: #363e4f;
92
+ --menu-dark-title: #306BE3;
93
+ --menu-dark-item-active-bg: #02234C; /* 激活的一级菜单项 */
94
+ --menu-dark-submenu-bg: #0E356E; /* 二级菜单项 */
95
+ --menu-dark-item-selected-bg: rgb(2, 35, 76); /* 选中的内部菜单项 */
96
+ --menu-dark-bg:rgb(0, 44, 107);
97
+ --menu-dark-active-bg: rgb(0, 44, 107);
94
98
  --menu-dark-subsidiary-color: rgba(255, 255, 255, 0.7);
95
99
  --menu-dark-group-title-color: rgba(255, 255, 255, 0.36);
100
+ --menu-item-hover-bg: darken(@menu-dark-bg, 5%);
96
101
  --date-picker-cell-hover-bg: #e1f0fe;
97
- --shadow-color: rgba(0, 0, 0, 0.2);
98
- --shadow-base: 0 1px 6px rgba(0, 0, 0, 0.2);
99
- --shadow-card: 0 1px 1px 0 rgba(0, 0, 0, 0.1);
100
- --shadow-up: 0 -1px 6px rgba(0, 0, 0, 0.2);
101
- --shadow-down: 0 1px 6px rgba(0, 0, 0, 0.2);
102
- --shadow-left: -1px 0 6px rgba(0, 0, 0, 0.2);
103
- --shadow-right: 1px 0 6px rgba(0, 0, 0, 0.2);
102
+ --shadow-color: rgb(2, 35, 76);
103
+ --shadow-base: 0 1px 6px rgb(2, 35, 76);
104
+ --shadow-card: 0 1px 1px 0 rgb(14, 53, 110);
105
+ --shadow-up: 0 -1px 6px rgb(2, 35, 76);
106
+ --shadow-down: 0 1px 6px rgb(2, 35, 76);
107
+ --shadow-left: -1px 0 6px rgb(2, 35, 76);
108
+ --shadow-right: 1px 0 6px rgb(2, 35, 76);
104
109
  --btn-height-base: 26px;
105
110
  --btn-height-large: 32px;
106
111
  --btn-height-small: 20px;
@@ -155,12 +160,13 @@ export default {
155
160
  --grid-columns: 24;
156
161
  --grid-gutter-width: 0;
157
162
  --layout-body-background: #f5f7f9;
158
- --layout-header-background: #333333;
163
+ --layout-header-background: #306BE3;
159
164
  --layout-header-height: 64px;
165
+ --layout-header-selected-background: #306BE3;
160
166
  --layout-header-padding: 0 50px;
161
167
  --layout-footer-padding: 24px 50px;
162
168
  --layout-footer-background: #f5f7f9;
163
- --layout-sider-background: #333333;
169
+ --layout-sider-background: #002C6B;
164
170
  --layout-sider-background-tint-10: #474747;
165
171
  --layout-trigger-height: 48px;
166
172
  --layout-trigger-color: #fff;
@@ -374,7 +380,7 @@ export default {
374
380
  --vxe-table-checkbox-range-border-width: 1px;
375
381
  --vxe-table-checkbox-range-border-color: #006af1;
376
382
  --vxe-table-checkbox-range-background-color: rgba(50, 128, 252, 0.2);
377
- --vxe-table-fixed-left-scrolling-box-shadow: 8px 0px 10px -5px rgba(0, 0, 0, 0.12);
383
+ --vxe-table-fixed-left-scrolling-box-shadow: 8px 0px 10px -5px rgb(14, 53, 110);
378
384
  --vxe-table-fixed-right-scrolling-box-shadow: -8px 0px 10px -5px rgba(0, 0, 0, 0.12);
379
385
  /*filter*/
380
386
  --vxe-table-filter-panel-background-color: #fff;
@@ -512,4 +518,5 @@ export default {
512
518
  margin:0;
513
519
  }
514
520
  `
521
+
515
522
  };
package/package.json CHANGED
@@ -1,23 +1,23 @@
1
- {
2
- "name": "@lambo-design/shared",
3
- "version": "1.0.0-beta.83",
4
- "description": "",
5
- "main": "index.js",
6
- "author": "lambo",
7
- "license": "ISC",
8
- "publishConfig": {
9
- "access": "public",
10
- "registry": "https://registry.npmjs.org/"
11
- },
12
- "dependencies": {
13
- "axios": "^0.24.0",
14
- "axios-cache-plugin": "^0.1.0",
15
- "classnames": "^2.3.1",
16
- "css-vars-ponyfill": "^2.4.8",
17
- "moment": "2.29.4",
18
- "qs": "^6.11.0",
19
- "xlsx": "http://cicd.lambo.top/package/cdn/xlsx-0.19.1.tgz",
20
- "xlsx-style": "^0.8.13"
21
- },
22
- "scripts": {}
23
- }
1
+ {
2
+ "name": "@lambo-design/shared",
3
+ "version": "1.0.0-beta.85",
4
+ "description": "",
5
+ "main": "index.js",
6
+ "scripts": {},
7
+ "author": "lambo",
8
+ "license": "ISC",
9
+ "publishConfig": {
10
+ "access": "public",
11
+ "registry": "https://registry.npmjs.org/"
12
+ },
13
+ "dependencies": {
14
+ "axios": "^0.24.0",
15
+ "axios-cache-plugin": "^0.1.0",
16
+ "classnames": "^2.3.1",
17
+ "css-vars-ponyfill": "^2.4.8",
18
+ "moment": "2.29.4",
19
+ "qs": "^6.11.0",
20
+ "xlsx": "http://cicd.lambo.top/package/cdn/xlsx-0.19.1.tgz",
21
+ "xlsx-style": "^0.8.13"
22
+ }
23
+ }
@@ -1,20 +1,20 @@
1
- export const builtInDictKeys = [
2
- 'SEX_ENUM',
3
- 'WHETHER_ENUM'
4
- ]
5
-
6
- export const builtInDictMap = {
7
- 'SEX_ENUM' : { '0': '女', '1': '男' },
8
- 'WHETHER_ENUM' : { '0': '否', '1': '是' }
9
- }
10
-
11
- export const builtInDictList = {
12
- 'SEX_ENUM' : [
13
- { K: '0', V: '女' },
14
- { K: '1', V: '男' },
15
- ],
16
- 'WHETHER_ENUM' : [
17
- { K: '0', V: '否' },
18
- { K: '1', V: '是' },
19
- ]
20
- }
1
+ export const builtInDictKeys = [
2
+ 'SEX_ENUM',
3
+ 'WHETHER_ENUM'
4
+ ]
5
+
6
+ export const builtInDictMap = {
7
+ 'SEX_ENUM' : { '0': '女', '1': '男' },
8
+ 'WHETHER_ENUM' : { '0': '否', '1': '是' }
9
+ }
10
+
11
+ export const builtInDictList = {
12
+ 'SEX_ENUM' : [
13
+ { K: '0', V: '女' },
14
+ { K: '1', V: '男' },
15
+ ],
16
+ 'WHETHER_ENUM' : [
17
+ { K: '0', V: '否' },
18
+ { K: '1', V: '是' },
19
+ ]
20
+ }
@@ -1,75 +1,75 @@
1
- import config from '../../config/config'
2
- import ajax from '../ajax'
3
- import { builtInDictKeys, builtInDictMap, builtInDictList} from './built-in-dict'
4
- import { setSessionStorage, getSessionStorage} from "../platform";
5
-
6
- export async function getAllDict(dictIdArray) {
7
- if (dictIdArray.length > 0) {
8
- try {
9
- const { data } = await ajax.get(`${config.upmsServerContext}/manage/acDict/getDictsForMulti`, { params: { dictIds : dictIdArray.join(",") } })
10
- let result = {}
11
- if (data.code == 1) {
12
- let dictList = data.data;
13
- for (let key in dictList) {
14
- let dicts = dictList[key]
15
- result[key] = {};
16
- if (dicts.length > 0) {
17
- result[key]['enumList'] = dicts
18
- setSessionStorage(key + '_LIST', dicts)
19
- let dictMap = {}
20
- for(let dict of dicts) {
21
- dictMap[dict.K] = dict.V;
22
- }
23
- result[key]['enumData'] = dictMap
24
- setSessionStorage(key + '_MAP', dictMap)
25
- } else if (builtInDictKeys.includes(key)) {
26
- let dicts = builtInDictList[key]
27
- result[key]['enumList'] = dicts
28
- setSessionStorage(key + '_LIST', dicts)
29
- let dictMap = {}
30
- for(let dict of dicts) {
31
- dictMap[dict.K] = dict.V;
32
- }
33
- result[key]['enumData'] = dictMap
34
- setSessionStorage(key + '_MAP', dictMap)
35
- }
36
- }
37
- }
38
- return result
39
- } catch (error) {
40
- console.error(`getDictsForMulti error dictId=${dictIdArray}`, error)
41
- }
42
- }
43
- }
44
-
45
- export async function getDictList(dictId) {
46
- if (builtInDictKeys.includes(dictId)) {
47
- return builtInDictList[dictId]
48
- }
49
- const dictValue = getSessionStorage(dictId + '_LIST')
50
- if (!!dictValue) {
51
- return dictValue
52
- }
53
- let data = await getAllDict([dictId]);
54
- return data[dictId];
55
- }
56
-
57
- export async function getDictMap(dictId) {
58
- if (builtInDictKeys.includes(dictId)) {
59
- return builtInDictMap[dictId]
60
- }
61
- const dictValue = getSessionStorage(dictId + '_MAP')
62
- if (!!dictValue) {
63
- return dictValue
64
- }
65
-
66
- try {
67
- const { data } = await ajax.get(`${config.upmsServerContext}/manage/acDict/getDictsMap`, { params: { dictId : dictId } })
68
- if (data.code == 1) {
69
- setSessionStorage(dictId + '_MAP', data.data)
70
- }
71
- return data.data
72
- } catch (error) {
73
- console.error(`getDictsMap error dictId=${dictId}`, error)
74
- }
75
- }
1
+ import config from '../../config/config'
2
+ import ajax from '../ajax'
3
+ import { builtInDictKeys, builtInDictMap, builtInDictList} from './built-in-dict'
4
+ import { setSessionStorage, getSessionStorage} from "../platform";
5
+
6
+ export async function getAllDict(dictIdArray) {
7
+ if (dictIdArray.length > 0) {
8
+ try {
9
+ const { data } = await ajax.get(`${config.upmsServerContext}/manage/acDict/getDictsForMulti`, { params: { dictIds : dictIdArray.join(",") } })
10
+ let result = {}
11
+ if (data.code == 1) {
12
+ let dictList = data.data;
13
+ for (let key in dictList) {
14
+ let dicts = dictList[key]
15
+ result[key] = {};
16
+ if (dicts.length > 0) {
17
+ result[key]['enumList'] = dicts
18
+ setSessionStorage(key + '_LIST', dicts)
19
+ let dictMap = {}
20
+ for(let dict of dicts) {
21
+ dictMap[dict.K] = dict.V;
22
+ }
23
+ result[key]['enumData'] = dictMap
24
+ setSessionStorage(key + '_MAP', dictMap)
25
+ } else if (builtInDictKeys.includes(key)) {
26
+ let dicts = builtInDictList[key]
27
+ result[key]['enumList'] = dicts
28
+ setSessionStorage(key + '_LIST', dicts)
29
+ let dictMap = {}
30
+ for(let dict of dicts) {
31
+ dictMap[dict.K] = dict.V;
32
+ }
33
+ result[key]['enumData'] = dictMap
34
+ setSessionStorage(key + '_MAP', dictMap)
35
+ }
36
+ }
37
+ }
38
+ return result
39
+ } catch (error) {
40
+ console.error(`getDictsForMulti error dictId=${dictIdArray}`, error)
41
+ }
42
+ }
43
+ }
44
+
45
+ export async function getDictList(dictId) {
46
+ if (builtInDictKeys.includes(dictId)) {
47
+ return builtInDictList[dictId]
48
+ }
49
+ const dictValue = getSessionStorage(dictId + '_LIST')
50
+ if (!!dictValue) {
51
+ return dictValue
52
+ }
53
+ let data = await getAllDict([dictId]);
54
+ return data[dictId];
55
+ }
56
+
57
+ export async function getDictMap(dictId) {
58
+ if (builtInDictKeys.includes(dictId)) {
59
+ return builtInDictMap[dictId]
60
+ }
61
+ const dictValue = getSessionStorage(dictId + '_MAP')
62
+ if (!!dictValue) {
63
+ return dictValue
64
+ }
65
+
66
+ try {
67
+ const { data } = await ajax.get(`${config.upmsServerContext}/manage/acDict/getDictsMap`, { params: { dictId : dictId } })
68
+ if (data.code == 1) {
69
+ setSessionStorage(dictId + '_MAP', data.data)
70
+ }
71
+ return data.data
72
+ } catch (error) {
73
+ console.error(`getDictsMap error dictId=${dictId}`, error)
74
+ }
75
+ }