ouisys-engine 5.0.1 → 5.0.3
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/package.json +1 -1
- package/dist/RemoteDataState-lcf8PfJd.js +0 -2
- package/dist/RemoteDataState-lcf8PfJd.js.map +0 -1
- package/dist/bupperizeCountry-CEtt0MKz.js +0 -2
- package/dist/bupperizeCountry-CEtt0MKz.js.map +0 -1
- package/dist/checkSubscriptionByRockmanIdOnly-BwR1un1L.js +0 -2
- package/dist/checkSubscriptionByRockmanIdOnly-BwR1un1L.js.map +0 -1
- package/dist/checkSubscriptionHander.js +0 -2
- package/dist/checkSubscriptionHander.js.map +0 -1
- package/dist/click2smsFlow.js +0 -2
- package/dist/click2smsFlow.js.map +0 -1
- package/dist/creditCardFlow.js +0 -2
- package/dist/creditCardFlow.js.map +0 -1
- package/dist/getConfig.js +0 -2
- package/dist/getConfig.js.map +0 -1
- package/dist/handleClickChainFlow.js +0 -2
- package/dist/handleClickChainFlow.js.map +0 -1
- package/dist/handleSubmitNumber.js +0 -2
- package/dist/handleSubmitNumber.js.map +0 -1
- package/dist/helpers-xPhGBX-B.js +0 -2
- package/dist/helpers-xPhGBX-B.js.map +0 -1
- package/dist/loadScriptInnerHtml-BzQm-AFb.js +0 -2
- package/dist/loadScriptInnerHtml-BzQm-AFb.js.map +0 -1
- package/dist/loadScriptSrc-Da4autZd.js +0 -2
- package/dist/loadScriptSrc-Da4autZd.js.map +0 -1
- package/dist/moFlow.js +0 -2
- package/dist/moFlow.js.map +0 -1
- package/dist/moRedirFlow.js +0 -2
- package/dist/moRedirFlow.js.map +0 -1
- package/dist/oneClickFlow.js +0 -2
- package/dist/oneClickFlow.js.map +0 -1
- package/dist/pinFlow.js +0 -2
- package/dist/pinFlow.js.map +0 -1
- package/dist/searchToObject.js +0 -2
- package/dist/searchToObject.js.map +0 -1
- package/dist/storeMsisdn-Cjq8_qYH.js +0 -2
- package/dist/storeMsisdn-Cjq8_qYH.js.map +0 -1
- package/dist/strategy.js +0 -2
- package/dist/strategy.js.map +0 -1
- package/dist/strategySlice-Dw14E22-.js +0 -2
- package/dist/strategySlice-Dw14E22-.js.map +0 -1
- package/dist/tracker-DaaILhEr.js +0 -2
- package/dist/tracker-DaaILhEr.js.map +0 -1
- package/dist/tracker.js +0 -2
- package/dist/tracker.js.map +0 -1
- package/dist/tryGetIPRangeName-QW-9NgzE.js +0 -2
- package/dist/tryGetIPRangeName-QW-9NgzE.js.map +0 -1
- package/dist/types/CreditCardTypes-B-IT-l6I.d.ts +0 -72
- package/dist/types/IHash-0OgZ_1ij.d.ts +0 -5
- package/dist/types/MoRedirTypes-4tEJjT1g.d.ts +0 -31
- package/dist/types/MoTypes-D-UK92gs.d.ts +0 -45
- package/dist/types/OneClickTypes-DjOesaHp.d.ts +0 -69
- package/dist/types/PinTypes-BLJDBZe6.d.ts +0 -128
- package/dist/types/RemoteDataState-D1aFrz8W.d.ts +0 -61
- package/dist/types/StrategyTypes-CbOgk0N4.d.ts +0 -326
- package/dist/types/UssdTypes-C7QlIW11.d.ts +0 -34
- package/dist/types/checkSubscriptionHander.d.ts +0 -8
- package/dist/types/click2smsFlow.d.ts +0 -37
- package/dist/types/creditCardFlow.d.ts +0 -37
- package/dist/types/getConfig.d.ts +0 -38
- package/dist/types/handleClickChainFlow.d.ts +0 -6
- package/dist/types/handleSubmitNumber.d.ts +0 -26
- package/dist/types/moFlow.d.ts +0 -70
- package/dist/types/moRedirFlow.d.ts +0 -82
- package/dist/types/oneClickFlow.d.ts +0 -56
- package/dist/types/pinFlow.d.ts +0 -179
- package/dist/types/searchToObject.d.ts +0 -3
- package/dist/types/strategy.d.ts +0 -94
- package/dist/types/tracker.d.ts +0 -5
- package/dist/types/ussdFlow.d.ts +0 -84
- package/dist/ussdFlow.js +0 -2
- package/dist/ussdFlow.js.map +0 -1
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { U as LOAD_OC2SMSState, V as Click2smsFlowState, j as IHash, W as IWithMultiKeywordShortcode, X as Click2smsFlowCurrentState } from './StrategyTypes-CbOgk0N4.js';
|
|
2
|
-
export { a4 as ICheckSubscriptionResult, a1 as IClick2smsConfig, a5 as IFetchResult, a0 as IKeywordShortcode, Z as ILOADOC2SMSFailure, _ as ILOADOC2SMSSuccess, $ as ILoadOc2click2smsPayload, Y as MSISDNEntryErrorTypes, a3 as MultiOperatorSubmissionResult, a2 as SingleSubmissionResult } from './StrategyTypes-CbOgk0N4.js';
|
|
3
|
-
import * as redux from 'redux';
|
|
4
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
5
|
-
import * as _reduxjs_toolkit_dist_createAsyncThunk from '@reduxjs/toolkit/dist/createAsyncThunk';
|
|
6
|
-
import { useSelector } from 'react-redux';
|
|
7
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
8
|
-
import './CreditCardTypes-B-IT-l6I.js';
|
|
9
|
-
import './MoRedirTypes-4tEJjT1g.js';
|
|
10
|
-
import './MoTypes-D-UK92gs.js';
|
|
11
|
-
import './OneClickTypes-DjOesaHp.js';
|
|
12
|
-
import './PinTypes-BLJDBZe6.js';
|
|
13
|
-
import './UssdTypes-C7QlIW11.js';
|
|
14
|
-
|
|
15
|
-
interface LOAD_OC2SMSArgs {
|
|
16
|
-
window: Window;
|
|
17
|
-
extraParams?: IHash;
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* loadOc2smsAction
|
|
21
|
-
* @returns {type: ' 'pinFlow/submitMSISDNAction', payload: {type: PossibleTypes, result: MSISDNEntryState}}
|
|
22
|
-
|
|
23
|
-
* Calls oc2sms api that returns a keyword and short code
|
|
24
|
-
*
|
|
25
|
-
*/
|
|
26
|
-
declare const loadOc2smsAction: _reduxjs_toolkit.AsyncThunk<LOAD_OC2SMSState, LOAD_OC2SMSArgs, _reduxjs_toolkit_dist_createAsyncThunk.AsyncThunkConfig>;
|
|
27
|
-
declare const click2smsFlowReducer: redux.Reducer<Click2smsFlowState, redux.UnknownAction, Click2smsFlowState>;
|
|
28
|
-
|
|
29
|
-
declare const useClick2smsFlowState: (useSelector: typeof useSelector) => LOAD_OC2SMSState;
|
|
30
|
-
|
|
31
|
-
declare const useKeyWordShortCode: (useSelector: typeof useSelector) => IWithMultiKeywordShortcode;
|
|
32
|
-
|
|
33
|
-
declare function click2smsFlowMatch<R>({ load }: {
|
|
34
|
-
load: (rds: RemoteDataState<string, IWithMultiKeywordShortcode>) => R;
|
|
35
|
-
}): (state: Click2smsFlowCurrentState) => R;
|
|
36
|
-
|
|
37
|
-
export { Click2smsFlowCurrentState, Click2smsFlowState, IWithMultiKeywordShortcode, LOAD_OC2SMSState, click2smsFlowMatch, click2smsFlowReducer, loadOc2smsAction, useClick2smsFlowState, useKeyWordShortCode };
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { U as USERDETAILSEntryState, S as SubmitUserDetailsFailure, C as CreditCardFlowState, I as IUserDetails, a as IUserDetailsEcardon, b as SubmitUserDetailsSuccess, c as CreditCardFlowCurrentState } from './CreditCardTypes-B-IT-l6I.js';
|
|
2
|
-
export { d as IEmailPasswordSubmissionResult, g as IMockCreditCardFlowStates, f as IUserDetailsSubmissionResult, e as SubmitUserDetailsErrorTypes } from './CreditCardTypes-B-IT-l6I.js';
|
|
3
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
4
|
-
import * as redux from 'redux';
|
|
5
|
-
import { useSelector } from 'react-redux';
|
|
6
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
7
|
-
|
|
8
|
-
interface SubmitUserDetailsArgs {
|
|
9
|
-
window: Window;
|
|
10
|
-
userDetails: IUserDetails | IUserDetailsEcardon;
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* submitUserDetailsAction
|
|
14
|
-
* @returns {type: ' 'pinFlow/submitUserDetailsAction', payload: {type: PossibleTypes, result: USERDETAILSEntryState}}
|
|
15
|
-
|
|
16
|
-
* Calls redirect or max api and returns a url
|
|
17
|
-
*
|
|
18
|
-
*/
|
|
19
|
-
declare const submitUserDetailsAction: _reduxjs_toolkit.AsyncThunk<USERDETAILSEntryState, SubmitUserDetailsArgs, {
|
|
20
|
-
rejectValue: SubmitUserDetailsFailure;
|
|
21
|
-
state?: unknown;
|
|
22
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
23
|
-
extra?: unknown;
|
|
24
|
-
serializedErrorType?: unknown;
|
|
25
|
-
pendingMeta?: unknown;
|
|
26
|
-
fulfilledMeta?: unknown;
|
|
27
|
-
rejectedMeta?: unknown;
|
|
28
|
-
}>;
|
|
29
|
-
declare const creditCardFlowReducer: redux.Reducer<CreditCardFlowState, redux.UnknownAction, CreditCardFlowState>;
|
|
30
|
-
|
|
31
|
-
declare const useCreditCardFlowState: (useSelector: typeof useSelector) => USERDETAILSEntryState;
|
|
32
|
-
|
|
33
|
-
declare function creditCardFlowMatch<R>({ userDetailsEntry }: {
|
|
34
|
-
userDetailsEntry: (rds: RemoteDataState<SubmitUserDetailsFailure, SubmitUserDetailsSuccess>) => R;
|
|
35
|
-
}): (state: CreditCardFlowCurrentState) => R;
|
|
36
|
-
|
|
37
|
-
export { CreditCardFlowCurrentState, CreditCardFlowState, IUserDetails, IUserDetailsEcardon, SubmitUserDetailsFailure, SubmitUserDetailsSuccess, USERDETAILSEntryState, creditCardFlowMatch, creditCardFlowReducer, submitUserDetailsAction, useCreditCardFlowState };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
declare type ConfigDetails = {
|
|
2
|
-
host: string;
|
|
3
|
-
slug: string;
|
|
4
|
-
country: string;
|
|
5
|
-
device?: 'smart' | 'feature';
|
|
6
|
-
queryString?: Array<[string, string]>;
|
|
7
|
-
automaticallySubmitAllOperators?: boolean;
|
|
8
|
-
operators?: string[];
|
|
9
|
-
service: string;
|
|
10
|
-
offer?: string;
|
|
11
|
-
};
|
|
12
|
-
declare type ISupportedFlows = 'pin' | 'mo' | 'oneClick' | 'click2sms' | 'moRedir' | 'ussd' | 'tpayHe' | 'creditCard';
|
|
13
|
-
declare type IFlow = {
|
|
14
|
-
flow: ISupportedFlows;
|
|
15
|
-
flowOnWifi?: ISupportedFlows;
|
|
16
|
-
operator?: string;
|
|
17
|
-
flowConfig: ConfigDetails;
|
|
18
|
-
default?: IFlow;
|
|
19
|
-
rockman_id?: string;
|
|
20
|
-
};
|
|
21
|
-
declare type StrategyConfig = {
|
|
22
|
-
operators: {
|
|
23
|
-
[key: string]: IFlow;
|
|
24
|
-
};
|
|
25
|
-
default: IFlow;
|
|
26
|
-
isUseMsisdnPrefix?: boolean;
|
|
27
|
-
};
|
|
28
|
-
declare type IStrategy = {
|
|
29
|
-
strategy: IStrategyNames;
|
|
30
|
-
country: string;
|
|
31
|
-
strategyConfigs: StrategyConfig;
|
|
32
|
-
};
|
|
33
|
-
declare type IStrategyNames = 'pin' | 'mo' | 'mo-redir' | 'click2sms' | 'one-click' | 'ussd' | 'tpay-he' | 'credit-card' | 'tallyman-one-click' | 'pin-mo-ask-operator' | 'pin-mo-ask-mobile-number' | 'pin-one-click-ask-operator' | 'pin-one-click-detect-operator-by-ip' | 'one-click-mo-pin-detect-operator-by-ip-or-msisdn' | 'pin-click2sms-ask-operator' | 'mo-redir-one-click-detect-operator-by-ip' | 'pin-mo-redir-ask-mobile-number' | 'pin-click2sms-ask-mobile-number' | 'mo-one-click-detect-operator-by-ip' | 'click2sms-one-click-detect-operator-by-ip' | 'pin-header-enrichment' | 'pin-msisdn-fowarding-pin-header-enrichment' | 'he-pin-mo-redir-header-enrichment' | 'he-pin-one-click-header-enrichment' | 'he-pin-one-click-ask-operator' | 'click2sms-one-click-ask-operator' | 'pin-mo-detect-operator-by-ip' | 'he-mo-redir-one-click-header-enrichment' | 'pin-combo-ask-mobile-number' | 'header-enrichment-script' | 'mo-redir-mo-click2sms-one-click-detect-operator-by-ip-or-msisdn' | 'pin-mo-mo-redir-ask-mobile-number';
|
|
34
|
-
|
|
35
|
-
declare function setConfig(userConfig: IStrategy): void;
|
|
36
|
-
declare function getConfig(): IStrategy;
|
|
37
|
-
|
|
38
|
-
export { getConfig, setConfig };
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { Dispatch } from '@reduxjs/toolkit';
|
|
2
|
-
|
|
3
|
-
declare const handleAutoSubmitMsisdn: ({ msisdnValue, dispatch, submitMSISDNAction, isHeaderEnrichmentSuccess, isHeaderEnrichmentAutoSubmit }: {
|
|
4
|
-
window: Window;
|
|
5
|
-
msisdnValue: string;
|
|
6
|
-
dispatch: Dispatch;
|
|
7
|
-
submitMSISDNAction: ({ window, msisdn }: {
|
|
8
|
-
window: Window;
|
|
9
|
-
msisdn: string;
|
|
10
|
-
}) => any;
|
|
11
|
-
isHeaderEnrichmentSuccess: boolean;
|
|
12
|
-
isHeaderEnrichmentAutoSubmit?: boolean;
|
|
13
|
-
}) => void;
|
|
14
|
-
declare const handleFormSubmit: ({ window, isHeaderEnrichmentSuccess, onEnd, internationalNumber, isValid }: {
|
|
15
|
-
window: Window;
|
|
16
|
-
isHeaderEnrichmentSuccess: boolean;
|
|
17
|
-
country: string;
|
|
18
|
-
setInternationalNumber: (msisdn: string) => void;
|
|
19
|
-
onEnd: (msisdn: string, extraParams?: {
|
|
20
|
-
[key: string]: string;
|
|
21
|
-
}) => void;
|
|
22
|
-
internationalNumber: string;
|
|
23
|
-
isValid: boolean;
|
|
24
|
-
}) => void;
|
|
25
|
-
|
|
26
|
-
export { handleAutoSubmitMsisdn, handleFormSubmit };
|
package/dist/types/moFlow.d.ts
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import { M as MSISDNEntryState, a as MSISDNEntryFailure, b as MSISDNEntrySuccess, c as MoFlowCurrentState } from './MoTypes-D-UK92gs.js';
|
|
2
|
-
export { h as IGoogleReCaptcha, I as IKeywordShortcode, f as IMSISDNSubmissionResult, g as IMockMoFlowStates, e as MSISDNEntryErrorTypes, d as MoFlowState } from './MoTypes-D-UK92gs.js';
|
|
3
|
-
import { useSelector } from 'react-redux';
|
|
4
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
5
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
6
|
-
import * as redux from 'redux';
|
|
7
|
-
import { I as IHash } from './IHash-0OgZ_1ij.js';
|
|
8
|
-
|
|
9
|
-
declare const useMoFlowState: (useSelector: typeof useSelector) => MSISDNEntryState;
|
|
10
|
-
|
|
11
|
-
declare function moFlowMatch<R>({ msisdnEntry }: {
|
|
12
|
-
msisdnEntry: (rds: RemoteDataState<MSISDNEntryFailure, MSISDNEntrySuccess>) => R;
|
|
13
|
-
}): (state: MoFlowCurrentState) => R;
|
|
14
|
-
|
|
15
|
-
interface SubmitMSISDNArgs {
|
|
16
|
-
window: Window;
|
|
17
|
-
msisdn: string;
|
|
18
|
-
extraParams?: IHash;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* submitMSISDNAction
|
|
22
|
-
* @returns {type: ' 'pinFlow/submitMSISDNAction', payload: {type: PossibleTypes, result: MSISDNEntryState}}
|
|
23
|
-
|
|
24
|
-
* Calls trigger-message api that returns a short code and key word
|
|
25
|
-
* Sets completed stated
|
|
26
|
-
*/
|
|
27
|
-
declare const submitMSISDNAction: _reduxjs_toolkit.AsyncThunk<MSISDNEntryState, SubmitMSISDNArgs, {
|
|
28
|
-
rejectValue: MSISDNEntryFailure;
|
|
29
|
-
state?: unknown;
|
|
30
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
31
|
-
extra?: unknown;
|
|
32
|
-
serializedErrorType?: unknown;
|
|
33
|
-
pendingMeta?: unknown;
|
|
34
|
-
fulfilledMeta?: unknown;
|
|
35
|
-
rejectedMeta?: unknown;
|
|
36
|
-
}>;
|
|
37
|
-
declare const moFlowReducer: redux.Reducer<{
|
|
38
|
-
currentState: {
|
|
39
|
-
type: 'MSISDNEntry';
|
|
40
|
-
result: {
|
|
41
|
-
type: "NothingYet";
|
|
42
|
-
} | {
|
|
43
|
-
type: "Loading";
|
|
44
|
-
} | {
|
|
45
|
-
type: "Failure";
|
|
46
|
-
error: any;
|
|
47
|
-
} | {
|
|
48
|
-
type: "Success";
|
|
49
|
-
data: any;
|
|
50
|
-
};
|
|
51
|
-
};
|
|
52
|
-
}, redux.UnknownAction, {
|
|
53
|
-
currentState: {
|
|
54
|
-
type: 'MSISDNEntry';
|
|
55
|
-
result: {
|
|
56
|
-
type: "NothingYet";
|
|
57
|
-
} | {
|
|
58
|
-
type: "Loading";
|
|
59
|
-
} | {
|
|
60
|
-
type: "Failure";
|
|
61
|
-
error: any;
|
|
62
|
-
} | {
|
|
63
|
-
type: "Success";
|
|
64
|
-
data: any;
|
|
65
|
-
};
|
|
66
|
-
};
|
|
67
|
-
}>;
|
|
68
|
-
declare const backToStartAction: _reduxjs_toolkit.ActionCreatorWithoutPayload<"moFlow/backToStartAction">;
|
|
69
|
-
|
|
70
|
-
export { MSISDNEntryFailure, MSISDNEntryState, MSISDNEntrySuccess, MoFlowCurrentState, backToStartAction, moFlowMatch, moFlowReducer, submitMSISDNAction, useMoFlowState };
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { M as MSISDNEntryState, a as MSISDNEntryFailure, b as MSISDNEntrySuccess, c as MoRedirFlowCurrentState, d as MSISDNEntryErrorTypes } from './MoRedirTypes-4tEJjT1g.js';
|
|
2
|
-
export { I as IMSISDNSubmissionResult, f as IMockMoRedirFlowStates, e as MoRedirFlowState } from './MoRedirTypes-4tEJjT1g.js';
|
|
3
|
-
import { useSelector } from 'react-redux';
|
|
4
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
5
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
6
|
-
import * as redux from 'redux';
|
|
7
|
-
import { I as IHash } from './IHash-0OgZ_1ij.js';
|
|
8
|
-
|
|
9
|
-
declare const useMoRedirFlowState: (useSelector: typeof useSelector) => MSISDNEntryState;
|
|
10
|
-
|
|
11
|
-
declare function moRedirFlowMatch<R>({ msisdnEntry }: {
|
|
12
|
-
msisdnEntry: (rds: RemoteDataState<MSISDNEntryFailure, MSISDNEntrySuccess>) => R;
|
|
13
|
-
}): (state: MoRedirFlowCurrentState) => R;
|
|
14
|
-
|
|
15
|
-
interface SubmitMSISDNArgs {
|
|
16
|
-
window: Window;
|
|
17
|
-
msisdn: string;
|
|
18
|
-
extraParams?: IHash;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* submitMSISDNAction
|
|
22
|
-
* @returns {type: ' 'pinFlow/submitMSISDNAction', payload: {type: PossibleTypes, result: MSISDNEntryState}}
|
|
23
|
-
|
|
24
|
-
* Calls redirec api that returns a redirect url
|
|
25
|
-
* Sets completed stated
|
|
26
|
-
*/
|
|
27
|
-
declare const submitMSISDNAction: _reduxjs_toolkit.AsyncThunk<MSISDNEntryState, SubmitMSISDNArgs, {
|
|
28
|
-
rejectValue: MSISDNEntryFailure;
|
|
29
|
-
state?: unknown;
|
|
30
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
31
|
-
extra?: unknown;
|
|
32
|
-
serializedErrorType?: unknown;
|
|
33
|
-
pendingMeta?: unknown;
|
|
34
|
-
fulfilledMeta?: unknown;
|
|
35
|
-
rejectedMeta?: unknown;
|
|
36
|
-
}>;
|
|
37
|
-
declare const moRedirFlowReducer: redux.Reducer<{
|
|
38
|
-
currentState: {
|
|
39
|
-
type: "MSISDNEntry";
|
|
40
|
-
result: {
|
|
41
|
-
type: "NothingYet";
|
|
42
|
-
} | {
|
|
43
|
-
type: "Loading";
|
|
44
|
-
} | {
|
|
45
|
-
type: "Failure";
|
|
46
|
-
error: {
|
|
47
|
-
errorType: MSISDNEntryErrorTypes;
|
|
48
|
-
error?: any;
|
|
49
|
-
productUrl?: string;
|
|
50
|
-
};
|
|
51
|
-
} | {
|
|
52
|
-
type: "Success";
|
|
53
|
-
data: {
|
|
54
|
-
href: string;
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
};
|
|
58
|
-
}, redux.UnknownAction, {
|
|
59
|
-
currentState: {
|
|
60
|
-
type: "MSISDNEntry";
|
|
61
|
-
result: {
|
|
62
|
-
type: "NothingYet";
|
|
63
|
-
} | {
|
|
64
|
-
type: "Loading";
|
|
65
|
-
} | {
|
|
66
|
-
type: "Failure";
|
|
67
|
-
error: {
|
|
68
|
-
errorType: MSISDNEntryErrorTypes;
|
|
69
|
-
error?: any;
|
|
70
|
-
productUrl?: string;
|
|
71
|
-
};
|
|
72
|
-
} | {
|
|
73
|
-
type: "Success";
|
|
74
|
-
data: {
|
|
75
|
-
href: string;
|
|
76
|
-
};
|
|
77
|
-
};
|
|
78
|
-
};
|
|
79
|
-
}>;
|
|
80
|
-
declare const backToStartAction: _reduxjs_toolkit.ActionCreatorWithoutPayload<"moRedirFlow/backToStartAction">;
|
|
81
|
-
|
|
82
|
-
export { MSISDNEntryErrorTypes, MSISDNEntryFailure, MSISDNEntryState, MSISDNEntrySuccess, MoRedirFlowCurrentState, backToStartAction, moRedirFlowMatch, moRedirFlowReducer, submitMSISDNAction, useMoRedirFlowState };
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { a as OneClickFlowCurrentState, I as IGETREDIRECTURLFailure, b as IGETREDIRECTURLSuccess, S as SubscribeFailure, c as SubscribeSuccess, G as GETREDIRECTUrlState, A as AJAXSUBSCRIBEState, O as OneClickFlowState } from './OneClickTypes-DjOesaHp.js';
|
|
2
|
-
export { g as IHEResult, f as IIDentifyUserResult, e as ILinkExtraParams, i as IMockOneClickFlowStates, h as ISubscribeResult, d as SubscribeUserErrorTypes } from './OneClickTypes-DjOesaHp.js';
|
|
3
|
-
import { useSelector } from 'react-redux';
|
|
4
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
5
|
-
import * as redux from 'redux';
|
|
6
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
7
|
-
import * as _reduxjs_toolkit_dist_createAsyncThunk from '@reduxjs/toolkit/dist/createAsyncThunk';
|
|
8
|
-
import { I as IHash } from './IHash-0OgZ_1ij.js';
|
|
9
|
-
|
|
10
|
-
declare const useOneClickFlowState: (useSelector: typeof useSelector) => OneClickFlowCurrentState;
|
|
11
|
-
|
|
12
|
-
declare function oneClickFlowMatch<R>({ getRedirectUrl, subscribe }: {
|
|
13
|
-
getRedirectUrl: (rds: RemoteDataState<IGETREDIRECTURLFailure, IGETREDIRECTURLSuccess>) => R;
|
|
14
|
-
subscribe?: (rds: RemoteDataState<SubscribeFailure, SubscribeSuccess>) => R;
|
|
15
|
-
}): (state: OneClickFlowCurrentState) => R;
|
|
16
|
-
|
|
17
|
-
interface GetRedirectUrlArgs {
|
|
18
|
-
window: Window;
|
|
19
|
-
extraParams?: IHash;
|
|
20
|
-
autoRedirect?: boolean;
|
|
21
|
-
isGetRedirectBupperWay?: boolean;
|
|
22
|
-
ignoreUrlParams?: boolean;
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* getRedirectUrlAction
|
|
26
|
-
* @returns {type: ' 'oneClickFlow/getRedirectUrlAction', payload: {type: PossibleTypes, result: GETREDIRECTUrlState}}
|
|
27
|
-
|
|
28
|
-
* Calls redirect api to get a redirect url for the user to be redirected to
|
|
29
|
-
* Can also create a bupper redirect url
|
|
30
|
-
*/
|
|
31
|
-
declare const getRedirectUrlAction: _reduxjs_toolkit.AsyncThunk<GETREDIRECTUrlState, GetRedirectUrlArgs, _reduxjs_toolkit_dist_createAsyncThunk.AsyncThunkConfig>;
|
|
32
|
-
/**
|
|
33
|
-
* subscribeUrlAction
|
|
34
|
-
* @returns {type: ' 'oneClickFlow/submitMSISDNAction', payload: {type: PossibleTypes.MO, result: PINEntryState}}
|
|
35
|
-
|
|
36
|
-
* Calls oneclick subscripe api to subscribe the user
|
|
37
|
-
* Returns a product url
|
|
38
|
-
*/
|
|
39
|
-
interface OneClickSubscribeArgs {
|
|
40
|
-
window: Window;
|
|
41
|
-
autoRedirect?: boolean;
|
|
42
|
-
extraParams?: IHash;
|
|
43
|
-
}
|
|
44
|
-
declare const subscribeUrlAction: _reduxjs_toolkit.AsyncThunk<AJAXSUBSCRIBEState, OneClickSubscribeArgs, {
|
|
45
|
-
rejectValue: SubscribeFailure;
|
|
46
|
-
state?: unknown;
|
|
47
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
48
|
-
extra?: unknown;
|
|
49
|
-
serializedErrorType?: unknown;
|
|
50
|
-
pendingMeta?: unknown;
|
|
51
|
-
fulfilledMeta?: unknown;
|
|
52
|
-
rejectedMeta?: unknown;
|
|
53
|
-
}>;
|
|
54
|
-
declare const oneClickFlowReducer: redux.Reducer<OneClickFlowState, redux.UnknownAction, OneClickFlowState>;
|
|
55
|
-
|
|
56
|
-
export { AJAXSUBSCRIBEState, GETREDIRECTUrlState, IGETREDIRECTURLFailure, IGETREDIRECTURLSuccess, OneClickFlowCurrentState, OneClickFlowState, SubscribeFailure, SubscribeSuccess, getRedirectUrlAction, oneClickFlowMatch, oneClickFlowReducer, subscribeUrlAction, useOneClickFlowState };
|
package/dist/types/pinFlow.d.ts
DELETED
|
@@ -1,179 +0,0 @@
|
|
|
1
|
-
import { P as PinFlowCurrentState, M as MSISDNEntryFailure, a as MSISDNEntrySuccess, b as PINEntryFailure, c as PINEntrySuccess, I as IMsisdnSumbitNextData, d as PINEntryState, e as PINEntryErrorTypes, f as IHash } from './PinTypes-BLJDBZe6.js';
|
|
2
|
-
export { E as ExtraData, n as IBackToStartPayload, o as IConfig, p as IMSISDNSubmissionResult, s as IMcpShieldResult, t as IMockPinFlowStates, k as IMsisdnSubmitErrorPayload, j as IMsisnSubmitActionPayload, q as IPINSubmissionResult, m as IPinErrorPayload, l as IPinSubmitPayload, i as MSISDNEntryErrorTypes, g as MSISDNEntryState, r as MultiOperatorMSISDNSubmissionResult, h as PinFlowState, S as SingleMSISDNSubmissionResult } from './PinTypes-BLJDBZe6.js';
|
|
3
|
-
import { useSelector } from 'react-redux';
|
|
4
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
5
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
6
|
-
import * as redux from 'redux';
|
|
7
|
-
|
|
8
|
-
declare const usePinFlowState: (useSelector: typeof useSelector) => PinFlowCurrentState;
|
|
9
|
-
|
|
10
|
-
declare function pinFlowMatch<R>({ msisdnEntry, pinEntry }: {
|
|
11
|
-
msisdnEntry: (rds: RemoteDataState<MSISDNEntryFailure, MSISDNEntrySuccess>) => R;
|
|
12
|
-
pinEntry: (rds: RemoteDataState<PINEntryFailure, PINEntrySuccess>, nextData: IMsisdnSumbitNextData) => R;
|
|
13
|
-
}): (state: PinFlowCurrentState) => R;
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* submitMSISDNAction
|
|
17
|
-
* @returns {type: ' 'pinFlow/submitMSISDNAction', payload: {type: PossibleTypes.MO, result: PINEntryState}}
|
|
18
|
-
|
|
19
|
-
* Calls trigger-pin api that sends a pin to the user
|
|
20
|
-
* Sets state to show pin entry
|
|
21
|
-
*/
|
|
22
|
-
interface SubmitMSISDNArgs {
|
|
23
|
-
window: Window;
|
|
24
|
-
msisdn: string;
|
|
25
|
-
extraParams?: IHash;
|
|
26
|
-
}
|
|
27
|
-
declare const submitMSISDNAction: _reduxjs_toolkit.AsyncThunk<PINEntryState, SubmitMSISDNArgs, {
|
|
28
|
-
rejectValue: MSISDNEntryFailure;
|
|
29
|
-
state?: unknown;
|
|
30
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
31
|
-
extra?: unknown;
|
|
32
|
-
serializedErrorType?: unknown;
|
|
33
|
-
pendingMeta?: unknown;
|
|
34
|
-
fulfilledMeta?: unknown;
|
|
35
|
-
rejectedMeta?: unknown;
|
|
36
|
-
}>;
|
|
37
|
-
/**
|
|
38
|
-
* submitPinAction
|
|
39
|
-
* @returns {type: ' 'pinFlow/submitMSISDNAction', payload: {type: 'PINEntry', result: RDS.NothingYet()}}
|
|
40
|
-
|
|
41
|
-
* Calls verify-pin api that check if the user enters a valid pin
|
|
42
|
-
* Sets state to show thank you page if pin is valid
|
|
43
|
-
*/
|
|
44
|
-
interface SubmitPINArgs {
|
|
45
|
-
window: Window;
|
|
46
|
-
msisdn: string;
|
|
47
|
-
pin: string;
|
|
48
|
-
extraParams?: IHash;
|
|
49
|
-
}
|
|
50
|
-
declare const submitPinAction: _reduxjs_toolkit.AsyncThunk<PINEntryState, SubmitPINArgs, {
|
|
51
|
-
rejectValue: PINEntryFailure;
|
|
52
|
-
state?: unknown;
|
|
53
|
-
dispatch?: redux.Dispatch<redux.UnknownAction>;
|
|
54
|
-
extra?: unknown;
|
|
55
|
-
serializedErrorType?: unknown;
|
|
56
|
-
pendingMeta?: unknown;
|
|
57
|
-
fulfilledMeta?: unknown;
|
|
58
|
-
rejectedMeta?: unknown;
|
|
59
|
-
}>;
|
|
60
|
-
declare const pinFlowReducer: redux.Reducer<{
|
|
61
|
-
currentState: {
|
|
62
|
-
type: "MSISDNEntry";
|
|
63
|
-
result: {
|
|
64
|
-
type: "NothingYet";
|
|
65
|
-
} | {
|
|
66
|
-
type: "Loading";
|
|
67
|
-
} | {
|
|
68
|
-
type: "Failure";
|
|
69
|
-
error: {
|
|
70
|
-
errorType: string;
|
|
71
|
-
error?: any;
|
|
72
|
-
productUrl?: string;
|
|
73
|
-
};
|
|
74
|
-
} | {
|
|
75
|
-
type: "Success";
|
|
76
|
-
data: {
|
|
77
|
-
[x: string]: unknown;
|
|
78
|
-
};
|
|
79
|
-
};
|
|
80
|
-
data?: {
|
|
81
|
-
actualPIN: string;
|
|
82
|
-
msisdn: string;
|
|
83
|
-
operator: string;
|
|
84
|
-
pinMaxLength: number;
|
|
85
|
-
};
|
|
86
|
-
} | {
|
|
87
|
-
type: "PINEntry";
|
|
88
|
-
result: {
|
|
89
|
-
type: "NothingYet";
|
|
90
|
-
} | {
|
|
91
|
-
type: "Loading";
|
|
92
|
-
} | {
|
|
93
|
-
type: "Failure";
|
|
94
|
-
error: {
|
|
95
|
-
errorType: PINEntryErrorTypes;
|
|
96
|
-
error?: {
|
|
97
|
-
name: string;
|
|
98
|
-
message: string;
|
|
99
|
-
stack?: string;
|
|
100
|
-
};
|
|
101
|
-
productUrl?: string;
|
|
102
|
-
};
|
|
103
|
-
} | {
|
|
104
|
-
type: "Success";
|
|
105
|
-
data: {
|
|
106
|
-
finalUrl: string;
|
|
107
|
-
msisdn?: string;
|
|
108
|
-
isAlreadySubscribed?: boolean;
|
|
109
|
-
};
|
|
110
|
-
};
|
|
111
|
-
data?: {
|
|
112
|
-
actualPIN: string;
|
|
113
|
-
msisdn: string;
|
|
114
|
-
operator: string;
|
|
115
|
-
pinMaxLength: number;
|
|
116
|
-
};
|
|
117
|
-
};
|
|
118
|
-
}, redux.UnknownAction, {
|
|
119
|
-
currentState: {
|
|
120
|
-
type: "MSISDNEntry";
|
|
121
|
-
result: {
|
|
122
|
-
type: "NothingYet";
|
|
123
|
-
} | {
|
|
124
|
-
type: "Loading";
|
|
125
|
-
} | {
|
|
126
|
-
type: "Failure";
|
|
127
|
-
error: {
|
|
128
|
-
errorType: string;
|
|
129
|
-
error?: any;
|
|
130
|
-
productUrl?: string;
|
|
131
|
-
};
|
|
132
|
-
} | {
|
|
133
|
-
type: "Success";
|
|
134
|
-
data: {
|
|
135
|
-
[x: string]: unknown;
|
|
136
|
-
};
|
|
137
|
-
};
|
|
138
|
-
data?: {
|
|
139
|
-
actualPIN: string;
|
|
140
|
-
msisdn: string;
|
|
141
|
-
operator: string;
|
|
142
|
-
pinMaxLength: number;
|
|
143
|
-
};
|
|
144
|
-
} | {
|
|
145
|
-
type: "PINEntry";
|
|
146
|
-
result: {
|
|
147
|
-
type: "NothingYet";
|
|
148
|
-
} | {
|
|
149
|
-
type: "Loading";
|
|
150
|
-
} | {
|
|
151
|
-
type: "Failure";
|
|
152
|
-
error: {
|
|
153
|
-
errorType: PINEntryErrorTypes;
|
|
154
|
-
error?: {
|
|
155
|
-
name: string;
|
|
156
|
-
message: string;
|
|
157
|
-
stack?: string;
|
|
158
|
-
};
|
|
159
|
-
productUrl?: string;
|
|
160
|
-
};
|
|
161
|
-
} | {
|
|
162
|
-
type: "Success";
|
|
163
|
-
data: {
|
|
164
|
-
finalUrl: string;
|
|
165
|
-
msisdn?: string;
|
|
166
|
-
isAlreadySubscribed?: boolean;
|
|
167
|
-
};
|
|
168
|
-
};
|
|
169
|
-
data?: {
|
|
170
|
-
actualPIN: string;
|
|
171
|
-
msisdn: string;
|
|
172
|
-
operator: string;
|
|
173
|
-
pinMaxLength: number;
|
|
174
|
-
};
|
|
175
|
-
};
|
|
176
|
-
}>;
|
|
177
|
-
declare const backToStartAction: _reduxjs_toolkit.ActionCreatorWithoutPayload<"pinFlow/backToStartAction">;
|
|
178
|
-
|
|
179
|
-
export { IHash, IMsisdnSumbitNextData, MSISDNEntryFailure, MSISDNEntrySuccess, PINEntryErrorTypes, PINEntryFailure, PINEntryState, PINEntrySuccess, PinFlowCurrentState, backToStartAction, pinFlowMatch, pinFlowReducer, submitMSISDNAction, submitPinAction, usePinFlowState };
|
package/dist/types/strategy.d.ts
DELETED
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import { R as RemoteDataState } from './RemoteDataState-D1aFrz8W.js';
|
|
2
|
-
export { a as RDS } from './RemoteDataState-D1aFrz8W.js';
|
|
3
|
-
import { S as StrategyCurrentState, I as IDENTIFYMSISDNEntryFailure, a as IDENTIFYMSISDNEntrySuccess, P as PossibleTypes, C as ConfigDetails, b as IConfig, c as StrategyState } from './StrategyTypes-CbOgk0N4.js';
|
|
4
|
-
export { Q as ExtraStrategyData, t as IDENTIFYFailure, k as IDENTIFYMSISDNEntryErrorTypes, u as IDENTIFYSuccess, q as IDENTIFY_FLOW_HESuccess, p as IDENTIFY_OPERATOR_MSISDNEntrySuccess, n as IDETECTYOPERATOBYIPFailure, o as IDETECTYOPERATOBYIPSuccess, w as IDetectOperatorByIpPayload, f as IFlow, j as IHash, E as IIdentfyFlowByIPOperatorNextAction, B as IIdentfyFlowByMsisdnNextAction, D as IIdentfyFlowByOperatorNextAction, A as IIdentifyFlowByHePayload, z as IIdentifyFlowByIpOperatorPayload, d as IIdentifyResult, G as IIdenyifyFlowByMsisdnPayload, F as IIdenyifyFlowByMsisdnSumbitNextData, H as IIdenyifyStrategyPayload, M as IMockFlowParams, L as IMockFlows, R as IMockPinFlowStates, v as IOperatorSelectFlowIdentifyPayload, x as IOperatorSelectPayload, N as IScriptHeaderEnrichmentSuccess, h as IStrategy, J as IStrategyCurrentState, K as IStrategyIDentifyUserResult, i as IStrategyNames, y as ISubmitMsisdnPayload, e as ISupportedFlows, l as IdentifyFlowOptionsResult, O as OPERATORSelectFailure, r as OPERATORSelectFlowIdentifyFailure, s as OPERATORSelectFlowIdentifySuccess, m as OPERATORSelectSuccess, T as RootState, g as StrategyConfig } from './StrategyTypes-CbOgk0N4.js';
|
|
5
|
-
import { useSelector } from 'react-redux';
|
|
6
|
-
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
7
|
-
import * as _reduxjs_toolkit_dist_createAsyncThunk from '@reduxjs/toolkit/dist/createAsyncThunk';
|
|
8
|
-
import * as redux from 'redux';
|
|
9
|
-
import './CreditCardTypes-B-IT-l6I.js';
|
|
10
|
-
import './MoRedirTypes-4tEJjT1g.js';
|
|
11
|
-
import './MoTypes-D-UK92gs.js';
|
|
12
|
-
import './OneClickTypes-DjOesaHp.js';
|
|
13
|
-
import './PinTypes-BLJDBZe6.js';
|
|
14
|
-
import './UssdTypes-C7QlIW11.js';
|
|
15
|
-
|
|
16
|
-
declare const useStrategyState: (useSelector: typeof useSelector) => StrategyCurrentState;
|
|
17
|
-
|
|
18
|
-
declare function strategy<R>({ identifyInitialState, identifyFlowByOperatorSelect, identifyFlowByMsisdn, pinFlow, moFlow, moRedirFlow, oneClickFlow, click2smsFlow, ussdFlow, creditCardFlow }: {
|
|
19
|
-
identifyInitialState: () => R;
|
|
20
|
-
identifyFlowByOperatorSelect?: () => R;
|
|
21
|
-
identifyFlowByMsisdn?: (rds: RemoteDataState<IDENTIFYMSISDNEntryFailure, IDENTIFYMSISDNEntrySuccess>) => R;
|
|
22
|
-
pinFlow?: () => R;
|
|
23
|
-
moFlow?: () => R;
|
|
24
|
-
moRedirFlow?: () => R;
|
|
25
|
-
oneClickFlow?: () => R;
|
|
26
|
-
click2smsFlow?: () => R;
|
|
27
|
-
ussdFlow?: () => R;
|
|
28
|
-
creditCardFlow?: () => R;
|
|
29
|
-
}): (state: StrategyCurrentState) => R;
|
|
30
|
-
|
|
31
|
-
declare const submitMSISDNAction: _reduxjs_toolkit.AsyncThunk<StrategyCurrentState | {
|
|
32
|
-
type: PossibleTypes;
|
|
33
|
-
result: RemoteDataState<unknown, unknown>;
|
|
34
|
-
data: {
|
|
35
|
-
operator: string;
|
|
36
|
-
config: ConfigDetails;
|
|
37
|
-
};
|
|
38
|
-
}, {
|
|
39
|
-
window: Window;
|
|
40
|
-
msisdn: string;
|
|
41
|
-
isHeSuccess?: boolean;
|
|
42
|
-
}, _reduxjs_toolkit_dist_createAsyncThunk.AsyncThunkConfig>;
|
|
43
|
-
|
|
44
|
-
declare const selectOperatorAction: _reduxjs_toolkit.AsyncThunk<{
|
|
45
|
-
type: PossibleTypes;
|
|
46
|
-
result: {
|
|
47
|
-
config: ConfigDetails;
|
|
48
|
-
operator: string;
|
|
49
|
-
autoRedirect?: undefined;
|
|
50
|
-
};
|
|
51
|
-
} | {
|
|
52
|
-
type: PossibleTypes;
|
|
53
|
-
result: {
|
|
54
|
-
config: ConfigDetails;
|
|
55
|
-
operator: string;
|
|
56
|
-
autoRedirect: boolean;
|
|
57
|
-
};
|
|
58
|
-
} | {
|
|
59
|
-
type: PossibleTypes;
|
|
60
|
-
result: RemoteDataState<unknown, unknown>;
|
|
61
|
-
}, {
|
|
62
|
-
operator: string;
|
|
63
|
-
}, _reduxjs_toolkit_dist_createAsyncThunk.AsyncThunkConfig>;
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* Identify Strategy
|
|
67
|
-
* @returns {type: 'strategy/identifyStrategy', payload: {type: PossibleTypes.MO, result: IdentifyFlowOptionsResult}}
|
|
68
|
-
* - Add type
|
|
69
|
-
* - Makes a decision on which strategy to use in order to identify the flow
|
|
70
|
-
* - Strategy could be asking user's phone number, selecting an operator etc
|
|
71
|
-
* - all with the intension of getting the flow and its configuration
|
|
72
|
-
* - Flows are usually tied to an operator in the pages config.json
|
|
73
|
-
* - But they could also be single flows
|
|
74
|
-
*
|
|
75
|
-
*/
|
|
76
|
-
declare const identifyStrategy: _reduxjs_toolkit.AsyncThunk<StrategyCurrentState | {
|
|
77
|
-
type: PossibleTypes;
|
|
78
|
-
result: RemoteDataState<unknown, unknown>;
|
|
79
|
-
data: {
|
|
80
|
-
config: ConfigDetails;
|
|
81
|
-
operator: string;
|
|
82
|
-
};
|
|
83
|
-
} | {
|
|
84
|
-
type: PossibleTypes;
|
|
85
|
-
result: RemoteDataState<unknown, unknown>;
|
|
86
|
-
data: {
|
|
87
|
-
config: IConfig;
|
|
88
|
-
msisdn: string;
|
|
89
|
-
operator: string;
|
|
90
|
-
};
|
|
91
|
-
}, void, _reduxjs_toolkit_dist_createAsyncThunk.AsyncThunkConfig>;
|
|
92
|
-
declare const strategyReducer: redux.Reducer<StrategyState, redux.UnknownAction, StrategyState>;
|
|
93
|
-
|
|
94
|
-
export { ConfigDetails, IConfig, IDENTIFYMSISDNEntryFailure, IDENTIFYMSISDNEntrySuccess, PossibleTypes, StrategyCurrentState, StrategyState, identifyStrategy, selectOperatorAction, strategy, strategyReducer, submitMSISDNAction, useStrategyState };
|