Skip to content

Show version history in the channel publish side panel#5721

Merged
AlexVelezLl merged 5 commits intolearningequality:unstablefrom
AllanOXDi:Ch-version
Mar 6, 2026
Merged

Show version history in the channel publish side panel#5721
AlexVelezLl merged 5 commits intolearningequality:unstablefrom
AllanOXDi:Ch-version

Conversation

@AllanOXDi
Copy link
Member

@AllanOXDi AllanOXDi commented Feb 27, 2026

Summary

This PR adds a new hannelVersionHistory component to abstract all the channel version history displaying logic.
It uses the ChannelVersion resource to fetch channel versions in the frontend and rendered it on the PublishSidePanel component.
closes #5463

Screen.Recording.2026-03-05.at.23.17.55.mov

References

#5463

Reviewer guidance

Edit a channel and publish it with a few versions
Open a channel in the publish side panel
Click "See all versions" to expand the version history
Verify that versions load and display correctly with their descriptions

AI usage

I used Codex for Code review and refinement,styling improvements

@AllanOXDi AllanOXDi requested a review from rtibblesbot March 4, 2026 20:12
Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New feature adds channel version history to the publish side panel via a ChannelVersionHistory component and useChannelVersionHistory composable with paginated fetching.

CI passing. No screenshots included — this PR adds a new UI component.

  • suggestion: Hardcoded colors in ChannelVersionHistory.vue — see inline comment
  • suggestion: Missing dedicated tests for ChannelVersionHistory and useChannelVersionHistory — see inline comment
  • suggestion: PR description is empty (template placeholders only) and no screenshots are included for a UI change
  • praise: Clean composable design — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Reviewed the pull request diff checking for:

  • Correctness: bugs, edge cases, undocumented behavior, resource leaks, hardcoded values
  • Design: unnecessary complexity, naming, readability, comment accuracy, redundant state
  • Architecture: duplicated concerns, minimal interfaces, composition over inheritance
  • Testing: behavior-based assertions, mocks only at hard boundaries, accurate coverage
  • Completeness: missing dependencies, unupdated usages, i18n, accessibility, security
  • Principles: DRY (same reason to change), SRP, Rule of Three (no premature abstraction)
  • Checked CI status and linked issue acceptance criteria
  • For UI changes: inspected screenshots for layout, visual completeness, and consistency

