@memberjunction/ng-tasks 4.0.0 → 4.2.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 -6
- package/CHANGELOG.md +21 -0
- package/README.md +85 -198
- package/package.json +5 -5
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
# @memberjunction/ng-tasks
|
|
2
2
|
|
|
3
|
+
## 4.2.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- @memberjunction/ai-engine-base@4.2.0
|
|
8
|
+
- @memberjunction/ai-core-plus@4.2.0
|
|
9
|
+
- @memberjunction/core@4.2.0
|
|
10
|
+
- @memberjunction/core-entities@4.2.0
|
|
11
|
+
|
|
12
|
+
## 4.1.0
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- Updated dependencies [77839a9]
|
|
17
|
+
- Updated dependencies [2ea241f]
|
|
18
|
+
- Updated dependencies [5af036f]
|
|
19
|
+
- @memberjunction/core@4.1.0
|
|
20
|
+
- @memberjunction/core-entities@4.1.0
|
|
21
|
+
- @memberjunction/ai-engine-base@4.1.0
|
|
22
|
+
- @memberjunction/ai-core-plus@4.1.0
|
|
23
|
+
|
|
3
24
|
## 4.0.0
|
|
4
25
|
|
|
5
26
|
### Major Changes
|
package/README.md
CHANGED
|
@@ -1,233 +1,120 @@
|
|
|
1
1
|
# @memberjunction/ng-tasks
|
|
2
2
|
|
|
3
|
-
Angular components for task visualization and management with Gantt chart support.
|
|
4
|
-
|
|
5
|
-
## Features
|
|
6
|
-
|
|
7
|
-
- 📋 **Simple List View** - Clean hierarchical task list with indentation for subtasks
|
|
8
|
-
- 📊 **Gantt Chart View** - Timeline visualization using Frappe Gantt
|
|
9
|
-
- 🔄 **View Toggle** - Easy switching between list and Gantt views
|
|
10
|
-
- 🎨 **Clean Design** - Modern, minimal UI that matches MemberJunction aesthetics
|
|
11
|
-
- 📦 **Standalone Components** - Can be used independently or together
|
|
12
|
-
- 🔗 **Dependency Support** - Visualizes task dependencies and relationships
|
|
3
|
+
Angular components for task visualization and management with Gantt chart support. Provides a simple hierarchical list view and a Gantt timeline view with dependency arrows, both working with MemberJunction `TaskEntity` data.
|
|
13
4
|
|
|
14
5
|
## Installation
|
|
15
6
|
|
|
16
|
-
This package is part of the MemberJunction monorepo. Install from the repository root:
|
|
17
|
-
|
|
18
7
|
```bash
|
|
19
|
-
npm install
|
|
8
|
+
npm install @memberjunction/ng-tasks
|
|
20
9
|
```
|
|
21
10
|
|
|
22
|
-
##
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
onViewModeChange(mode: TaskViewMode) {
|
|
51
|
-
console.log('View mode changed to:', mode);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
11
|
+
## Overview
|
|
12
|
+
|
|
13
|
+
The tasks package provides two interchangeable visualization modes for task data: a clean hierarchical list and a Gantt chart timeline. A wrapper component provides a toggle to switch between views. Tasks support dependencies via `DependsOnTaskID`, displayed as indentation in list view and dependency arrows in Gantt view.
|
|
14
|
+
|
|
15
|
+
```mermaid
|
|
16
|
+
flowchart TD
|
|
17
|
+
subgraph Container["TaskComponent"]
|
|
18
|
+
A["View Toggle"]
|
|
19
|
+
A -->|simple| B["SimpleTaskViewerComponent"]
|
|
20
|
+
A -->|gantt| C["GanttTaskViewerComponent"]
|
|
21
|
+
end
|
|
22
|
+
subgraph List["Simple View"]
|
|
23
|
+
D["Hierarchical list with indentation"]
|
|
24
|
+
E["Status icons and color coding"]
|
|
25
|
+
F["Expand/collapse subtasks"]
|
|
26
|
+
end
|
|
27
|
+
subgraph Gantt["Gantt View"]
|
|
28
|
+
G["Timeline bars"]
|
|
29
|
+
H["Dependency arrows"]
|
|
30
|
+
I["Progress indicators"]
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
B --> List
|
|
34
|
+
C --> Gantt
|
|
35
|
+
|
|
36
|
+
style Container fill:#2d6a9f,stroke:#1a4971,color:#fff
|
|
37
|
+
style List fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
38
|
+
style Gantt fill:#7c5295,stroke:#563a6b,color:#fff
|
|
54
39
|
```
|
|
55
40
|
|
|
56
|
-
|
|
57
|
-
- `tasks: TaskEntity[]` - Array of tasks to display
|
|
58
|
-
- `title?: string` - Optional header title
|
|
59
|
-
- `description?: string` - Optional header description
|
|
60
|
-
- `showHeader: boolean` - Whether to show the header (default: true)
|
|
61
|
-
- `viewMode: TaskViewMode` - Initial view mode: 'simple' or 'gantt' (default: 'simple')
|
|
62
|
-
|
|
63
|
-
**Outputs:**
|
|
64
|
-
- `taskClicked: EventEmitter<TaskEntity>` - Emitted when a task is clicked
|
|
65
|
-
- `viewModeChanged: EventEmitter<TaskViewMode>` - Emitted when view mode changes
|
|
41
|
+
## Usage
|
|
66
42
|
|
|
67
|
-
###
|
|
68
|
-
|
|
69
|
-
Displays tasks in a clean, hierarchical list format.
|
|
43
|
+
### Standalone Component Import
|
|
70
44
|
|
|
71
45
|
```typescript
|
|
72
|
-
import {
|
|
73
|
-
|
|
74
|
-
@Component({
|
|
75
|
-
template: `
|
|
76
|
-
<mj-simple-task-viewer
|
|
77
|
-
[tasks]="myTasks"
|
|
78
|
-
(taskClicked)="onTaskClick($event)">
|
|
79
|
-
</mj-simple-task-viewer>
|
|
80
|
-
`
|
|
81
|
-
})
|
|
82
|
-
export class MyComponent {
|
|
83
|
-
myTasks: TaskEntity[] = [...];
|
|
84
|
-
}
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
**Features:**
|
|
88
|
-
- Hierarchical display with indentation
|
|
89
|
-
- Expand/collapse for tasks with subtasks
|
|
90
|
-
- Status icons with color coding
|
|
91
|
-
- Due dates and assignee information
|
|
92
|
-
- Click to interact with tasks
|
|
93
|
-
|
|
94
|
-
### GanttTaskViewerComponent
|
|
95
|
-
|
|
96
|
-
Displays tasks in a Gantt chart timeline using Frappe Gantt.
|
|
97
|
-
|
|
98
|
-
```typescript
|
|
99
|
-
import { GanttTaskViewerComponent } from '@memberjunction/ng-tasks';
|
|
46
|
+
import { TaskComponent } from '@memberjunction/ng-tasks';
|
|
100
47
|
|
|
101
48
|
@Component({
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
[tasks]="myTasks"
|
|
105
|
-
(taskClicked)="onTaskClick($event)">
|
|
106
|
-
</mj-gantt-task-viewer>
|
|
107
|
-
`
|
|
49
|
+
imports: [TaskComponent],
|
|
50
|
+
// ...
|
|
108
51
|
})
|
|
109
|
-
export class
|
|
110
|
-
myTasks: TaskEntity[] = [...];
|
|
111
|
-
}
|
|
52
|
+
export class YourComponent {}
|
|
112
53
|
```
|
|
113
54
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
```typescript
|
|
127
|
-
interface TaskEntity {
|
|
128
|
-
ID: string;
|
|
129
|
-
Title: string;
|
|
130
|
-
Description?: string;
|
|
131
|
-
Status: 'Pending' | 'In Progress' | 'Complete';
|
|
132
|
-
StartDate?: Date;
|
|
133
|
-
DueDate?: Date;
|
|
134
|
-
DependsOnTaskID?: string; // For task dependencies
|
|
135
|
-
AssignedTo?: string;
|
|
136
|
-
// ... other MJ entity fields
|
|
137
|
-
}
|
|
55
|
+
### Basic Usage
|
|
56
|
+
|
|
57
|
+
```html
|
|
58
|
+
<mj-task
|
|
59
|
+
[tasks]="projectTasks"
|
|
60
|
+
[title]="'Project Tasks'"
|
|
61
|
+
[description]="'Active tasks for Q1'"
|
|
62
|
+
[viewMode]="'simple'"
|
|
63
|
+
(taskClicked)="onTaskClick($event)"
|
|
64
|
+
(viewModeChanged)="onViewModeChange($event)">
|
|
65
|
+
</mj-task>
|
|
138
66
|
```
|
|
139
67
|
|
|
140
|
-
|
|
68
|
+
### Individual Sub-Components
|
|
141
69
|
|
|
142
|
-
|
|
70
|
+
```html
|
|
71
|
+
<!-- List view only -->
|
|
72
|
+
<mj-simple-task-viewer
|
|
73
|
+
[tasks]="tasks"
|
|
74
|
+
(taskClicked)="onTaskClick($event)">
|
|
75
|
+
</mj-simple-task-viewer>
|
|
143
76
|
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
Status: 'Complete',
|
|
150
|
-
StartDate: new Date('2025-01-01'),
|
|
151
|
-
DueDate: new Date('2025-01-05')
|
|
152
|
-
},
|
|
153
|
-
{
|
|
154
|
-
ID: 'task-2',
|
|
155
|
-
Title: 'Implement Backend API',
|
|
156
|
-
Status: 'In Progress',
|
|
157
|
-
StartDate: new Date('2025-01-06'),
|
|
158
|
-
DueDate: new Date('2025-01-15'),
|
|
159
|
-
DependsOnTaskID: 'task-1' // Depends on task-1
|
|
160
|
-
},
|
|
161
|
-
{
|
|
162
|
-
ID: 'task-3',
|
|
163
|
-
Title: 'Build Frontend UI',
|
|
164
|
-
Status: 'Pending',
|
|
165
|
-
StartDate: new Date('2025-01-16'),
|
|
166
|
-
DueDate: new Date('2025-01-25'),
|
|
167
|
-
DependsOnTaskID: 'task-2' // Depends on task-2
|
|
168
|
-
}
|
|
169
|
-
];
|
|
77
|
+
<!-- Gantt view only -->
|
|
78
|
+
<mj-gantt-task-viewer
|
|
79
|
+
[tasks]="tasks"
|
|
80
|
+
(taskClicked)="onTaskClick($event)">
|
|
81
|
+
</mj-gantt-task-viewer>
|
|
170
82
|
```
|
|
171
83
|
|
|
172
|
-
|
|
173
|
-
In **Gantt View**, dependency arrows connect the tasks.
|
|
84
|
+
## Components
|
|
174
85
|
|
|
175
|
-
|
|
86
|
+
| Component | Selector | Purpose |
|
|
87
|
+
|-----------|----------|---------|
|
|
88
|
+
| `TaskComponent` | `mj-task` | Composite wrapper with view toggle |
|
|
89
|
+
| `SimpleTaskViewerComponent` | `mj-simple-task-viewer` | Hierarchical list view |
|
|
90
|
+
| `GanttTaskViewerComponent` | `mj-gantt-task-viewer` | Gantt chart timeline |
|
|
176
91
|
|
|
177
|
-
|
|
92
|
+
## TaskComponent API
|
|
178
93
|
|
|
179
|
-
|
|
180
|
-
- **Typography:** System fonts with consistent sizing
|
|
181
|
-
- **Spacing:** Comfortable padding and margins
|
|
182
|
-
- **Icons:** Font Awesome icons throughout
|
|
94
|
+
### Inputs
|
|
183
95
|
|
|
184
|
-
|
|
96
|
+
| Property | Type | Default | Description |
|
|
97
|
+
|----------|------|---------|-------------|
|
|
98
|
+
| `tasks` | `TaskEntity[]` | `[]` | Array of task entities |
|
|
99
|
+
| `title` | `string` | `undefined` | Optional header title |
|
|
100
|
+
| `description` | `string` | `undefined` | Optional header description |
|
|
101
|
+
| `showHeader` | `boolean` | `true` | Show the header area |
|
|
102
|
+
| `viewMode` | `TaskViewMode` | `'simple'` | Initial view mode: `'simple'` or `'gantt'` |
|
|
185
103
|
|
|
186
|
-
|
|
104
|
+
### Outputs
|
|
187
105
|
|
|
188
|
-
|
|
106
|
+
| Event | Type | Description |
|
|
107
|
+
|-------|------|-------------|
|
|
108
|
+
| `taskClicked` | `EventEmitter<TaskEntity>` | Task was clicked |
|
|
109
|
+
| `viewModeChanged` | `EventEmitter<TaskViewMode>` | View mode toggled |
|
|
189
110
|
|
|
190
|
-
|
|
191
|
-
import { TaskComponent } from '@memberjunction/ng-tasks';
|
|
111
|
+
## Exported Types
|
|
192
112
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
imports: [TaskComponent],
|
|
196
|
-
template: `
|
|
197
|
-
<mj-task
|
|
198
|
-
[tasks]="allTasks"
|
|
199
|
-
[title]="'All Tasks'"
|
|
200
|
-
[viewMode]="'simple'"
|
|
201
|
-
(taskClicked)="navigateToTask($event)">
|
|
202
|
-
</mj-task>
|
|
203
|
-
`
|
|
204
|
-
})
|
|
205
|
-
export class TasksFullViewComponent {
|
|
206
|
-
// ... component implementation
|
|
207
|
-
}
|
|
208
|
-
```
|
|
209
|
-
|
|
210
|
-
## Browser Support
|
|
211
|
-
|
|
212
|
-
- Chrome/Edge (latest)
|
|
213
|
-
- Firefox (latest)
|
|
214
|
-
- Safari (latest)
|
|
113
|
+
- `TaskViewMode` -- `'simple' | 'gantt'`
|
|
114
|
+
- `GanttTask` -- Interface for Gantt chart task data
|
|
215
115
|
|
|
216
116
|
## Dependencies
|
|
217
117
|
|
|
218
|
-
-
|
|
219
|
-
-
|
|
220
|
-
-
|
|
221
|
-
- **@memberjunction/core-entities:** ^2.104.0
|
|
222
|
-
|
|
223
|
-
## License
|
|
224
|
-
|
|
225
|
-
MIT
|
|
226
|
-
|
|
227
|
-
## Contributing
|
|
228
|
-
|
|
229
|
-
This package is part of the MemberJunction open-source project. Contributions are welcome!
|
|
230
|
-
|
|
231
|
-
## Support
|
|
232
|
-
|
|
233
|
-
For issues or questions, please file an issue on the [MemberJunction GitHub repository](https://github.com/MemberJunction/MJ).
|
|
118
|
+
- [@memberjunction/core](../../MJCore/README.md) -- Core framework
|
|
119
|
+
- [@memberjunction/core-entities](../../MJCoreEntities/README.md) -- TaskEntity
|
|
120
|
+
- `frappe-gantt` -- Gantt chart rendering (peer dependency)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/ng-tasks",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.2.0",
|
|
4
4
|
"description": "MemberJunction: Angular components for task visualization and management with Gantt chart support",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
"@angular/common": "21.1.3",
|
|
14
14
|
"@angular/core": "21.1.3",
|
|
15
15
|
"@angular/platform-browser": "21.1.3",
|
|
16
|
-
"@memberjunction/core": "4.
|
|
17
|
-
"@memberjunction/core-entities": "4.
|
|
18
|
-
"@memberjunction/ai-core-plus": "4.
|
|
19
|
-
"@memberjunction/ai-engine-base": "4.
|
|
16
|
+
"@memberjunction/core": "4.2.0",
|
|
17
|
+
"@memberjunction/core-entities": "4.2.0",
|
|
18
|
+
"@memberjunction/ai-core-plus": "4.2.0",
|
|
19
|
+
"@memberjunction/ai-engine-base": "4.2.0",
|
|
20
20
|
"dhtmlx-gantt": "^9.1.1",
|
|
21
21
|
"rxjs": "^7.8.2"
|
|
22
22
|
},
|