@lifeready/core 6.0.4 → 6.1.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.
Files changed (99) hide show
  1. package/bundles/lifeready-core.umd.js +3482 -7309
  2. package/bundles/lifeready-core.umd.js.map +1 -1
  3. package/bundles/lifeready-core.umd.min.js +1 -1
  4. package/bundles/lifeready-core.umd.min.js.map +1 -1
  5. package/esm2015/lib/auth2/auth.config.js +57 -0
  6. package/esm2015/lib/auth2/auth2.gql.private.js +8 -1
  7. package/esm2015/lib/auth2/auth2.service.js +3 -4
  8. package/esm2015/lib/auth2/auth2.types.js +1 -1
  9. package/esm2015/lib/file-upload/file-upload.service.js +17 -12
  10. package/esm2015/lib/idle/idle.service.js +1 -2
  11. package/esm2015/lib/item2/item2.service.js +15 -45
  12. package/esm2015/lib/item2/item2.types.js +1 -1
  13. package/esm2015/lib/key/key-meta.service.js +16 -8
  14. package/esm2015/lib/key-exchange/key-exchange2.service.js +6 -25
  15. package/esm2015/lib/life-ready.module.js +2 -9
  16. package/esm2015/lib/password/password.service.js +1 -1
  17. package/esm2015/lib/profile/profile-details.service.js +120 -75
  18. package/esm2015/lib/profile/profile.gql.js +134 -1
  19. package/esm2015/lib/profile/profile.service.js +8 -5
  20. package/esm2015/lib/profile/profile.types.js +14 -3
  21. package/esm2015/lib/shared-contact-card/shared-contact-card.service.js +2 -2
  22. package/esm2015/lib/tp-password-reset/tp-password-reset.types.js +1 -1
  23. package/esm2015/lib/trusted-party/trusted-party2.service.js +3 -7
  24. package/esm2015/lifeready-core.js +7 -9
  25. package/esm2015/public-api.js +2 -20
  26. package/fesm2015/lifeready-core.js +3207 -6516
  27. package/fesm2015/lifeready-core.js.map +1 -1
  28. package/lib/auth2/auth2.gql.private.d.ts +15 -2
  29. package/lib/auth2/auth2.service.d.ts +1 -1
  30. package/lib/auth2/auth2.types.d.ts +19 -2
  31. package/lib/file-upload/file-upload.service.d.ts +3 -3
  32. package/lib/item2/item2.service.d.ts +11 -74
  33. package/lib/item2/item2.types.d.ts +1 -1
  34. package/lib/key/key-meta.service.d.ts +8 -1
  35. package/lib/key-exchange/key-exchange2.service.d.ts +5 -66
  36. package/lib/password/password.service.d.ts +1 -1
  37. package/lib/profile/profile-details.service.d.ts +10 -11
  38. package/lib/profile/profile.gql.d.ts +12 -0
  39. package/lib/profile/profile.service.d.ts +1 -3
  40. package/lib/profile/profile.types.d.ts +31 -4
  41. package/lib/shared-contact-card/shared-contact-card.service.d.ts +1 -2
  42. package/lib/tp-password-reset/tp-password-reset.types.d.ts +3 -3
  43. package/lib/trusted-party/trusted-party2.service.d.ts +2 -7
  44. package/lifeready-core.d.ts +6 -8
  45. package/lifeready-core.metadata.json +1 -1
  46. package/package.json +1 -1
  47. package/public-api.d.ts +1 -19
  48. package/esm2015/lib/auth/auth.config.js +0 -57
  49. package/esm2015/lib/auth/auth.gql.js +0 -16
  50. package/esm2015/lib/auth/auth.types.js +0 -18
  51. package/esm2015/lib/auth/life-ready-auth.service.js +0 -568
  52. package/esm2015/lib/category/category-meta.service.js +0 -99
  53. package/esm2015/lib/category/category.gql.js +0 -385
  54. package/esm2015/lib/category/category.service.js +0 -361
  55. package/esm2015/lib/category/category.types.js +0 -29
  56. package/esm2015/lib/key-exchange/key-exchange.gql.js +0 -188
  57. package/esm2015/lib/key-exchange/key-exchange.service.js +0 -436
  58. package/esm2015/lib/key-exchange/key-exchange.types.js +0 -7
  59. package/esm2015/lib/message/message.gql.js +0 -32
  60. package/esm2015/lib/message/message.service.js +0 -118
  61. package/esm2015/lib/message/message.types.js +0 -2
  62. package/esm2015/lib/plan/plan.gql.js +0 -123
  63. package/esm2015/lib/plan/plan.service.js +0 -150
  64. package/esm2015/lib/plan/plan.types.js +0 -11
  65. package/esm2015/lib/record/record-attachment.service.js +0 -102
  66. package/esm2015/lib/record/record.gql.js +0 -182
  67. package/esm2015/lib/record/record.service.js +0 -194
  68. package/esm2015/lib/record/record.types.js +0 -15
  69. package/esm2015/lib/record-type/record-type.service.js +0 -75
  70. package/esm2015/lib/record-type/record-type.types.js +0 -28
  71. package/esm2015/lib/trusted-party/trusted-party.gql.js +0 -148
  72. package/esm2015/lib/trusted-party/trusted-party.service.js +0 -308
  73. package/esm2015/lib/trusted-party/trusted-party.types.js +0 -41
  74. package/lib/auth/auth.gql.d.ts +0 -12
  75. package/lib/auth/auth.types.d.ts +0 -52
  76. package/lib/auth/life-ready-auth.service.d.ts +0 -73
  77. package/lib/category/category-meta.service.d.ts +0 -23
  78. package/lib/category/category.gql.d.ts +0 -44
  79. package/lib/category/category.service.d.ts +0 -66
  80. package/lib/category/category.types.d.ts +0 -75
  81. package/lib/key-exchange/key-exchange.gql.d.ts +0 -9
  82. package/lib/key-exchange/key-exchange.service.d.ts +0 -37
  83. package/lib/key-exchange/key-exchange.types.d.ts +0 -188
  84. package/lib/message/message.gql.d.ts +0 -13
  85. package/lib/message/message.service.d.ts +0 -36
  86. package/lib/message/message.types.d.ts +0 -12
  87. package/lib/plan/plan.gql.d.ts +0 -11
  88. package/lib/plan/plan.service.d.ts +0 -34
  89. package/lib/plan/plan.types.d.ts +0 -32
  90. package/lib/record/record-attachment.service.d.ts +0 -16
  91. package/lib/record/record.gql.d.ts +0 -14
  92. package/lib/record/record.service.d.ts +0 -25
  93. package/lib/record/record.types.d.ts +0 -56
  94. package/lib/record-type/record-type.service.d.ts +0 -11
  95. package/lib/record-type/record-type.types.d.ts +0 -50
  96. package/lib/trusted-party/trusted-party.gql.d.ts +0 -9
  97. package/lib/trusted-party/trusted-party.service.d.ts +0 -43
  98. package/lib/trusted-party/trusted-party.types.d.ts +0 -101
  99. /package/lib/{auth → auth2}/auth.config.d.ts +0 -0
