@memberjunction/ng-tasks 2.105.0
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/.turbo/turbo-build.log +4 -0
- package/CHANGELOG.md +10 -0
- package/README.md +233 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/components/gantt-task-viewer.component.d.ts +44 -0
- package/dist/lib/components/gantt-task-viewer.component.d.ts.map +1 -0
- package/dist/lib/components/gantt-task-viewer.component.js +461 -0
- package/dist/lib/components/gantt-task-viewer.component.js.map +1 -0
- package/dist/lib/components/simple-task-viewer.component.d.ts +36 -0
- package/dist/lib/components/simple-task-viewer.component.d.ts.map +1 -0
- package/dist/lib/components/simple-task-viewer.component.js +275 -0
- package/dist/lib/components/simple-task-viewer.component.js.map +1 -0
- package/dist/lib/components/task-detail-panel.component.d.ts +26 -0
- package/dist/lib/components/task-detail-panel.component.d.ts.map +1 -0
- package/dist/lib/components/task-detail-panel.component.js +294 -0
- package/dist/lib/components/task-detail-panel.component.js.map +1 -0
- package/dist/lib/components/task.component.d.ts +34 -0
- package/dist/lib/components/task.component.d.ts.map +1 -0
- package/dist/lib/components/task.component.js +201 -0
- package/dist/lib/components/task.component.js.map +1 -0
- package/dist/lib/models/task-view.models.d.ts +17 -0
- package/dist/lib/models/task-view.models.d.ts.map +1 -0
- package/dist/lib/models/task-view.models.js +2 -0
- package/dist/lib/models/task-view.models.js.map +1 -0
- package/dist/lib/ng-tasks.module.d.ts +14 -0
- package/dist/lib/ng-tasks.module.d.ts.map +1 -0
- package/dist/lib/ng-tasks.module.js +37 -0
- package/dist/lib/ng-tasks.module.js.map +1 -0
- package/dist/public-api.d.ts +9 -0
- package/dist/public-api.d.ts.map +1 -0
- package/dist/public-api.js +12 -0
- package/dist/public-api.js.map +1 -0
- package/package.json +31 -0
- package/src/index.ts +1 -0
- package/src/lib/components/gantt-task-viewer.component.ts +524 -0
- package/src/lib/components/simple-task-viewer.component.ts +356 -0
- package/src/lib/components/task-detail-panel.component.ts +304 -0
- package/src/lib/components/task.component.ts +175 -0
- package/src/lib/models/task-view.models.ts +19 -0
- package/src/lib/ng-tasks.module.ts +22 -0
- package/src/lib/types/frappe-gantt.d.ts +32 -0
- package/src/public-api.ts +14 -0
- package/tsconfig.json +24 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import { TaskEntity, TaskDependencyEntity } from '@memberjunction/core-entities';
|
|
3
|
+
import { TaskViewMode } from '../models/task-view.models';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
/**
|
|
6
|
+
* Main task component that composes SimpleTaskViewer and GanttTaskViewer
|
|
7
|
+
* Allows switching between list and Gantt chart views
|
|
8
|
+
*/
|
|
9
|
+
export declare class TaskComponent {
|
|
10
|
+
tasks: TaskEntity[];
|
|
11
|
+
ganttTasks?: TaskEntity[];
|
|
12
|
+
taskDependencies?: TaskDependencyEntity[];
|
|
13
|
+
agentRunMap?: Map<string, string>;
|
|
14
|
+
title?: string;
|
|
15
|
+
description?: string;
|
|
16
|
+
showHeader: boolean;
|
|
17
|
+
showViewToggle: boolean;
|
|
18
|
+
viewMode: TaskViewMode;
|
|
19
|
+
viewModeChanged: EventEmitter<TaskViewMode>;
|
|
20
|
+
taskClicked: EventEmitter<TaskEntity>;
|
|
21
|
+
openEntityRecord: EventEmitter<{
|
|
22
|
+
entityName: string;
|
|
23
|
+
recordId: string;
|
|
24
|
+
}>;
|
|
25
|
+
setViewMode(mode: TaskViewMode): void;
|
|
26
|
+
onTaskClicked(task: TaskEntity): void;
|
|
27
|
+
onOpenEntityRecord(event: {
|
|
28
|
+
entityName: string;
|
|
29
|
+
recordId: string;
|
|
30
|
+
}): void;
|
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TaskComponent, never>;
|
|
32
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TaskComponent, "mj-task", never, { "tasks": { "alias": "tasks"; "required": false; }; "ganttTasks": { "alias": "ganttTasks"; "required": false; }; "taskDependencies": { "alias": "taskDependencies"; "required": false; }; "agentRunMap": { "alias": "agentRunMap"; "required": false; }; "title": { "alias": "title"; "required": false; }; "description": { "alias": "description"; "required": false; }; "showHeader": { "alias": "showHeader"; "required": false; }; "showViewToggle": { "alias": "showViewToggle"; "required": false; }; "viewMode": { "alias": "viewMode"; "required": false; }; }, { "viewModeChanged": "viewModeChanged"; "taskClicked": "taskClicked"; "openEntityRecord": "openEntityRecord"; }, never, never, true, never>;
|
|
33
|
+
}
|
|
34
|
+
//# sourceMappingURL=task.component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"task.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/task.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAAE,MAAM,eAAe,CAAC;AAEvE,OAAO,EAAE,UAAU,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACjF,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;;AAI1D;;;GAGG;AACH,qBAwIa,aAAa;IACf,KAAK,EAAE,UAAU,EAAE,CAAM;IACzB,UAAU,CAAC,EAAE,UAAU,EAAE,CAAC;IAC1B,gBAAgB,CAAC,EAAE,oBAAoB,EAAE,CAAC;IAC1C,WAAW,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,OAAO,CAAQ;IAC3B,cAAc,EAAE,OAAO,CAAQ;IAC/B,QAAQ,EAAE,YAAY,CAAY;IAEjC,eAAe,6BAAoC;IACnD,WAAW,2BAAkC;IAC7C,gBAAgB;oBAAkC,MAAM;kBAAY,MAAM;OAAM;IAEnF,WAAW,CAAC,IAAI,EAAE,YAAY,GAAG,IAAI;IAKrC,aAAa,CAAC,IAAI,EAAE,UAAU,GAAG,IAAI;IAIrC,kBAAkB,CAAC,KAAK,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;yCAxBrE,aAAa;2CAAb,aAAa;CA2BzB"}
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
import { Component, Input, Output, EventEmitter } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
import { SimpleTaskViewerComponent } from './simple-task-viewer.component';
|
|
4
|
+
import { GanttTaskViewerComponent } from './gantt-task-viewer.component';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
import * as i1 from "@angular/common";
|
|
7
|
+
const _c0 = () => [];
|
|
8
|
+
function TaskComponent_div_1_h2_2_Template(rf, ctx) { if (rf & 1) {
|
|
9
|
+
i0.ɵɵelementStart(0, "h2", 10);
|
|
10
|
+
i0.ɵɵtext(1);
|
|
11
|
+
i0.ɵɵelementEnd();
|
|
12
|
+
} if (rf & 2) {
|
|
13
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
14
|
+
i0.ɵɵadvance();
|
|
15
|
+
i0.ɵɵtextInterpolate(ctx_r0.title);
|
|
16
|
+
} }
|
|
17
|
+
function TaskComponent_div_1_p_3_Template(rf, ctx) { if (rf & 1) {
|
|
18
|
+
i0.ɵɵelementStart(0, "p", 11);
|
|
19
|
+
i0.ɵɵtext(1);
|
|
20
|
+
i0.ɵɵelementEnd();
|
|
21
|
+
} if (rf & 2) {
|
|
22
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
23
|
+
i0.ɵɵadvance();
|
|
24
|
+
i0.ɵɵtextInterpolate(ctx_r0.description);
|
|
25
|
+
} }
|
|
26
|
+
function TaskComponent_div_1_div_4_Template(rf, ctx) { if (rf & 1) {
|
|
27
|
+
const _r2 = i0.ɵɵgetCurrentView();
|
|
28
|
+
i0.ɵɵelementStart(0, "div", 12)(1, "button", 13);
|
|
29
|
+
i0.ɵɵlistener("click", function TaskComponent_div_1_div_4_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.setViewMode("gantt")); });
|
|
30
|
+
i0.ɵɵelement(2, "i", 14);
|
|
31
|
+
i0.ɵɵelementStart(3, "span");
|
|
32
|
+
i0.ɵɵtext(4, "Gantt");
|
|
33
|
+
i0.ɵɵelementEnd()();
|
|
34
|
+
i0.ɵɵelementStart(5, "button", 15);
|
|
35
|
+
i0.ɵɵlistener("click", function TaskComponent_div_1_div_4_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.setViewMode("simple")); });
|
|
36
|
+
i0.ɵɵelement(6, "i", 16);
|
|
37
|
+
i0.ɵɵelementStart(7, "span");
|
|
38
|
+
i0.ɵɵtext(8, "List");
|
|
39
|
+
i0.ɵɵelementEnd()()();
|
|
40
|
+
} if (rf & 2) {
|
|
41
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
42
|
+
i0.ɵɵadvance();
|
|
43
|
+
i0.ɵɵclassProp("active", ctx_r0.viewMode === "gantt");
|
|
44
|
+
i0.ɵɵadvance(4);
|
|
45
|
+
i0.ɵɵclassProp("active", ctx_r0.viewMode === "simple");
|
|
46
|
+
} }
|
|
47
|
+
function TaskComponent_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
48
|
+
i0.ɵɵelementStart(0, "div", 5)(1, "div", 6);
|
|
49
|
+
i0.ɵɵtemplate(2, TaskComponent_div_1_h2_2_Template, 2, 1, "h2", 7)(3, TaskComponent_div_1_p_3_Template, 2, 1, "p", 8);
|
|
50
|
+
i0.ɵɵelementEnd();
|
|
51
|
+
i0.ɵɵtemplate(4, TaskComponent_div_1_div_4_Template, 9, 4, "div", 9);
|
|
52
|
+
i0.ɵɵelementEnd();
|
|
53
|
+
} if (rf & 2) {
|
|
54
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
55
|
+
i0.ɵɵadvance(2);
|
|
56
|
+
i0.ɵɵproperty("ngIf", ctx_r0.title);
|
|
57
|
+
i0.ɵɵadvance();
|
|
58
|
+
i0.ɵɵproperty("ngIf", ctx_r0.description);
|
|
59
|
+
i0.ɵɵadvance();
|
|
60
|
+
i0.ɵɵproperty("ngIf", ctx_r0.showViewToggle);
|
|
61
|
+
} }
|
|
62
|
+
function TaskComponent_mj_simple_task_viewer_3_Template(rf, ctx) { if (rf & 1) {
|
|
63
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
64
|
+
i0.ɵɵelementStart(0, "mj-simple-task-viewer", 17);
|
|
65
|
+
i0.ɵɵlistener("taskClicked", function TaskComponent_mj_simple_task_viewer_3_Template_mj_simple_task_viewer_taskClicked_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onTaskClicked($event)); })("openEntityRecord", function TaskComponent_mj_simple_task_viewer_3_Template_mj_simple_task_viewer_openEntityRecord_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onOpenEntityRecord($event)); });
|
|
66
|
+
i0.ɵɵelementEnd();
|
|
67
|
+
} if (rf & 2) {
|
|
68
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
69
|
+
i0.ɵɵproperty("tasks", ctx_r0.tasks)("agentRunMap", ctx_r0.agentRunMap);
|
|
70
|
+
} }
|
|
71
|
+
function TaskComponent_mj_gantt_task_viewer_4_Template(rf, ctx) { if (rf & 1) {
|
|
72
|
+
const _r4 = i0.ɵɵgetCurrentView();
|
|
73
|
+
i0.ɵɵelementStart(0, "mj-gantt-task-viewer", 18);
|
|
74
|
+
i0.ɵɵlistener("taskClicked", function TaskComponent_mj_gantt_task_viewer_4_Template_mj_gantt_task_viewer_taskClicked_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onTaskClicked($event)); })("openEntityRecord", function TaskComponent_mj_gantt_task_viewer_4_Template_mj_gantt_task_viewer_openEntityRecord_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onOpenEntityRecord($event)); });
|
|
75
|
+
i0.ɵɵelementEnd();
|
|
76
|
+
} if (rf & 2) {
|
|
77
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
78
|
+
i0.ɵɵproperty("tasks", ctx_r0.ganttTasks || ctx_r0.tasks)("taskDependencies", ctx_r0.taskDependencies || i0.ɵɵpureFunction0(3, _c0))("agentRunMap", ctx_r0.agentRunMap);
|
|
79
|
+
} }
|
|
80
|
+
/**
|
|
81
|
+
* Main task component that composes SimpleTaskViewer and GanttTaskViewer
|
|
82
|
+
* Allows switching between list and Gantt chart views
|
|
83
|
+
*/
|
|
84
|
+
export class TaskComponent {
|
|
85
|
+
tasks = [];
|
|
86
|
+
ganttTasks; // Optional separate task list for Gantt (includes parent)
|
|
87
|
+
taskDependencies; // Task dependencies for Gantt links
|
|
88
|
+
agentRunMap; // Maps TaskID -> AgentRunID
|
|
89
|
+
title;
|
|
90
|
+
description;
|
|
91
|
+
showHeader = true;
|
|
92
|
+
showViewToggle = true; // Show Gantt/List toggle
|
|
93
|
+
viewMode = 'simple';
|
|
94
|
+
viewModeChanged = new EventEmitter();
|
|
95
|
+
taskClicked = new EventEmitter();
|
|
96
|
+
openEntityRecord = new EventEmitter();
|
|
97
|
+
setViewMode(mode) {
|
|
98
|
+
this.viewMode = mode;
|
|
99
|
+
this.viewModeChanged.emit(mode);
|
|
100
|
+
}
|
|
101
|
+
onTaskClicked(task) {
|
|
102
|
+
this.taskClicked.emit(task);
|
|
103
|
+
}
|
|
104
|
+
onOpenEntityRecord(event) {
|
|
105
|
+
this.openEntityRecord.emit(event);
|
|
106
|
+
}
|
|
107
|
+
static ɵfac = function TaskComponent_Factory(t) { return new (t || TaskComponent)(); };
|
|
108
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: TaskComponent, selectors: [["mj-task"]], inputs: { tasks: "tasks", ganttTasks: "ganttTasks", taskDependencies: "taskDependencies", agentRunMap: "agentRunMap", title: "title", description: "description", showHeader: "showHeader", showViewToggle: "showViewToggle", viewMode: "viewMode" }, outputs: { viewModeChanged: "viewModeChanged", taskClicked: "taskClicked", openEntityRecord: "openEntityRecord" }, standalone: true, features: [i0.ɵɵStandaloneFeature], decls: 5, vars: 3, consts: [[1, "task-component"], ["class", "task-header", 4, "ngIf"], [1, "task-viewer"], [3, "tasks", "agentRunMap", "taskClicked", "openEntityRecord", 4, "ngIf"], [3, "tasks", "taskDependencies", "agentRunMap", "taskClicked", "openEntityRecord", 4, "ngIf"], [1, "task-header"], [1, "header-left"], ["class", "task-title", 4, "ngIf"], ["class", "task-description", 4, "ngIf"], ["class", "view-toggle", 4, "ngIf"], [1, "task-title"], [1, "task-description"], [1, "view-toggle"], ["title", "Gantt Chart", 1, "toggle-btn", 3, "click"], [1, "fas", "fa-chart-gantt"], ["title", "List View", 1, "toggle-btn", 3, "click"], [1, "fas", "fa-list"], [3, "taskClicked", "openEntityRecord", "tasks", "agentRunMap"], [3, "taskClicked", "openEntityRecord", "tasks", "taskDependencies", "agentRunMap"]], template: function TaskComponent_Template(rf, ctx) { if (rf & 1) {
|
|
109
|
+
i0.ɵɵelementStart(0, "div", 0);
|
|
110
|
+
i0.ɵɵtemplate(1, TaskComponent_div_1_Template, 5, 3, "div", 1);
|
|
111
|
+
i0.ɵɵelementStart(2, "div", 2);
|
|
112
|
+
i0.ɵɵtemplate(3, TaskComponent_mj_simple_task_viewer_3_Template, 1, 2, "mj-simple-task-viewer", 3)(4, TaskComponent_mj_gantt_task_viewer_4_Template, 1, 4, "mj-gantt-task-viewer", 4);
|
|
113
|
+
i0.ɵɵelementEnd()();
|
|
114
|
+
} if (rf & 2) {
|
|
115
|
+
i0.ɵɵadvance();
|
|
116
|
+
i0.ɵɵproperty("ngIf", ctx.showHeader);
|
|
117
|
+
i0.ɵɵadvance(2);
|
|
118
|
+
i0.ɵɵproperty("ngIf", ctx.viewMode === "simple");
|
|
119
|
+
i0.ɵɵadvance();
|
|
120
|
+
i0.ɵɵproperty("ngIf", ctx.viewMode === "gantt");
|
|
121
|
+
} }, dependencies: [CommonModule, i1.NgIf, SimpleTaskViewerComponent, GanttTaskViewerComponent], styles: [".task-component[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n height: 100%;\n background: #FAFAFA;\n }\n\n .task-header[_ngcontent-%COMP%] {\n display: flex;\n justify-content: space-between;\n align-items: flex-start;\n gap: 20px;\n padding: 20px 24px;\n background: white;\n border-bottom: 1px solid #E5E7EB;\n }\n\n .header-left[_ngcontent-%COMP%] {\n flex: 1;\n min-width: 0;\n }\n\n .task-title[_ngcontent-%COMP%] {\n margin: 0 0 8px 0;\n font-size: 20px;\n font-weight: 700;\n color: #111827;\n }\n\n .task-description[_ngcontent-%COMP%] {\n margin: 0;\n font-size: 14px;\n color: #6B7280;\n line-height: 1.5;\n }\n\n .view-toggle[_ngcontent-%COMP%] {\n display: flex;\n gap: 8px;\n background: #F3F4F6;\n padding: 4px;\n border-radius: 8px;\n }\n\n .toggle-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 16px;\n border: none;\n background: transparent;\n color: #6B7280;\n font-size: 13px;\n font-weight: 600;\n border-radius: 6px;\n cursor: pointer;\n transition: all 0.15s;\n }\n\n .toggle-btn[_ngcontent-%COMP%]:hover {\n color: #111827;\n background: rgba(255, 255, 255, 0.5);\n }\n\n .toggle-btn.active[_ngcontent-%COMP%] {\n background: white;\n color: #3B82F6;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);\n }\n\n .toggle-btn[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 14px;\n }\n\n .task-viewer[_ngcontent-%COMP%] {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n }"] });
|
|
122
|
+
}
|
|
123
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TaskComponent, [{
|
|
124
|
+
type: Component,
|
|
125
|
+
args: [{ selector: 'mj-task', standalone: true, imports: [CommonModule, SimpleTaskViewerComponent, GanttTaskViewerComponent], template: `
|
|
126
|
+
<div class="task-component">
|
|
127
|
+
<!-- Header with View Toggle -->
|
|
128
|
+
<div class="task-header" *ngIf="showHeader">
|
|
129
|
+
<div class="header-left">
|
|
130
|
+
<h2 class="task-title" *ngIf="title">{{ title }}</h2>
|
|
131
|
+
<p class="task-description" *ngIf="description">{{ description }}</p>
|
|
132
|
+
</div>
|
|
133
|
+
|
|
134
|
+
<div class="view-toggle" *ngIf="showViewToggle">
|
|
135
|
+
<button
|
|
136
|
+
class="toggle-btn"
|
|
137
|
+
[class.active]="viewMode === 'gantt'"
|
|
138
|
+
(click)="setViewMode('gantt')"
|
|
139
|
+
title="Gantt Chart">
|
|
140
|
+
<i class="fas fa-chart-gantt"></i>
|
|
141
|
+
<span>Gantt</span>
|
|
142
|
+
</button>
|
|
143
|
+
<button
|
|
144
|
+
class="toggle-btn"
|
|
145
|
+
[class.active]="viewMode === 'simple'"
|
|
146
|
+
(click)="setViewMode('simple')"
|
|
147
|
+
title="List View">
|
|
148
|
+
<i class="fas fa-list"></i>
|
|
149
|
+
<span>List</span>
|
|
150
|
+
</button>
|
|
151
|
+
</div>
|
|
152
|
+
</div>
|
|
153
|
+
|
|
154
|
+
<!-- Task Viewer (Simple or Gantt) -->
|
|
155
|
+
<div class="task-viewer">
|
|
156
|
+
<mj-simple-task-viewer
|
|
157
|
+
*ngIf="viewMode === 'simple'"
|
|
158
|
+
[tasks]="tasks"
|
|
159
|
+
[agentRunMap]="agentRunMap"
|
|
160
|
+
(taskClicked)="onTaskClicked($event)"
|
|
161
|
+
(openEntityRecord)="onOpenEntityRecord($event)">
|
|
162
|
+
</mj-simple-task-viewer>
|
|
163
|
+
|
|
164
|
+
<mj-gantt-task-viewer
|
|
165
|
+
*ngIf="viewMode === 'gantt'"
|
|
166
|
+
[tasks]="ganttTasks || tasks"
|
|
167
|
+
[taskDependencies]="taskDependencies || []"
|
|
168
|
+
[agentRunMap]="agentRunMap"
|
|
169
|
+
(taskClicked)="onTaskClicked($event)"
|
|
170
|
+
(openEntityRecord)="onOpenEntityRecord($event)">
|
|
171
|
+
</mj-gantt-task-viewer>
|
|
172
|
+
</div>
|
|
173
|
+
</div>
|
|
174
|
+
`, styles: ["\n .task-component {\n display: flex;\n flex-direction: column;\n height: 100%;\n background: #FAFAFA;\n }\n\n .task-header {\n display: flex;\n justify-content: space-between;\n align-items: flex-start;\n gap: 20px;\n padding: 20px 24px;\n background: white;\n border-bottom: 1px solid #E5E7EB;\n }\n\n .header-left {\n flex: 1;\n min-width: 0;\n }\n\n .task-title {\n margin: 0 0 8px 0;\n font-size: 20px;\n font-weight: 700;\n color: #111827;\n }\n\n .task-description {\n margin: 0;\n font-size: 14px;\n color: #6B7280;\n line-height: 1.5;\n }\n\n .view-toggle {\n display: flex;\n gap: 8px;\n background: #F3F4F6;\n padding: 4px;\n border-radius: 8px;\n }\n\n .toggle-btn {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 16px;\n border: none;\n background: transparent;\n color: #6B7280;\n font-size: 13px;\n font-weight: 600;\n border-radius: 6px;\n cursor: pointer;\n transition: all 0.15s;\n }\n\n .toggle-btn:hover {\n color: #111827;\n background: rgba(255, 255, 255, 0.5);\n }\n\n .toggle-btn.active {\n background: white;\n color: #3B82F6;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);\n }\n\n .toggle-btn i {\n font-size: 14px;\n }\n\n .task-viewer {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n }\n "] }]
|
|
175
|
+
}], null, { tasks: [{
|
|
176
|
+
type: Input
|
|
177
|
+
}], ganttTasks: [{
|
|
178
|
+
type: Input
|
|
179
|
+
}], taskDependencies: [{
|
|
180
|
+
type: Input
|
|
181
|
+
}], agentRunMap: [{
|
|
182
|
+
type: Input
|
|
183
|
+
}], title: [{
|
|
184
|
+
type: Input
|
|
185
|
+
}], description: [{
|
|
186
|
+
type: Input
|
|
187
|
+
}], showHeader: [{
|
|
188
|
+
type: Input
|
|
189
|
+
}], showViewToggle: [{
|
|
190
|
+
type: Input
|
|
191
|
+
}], viewMode: [{
|
|
192
|
+
type: Input
|
|
193
|
+
}], viewModeChanged: [{
|
|
194
|
+
type: Output
|
|
195
|
+
}], taskClicked: [{
|
|
196
|
+
type: Output
|
|
197
|
+
}], openEntityRecord: [{
|
|
198
|
+
type: Output
|
|
199
|
+
}] }); })();
|
|
200
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(TaskComponent, { className: "TaskComponent", filePath: "src/lib/components/task.component.ts", lineNumber: 148 }); })();
|
|
201
|
+
//# sourceMappingURL=task.component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"task.component.js","sourceRoot":"","sources":["../../../src/lib/components/task.component.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* View mode for task display
|
|
3
|
+
*/
|
|
4
|
+
export type TaskViewMode = 'simple' | 'gantt';
|
|
5
|
+
/**
|
|
6
|
+
* Gantt bar data for Frappe Gantt
|
|
7
|
+
*/
|
|
8
|
+
export interface GanttTask {
|
|
9
|
+
id: string;
|
|
10
|
+
name: string;
|
|
11
|
+
start: string;
|
|
12
|
+
end: string;
|
|
13
|
+
progress: number;
|
|
14
|
+
dependencies?: string;
|
|
15
|
+
custom_class?: string;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=task-view.models.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"task-view.models.d.ts","sourceRoot":"","sources":["../../../src/lib/models/task-view.models.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,OAAO,CAAC;AAE9C;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"task-view.models.js","sourceRoot":"","sources":["../../../src/lib/models/task-view.models.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./components/task.component";
|
|
3
|
+
import * as i2 from "./components/simple-task-viewer.component";
|
|
4
|
+
import * as i3 from "./components/gantt-task-viewer.component";
|
|
5
|
+
/**
|
|
6
|
+
* MemberJunction Tasks Module
|
|
7
|
+
* Provides task visualization components with Gantt chart support
|
|
8
|
+
*/
|
|
9
|
+
export declare class NgTasksModule {
|
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgTasksModule, never>;
|
|
11
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<NgTasksModule, never, [typeof i1.TaskComponent, typeof i2.SimpleTaskViewerComponent, typeof i3.GanttTaskViewerComponent], [typeof i1.TaskComponent, typeof i2.SimpleTaskViewerComponent, typeof i3.GanttTaskViewerComponent]>;
|
|
12
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<NgTasksModule>;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=ng-tasks.module.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ng-tasks.module.d.ts","sourceRoot":"","sources":["../../src/lib/ng-tasks.module.ts"],"names":[],"mappings":";;;;AAKA;;;GAGG;AACH,qBAYa,aAAa;yCAAb,aAAa;0CAAb,aAAa;0CAAb,aAAa;CAAI"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { TaskComponent } from './components/task.component';
|
|
3
|
+
import { SimpleTaskViewerComponent } from './components/simple-task-viewer.component';
|
|
4
|
+
import { GanttTaskViewerComponent } from './components/gantt-task-viewer.component';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
/**
|
|
7
|
+
* MemberJunction Tasks Module
|
|
8
|
+
* Provides task visualization components with Gantt chart support
|
|
9
|
+
*/
|
|
10
|
+
export class NgTasksModule {
|
|
11
|
+
static ɵfac = function NgTasksModule_Factory(t) { return new (t || NgTasksModule)(); };
|
|
12
|
+
static ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: NgTasksModule });
|
|
13
|
+
static ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [TaskComponent,
|
|
14
|
+
SimpleTaskViewerComponent,
|
|
15
|
+
GanttTaskViewerComponent] });
|
|
16
|
+
}
|
|
17
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NgTasksModule, [{
|
|
18
|
+
type: NgModule,
|
|
19
|
+
args: [{
|
|
20
|
+
imports: [
|
|
21
|
+
TaskComponent,
|
|
22
|
+
SimpleTaskViewerComponent,
|
|
23
|
+
GanttTaskViewerComponent
|
|
24
|
+
],
|
|
25
|
+
exports: [
|
|
26
|
+
TaskComponent,
|
|
27
|
+
SimpleTaskViewerComponent,
|
|
28
|
+
GanttTaskViewerComponent
|
|
29
|
+
]
|
|
30
|
+
}]
|
|
31
|
+
}], null, null); })();
|
|
32
|
+
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(NgTasksModule, { imports: [TaskComponent,
|
|
33
|
+
SimpleTaskViewerComponent,
|
|
34
|
+
GanttTaskViewerComponent], exports: [TaskComponent,
|
|
35
|
+
SimpleTaskViewerComponent,
|
|
36
|
+
GanttTaskViewerComponent] }); })();
|
|
37
|
+
//# sourceMappingURL=ng-tasks.module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ng-tasks.module.js","sourceRoot":"","sources":["../../src/lib/ng-tasks.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,EAAE,yBAAyB,EAAE,MAAM,2CAA2C,CAAC;AACtF,OAAO,EAAE,wBAAwB,EAAE,MAAM,0CAA0C,CAAC;;AAEpF;;;GAGG;AAaH,MAAM,OAAO,aAAa;uEAAb,aAAa;4DAAb,aAAa;gEAVtB,aAAa;YACb,yBAAyB;YACzB,wBAAwB;;iFAQf,aAAa;cAZzB,QAAQ;eAAC;gBACR,OAAO,EAAE;oBACP,aAAa;oBACb,yBAAyB;oBACzB,wBAAwB;iBACzB;gBACD,OAAO,EAAE;oBACP,aAAa;oBACb,yBAAyB;oBACzB,wBAAwB;iBACzB;aACF;;wFACY,aAAa,cAVtB,aAAa;QACb,yBAAyB;QACzB,wBAAwB,aAGxB,aAAa;QACb,yBAAyB;QACzB,wBAAwB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public API Surface of @memberjunction/ng-tasks
|
|
3
|
+
*/
|
|
4
|
+
export * from './lib/ng-tasks.module';
|
|
5
|
+
export * from './lib/components/task.component';
|
|
6
|
+
export * from './lib/components/simple-task-viewer.component';
|
|
7
|
+
export * from './lib/components/gantt-task-viewer.component';
|
|
8
|
+
export * from './lib/models/task-view.models';
|
|
9
|
+
//# sourceMappingURL=public-api.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public-api.d.ts","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,cAAc,uBAAuB,CAAC;AAGtC,cAAc,iCAAiC,CAAC;AAChD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,8CAA8C,CAAC;AAG7D,cAAc,+BAA+B,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public API Surface of @memberjunction/ng-tasks
|
|
3
|
+
*/
|
|
4
|
+
// Module
|
|
5
|
+
export * from './lib/ng-tasks.module';
|
|
6
|
+
// Components
|
|
7
|
+
export * from './lib/components/task.component';
|
|
8
|
+
export * from './lib/components/simple-task-viewer.component';
|
|
9
|
+
export * from './lib/components/gantt-task-viewer.component';
|
|
10
|
+
// Models
|
|
11
|
+
export * from './lib/models/task-view.models';
|
|
12
|
+
//# sourceMappingURL=public-api.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,SAAS;AACT,cAAc,uBAAuB,CAAC;AAEtC,aAAa;AACb,cAAc,iCAAiC,CAAC;AAChD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,8CAA8C,CAAC;AAE7D,SAAS;AACT,cAAc,+BAA+B,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@memberjunction/ng-tasks",
|
|
3
|
+
"version": "2.105.0",
|
|
4
|
+
"description": "MemberJunction: Angular components for task visualization and management with Gantt chart support",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"build": "ngc",
|
|
9
|
+
"watch": "ngc --watch"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@angular/animations": "^18.0.0",
|
|
13
|
+
"@angular/common": "^18.0.0",
|
|
14
|
+
"@angular/core": "^18.0.0",
|
|
15
|
+
"@angular/platform-browser": "^18.0.0",
|
|
16
|
+
"@memberjunction/core": "2.100.3",
|
|
17
|
+
"@memberjunction/core-entities": "2.105.0",
|
|
18
|
+
"dhtmlx-gantt": "^8.0.10",
|
|
19
|
+
"rxjs": "^7.8.1"
|
|
20
|
+
},
|
|
21
|
+
"peerDependencies": {
|
|
22
|
+
"@angular/common": "^18.0.0",
|
|
23
|
+
"@angular/core": "^18.0.0"
|
|
24
|
+
},
|
|
25
|
+
"author": "MemberJunction",
|
|
26
|
+
"license": "MIT",
|
|
27
|
+
"repository": {
|
|
28
|
+
"type": "git",
|
|
29
|
+
"url": "https://github.com/MemberJunction/MJ.git"
|
|
30
|
+
}
|
|
31
|
+
}
|
package/src/index.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './public-api';
|