cat-documents-ng 0.3.52 → 0.3.53

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.
@@ -2014,6 +2014,255 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
2014
2014
  args: [{ providedIn: 'root' }]
2015
2015
  }], ctorParameters: () => [{ type: DocumentStore }] });
2016
2016
 
2017
+ class DocumentMenuService {
2018
+ documentStore;
2019
+ constructor(documentStore) {
2020
+ this.documentStore = documentStore;
2021
+ }
2022
+ /**
2023
+ * Sorts categories alphabetically by label
2024
+ * @param categories - The list of document categories to sort
2025
+ * @returns Sorted categories array
2026
+ */
2027
+ sortCategoriesAlphabetically(categories) {
2028
+ return [...categories].sort((a, b) => a.label.localeCompare(b.label));
2029
+ }
2030
+ /**
2031
+ * Sorts menu items within each category alphabetically by label
2032
+ * @param categories - The list of document categories to sort
2033
+ * @returns Categories with sorted menu items
2034
+ */
2035
+ sortMenuItemsAlphabetically(categories) {
2036
+ return categories.map(category => ({
2037
+ ...category,
2038
+ items: category.items ? [...category.items].sort((a, b) => a.label.localeCompare(b.label)) : category.items
2039
+ }));
2040
+ }
2041
+ /**
2042
+ * Sorts both categories and their menu items alphabetically
2043
+ * @param categories - The list of document categories to sort
2044
+ * @returns Fully sorted categories array
2045
+ */
2046
+ sortCategoriesAndMenuItems(categories) {
2047
+ const sortedCategories = this.sortCategoriesAlphabetically(categories);
2048
+ return this.sortMenuItemsAlphabetically(sortedCategories);
2049
+ }
2050
+ /**
2051
+ * Gets the category name for a given menu item _id
2052
+ * @param menuItemId - The _id of the menu item
2053
+ * @param categories - The list of document categories
2054
+ * @returns The category name or null if not found
2055
+ */
2056
+ getMenuItemCategory(menuItemId, categories) {
2057
+ for (const category of categories) {
2058
+ if (category.items?.some((menuItem) => menuItem._id === menuItemId)) {
2059
+ return category.label;
2060
+ }
2061
+ }
2062
+ return null;
2063
+ }
2064
+ /**
2065
+ * Gets the menu item by its _id
2066
+ * @param menuItemId - The _id of the menu item
2067
+ * @param categories - The list of document categories
2068
+ * @returns The menu item or null if not found
2069
+ */
2070
+ getMenuItemById(menuItemId, categories) {
2071
+ for (const category of categories) {
2072
+ if (category.items) {
2073
+ const item = category.items.find((menuItem) => menuItem._id === menuItemId);
2074
+ if (item) {
2075
+ return item;
2076
+ }
2077
+ }
2078
+ }
2079
+ return null;
2080
+ }
2081
+ /**
2082
+ * Handles user list visibility based on menu item category
2083
+ * @param menuItemId - The _id of the menu item
2084
+ * @param categories - The list of document categories
2085
+ */
2086
+ handleUserListVisibility(menuItemId, categories) {
2087
+ const category = this.getMenuItemCategory(menuItemId, categories);
2088
+ this.documentStore.setShowUserList(true);
2089
+ }
2090
+ /**
2091
+ * Calculates total documents for a menu item
2092
+ * @param item - The menu item
2093
+ * @returns Total number of documents
2094
+ */
2095
+ getTotalDocuments(item) {
2096
+ const status = item.status;
2097
+ // Handle both uppercase and lowercase keys
2098
+ const pending = status.Pending || status.pending || 0;
2099
+ const reviewing = status.Reviewing || status.reviewing || 0;
2100
+ const accepted = status.Accepted || status.approved || 0; // Note: approved maps to Accepted
2101
+ const rejected = status.Rejected || status.rejected || 0;
2102
+ return pending + reviewing + accepted + rejected;
2103
+ }
2104
+ /**
2105
+ * Gets badge value for a menu item
2106
+ * @param item - The menu item
2107
+ * @returns Badge value string (e.g., "2/3")
2108
+ */
2109
+ getBadgeValue(item) {
2110
+ const approved = this.getApprovedDocuments(item);
2111
+ const total = this.getTotalDocuments(item);
2112
+ return `${approved}/${total}`;
2113
+ }
2114
+ /**
2115
+ * Gets badge severity based on status
2116
+ * @param item - The menu item
2117
+ * @returns Badge severity for PrimeNG
2118
+ */
2119
+ getBadgeSeverity(item) {
2120
+ const status = item.status;
2121
+ const total = this.getTotalDocuments(item);
2122
+ const pending = status.Pending || status.pending || 0;
2123
+ const rejected = status.Rejected || status.rejected || 0;
2124
+ const reviewing = status.Reviewing || status.reviewing || 0;
2125
+ const approved = this.getApprovedDocuments(item);
2126
+ if (total === 0)
2127
+ return 'info';
2128
+ if (pending > 0)
2129
+ return 'info';
2130
+ if (rejected > 0)
2131
+ return 'danger';
2132
+ if (reviewing > 0)
2133
+ return 'warning';
2134
+ if (approved === total && total > 0)
2135
+ return 'success';
2136
+ return 'warning';
2137
+ }
2138
+ /**
2139
+ * Checks if badge should be shown for a menu item
2140
+ * @param item - The menu item
2141
+ * @returns True if badge should be shown
2142
+ */
2143
+ shouldShowBadge(item) {
2144
+ return this.getTotalDocuments(item) > 0;
2145
+ }
2146
+ /**
2147
+ * Calculates approved documents for a menu item
2148
+ * @param item - The menu item
2149
+ * @returns Number of approved documents
2150
+ */
2151
+ getApprovedDocuments(item) {
2152
+ const status = item.status;
2153
+ // Handle both uppercase and lowercase keys, with approved mapping to Accepted
2154
+ return status.Accepted || status.approved || 0;
2155
+ }
2156
+ /**
2157
+ * Checks if a menu item's section is visible in the filtered document list
2158
+ * @param menuItemId - The ID of the menu item to check
2159
+ * @param documentListResponse - The filtered document list response
2160
+ * @returns True if the section is visible, false otherwise
2161
+ */
2162
+ isMenuItemSectionVisible(menuItemId, documentListResponse, menuItemLabel) {
2163
+ if (!menuItemId || !documentListResponse || documentListResponse.length === 0) {
2164
+ return false;
2165
+ }
2166
+ return documentListResponse.some(category => {
2167
+ if (!category.label || !category.list || category.list.length === 0) {
2168
+ return false;
2169
+ }
2170
+ const categoryLabelLower = category.label.toLowerCase();
2171
+ if (menuItemLabel) {
2172
+ const menuItemLabelLower = menuItemLabel.toLowerCase();
2173
+ if (categoryLabelLower === menuItemLabelLower) {
2174
+ return true;
2175
+ }
2176
+ if (this.isSmartPartialMatch(menuItemLabelLower, categoryLabelLower)) {
2177
+ return true;
2178
+ }
2179
+ }
2180
+ const menuItemIdLower = menuItemId.toLowerCase();
2181
+ if (this.isSmartPartialMatch(menuItemIdLower, categoryLabelLower)) {
2182
+ return true;
2183
+ }
2184
+ return false;
2185
+ });
2186
+ }
2187
+ /**
2188
+ * Performs smart partial matching to prevent substring conflicts
2189
+ * @param menuLabel - The menu item label to match
2190
+ * @param categoryLabel - The category label to match against
2191
+ * @returns True if it's a valid partial match, false otherwise
2192
+ */
2193
+ isSmartPartialMatch(menuLabel, categoryLabel) {
2194
+ if (categoryLabel.length > menuLabel.length + 3) {
2195
+ return false;
2196
+ }
2197
+ return categoryLabel.includes(menuLabel) || menuLabel.includes(categoryLabel);
2198
+ }
2199
+ /**
2200
+ * Deselects a menu item if its section is not visible in the filtered document list
2201
+ * @param menuItemId - The ID of the menu item to check
2202
+ * @param documentListResponse - The filtered document list response
2203
+ * @param menuItemLabel - The label of the menu item (optional)
2204
+ * @returns True if the menu item was deselected, false otherwise
2205
+ */
2206
+ deselectMenuItemIfSectionNotVisible(menuItemId, documentListResponse, menuItemLabel) {
2207
+ if (!this.isMenuItemSectionVisible(menuItemId, documentListResponse, menuItemLabel)) {
2208
+ this.documentStore.setSelectedMenuItem(null);
2209
+ return true;
2210
+ }
2211
+ return false;
2212
+ }
2213
+ /**
2214
+ * Checks if a menu item should be selectable based on the filtered document list
2215
+ * @param menuItemId - The ID of the menu item to check
2216
+ * @param documentListResponse - The filtered document list response
2217
+ * @param menuItemLabel - The label of the menu item (optional)
2218
+ * @returns True if the menu item should be selectable, false otherwise
2219
+ */
2220
+ isMenuItemSelectable(menuItemId, documentListResponse, menuItemLabel) {
2221
+ return this.isMenuItemSectionVisible(menuItemId, documentListResponse, menuItemLabel);
2222
+ }
2223
+ /**
2224
+ * Gets the selectability status for all menu items in categories
2225
+ * @param categories - The document categories containing menu items
2226
+ * @param documentListResponse - The filtered document list response
2227
+ * @returns Map of menu item IDs to their selectability status
2228
+ */
2229
+ getMenuItemsSelectabilityStatus(categories, documentListResponse) {
2230
+ const selectabilityMap = new Map();
2231
+ categories.forEach(category => {
2232
+ if (category.items) {
2233
+ category.items.forEach(item => {
2234
+ const isSelectable = this.isMenuItemSelectable(item._id, documentListResponse);
2235
+ selectabilityMap.set(item._id, isSelectable);
2236
+ });
2237
+ }
2238
+ });
2239
+ return selectabilityMap;
2240
+ }
2241
+ /**
2242
+ * Updates menu items with selectability status
2243
+ * @param categories - The document categories containing menu items
2244
+ * @param documentListResponse - The filtered document list response
2245
+ * @returns Updated categories with selectability information
2246
+ */
2247
+ updateMenuItemsWithSelectabilityStatus(categories, documentListResponse) {
2248
+ return categories.map(category => ({
2249
+ ...category,
2250
+ items: category.items?.map(item => ({
2251
+ ...item,
2252
+ isSelectable: this.isMenuItemSelectable(item._id, documentListResponse, item.label)
2253
+ }))
2254
+ }));
2255
+ }
2256
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, deps: [{ token: DocumentStore }], target: i0.ɵɵFactoryTarget.Injectable });
2257
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, providedIn: 'root' });
2258
+ }
2259
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, decorators: [{
2260
+ type: Injectable,
2261
+ args: [{
2262
+ providedIn: 'root'
2263
+ }]
2264
+ }], ctorParameters: () => [{ type: DocumentStore }] });
2265
+
2017
2266
  /**
2018
2267
  * Service to manage the document data and selection state
2019
2268
  */