@@ -1,16 +0,0 @@
1
- import { LrApolloService } from '../api/lr-apollo.service';
2
- import { FileUploadService } from '../file-upload/file-upload.service';
3
- import { KeyGraphService } from '../key/key-graph.service';
4
- import { KeyMetaService } from '../key/key-meta.service';
5
- import { NewOrUpdatedAttachment } from './record.types';
6
- export declare class RecordAttachmentService {
7
- private fileUploadService;
8
- private lrApollo;
9
- private keyMetaService;
10
- private keyGraph;
11
- constructor(fileUploadService: FileUploadService, lrApollo: LrApolloService, keyMetaService: KeyMetaService, keyGraph: KeyGraphService);
12
- downloadAttachment(fileStateNodeId: string, keyId: string): Promise<any>;
13
- uploadAttachments(recordId: string, attachments: NewOrUpdatedAttachment[]): Promise<string[]>;
14
- private addAttachment;
15
- deleteAttachment(fileId: string): Promise<void>;
16
- }
@@ -1,14 +0,0 @@
1
- export declare enum FileType {
2
- RecordContent = "record-content",
3
- RecordAttachment = "record-attachment"
4
- }
5
- export declare const RecordContentFilter: string;
6
- export declare const RecordAttachmentFilter: string;
7
- export declare const GetRecordQuery: (depth?: number) => import("graphql").DocumentNode;
8
- export declare const CreateRecordContainerMutation: import("graphql").DocumentNode;
9
- export declare const CreateRecordMutation: import("graphql").DocumentNode;
10
- export declare const UpdateRecordContainerMutation: import("graphql").DocumentNode;
11
- export declare const UpdateRecordMutation: import("graphql").DocumentNode;
12
- export declare const DeleteRecordMutation: import("graphql").DocumentNode;
13
- export declare const CreateFileMutation: import("graphql").DocumentNode;
14
- export declare const DeleteFileMutation: import("graphql").DocumentNode;
@@ -1,25 +0,0 @@
1
- import { LrApolloService } from '../api/lr-apollo.service';
2
- import { CategoryService } from '../category/category.service';
3
- import { KeyMetaService } from '../key/key-meta.service';
4
- import { RecordAttachmentService } from './record-attachment.service';
5
- import { LrRecord, NewRecord, UpdatedRecord } from './record.types';
6
- export declare class RecordService {
7
- private lrApollo;
8
- private keyMetaService;
9
- private categoryService;
10
- private recordAttachmentService;
11
- constructor(lrApollo: LrApolloService, keyMetaService: KeyMetaService, categoryService: CategoryService, recordAttachmentService: RecordAttachmentService);
12
- getRecord(recordId: string): Promise<LrRecord>;
13
- private mapAttachments;
14
- createRecord(newRecord: NewRecord): Promise<{
15
- recordId: string;
16
- attachmentError?: Error;
17
- }>;
18
- updateRecord(recordId: string, updateId: string, updateKeyId: string, updatedRecord: UpdatedRecord): Promise<{
19
- recordId: string;
20
- attachmentError?: Error;
21
- }>;
22
- archiveRecord(recordId: string): Promise<void>;
23
- unarchiveRecord(recordId: string): Promise<void>;
24
- deleteRecord(recordId: string): Promise<void>;
25
- }
@@ -1,56 +0,0 @@
1
- import { Category } from '../category/category.types';
2
- import { RecordFieldType, RecordTypeFieldOption, RecordTypeSummary } from '../record-type/record-type.types';
3
- export declare type RecordFieldValue = string | string[] | RecordTypeFieldOption | RecordTypeFieldOption[] | RecordField[];
4
- export declare class RecordField {
5
- id?: string;
6
- label: string;
7
- type: RecordFieldType;
8
- value?: RecordFieldValue;
9
- }
10
- export declare class RecordAttachment {
11
- fileId: string;
12
- keyId: string;
13
- fieldId?: string;
14
- contentId: string;
15
- name: string;
16
- fileType: string;
17
- fileSize: number;
18
- lastModified: number | Date;
19
- }
20
- export declare class LrRecord {
21
- id: string;
22
- keyId: string;
23
- updateKeyId: string;
24
- updateId: string;
25
- name: string;
26
- categories?: Category[][];
27
- fields?: RecordField[];
28
- attachments?: RecordAttachment[];
29
- recordType: RecordTypeSummary;
30
- createdOn: string | Date;
31
- lastModified: string | Date;
32
- isArchived: boolean;
33
- isConfidential: boolean;
34
- }
35
- export declare class NewAttachment {
36
- fieldId?: string;
37
- name: string;
38
- file?: File;
39
- }
40
- export declare class NewRecord {
41
- name: string;
42
- recordType: RecordTypeSummary;
43
- categoryIds: string[];
44
- fields?: RecordField[];
45
- attachments?: NewAttachment[];
46
- }
47
- export declare class NewOrUpdatedAttachment extends NewAttachment {
48
- fileId?: string;
49
- isDeleted?: boolean;
50
- }
51
- export declare class UpdatedRecord {
52
- name: string;
53
- recordType: RecordTypeSummary;
54
- fields?: RecordField[];
55
- attachments?: NewOrUpdatedAttachment[];
56
- }
@@ -1,11 +0,0 @@
1
- import { HttpClient } from '@angular/common/http';
2
- import { RecordType } from './record-type.types';
3
- export declare class RecordTypeService {
4
- private http;
5
- private recordTypes;
6
- private categories;
7
- constructor(http: HttpClient);
8
- getRecordTypes(): Promise<RecordType[]>;
9
- getRecordType(recordTypeId: string): Promise<RecordType>;
10
- getRecordTypesForCategory(categoryTree: string[]): Promise<RecordType[]>;
11
- }
@@ -1,50 +0,0 @@
1
- export declare enum RecordFieldType {
2
- Text = "text",
3
- Email = "email",
4
- Url = "url",
5
- Phone = "phone",
6
- Date = "date",
7
- Password = "password",
8
- TextArea = "textArea",
9
- Select = "select",
10
- SingleChoice = "singleChoice",
11
- MultiChoice = "multiChoice",
12
- File = "file",
13
- MultiFile = "multiFile",
14
- Record = "record",
15
- MultiRecord = "multiRecord",
16
- Group = "group",
17
- Custom = "custom"
18
- }
19
- export declare class RecordType {
20
- id: string;
21
- version: number;
22
- name: string;
23
- tags: string[];
24
- allowAttachments: boolean;
25
- allowCustomFields: boolean;
26
- fields: RecordTypeField[];
27
- categories: string[][];
28
- categoryNames: string[][];
29
- }
30
- export declare class RecordTypeFieldOption {
31
- name: string;
32
- categories?: string[][];
33
- }
34
- export declare class RecordTypeField {
35
- id: string;
36
- label: string;
37
- type: RecordFieldType;
38
- placeholder?: string;
39
- hint?: string;
40
- isMandatory?: boolean;
41
- options?: RecordTypeFieldOption[];
42
- extensions?: string;
43
- recordTypeIds?: string[];
44
- fields?: RecordTypeField[];
45
- }
46
- export declare class RecordTypeSummary {
47
- id: string;
48
- version: number;
49
- name: string;
50
- }
@@ -1,9 +0,0 @@
1
- export declare const TrustedPartyProperties: string;
2
- export declare const GetTrustedPartiesQuery: import("graphql").DocumentNode;
3
- export declare const GetAllTrustedPartiesQuery: import("graphql").DocumentNode;
4
- export declare const GetTrustedPartyQuery: import("graphql").DocumentNode;
5
- export declare const DeclineTrustedPartyInvitationMutation: import("graphql").DocumentNode;
6
- export declare const CancelTrustedPartyInvitationMutation: import("graphql").DocumentNode;
7
- export declare const DeleteTrustedPartyMutation: import("graphql").DocumentNode;
8
- export declare const ShareCategoryMutation: import("graphql").DocumentNode;
9
- export declare const UnshareCategoryMutation: import("graphql").DocumentNode;
@@ -1,43 +0,0 @@
1
- import { HttpClient } from '@angular/common/http';
2
- import { LrApolloService } from '../api/lr-apollo.service';
3
- import { LifeReadyAuthService } from '../auth/life-ready-auth.service';
4
- import { AccessLevel } from '../category/category.types';
5
- import { EncryptionService } from '../encryption/encryption.service';
6
- import { KeyExchangeService } from '../key-exchange/key-exchange.service';
7
- import { KeyFactoryService } from '../key/key-factory.service';
8
- import { KeyGraphService } from '../key/key-graph.service';
9
- import { KeyService } from '../key/key.service';
10
- import { SharedContactCardService } from '../shared-contact-card/shared-contact-card.service';
11
- import { UserService } from '../user/user.service';
12
- import { AcceptTrustedPartyInvite, ConfirmTrustedPartyInvite, InviteTrustedParty, TrustedParties, TrustedParty, TrustedPartyInvite, TrustedPartyRole, TrustedPartyRoleType } from './trusted-party.types';
13
- export declare class TrustedPartyService {
14
- private http;
15
- private lrApollo;
16
- private sharedContactCardService;
17
- private userService;
18
- private authService;
19
- private keyExchangeService;
20
- private keyGraphService;
21
- private keyService;
22
- private keyFactory;
23
- private encryptionService;
24
- private trustedPartyRoles;
25
- constructor(http: HttpClient, lrApollo: LrApolloService, sharedContactCardService: SharedContactCardService, userService: UserService, authService: LifeReadyAuthService, keyExchangeService: KeyExchangeService, keyGraphService: KeyGraphService, keyService: KeyService, keyFactory: KeyFactoryService, encryptionService: EncryptionService);
26
- getTrustedParties(): Promise<TrustedParty[]>;
27
- getAllTrustedParties(): Promise<TrustedParties>;
28
- getTrustedParty(partyId: string): Promise<TrustedParty>;
29
- getTrustedPartyRoles(roleType?: TrustedPartyRoleType): Promise<TrustedPartyRole[]>;
30
- inviteTrustedParty(invite: InviteTrustedParty): Promise<void>;
31
- cancelInvitation(inviteId: string): Promise<void>;
32
- getInvitation(inviteId: string, inviteToken: string, key: string): Promise<TrustedPartyInvite>;
33
- acceptInvitation(invite: AcceptTrustedPartyInvite): Promise<string>;
34
- declineInvitation(inviteId: string, inviteToken: string): Promise<void>;
35
- confirmInvitation(confirm: ConfirmTrustedPartyInvite): Promise<string>;
36
- removeTrustedParty(partyId: string): Promise<void>;
37
- setCategoryAccessLevel(categoryId: string, keyId: string, trustedParty: TrustedParty, accessLevel?: AccessLevel): Promise<void>;
38
- setRecordAccessLevel(recordId: string, keyId: string, trustedParty: TrustedParty, accessLevel: AccessLevel): Promise<void>;
39
- private shareDirectory;
40
- private unshareDirectory;
41
- mapTrustedParty(tp: any): Promise<TrustedParty>;
42
- private mapInvite;
43
- }
@@ -1,101 +0,0 @@
1
- import { DecryptedOtk, KeyExchangeMessage, PreparedPermissions, UserSharedKey } from '../key-exchange/key-exchange.types';
2
- import { TrustedPartyDetails } from '../profile/profile.types';
3
- import { AccessLevel } from './../category/category.types';
4
- export declare class TrustedPartyRole {
5
- id: string;
6
- name: string;
7
- roleType: TrustedPartyRoleType;
8
- categories: {
9
- category: string[];
10
- accessLevel: AccessLevel;
11
- }[];
12
- }
13
- export declare enum TrustedPartyRoleType {
14
- General = "general",
15
- Scenario = "scenario"
16
- }
17
- export declare enum TrustedPartyType {
18
- User = "user",
19
- Organisation = "organisation"
20
- }
21
- export declare enum TrustedPartyInviteStatus {
22
- Invited = "IN_PROGRESS",
23
- Cancelled = "CANCELLED",
24
- Declined = "DECLINED",
25
- Completed = "COMPLETED"
26
- }
27
- export declare class TrustedParties {
28
- parties: TrustedParty[];
29
- invites: TrustedPartyInvite[];
30
- sentInvites: TrustedPartyInvite[];
31
- }
32
- export declare class SharedTrustedPartyDetails extends TrustedPartyDetails {
33
- id: string;
34
- ownedKeyId: string;
35
- sharedKeyId: string;
36
- }
37
- export declare class TrustedPartyInvite {
38
- id: string;
39
- type: TrustedPartyType;
40
- status: TrustedPartyInviteStatus;
41
- token: string;
42
- tokenExpiry: string | Date;
43
- isExpired: boolean;
44
- isSender: boolean;
45
- actionRequired: boolean;
46
- name: string;
47
- email: string;
48
- details?: TrustedPartyDetails;
49
- message?: KeyExchangeMessage;
50
- mySharedDetails?: TrustedPartyDetails;
51
- mySharedMessage?: KeyExchangeMessage;
52
- rootKeyCipher: string;
53
- pbkCipher: string;
54
- decryptedOtk: DecryptedOtk;
55
- }
56
- export declare class TPFeatures {
57
- sharedVault: SharedVaultFeature;
58
- }
59
- export declare class SharedVaultFeature {
60
- hasAccess: boolean;
61
- }
62
- export declare class TrustedParty {
63
- id: string;
64
- type: TrustedPartyType;
65
- name: string;
66
- hasScenarios: boolean;
67
- hasSharedVault: boolean;
68
- details: TrustedPartyDetails;
69
- mySharedDetails: SharedTrustedPartyDetails;
70
- userSharedKey: UserSharedKey;
71
- username: string;
72
- features: TPFeatures;
73
- }
74
- export declare class FoundTrustedParty {
75
- id: string;
76
- email: string;
77
- username: string;
78
- isTrustedParty: boolean;
79
- isMe: boolean;
80
- }
81
- export declare class InviteTrustedParty {
82
- party: {
83
- username?: string;
84
- email?: string;
85
- name?: string;
86
- message?: string;
87
- };
88
- permissions?: PreparedPermissions;
89
- mySharedDetails: TrustedPartyDetails;
90
- }
91
- export declare class AcceptTrustedPartyInvite {
92
- inviteId: string;
93
- inviteToken: string;
94
- decryptedOtk: DecryptedOtk;
95
- mySharedDetails: TrustedPartyDetails;
96
- }
97
- export declare class ConfirmTrustedPartyInvite {
98
- inviteId: string;
99
- initiatorRootKeyCipher: string;
100
- initiatorOneTimePbkCipher: string;
101
- }
File without changes