Repository navigation
feat(timeline): add runnable basic timeline example (#21039) - #21044
Conversation
neo-fable-mnemosyne
left a comment
There was a problem hiding this comment.
PR Micro-Review
Opening: Thank you for this one too. The example does the one thing the issue cared most about: it mounts the timeline column by its module in an ordinary grid, with the axis and the event store as plain configs, and it reaches for neither the scheduler nor the Gantt chart. The pointers into Neo are in my review of your Gantt page; I filed this issue as well.
Class: contained: a new example of four files, its entry in the examples index and the generated SEO lines; the index spec follows the count. No engine code changes.
Verdict: Request Changes
Glance: The claim is a runnable example of Neo.timeline.Column in a plain grid, with a control that moves a bar through its record. I opened it in development mode at 6f040475bd (19:37Z): seven rows, all twelve interval titles drawn. Pressing the button moved "Sprint Planning" from 670 to 730 px, one hour at one pixel per minute, without a reload, and no other bar moved. Nothing is imported from src/scheduler or src/gantt, the index entry has the shape of its two siblings, and CI is green with the count at 76. What I looked for was whether the button does what its label says once a row is selected. It does not (finding 1). The screenshots the issue asked for are no longer needed: the observation is in this review.
Findings:
-
1 · The button moves the selected row's interval, or its label and comment stop saying so. With the third row selected, pressing it moved the first row's "Sprint Planning" again (730 to 790 px) and left "Timeline Testing" where it was.
grid.selectionModel?.selectedRecordIdsreads nothing: a grid's selection model lives on its view, and the row model keeps the selected ids inselectedRows, so the read isgrid.view.selectionModel?.selectedRows?.[0]. The nameselectedRecordIdsoccurs nowhere undersrcondev9575d2689b. Either take that read and try it with a row selected, or drop the selection and name the button for what it does ("Shift the first interval by one hour"). An example is what the next person copies, so it should hold no read that silently returns nothing. -
2 ·
onShiftIntervalgets a@summaryline, as the methods of the two sibling examples have:/** @summary Moves one interval an hour later through its record. */. -
Origin Session ID: 0d801763-b80f-4990-a86a-ee52142a3225
-
PR body attribution: the contributor template's own AI line; no harness-appended session backlink.
🪢 Mnemosyne (Claude Fable 5.2, Claude Code). Eligibility rules: pr-review-guide §6.4.
[review-budget-managed]
- outcome: within-budget
- ordinary-limit: 1
- activation-issue: 15257
- activation-pr: 15307
- activated-at: 2026-07-16T20:54:31Z
d432e70 to
f94ce61
Compare
neo-fable-mnemosyne
left a comment
There was a problem hiding this comment.
PR Review — Round 2 (disposition only)
Status: Comment
Opening: Thank you for the quick turn. This dispositions the two findings of my first review at f94ce61fd3: the summary line is in, and the button still moves the first row when another row is selected. That second one is on me, not on you: you took the read I gave you, and my read was incomplete. One line is left, and it is below, tested.
⚓ Anchor
- PR / Target Issue: #21044 / #21039
- Round-1 Review ID: #21044 (review) · Author Response: none; the repair is commit
f94ce61fd3 - Head under review:
f94ce61fd3 - Origin Session ID: 02ab4651-2282-4faf-bc5c-856a5ee5ab05
📋 Disposition
| # | Required Action (verbatim from Round 1) | Disposition | Evidence |
|---|---|---|---|
| RA-1 | 1 · The button moves the selected row's interval, or its label and comment stop saying so. With the third row selected, pressing it moved the first row's "Sprint Planning" again (730 to 790 px) and left "Timeline Testing" where it was. grid.selectionModel?.selectedRecordIds reads nothing: a grid's selection model lives on its view, and the row model keeps the selected ids in selectedRows, so the read is grid.view.selectionModel?.selectedRows?.[0]. The name selectedRecordIds occurs nowhere under src on dev 9575d2689b. Either take that read and try it with a row selected, or drop the selection and name the button for what it does ("Shift the first interval by one hour"). An example is what the next person copies, so it should hold no read that silently returns nothing. |
STILL_OPEN | Development mode at f94ce61fd3, 05:27Z: with the third row selected the button moved the first row's "Sprint Planning" from 661 to 721 px and left "Timeline Testing" in place. Read inside the app worker, selectedRows holds ["neo-record-3"]: a grid issues its own row ids by default (useInternalId: true), so the value is never equal to a resourceId and line 103 falls back to the first event. The selection model resolves such an id to its record: getRowRecord("neo-record-3").id is "r-3". The replacement for line 101 is under this table. |
| RA-2 | 2 · onShiftInterval gets a @summary line, as the methods of the two sibling examples have: /** @summary Moves one interval an hour later through its record. */. |
ADDRESSED | examples/timeline/basic/Viewport.mjs:96 at f94ce61fd3. |
The one line for RA-1, in place of examples/timeline/basic/Viewport.mjs:101:
selection = grid.view.selectionModel?.getRowRecord(grid.view.selectionModel.selectedRows[0])?.id,With that line on top of f94ce61fd3 I measured (05:29Z, one pixel per minute): third row selected, "Timeline Testing" 781 to 841 px; fifth row selected, "Integration Tests" 721 to 781 px, and 781 to 841 px on a second press; nothing selected, "Sprint Planning" 661 to 721 px. No other bar moved in any of the four presses.
🔚 Verdict
COMMENT. RA-1 stays open for that one line; nothing else is. CI is green at this head, and the rebase onto dev carried the catalog count to 77 correctly. When the line is in I approve at that head.
🖖 Mnemosyne (Claude Fable 5.2, Claude Code). Memory Core session 02ab4651-2282-4faf-bc5c-856a5ee5ab05.
|
Thanks for the review and the pointer on grid selection! Addressed both findings in commit
Rebased on current |
|
Your comment and my second review crossed by four minutes, so in case you have not seen it yet: at The one tested line is in that review. When it is in, I approve at that head. 🪢 Mnemosyne (Claude Fable 5.2, Claude Code) |
126c3b1 to
702b462
Compare
|
Thanks for catching the internal row id nuance and sharing the tested fix! Updated the selection line in selection = grid.view.selectionModel?.getRowRecord(grid.view.selectionModel.selectedRows[0])?.id,in commit |
|
A note for the timeline example, from #21102's AC-5: #21132 adds If this PR is still open when #21132 merges, please switch to that read here. If this PR lands first, a follow-up makes the switch; #21132's author offered to do it. 🖖 Grace (Claude Opus 5.5, Claude Code) · session 9d2c0742-5c77-402e-82c9-3294b03a4062 |
neo-fable-mnemosyne
left a comment
There was a problem hiding this comment.
PR Review — Round 2 (disposition only)
Status: Approved
Opening: This dispositions the two findings of my first review at 702b462449: both are in, and the button now moves the bar of the row that is selected. Thank you for staying with it through a hint of mine that was wrong.
⚓ Anchor
- PR / Target Issue: #21044 / #21039
- Round-1 Review ID: #21044 (review) · Author Response: #21044 (comment)
- Head under review:
702b462449 - Origin Session ID: 2aca1b1d-2c66-48b0-91b9-915e506da9a7
📋 Disposition
| # | Required Action (verbatim from Round 1) | Disposition | Evidence |
|---|---|---|---|
| RA-1 | 1 · The button moves the selected row's interval, or its label and comment stop saying so. With the third row selected, pressing it moved the first row's "Sprint Planning" again (730 to 790 px) and left "Timeline Testing" where it was. grid.selectionModel?.selectedRecordIds reads nothing: a grid's selection model lives on its view, and the row model keeps the selected ids in selectedRows, so the read is grid.view.selectionModel?.selectedRows?.[0]. The name selectedRecordIds occurs nowhere under src on dev 9575d2689b. Either take that read and try it with a row selected, or drop the selection and name the button for what it does ("Shift the first interval by one hour"). An example is what the next person copies, so it should hold no read that silently returns nothing. |
ADDRESSED | examples/timeline/basic/Viewport.mjs:101 at 702b462449 resolves the row id to its record. Development mode at that head, 13:33Z, one pixel per minute: third row selected, "Timeline Testing" 781 to 841 px; fifth row selected, "Integration Tests" 721 to 781 px, and 781 to 841 px on a second press; nothing selected, "Sprint Planning" 661 to 721 px. |
| RA-2 | 2 · onShiftInterval gets a @summary line, as the methods of the two sibling examples have: /** @summary Moves one interval an hour later through its record. */. |
ADDRESSED | examples/timeline/basic/Viewport.mjs:96, unchanged since f94ce61fd3. |
🔚 Verdict
Approve. No required actions — eligible for human merge.
CI is green at this head. Three e2e shards had failed on tests that touch no file of this pull request (portal/NewsTabOverflow, grid/StoreUpdateRowsNL, grid/IssuesShowcase); a re-run of the failed jobs passed, and the second of them is tracked in #21135.
One note that asks nothing of this pull request: #21132 adds grid.view.selectedRecords, and the comment above this review says who switches line 101 to it and when.
🖖 Mnemosyne (Claude Fable 5.2, Claude Code). Memory Core session 2aca1b1d-2c66-48b0-91b9-915e506da9a7.
|
Merged. Standing: Contributor (3 merged). 2 more reach Returning Contributor. Your record and badge: https://neomjs.com/badges/mrdeyroy-169705535/ Next, if you want one: #19145 and #20696 are open and unclaimed; a comment on either claims it. The full list has more if both are taken by then. |
Resolves #21039
What kind of change does this PR introduce? (check at least one)
Does this PR introduce a breaking change? (check one)
The PR fulfills this requirement:
devbranch, not themainbranchIf adding a new feature, the PR's description includes:
Adds
examples/timeline/basic: a standalone, runnable example demonstratingNeo.timeline.Columnmounted in a plainNeo.grid.Containerwith a 24-hourNeo.timeline.TimeAxisand an inlineNeo.timeline.store.Events.Key details:
app.mjs,index.html,neo-config.json,Viewport.mjs) importing only fromsrc/timeline,src/grid,src/button, andsrc/container. Imports nothing fromsrc/schedulerorsrc/gantt.record.set()) demonstrating live reactive bar repositioning on event store changes without reloading.timeline-basictoapps/portal/resources/data/examples.jsonand updated SEO metadata.test/playwright/unit/apps/portal/view/examples/TabContainerController.spec.mjscatalog count (75 -> 76) and family store order.check-guard-ci-parity,check-examples-body-only,check-relative-links,check-package-contents,check-class-module-scope,check-ticket-archaeology).This issue/PR was prepared with AI assistance.