@@ -2021,11 +2270,13 @@ class DocumentHelperService {
2021
2270
  documentStore;
2022
2271
  documentQuery;
2023
2272
  documentHttpService;
2273
+ documentMenuService;
2024
2274
  selectionWatcherSubscription = null;
2025
- constructor(documentStore, documentQuery, documentHttpService) {
2275
+ constructor(documentStore, documentQuery, documentHttpService, documentMenuService) {
2026
2276
  this.documentStore = documentStore;
2027
2277
  this.documentQuery = documentQuery;
2028
2278
  this.documentHttpService = documentHttpService;
2279
+ this.documentMenuService = documentMenuService;
2029
2280
  // Note: initializeSelectionWatcher now requires contextId
2030
2281
  // This should be called from the component that has access to contextId
2031
2282
  }
@@ -2197,9 +2448,13 @@ class DocumentHelperService {
2197
2448
  refreshDocumentsWithCurrentSelection(contextId) {
2198
2449
  const currentState = this.documentQuery.getSelectionState();
2199
2450
  this.documentHttpService.getDocumentsBySelection(contextId, null, // No menu item filtering
2200
- currentState.userId, currentState.status).subscribe({
2451
+ currentState.userId, currentState.status, currentState.searchKey).subscribe({
2201
2452
  next: (response) => {
2202
- this.documentStore.setDocumentListResponse(response);
2453
+ // Set the correct response structure - check if response has documents property
2454
+ const documentListResponse = response.documents || response;
2455
+ this.documentStore.setDocumentListResponse(documentListResponse);
2456
+ // Check if the selected menu item's section is still visible after filtering
2457
+ this.checkAndDeselectMenuItemIfSectionNotVisible(contextId);
2203
2458
  },
2204
2459
  error: (error) => {
2205
2460
  throw new Error(error);
@@ -2286,164 +2541,31 @@ class DocumentHelperService {
2286
2541
  });
2287
2542
  this.refreshDocumentsWithCurrentSelection(contextId);
2288
2543
  }
2289
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, deps: [{ token: DocumentStore }, { token: DocumentQuery }, { token: DocumentHttpService }], target: i0.ɵɵFactoryTarget.Injectable });
2290
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, providedIn: 'root' });
2291
- }
2292
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, decorators: [{
2293
- type: Injectable,
2294
- args: [{
2295
- providedIn: 'root',
2296
- }]
2297
- }], ctorParameters: () => [{ type: DocumentStore }, { type: DocumentQuery }, { type: DocumentHttpService }] });
2298
-
2299
- class DocumentMenuService {
2300
- documentStore;
2301
- constructor(documentStore) {
2302
- this.documentStore = documentStore;
2303
- }
2304
- /**
2305
- * Sorts categories alphabetically by label
2306
- * @param categories - The list of document categories to sort
2307
- * @returns Sorted categories array
2308
- */
2309
- sortCategoriesAlphabetically(categories) {
2310
- return [...categories].sort((a, b) => a.label.localeCompare(b.label));
2311
- }
2312
- /**
2313
- * Sorts menu items within each category alphabetically by label
2314
- * @param categories - The list of document categories to sort
2315
- * @returns Categories with sorted menu items
2316
- */
2317
- sortMenuItemsAlphabetically(categories) {
2318
- return categories.map(category => ({
2319
- ...category,
2320
- items: category.items ? [...category.items].sort((a, b) => a.label.localeCompare(b.label)) : category.items
2321
- }));
2322
- }
2323
- /**
2324
- * Sorts both categories and their menu items alphabetically
2325
- * @param categories - The list of document categories to sort
2326
- * @returns Fully sorted categories array
2327
- */
2328
- sortCategoriesAndMenuItems(categories) {
2329
- const sortedCategories = this.sortCategoriesAlphabetically(categories);
2330
- return this.sortMenuItemsAlphabetically(sortedCategories);
2331
- }
2332
- /**
2333
- * Gets the category name for a given menu item _id
2334
- * @param menuItemId - The _id of the menu item
2335
- * @param categories - The list of document categories
2336
- * @returns The category name or null if not found
2337
- */
2338
- getMenuItemCategory(menuItemId, categories) {
2339
- for (const category of categories) {
2340
- if (category.items?.some((menuItem) => menuItem._id === menuItemId)) {
2341
- return category.label;
2342
- }
2343
- }
2344
- return null;
2345
- }
2346
2544
  /**
2347
- * Gets the menu item by its _id
2348
- * @param menuItemId - The _id of the menu item
2349
- * @param categories - The list of document categories
2350
- * @returns The menu item or null if not found
2545
+ * Checks if the currently selected menu item's section is visible in the filtered document list
2546
+ * and deselects it if not visible
2547
+ * @param contextId - The context ID to use for API calls
2351
2548
  */
2352
- getMenuItemById(menuItemId, categories) {
2353
- for (const category of categories) {
2354
- if (category.items) {
2355
- const item = category.items.find((menuItem) => menuItem._id === menuItemId);
2356
- if (item) {
2357
- return item;
2358
- }
2359
- }
2549
+ checkAndDeselectMenuItemIfSectionNotVisible(contextId) {
2550
+ const currentState = this.documentQuery.getSelectionState();
2551
+ const selectedMenuItem = currentState.menuItem;
2552
+ if (selectedMenuItem) {
2553
+ // Get the current document list response
2554
+ const documentListResponse = this.documentQuery.getDocumentListResponse();
2555
+ // Check if the menu item's section is visible and deselect if not
2556
+ const wasDeselected = this.documentMenuService.deselectMenuItemIfSectionNotVisible(selectedMenuItem, documentListResponse);
2557
+ // Menu item was deselected if its section is not visible
2360
2558
  }
2361
- return null;
2362
- }
2363
- /**
2364
- * Handles user list visibility based on menu item category
2365
- * @param menuItemId - The _id of the menu item
2366
- * @param categories - The list of document categories
2367
- */
2368
- handleUserListVisibility(menuItemId, categories) {
2369
- const category = this.getMenuItemCategory(menuItemId, categories);
2370
- this.documentStore.setShowUserList(true);
2371
2559
  }
2372
- /**
2373
- * Calculates total documents for a menu item
2374
- * @param item - The menu item
2375
- * @returns Total number of documents
2376
- */
2377
- getTotalDocuments(item) {
2378
- const status = item.status;
2379
- // Handle both uppercase and lowercase keys
2380
- const pending = status.Pending || status.pending || 0;
2381
- const reviewing = status.Reviewing || status.reviewing || 0;
2382
- const accepted = status.Accepted || status.approved || 0; // Note: approved maps to Accepted
2383
- const rejected = status.Rejected || status.rejected || 0;
2384
- return pending + reviewing + accepted + rejected;
2385
- }
2386
- /**
2387
- * Gets badge value for a menu item
2388
- * @param item - The menu item
2389
- * @returns Badge value string (e.g., "2/3")
2390
- */
2391
- getBadgeValue(item) {
2392
- const approved = this.getApprovedDocuments(item);
2393
- const total = this.getTotalDocuments(item);
2394
- return `${approved}/${total}`;
2395
- }
2396
- /**
2397
- * Gets badge severity based on status
2398
- * @param item - The menu item
2399
- * @returns Badge severity for PrimeNG
2400
- */
2401
- getBadgeSeverity(item) {
2402
- const status = item.status;
2403
- const total = this.getTotalDocuments(item);
2404
- const pending = status.Pending || status.pending || 0;
2405
- const rejected = status.Rejected || status.rejected || 0;
2406
- const reviewing = status.Reviewing || status.reviewing || 0;
2407
- const approved = this.getApprovedDocuments(item);
2408
- if (total === 0)
2409
- return 'info';
2410
- if (pending > 0)
2411
- return 'info';
2412
- if (rejected > 0)
2413
- return 'danger';
2414
- if (reviewing > 0)
2415
- return 'warning';
2416
- if (approved === total && total > 0)
2417
- return 'success';
2418
- return 'warning';
2419
- }
2420
- /**
2421
- * Checks if badge should be shown for a menu item
2422
- * @param item - The menu item
2423
- * @returns True if badge should be shown
2424
- */
2425
- shouldShowBadge(item) {
2426
- return this.getTotalDocuments(item) > 0;
2427
- }
2428
- /**
2429
- * Calculates approved documents for a menu item
2430
- * @param item - The menu item
2431
- * @returns Number of approved documents
2432
- */
2433
- getApprovedDocuments(item) {
2434
- const status = item.status;
2435
- // Handle both uppercase and lowercase keys, with approved mapping to Accepted
2436
- return status.Accepted || status.approved || 0;
2437
- }
2438
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, deps: [{ token: DocumentStore }], target: i0.ɵɵFactoryTarget.Injectable });
2439
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, providedIn: 'root' });
2560
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, deps: [{ token: DocumentStore }, { token: DocumentQuery }, { token: DocumentHttpService }, { token: DocumentMenuService }], target: i0.ɵɵFactoryTarget.Injectable });
2561
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, providedIn: 'root' });
2440
2562
  }
