@equinor/fusion-framework-module-bookmark 2.2.0 → 2.2.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/CHANGELOG.md +61 -0
- package/dist/esm/BookmarkProvider.js +3 -3
- package/dist/esm/BookmarkProvider.js.map +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/BookmarkProvider.d.ts +1 -1
- package/dist/types/version.d.ts +1 -1
- package/package.json +11 -11
- package/src/BookmarkProvider.ts +7 -3
- package/src/version.ts +1 -1
|
@@ -162,7 +162,7 @@ export declare class BookmarkProvider implements IBookmarkProvider {
|
|
|
162
162
|
* If the generator returns a value, a warning will be logged.
|
|
163
163
|
* If the generator returns null, an info message will be logged indicating that the bookmark data should be cleared.
|
|
164
164
|
*/
|
|
165
|
-
protected _producePayload<T extends BookmarkData>(value: Partial<T>, generator: BookmarkPayloadGenerator<T>, initial?: Partial<T> | null):
|
|
165
|
+
protected _producePayload<T extends BookmarkData>(value: Partial<T>, generator: BookmarkPayloadGenerator<T>, initial?: Partial<T> | null): Partial<T>;
|
|
166
166
|
/**
|
|
167
167
|
* Retrieves a bookmark with the specified bookmarkId and returns an observable that emits the combined result of fetching the bookmark and bookmark data.
|
|
168
168
|
* @template T The type of the bookmark payload.
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "2.2.
|
|
1
|
+
export declare const version = "2.2.1";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/fusion-framework-module-bookmark",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./dist/esm/index.js",
|
|
6
6
|
"types": "./dist/types/index.d.ts",
|
|
@@ -38,23 +38,23 @@
|
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"fast-deep-equal": "^3.1.3",
|
|
41
|
-
"immer": "^
|
|
41
|
+
"immer": "^10.1.3",
|
|
42
42
|
"rxjs": "^7.8.1",
|
|
43
|
-
"uuid": "^
|
|
44
|
-
"@equinor/fusion-framework-module": "^5.0.
|
|
45
|
-
"@equinor/fusion-
|
|
46
|
-
"@equinor/fusion-query": "^5.2.
|
|
47
|
-
"@equinor/fusion-
|
|
43
|
+
"uuid": "^13.0.0",
|
|
44
|
+
"@equinor/fusion-framework-module": "^5.0.1",
|
|
45
|
+
"@equinor/fusion-log": "^1.1.7",
|
|
46
|
+
"@equinor/fusion-query": "^5.2.13",
|
|
47
|
+
"@equinor/fusion-observable": "^8.5.3"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
|
-
"@types/uuid": "^
|
|
50
|
+
"@types/uuid": "^11.0.0",
|
|
51
51
|
"typescript": "^5.8.2",
|
|
52
52
|
"zod": "^3.25.76",
|
|
53
|
-
"@equinor/fusion-framework-module-app": "^6.1.
|
|
53
|
+
"@equinor/fusion-framework-module-app": "^6.1.19",
|
|
54
54
|
"@equinor/fusion-framework-module-context": "^7.0.0",
|
|
55
|
+
"@equinor/fusion-framework-module-services": "^7.0.2",
|
|
55
56
|
"@equinor/fusion-framework-module-event": "^4.3.7",
|
|
56
|
-
"@equinor/fusion-framework-module-http": "^6.3.
|
|
57
|
-
"@equinor/fusion-framework-module-services": "^7.0.0"
|
|
57
|
+
"@equinor/fusion-framework-module-http": "^6.3.5"
|
|
58
58
|
},
|
|
59
59
|
"scripts": {
|
|
60
60
|
"build": "tsc -b"
|
package/src/BookmarkProvider.ts
CHANGED
|
@@ -407,7 +407,11 @@ export class BookmarkProvider implements IBookmarkProvider {
|
|
|
407
407
|
* Observable that emits the generated payload.
|
|
408
408
|
*/
|
|
409
409
|
const result$ = from(this.#payloadGenerators).pipe(
|
|
410
|
-
mergeScan(
|
|
410
|
+
mergeScan(
|
|
411
|
+
(acc, generator) => of(this._producePayload(acc, generator)),
|
|
412
|
+
initial ?? ({} as Partial<T>),
|
|
413
|
+
1,
|
|
414
|
+
),
|
|
411
415
|
tap((payload) => this._log?.debug(`generated payload`, { initial, payload })),
|
|
412
416
|
) as Observable<T | null | undefined>;
|
|
413
417
|
|
|
@@ -434,9 +438,9 @@ export class BookmarkProvider implements IBookmarkProvider {
|
|
|
434
438
|
initial?: Partial<T> | null,
|
|
435
439
|
) {
|
|
436
440
|
// produce payload from generator
|
|
437
|
-
return produce(value,
|
|
441
|
+
return produce(value, (draft) => {
|
|
438
442
|
try {
|
|
439
|
-
const result =
|
|
443
|
+
const result = generator(draft as Partial<T>, initial);
|
|
440
444
|
// cast the result to a draft object
|
|
441
445
|
if (result) {
|
|
442
446
|
this._log?.warn(
|
package/src/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Generated by genversion.
|
|
2
|
-
export const version = '2.2.
|
|
2
|
+
export const version = '2.2.1';
|