@object-ui/plugin-gantt 4.0.7 → 4.0.9

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/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # @object-ui/plugin-gantt
2
2
 
3
+ ## 4.0.9
4
+
5
+ ### Patch Changes
6
+
7
+ - @object-ui/types@4.0.9
8
+ - @object-ui/core@4.0.9
9
+ - @object-ui/react@4.0.9
10
+ - @object-ui/components@4.0.9
11
+ - @object-ui/fields@4.0.9
12
+ - @object-ui/plugin-detail@4.0.9
13
+
14
+ ## 4.0.8
15
+
16
+ ### Patch Changes
17
+
18
+ - @object-ui/components@4.0.8
19
+ - @object-ui/fields@4.0.8
20
+ - @object-ui/react@4.0.8
21
+ - @object-ui/plugin-detail@4.0.8
22
+ - @object-ui/types@4.0.8
23
+ - @object-ui/core@4.0.8
24
+
3
25
  ## 4.0.7
4
26
 
5
27
  ### Patch Changes
package/README.md CHANGED
@@ -5,12 +5,74 @@ Gantt chart plugin for Object UI - Visualize project timelines and task dependen
5
5
  ## Features
6
6
 
7
7
  - **Gantt Charts** - Interactive Gantt chart visualization
8
+ - **Full CRUD on the timeline** - Create via toolbar quick-create dialog, edit
9
+ inline or via drag, delete via row kebab → confirmation dialog, view detail
10
+ via click → navigation overlay
11
+ - **Drag-and-drop rescheduling** - Drag a bar to move it; drag either edge to resize
12
+ start/end (snaps to whole days, persists via `dataSource.update`)
8
13
  - **Task Dependencies** - Link tasks with dependencies
9
14
  - **Timeline View** - Visualize project schedules
10
15
  - **Task Management** - Create, edit, and track tasks
11
16
  - **Responsive** - Scrollable timeline for large projects
12
17
  - **Customizable** - Tailwind CSS styling support
13
18
 
19
+ ### Create / Edit / Delete / View
20
+
21
+ When used through `ObjectGantt` (the wiring the framework uses for the
22
+ `gantt` view type) the full CRUD lifecycle is wired automatically:
23
+
24
+ - **Create** — click the toolbar "+ New Task" button. A small dialog opens
25
+ pre-filled with start/end (today → +7 days). On submit the component calls
26
+ `dataSource.create(objectName, { [titleField], [startDateField],
27
+ [endDateField], …required fields })` and optimistically inserts the new
28
+ record into the chart.
29
+ - **Edit** — drag the bar (move), drag an edge (resize), or hover the row
30
+ and pick **Edit inline** from the kebab menu to rename / change dates
31
+ inline. All paths funnel through `dataSource.update`.
32
+ - **Delete** — hover a row, open the kebab menu, choose **Delete**. A
33
+ shadcn `<AlertDialog>` asks for confirmation; on confirm `dataSource.delete`
34
+ removes the record (optimistic local removal, reverts on failure).
35
+ - **View / Edit / Delete in a side drawer** — click anywhere on a row
36
+ (or pick **View details** in the kebab) to open a right-side drawer
37
+ containing the standard `<DetailView>` from `@object-ui/plugin-detail`.
38
+ The drawer ships the same record-header chrome used everywhere else
39
+ (badges, summary chips, **Edit** + **Inline edit** buttons, and a
40
+ **…** more-actions menu with **Delete**). Edits via inline-edit save
41
+ through `dataSource.update` and merge into the local timeline state;
42
+ delete confirms via the platform standard dialog and removes the row
43
+ on success. Fields are auto-derived from the record (object schema is
44
+ fetched by `DetailView` itself when `dataSource.getObjectSchema` is
45
+ available).
46
+
47
+ Override by setting `navigation` on the schema, e.g.
48
+ `{ mode: 'page', basePath: '/console/apps/.../campaign' }` to route
49
+ to the standalone detail page instead.
50
+
51
+
52
+ ### Drag-and-drop rescheduling
53
+
54
+ When the renderer is used through `ObjectGantt` (the standard wiring used by
55
+ the framework's `gantt` view type) drag is enabled automatically: each bar
56
+ shows a grab cursor; the body drags the entire task, and the two thin edge
57
+ zones (≈6px) resize start or end. Pointer motion snaps to whole days using
58
+ the current column width. On release `ObjectGantt` issues an optimistic local
59
+ patch and a `dataSource.update(objectName, recordId, { [startDateField]: …,
60
+ [endDateField]: … })`. If the request fails the local state is reverted.
61
+
62
+ When you embed the lower-level `<GanttView>` directly, pass `onTaskUpdate`
63
+ to opt in:
64
+
65
+ ```tsx
66
+ <GanttView
67
+ tasks={tasks}
68
+ onTaskUpdate={(task, { start, end }) => {
69
+ // start/end are JS Date objects already snapped to whole days,
70
+ // and the resize-left/right cases clamp so end - start >= 1 day.
71
+ save(task.id, { start, end });
72
+ }}
73
+ />
74
+ ```
75
+
14
76
  ## Installation
15
77
 
16
78
  ```bash