2441
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentMenuService, decorators: [{
2563
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentHelperService, decorators: [{
2442
2564
  type: Injectable,
2443
2565
  args: [{
2444
- providedIn: 'root'
2566
+ providedIn: 'root',
2445
2567
  }]
2446
- }], ctorParameters: () => [{ type: DocumentStore }] });
2568
+ }], ctorParameters: () => [{ type: DocumentStore }, { type: DocumentQuery }, { type: DocumentHttpService }, { type: DocumentMenuService }] });
2447
2569
 
2448
2570
  /**
2449
2571
  * Service for managing document-related operations.
@@ -8358,20 +8480,12 @@ class DocumentListComponent {
8358
8480
  return;
8359
8481
  }
8360
8482
  this.documentScrollService.setScrolling();
8361
- let targetCategory = this.documentCategories.find(category => category.label.toLowerCase().includes(SHARED.APPLICATION_LOWERCASE) ||
8362
- category.label.toLowerCase().includes(SHARED.APPLICANT_LOWERCASE) ||
8363
- category.label.toLowerCase().includes(SHARED.DOCUMENT_LOWERCASE));
8483
+ let targetCategory = this.findCategoryByMenuItemId(menuItemId);
8364
8484
  if (!targetCategory) {
8365
- if (menuItemId.includes(SHARED.APPLICATION_LOWERCASE)) {
8366
- targetCategory = this.documentCategories.find(cat => cat.label.toLowerCase().includes(SHARED.APPLICATION_LOWERCASE));
8367
- }
8368
- else if (menuItemId.includes(SHARED.APPLICANT_LOWERCASE) || menuItemId.includes(SHARED.USER_LOWERCASE)) {
8369
- targetCategory = this.documentCategories.find(cat => cat.label.toLowerCase().includes(SHARED.APPLICANT_LOWERCASE) ||
8370
- cat.label.toLowerCase().includes(SHARED.USER_LOWERCASE));
8371
- }
8372
- else {
8373
- targetCategory = this.documentCategories[0];
8374
- }
8485
+ targetCategory = this.findCategoryByLegacyMatching(menuItemId);
8486
+ }
8487
+ if (!targetCategory) {
8488
+ targetCategory = this.documentCategories[0];
8375
8489
  }
8376
8490
  if (targetCategory) {
8377
8491
  const categoryIndex = this.documentCategories.findIndex(cat => cat === targetCategory);
@@ -8388,6 +8502,61 @@ class DocumentListComponent {
8388
8502
  }
8389
8503
  }
8390
8504
  }
8505
+ /**
8506
+ * Finds category by converting menuItemId to readable format and matching exactly
8507
+ * @param menuItemId - The menu item ID to match
8508
+ * @returns The matching category or null
8509
+ */
8510
+ findCategoryByMenuItemId(menuItemId) {
8511
+ const readableLabel = this.convertMenuItemIdToReadableLabel(menuItemId);
8512
+ let targetCategory = this.documentCategories.find(category => category.label.toLowerCase() === readableLabel.toLowerCase());
8513
+ if (!targetCategory) {
8514
+ targetCategory = this.documentCategories.find(category => {
8515
+ const categoryLabel = category.label.toLowerCase();
8516
+ const menuLabel = readableLabel.toLowerCase();
8517
+ return categoryLabel.includes(menuLabel) &&
8518
+ !this.isSubstringOfLongerCategory(menuLabel, categoryLabel);
8519
+ });
8520
+ }
8521
+ return targetCategory || null;
8522
+ }
8523
+ /**
8524
+ * Converts menuItemId to readable label format
8525
+ * @param menuItemId - The menu item ID
8526
+ * @returns Readable label
8527
+ */
8528
+ convertMenuItemIdToReadableLabel(menuItemId) {
8529
+ // Convert kebab-case or snake_case to Title Case
8530
+ return menuItemId
8531
+ .replace(/[-_]/g, ' ')
8532
+ .replace(/\b\w/g, l => l.toUpperCase());
8533
+ }
8534
+ /**
8535
+ * Checks if a menu label is a substring of a longer category name
8536
+ * @param menuLabel - The menu label to check
8537
+ * @param categoryLabel - The category label to check against
8538
+ * @returns True if menuLabel is a substring of a longer category
8539
+ */
8540
+ isSubstringOfLongerCategory(menuLabel, categoryLabel) {
8541
+ // If the category is significantly longer than the menu item, it's likely a substring
8542
+ return categoryLabel.length > menuLabel.length + 3; // Allow some tolerance
8543
+ }
8544
+ /**
8545
+ * Legacy matching for backward compatibility with existing hardcoded keywords
8546
+ * @param menuItemId - The menu item ID
8547
+ * @returns The matching category or null
8548
+ */
8549
+ findCategoryByLegacyMatching(menuItemId) {
8550
+ // Legacy matching for specific hardcoded keywords
8551
+ if (menuItemId.includes(SHARED.APPLICATION_LOWERCASE)) {
8552
+ return this.documentCategories.find(cat => cat.label.toLowerCase().includes(SHARED.APPLICATION_LOWERCASE)) || null;
8553
+ }
8554
+ else if (menuItemId.includes(SHARED.APPLICANT_LOWERCASE) || menuItemId.includes(SHARED.USER_LOWERCASE)) {
8555
+ return this.documentCategories.find(cat => cat.label.toLowerCase().includes(SHARED.APPLICANT_LOWERCASE) ||
8556
+ cat.label.toLowerCase().includes(SHARED.USER_LOWERCASE)) || null;
8557
+ }
8558
+ return null;
8559
+ }
8391
8560
  /**
8392
8561
  * Scrolls to the category section using navigationInfo
8393
8562
  * @param navigationInfo - The navigation info object containing menuItemId
@@ -8409,9 +8578,7 @@ class DocumentListComponent {
8409
8578
  inline: 'nearest'
8410
8579
  });
8411
8580
  this.highlightCategory(targetElement);
8412
- // Setup observer to deselect menu item when section scrolls out of view
8413
8581
  this.documentScrollService.setupSectionObserver(targetElement, this.selectedMenuItemId);
8414
- // Reset scrolling flag after smooth scroll completes
8415
8582
  this.documentScrollService.resetScrollingAfterDelay(1200);
8416
8583
  }
8417
8584
  else {
@@ -8491,26 +8658,26 @@ class DocumentListComponent {
8491
8658
  * Checks if the selected menu item's section is still visible and deselects if not
8492
8659
  */
