@lambo-design/shared 1.0.0-beta.11 → 1.0.0-beta.13

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,10 +1,14 @@
1
1
  import themeDefault from "./theme-default";
2
2
  import themeGold from "./theme-gold";
3
3
  import themeLime from "./theme-lime";
4
+ import themeOrange from "./theme-orange";
5
+ import themeRed from "./theme-red";
4
6
 
5
7
 
6
8
  export default [
7
9
  themeDefault,
8
10
  themeGold,
9
- themeLime
11
+ themeLime,
12
+ themeOrange,
13
+ themeRed
10
14
  ]
@@ -0,0 +1,40 @@
1
+ export default {
2
+ key: "orange",
3
+ title: "魅力橙",
4
+ primaryColor: "#ee5414",
5
+ //自定义主题相关颜色覆盖
6
+ vars:
7
+ `
8
+ --primary-color: #ee5414;
9
+ --primary-color-tint-20: #f17643;
10
+ --primary-color-tint-90: #fdeee8;
11
+ --primary-color-tint-80: #fcddd0;
12
+ --primary-color-tint-5: #ef5d20;
13
+ --primary-color-tint-95-fade-50: rgba(254, 246, 243, 0.5);
14
+ --primary-color-fade-20: rgba(238, 84, 20, 0.2);
15
+ --primary-color-shade-5: #e25013;
16
+ --normal-color: rgba(254, 246, 243, 0);
17
+ --link-color: #ee5414;
18
+ --link-hover-color: #f17643;
19
+ --link-active-color: #e25013;
20
+ --selected-color: rgba(238, 84, 20, 0.9);
21
+ --selected-color-shade-10: rgba(210, 74, 18, 0.91);
22
+ --date-picker-cell-hover-bg: rgba(238, 84, 20, 0.3);
23
+ --btn-group-border: #e25013;
24
+ --btn-primary-bg: #ee5414;
25
+ --btn-primary-bg-tint-20: #f17643;
26
+ --btn-primary-bg-tint-5: #ef5d20;
27
+ --input-hover-border-color: #ee5414;
28
+ --input-hover-border-color-tint-20: #f17643;
29
+ --input-hover-border-color-fade-20: rgba(238, 84, 20, 0.2);
30
+ --input-focus-border-color: color:#ee5414;
31
+ --slider-color: #f17643;
32
+ `,
33
+ style:
34
+ `
35
+ html {
36
+ padding:0;
37
+ margin:0;
38
+ }
39
+ `
40
+ };
@@ -0,0 +1,40 @@
1
+ export default {
2
+ key: "read",
3
+ title: "发财红",
4
+ primaryColor: "#ff3457",
5
+ //自定义主题相关颜色覆盖
6
+ vars:
7
+ `
8
+ --primary-color: #ff3457;
9
+ --primary-color-tint-20: #ff5d79;
10
+ --primary-color-tint-90: #ffebee;
11
+ --primary-color-tint-80: #ffd6dd;
12
+ --primary-color-tint-5: #ff3e5f;
13
+ --primary-color-tint-95-fade-50: rgba(255, 245, 247, 0.5);
14
+ --primary-color-fade-20: rgba(255, 52, 87, 0.2);
15
+ --primary-color-shade-5: #f23153;
16
+ --normal-color: rgba(255, 245, 247, 0);
17
+ --link-color: #ff3457;
18
+ --link-hover-color: #ff5d79;
19
+ --link-active-color: #f23153;
20
+ --selected-color: rgba(255, 52, 87, 0.9);
21
+ --selected-color-shade-10: rgba(225, 46, 77, 0.9);
22
+ --date-picker-cell-hover-bg: rgba(255, 52, 87, 0.3);
23
+ --btn-group-border: #f23153;
24
+ --btn-primary-bg: #ff3457;
25
+ --btn-primary-bg-tint-20: #ff5d79;
26
+ --btn-primary-bg-tint-5: #ff3e5f;
27
+ --input-hover-border-color: #ff3457;
28
+ --input-hover-border-color-tint-20: #ff5d79;
29
+ --input-hover-border-color-fade-20: rgba(255, 52, 87, 0.2);
30
+ --input-focus-border-color: color:#ff3457;
31
+ --slider-color: #ff5d79;
32
+ `,
33
+ style:
34
+ `
35
+ html {
36
+ padding:0;
37
+ margin:0;
38
+ }
39
+ `
40
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lambo-design/shared",
3
- "version": "1.0.0-beta.11",
3
+ "version": "1.0.0-beta.13",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "author": "lambo",
@@ -9,6 +9,17 @@ export const hasRoute = ($router, name) => {
9
9
  let res = routes.filter(item => item.name === name)
10
10
  return res && res.length > 0
11
11
  }
12
+ /**
13
+ * 判断是否存在路由并且页面存在
14
+ * @param $router
15
+ * @param name
16
+ * @returns {*|boolean}
17
+ */
18
+ export const hasRouteAndComponent = ($router, name) => {
19
+ let routes = $router.getRoutes();
20
+ let res = routes.filter(item => item.name === name && item.component)
21
+ return res && res.length > 0
22
+ }
12
23
  /**
13
24
  * 动态生成菜单
14
25
  * @param permissionList