@fluid-topics/ft-reader-context 1.3.52 → 1.3.54
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/build/ft-reader-context.light.js +6 -6
- package/build/ft-reader-context.min.js +18 -18
- package/build/store/FtReaderStateManager.d.ts +1 -0
- package/build/store/FtReaderStateManager.js +3 -0
- package/build/store/model.d.ts +1 -0
- package/build/store/redux.d.ts +2 -0
- package/build/store/redux.js +8 -4
- package/package.json +4 -4
|
@@ -44,6 +44,7 @@ export declare class FtReaderStateManager {
|
|
|
44
44
|
setTranslationLoading(isLoading: boolean): Promise<void>;
|
|
45
45
|
setTranslationError(isError: boolean): Promise<void>;
|
|
46
46
|
getTranslationSettings(): FtTranslationSettings | undefined;
|
|
47
|
+
setLinkPreviewDialogId(linkPreviewDialogId?: string): void;
|
|
47
48
|
fetchMapRating(): Promise<void>;
|
|
48
49
|
fetchTopicRating(tocId: string): Promise<void>;
|
|
49
50
|
registerMetadataForSwitchToRelatives(id: string): void;
|
|
@@ -226,6 +226,9 @@ export class FtReaderStateManager {
|
|
|
226
226
|
sourceLanguage: (_a = state.map) === null || _a === void 0 ? void 0 : _a.lang,
|
|
227
227
|
} : undefined;
|
|
228
228
|
}
|
|
229
|
+
setLinkPreviewDialogId(linkPreviewDialogId) {
|
|
230
|
+
this.store.actions.setLinkPreviewDialogId(linkPreviewDialogId);
|
|
231
|
+
}
|
|
229
232
|
async fetchMapRating() {
|
|
230
233
|
var _a;
|
|
231
234
|
this.store.actions.mapRating(await ((_a = this.service) === null || _a === void 0 ? void 0 : _a.getMapRating()));
|
package/build/store/model.d.ts
CHANGED
package/build/store/redux.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ declare const readerStoreStateReducers: {
|
|
|
8
8
|
setTranslationLoading: (state: FtReaderState, action: PayloadAction<FtReaderState["translation"]["isLoading"]>) => void;
|
|
9
9
|
setTranslationError: (state: FtReaderState, action: PayloadAction<FtReaderState["translation"]["isError"]>) => void;
|
|
10
10
|
setTopicsRating: (state: FtReaderState, action: PayloadAction<FtReaderState["topicsRating"]>) => void;
|
|
11
|
+
setLinkPreviewDialogId: (state: FtReaderState, action: PayloadAction<FtReaderState["linkPreviewDialogId"]>) => void;
|
|
11
12
|
};
|
|
12
13
|
export type FtReaderStateReducers = typeof readerStoreStateReducers;
|
|
13
14
|
export type FtReaderReduxStore = FtReduxStore<FtReaderState, FtReaderStateReducers>;
|
|
@@ -18,5 +19,6 @@ export declare const createReaderStore: (id: string) => FtReduxStore<FtReaderSta
|
|
|
18
19
|
setTranslationLoading: (state: FtReaderState, action: PayloadAction<FtReaderState["translation"]["isLoading"]>) => void;
|
|
19
20
|
setTranslationError: (state: FtReaderState, action: PayloadAction<FtReaderState["translation"]["isError"]>) => void;
|
|
20
21
|
setTopicsRating: (state: FtReaderState, action: PayloadAction<FtReaderState["topicsRating"]>) => void;
|
|
22
|
+
setLinkPreviewDialogId: (state: FtReaderState, action: PayloadAction<FtReaderState["linkPreviewDialogId"]>) => void;
|
|
21
23
|
}, import("redux").AnyAction>;
|
|
22
24
|
export {};
|
package/build/store/redux.js
CHANGED
|
@@ -16,10 +16,13 @@ const readerStoreStateReducers = {
|
|
|
16
16
|
state.translation.isError = action.payload;
|
|
17
17
|
},
|
|
18
18
|
setTopicsRating: (state, action) => {
|
|
19
|
-
for (
|
|
19
|
+
for (const key in action.payload) {
|
|
20
20
|
state.topicsRating[key] = action.payload[key];
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
|
+
setLinkPreviewDialogId: (state, action) => {
|
|
24
|
+
state.linkPreviewDialogId = action.payload;
|
|
25
|
+
},
|
|
23
26
|
};
|
|
24
27
|
export const createReaderStore = (id) => FtReduxStore.get({
|
|
25
28
|
name: "ft-reader-" + id,
|
|
@@ -43,8 +46,9 @@ export const createReaderStore = (id) => FtReduxStore.get({
|
|
|
43
46
|
destinationLanguage: undefined,
|
|
44
47
|
profileId: undefined,
|
|
45
48
|
isLoading: false,
|
|
46
|
-
isError: false
|
|
47
|
-
}
|
|
49
|
+
isError: false,
|
|
50
|
+
},
|
|
51
|
+
linkPreviewDialogId: undefined,
|
|
48
52
|
},
|
|
49
|
-
reducers: readerStoreStateReducers
|
|
53
|
+
reducers: readerStoreStateReducers,
|
|
50
54
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-reader-context",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.54",
|
|
4
4
|
"description": "Context block for integrated reader components",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,13 +19,13 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-app-context": "1.3.
|
|
23
|
-
"@fluid-topics/ft-wc-utils": "1.3.
|
|
22
|
+
"@fluid-topics/ft-app-context": "1.3.54",
|
|
23
|
+
"@fluid-topics/ft-wc-utils": "1.3.54",
|
|
24
24
|
"@reduxjs/toolkit": "^1.6.2",
|
|
25
25
|
"lit": "3.1.0"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@fluid-topics/public-api": "1.0.112"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "cf94f6196c0b97b6f3ee585302a0ffe35c442f32"
|
|
31
31
|
}
|