* fetchMore: () => Promise<void>,
* }}
*/
export function useChannelVersionHistory() {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

praise: Clean separation of concerns. The composable encapsulates pagination state, loading states, and error handling well. The reset() function and guard clauses in fetchMore() are good defensive design.

</div>
<div class="description-body">
{{ version.version_notes }}
</div>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: version.version_notes is rendered safely via text interpolation ({{ }}), which is good. Just noting that if notes can be long, you may want to consider truncation or overflow-wrap: break-word on .description-body to handle edge cases with very long unbroken strings.

@AllanOXDi AllanOXDi closed this Mar 5, 2026
@AllanOXDi AllanOXDi reopened this Mar 5, 2026
Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Channel version history feature with clean composable + component separation, comprehensive tests, and proper i18n. CI passing.

2 prior finding(s) resolved.

  • suggestion: Hardcoded English aria-label — see inline comment
  • suggestion: hasMore logic inconsistency between initial fetch and pagination — see inline comment
  • suggestion (prior, unaddressed): PR description is still empty (template placeholders only) and no screenshots for a UI change
  • praise: Thorough test coverage — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Compared the current PR state against findings from a prior review:

  • Retrieved prior bot reviews deterministically via the GitHub API
  • Classified each prior finding as RESOLVED, UNADDRESSED, ACKNOWLEDGED, or CONTESTED
  • Only raised NEW findings for newly introduced code
  • Reviewed the pull request diff checking for correctness, design, architecture, testing, completeness, and adherence to DRY/SRP principles
  • Checked CI status and linked issue acceptance criteria

@AllanOXDi AllanOXDi requested review from AlexVelezLl and akolson March 5, 2026 20:59
Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Channel version history feature looks solid. Clean composable/component separation, consistent pagination logic, comprehensive tests, and proper i18n throughout.

CI passing. Targets unstable (default branch) — new strings are appropriate.

4 prior finding(s) resolved.

  • suggestion (prior, unaddressed): PR description is still empty (template placeholders only) and no screenshots for a UI change — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Compared the current PR state against findings from a prior review:

  • Retrieved prior bot reviews deterministically via the GitHub API
  • Classified each prior finding as RESOLVED, UNADDRESSED, ACKNOWLEDGED, or CONTESTED
  • Only raised NEW findings for newly introduced code
  • Reviewed the pull request diff checking for correctness, design, architecture, testing, completeness, and adherence to DRY/SRP principles
  • Checked CI status and linked issue acceptance criteria

@AllanOXDi AllanOXDi marked this pull request as ready for review March 5, 2026 21:03
Copy link
Member

@AlexVelezLl AlexVelezLl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @AllanOXDi! Great work! I have just made a couple of small changes, one because I had incorrectly defined the ChannelVersionViewset with a pageNumber pagination instead of cursor pagination, and also just aligned the styles a little bit. Will wait until the checks pass, and will proceed to merge. Thanks!

Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Channel version history feature is solid — clean composable/component separation, proper i18n, cursor-based pagination, theme-aware styling, and comprehensive tests.

CI passing. Targets unstable (default branch) — new i18n strings are appropriate.

5 prior finding(s) resolved.

  • nitpick: Stale JSDoc comment — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Compared the current PR state against findings from a prior review:

  • Retrieved prior bot reviews deterministically via the GitHub API
  • Classified each prior finding as RESOLVED, UNADDRESSED, ACKNOWLEDGED, or CONTESTED
  • Only raised NEW findings for newly introduced code
  • Reviewed the pull request diff checking for correctness, design, architecture, testing, completeness, and adherence to DRY/SRP principles
  • Checked CI status and linked issue acceptance criteria

* Displays channel version history with pagination
*
* Shows a collapsible list of channel versions with their descriptions.
* Versions are fetched on-demand when expanded and paginated with 10 versions per page.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: JSDoc says "10 versions per page" but VERSIONS_PER_PAGE is 5.

Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Channel version history feature is clean and well-tested. Composable/component separation is solid, cursor-based pagination works correctly, i18n throughout, and theme-aware styling.

CI passing. Targets unstable (default branch) — new i18n strings are appropriate.

5 prior finding(s) resolved.

  • nitpick (prior, unaddressed): Stale JSDoc comment — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Compared the current PR state against findings from a prior review:

  • Retrieved prior bot reviews deterministically via the GitHub API
  • Classified each prior finding as RESOLVED, UNADDRESSED, ACKNOWLEDGED, or CONTESTED
  • Only raised NEW findings for newly introduced code
  • Reviewed the pull request diff checking for correctness, design, architecture, testing, completeness, and adherence to DRY/SRP principles
  • Checked CI status and linked issue acceptance criteria

* Displays channel version history with pagination
*
* Shows a collapsible list of channel versions with their descriptions.
* Versions are fetched on-demand when expanded and paginated with 5 versions per page.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick (prior, unaddressed): JSDoc says "10 versions per page" but VERSIONS_PER_PAGE is 5.

Suggested change
* Versions are fetched on-demand when expanded and paginated with 5 versions per page.
* Shows a collapsible list of channel versions with their descriptions.
* Versions are fetched on-demand when expanded and paginated with 5 versions per page.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is now addressed!

Copy link

@rtibblesbot rtibblesbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Channel version history feature is clean and well-structured. CI still in progress (Python tests running).

5 prior finding(s) resolved.

  • nitpick (prior, unaddressed): Stale JSDoc comment — see inline comment

@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly

How was this generated?

Compared the current PR state against findings from a prior review:

  • Retrieved prior bot reviews deterministically via the GitHub API
  • Classified each prior finding as RESOLVED, UNADDRESSED, ACKNOWLEDGED, or CONTESTED
  • Only raised NEW findings for newly introduced code
  • Reviewed the pull request diff checking for correctness, design, architecture, testing, completeness, and adherence to DRY/SRP principles
  • Checked CI status and linked issue acceptance criteria

@AlexVelezLl AlexVelezLl merged commit 68f6102 into learningequality:unstable Mar 6, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Show version history in the channel publish side panel

3 participants