8493
8660
  handleDocumentListFilteringChange() {
8494
- if (this.selectedMenuItemId && this.documentCategories && this.documentCategories.length > 0) {
8495
- const isSectionVisible = this.isSelectedMenuItemSectionVisible();
8661
+ if (this.selectedMenuItemId && this.documentCategories) {
8662
+ // If no categories are available (all filtered out), deselect the menu item
8663
+ if (this.documentCategories.length === 0) {
8664
+ this.deselectMenuItemAndReset();
8665
+ return;
8666
+ }
8667
+ // Use the document menu service to check visibility
8668
+ const isSectionVisible = this.documentMenuService.isMenuItemSectionVisible(this.selectedMenuItemId, this.documentListResponse);
8496
8669
  if (!isSectionVisible) {
8497
- this.selectedMenuItemId = null;
8498
- this.documentStore.setSelectedMenuItem(null);
8499
- this.resetToTop();
8670
+ this.deselectMenuItemAndReset();
8500
8671
  }
8501
8672
  }
8502
8673
  }
8503
8674
  /**
8504
- * Checks if the currently selected menu item's section is visible in the filtered document list
8505
- * @returns True if the section is visible, false otherwise
8675
+ * Deselects the current menu item and resets the view
8506
8676
  */
8507
- isSelectedMenuItemSectionVisible() {
8508
- if (!this.selectedMenuItemId || !this.documentCategories || this.documentCategories.length === 0) {
8509
- return false;
8510
- }
8511
- return this.documentCategories.some(category => category.label && this.selectedMenuItemId &&
8512
- (category.label.toLowerCase().includes(this.selectedMenuItemId.toLowerCase()) ||
8513
- this.selectedMenuItemId.toLowerCase().includes(category.label.toLowerCase())));
8677
+ deselectMenuItemAndReset() {
8678
+ this.selectedMenuItemId = null;
8679
+ this.documentStore.setSelectedMenuItem(null);
8680
+ this.resetToTop();
8514
8681
  }
8515
8682
  /**
8516
8683
  * Cleanup subscriptions on component destroy
@@ -8563,6 +8730,7 @@ class DocumentsMenuComponent {
8563
8730
  // Subscriptions to track for cleanup
8564
8731
  selectedMenuItemSubscription;
8565
8732
  documentCategoriesSubscription;
8733
+ documentListResponseSubscription;
8566
8734
  constructor(documentStore, documentQuery, documentMenuService, documentHelperService) {
8567
8735
  this.documentStore = documentStore;
8568
8736
  this.documentQuery = documentQuery;
@@ -8587,6 +8755,8 @@ class DocumentsMenuComponent {
8587
8755
  this.updateMenuItemsData();
8588
8756
  }
8589
8757
  });
8758
+ // Subscribe to document list response to update menu item selectability
8759
+ this.setupDocumentListResponseSubscription();
8590
8760
  }
8591
8761
  /**
8592
8762
  * Handle changes to input properties
@@ -8670,16 +8840,57 @@ class DocumentsMenuComponent {
8670
8840
  shouldShowBadge: this.documentMenuService.shouldShowBadge(item)
8671
8841
  };
8672
8842
  item.menuData = menuData;
8843
+ // Initialize isSelectable as true (default state)
8844
+ if (item.isSelectable === undefined) {
8845
+ item.isSelectable = true;
8846
+ }
8673
8847
  });
8674
8848
  }
8675
8849
  });
8676
8850
  }
8851
+ /**
8852
+ * Sets up subscription to document list response to update menu item selectability
8853
+ */
8854
+ setupDocumentListResponseSubscription() {
8855
+ this.documentListResponseSubscription = this.documentQuery.selectDocumentListResponse().subscribe(documentListResponse => {
8856
+ this.updateMenuItemsSelectability(documentListResponse);
8857
+ });
8858
+ }
8859
+ /**
8860
+ * Updates menu items with selectability status based on filtered document list
8861
+ * @param documentListResponse - The filtered document list response
8862
+ */
8863
+ updateMenuItemsSelectability(documentListResponse) {
8864
+ if (this._cachedCategories && this._cachedCategories.length > 0) {
8865
+ // Only update if we have a valid response (not null/undefined)
8866
+ // If response is null, it means no filters are applied, so all items should be selectable
8867
+ if (documentListResponse !== null && documentListResponse !== undefined) {
8868
+ this._cachedCategories = this.documentMenuService.updateMenuItemsWithSelectabilityStatus(this._cachedCategories, documentListResponse);
8869
+ }
8870
+ else {
8871
+ // If no response, make all items selectable (default state)
8872
+ this._cachedCategories = this._cachedCategories.map(category => ({
8873
+ ...category,
8874
+ items: category.items?.map(item => ({
8875
+ ...item,
8876
+ isSelectable: true
8877
+ }))
8878
+ }));
8879
+ }
8880
+ }
8881
+ }
8677
8882
  /**
8678
8883
  * Handle the menu item click for navigation
8679
8884
  * @param {*} event - Event
8680
8885
  * @param {DocumentCategoryItem} item - catagory item
8681
8886
  */
8682
8887
  onMenuItemClick(event, item) {
8888
+ // Prevent selection if the menu item is not selectable
8889
+ if (item.isSelectable === false) {
8890
+ event.preventDefault();
8891
+ event.stopPropagation();
8892
+ return;
8893
+ }
8683
8894
  if (this.selectedMenuItemId === item._id) {
8684
8895
  this.selectedMenuItem = null;
8685
8896
  this.selectedMenuItemId = null;
@@ -8744,13 +8955,16 @@ class DocumentsMenuComponent {
8744
8955
  if (this.documentCategoriesSubscription) {
8745
8956
  this.documentCategoriesSubscription.unsubscribe();
8746
8957
  }
8958
+ if (this.documentListResponseSubscription) {
8959
+ this.documentListResponseSubscription.unsubscribe();
8960
+ }
8747
8961
  }
8748
8962
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentsMenuComponent, deps: [{ token: DocumentStore }, { token: DocumentQuery }, { token: DocumentMenuService }, { token: DocumentHelperService }], target: i0.ɵɵFactoryTarget.Component });
8749
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DocumentsMenuComponent, isStandalone: false, selector: "lib-documents-menu", inputs: { catagories: "catagories", applicationNumber: "applicationNumber", contextId: "contextId" }, outputs: { menuItemSelected: "menuItemSelected" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"document-sidebar-container h-full\">\r\n <!-- Menu items are now used for navigation to specific sections, not for filtering documents -->\r\n <p-card class=\"widget-menu-wrapper h-full\">\r\n @if(applicationNumber){\r\n <div class=\"flex align-items-center justify-content-between widget-menu-header-wrapper\">\r\n <p class=\"mb-0 application-title-wrapper\">ID - {{applicationNumber}}</p>\r\n <div class=\"expand-icon-wrapper\">\r\n <i class=\"ri-arrow-left-s-line text-primary flex align-items-center justify-content-center w-full h-full\"></i>\r\n </div>\r\n </div>\r\n }\r\n\r\n <div class=\"widget-menu-container\" >\r\n <div class=\"widget-menu-wrapper h-ful l custom-scroll\">\r\n <p-menu [model]=\"categories\" styleClass=\"w-full md:w-15rem\">\r\n <ng-template pTemplate=\"submenuheader\" let-item>\r\n <span [style]=\"{\r\n color : '#9EA0B3'\r\n }\">{{ item.label }} Documents</span>\r\n </ng-template>\r\n <ng-template pTemplate=\"item\" let-item>\r\n <a pRipple \r\n class=\"flex align-items-center p-menuitem-link\"\r\n [class.selected-menu-item]=\"selectedMenuItemId === item._id\"\r\n (click)=\"onMenuItemClick($event, item)\">\r\n <span [class]=\"item.icon\" class=\"text-xl\"></span>\r\n <span class=\"ml-2\">{{ item.label }}</span>\r\n <p-badge *ngIf=\"item.menuData?.shouldShowBadge\" \r\n class=\"ml-auto\" \r\n [severity]=\"item.menuData?.badgeSeverity\" \r\n [value]=\"item.menuData?.badgeValue\" />\r\n </a>\r\n </ng-template>\r\n </p-menu>\r\n </div>\r\n </div>\r\n </p-card>\r\n</div>\r\n\r\n ", styles: [".expand-icon-wrapper{border:1px solid var(--primary-color);height:24px;width:24px;border-radius:50%;background:var(--blue-bg-light)}::ng-deep .p-badge.p-badge-success{background-color:#dcfce7;color:#16a34a;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-danger{background-color:#fee2e2;color:#dc2626;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-warning{background-color:#fef3c7;color:#d97706;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-info{background-color:#e5e7eb;color:#000;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-menu .p-menuitem>.p-menuitem-content .p-menuitem-link{color:#1f2937}@media screen and (min-width: 768px){::ng-deep .md\\:w-15rem{width:100%!important}}::ng-deep .p-menu{border:none}::ng-deep .custom-scroll{scrollbar-gutter:inherit}::ng-deep .selected-menu-item{background-color:#0066ff1a!important;color:var(--primary-color)!important;border:1px solid rgba(68,72,109,.1)!important;border-radius:10px!important}::ng-deep .selected-menu-item .text-xl{color:var(--primary-color)!important}::ng-deep .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important}::ng-deep .p-menuitem-link:not(.selected-menu-item) .text-xl{color:var(--text-color)!important}::ng-deep .p-panelmenu .p-panelmenu-content{border:none!important}.application-title-wrapper{color:#9ea0b3;font-weight:500}.widget-menu-wrapper{margin-top:8px}.widget-menu-header-wrapper{padding:4px 4px 4px 16px}.widget-menu-container{overflow-y:auto;overflow-x:hidden}.custom-scroll{overflow-y:hidden;scrollbar-gutter:stable}.custom-scroll:hover{overflow-y:auto}::ng-deep .document-sidebar-container .p-card{height:100%;box-shadow:none}::ng-deep .document-sidebar-container .p-card .p-card-content{height:100%;padding:0!important}::ng-deep .document-sidebar-container .p-card .p-card-body{height:100%;width:100%;padding:12px 8px;border-radius:10px;border:1px solid #e5e7eb}::ng-deep .document-sidebar-container .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content{border:none;color:var(--text-color);font-weight:400!important;background-color:var(--surface-0)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action{color:var(--text-color);font-weight:400!important;position:relative;padding:12px}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{position:absolute;right:0;top:16px;margin-right:7px;transform:rotate(90deg)!important;transition:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .company-action-wrapper:not(.p-disabled).p-highlight .p-panelmenu-header-content{margin:12px 0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content{background-color:transparent!important;border-radius:10px;padding:12px;border-bottom:0!important;border-bottom-left-radius:0!important;border-bottom-right-radius:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{transform:rotate(180deg)!important;transition:none!important;top:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link{background-color:#fff!important;color:var(--text-color);padding:12px 6px!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);box-shadow:none!important;background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem.p-focus>.p-menuitem-content{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem:not(.p-focus)>.p-menuitem-content .p-menuitem-link{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important;color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-icon{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-text{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:1px solid rgba(68,72,109,.1)!important;border-top:0!important;border-bottom-left-radius:10px;border-bottom-right-radius:10px}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator{border-top:1px solid rgba(68,72,109,.1)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}.no-documents-message{padding:12px 16px;text-align:center}.no-documents-message .text-muted{color:#9ea0b3;font-size:14px;font-style:italic}\n"], dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i9$1.Badge, selector: "p-badge", inputs: ["styleClass", "style", "badgeSize", "severity", "value", "badgeDisabled", "size"] }, { kind: "component", type: i8$2.Menu, selector: "p-menu", inputs: ["model", "popup", "style", "styleClass", "appendTo", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "ariaLabel", "ariaLabelledBy", "id", "tabindex"], outputs: ["onShow", "onHide", "onBlur", "onFocus"] }, { kind: "component", type: i9$2.Card, selector: "p-card", inputs: ["header", "subheader", "style", "styleClass"] }] });
8963
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DocumentsMenuComponent, isStandalone: false, selector: "lib-documents-menu", inputs: { catagories: "catagories", applicationNumber: "applicationNumber", contextId: "contextId" }, outputs: { menuItemSelected: "menuItemSelected" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"document-sidebar-container h-full\">\n <!-- Menu items are now used for navigation to specific sections, not for filtering documents -->\n <p-card class=\"widget-menu-wrapper h-full\">\n @if(applicationNumber){\n <div class=\"flex align-items-center justify-content-between widget-menu-header-wrapper\">\n <p class=\"mb-0 application-title-wrapper\">ID - {{applicationNumber}}</p>\n <div class=\"expand-icon-wrapper\">\n <i class=\"ri-arrow-left-s-line text-primary flex align-items-center justify-content-center w-full h-full\"></i>\n </div>\n </div>\n }\n\n <div class=\"widget-menu-container\" >\n <div class=\"widget-menu-wrapper h-ful l custom-scroll\">\n <p-menu [model]=\"categories\" styleClass=\"w-full md:w-15rem\">\n <ng-template pTemplate=\"submenuheader\" let-item>\n <span [style]=\"{\n color : '#9EA0B3'\n }\">{{ item.label }} Documents</span>\n </ng-template>\n <ng-template pTemplate=\"item\" let-item>\n <a pRipple \n class=\"flex align-items-center p-menuitem-link\"\n [class.selected-menu-item]=\"selectedMenuItemId === item._id\"\n [class.disabled-menu-item]=\"item.isSelectable === false\"\n [class.pointer-events-none]=\"item.isSelectable === false\"\n [style.opacity]=\"item.isSelectable === false ? '0.5' : '1'\"\n [style.cursor]=\"item.isSelectable === false ? 'not-allowed' : 'pointer'\"\n (click)=\"onMenuItemClick($event, item)\">\n <span [class]=\"item.icon\" class=\"text-xl\"></span>\n <span class=\"ml-2\">{{ item.label }}</span>\n <p-badge *ngIf=\"item.menuData?.shouldShowBadge\" \n class=\"ml-auto\" \n [severity]=\"item.menuData?.badgeSeverity\" \n [value]=\"item.menuData?.badgeValue\" />\n </a>\n </ng-template>\n </p-menu>\n </div>\n </div>\n </p-card>\n</div>\n\n ", styles: [".expand-icon-wrapper{border:1px solid var(--primary-color);height:24px;width:24px;border-radius:50%;background:var(--blue-bg-light)}::ng-deep .p-badge.p-badge-success{background-color:#dcfce7;color:#16a34a;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-danger{background-color:#fee2e2;color:#dc2626;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-warning{background-color:#fef3c7;color:#d97706;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-info{background-color:#e5e7eb;color:#000;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-menu .p-menuitem>.p-menuitem-content .p-menuitem-link{color:#1f2937}@media screen and (min-width: 768px){::ng-deep .md\\:w-15rem{width:100%!important}}::ng-deep .p-menu{border:none}::ng-deep .custom-scroll{scrollbar-gutter:inherit}::ng-deep .selected-menu-item{background-color:#0066ff1a!important;color:var(--primary-color)!important;border:1px solid rgba(68,72,109,.1)!important;border-radius:10px!important}::ng-deep .selected-menu-item .text-xl{color:var(--primary-color)!important}::ng-deep .disabled-menu-item{opacity:.5!important;cursor:not-allowed!important;pointer-events:none!important}::ng-deep .disabled-menu-item .text-xl{color:#9ea0b3!important}::ng-deep .disabled-menu-item .ml-2{color:#9ea0b3!important}::ng-deep .disabled-menu-item .p-badge{opacity:.5!important}::ng-deep .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important}::ng-deep .p-menuitem-link:not(.selected-menu-item) .text-xl{color:var(--text-color)!important}::ng-deep .p-panelmenu .p-panelmenu-content{border:none!important}.application-title-wrapper{color:#9ea0b3;font-weight:500}.widget-menu-wrapper{margin-top:8px}.widget-menu-header-wrapper{padding:4px 4px 4px 16px}.widget-menu-container{overflow-y:auto;overflow-x:hidden}.custom-scroll{overflow-y:hidden;scrollbar-gutter:stable}.custom-scroll:hover{overflow-y:auto}::ng-deep .document-sidebar-container .p-card{height:100%;box-shadow:none}::ng-deep .document-sidebar-container .p-card .p-card-content{height:100%;padding:0!important}::ng-deep .document-sidebar-container .p-card .p-card-body{height:100%;width:100%;padding:12px 8px;border-radius:10px;border:1px solid #e5e7eb}::ng-deep .document-sidebar-container .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content{border:none;color:var(--text-color);font-weight:400!important;background-color:var(--surface-0)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action{color:var(--text-color);font-weight:400!important;position:relative;padding:12px}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{position:absolute;right:0;top:16px;margin-right:7px;transform:rotate(90deg)!important;transition:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .company-action-wrapper:not(.p-disabled).p-highlight .p-panelmenu-header-content{margin:12px 0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content{background-color:transparent!important;border-radius:10px;padding:12px;border-bottom:0!important;border-bottom-left-radius:0!important;border-bottom-right-radius:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{transform:rotate(180deg)!important;transition:none!important;top:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link{background-color:#fff!important;color:var(--text-color);padding:12px 6px!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);box-shadow:none!important;background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem.p-focus>.p-menuitem-content{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem:not(.p-focus)>.p-menuitem-content .p-menuitem-link{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important;color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-icon{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-text{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:1px solid rgba(68,72,109,.1)!important;border-top:0!important;border-bottom-left-radius:10px;border-bottom-right-radius:10px}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator{border-top:1px solid rgba(68,72,109,.1)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}.no-documents-message{padding:12px 16px;text-align:center}.no-documents-message .text-muted{color:#9ea0b3;font-size:14px;font-style:italic}\n"], dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i9$1.Badge, selector: "p-badge", inputs: ["styleClass", "style", "badgeSize", "severity", "value", "badgeDisabled", "size"] }, { kind: "component", type: i8$2.Menu, selector: "p-menu", inputs: ["model", "popup", "style", "styleClass", "appendTo", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "ariaLabel", "ariaLabelledBy", "id", "tabindex"], outputs: ["onShow", "onHide", "onBlur", "onFocus"] }, { kind: "component", type: i9$2.Card, selector: "p-card", inputs: ["header", "subheader", "style", "styleClass"] }] });
8750
8964
  }
