@lysaab/lysa-pep 3.0.2 → 3.0.4

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.
Files changed (44) hide show
  1. package/Exports.d.ts +7 -7
  2. package/Exports.js +7 -7
  3. package/components/CountrySelect.d.ts +11 -11
  4. package/components/CountrySelect.js +41 -41
  5. package/components/PepAnswers.d.ts +8 -8
  6. package/components/PepAnswers.js +137 -137
  7. package/messages/src/pages/IsPep/IsPepMessages.json +1 -1
  8. package/messages/src/pages/RelationPage/RelationMessages.json +1 -1
  9. package/messages/src/pages/StatusPage/StatusMessages.json +1 -1
  10. package/model/PepModel.d.ts +7 -7
  11. package/model/PepModel.js +40 -40
  12. package/package.json +1 -1
  13. package/pages/IsPep/IsPepMessages.d.ts +32 -32
  14. package/pages/IsPep/IsPepMessages.js +38 -34
  15. package/pages/IsPep/IsPepPage.d.ts +15 -15
  16. package/pages/IsPep/IsPepPage.js +61 -61
  17. package/pages/PepContext.d.ts +81 -80
  18. package/pages/PepContext.js +89 -88
  19. package/pages/RelationPage/RelationMessages.d.ts +105 -105
  20. package/pages/RelationPage/RelationMessages.js +112 -107
  21. package/pages/RelationPage/RelationPage.d.ts +6 -6
  22. package/pages/RelationPage/RelationPage.js +156 -156
  23. package/pages/RolePage/RoleMessages.d.ts +185 -185
  24. package/pages/RolePage/RoleMessages.js +187 -187
  25. package/pages/RolePage/RolePage.d.ts +11 -11
  26. package/pages/RolePage/RolePage.js +223 -223
  27. package/pages/StatusPage/StatusMessages.d.ts +72 -72
  28. package/pages/StatusPage/StatusMessages.js +82 -74
  29. package/pages/StatusPage/StatusPage.d.ts +8 -8
  30. package/pages/StatusPage/StatusPage.js +105 -105
  31. package/utils/Possession.d.ts +1 -1
  32. package/utils/Possession.js +27 -27
  33. package/model/Countries.d.ts +0 -4
  34. package/model/Countries.js +0 -1002
  35. package/model/PepTexts.d.ts +0 -380
  36. package/model/PepTexts.js +0 -552
  37. package/pages/PepIsPepPage.d.ts +0 -15
  38. package/pages/PepIsPepPage.js +0 -59
  39. package/pages/PepRelationPage.d.ts +0 -6
  40. package/pages/PepRelationPage.js +0 -79
  41. package/pages/PepRolePage.d.ts +0 -10
  42. package/pages/PepRolePage.js +0 -127
  43. package/pages/PepStatusPage.d.ts +0 -6
  44. package/pages/PepStatusPage.js +0 -58
