@hamak/ui-store-impl 0.4.19 → 0.5.1
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/dist/autosave/autosave-config-resolver.d.ts +45 -0
- package/dist/autosave/autosave-config-resolver.d.ts.map +1 -0
- package/dist/autosave/autosave-config-resolver.js +107 -0
- package/dist/autosave/autosave-middleware.d.ts +37 -0
- package/dist/autosave/autosave-middleware.d.ts.map +1 -0
- package/dist/autosave/autosave-middleware.js +297 -0
- package/dist/autosave/autosave-registry.d.ts +15 -0
- package/dist/autosave/autosave-registry.d.ts.map +1 -0
- package/dist/autosave/autosave-registry.js +33 -0
- package/dist/autosave/autosave-sync-middleware.d.ts +24 -0
- package/dist/autosave/autosave-sync-middleware.d.ts.map +1 -0
- package/dist/autosave/autosave-sync-middleware.js +98 -0
- package/dist/autosave/index.d.ts +8 -0
- package/dist/autosave/index.d.ts.map +1 -0
- package/dist/autosave/index.js +7 -0
- package/dist/core/store-manager.d.ts +1 -1
- package/dist/core/store-manager.d.ts.map +1 -1
- package/dist/core/store-manager.js +21 -15
- package/dist/es2015/autosave/autosave-config-resolver.js +110 -0
- package/dist/es2015/autosave/autosave-middleware.js +311 -0
- package/dist/es2015/autosave/autosave-registry.js +33 -0
- package/dist/es2015/autosave/autosave-sync-middleware.js +98 -0
- package/dist/es2015/autosave/index.js +7 -0
- package/dist/es2015/core/store-manager.js +21 -15
- package/dist/es2015/fs/commands/fs-commands.js +36 -7
- package/dist/es2015/fs/core/fs-adapter.js +16 -5
- package/dist/es2015/index.js +3 -6
- package/dist/es2015/plugin/store-plugin-factory.js +12 -0
- package/dist/fs/commands/fs-commands.d.ts +13 -2
- package/dist/fs/commands/fs-commands.d.ts.map +1 -1
- package/dist/fs/commands/fs-commands.js +39 -7
- package/dist/fs/core/fs-adapter.d.ts +4 -1
- package/dist/fs/core/fs-adapter.d.ts.map +1 -1
- package/dist/fs/core/fs-adapter.js +16 -5
- package/dist/index.d.ts +2 -6
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -6
- package/dist/plugin/store-plugin-factory.d.ts.map +1 -1
- package/dist/plugin/store-plugin-factory.js +12 -0
- package/package.json +8 -24
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Store Manager Implementation
|
|
3
3
|
*/
|
|
4
|
-
import {
|
|
4
|
+
import { configureStore } from '@reduxjs/toolkit';
|
|
5
5
|
import { MiddlewareRegistry } from './middleware-registry';
|
|
6
6
|
import { ReducerRegistry } from './reducer-registry';
|
|
7
7
|
export class StoreManager {
|
|
@@ -46,20 +46,26 @@ export class StoreManager {
|
|
|
46
46
|
const rootReducer = this.reducerRegistry.getCombinedReducer();
|
|
47
47
|
// Create enhancers
|
|
48
48
|
const enhancers = config.enhancers || [];
|
|
49
|
-
//
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
49
|
+
// Create store using configureStore (modern Redux Toolkit API)
|
|
50
|
+
this.store = configureStore({
|
|
51
|
+
reducer: rootReducer,
|
|
52
|
+
preloadedState: config.preloadedState,
|
|
53
|
+
// Use only our custom middleware (disabling Redux Toolkit defaults to maintain exact behavior)
|
|
54
|
+
middleware: (getDefaultMiddleware) => getDefaultMiddleware({
|
|
55
|
+
// Disable all default middleware to maintain exact parity with old createStore behavior
|
|
56
|
+
thunk: false,
|
|
57
|
+
serializableCheck: false,
|
|
58
|
+
immutableCheck: false,
|
|
59
|
+
actionCreatorCheck: false,
|
|
60
|
+
}).concat(...middleware),
|
|
61
|
+
// Add custom enhancers if provided
|
|
62
|
+
enhancers: (getDefaultEnhancers) => getDefaultEnhancers().concat(enhancers),
|
|
63
|
+
// Configure DevTools with trace support
|
|
64
|
+
devTools: config.devTools !== false ? {
|
|
65
|
+
trace: true,
|
|
66
|
+
traceLimit: 25,
|
|
67
|
+
} : false,
|
|
68
|
+
});
|
|
63
69
|
this.initialized = true;
|
|
64
70
|
console.log('[StoreManager] Store initialized with:', {
|
|
65
71
|
reducers: this.reducerRegistry.getAllRegistrations().map(r => r.key),
|
|
@@ -28,10 +28,14 @@ export function getFileSystemNode(fsNode, path) {
|
|
|
28
28
|
/**
|
|
29
29
|
* Create a directory node
|
|
30
30
|
*/
|
|
31
|
-
function createDirectoryNode(step) {
|
|
31
|
+
function createDirectoryNode(step, extensionStates) {
|
|
32
|
+
const state = fileSystemNodeInitialState();
|
|
33
|
+
if (extensionStates) {
|
|
34
|
+
state.extensionStates = Object.assign(Object.assign({}, state.extensionStates), extensionStates);
|
|
35
|
+
}
|
|
32
36
|
return {
|
|
33
37
|
type: 'directory',
|
|
34
|
-
state
|
|
38
|
+
state,
|
|
35
39
|
name: step,
|
|
36
40
|
children: {}
|
|
37
41
|
};
|
|
@@ -39,7 +43,10 @@ function createDirectoryNode(step) {
|
|
|
39
43
|
/**
|
|
40
44
|
* Create a file node
|
|
41
45
|
*/
|
|
42
|
-
function createFileNode(name, content, schema, state) {
|
|
46
|
+
function createFileNode(name, content, schema, state, extensionStates) {
|
|
47
|
+
if (extensionStates) {
|
|
48
|
+
state.extensionStates = Object.assign(Object.assign({}, state.extensionStates), extensionStates);
|
|
49
|
+
}
|
|
43
50
|
return { type: 'file', name, content, schema, state };
|
|
44
51
|
}
|
|
45
52
|
/**
|
|
@@ -56,10 +63,11 @@ export class FileSystemCommandHandler {
|
|
|
56
63
|
case 'update-file-content': return this.executeContentCommand(state, command);
|
|
57
64
|
case 'set-file-content': return this.executeSetContentCommand(state, command);
|
|
58
65
|
case 'remove': return this.executeRemove(state, command);
|
|
66
|
+
case 'set-extension-state': return this.executeSetExtensionState(state, command);
|
|
59
67
|
}
|
|
60
68
|
}
|
|
61
69
|
executeMkdir(state, command) {
|
|
62
|
-
const { path, parents } = command;
|
|
70
|
+
const { path, parents, extensionStates } = command;
|
|
63
71
|
const steps = pathSteps(path);
|
|
64
72
|
return produce(state, draft => {
|
|
65
73
|
const { root } = draft;
|
|
@@ -69,7 +77,7 @@ export class FileSystemCommandHandler {
|
|
|
69
77
|
if (i + 1 === steps.length) {
|
|
70
78
|
// Last step is the element to create
|
|
71
79
|
if (dir.children[step] === undefined) {
|
|
72
|
-
dir.children[step] = createDirectoryNode(step);
|
|
80
|
+
dir.children[step] = createDirectoryNode(step, extensionStates);
|
|
73
81
|
}
|
|
74
82
|
}
|
|
75
83
|
else {
|
|
@@ -116,7 +124,7 @@ export class FileSystemCommandHandler {
|
|
|
116
124
|
});
|
|
117
125
|
}
|
|
118
126
|
executeSetFile(state, command) {
|
|
119
|
-
const { path, content, schema, override, contentIsPresent } = command;
|
|
127
|
+
const { path, content, schema, override, contentIsPresent, extensionStates } = command;
|
|
120
128
|
const steps = pathSteps(path);
|
|
121
129
|
return produce(state, draft => {
|
|
122
130
|
const { root } = draft;
|
|
@@ -129,7 +137,7 @@ export class FileSystemCommandHandler {
|
|
|
129
137
|
const last = steps[steps.length - 1];
|
|
130
138
|
const child = parentDir.children[last];
|
|
131
139
|
if (child === undefined || override === true) {
|
|
132
|
-
parentDir.children[last] = createFileNode(last, content, schema, fileSystemNodeInitialState(contentIsPresent));
|
|
140
|
+
parentDir.children[last] = createFileNode(last, content, schema, fileSystemNodeInitialState(contentIsPresent), extensionStates);
|
|
133
141
|
}
|
|
134
142
|
else {
|
|
135
143
|
console.warn(`File already exists at location`, path);
|
|
@@ -210,6 +218,27 @@ export class FileSystemCommandHandler {
|
|
|
210
218
|
}
|
|
211
219
|
});
|
|
212
220
|
}
|
|
221
|
+
executeSetExtensionState(state, command) {
|
|
222
|
+
const { path, key, state: extensionState } = command;
|
|
223
|
+
return produce(state, draft => {
|
|
224
|
+
const { root } = draft;
|
|
225
|
+
const node = getFileSystemNode(root, path);
|
|
226
|
+
if (node !== undefined) {
|
|
227
|
+
if (node.state === undefined) {
|
|
228
|
+
node.state = fileSystemNodeInitialState();
|
|
229
|
+
}
|
|
230
|
+
if (node.state.extensionStates === undefined) {
|
|
231
|
+
node.state.extensionStates = {};
|
|
232
|
+
}
|
|
233
|
+
// Merge the new state with existing state for this key
|
|
234
|
+
const existing = node.state.extensionStates[key];
|
|
235
|
+
node.state.extensionStates[key] = Object.assign(Object.assign({}, existing), extensionState);
|
|
236
|
+
}
|
|
237
|
+
else {
|
|
238
|
+
console.warn(`No node found at location`, path);
|
|
239
|
+
}
|
|
240
|
+
});
|
|
241
|
+
}
|
|
213
242
|
current(o) {
|
|
214
243
|
if (o === null || o === undefined) {
|
|
215
244
|
return o;
|
|
@@ -63,12 +63,14 @@ export class FileSystemNodeActions {
|
|
|
63
63
|
this._removeType = `${this.sliceName}/removeNode`;
|
|
64
64
|
this._updateFileContentType = `${this.sliceName}/updateFileContent`;
|
|
65
65
|
this._setFileContentType = `${this.sliceName}/setFileContent`;
|
|
66
|
+
this._setExtensionStateType = `${this.sliceName}/setExtensionState`;
|
|
66
67
|
this.actionTypeSet = new Set([
|
|
67
68
|
this._mkdirType,
|
|
68
69
|
this._setFileType,
|
|
69
70
|
this._removeType,
|
|
70
71
|
this._updateFileContentType,
|
|
71
|
-
this._setFileContentType
|
|
72
|
+
this._setFileContentType,
|
|
73
|
+
this._setExtensionStateType
|
|
72
74
|
]);
|
|
73
75
|
}
|
|
74
76
|
get mkdirType() {
|
|
@@ -86,20 +88,23 @@ export class FileSystemNodeActions {
|
|
|
86
88
|
get setFileContentType() {
|
|
87
89
|
return this._setFileContentType;
|
|
88
90
|
}
|
|
91
|
+
get setExtensionStateType() {
|
|
92
|
+
return this._setExtensionStateType;
|
|
93
|
+
}
|
|
89
94
|
isFileSystemNodeAction(action) {
|
|
90
95
|
return this.actionTypeSet.has(action.type);
|
|
91
96
|
}
|
|
92
|
-
mkdir(path, parents) {
|
|
97
|
+
mkdir(path, parents, extensionStates) {
|
|
93
98
|
return {
|
|
94
99
|
type: this.mkdirType,
|
|
95
|
-
command: { name: 'mkdir', path, parents }
|
|
100
|
+
command: { name: 'mkdir', path, parents, extensionStates }
|
|
96
101
|
};
|
|
97
102
|
}
|
|
98
103
|
setFile(path, content, schema, params = { override: true, contentIsPresent: true }) {
|
|
99
|
-
const { override, contentIsPresent } = params;
|
|
104
|
+
const { override, contentIsPresent, extensionStates } = params;
|
|
100
105
|
return {
|
|
101
106
|
type: this.setFileType,
|
|
102
|
-
command: { name: 'set-file', path, content, schema, override, contentIsPresent }
|
|
107
|
+
command: { name: 'set-file', path, content, schema, override, contentIsPresent, extensionStates }
|
|
103
108
|
};
|
|
104
109
|
}
|
|
105
110
|
updateFileContent(path, contentCommand) {
|
|
@@ -120,4 +125,10 @@ export class FileSystemNodeActions {
|
|
|
120
125
|
command: { name: 'remove', path, recursive }
|
|
121
126
|
};
|
|
122
127
|
}
|
|
128
|
+
setExtensionState(path, key, state) {
|
|
129
|
+
return {
|
|
130
|
+
type: this.setExtensionStateType,
|
|
131
|
+
command: { name: 'set-extension-state', path, key, state }
|
|
132
|
+
};
|
|
133
|
+
}
|
|
123
134
|
}
|
package/dist/es2015/index.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* Concrete implementations of Redux store management
|
|
2
|
+
* @deprecated This package is deprecated. Please migrate to @hamak/ui-store
|
|
4
3
|
*/
|
|
5
|
-
|
|
6
|
-
export * from '
|
|
7
|
-
export * from './plugin';
|
|
8
|
-
export * from './fs';
|
|
4
|
+
console.warn('[@hamak/ui-store-impl] This package is deprecated. Please migrate to @hamak/ui-store');
|
|
5
|
+
export * from '@hamak/ui-store';
|
|
@@ -63,6 +63,18 @@ export function createStorePlugin(config = {}) {
|
|
|
63
63
|
middleware,
|
|
64
64
|
});
|
|
65
65
|
}
|
|
66
|
+
// Call middlewareFactory if provided, passing the fileSystemAdapter
|
|
67
|
+
if (config.middlewareFactory) {
|
|
68
|
+
const factoryMiddleware = config.middlewareFactory(fileSystemAdapter);
|
|
69
|
+
if (factoryMiddleware === null || factoryMiddleware === void 0 ? void 0 : factoryMiddleware.length) {
|
|
70
|
+
extensionsCollector.register('ui-store-config:middleware-factory', {
|
|
71
|
+
middleware: factoryMiddleware.map((mw) => {
|
|
72
|
+
var _a;
|
|
73
|
+
return (Object.assign(Object.assign({}, mw), { plugin: (_a = mw.plugin) !== null && _a !== void 0 ? _a : 'ui-store-config' }));
|
|
74
|
+
}),
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
}
|
|
66
78
|
if (config.reducers && Object.keys(config.reducers).length) {
|
|
67
79
|
extensionsCollector.register('ui-store-config:reducers', {
|
|
68
80
|
reducers: config.reducers,
|
|
@@ -5,7 +5,7 @@ import { DataUpdater } from '../utils/data-updater';
|
|
|
5
5
|
* Base interface for filesystem commands
|
|
6
6
|
*/
|
|
7
7
|
export interface FsCommandBase {
|
|
8
|
-
name: 'mkdir' | 'set-file' | 'remove' | 'update-file-content' | 'set-file-content';
|
|
8
|
+
name: 'mkdir' | 'set-file' | 'remove' | 'update-file-content' | 'set-file-content' | 'set-extension-state';
|
|
9
9
|
path: string | string[];
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
@@ -14,6 +14,7 @@ export interface FsCommandBase {
|
|
|
14
14
|
export interface MkdirCommand extends FsCommandBase {
|
|
15
15
|
name: 'mkdir';
|
|
16
16
|
parents?: boolean;
|
|
17
|
+
extensionStates?: Record<string, unknown>;
|
|
17
18
|
}
|
|
18
19
|
/**
|
|
19
20
|
* Remove file or directory command
|
|
@@ -31,6 +32,7 @@ export interface SetFileCommand extends FsCommandBase {
|
|
|
31
32
|
schema: FileContentSchema;
|
|
32
33
|
override?: boolean;
|
|
33
34
|
contentIsPresent?: boolean;
|
|
35
|
+
extensionStates?: Record<string, unknown>;
|
|
34
36
|
}
|
|
35
37
|
/**
|
|
36
38
|
* Update file content with structure command
|
|
@@ -47,10 +49,18 @@ export interface SetFileContentCommand extends FsCommandBase {
|
|
|
47
49
|
content: any;
|
|
48
50
|
fromRemote?: boolean;
|
|
49
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* Set extension state on a node
|
|
54
|
+
*/
|
|
55
|
+
export interface SetExtensionStateCommand extends FsCommandBase {
|
|
56
|
+
name: 'set-extension-state';
|
|
57
|
+
key: string;
|
|
58
|
+
state: Record<string, unknown>;
|
|
59
|
+
}
|
|
50
60
|
/**
|
|
51
61
|
* Union type for all filesystem commands
|
|
52
62
|
*/
|
|
53
|
-
export type FileSystemCommand = MkdirCommand | RemoveCommand | SetFileCommand | UpdateFileContentCommand | SetFileContentCommand;
|
|
63
|
+
export type FileSystemCommand = MkdirCommand | RemoveCommand | SetFileCommand | UpdateFileContentCommand | SetFileContentCommand | SetExtensionStateCommand;
|
|
54
64
|
export { pathSteps, parentPathSteps } from '@hamak/shared-utils';
|
|
55
65
|
/**
|
|
56
66
|
* Get filesystem node at path
|
|
@@ -68,6 +78,7 @@ export declare class FileSystemCommandHandler {
|
|
|
68
78
|
private executeContentCommand;
|
|
69
79
|
private contentMayChange;
|
|
70
80
|
private executeSetContentCommand;
|
|
81
|
+
private executeSetExtensionState;
|
|
71
82
|
protected current<T = any>(o: T): T;
|
|
72
83
|
protected original<T = any>(o: T): T | undefined;
|
|
73
84
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fs-commands.d.ts","sourceRoot":"","sources":["../../../src/fs/commands/fs-commands.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,QAAQ,EACR,cAAc,EACd,eAAe,EACf,iBAAiB,EAGlB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAIpD;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAG,OAAO,GAAG,UAAU,GAAG,QAAQ,GAAG,qBAAqB,GAAG,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"fs-commands.d.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AO,EAAE,oBAAoB;IAoBtD,OAAO,CAAC,aAAa;IAUrB,OAAO,CAAC,UAAU;IAUlB,OAAO,CAAC,UAAU;IAOlB,OAAO,CAAC,aAAa;IAUrB;;OAEG;IACI,YAAY,CAAC,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,GAAG,IAAI;CAKxD"}
|
|
@@ -28,10 +28,14 @@ export function getFileSystemNode(fsNode, path) {
|
|
|
28
28
|
/**
|
|
29
29
|
* Create a directory node
|
|
30
30
|
*/
|
|
31
|
-
function createDirectoryNode(step) {
|
|
31
|
+
function createDirectoryNode(step, extensionStates) {
|
|
32
|
+
const state = fileSystemNodeInitialState();
|
|
33
|
+
if (extensionStates) {
|
|
34
|
+
state.extensionStates = { ...state.extensionStates, ...extensionStates };
|
|
35
|
+
}
|
|
32
36
|
return {
|
|
33
37
|
type: 'directory',
|
|
34
|
-
state
|
|
38
|
+
state,
|
|
35
39
|
name: step,
|
|
36
40
|
children: {}
|
|
37
41
|
};
|
|
@@ -39,7 +43,10 @@ function createDirectoryNode(step) {
|
|
|
39
43
|
/**
|
|
40
44
|
* Create a file node
|
|
41
45
|
*/
|
|
42
|
-
function createFileNode(name, content, schema, state) {
|
|
46
|
+
function createFileNode(name, content, schema, state, extensionStates) {
|
|
47
|
+
if (extensionStates) {
|
|
48
|
+
state.extensionStates = { ...state.extensionStates, ...extensionStates };
|
|
49
|
+
}
|
|
43
50
|
return { type: 'file', name, content, schema, state };
|
|
44
51
|
}
|
|
45
52
|
/**
|
|
@@ -56,10 +63,11 @@ export class FileSystemCommandHandler {
|
|
|
56
63
|
case 'update-file-content': return this.executeContentCommand(state, command);
|
|
57
64
|
case 'set-file-content': return this.executeSetContentCommand(state, command);
|
|
58
65
|
case 'remove': return this.executeRemove(state, command);
|
|
66
|
+
case 'set-extension-state': return this.executeSetExtensionState(state, command);
|
|
59
67
|
}
|
|
60
68
|
}
|
|
61
69
|
executeMkdir(state, command) {
|
|
62
|
-
const { path, parents } = command;
|
|
70
|
+
const { path, parents, extensionStates } = command;
|
|
63
71
|
const steps = pathSteps(path);
|
|
64
72
|
return produce(state, draft => {
|
|
65
73
|
const { root } = draft;
|
|
@@ -69,7 +77,7 @@ export class FileSystemCommandHandler {
|
|
|
69
77
|
if (i + 1 === steps.length) {
|
|
70
78
|
// Last step is the element to create
|
|
71
79
|
if (dir.children[step] === undefined) {
|
|
72
|
-
dir.children[step] = createDirectoryNode(step);
|
|
80
|
+
dir.children[step] = createDirectoryNode(step, extensionStates);
|
|
73
81
|
}
|
|
74
82
|
}
|
|
75
83
|
else {
|
|
@@ -116,7 +124,7 @@ export class FileSystemCommandHandler {
|
|
|
116
124
|
});
|
|
117
125
|
}
|
|
118
126
|
executeSetFile(state, command) {
|
|
119
|
-
const { path, content, schema, override, contentIsPresent } = command;
|
|
127
|
+
const { path, content, schema, override, contentIsPresent, extensionStates } = command;
|
|
120
128
|
const steps = pathSteps(path);
|
|
121
129
|
return produce(state, draft => {
|
|
122
130
|
const { root } = draft;
|
|
@@ -129,7 +137,7 @@ export class FileSystemCommandHandler {
|
|
|
129
137
|
const last = steps[steps.length - 1];
|
|
130
138
|
const child = parentDir.children[last];
|
|
131
139
|
if (child === undefined || override === true) {
|
|
132
|
-
parentDir.children[last] = createFileNode(last, content, schema, fileSystemNodeInitialState(contentIsPresent));
|
|
140
|
+
parentDir.children[last] = createFileNode(last, content, schema, fileSystemNodeInitialState(contentIsPresent), extensionStates);
|
|
133
141
|
}
|
|
134
142
|
else {
|
|
135
143
|
console.warn(`File already exists at location`, path);
|
|
@@ -210,6 +218,30 @@ export class FileSystemCommandHandler {
|
|
|
210
218
|
}
|
|
211
219
|
});
|
|
212
220
|
}
|
|
221
|
+
executeSetExtensionState(state, command) {
|
|
222
|
+
const { path, key, state: extensionState } = command;
|
|
223
|
+
return produce(state, draft => {
|
|
224
|
+
const { root } = draft;
|
|
225
|
+
const node = getFileSystemNode(root, path);
|
|
226
|
+
if (node !== undefined) {
|
|
227
|
+
if (node.state === undefined) {
|
|
228
|
+
node.state = fileSystemNodeInitialState();
|
|
229
|
+
}
|
|
230
|
+
if (node.state.extensionStates === undefined) {
|
|
231
|
+
node.state.extensionStates = {};
|
|
232
|
+
}
|
|
233
|
+
// Merge the new state with existing state for this key
|
|
234
|
+
const existing = node.state.extensionStates[key];
|
|
235
|
+
node.state.extensionStates[key] = {
|
|
236
|
+
...existing,
|
|
237
|
+
...extensionState
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
else {
|
|
241
|
+
console.warn(`No node found at location`, path);
|
|
242
|
+
}
|
|
243
|
+
});
|
|
244
|
+
}
|
|
213
245
|
current(o) {
|
|
214
246
|
if (o === null || o === undefined) {
|
|
215
247
|
return o;
|
|
@@ -40,6 +40,7 @@ export declare class FileSystemNodeActions {
|
|
|
40
40
|
private readonly _removeType;
|
|
41
41
|
private readonly _updateFileContentType;
|
|
42
42
|
private readonly _setFileContentType;
|
|
43
|
+
private readonly _setExtensionStateType;
|
|
43
44
|
private actionTypeSet;
|
|
44
45
|
constructor(sliceName: string);
|
|
45
46
|
get mkdirType(): string;
|
|
@@ -47,11 +48,13 @@ export declare class FileSystemNodeActions {
|
|
|
47
48
|
get removeType(): string;
|
|
48
49
|
get updateFileContentType(): string;
|
|
49
50
|
get setFileContentType(): string;
|
|
51
|
+
get setExtensionStateType(): string;
|
|
50
52
|
isFileSystemNodeAction(action: Action): action is FileSystemNodeAction;
|
|
51
|
-
mkdir(path: string | string[], parents?: boolean): FileSystemNodeAction;
|
|
53
|
+
mkdir(path: string | string[], parents?: boolean, extensionStates?: Record<string, unknown>): FileSystemNodeAction;
|
|
52
54
|
setFile(path: string | string[], content: any, schema: FileContentSchema, params?: FileSystemNodeActionParams): FileSystemNodeAction;
|
|
53
55
|
updateFileContent(path: string | string[], contentCommand: StructureNodeCommand): FileSystemNodeAction;
|
|
54
56
|
setFileContent(path: string | string[], content: any, fromRemote?: boolean): FileSystemNodeAction;
|
|
55
57
|
removeNode(path: string | string[], recursive?: boolean): FileSystemNodeAction;
|
|
58
|
+
setExtensionState(path: string | string[], key: string, state: Record<string, unknown>): FileSystemNodeAction;
|
|
56
59
|
}
|
|
57
60
|
//# sourceMappingURL=fs-adapter.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fs-adapter.d.ts","sourceRoot":"","sources":["../../../src/fs/core/fs-adapter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAkB,MAAM,kBAAkB,CAAC;AAC1D,OAAO,EACL,iBAAiB,EACjB,wBAAwB,EAEzB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,cAAc,EAEd,eAAe,EACf,iBAAiB,EACjB,0BAA0B,EAC1B,QAAQ,EACT,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAEtE;;GAEG;AACH,MAAM,WAAW,oBAAqB,SAAQ,MAAM;IAClD,OAAO,EAAE,iBAAiB,CAAA;CAC3B;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,SAAS,EAAE,MAAM,qBAExD;AAED;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,KAAK,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,KAAK,eAAe,CAAA;AAEjG;;GAEG;AACH,qBAAa,iBAAiB;aAKO,SAAS,EAAE,MAAM;IAJpD,QAAQ,CAAC,OAAO,EAAE,qBAAqB,CAAA;IACvC,QAAQ,CAAC,cAAc,EAAE,wBAAwB,CAAA;IACjD,QAAQ,CAAC,OAAO,EAAE,uBAAuB,CAAA;gBAEN,SAAS,EAAE,MAAM;IAapD,eAAe,IAAI,eAAe;IAIlC,UAAU;IAIV,UAAU,CAAC,aAAa,CAAC,EAAE,uBAAuB,GAAG,uBAAuB;IAQ5E,cAAc,CAAC,CAAC,EAAE,kBAAkB,EAAE,QAAQ,CAAC,CAAC,EAAE,eAAe,GAAG,SAAS,CAAC,EAAE,IAAI,EAAG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AoB;IAQhG,UAAU,CAAC,IAAI,EAAG,MAAM,GAAG,MAAM,EAAE,EAAE,SAAS,CAAC,EAAG,OAAO,GAAG,oBAAoB;IAOhF,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,oBAAoB;CAOrH"}
|
|
@@ -63,12 +63,14 @@ export class FileSystemNodeActions {
|
|
|
63
63
|
this._removeType = `${this.sliceName}/removeNode`;
|
|
64
64
|
this._updateFileContentType = `${this.sliceName}/updateFileContent`;
|
|
65
65
|
this._setFileContentType = `${this.sliceName}/setFileContent`;
|
|
66
|
+
this._setExtensionStateType = `${this.sliceName}/setExtensionState`;
|
|
66
67
|
this.actionTypeSet = new Set([
|
|
67
68
|
this._mkdirType,
|
|
68
69
|
this._setFileType,
|
|
69
70
|
this._removeType,
|
|
70
71
|
this._updateFileContentType,
|
|
71
|
-
this._setFileContentType
|
|
72
|
+
this._setFileContentType,
|
|
73
|
+
this._setExtensionStateType
|
|
72
74
|
]);
|
|
73
75
|
}
|
|
74
76
|
get mkdirType() {
|
|
@@ -86,20 +88,23 @@ export class FileSystemNodeActions {
|
|
|
86
88
|
get setFileContentType() {
|
|
87
89
|
return this._setFileContentType;
|
|
88
90
|
}
|
|
91
|
+
get setExtensionStateType() {
|
|
92
|
+
return this._setExtensionStateType;
|
|
93
|
+
}
|
|
89
94
|
isFileSystemNodeAction(action) {
|
|
90
95
|
return this.actionTypeSet.has(action.type);
|
|
91
96
|
}
|
|
92
|
-
mkdir(path, parents) {
|
|
97
|
+
mkdir(path, parents, extensionStates) {
|
|
93
98
|
return {
|
|
94
99
|
type: this.mkdirType,
|
|
95
|
-
command: { name: 'mkdir', path, parents }
|
|
100
|
+
command: { name: 'mkdir', path, parents, extensionStates }
|
|
96
101
|
};
|
|
97
102
|
}
|
|
98
103
|
setFile(path, content, schema, params = { override: true, contentIsPresent: true }) {
|
|
99
|
-
const { override, contentIsPresent } = params;
|
|
104
|
+
const { override, contentIsPresent, extensionStates } = params;
|
|
100
105
|
return {
|
|
101
106
|
type: this.setFileType,
|
|
102
|
-
command: { name: 'set-file', path, content, schema, override, contentIsPresent }
|
|
107
|
+
command: { name: 'set-file', path, content, schema, override, contentIsPresent, extensionStates }
|
|
103
108
|
};
|
|
104
109
|
}
|
|
105
110
|
updateFileContent(path, contentCommand) {
|
|
@@ -120,4 +125,10 @@ export class FileSystemNodeActions {
|
|
|
120
125
|
command: { name: 'remove', path, recursive }
|
|
121
126
|
};
|
|
122
127
|
}
|
|
128
|
+
setExtensionState(path, key, state) {
|
|
129
|
+
return {
|
|
130
|
+
type: this.setExtensionStateType,
|
|
131
|
+
command: { name: 'set-extension-state', path, key, state }
|
|
132
|
+
};
|
|
133
|
+
}
|
|
123
134
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* Concrete implementations of Redux store management
|
|
2
|
+
* @deprecated This package is deprecated. Please migrate to @hamak/ui-store
|
|
4
3
|
*/
|
|
5
|
-
export * from '
|
|
6
|
-
export * from './middleware';
|
|
7
|
-
export * from './plugin';
|
|
8
|
-
export * from './fs';
|
|
4
|
+
export * from '@hamak/ui-store';
|
|
9
5
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,cAAc,iBAAiB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* Concrete implementations of Redux store management
|
|
2
|
+
* @deprecated This package is deprecated. Please migrate to @hamak/ui-store
|
|
4
3
|
*/
|
|
5
|
-
|
|
6
|
-
export * from '
|
|
7
|
-
export * from './plugin';
|
|
8
|
-
export * from './fs';
|
|
4
|
+
console.warn('[@hamak/ui-store-impl] This package is deprecated. Please migrate to @hamak/ui-store');
|
|
5
|
+
export * from '@hamak/ui-store';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store-plugin-factory.d.ts","sourceRoot":"","sources":["../../src/plugin/store-plugin-factory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAML,KAAK,qBAAqB,EAC3B,MAAM,qBAAqB,CAAC;AAa7B,eAAO,MAAM,wBAAwB,uBAAuB,CAAC;AAE7D,MAAM,WAAW,iBAAkB,SAAQ,qBAAqB;IAC9D,wCAAwC;IACxC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,8CAA8C;IAC9C,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,wBAAgB,iBAAiB,CAC/B,MAAM,GAAE,iBAAsB,GAC7B,YAAY,
|
|
1
|
+
{"version":3,"file":"store-plugin-factory.d.ts","sourceRoot":"","sources":["../../src/plugin/store-plugin-factory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAML,KAAK,qBAAqB,EAC3B,MAAM,qBAAqB,CAAC;AAa7B,eAAO,MAAM,wBAAwB,uBAAuB,CAAC;AAE7D,MAAM,WAAW,iBAAkB,SAAQ,qBAAqB;IAC9D,wCAAwC;IACxC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,8CAA8C;IAC9C,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,wBAAgB,iBAAiB,CAC/B,MAAM,GAAE,iBAAsB,GAC7B,YAAY,CAqId"}
|
|
@@ -53,6 +53,18 @@ export function createStorePlugin(config = {}) {
|
|
|
53
53
|
middleware,
|
|
54
54
|
});
|
|
55
55
|
}
|
|
56
|
+
// Call middlewareFactory if provided, passing the fileSystemAdapter
|
|
57
|
+
if (config.middlewareFactory) {
|
|
58
|
+
const factoryMiddleware = config.middlewareFactory(fileSystemAdapter);
|
|
59
|
+
if (factoryMiddleware?.length) {
|
|
60
|
+
extensionsCollector.register('ui-store-config:middleware-factory', {
|
|
61
|
+
middleware: factoryMiddleware.map((mw) => ({
|
|
62
|
+
...mw,
|
|
63
|
+
plugin: mw.plugin ?? 'ui-store-config',
|
|
64
|
+
})),
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
}
|
|
56
68
|
if (config.reducers && Object.keys(config.reducers).length) {
|
|
57
69
|
extensionsCollector.register('ui-store-config:reducers', {
|
|
58
70
|
reducers: config.reducers,
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hamak/ui-store-impl",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "DEPRECATED: Use @hamak/ui-store instead",
|
|
7
7
|
"main": "dist/index.js",
|
|
8
8
|
"types": "dist/index.d.ts",
|
|
9
9
|
"sideEffects": false,
|
|
@@ -18,38 +18,22 @@
|
|
|
18
18
|
"publishConfig": {
|
|
19
19
|
"access": "public"
|
|
20
20
|
},
|
|
21
|
+
"deprecated": "Use @hamak/ui-store instead",
|
|
21
22
|
"scripts": {
|
|
22
|
-
"build": "tsc -p tsconfig.json
|
|
23
|
-
"clean": "rm -rf dist"
|
|
24
|
-
"test": "vitest run",
|
|
25
|
-
"test:watch": "vitest"
|
|
23
|
+
"build": "tsc -p tsconfig.json",
|
|
24
|
+
"clean": "rm -rf dist"
|
|
26
25
|
},
|
|
27
26
|
"exports": {
|
|
28
27
|
".": {
|
|
29
28
|
"types": "./dist/index.d.ts",
|
|
30
29
|
"import": "./dist/index.js",
|
|
31
|
-
"default": "./dist/index.js"
|
|
32
|
-
"legacy": "./dist/es2015/index.js"
|
|
33
|
-
},
|
|
34
|
-
"./es2015": {
|
|
35
|
-
"import": "./dist/es2015/index.js",
|
|
36
|
-
"default": "./dist/es2015/index.js"
|
|
30
|
+
"default": "./dist/index.js"
|
|
37
31
|
}
|
|
38
32
|
},
|
|
39
33
|
"dependencies": {
|
|
40
|
-
"@hamak/
|
|
41
|
-
"@hamak/ui-store-api": "*",
|
|
42
|
-
"@hamak/ui-store-spi": "*",
|
|
43
|
-
"@hamak/microkernel-api": "*",
|
|
44
|
-
"@hamak/microkernel-spi": "*",
|
|
45
|
-
"@reduxjs/toolkit": "^2.0.0",
|
|
46
|
-
"immer": "^10.0.0",
|
|
47
|
-
"redux": "^5.0.1",
|
|
48
|
-
"redux-thunk": "^3.1.0"
|
|
34
|
+
"@hamak/ui-store": "*"
|
|
49
35
|
},
|
|
50
36
|
"devDependencies": {
|
|
51
|
-
"typescript": "~5.4.0"
|
|
52
|
-
"vitest": "^2.0.0",
|
|
53
|
-
"@types/node": "^20.0.0"
|
|
37
|
+
"typescript": "~5.4.0"
|
|
54
38
|
}
|
|
55
39
|
}
|