8751
8965
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DocumentsMenuComponent, decorators: [{
8752
8966
  type: Component,
8753
- args: [{ selector: 'lib-documents-menu', standalone: false, template: "<div class=\"document-sidebar-container h-full\">\r\n <!-- Menu items are now used for navigation to specific sections, not for filtering documents -->\r\n <p-card class=\"widget-menu-wrapper h-full\">\r\n @if(applicationNumber){\r\n <div class=\"flex align-items-center justify-content-between widget-menu-header-wrapper\">\r\n <p class=\"mb-0 application-title-wrapper\">ID - {{applicationNumber}}</p>\r\n <div class=\"expand-icon-wrapper\">\r\n <i class=\"ri-arrow-left-s-line text-primary flex align-items-center justify-content-center w-full h-full\"></i>\r\n </div>\r\n </div>\r\n }\r\n\r\n <div class=\"widget-menu-container\" >\r\n <div class=\"widget-menu-wrapper h-ful l custom-scroll\">\r\n <p-menu [model]=\"categories\" styleClass=\"w-full md:w-15rem\">\r\n <ng-template pTemplate=\"submenuheader\" let-item>\r\n <span [style]=\"{\r\n color : '#9EA0B3'\r\n }\">{{ item.label }} Documents</span>\r\n </ng-template>\r\n <ng-template pTemplate=\"item\" let-item>\r\n <a pRipple \r\n class=\"flex align-items-center p-menuitem-link\"\r\n [class.selected-menu-item]=\"selectedMenuItemId === item._id\"\r\n (click)=\"onMenuItemClick($event, item)\">\r\n <span [class]=\"item.icon\" class=\"text-xl\"></span>\r\n <span class=\"ml-2\">{{ item.label }}</span>\r\n <p-badge *ngIf=\"item.menuData?.shouldShowBadge\" \r\n class=\"ml-auto\" \r\n [severity]=\"item.menuData?.badgeSeverity\" \r\n [value]=\"item.menuData?.badgeValue\" />\r\n </a>\r\n </ng-template>\r\n </p-menu>\r\n </div>\r\n </div>\r\n </p-card>\r\n</div>\r\n\r\n ", styles: [".expand-icon-wrapper{border:1px solid var(--primary-color);height:24px;width:24px;border-radius:50%;background:var(--blue-bg-light)}::ng-deep .p-badge.p-badge-success{background-color:#dcfce7;color:#16a34a;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-danger{background-color:#fee2e2;color:#dc2626;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-warning{background-color:#fef3c7;color:#d97706;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-info{background-color:#e5e7eb;color:#000;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-menu .p-menuitem>.p-menuitem-content .p-menuitem-link{color:#1f2937}@media screen and (min-width: 768px){::ng-deep .md\\:w-15rem{width:100%!important}}::ng-deep .p-menu{border:none}::ng-deep .custom-scroll{scrollbar-gutter:inherit}::ng-deep .selected-menu-item{background-color:#0066ff1a!important;color:var(--primary-color)!important;border:1px solid rgba(68,72,109,.1)!important;border-radius:10px!important}::ng-deep .selected-menu-item .text-xl{color:var(--primary-color)!important}::ng-deep .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important}::ng-deep .p-menuitem-link:not(.selected-menu-item) .text-xl{color:var(--text-color)!important}::ng-deep .p-panelmenu .p-panelmenu-content{border:none!important}.application-title-wrapper{color:#9ea0b3;font-weight:500}.widget-menu-wrapper{margin-top:8px}.widget-menu-header-wrapper{padding:4px 4px 4px 16px}.widget-menu-container{overflow-y:auto;overflow-x:hidden}.custom-scroll{overflow-y:hidden;scrollbar-gutter:stable}.custom-scroll:hover{overflow-y:auto}::ng-deep .document-sidebar-container .p-card{height:100%;box-shadow:none}::ng-deep .document-sidebar-container .p-card .p-card-content{height:100%;padding:0!important}::ng-deep .document-sidebar-container .p-card .p-card-body{height:100%;width:100%;padding:12px 8px;border-radius:10px;border:1px solid #e5e7eb}::ng-deep .document-sidebar-container .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content{border:none;color:var(--text-color);font-weight:400!important;background-color:var(--surface-0)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action{color:var(--text-color);font-weight:400!important;position:relative;padding:12px}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{position:absolute;right:0;top:16px;margin-right:7px;transform:rotate(90deg)!important;transition:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .company-action-wrapper:not(.p-disabled).p-highlight .p-panelmenu-header-content{margin:12px 0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content{background-color:transparent!important;border-radius:10px;padding:12px;border-bottom:0!important;border-bottom-left-radius:0!important;border-bottom-right-radius:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{transform:rotate(180deg)!important;transition:none!important;top:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link{background-color:#fff!important;color:var(--text-color);padding:12px 6px!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);box-shadow:none!important;background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem.p-focus>.p-menuitem-content{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem:not(.p-focus)>.p-menuitem-content .p-menuitem-link{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important;color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-icon{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-text{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:1px solid rgba(68,72,109,.1)!important;border-top:0!important;border-bottom-left-radius:10px;border-bottom-right-radius:10px}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator{border-top:1px solid rgba(68,72,109,.1)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}.no-documents-message{padding:12px 16px;text-align:center}.no-documents-message .text-muted{color:#9ea0b3;font-size:14px;font-style:italic}\n"] }]
8967
+ args: [{ selector: 'lib-documents-menu', standalone: false, template: "<div class=\"document-sidebar-container h-full\">\n <!-- Menu items are now used for navigation to specific sections, not for filtering documents -->\n <p-card class=\"widget-menu-wrapper h-full\">\n @if(applicationNumber){\n <div class=\"flex align-items-center justify-content-between widget-menu-header-wrapper\">\n <p class=\"mb-0 application-title-wrapper\">ID - {{applicationNumber}}</p>\n <div class=\"expand-icon-wrapper\">\n <i class=\"ri-arrow-left-s-line text-primary flex align-items-center justify-content-center w-full h-full\"></i>\n </div>\n </div>\n }\n\n <div class=\"widget-menu-container\" >\n <div class=\"widget-menu-wrapper h-ful l custom-scroll\">\n <p-menu [model]=\"categories\" styleClass=\"w-full md:w-15rem\">\n <ng-template pTemplate=\"submenuheader\" let-item>\n <span [style]=\"{\n color : '#9EA0B3'\n }\">{{ item.label }} Documents</span>\n </ng-template>\n <ng-template pTemplate=\"item\" let-item>\n <a pRipple \n class=\"flex align-items-center p-menuitem-link\"\n [class.selected-menu-item]=\"selectedMenuItemId === item._id\"\n [class.disabled-menu-item]=\"item.isSelectable === false\"\n [class.pointer-events-none]=\"item.isSelectable === false\"\n [style.opacity]=\"item.isSelectable === false ? '0.5' : '1'\"\n [style.cursor]=\"item.isSelectable === false ? 'not-allowed' : 'pointer'\"\n (click)=\"onMenuItemClick($event, item)\">\n <span [class]=\"item.icon\" class=\"text-xl\"></span>\n <span class=\"ml-2\">{{ item.label }}</span>\n <p-badge *ngIf=\"item.menuData?.shouldShowBadge\" \n class=\"ml-auto\" \n [severity]=\"item.menuData?.badgeSeverity\" \n [value]=\"item.menuData?.badgeValue\" />\n </a>\n </ng-template>\n </p-menu>\n </div>\n </div>\n </p-card>\n</div>\n\n ", styles: [".expand-icon-wrapper{border:1px solid var(--primary-color);height:24px;width:24px;border-radius:50%;background:var(--blue-bg-light)}::ng-deep .p-badge.p-badge-success{background-color:#dcfce7;color:#16a34a;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-danger{background-color:#fee2e2;color:#dc2626;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-warning{background-color:#fef3c7;color:#d97706;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-badge.p-badge-info{background-color:#e5e7eb;color:#000;font-family:inherit;font-size:12px;font-weight:400;font-style:inherit}::ng-deep .p-menu .p-menuitem>.p-menuitem-content .p-menuitem-link{color:#1f2937}@media screen and (min-width: 768px){::ng-deep .md\\:w-15rem{width:100%!important}}::ng-deep .p-menu{border:none}::ng-deep .custom-scroll{scrollbar-gutter:inherit}::ng-deep .selected-menu-item{background-color:#0066ff1a!important;color:var(--primary-color)!important;border:1px solid rgba(68,72,109,.1)!important;border-radius:10px!important}::ng-deep .selected-menu-item .text-xl{color:var(--primary-color)!important}::ng-deep .disabled-menu-item{opacity:.5!important;cursor:not-allowed!important;pointer-events:none!important}::ng-deep .disabled-menu-item .text-xl{color:#9ea0b3!important}::ng-deep .disabled-menu-item .ml-2{color:#9ea0b3!important}::ng-deep .disabled-menu-item .p-badge{opacity:.5!important}::ng-deep .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important}::ng-deep .p-menuitem-link:not(.selected-menu-item) .text-xl{color:var(--text-color)!important}::ng-deep .p-panelmenu .p-panelmenu-content{border:none!important}.application-title-wrapper{color:#9ea0b3;font-weight:500}.widget-menu-wrapper{margin-top:8px}.widget-menu-header-wrapper{padding:4px 4px 4px 16px}.widget-menu-container{overflow-y:auto;overflow-x:hidden}.custom-scroll{overflow-y:hidden;scrollbar-gutter:stable}.custom-scroll:hover{overflow-y:auto}::ng-deep .document-sidebar-container .p-card{height:100%;box-shadow:none}::ng-deep .document-sidebar-container .p-card .p-card-content{height:100%;padding:0!important}::ng-deep .document-sidebar-container .p-card .p-card-body{height:100%;width:100%;padding:12px 8px;border-radius:10px;border:1px solid #e5e7eb}::ng-deep .document-sidebar-container .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content{border:none;color:var(--text-color);font-weight:400!important;background-color:var(--surface-0)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action{color:var(--text-color);font-weight:400!important;position:relative;padding:12px}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{position:absolute;right:0;top:16px;margin-right:7px;transform:rotate(90deg)!important;transition:none!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-panelmenu-header-action .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-header .p-panelmenu-header-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .company-action-wrapper:not(.p-disabled).p-highlight .p-panelmenu-header-content{margin:12px 0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content{background-color:transparent!important;border-radius:10px;padding:12px;border-bottom:0!important;border-bottom-left-radius:0!important;border-bottom-right-radius:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .no-highlight.p-panelmenu-header:not(.p-disabled).p-highlight .p-panelmenu-header-content .p-panelmenu-header-action .p-icon-wrapper{transform:rotate(180deg)!important;transition:none!important;top:0!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link{background-color:#fff!important;color:var(--text-color);padding:12px 6px!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link .p-menuitem-text{max-width:75%;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active{border:1px solid rgba(68,72,109,.1);border-radius:10px;padding:12px;color:var(--primary-color);box-shadow:none!important;background-color:#0066ff1a!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-icon{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link-active .p-menuitem-text{color:var(--primary-color)}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem.p-focus>.p-menuitem-content{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem:not(.p-focus)>.p-menuitem-content .p-menuitem-link{background-color:#fff!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item){background-color:#fff!important;border:none!important;border-radius:0!important;color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-icon{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu .p-panelmenu-content .p-menuitem>.p-menuitem-content .p-menuitem-link:not(.selected-menu-item) .p-menuitem-text{color:var(--text-color)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .p-panelmenu-expanded .p-panelmenu-content{border:1px solid rgba(68,72,109,.1)!important;border-top:0!important;border-bottom-left-radius:10px;border-bottom-right-radius:10px}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator{border-top:1px solid rgba(68,72,109,.1)!important}::ng-deep .widget-menu-wrapper .p-panelmenu-panel .widget-separator .p-panelmenu-header-content .p-panelmenu-header-action{padding:0!important}.no-documents-message{padding:12px 16px;text-align:center}.no-documents-message .text-muted{color:#9ea0b3;font-size:14px;font-style:italic}\n"] }]
8754
8968
  }], ctorParameters: () => [{ type: DocumentStore }, { type: DocumentQuery }, { type: DocumentMenuService }, { type: DocumentHelperService }], propDecorators: { catagories: [{
8755
8969
  type: Input
8756
8970
  }], applicationNumber: [{