package/model/PepModel.js CHANGED
@@ -1,40 +1,40 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import { PepType, EntityType, PepStatus } from "../pages/PepContext";
13
- import { DateTime } from "luxon";
14
- export function stateToRequest(pepState) {
15
- const state = Object.assign({}, pepState);
16
- delete state.isLocalCountry;
17
- delete state.isOngoing;
18
- delete state.ownerName;
19
- if (state.legalEntityType === EntityType.PERSON) {
20
- delete state.tin;
21
- }
22
- return Object.assign(Object.assign({}, state), { country: state.type === PepType.NOT_PEP ? undefined : state.country, ended: state.ended
23
- ? DateTime.fromJSDate(state.ended).toFormat("yyyy-MM")
24
- : undefined, birthdayOfPEP: state.birthdayOfPEP
25
- ? DateTime.fromJSDate(state.birthdayOfPEP).toFormat("yyyy-MM-dd")
26
- : undefined });
27
- }
28
- export function requestToState(_a, countryCode) {
29
- var { ended, birthdayOfPEP } = _a, serverData = __rest(_a, ["ended", "birthdayOfPEP"]);
30
- const state = Object.assign({}, serverData);
31
- if (ended) {
32
- state.ended = DateTime.fromFormat(ended, "yyyy-MM").toJSDate();
33
- }
34
- if (birthdayOfPEP) {
35
- state.birthdayOfPEP = DateTime.fromFormat(birthdayOfPEP, "yyyy-MM-dd").toJSDate();
36
- }
37
- state.isLocalCountry = state.country === countryCode ? "local" : "other";
38
- state.isOngoing = state.ended ? PepStatus.ENDED : PepStatus.ONGOING;
39
- return state;
40
- }
1
+ var __rest = (this && this.__rest) || function (s, e) {
2
+ var t = {};
3
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
+ t[p] = s[p];
5
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
+ t[p[i]] = s[p[i]];
9
+ }
10
+ return t;
11
+ };
12
+ import { PepType, EntityType, PepStatus } from "../pages/PepContext";
13
+ import { DateTime } from "luxon";
14
+ export function stateToRequest(pepState) {
15
+ const state = Object.assign({}, pepState);
16
+ delete state.isLocalCountry;
17
+ delete state.isOngoing;
18
+ delete state.ownerName;
19
+ if (state.legalEntityType === EntityType.PERSON) {
20
+ delete state.tin;
21
+ }
22
+ return Object.assign(Object.assign({}, state), { country: state.type === PepType.NOT_PEP ? undefined : state.country, ended: state.ended
23
+ ? DateTime.fromJSDate(state.ended).toFormat("yyyy-MM")
24
+ : undefined, birthdayOfPEP: state.birthdayOfPEP
25
+ ? DateTime.fromJSDate(state.birthdayOfPEP).toFormat("yyyy-MM-dd")
26
+ : undefined });
27
+ }
28
+ export function requestToState(_a, countryCode) {
29
+ var { ended, birthdayOfPEP } = _a, serverData = __rest(_a, ["ended", "birthdayOfPEP"]);
30
+ const state = Object.assign({}, serverData);
31
+ if (ended) {
32
+ state.ended = DateTime.fromFormat(ended, "yyyy-MM").toJSDate();
33
+ }
34
+ if (birthdayOfPEP) {
35
+ state.birthdayOfPEP = DateTime.fromFormat(birthdayOfPEP, "yyyy-MM-dd").toJSDate();
36
+ }
37
+ state.isLocalCountry = state.country === countryCode ? "local" : "other";
38
+ state.isOngoing = state.ended ? PepStatus.ENDED : PepStatus.ONGOING;
39
+ return state;
40
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@lysaab/lysa-pep",
3
3
  "author": "Lysa AB",
4
- "version": "3.0.2",
4
+ "version": "3.0.4",
5
5
  "main": "./Exports.js",
6
6
  "dependencies": {
7
7
  "@lysaab/countries": "^3.1.1",
@@ -1,32 +1,32 @@
1
- export declare const messages: {
2
- header: {
3
- id: string;
4
- description: string;
5
- defaultMessage: string;
6
- };
7
- required: {
8
- id: string;
9
- description: string;
10
- defaultMessage: string;
11
- };
12
- NOT_PEP: {
13
- id: string;
14
- description: string;
15
- defaultMessage: string;
16
- };
17
- ME: {
18
- id: string;
19
- description: string;
20
- defaultMessage: string;
21
- };
22
- RELATIVE: {
23
- id: string;
24
- description: string;
25
- defaultMessage: string;
26
- };
27
- COLLEAGUE: {
28
- id: string;
29
- description: string;
30
- defaultMessage: string;
31
- };
32
- };
1
+ export declare const messages: {
2
+ header: {
3
+ id: string;
4
+ description: string;
5
+ defaultMessage: string;
6
+ };
7
+ required: {
8
+ id: string;
9
+ description: string;
10
+ defaultMessage: string;
11
+ };
12
+ NOT_PEP: {
13
+ id: string;
14
+ description: string;
15
+ defaultMessage: string;
16
+ };
17
+ ME: {
18
+ id: string;
19
+ description: string;
20
+ defaultMessage: string;
21
+ };
22
+ RELATIVE: {
23
+ id: string;
24
+ description: string;
25
+ defaultMessage: string;
26
+ };
27
+ COLLEAGUE: {
28
+ id: string;
29
+ description: string;
30
+ defaultMessage: string;
31
+ };
32
+ };
@@ -1,9 +1,9 @@
1
- import { defineMessages } from "react-intl";
2
- import { PepType } from "../PepContext";
3
- export const messages = defineMessages({
4
- header: {
5
- id: "pep.ispep.header",
6
- description: "Is PEP question header",
1
+ import { defineMessages } from "react-intl";
2
+ import { PepType } from "../PepContext";
3
+ export const messages = defineMessages({
4
+ header: {
5
+ id: "pep.ispep.header",
6
+ description: "Is PEP question header",
7
7
  defaultMessage: `{
8
8
  entityType, select,
9
9
  PERSON {
@@ -12,21 +12,22 @@ export const messages = defineMessages({
12
12
  CORPORATION {
13
13
  Is {name} or a person close to {name} a politically exposed person (PEP)?
14
14
  }
15
- }`,
16
- },
17
- required: {
18
- id: "pep.ispep.required",
19
- description: "Required validator text",
20
- defaultMessage: "You need to choose an alternative",
21
- },
22
- [PepType.NOT_PEP]: {
23
- id: "pep.ispep.NOT_PEP",
24
- description: "Not pep",
25
- defaultMessage: "No",
26
- },
27
- [PepType.ME]: {
28
- id: "pep.ispep.ME",
29
- description: "The person is pep",
15
+ other {}
16
+ }`,
17
+ },
18
+ required: {
19
+ id: "pep.ispep.required",
20
+ description: "Required validator text",
21
+ defaultMessage: "You need to choose an alternative",
22
+ },
23
+ [PepType.NOT_PEP]: {
24
+ id: "pep.ispep.NOT_PEP",
25
+ description: "Not pep",
26
+ defaultMessage: "No",
27
+ },
28
+ [PepType.ME]: {
29
+ id: "pep.ispep.ME",
30
+ description: "The person is pep",
30
31
  defaultMessage: `{
31
32
  entityType, select,
32
33
  PERSON {
@@ -35,11 +36,12 @@ export const messages = defineMessages({
35
36
  CORPORATION {
36
37
  {name} is PEP because of his or her role
37
38
  }
38
- }`,
39
- },
40
- [PepType.RELATIVE]: {
41
- id: "pep.ispep.RELATIVE",
42
- description: "I have a relationship with a person that is a PEP",
39
+ other {}
40
+ }`,
41
+ },
42
+ [PepType.RELATIVE]: {
43
+ id: "pep.ispep.RELATIVE",
44
+ description: "I have a relationship with a person that is a PEP",
43
45
  defaultMessage: `{
44
46
  entityType, select,
45
47
  PERSON {
@@ -48,11 +50,12 @@ export const messages = defineMessages({
48
50
  CORPORATION {
49
51
  {name} has a relationship with a PEP
50
52
  }
51
- }`,
52
- },
53
- [PepType.COLLEAGUE]: {
54
- id: "pep.ispep.COLLEAGUE",
55
- description: "The person has a colleague that is a PEP",
53
+ other {}
54
+ }`,
55
+ },
56
+ [PepType.COLLEAGUE]: {
57
+ id: "pep.ispep.COLLEAGUE",
58
+ description: "The person has a colleague that is a PEP",
56
59
  defaultMessage: `{
57
60
  entityType, select,
58
61
  PERSON {
@@ -61,6 +64,7 @@ export const messages = defineMessages({
61
64
  CORPORATION {
62
65
  {name} works for, or has a business relationship with, a PEP
63
66
  }
64
- }`,
65
- },
66
- });
67
+ other {}
68
+ }`,
69
+ },
70
+ });
@@ -1,15 +1,15 @@
1
- import React, { FunctionComponent } from "react";
2
- import { PepType, EntityType } from "../PepContext";
3
- export interface QuestionsProps {
4
- ownerName?: string;
5
- entityType?: EntityType;
6
- type?: PepType;
7
- onChange: (type: PepType) => void;
8
- resetValues?: () => void;
9
- }
10
- export declare const IsPepQuestion: React.FC<QuestionsProps>;
11
- interface Props {
12
- next: () => void;
13
- }
14
- export declare const IsPepPage: FunctionComponent<Props>;
15
- export {};
1
+ import React, { FunctionComponent } from "react";
2
+ import { PepType, EntityType } from "../PepContext";
3
+ export interface QuestionsProps {
4
+ ownerName?: string;
5
+ entityType?: EntityType;
6
+ type?: PepType;
7
+ onChange: (type: PepType) => void;
8
+ resetValues?: () => void;
9
+ }
10
+ export declare const IsPepQuestion: React.FC<QuestionsProps>;
11
+ interface Props {
12
+ next: () => void;
13
+ }
14
+ export declare const IsPepPage: FunctionComponent<Props>;
15
+ export {};
@@ -1,61 +1,61 @@
1
- import React, { useRef, useCallback, useContext, } from "react";
2
- import { Form, RadioGroup, RequiredValidator, PrimaryButton, Card, } from "@lysaab/ui-2";
3
- import { PepType, PepContext, EntityType } from "../PepContext";
4
- import { useIntl, FormattedMessage } from "react-intl";
5
- import { messages } from "./IsPepMessages";
6
- export const IsPepQuestion = ({ ownerName, entityType, type, onChange, resetValues, }) => {
7
- const intl = useIntl();
8
- const IsPepAlternatives = [
9
- {
10
- text: intl.formatMessage(messages[PepType.NOT_PEP], {
11
- entityType,
12
- name: ownerName,
13
- }),
14
- value: PepType.NOT_PEP,
15
- },
16
- {
17
- text: intl.formatMessage(messages[PepType.ME], {
18
- entityType,
19
- name: ownerName,
20
- }),
21
- value: PepType.ME,
22
- },
23
- {
24
- text: intl.formatMessage(messages[PepType.RELATIVE], {
25
- entityType,
26
- name: ownerName,
27
- }),
28
- value: PepType.RELATIVE,
29
- },
30
- {
31
- text: intl.formatMessage(messages[PepType.COLLEAGUE], {
32
- entityType,
33
- name: ownerName,
34
- }),
35
- value: PepType.COLLEAGUE,
36
- },
37
- ];
38
- return (React.createElement(RadioGroup, { alternatives: IsPepAlternatives, onChange: (alternative) => {
39
- onChange(alternative.value);
40
- resetValues === null || resetValues === void 0 ? void 0 : resetValues();
41
- }, value: IsPepAlternatives.find((alt) => alt.value === type), header: intl.formatMessage(messages.header, {
42
- entityType,
43
- name: ownerName,
44
- }), validators: [
45
- new RequiredValidator(intl.formatMessage(messages.required)),
46
- ], "data-test-id": "pep-ispep" }));
47
- };
48
- export const IsPepPage = ({ next }) => {
49
- const pepContext = useContext(PepContext);
50
- const formRef = useRef();
51
- const nextPage = useCallback(() => {
52
- if (formRef.current && formRef.current.isValid) {
53
- next();
54
- }
55
- }, [formRef, next]);
56
- return (React.createElement(Form, { onSubmit: nextPage, lysaFormRef: formRef },
57
- React.createElement(Card, null,
58
- React.createElement(IsPepQuestion, { ownerName: pepContext.state.ownerName, entityType: pepContext.state.legalEntityType || EntityType.PERSON, type: pepContext.state.type, onChange: (type) => pepContext.setState({ type }) })),
59
- React.createElement(PrimaryButton, { block: true, type: "submit" },
60
- React.createElement(FormattedMessage, { id: "pep.ispep.next", description: "Next button", defaultMessage: "Next" }))));
61
- };
1
+ import React, { useRef, useCallback, useContext, } from "react";
2
+ import { Form, RadioGroup, RequiredValidator, PrimaryButton, Card, } from "@lysaab/ui-2";
3
+ import { PepType, PepContext, EntityType } from "../PepContext";
4
+ import { useIntl, FormattedMessage } from "react-intl";
5
+ import { messages } from "./IsPepMessages";
6
+ export const IsPepQuestion = ({ ownerName, entityType, type, onChange, resetValues, }) => {
7
+ const intl = useIntl();
8
+ const IsPepAlternatives = [
9
+ {
10
+ text: intl.formatMessage(messages[PepType.NOT_PEP], {
11
+ entityType,
12
+ name: ownerName,
13
+ }),
14
+ value: PepType.NOT_PEP,
15
+ },
16
+ {
17
+ text: intl.formatMessage(messages[PepType.ME], {
18
+ entityType,
19
+ name: ownerName,
20
+ }),
21
+ value: PepType.ME,
22
+ },
23
+ {
24
+ text: intl.formatMessage(messages[PepType.RELATIVE], {
25
+ entityType,
26
+ name: ownerName,
27
+ }),
28
+ value: PepType.RELATIVE,
29
+ },
30
+ {
31
+ text: intl.formatMessage(messages[PepType.COLLEAGUE], {
32
+ entityType,
33
+ name: ownerName,
34
+ }),
35
+ value: PepType.COLLEAGUE,
36
+ },
37
+ ];
38
+ return (React.createElement(RadioGroup, { alternatives: IsPepAlternatives, onChange: (alternative) => {
39
+ onChange(alternative.value);
40
+ resetValues === null || resetValues === void 0 ? void 0 : resetValues();
41
+ }, value: IsPepAlternatives.find((alt) => alt.value === type), header: intl.formatMessage(messages.header, {
42
+ entityType,
43
+ name: ownerName,
44
+ }), validators: [
45
+ new RequiredValidator(intl.formatMessage(messages.required)),
46
+ ], "data-test-id": "pep-ispep" }));
47
+ };
48
+ export const IsPepPage = ({ next }) => {
49
+ const pepContext = useContext(PepContext);
50
+ const formRef = useRef();
51
+ const nextPage = useCallback(() => {
52
+ if (formRef.current && formRef.current.isValid) {
53
+ next();
54
+ }
55
+ }, [formRef, next]);
56
+ return (React.createElement(Form, { onSubmit: nextPage, lysaFormRef: formRef },
57
+ React.createElement(Card, null,
58
+ React.createElement(IsPepQuestion, { ownerName: pepContext.state.ownerName, entityType: pepContext.state.legalEntityType || EntityType.PERSON, type: pepContext.state.type, onChange: (type) => pepContext.setState({ type }) })),
59
+ React.createElement(PrimaryButton, { block: true, type: "submit" },
60
+ React.createElement(FormattedMessage, { id: "pep.ispep.next", description: "Next button", defaultMessage: "Next" }))));
61
+ };
@@ -1,80 +1,81 @@
1
- import React from "react";
2
- export declare enum EntityType {
3
- PERSON = "PERSON",
4
- CORPORATION = "CORPORATION"
5
- }
6
- export declare enum PepType {
7
- NOT_PEP = "NOT_PEP",
8
- ME = "ME",
9
- RELATIVE = "RELATIVE",
10
- COLLEAGUE = "COLLEAGUE"
11
- }
12
- export declare enum PepStatus {
13
- ONGOING = "ONGOING",
14
- ENDED = "ENDED"
15
- }
16
- export declare enum Role {
17
- HEAD_OF_GOVERNMENT = "HEAD_OF_GOVERNMENT",
18
- MINISTER = "MINISTER",
19
- PARLIMENT_MEMBER = "PARLIMENT_MEMBER",
20
- CENTRAL_BANK_MEMBER = "CENTRAL_BANK_MEMBER",
21
- BOARD_MEMBER_POLITICAL_PARTY = "BOARD_MEMBER_POLITICAL_PARTY",
22
- JUDGE_SUPREME_COURT = "JUDGE_SUPREME_COURT",
23
- JUDGE_OTHER_HIGH_COURT = "JUDGE_OTHER_HIGH_COURT",
24
- REVISION_INSTITUTE = "REVISION_INSTITUTE",
25
- AMBASSADOR = "AMBASSADOR",
26
- MILITARY_OFFICER = "MILITARY_OFFICER",
27
- GOVERNMENT_COMPANY = "GOVERNMENT_COMPANY",
28
- EU_HIGH_RANKING_POSITION = "EU_HIGH_RANKING_POSITION",
29
- HIGH_RANKING_POSITION_INTERNALTIONAL_CORP = "HIGH_RANKING_POSITION_INTERNALTIONAL_CORP"
30
- }
31
- export declare enum Relation {
32
- MARRIED_PARTNER = "MARRIED_PARTNER",
33
- COLIVING_PARTNER = "COLIVING_PARTNER",
34
- CHILD = "CHILD",
35
- PARENT = "PARENT",
36
- CHILD_MARRIED_PARTNER = "CHILD_MARRIED_PARTNER",
37
- CHILD_COLIVING_PARTNER = "CHILD_COLIVING_PARTNER"
38
- }
39
- export declare enum BusinessRelation {
40
- CO_OWNERSHIP = "CO_OWNERSHIP",
41
- CLOSE_CONNECTION = "CLOSE_CONNECTION",
42
- COMPANY_FOR_PEP = "COMPANY_FOR_PEP"
43
- }
44
- export declare enum MilitaryRank {
45
- GENERAL = "GENERAL",
46
- LIEUTENANT_GENERAL = "LIEUTENANT_GENERAL",
47
- MAJOR_GENERAL = "MAJOR_GENERAL",
48
- ADMIRAL = "ADMIRAL",
49
- VICE_ADMIRAL = "VICE_ADMIRAL",
50
- REAR_ADMIRAL = "REAR_ADMIRAL"
51
- }
52
- export interface PepState {
53
- legalEntityType?: EntityType;
54
- type?: PepType;
55
- role?: Role;
56
- country?: string;
57
- ended?: Date;
58
- ambassadorCountry?: string;
59
- militaryRank?: MilitaryRank;
60
- governmentCompany?: string;
61
- governmentCompanyRole?: string;
62
- internationalOrganisation?: string;
63
- internationalOrganisationRole?: string;
64
- relationToPEP?: Relation;
65
- nameOfPEP?: string;
66
- birthdayOfPEP?: Date;
67
- tin?: string;
68
- businessRelation?: BusinessRelation;
69
- isOngoing?: PepStatus;
70
- isLocalCountry?: string;
71
- ownerName?: string;
72
- }
73
- export declare const EMPTY_PEP_STATE: PepState;
74
- export interface PepContextProps {
75
- state: PepState;
76
- setState: (newState: Partial<PepState>) => void;
77
- }
78
- export declare const PepContext: React.Context<PepContextProps>;
79
- export declare const withPep: <P extends object>(Component: React.ComponentType<P>) => React.FC<Omit<P, keyof PepContextProps>>;
80
- export declare const PepContextProvider: React.FC;
1
+ import React from "react";
2
+ export declare enum EntityType {
3
+ PERSON = "PERSON",
4
+ CORPORATION = "CORPORATION"
5
+ }
6
+ export declare enum PepType {
7
+ NOT_PEP = "NOT_PEP",
8
+ ME = "ME",
9
+ RELATIVE = "RELATIVE",
10
+ COLLEAGUE = "COLLEAGUE"
11
+ }
12
+ export declare enum PepStatus {
13
+ ONGOING = "ONGOING",
14
+ ENDED = "ENDED"
15
+ }
16
+ export declare enum Role {
17
+ HEAD_OF_GOVERNMENT = "HEAD_OF_GOVERNMENT",
18
+ MINISTER = "MINISTER",
19
+ PARLIMENT_MEMBER = "PARLIMENT_MEMBER",
20
+ CENTRAL_BANK_MEMBER = "CENTRAL_BANK_MEMBER",
21
+ BOARD_MEMBER_POLITICAL_PARTY = "BOARD_MEMBER_POLITICAL_PARTY",
22
+ JUDGE_SUPREME_COURT = "JUDGE_SUPREME_COURT",
23
+ JUDGE_OTHER_HIGH_COURT = "JUDGE_OTHER_HIGH_COURT",
24
+ REVISION_INSTITUTE = "REVISION_INSTITUTE",
25
+ AMBASSADOR = "AMBASSADOR",
26
+ MILITARY_OFFICER = "MILITARY_OFFICER",
27
+ GOVERNMENT_COMPANY = "GOVERNMENT_COMPANY",
28
+ EU_HIGH_RANKING_POSITION = "EU_HIGH_RANKING_POSITION",
29
+ HIGH_RANKING_POSITION_INTERNALTIONAL_CORP = "HIGH_RANKING_POSITION_INTERNALTIONAL_CORP"
30
+ }
31
+ export declare enum Relation {
32
+ MARRIED_PARTNER = "MARRIED_PARTNER",
33
+ COLIVING_PARTNER = "COLIVING_PARTNER",
34
+ CHILD = "CHILD",
35
+ PARENT = "PARENT",
36
+ CHILD_MARRIED_PARTNER = "CHILD_MARRIED_PARTNER",
37
+ CHILD_COLIVING_PARTNER = "CHILD_COLIVING_PARTNER"
38
+ }
39
+ export declare enum BusinessRelation {
40
+ CO_OWNERSHIP = "CO_OWNERSHIP",
41
+ CLOSE_CONNECTION = "CLOSE_CONNECTION",
42
+ COMPANY_FOR_PEP = "COMPANY_FOR_PEP"
43
+ }
44
+ export declare enum MilitaryRank {
45
+ GENERAL = "GENERAL",
46
+ LIEUTENANT_GENERAL = "LIEUTENANT_GENERAL",
47
+ MAJOR_GENERAL = "MAJOR_GENERAL",
48
+ ADMIRAL = "ADMIRAL",
49
+ VICE_ADMIRAL = "VICE_ADMIRAL",
50
+ REAR_ADMIRAL = "REAR_ADMIRAL"
51
+ }
52
+ export interface PepState {
53
+ legalEntityType?: EntityType;
54
+ type?: PepType;
55
+ role?: Role;
56
+ country?: string;
57
+ ended?: Date;
58
+ ambassadorCountry?: string;
59
+ militaryRank?: MilitaryRank;
60
+ governmentCompany?: string;
61
+ governmentCompanyRole?: string;
62
+ internationalOrganisation?: string;
63
+ internationalOrganisationRole?: string;
64
+ relationToPEP?: Relation;
65
+ nameOfPEP?: string;
66
+ birthdayOfPEP?: Date;
67
+ tin?: string;
68
+ businessRelation?: BusinessRelation;
69
+ locked?: boolean;
70
+ isOngoing?: PepStatus;
71
+ isLocalCountry?: string;
72
+ ownerName?: string;
73
+ }
74
+ export declare const EMPTY_PEP_STATE: PepState;
75
+ export interface PepContextProps {
76
+ state: PepState;
77
+ setState: (newState: Partial<PepState>) => void;
78
+ }
79
+ export declare const PepContext: React.Context<PepContextProps>;
80
+ export declare const withPep: <P extends object>(Component: React.ComponentType<P>) => React.FC<Omit<P, keyof PepContextProps>>;
81
+ export declare const PepContextProvider: React.FC;