Skip to content

Represent chapters/excursions in editor comments list#2439

Merged
tf merged 4 commits into
codevise:masterfrom
tf:located-comments
Jun 24, 2026
Merged

Represent chapters/excursions in editor comments list#2439
tf merged 4 commits into
codevise:masterfrom
tf:located-comments

Conversation

@tf

@tf tf commented Jun 24, 2026

Copy link
Copy Markdown
Member

REDMINE-21261

tf added 4 commits June 22, 2026 13:11
Nests an ordered contentElements array (including backdrop elements)
into each section of the entry structure. Kept as a separate hook from
useEntryStructure so the more frequently used variant does not
re-derive when content elements change. Both share a buildEntryStructure
helper so the nested shape stays consistent.
Replace the positional (subject, {resolved}) signature with one
{subjectType, subjectId, subjectRange, resolution} options object.
Omitting the subject fields returns all threads, and resolution
('all' | 'resolved' | 'unresolved', default 'all') filters by resolved
state — so threads can be filtered by resolution alone. Subject-only
call sites keep working unchanged.
Joins comment threads from the review state with the entry structure,
grouping them by chapter, section and content element (main storyline
first, excursions last). Returns the located chapters, a flat list of
threads in document order for the upcoming preview navigator, and the
threads whose subject is no longer part of the entry.
Render the comments sidebar from the entry structure instead of a
Backbone collection of items: EntryCommentsView now provides entry
state (seeded from the entry and kept live via watchCollections) and
builds its groups from useLocatedCommentThreads.

Each chapter that has threads gets a heading using the same number and
title as the chapter outline, and excursion chapters are grouped below
the main chapters. Selection, highlighting and transient-thread
behavior is preserved.
@tf tf added this to the v17.2 milestone Jun 24, 2026
@tf tf merged commit 0372da6 into codevise:master Jun 24, 2026
18 checks passed
@tf tf deleted the located-comments branch June 24, 2026 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant