@aprilium/tripsm_global-states 0.0.111 → 0.0.113
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/index.d.ts +20 -17
- package/lib/index.js +21 -14
- package/package.json +4 -3
package/lib/index.d.ts
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
/// <reference types="redux-persist/types/types" />
|
|
2
|
-
import { Store } from
|
|
3
|
-
import { Saga } from
|
|
4
|
-
import { PersistGate } from
|
|
5
|
-
import { PersistConfig } from
|
|
6
|
-
import { State as passengerState } from
|
|
7
|
-
import { State as constantState } from
|
|
8
|
-
import { State as tripState } from
|
|
9
|
-
import { State as groupState } from
|
|
10
|
-
import { State as userState } from
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import TripSaga from
|
|
14
|
-
import groupSaga from
|
|
15
|
-
import userSaga from
|
|
2
|
+
import { Store } from "redux";
|
|
3
|
+
import { Saga } from "redux-saga";
|
|
4
|
+
import { PersistGate } from "redux-persist/integration/react";
|
|
5
|
+
import { PersistConfig } from "redux-persist";
|
|
6
|
+
import { State as passengerState } from "@aprilium/tripsm_passenger/lib/state";
|
|
7
|
+
import { State as constantState } from "@aprilium/tripsm_constants/lib/state";
|
|
8
|
+
import { State as tripState } from "@aprilium/tripsm_trip/lib/state";
|
|
9
|
+
import { State as groupState } from "@aprilium/tripsm_trip-group/lib/state";
|
|
10
|
+
import { State as userState } from "@aprilium/tripsm_user/lib/state";
|
|
11
|
+
import { State as ticketState } from "@aprilium/tripsm_ticket/lib/state";
|
|
12
|
+
import passengerSaga from "@aprilium/tripsm_passenger/lib/effects";
|
|
13
|
+
import TripSaga from "@aprilium/tripsm_trip/lib/effects";
|
|
14
|
+
import groupSaga from "@aprilium/tripsm_trip-group/lib/effects";
|
|
15
|
+
import userSaga from "@aprilium/tripsm_user/lib/effects";
|
|
16
|
+
import ticketSaga from "@aprilium/tripsm_ticket/lib/effects";
|
|
16
17
|
export declare const sagaMiddleware: import("redux-saga").SagaMiddleware<object>;
|
|
17
18
|
export declare const reducers: {
|
|
18
19
|
passenger: import("immer-reducer").ImmerReducerFunction<typeof import("@aprilium/tripsm_passenger/lib/state").PassengerState>;
|
|
@@ -20,13 +21,14 @@ export declare const reducers: {
|
|
|
20
21
|
trip: import("immer-reducer").ImmerReducerFunction<typeof import("@aprilium/tripsm_trip/lib/state").TripState>;
|
|
21
22
|
group: import("immer-reducer").ImmerReducerFunction<typeof import("@aprilium/tripsm_trip-group/lib/state").GroupState>;
|
|
22
23
|
user: import("immer-reducer").ImmerReducerFunction<typeof import("@aprilium/tripsm_user/lib/state").UserState>;
|
|
24
|
+
ticket: import("immer-reducer").ImmerReducerFunction<typeof import("@aprilium/tripsm_ticket/lib/state").TicketState>;
|
|
23
25
|
};
|
|
24
26
|
export declare const initialSagas: {
|
|
25
27
|
passenger: typeof passengerSaga;
|
|
26
|
-
constants: typeof constantsSaga;
|
|
27
28
|
trip: typeof TripSaga;
|
|
28
29
|
group: typeof groupSaga;
|
|
29
30
|
user: typeof userSaga;
|
|
31
|
+
ticket: typeof ticketSaga;
|
|
30
32
|
};
|
|
31
33
|
export type States = {
|
|
32
34
|
passenger: passengerState;
|
|
@@ -34,10 +36,11 @@ export type States = {
|
|
|
34
36
|
group: groupState;
|
|
35
37
|
trip: tripState;
|
|
36
38
|
user: userState;
|
|
39
|
+
ticket: ticketState;
|
|
37
40
|
};
|
|
38
|
-
export type StateName =
|
|
41
|
+
export type StateName = "passenger" | "constants" | "trip" | "group" | "user" | "ticket";
|
|
39
42
|
export declare function setUrlConfig(coreApi: string, debugMode?: boolean): void;
|
|
40
|
-
export declare const sagas: (typeof passengerSaga | typeof
|
|
43
|
+
export declare const sagas: (typeof passengerSaga | typeof userSaga | typeof ticketSaga | typeof TripSaga | typeof groupSaga)[];
|
|
41
44
|
export declare function initSagaMiddleware(extraSagas?: Array<Saga>, // local sagas from frontEnd Client
|
|
42
45
|
waitForRehydrate?: boolean): void;
|
|
43
46
|
declare function configStore(extraMiddleWares: any[] | undefined, // Adding other middlewares
|
package/lib/index.js
CHANGED
|
@@ -58,51 +58,58 @@ var react_1 = require("redux-persist/integration/react");
|
|
|
58
58
|
var redux_persist_1 = require("redux-persist");
|
|
59
59
|
var lib_1 = require("@aprilium/tripsm_passenger/lib");
|
|
60
60
|
var lib_2 = require("@aprilium/tripsm_constants/lib");
|
|
61
|
-
var lib_3 = require("@aprilium/
|
|
61
|
+
var lib_3 = require("@aprilium/tripsm_group/lib");
|
|
62
62
|
var lib_4 = require("@aprilium/tripsm_user/lib");
|
|
63
|
+
var lib_5 = require("@aprilium/tripsm_ticket/lib");
|
|
63
64
|
var state_1 = require("@aprilium/tripsm_passenger/lib/state");
|
|
64
65
|
var state_2 = require("@aprilium/tripsm_constants/lib/state");
|
|
65
66
|
var state_3 = require("@aprilium/tripsm_trip/lib/state");
|
|
66
67
|
var state_4 = require("@aprilium/tripsm_trip-group/lib/state");
|
|
67
68
|
var state_5 = require("@aprilium/tripsm_user/lib/state");
|
|
69
|
+
var state_6 = require("@aprilium/tripsm_ticket/lib/state");
|
|
68
70
|
//import sagas
|
|
69
71
|
var effects_2 = __importDefault(require("@aprilium/tripsm_passenger/lib/effects"));
|
|
70
|
-
var effects_3 = __importDefault(require("@aprilium/
|
|
71
|
-
var effects_4 = __importDefault(require("@aprilium/tripsm_trip/lib/effects"));
|
|
72
|
-
var effects_5 = __importDefault(require("@aprilium/
|
|
73
|
-
var effects_6 = __importDefault(require("@aprilium/
|
|
72
|
+
var effects_3 = __importDefault(require("@aprilium/tripsm_trip/lib/effects"));
|
|
73
|
+
var effects_4 = __importDefault(require("@aprilium/tripsm_trip-group/lib/effects"));
|
|
74
|
+
var effects_5 = __importDefault(require("@aprilium/tripsm_user/lib/effects"));
|
|
75
|
+
var effects_6 = __importDefault(require("@aprilium/tripsm_ticket/lib/effects"));
|
|
74
76
|
exports.sagaMiddleware = (0, redux_saga_1.default)();
|
|
75
77
|
exports.reducers = {
|
|
76
78
|
passenger: state_1.passengerReducerFunction,
|
|
77
79
|
constants: state_2.ConstantsReducerFunction,
|
|
78
80
|
trip: state_3.TripReducerFunction,
|
|
79
81
|
group: state_4.GroupReducerFunction,
|
|
80
|
-
user: state_5.userReducerFunction
|
|
82
|
+
user: state_5.userReducerFunction,
|
|
83
|
+
ticket: state_6.TicketReducerFunction,
|
|
81
84
|
};
|
|
82
85
|
exports.initialSagas = {
|
|
83
86
|
passenger: effects_2.default,
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
87
|
+
trip: effects_3.default,
|
|
88
|
+
group: effects_4.default,
|
|
89
|
+
user: effects_5.default,
|
|
90
|
+
ticket: effects_6.default,
|
|
88
91
|
};
|
|
89
92
|
function setUrlConfig(coreApi, debugMode) {
|
|
90
93
|
if (debugMode === void 0) { debugMode = false; }
|
|
91
94
|
lib_1.urlsConfig.setURls({
|
|
92
95
|
CORE_BASE_URL: coreApi,
|
|
93
|
-
DEBUG_MODE: debugMode
|
|
96
|
+
DEBUG_MODE: debugMode,
|
|
94
97
|
});
|
|
95
98
|
lib_2.urlsConfig.setURls({
|
|
96
99
|
CORE_BASE_URL: coreApi,
|
|
97
|
-
DEBUG_MODE: debugMode
|
|
100
|
+
DEBUG_MODE: debugMode,
|
|
98
101
|
});
|
|
99
102
|
lib_3.urlsConfig.setURls({
|
|
100
103
|
CORE_BASE_URL: coreApi,
|
|
101
|
-
DEBUG_MODE: debugMode
|
|
104
|
+
DEBUG_MODE: debugMode,
|
|
102
105
|
});
|
|
103
106
|
lib_4.urlsConfig.setURls({
|
|
104
107
|
CORE_BASE_URL: coreApi,
|
|
105
|
-
DEBUG_MODE: debugMode
|
|
108
|
+
DEBUG_MODE: debugMode,
|
|
109
|
+
});
|
|
110
|
+
lib_5.urlsConfig.setURls({
|
|
111
|
+
CORE_BASE_URL: coreApi,
|
|
112
|
+
DEBUG_MODE: debugMode,
|
|
106
113
|
});
|
|
107
114
|
}
|
|
108
115
|
exports.setUrlConfig = setUrlConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aprilium/tripsm_global-states",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.113",
|
|
4
4
|
"description": "global states",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -14,13 +14,14 @@
|
|
|
14
14
|
"dependencies": {
|
|
15
15
|
"@aprilium/tripsm_passenger": "^0.0.49",
|
|
16
16
|
"@aprilium/tripsm_common": "^0.0.6",
|
|
17
|
-
"@aprilium/tripsm_constants": "^0.0.
|
|
17
|
+
"@aprilium/tripsm_constants": "^0.0.18",
|
|
18
18
|
"@aprilium/tripsm_trip": "^0.0.5",
|
|
19
19
|
"@aprilium/tripsm_trip-group": "^0.0.2",
|
|
20
20
|
"@aprilium/tripsm_user":"^0.0.6",
|
|
21
21
|
"@aprilium/tripsm_passenger-hotel":"^0.0.2",
|
|
22
22
|
"@aprilium/tripsm_identity-type":"^0.0.2",
|
|
23
|
-
|
|
23
|
+
"@aprilium/tripsm_ticket":"^0.0.1",
|
|
24
|
+
|
|
24
25
|
"@types/react": "^17.0.0",
|
|
25
26
|
"axios": "^0.21.1",
|
|
26
27
|
"immer": "^9.0.15",
|