@bdlite/domains 1.1.23 → 1.1.25
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/es/layout/constants.js +8 -1
- package/es/sider/constants.js +3 -0
- package/es/sider/plugin.js +14 -0
- package/package.json +2 -2
package/es/layout/constants.js
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
1
|
export const CHANNEL_NAME = 'layout'
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// 初始值
|
|
4
|
+
export const LAYOUT_MODE = {
|
|
5
|
+
HEADER: 'header',
|
|
6
|
+
SIDER: 'sider',
|
|
7
|
+
BOTH: 'both',
|
|
8
|
+
}
|
|
9
|
+
export const DEFAULT_LAYOUT_MODE = LAYOUT_MODE.HEADER
|
|
10
|
+
export const DEFAULT_LAYOUT_DATA = { systemName: '', layoutMode: DEFAULT_LAYOUT_MODE }
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { isObject } from '@bdlite/strategy'
|
|
2
|
+
import { createObservableKit, createSubChannelKit } from '@bdlite/observable/es/create-observable-kit'
|
|
3
|
+
|
|
4
|
+
import { PLUGIN_CHANNEL_NAME, DEFAULT_TOP_SHOW } from './constants'
|
|
5
|
+
|
|
6
|
+
const { getData, publish } = createObservableKit({ topShow: DEFAULT_TOP_SHOW }, null, { channelName: PLUGIN_CHANNEL_NAME })
|
|
7
|
+
const { subscribe } = createSubChannelKit({ channelName: PLUGIN_CHANNEL_NAME })
|
|
8
|
+
|
|
9
|
+
export const subscribeSiderPluginStatus = subscribe
|
|
10
|
+
export function publishSiderPluginStatus(data) {
|
|
11
|
+
if (isObject(data)) {
|
|
12
|
+
publish({ ...getData(), ...data })
|
|
13
|
+
}
|
|
14
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bdlite/domains",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.25",
|
|
4
4
|
"description": "A domains entity collection library driven by @bdlite/observable",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"DDD",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"@bdlite/strategy": "^1.1.0"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@bdlite/helpers": "^1.1.
|
|
28
|
+
"@bdlite/helpers": "^1.1.24",
|
|
29
29
|
"@bdlite/observable": "^1.1.20",
|
|
30
30
|
"@bdlite/strategy": "^1.1.22"
|
|
31
31
|
},
|