cat-documents-ng 1.0.3 → 1.0.5

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 (142) hide show
  1. package/README.md +322 -59
  2. package/Shared/components/confirmation-dialog/confirmation-dialog.component.d.ts +44 -0
  3. package/Shared/components/table-primary/table-primary.component.d.ts +31 -0
  4. package/Shared/components/table-primary/table-primary.model.d.ts +19 -0
  5. package/Shared/constant/ERROR.d.ts +52 -0
  6. package/Shared/constant/SHARED.d.ts +546 -0
  7. package/Shared/constant/URLS.d.ts +123 -0
  8. package/Shared/services/app-config.service.d.ts +51 -0
  9. package/{projects/cat-document-lib/src/shared/services/global-error.handler.ts → Shared/services/global-error.handler.d.ts} +9 -11
  10. package/Shared/services/session.service.d.ts +46 -0
  11. package/Shared/shared.module.d.ts +14 -0
  12. package/fesm2022/cat-documents-ng.mjs +11392 -0
  13. package/fesm2022/cat-documents-ng.mjs.map +1 -0
  14. package/index.d.ts +5 -0
  15. package/lib/document/components/document-actions/document-actions.component.d.ts +78 -0
  16. package/lib/document/components/document-container/document-container.component.d.ts +162 -0
  17. package/lib/document/components/document-content-viewer/document-content-viewer.component.d.ts +291 -0
  18. package/lib/document/components/document-history/document-history.component.d.ts +160 -0
  19. package/lib/document/components/document-list/document-list.component.d.ts +299 -0
  20. package/lib/document/components/document-list-item/document-list-item.component.d.ts +28 -0
  21. package/lib/document/components/document-search/document-search.component.d.ts +77 -0
  22. package/lib/document/components/document-status/document-status.component.d.ts +24 -0
  23. package/lib/document/components/document-upload/document-upload.component.d.ts +321 -0
  24. package/lib/document/components/document-viewer/document-viewer.component.d.ts +137 -0
  25. package/lib/document/components/document-zoom-controls/document-zoom-controls.component.d.ts +33 -0
  26. package/lib/document/components/documents-menu/documents-menu.component.d.ts +110 -0
  27. package/{projects/cat-document-lib/src/lib/document/components/folder-block/folder-block.component.ts → lib/document/components/folder-block/folder-block.component.d.ts} +12 -26
  28. package/lib/document/components/folder-container/folder-container.component.d.ts +162 -0
  29. package/lib/document/components/linked-document/linked-document.component.d.ts +39 -0
  30. package/lib/document/components/request-document/request-document.component.d.ts +69 -0
  31. package/lib/document/components/sidebar/sidebar.component.d.ts +109 -0
  32. package/lib/document/components/user-list/user-list.component.d.ts +34 -0
  33. package/lib/document/constant/DOCUMENT_HISTORY.d.ts +41 -0
  34. package/lib/document/directives/document.directive.d.ts +20 -0
  35. package/lib/document/directives/permission.directive.d.ts +38 -0
  36. package/lib/document/document.module.d.ts +60 -0
  37. package/lib/document/models/document-alert.model.d.ts +38 -0
  38. package/lib/document/models/document-category.model.d.ts +24 -0
  39. package/lib/document/models/document-history.model.d.ts +94 -0
  40. package/lib/document/models/document-list-response.model.d.ts +33 -0
  41. package/lib/document/models/document-type.model.d.ts +37 -0
  42. package/lib/document/models/document.model.d.ts +44 -0
  43. package/{projects/cat-document-lib/src/lib/document/models/folder.model.ts → lib/document/models/folder.model.d.ts} +7 -13
  44. package/lib/document/models/status-data.model.d.ts +27 -0
  45. package/lib/document/models/uploaded-file-response.model.d.ts +7 -0
  46. package/lib/document/models/user-list.model.d.ts +8 -0
  47. package/lib/document/services/csv-parser.service.d.ts +88 -0
  48. package/lib/document/services/document-actions.service.d.ts +48 -0
  49. package/lib/document/services/document-content-type.service.d.ts +85 -0
  50. package/lib/document/services/document-history-style.service.d.ts +34 -0
  51. package/lib/document/services/document-history.service.d.ts +42 -0
  52. package/lib/document/services/document-http.service.d.ts +179 -0
  53. package/lib/document/services/document-list.service.d.ts +74 -0
  54. package/lib/document/services/document-menu.service.d.ts +122 -0
  55. package/lib/document/services/document-scroll.service.d.ts +55 -0
  56. package/lib/document/services/document-table-builder.service.d.ts +38 -0
  57. package/lib/document/services/document-upload-business.service.d.ts +107 -0
  58. package/lib/document/services/document-upload-data.service.d.ts +40 -0
  59. package/lib/document/services/document-upload-form.service.d.ts +41 -0
  60. package/lib/document/services/document-upload.service.d.ts +99 -0
  61. package/lib/document/services/document-viewer.service.d.ts +97 -0
  62. package/lib/document/services/document-zoom.service.d.ts +81 -0
  63. package/lib/document/services/document.service.d.ts +161 -0
  64. package/lib/document/services/eml-parser.service.d.ts +116 -0
  65. package/lib/document/services/excel-parser.service.d.ts +169 -0
  66. package/lib/document/services/file-format.service.d.ts +34 -0
  67. package/lib/document/services/status-calculator.service.d.ts +20 -0
  68. package/lib/document/services/user-list.service.d.ts +29 -0
  69. package/lib/document/state/document.query.d.ts +243 -0
  70. package/{projects/cat-document-lib/src/lib/document/state/document.service.ts → lib/document/state/document.service.d.ts} +15 -46
  71. package/lib/document/state/document.state.d.ts +61 -0
  72. package/lib/document/state/document.store.d.ts +56 -0
  73. package/package.json +19 -57
  74. package/public-api.d.ts +27 -0
  75. package/src/assets/images/Document interface.png +0 -0
  76. package/src/assets/images/Document upload.png +0 -0
  77. package/src/assets/images/Pdf viewer dialog.png +0 -0
  78. package/.github/PULL_REQUEST_TEMPLATE.md +0 -32
  79. package/.husky/pre-commit +0 -4
  80. package/angular.json +0 -119
  81. package/eslint.config.cjs +0 -148
  82. package/projects/cat-document-lib/README.md +0 -63
  83. package/projects/cat-document-lib/ng-package.json +0 -11
  84. package/projects/cat-document-lib/package.json +0 -16
  85. package/projects/cat-document-lib/setup-jest.ts +0 -1
  86. package/projects/cat-document-lib/src/lib/document/components/document-container/document-container.component.html +0 -6
  87. package/projects/cat-document-lib/src/lib/document/components/document-container/document-container.component.scss +0 -0
  88. package/projects/cat-document-lib/src/lib/document/components/document-container/document-container.component.spec.ts +0 -0
  89. package/projects/cat-document-lib/src/lib/document/components/document-container/document-container.component.ts +0 -82
  90. package/projects/cat-document-lib/src/lib/document/components/document-list/document-list.component.html +0 -35
  91. package/projects/cat-document-lib/src/lib/document/components/document-list/document-list.component.scss +0 -12
  92. package/projects/cat-document-lib/src/lib/document/components/document-list/document-list.component.spec.ts +0 -0
  93. package/projects/cat-document-lib/src/lib/document/components/document-list/document-list.component.ts +0 -73
  94. package/projects/cat-document-lib/src/lib/document/components/document-list-item/document-list-item.component.html +0 -33
  95. package/projects/cat-document-lib/src/lib/document/components/document-list-item/document-list-item.component.scss +0 -22
  96. package/projects/cat-document-lib/src/lib/document/components/document-list-item/document-list-item.component.spec.ts +0 -23
  97. package/projects/cat-document-lib/src/lib/document/components/document-list-item/document-list-item.component.ts +0 -40
  98. package/projects/cat-document-lib/src/lib/document/components/document-upload/document-upload.component.html +0 -56
  99. package/projects/cat-document-lib/src/lib/document/components/document-upload/document-upload.component.scss +0 -26
  100. package/projects/cat-document-lib/src/lib/document/components/document-upload/document-upload.component.spec.ts +0 -24
  101. package/projects/cat-document-lib/src/lib/document/components/document-upload/document-upload.component.ts +0 -184
  102. package/projects/cat-document-lib/src/lib/document/components/document-viewer/document-viewer.component.html +0 -244
  103. package/projects/cat-document-lib/src/lib/document/components/document-viewer/document-viewer.component.scss +0 -36
  104. package/projects/cat-document-lib/src/lib/document/components/document-viewer/document-viewer.component.spec.ts +0 -21
  105. package/projects/cat-document-lib/src/lib/document/components/document-viewer/document-viewer.component.ts +0 -125
  106. package/projects/cat-document-lib/src/lib/document/components/folder-block/folder-block.component.html +0 -46
  107. package/projects/cat-document-lib/src/lib/document/components/folder-block/folder-block.component.scss +0 -0
  108. package/projects/cat-document-lib/src/lib/document/components/folder-block/folder-block.component.spec.ts +0 -0
  109. package/projects/cat-document-lib/src/lib/document/components/folder-container/folder-container.component.html +0 -2
  110. package/projects/cat-document-lib/src/lib/document/components/folder-container/folder-container.component.scss +0 -0
  111. package/projects/cat-document-lib/src/lib/document/components/folder-container/folder-container.component.spec.ts +0 -0
  112. package/projects/cat-document-lib/src/lib/document/components/folder-container/folder-container.component.ts +0 -29
  113. package/projects/cat-document-lib/src/lib/document/document.module.ts +0 -187
  114. package/projects/cat-document-lib/src/lib/document/models/document.model.ts +0 -39
  115. package/projects/cat-document-lib/src/lib/document/services/file-format.service.spec.ts +0 -16
  116. package/projects/cat-document-lib/src/lib/document/services/file-format.service.ts +0 -41
  117. package/projects/cat-document-lib/src/lib/document/state/document.query.ts +0 -23
  118. package/projects/cat-document-lib/src/lib/document/state/document.state.ts +0 -39
  119. package/projects/cat-document-lib/src/lib/document/state/document.store.ts +0 -23
  120. package/projects/cat-document-lib/src/public-api.ts +0 -8
  121. package/projects/cat-document-lib/src/shared/constant/SHARED.ts +0 -232
  122. package/projects/cat-document-lib/src/shared/constant/URLS.ts +0 -31
  123. package/projects/cat-document-lib/src/shared/services/app-config.service.spec.ts +0 -16
  124. package/projects/cat-document-lib/src/shared/services/app-config.service.ts +0 -73
  125. package/projects/cat-document-lib/tsconfig.lib.json +0 -15
  126. package/projects/cat-document-lib/tsconfig.lib.prod.json +0 -11
  127. package/projects/cat-document-lib/tsconfig.spec.json +0 -15
  128. package/public/favicon.ico +0 -0
  129. package/src/app/app.component.html +0 -1
  130. package/src/app/app.component.scss +0 -0
  131. package/src/app/app.component.spec.ts +0 -29
  132. package/src/app/app.component.ts +0 -15
  133. package/src/app/app.module.ts +0 -60
  134. package/src/app/app.routing.module.ts +0 -19
  135. package/src/index.html +0 -13
  136. package/src/main.ts +0 -5
  137. package/src/styles.scss +0 -39
  138. package/tsconfig.app.json +0 -15
  139. package/tsconfig.json +0 -32
  140. /package/{projects/cat-document-lib/src → src}/assets/images/FolderImg.png +0 -0
  141. /package/{projects/cat-document-lib/src → src}/assets/images/Frame.png +0 -0
  142. /package/{projects/cat-document-lib/src → src}/assets/images/document.png +0 -0
