@masterteam/delegations 0.0.28 → 0.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@masterteam/delegations",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.30",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"directory": "../../../dist/masterteam/delegations",
|
|
6
6
|
"linkDirectory": false,
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
"tailwindcss": "^4.2.2",
|
|
21
21
|
"tailwindcss-primeui": "^0.6.1",
|
|
22
22
|
"@ngxs/store": "^20.1.0",
|
|
23
|
-
"@masterteam/
|
|
23
|
+
"@masterteam/components": "^0.0.179",
|
|
24
24
|
"@masterteam/icons": "^0.0.15",
|
|
25
|
-
"@masterteam/
|
|
25
|
+
"@masterteam/forms": "^0.0.81"
|
|
26
26
|
},
|
|
27
27
|
"sideEffects": false,
|
|
28
28
|
"exports": {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as _masterteam_components_entities from '@masterteam/components/entities';
|
|
2
|
+
import { EntityUserValue } from '@masterteam/components/entities';
|
|
2
3
|
import * as _masterteam_delegations from '@masterteam/delegations';
|
|
3
4
|
import * as _angular_core from '@angular/core';
|
|
4
|
-
import { OnInit
|
|
5
|
+
import { OnInit } from '@angular/core';
|
|
5
6
|
import { Popover } from 'primeng/popover';
|
|
6
7
|
import { PageHeaderTab } from '@masterteam/components/page-header';
|
|
7
|
-
import { TableAction, ColumnDef } from '@masterteam/components/table';
|
|
8
|
+
import { TableAction, TableStatusMapValue, ColumnDef } from '@masterteam/components/table';
|
|
8
9
|
import { FormControl } from '@angular/forms';
|
|
9
10
|
import { HttpContext, HttpInterceptorFn } from '@angular/common/http';
|
|
10
11
|
import { DynamicFormConfig } from '@masterteam/components';
|
|
@@ -334,7 +335,7 @@ declare class TopbarDelegationMenu implements OnInit {
|
|
|
334
335
|
protected readonly onBehalfOf: _angular_core.Signal<_masterteam_delegations.DelegationParty | null>;
|
|
335
336
|
protected readonly executedBy: _angular_core.Signal<_masterteam_delegations.DelegationParty | null>;
|
|
336
337
|
private readonly promptShown;
|
|
337
|
-
protected readonly mode: _angular_core.Signal<"
|
|
338
|
+
protected readonly mode: _angular_core.Signal<"active" | "candidates" | "hidden">;
|
|
338
339
|
constructor();
|
|
339
340
|
ngOnInit(): void;
|
|
340
341
|
protected formatScopeSummary(summary: DelegationRow['scopeSummary']): string;
|
|
@@ -374,7 +375,7 @@ declare class StartSessionDialog {
|
|
|
374
375
|
private readonly transloco;
|
|
375
376
|
protected readonly isBusy: _angular_core.Signal<boolean>;
|
|
376
377
|
protected readonly bodyKey: _angular_core.Signal<"delegations.session.switchConfirmBody" | "delegations.session.startConfirmBody">;
|
|
377
|
-
protected readonly confirmLabelKey: _angular_core.Signal<"delegations.action.
|
|
378
|
+
protected readonly confirmLabelKey: _angular_core.Signal<"delegations.action.startSession" | "delegations.action.switchSession">;
|
|
378
379
|
protected readonly successMessageKey: _angular_core.Signal<"delegations.session.switched" | "delegations.session.started">;
|
|
379
380
|
protected formatScopeSummary(summary: DelegationRow['scopeSummary']): string;
|
|
380
381
|
protected userEntity(party: DelegationRow['delegator']): _masterteam_components_entities.EntityData;
|
|
@@ -422,7 +423,15 @@ declare class Delegations implements OnInit {
|
|
|
422
423
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<Delegations, "mt-delegations", never, {}, {}, never, never, true, never>;
|
|
423
424
|
}
|
|
424
425
|
|
|
426
|
+
declare function toDelegationUserValue(party: DelegationParty | null | undefined): EntityUserValue;
|
|
427
|
+
|
|
425
428
|
type DelegationTab = 'my' | 'assigned' | 'approvals';
|
|
429
|
+
type DelegationTableRow = DelegationRow & {
|
|
430
|
+
listedUser: ReturnType<typeof toDelegationUserValue>;
|
|
431
|
+
delegatorUser: ReturnType<typeof toDelegationUserValue>;
|
|
432
|
+
delegatedToUser: ReturnType<typeof toDelegationUserValue>;
|
|
433
|
+
daysText: string;
|
|
434
|
+
};
|
|
426
435
|
/**
|
|
427
436
|
* Delegations portal page (doc 02, 09): two lists — My Delegations (current user
|
|
428
437
|
* is delegator) and Delegated To Me (current user is delegate). Rows render only
|
|
@@ -435,25 +444,25 @@ declare class DelegationsList implements OnInit {
|
|
|
435
444
|
* `withComponentInputBinding()` — admin leaves it default; client passes
|
|
436
445
|
* `data: { showBreadcrumb: false }`.
|
|
437
446
|
*/
|
|
438
|
-
readonly showBreadcrumb: _angular_core.
|
|
447
|
+
readonly showBreadcrumb: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
439
448
|
/**
|
|
440
449
|
* Admin routes can embed the list under `mt-delegations`, which already owns
|
|
441
450
|
* the page title, back button, and route tabs.
|
|
442
451
|
*/
|
|
443
|
-
readonly showPageShell: _angular_core.
|
|
452
|
+
readonly showPageShell: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
444
453
|
/**
|
|
445
454
|
* Admin-managed surface: the create/edit form also collects the Delegator /
|
|
446
455
|
* From user (admin creates a delegation between two users). Client
|
|
447
456
|
* self-service leaves this false. Bound from route data via
|
|
448
457
|
* `withComponentInputBinding()` — admin passes `data: { adminMode: true }`.
|
|
449
458
|
*/
|
|
450
|
-
readonly adminMode: _angular_core.
|
|
459
|
+
readonly adminMode: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
451
460
|
readonly surfaceTitleKey: _angular_core.InputSignal<string>;
|
|
452
461
|
readonly assignedTabLabelKey: _angular_core.InputSignal<string>;
|
|
453
|
-
readonly assignedDecisionTab: _angular_core.
|
|
462
|
+
readonly assignedDecisionTab: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
454
463
|
readonly assignedEmptyStateKey: _angular_core.InputSignal<string>;
|
|
455
464
|
readonly assignedStatus: _angular_core.InputSignal<DelegationEffectiveStatus | null>;
|
|
456
|
-
readonly showApprovalTab: _angular_core.
|
|
465
|
+
readonly showApprovalTab: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
457
466
|
readonly approvalTabLabelKey: _angular_core.InputSignal<string>;
|
|
458
467
|
readonly approvalEmptyStateKey: _angular_core.InputSignal<string>;
|
|
459
468
|
readonly approvalStatus: _angular_core.InputSignal<DelegationEffectiveStatus>;
|
|
@@ -482,14 +491,12 @@ declare class DelegationsList implements OnInit {
|
|
|
482
491
|
}[]>;
|
|
483
492
|
protected readonly isLoading: _angular_core.Signal<boolean>;
|
|
484
493
|
protected readonly rows: _angular_core.Signal<DelegationRow[]>;
|
|
494
|
+
protected readonly tableRows: _angular_core.Signal<DelegationTableRow[]>;
|
|
485
495
|
protected readonly emptyStateKey: _angular_core.Signal<string>;
|
|
486
|
-
statusCol: _angular_core.Signal<TemplateRef<unknown>>;
|
|
487
|
-
userCol: _angular_core.Signal<TemplateRef<unknown>>;
|
|
488
|
-
delegatorCol: _angular_core.Signal<TemplateRef<unknown>>;
|
|
489
|
-
delegatedUserCol: _angular_core.Signal<TemplateRef<unknown>>;
|
|
490
|
-
daysCol: _angular_core.Signal<TemplateRef<unknown>>;
|
|
491
496
|
protected readonly tableActions: _angular_core.Signal<TableAction[]>;
|
|
492
497
|
protected readonly rowActions: _angular_core.WritableSignal<TableAction[]>;
|
|
498
|
+
private readonly statusColors;
|
|
499
|
+
protected readonly statusMap: _angular_core.WritableSignal<Record<DelegationEffectiveStatus, TableStatusMapValue>>;
|
|
493
500
|
protected readonly tableColumns: _angular_core.WritableSignal<ColumnDef[]>;
|
|
494
501
|
private readonly busyIds;
|
|
495
502
|
private readonly weekdayKeys;
|
|
@@ -500,8 +507,8 @@ declare class DelegationsList implements OnInit {
|
|
|
500
507
|
private reloadCurrentTab;
|
|
501
508
|
protected has(row: DelegationRow, action: DelegationAllowedAction): boolean;
|
|
502
509
|
protected formatDays(row: DelegationRow): string;
|
|
503
|
-
protected getListedParty(row: DelegationRow): DelegationParty;
|
|
504
|
-
|
|
510
|
+
protected getListedParty(row: DelegationRow): _masterteam_delegations.DelegationParty;
|
|
511
|
+
private translateTab;
|
|
505
512
|
private viewDetails;
|
|
506
513
|
private openForm;
|
|
507
514
|
private approve;
|