update migration docs with latest changes#2680
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
migrations/redesign/message_composer.md (1)
421-422:⚠️ Potential issue | 🟠 Major | ⚡ Quick winFix
slowModeOnLabelusage in migration snippet (missingcooldownTimeOut).In
migrations/redesign/message_composer.md(lines 421-422), the example usestranslations.slowModeOnLabelwithout the requiredint cooldownTimeOut. The SDK definesslowModeOnLabel(int cooldownTimeOut), so copy-pasting this will fail.Suggested doc fix
- SlowModePlaceholder() => translations.slowModeOnLabel, + SlowModePlaceholder(:final cooldownTimeOut) => + translations.slowModeOnLabel(cooldownTimeOut),🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@migrations/redesign/message_composer.md` around lines 421 - 422, The migration snippet uses translations.slowModeOnLabel without the required integer argument; update the example so SlowModePlaceholder calls translations.slowModeOnLabel with a concrete int (e.g., translations.slowModeOnLabel(30)) or a named variable such as cooldownTimeOut, ensuring the signature slowModeOnLabel(int cooldownTimeOut) is satisfied in the example in message_composer.md where SlowModePlaceholder is shown.migrations/redesign/message_actions.md (1)
236-265:⚠️ Potential issue | 🟠 Major | ⚡ Quick winReplace stale
StreamMessageReactionsModalexamples after declaring it deleted.This section says the class is deleted, but the “After” snippet still constructs
StreamMessageReactionsModal, and Line 480 still lists it as a return-value source. That makes the migration path self-contradictory and likely leads to compile errors for readers following it.Proposed doc fix
-### StreamMessageReactionsModal +### StreamMessageReactionsModal → ReactionDetailSheet @@ -**After:** +**After:** ```dart -final action = await showStreamDialog<MessageAction>( - context: context, - builder: (_) => StreamMessageReactionsModal( - message: message, - messageWidget: messageWidget, - ), -); +final action = await ReactionDetailSheet.show( + context: context, + message: message, +); if (action is SelectReaction) { _addReaction(action.reaction); }@@
-- ReturnsFuture<T?>— the value passed toNavigator.popinside the dialog, which is howStreamMessageActionsModal,StreamMessageReactionsModal, andModeratedMessageActionsModaldeliver the selected action back to the caller
+- ReturnsFuture<T?>— the value passed toNavigator.popinside the dialog, which is howStreamMessageActionsModalandModeratedMessageActionsModaldeliver the selected action back to the caller</details> Also applies to: 480-480 <details> <summary>🤖 Prompt for AI Agents</summary>Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.In
@migrations/redesign/message_actions.mdaround lines 236 - 265, Update the
migration docs to stop referencing the deleted StreamMessageReactionsModal:
replace the "After" example that still calls StreamMessageReactionsModal with a
call to ReactionDetailSheet.show(...) (passing context and message) and await
its MessageAction result via showStreamDialog/ReactionDetailSheet.show; then
adjust the Returns description to remove StreamMessageReactionsModal from the
list of dialogs that return Future<T?> so it only mentions
StreamMessageActionsModal and ModeratedMessageActionsModal; keep references to
SelectReaction and MessageAction so readers know how to handle the returned
action.</details> </blockquote></details> </blockquote></details>🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. Inline comments: In `@migrations/redesign/attachments_and_polls.md`: - Line 300: The migration doc contains inconsistent anchors for the redesigned attachment picker link — replace the stale `#streamattachmentpickeroption` anchor in the sentence referencing `AttachmentModalSheet` and `showStreamAttachmentPickerModalBottomSheet` with the confirmed `#attachment-picker` anchor (the same used elsewhere in the document) so the link points to the correct section; update the link target text to match the existing anchor name to avoid broken docs links. In `@migrations/redesign/unread_indicator_button.md`: - Around line 31-35: The migration note is ambiguous about which callback was renamed; update the text to explicitly state that only onTap was renamed to onJumpTap while onDismissTap remains unchanged (or change the section heading from "callback renames" to "callback rename" and add a clarifying sentence). Reference the callback names onTap, onJumpTap, and onDismissTap so readers clearly understand that onTap → onJumpTap is the only change. In `@migrations/v10-migration.md`: - Line 1054: Update the stable-range version boundary wording so it matches the upgrade matrix/timeline: change the reference from "beta.13" to "beta.12" in the migration note that currently reads "The following breaking changes landed between beta.13 and the stable release" so that it correctly routes v10.0.0-beta.12 users to this section; ensure the adjacent sentence/context that mentions the timeline/upgrade matrix uses the same "beta.12" boundary to avoid conflicting migration guidance. --- Outside diff comments: In `@migrations/redesign/message_actions.md`: - Around line 236-265: Update the migration docs to stop referencing the deleted StreamMessageReactionsModal: replace the "After" example that still calls StreamMessageReactionsModal with a call to ReactionDetailSheet.show(...) (passing context and message) and await its MessageAction result via showStreamDialog/ReactionDetailSheet.show; then adjust the Returns description to remove StreamMessageReactionsModal from the list of dialogs that return Future<T?> so it only mentions StreamMessageActionsModal and ModeratedMessageActionsModal; keep references to SelectReaction and MessageAction so readers know how to handle the returned action. In `@migrations/redesign/message_composer.md`: - Around line 421-422: The migration snippet uses translations.slowModeOnLabel without the required integer argument; update the example so SlowModePlaceholder calls translations.slowModeOnLabel with a concrete int (e.g., translations.slowModeOnLabel(30)) or a named variable such as cooldownTimeOut, ensuring the signature slowModeOnLabel(int cooldownTimeOut) is satisfied in the example in message_composer.md where SlowModePlaceholder is shown.🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID:
821e3ca9-d434-40a8-9168-61239f3ed41c📒 Files selected for processing (18)
migrations/redesign/README.mdmigrations/redesign/attachments_and_polls.mdmigrations/redesign/audio_theme.mdmigrations/redesign/channel_list_item.mdmigrations/redesign/headers_and_icons.mdmigrations/redesign/image_cdn.mdmigrations/redesign/localizations.mdmigrations/redesign/media_viewer.mdmigrations/redesign/message_actions.mdmigrations/redesign/message_composer.mdmigrations/redesign/message_list.mdmigrations/redesign/message_widget.mdmigrations/redesign/reaction_list.mdmigrations/redesign/reaction_picker.mdmigrations/redesign/stream_avatar.mdmigrations/redesign/unread_indicator.mdmigrations/redesign/unread_indicator_button.mdmigrations/v10-migration.md
| | --------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | ||
| | `StreamFileAttachmentThumbnail` | Use `StreamImageAttachmentThumbnail` for images, `StreamVideoAttachmentThumbnail` for videos, or `StreamFileTypeIcon.fromMimeType(...)` for generic file icons | | ||
| | `StreamAttachmentUploadStateBuilder.successBuilder` | Removed — was unreachable in practice (the success state immediately transitions to the rendered attachment) | | ||
| | `AttachmentModalSheet` | Use the redesigned attachment picker — see [v10-migration.md](../v10-migration.md#streamattachmentpickeroption) for the new sealed-class option types and `showStreamAttachmentPickerModalBottomSheet` | |
There was a problem hiding this comment.
Fix likely stale anchor in migration link.
Line 300 uses #streamattachmentpickeroption, but Line 647 links to #attachment-picker for the same target document. Please normalize to one confirmed anchor to avoid a broken docs link.
Suggested patch
-| `AttachmentModalSheet` | Use the redesigned attachment picker — see [v10-migration.md](../v10-migration.md#streamattachmentpickeroption) for the new sealed-class option types and `showStreamAttachmentPickerModalBottomSheet` |
+| `AttachmentModalSheet` | Use the redesigned attachment picker — see [v10-migration.md](../v10-migration.md#attachment-picker) for the new sealed-class option types and `showStreamAttachmentPickerModalBottomSheet` |📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| | `AttachmentModalSheet` | Use the redesigned attachment picker — see [v10-migration.md](../v10-migration.md#streamattachmentpickeroption) for the new sealed-class option types and `showStreamAttachmentPickerModalBottomSheet` | | |
| | `AttachmentModalSheet` | Use the redesigned attachment picker — see [v10-migration.md](../v10-migration.md#attachment-picker) for the new sealed-class option types and `showStreamAttachmentPickerModalBottomSheet` | |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@migrations/redesign/attachments_and_polls.md` at line 300, The migration doc
contains inconsistent anchors for the redesigned attachment picker link —
replace the stale `#streamattachmentpickeroption` anchor in the sentence
referencing `AttachmentModalSheet` and
`showStreamAttachmentPickerModalBottomSheet` with the confirmed
`#attachment-picker` anchor (the same used elsewhere in the document) so the
link points to the correct section; update the link target text to match the
existing anchor name to avoid broken docs links.
| | Before | After | | ||
| | -------------- | -------------- | | ||
| | `onTap` | `onJumpTap` | | ||
| | `onDismissTap` | `onDismissTap` | | ||
|
|
There was a problem hiding this comment.
Clarify which callback is actually renamed.
Line 29 says “callback renames”, but Line 34 shows onDismissTap unchanged. This can confuse migration readers; either rename the section to singular or explicitly note only onTap changed.
Suggested doc tweak
-### 4. `UnreadIndicatorButton` callback renames
+### 4. `UnreadIndicatorButton` callback rename
| Before | After |
| -------------- | -------------- |
| `onTap` | `onJumpTap` |
-| `onDismissTap` | `onDismissTap` |
+| `onDismissTap` | `onDismissTap` (unchanged) |🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@migrations/redesign/unread_indicator_button.md` around lines 31 - 35, The
migration note is ambiguous about which callback was renamed; update the text to
explicitly state that only onTap was renamed to onJumpTap while onDismissTap
remains unchanged (or change the section heading from "callback renames" to
"callback rename" and add a clarifying sentence). Reference the callback names
onTap, onJumpTap, and onDismissTap so readers clearly understand that onTap →
onJumpTap is the only change.
|
|
||
| > **Introduced in:** v10.0.0 (stable) | ||
|
|
||
| The following breaking changes landed between beta.13 and the stable release. |
There was a problem hiding this comment.
Fix stable-range version boundary (beta.13 vs beta.12).
Line 1054 conflicts with the same document’s upgrade matrix/timeline (which route v10.0.0-beta.12 users to this section). Please align this boundary to avoid migration-path confusion.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@migrations/v10-migration.md` at line 1054, Update the stable-range version
boundary wording so it matches the upgrade matrix/timeline: change the reference
from "beta.13" to "beta.12" in the migration note that currently reads "The
following breaking changes landed between beta.13 and the stable release" so
that it correctly routes v10.0.0-beta.12 users to this section; ensure the
adjacent sentence/context that mentions the timeline/upgrade matrix uses the
same "beta.12" boundary to avoid conflicting migration guidance.
f325292 to
5aa1043
Compare
Submit a pull request
CLA
Description of the pull request
This updates the migration docs with missing changes.
It also formats the tables so it's easier to find mistakes.
Summary by CodeRabbit