@common-stack/client-react 0.5.1-alpha.3 → 0.5.1-alpha.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/lib/interfaces/menu.d.ts
CHANGED
package/lib/interfaces/menu.js
CHANGED
|
@@ -8,5 +8,10 @@ var IMenuPosition;
|
|
|
8
8
|
IMenuPosition["MIDDLE"] = "MIDDLE";
|
|
9
9
|
IMenuPosition["LOWER"] = "LOWER";
|
|
10
10
|
IMenuPosition["BOTTOM"] = "BOTTOM";
|
|
11
|
+
IMenuPosition["Logo"] = "LOGO";
|
|
12
|
+
IMenuPosition["Upper"] = "UPPER";
|
|
13
|
+
IMenuPosition["Middle"] = "MIDDLE";
|
|
14
|
+
IMenuPosition["Lower"] = "LOWER";
|
|
15
|
+
IMenuPosition["Bottom"] = "BOTTOM";
|
|
11
16
|
})(IMenuPosition = exports.IMenuPosition || (exports.IMenuPosition = {}));
|
|
12
17
|
//# sourceMappingURL=menu.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"menu.js","sourceRoot":"","sources":["../../src/interfaces/menu.tsx"],"names":[],"mappings":";;;AAsGA,IAAY,
|
|
1
|
+
{"version":3,"file":"menu.js","sourceRoot":"","sources":["../../src/interfaces/menu.tsx"],"names":[],"mappings":";;;AAsGA,IAAY,aAWX;AAXD,WAAY,aAAa;IACrB,8BAAa,CAAA;IACb,gCAAe,CAAA;IACf,kCAAiB,CAAA;IACjB,gCAAe,CAAA;IACf,kCAAiB,CAAA;IACjB,8BAAa,CAAA;IACb,gCAAe,CAAA;IACf,kCAAiB,CAAA;IACjB,gCAAe,CAAA;IACf,kCAAiB,CAAA;AACrB,CAAC,EAXW,aAAa,GAAb,qBAAa,KAAb,qBAAa,QAWxB"}
|
package/lib/route/get-routes.js
CHANGED
|
@@ -31,13 +31,13 @@ function getRoutes(path, routeData, authWrapper = null) {
|
|
|
31
31
|
return menuPath.indexOf(searchPath) === 0 || menuPath === path;
|
|
32
32
|
});
|
|
33
33
|
const mappedMenuPaths = routes.map(mPath => {
|
|
34
|
-
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.
|
|
34
|
+
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.Middle }, routeData[mPath]);
|
|
35
35
|
});
|
|
36
36
|
const root = {
|
|
37
37
|
// just to satisfy types added following
|
|
38
38
|
// TOOD need to correct types so we don't have to enter them.
|
|
39
39
|
name: 'root',
|
|
40
|
-
position: interfaces_1.IMenuPosition.
|
|
40
|
+
position: interfaces_1.IMenuPosition.Logo,
|
|
41
41
|
};
|
|
42
42
|
mappedMenuPaths.forEach(routeItem => {
|
|
43
43
|
const children = routeItem.route.split('/');
|
|
@@ -25,13 +25,13 @@ function getMenus(path, menuData) {
|
|
|
25
25
|
return menuPath.indexOf(searchPath) === 0 || menuPath === path;
|
|
26
26
|
});
|
|
27
27
|
const mappedMenuPaths = routes.map(mPath => {
|
|
28
|
-
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.
|
|
28
|
+
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.Middle }, menuData[mPath]);
|
|
29
29
|
});
|
|
30
30
|
const root = {
|
|
31
31
|
// just to satisfy types added following
|
|
32
32
|
// TOOD need to correct types so we don't have to enter them.
|
|
33
33
|
name: 'root',
|
|
34
|
-
position: interfaces_1.IMenuPosition.
|
|
34
|
+
position: interfaces_1.IMenuPosition.Logo,
|
|
35
35
|
};
|
|
36
36
|
mappedMenuPaths.forEach(menutItem => {
|
|
37
37
|
const children = menutItem.route.split('/');
|
|
@@ -50,13 +50,13 @@ function getNavigation(path, routeData, authWrapper) {
|
|
|
50
50
|
return menuPath.indexOf(searchPath) === 0 || menuPath === path;
|
|
51
51
|
});
|
|
52
52
|
const mappedMenuPaths = childrens.map(mPath => {
|
|
53
|
-
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.
|
|
53
|
+
return Object.assign({ route: mPath, position: interfaces_1.IMenuPosition.Middle }, routeData[mPath]);
|
|
54
54
|
});
|
|
55
55
|
const root = {
|
|
56
56
|
// just to satisfy types added following
|
|
57
57
|
// TOOD need to correct types so we don't have to enter them.
|
|
58
58
|
name: 'root',
|
|
59
|
-
position: interfaces_1.IMenuPosition.
|
|
59
|
+
position: interfaces_1.IMenuPosition.Logo,
|
|
60
60
|
};
|
|
61
61
|
mappedMenuPaths.forEach(routeItem => {
|
|
62
62
|
var _a, _b, _c;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@common-stack/client-react",
|
|
3
|
-
"version": "0.5.1-alpha.
|
|
3
|
+
"version": "0.5.1-alpha.4",
|
|
4
4
|
"description": "browser plugin for git",
|
|
5
5
|
"homepage": "https://github.com/cdmbase/fullstack-pro#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -28,8 +28,8 @@
|
|
|
28
28
|
"watch": "npm run build:lib:watch"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@common-stack/client-core": "0.5.1-alpha.
|
|
32
|
-
"@common-stack/core": "0.5.1-alpha.
|
|
31
|
+
"@common-stack/client-core": "0.5.1-alpha.4",
|
|
32
|
+
"@common-stack/core": "0.5.1-alpha.4",
|
|
33
33
|
"@wordpress/hooks": "^2.10.0",
|
|
34
34
|
"browser-bunyan": "^1.6.3",
|
|
35
35
|
"history-with-query": "^4.10.4",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"publishConfig": {
|
|
49
49
|
"access": "public"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "23a35da8b66525121fee75983535c241332987ec",
|
|
52
52
|
"typescript": {
|
|
53
53
|
"definition": "lib/index.d.ts"
|
|
54
54
|
}
|