@@ -0,0 +1,299 @@
1
+ import { EventEmitter, OnInit, OnDestroy, OnChanges, SimpleChanges, ElementRef, AfterViewInit } from '@angular/core';
2
+ import { DocumentListItem, DocumentListResponse } from '../../models/document-list-response.model';
3
+ import { TableData } from '../../../../Shared/components/table-primary/table-primary.model';
4
+ import { DocumentListService } from '../../services/document-list.service';
5
+ import { Message } from 'primeng/api';
6
+ import { DocumentHttpService } from '../../services/document-http.service';
7
+ import { DocumentMenuService } from '../../services/document-menu.service';
8
+ import { DocumentStore } from '../../state/document.store';
9
+ import { DocumentScrollService } from '../../services/document-scroll.service';
10
+ import * as i0 from "@angular/core";
11
+ /**
12
+ * This component is responsible for displaying and managing a list of documents.
13
+ * Provides functionality for file upload, document selection, and dialog management.
14
+ * @class DocumentListComponent
15
+ */
16
+ export declare class DocumentListComponent implements OnInit, OnDestroy, OnChanges, AfterViewInit {
17
+ private documentListService;
18
+ private documentHttpService;
19
+ private documentMenuService;
20
+ private documentStore;
21
+ private documentScrollService;
22
+ /**
23
+ * Represents the context ID for the document list.
24
+ * This value is passed from the parent component.
25
+ * @type {string}
26
+ * @memberof DocumentListComponent
27
+ */
28
+ contextId: string;
29
+ /**
30
+ * The document list response data passed from the parent component.
31
+ * @type {DocumentListResponse[] | null}
32
+ * @memberof DocumentListComponent
33
+ */
34
+ documentListResponse: DocumentListResponse[] | null;
35
+ /**
36
+ * The selected menu item ID for scrolling to specific sections
37
+ * @type {string | null}
38
+ * @memberof DocumentListComponent
39
+ */
40
+ selectedMenuItemId: string | null;
41
+ /**
42
+ * Additional navigation information for precise scrolling
43
+ * @type {object | null}
44
+ * @memberof DocumentListComponent
45
+ */
46
+ navigationInfo: {
47
+ menuItemId: string;
48
+ menuItemLabel: string;
49
+ categoryLabel: string;
50
+ categoryIndex: number;
51
+ } | null;
52
+ /**
53
+ * Reference to the document categories container for scrolling
54
+ */
55
+ documentCategoriesContainer: ElementRef;
56
+ /**
57
+ * Subscription to document list response from store
58
+ */
59
+ private documentListSubscription;
60
+ handleSelectedDocumentInNewTab: EventEmitter<{
61
+ selectedDocument: DocumentListItem;
62
+ contextId: string;
63
+ documentList: DocumentListItem[];
64
+ }>;
65
+ /**
66
+ * The currently selected document.
67
+ * @type {DocumentModel}
68
+ * @memberof DocumentListComponent
69
+ */
70
+ selectedDocument: DocumentListItem;
71
+ /**
72
+ * Default visibility of the sidebar.
73
+ * @type {boolean}
74
+ * @memberof DocumentListComponent
75
+ */
76
+ isSidebarVisible: boolean;
77
+ /**
78
+ * Default visibility of the messages.
79
+ * @type {Message[]}
80
+ * @memberof DocumentListComponent
81
+ */
82
+ messages: Message[];
83
+ /**
84
+ * Default visibility of the dialog.
85
+ * @type {boolean}
86
+ * @memberof DocumentListComponent
87
+ */
88
+ isdialogVisible: boolean;
89
+ /**
90
+ * The list of documents to display.
91
+ * This value is passed from the parent component.
92
+ * @type {DocumentModel[]}
93
+ * @memberof DocumentListComponent
94
+ */
95
+ documentList: DocumentListItem[];
96
+ /**
97
+ * Available document types for selection.
98
+ * @type {string[]}
99
+ * @memberof DocumentListComponent
100
+ */
101
+ options: any[];
102
+ /**
103
+ * The selected option for the document type.
104
+ * @type {(string | null)}
105
+ * @memberof DocumentListComponent
106
+ */
107
+ selectedOption: string | null;
108
+ /**
109
+ * The file name associated with the document.
110
+ * It may be undefined until a file is selected or loaded.
111
+ * @type {string | undefined}
112
+ */
113
+ fileName: string | undefined;
114
+ /**
115
+ * Table data for each category
116
+ */
117
+ categoryTables: TableData[];
118
+ /**
119
+ * Document categories from the response
120
+ */
121
+ documentCategories: DocumentListResponse[];
122
+ /**
123
+ * Completion counts for each category
124
+ */
125
+ categoryCompletionCounts: string[];
126
+ /**
127
+ * Severity levels for each category completion badge
128
+ */
129
+ categorySeverities: ('success' | 'info' | 'warning' | 'danger')[];
130
+ /**
131
+ * Message to display for document deletion
132
+ */
133
+ deleteMessage: Message[];
134
+ handleSelectedDocument: EventEmitter<DocumentListItem>;
135
+ /**
136
+ * Getter to return category labels as they come from the API
137
+ */
138
+ get formattedCategoryLabels(): string[];
139
+ /**
140
+ * Getter to generate safe category IDs for HTML elements
141
+ */
142
+ get categoryIds(): string[];
143
+ /**
144
+ * Creates an instance of DocumentListComponent.
145
+ * @class
146
+ * @param {DocumentListService} documentListService - The service responsible for document list operations.
147
+ */
148
+ constructor(documentListService: DocumentListService, documentHttpService: DocumentHttpService, documentMenuService: DocumentMenuService, documentStore: DocumentStore, documentScrollService: DocumentScrollService);
149
+ /**
150
+ * Handles changes to input properties
151
+ */
152
+ ngOnChanges(changes: SimpleChanges): void;
153
+ /**
154
+ * Initializes the component by setting up document list subscription.
155
+ */
156
+ ngOnInit(): void;
157
+ /**
158
+ * Called after the view is initialized
159
+ */
160
+ ngAfterViewInit(): void;
161
+ /**
162
+ * Handles the visibility of the sidebar.
163
+ * @param {boolean} isVisible - Indicates whether the sidebar should be visible or not.
164
+ * @memberof DocumentListComponent
165
+ */
166
+ handleOpenSideBar(isVisible: boolean): void;
167
+ /**
168
+ * Builds document categories from the API response
169
+ */
170
+ buildDocumentCategories(): void;
171
+ /**
172
+ * Sets up subscription to document list response from store
173
+ */
174
+ setupDocumentListSubscription(): void;
175
+ /**
176
+ * Handles table row click event
177
+ */
178
+ handleTableRowClick(rowData: any): void;
179
+ /**
180
+ * Handles the delete action from the table component
181
+ * @param {any} rowData - The row data containing the document to delete
182
+ */
183
+ handleDeleteAction(rowData: any): void;
184
+ /**
185
+ * Closes the document viewer dialog and resets the selected document
186
+ */
187
+ handleCloseModal(): void;
188
+ /**
189
+ * Refreshes the document list after a status update
190
+ * @param {boolean} isDeleteAction - Optional flag indicating if this refresh is due to a delete action
191
+ */
192
+ refreshDocumentList(isDeleteAction?: boolean): void;
193
+ handleTableRowCtrlClick(rowData: any): void;
194
+ /**
195
+ * Handles document status update events from viewer
196
+ * @param event - The status update event
197
+ */
198
+ handleDocumentStatusUpdate(event: {
199
+ actionType?: string;
200
+ }): void;
201
+ /**
202
+ * Shows delete error message for 2 seconds without closing dialog
203
+ * @param error - The error object from the delete operation
204
+ */
205
+ private showDeleteErrorMessage;
206
+ /**
207
+ * Handles delete error events from the document viewer
208
+ * @param error - The error object from the delete operation
209
+ */
210
+ handleDeleteError(error: any): void;
211
+ /**
212
+ * Handles delete success events from the document viewer
213
+ */
214
+ handleDeleteSuccess(): void;
215
+ /**
216
+ * Handles document name update event from viewer
217
+ */
218
+ handleDocumentNameUpdate(): void;
219
+ /**
220
+ * Handles the event when the document viewer is destroyed
221
+ * Triggers a refresh of the document data
222
+ */
223
+ handleViewerDestroyed(): void;
224
+ /**
225
+ * Scrolls to the category section that matches the selected menu item
226
+ * @param menuItemId - The ID of the selected menu item
227
+ */
228
+ scrollToCategorySection(menuItemId: string): void;
229
+ /**
230
+ * Finds category by converting menuItemId to readable format and matching exactly
231
+ * @param menuItemId - The menu item ID to match
232
+ * @returns The matching category or null
233
+ */
234
+ private findCategoryByMenuItemId;
235
+ /**
236
+ * Converts menuItemId to readable label format
237
+ * @param menuItemId - The menu item ID
238
+ * @returns Readable label
239
+ */
240
+ private convertMenuItemIdToReadableLabel;
241
+ /**
242
+ * Checks if a menu label is a substring of a longer category name
243
+ * @param menuLabel - The menu label to check
244
+ * @param categoryLabel - The category label to check against
245
+ * @returns True if menuLabel is a substring of a longer category
246
+ */
247
+ private isSubstringOfLongerCategory;
248
+ /**
249
+ * Legacy matching for backward compatibility with existing hardcoded keywords
250
+ * @param menuItemId - The menu item ID
251
+ * @returns The matching category or null
252
+ */
253
+ private findCategoryByLegacyMatching;
254
+ /**
255
+ * Scrolls to the category section using navigationInfo
256
+ * @param navigationInfo - The navigation info object containing menuItemId
257
+ */
258
+ scrollToCategorySectionWithNavigationInfo(navigationInfo: {
259
+ menuItemId: string;
260
+ menuItemLabel: string;
261
+ categoryLabel: string;
262
+ categoryIndex: number;
263
+ }): void;
264
+ /**
265
+ * Adds a temporary highlight effect to the scrolled category
266
+ * @param categoryElement - The DOM element of the category to highlight
267
+ */
268
+ highlightCategory(categoryElement: HTMLElement): void;
269
+ /**
270
+ * Alternative scrolling method using IntersectionObserver for better performance
271
+ * This method can be used as a fallback or alternative to the current approach
272
+ * @param navigationInfo - The navigation info object
273
+ */
274
+ scrollToCategorySectionWithIntersectionObserver(navigationInfo: {
275
+ menuItemId: string;
276
+ menuItemLabel: string;
277
+ categoryLabel: string;
278
+ categoryIndex: number;
279
+ }): void;
280
+ /**
281
+ * Resets the document list to the top when menu item is deselected
282
+ */
283
+ private resetToTop;
284
+ /**
285
+ * Handles changes in document list due to filtering
286
+ * Checks if the selected menu item's section is still visible and deselects if not
287
+ */
288
+ private handleDocumentListFilteringChange;
289
+ /**
290
+ * Deselects the current menu item and resets the view
291
+ */
292
+ private deselectMenuItemAndReset;
293
+ /**
294
+ * Cleanup subscriptions on component destroy
295
+ */
296
+ ngOnDestroy(): void;
297
+ static ɵfac: i0.ɵɵFactoryDeclaration<DocumentListComponent, never>;
298
+ static ɵcmp: i0.ɵɵComponentDeclaration<DocumentListComponent, "lib-document-list", never, { "contextId": { "alias": "contextId"; "required": false; }; "documentListResponse": { "alias": "documentListResponse"; "required": false; }; "selectedMenuItemId": { "alias": "selectedMenuItemId"; "required": false; }; "navigationInfo": { "alias": "navigationInfo"; "required": false; }; "documentList": { "alias": "documentList"; "required": false; }; }, { "handleSelectedDocumentInNewTab": "handleSelectedDocumentInNewTab"; "handleSelectedDocument": "handleSelectedDocument"; }, never, ["*"], false, never>;
299
+ }
@@ -0,0 +1,28 @@
1
+ import { EventEmitter } from '@angular/core';
2
+ import { DocumentModel } from '../../models/document.model';
3
+ import * as i0 from "@angular/core";
4
+ /**
5
+ * DocumentListItemComponent
6
+ *
7
+ * This component displays individual document items within a list.
8
+ * It accepts a list of documents as input and handles interactions with documents.
9
+ */
10
+ export declare class DocumentListItemComponent {
11
+ /**
12
+ * Emit the selected document.
13
+ * @type {EventEmitter<DocumentModel>}
14
+ */
15
+ documentClick: EventEmitter<DocumentModel>;
16
+ /**
17
+ * The document to display.
18
+ * @type {DocumentModel[]}
19
+ */
20
+ document: DocumentModel;
21
+ /**
22
+ * Handles interactions with a document.
23
+ * @param {DocumentModel} document - The document to be opened or interacted with.
24
+ */
25
+ handleOpenDocument(document: DocumentModel): void;
26
+ static ɵfac: i0.ɵɵFactoryDeclaration<DocumentListItemComponent, never>;
27
+ static ɵcmp: i0.ɵɵComponentDeclaration<DocumentListItemComponent, "lib-document-list-item", never, { "document": { "alias": "document"; "required": false; }; }, { "documentClick": "documentClick"; }, never, never, false, never>;
28
+ }
@@ -0,0 +1,77 @@
1
+ import { OnInit, OnDestroy, EventEmitter } from '@angular/core';
2
+ import { SHARED } from '../../../../Shared/constant/SHARED';
3
+ import { DocumentHelperService } from '../../services/document.service';
4
+ import { DocumentQuery } from '../../state/document.query';
5
+ import * as i0 from "@angular/core";
6
+ export declare class DocumentSearchComponent implements OnInit, OnDestroy {
7
+ private documentHelperService;
8
+ private documentQuery;
9
+ readonly SHARED: typeof SHARED;
10
+ contextId: string;
11
+ onActionClick: EventEmitter<void>;
12
+ onRequestClick: EventEmitter<void>;
13
+ searchTerm: string;
14
+ showActionsMenu: boolean;
15
+ private destroy$;
16
+ private searchSubject;
17
+ private hasActiveFilters;
18
+ constructor(documentHelperService: DocumentHelperService, documentQuery: DocumentQuery);
19
+ ngOnInit(): void;
20
+ ngOnDestroy(): void;
21
+ /**
22
+ * Sets up the search input subscription with debouncing
23
+ */
24
+ private setupSearchSubscription;
25
+ /**
26
+ * Sets up subscription to monitor all filter states
27
+ */
28
+ private setupFilterSubscription;
29
+ /**
30
+ * Handles search term changes from ngModel
31
+ * @param searchTerm - The search term entered by the user
32
+ */
33
+ onSearchInputChange(searchTerm: string): void;
34
+ /**
35
+ * Handles search term changes
36
+ * @param searchTerm - The search term entered by the user
37
+ */
38
+ private onSearchChange;
39
+ /**
40
+ * Clears the search input
41
+ */
42
+ onClearSearch(): void;
43
+ /**
44
+ * Clears all filters including search, menu item, user, and status selections
45
+ */
46
+ onClearAllFilters(): void;
47
+ /**
48
+ * Determines if the Clear All button should be visible
49
+ */
50
+ get shouldShowClearAll(): boolean;
51
+ /**
52
+ * Toggles the actions dropdown menu
53
+ */
54
+ toggleActionsMenu(): void;
55
+ /**
56
+ * Handles upload document action
57
+ */
58
+ handleUploadDocument(): void;
59
+ /**
60
+ * Handles request document action
61
+ */
62
+ handleRequestDocument(): void;
63
+ /**
64
+ * Sets up click outside listener to close dropdown
65
+ */
66
+ private setupClickOutsideListener;
67
+ /**
68
+ * Removes click outside listener
69
+ */
70
+ private removeClickOutsideListener;
71
+ /**
72
+ * Handles clicks outside the dropdown to close it
73
+ */
74
+ private handleClickOutside;
75
+ static ɵfac: i0.ɵɵFactoryDeclaration<DocumentSearchComponent, never>;
76
+ static ɵcmp: i0.ɵɵComponentDeclaration<DocumentSearchComponent, "document-search", never, { "contextId": { "alias": "contextId"; "required": false; }; }, { "onActionClick": "onActionClick"; "onRequestClick": "onRequestClick"; }, never, never, false, never>;
77
+ }
@@ -0,0 +1,24 @@
1
+ import { OnInit, OnDestroy, OnChanges, SimpleChanges } from '@angular/core';
2
+ import { DocumentQuery } from '../../state/document.query';
3
+ import { StatusCalculatorService, CalculatedStatusData } from '../../services/status-calculator.service';
4
+ import { DocumentHelperService } from '../../services/document.service';
5
+ import * as i0 from "@angular/core";
6
+ export declare class DocumentStatusComponent implements OnInit, OnDestroy, OnChanges {
7
+ private documentQuery;
8
+ private documentService;
9
+ private statusCalculatorService;
10
+ contextId: string;
11
+ statusData: any;
12
+ selectedStatus: string | null;
13
+ statusDataWithPercentages: CalculatedStatusData[];
14
+ private subscription;
15
+ constructor(documentQuery: DocumentQuery, documentService: DocumentHelperService, statusCalculatorService: StatusCalculatorService);
16
+ ngOnChanges(changes: SimpleChanges): void;
17
+ ngOnInit(): void;
18
+ private refetchStatusData;
19
+ selectStatus(status: string): void;
20
+ private updateCalculatedStatusData;
21
+ ngOnDestroy(): void;
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<DocumentStatusComponent, never>;
23
+ static ɵcmp: i0.ɵɵComponentDeclaration<DocumentStatusComponent, "lib-document-status", never, { "contextId": { "alias": "contextId"; "required": false; }; "statusData": { "alias": "statusData"; "required": false; }; }, {}, never, never, false, never>;
24
+ }