Repository navigation
feat(ui-message-list): add the message variants, delete the app copies - #43727
gabriellsh wants to merge 25 commits into
Conversation
|
Looks like this PR is not ready to merge, because of the following issues:
Please fix the issues and try again If you have any trouble, please check the PR guidelines |
🦋 Changeset detectedLatest commit: bb86c64 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
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. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## message-list/05-toolbar #43727 +/- ##
===========================================================
+ Coverage 71.53% 71.57% +0.03%
===========================================================
Files 5765 5632 -133
Lines 253313 251970 -1343
Branches 47920 47469 -451
===========================================================
- Hits 181212 180350 -862
+ Misses 67679 67288 -391
+ Partials 4422 4332 -90
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
…ord the answers Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
…ements around it message-variants R14: the user info opened from the avatar of a message in a thread closed right after it opened, as it did in the room before #43272. Co-Authored-By: Claude <noreply@anthropic.com>
… empty message-variants R38: `length && <Part/>` drew a literal 0. Co-Authored-By: Claude <noreply@anthropic.com>
message-variants R38: the reply button of a broadcast room showed on messages in places that allow no interaction, where it did nothing. Co-Authored-By: Claude <noreply@anthropic.com>
…ormat message-variants R15: the tooltip of the edited indicator used Date.toLocaleString(). Co-Authored-By: Claude <noreply@anthropic.com>
…s open message-variants R49: the toolbar of a message found by a search in all rooms asked the open chat for its room and subscription, so it offered the actions of the room that is open. Co-Authored-By: Claude <noreply@anthropic.com>
…message header message-variants R49: a header takes the roles the place resolved once for its list, or looks them up itself, as two components; a hook cannot be called conditionally. Co-Authored-By: Claude <noreply@anthropic.com>
… provider message-variants R49, R52: the old list provider resolved them once per list; the provider for every place that shows messages now does, and answers them to the message header through usePlaceUserRoles. A request that fails leaves no roles and no error. Nothing reads it yet. Co-Authored-By: Claude <noreply@anthropic.com>
…mponents message-variants R47, D1: the editing context follows the store that editing and jumps write to, in places that allow interaction, until the store is renamed in branch 09. Nothing reads it yet. Co-Authored-By: Claude <noreply@anthropic.com>
message-variants R9 to R16, R18 to R21, R51: the header with the author's name, username and roles, the avatar, the status indicators, the read receipt, and the hooks that decide whether a row is selected or drawn with the editing look. From the reference, with develop's username rule, roles without a click, and the clicks of the avatar and of a selecting row kept on their element. Co-Authored-By: Claude <noreply@anthropic.com>
… stores message-variants R49: one request per message gave way to the room and the subscription the place already has, as the base did for the broadcast reply since #43471. Nothing changes for the viewer: a message of another room already reads the client stores for its own (the fix before it). Co-Authored-By: Claude <noreply@anthropic.com>
message-variants R1, R2, R6, R9, R14, R17 to R21, R23, R27, R30, R31, R33, R37 to R39 and the known defects D2 and D3: RoomMessage and its content from the reference, compared with develop's: usernames, the click of the avatar and of a selecting row kept on their element, the thread metrics and the broadcast reply by the display and the conversation the place gives. Co-Authored-By: Claude <noreply@anthropic.com>
…ead preview variants message-variants R3 to R5, R10, R11, R12, R22, R24, R28, R29, R32, R34 to R37, R39, R8, R51 and the known defects D4 to D8: from the reference, compared with develop's: the username next to the name of a system message, the avatar click of a thread message kept on its element, the plain text preview of a thread started by a message without markdown, and the Fuselage left container. A story stacks the four variants. Co-Authored-By: Claude <noreply@anthropic.com>
message-variants R44, R45, R52: the audit draws the package's room and system messages and follows the viewer's display settings (time, roles, username beside the real name, read receipts, URL previews), without a toolbar; a failed request for the roles of an audited room leaves the row as it is. Contact history draws the package's status indicators. Co-Authored-By: Claude <noreply@anthropic.com>
…iants message-variants R25, R26, R40, R46, R48: the room's list draws the package's room message, system message and thread preview with the room's selection and the date format of the display context. Each row it renders registers itself for "Select all", as the old variants did, until the list engine replaces it. Co-Authored-By: Claude <noreply@anthropic.com>
…e ui-message-list message variants message-variants R25, R42, R43, R46, R48: the tabs and search draw the package's room message and system message with the room's selection, their place and the markers of the subscription. Co-Authored-By: Claude <noreply@anthropic.com>
…iants message-variants R24, R25, R28, R32, R41, R46: the thread's list draws the package's thread message and system message and gives them no selection, so they never join the room's; the selection store the thread kept for that is gone. Co-Authored-By: Claude <noreply@anthropic.com>
… no longer renders message-variants R50: the room's list, a thread's list, the pinned, starred and mentions tabs and search mount the messages provider with their room and subscription, and the room's list, tabs and search with the room's selection. The app keeps no variant, no old list context and no provider that fed it; the proofs of the specs of branches 03 to 05 that sat next to them move with their code. Co-Authored-By: Claude <noreply@anthropic.com>
… read message-variants R47: the room no longer provides the highlighted message to its lists; the messages provider reads the store that jumps and editing write to. The store stays until branch 09. Co-Authored-By: Claude <noreply@anthropic.com>
message-variants R51: the app's lib/MessageAction.ts re-exports the package's types. Co-Authored-By: Claude <noreply@anthropic.com>
message-variants: Design, code and tests of the spec, the proof table of the plan, and the plan done. Co-Authored-By: Claude <noreply@anthropic.com>
7bf8bd2 to
bb86c64
Compare
Proposed changes (including videos or screenshots)
Adds the message variants to
@rocket.chat/ui-message-list(RoomMessage,SystemMessage,ThreadMessage,ThreadMessagePreview, the header, roles, avatar, status and receipt parts, and the hooks and libs they use) and switches every consumer to them: the old room and thread lists, the pinned, starred and mentions tabs, search, the audit, and the threads list. It deletesapps/meteor/client/components/message/**,MessageListContextandMessageListProvider;lib/MessageAction.tsbecomes a re-export of the package's types.MessagesProvidergains the editing context, the selection adapter and the data the variants read about a conversation.Twenty-five commits. Five fixes sit at the bottom, each with a changeset and a spec that fails first; then enabling steps (roles resolved once per place, the editing context fed from the highlight store); then the package variants in three commits, the consumer switches, the deletions and docs. The old lists stay until parts 08 and 09 of the stack, so their jump highlight still comes through the shared highlight store, and the old room list registers what it renders for "Select all" through the rows themselves.
The specs
developadded or changed in #43386 forRoomMessageandSystemMessageare ported to the package's specs of those variants.This is part 06 of the stack (00 to 09). Review it against its base branch
message-list/05-toolbar, not againstdevelop.Stack
Visible changes
.changeset/audit-messages-follow-display-settings.md,'@rocket.chat/meteor': minor: the audit shows the time, the roles, the username beside the real name when real names are on, read receipts and URL previews, as the viewer's settings say..changeset/thread-avatar-click-stays-in-the-message.md,'@rocket.chat/meteor': patch: the user info no longer closes right after it opens from a thread message's avatar..changeset/messages-draw-no-stray-zero.md,'@rocket.chat/meteor': patch: no stray "0" under a message with empty action links or reactions..changeset/broadcast-reply-hidden-where-interaction-is-off.md,'@rocket.chat/meteor': patch: no broadcast reply button where messages cannot be acted on, such as the audit..changeset/edited-message-date-follows-date-format.md,'@rocket.chat/meteor': patch: the tooltip of the "edited" indicator uses the viewer's date and time format..changeset/message-toolbar-uses-the-room-of-the-message.md,'@rocket.chat/meteor': patch: the toolbar of a message found by search in all rooms uses the message's own room, not the open one.Known differences from develop
The changes above, and:
showUserAvatarprop is removed;The package records eight behaviors carried over from
developas pinned defects (skipped tests): D2 a revealed ignored message is hidden again when its row remounts; D3 activating the checkbox input toggles twice; D4 a thread preview has no per-message fallback; D5 Space on a thread preview does not prevent the default; D6 a pending encrypted message in a thread keeps its toolbar; D7 system and thread messages have no accessible name; D8 the preview of a reply to a system message writes the text from the reply. D1 (a jump replaces the editing look) is retired in part 09 of the stack.Issue(s)
Steps to test or reproduce
?msg=link (highlight).@allmarkers.Further comments
Decisions to check
349d4cc7d1fsits above two feature commits (b4ce5b8bd88,1ea07c37ad7). Moving it down conflicted inMessagesProvider.spec.tsx, so the order was left.roles-changelistener per row. Resolving once per place there needs a multi-room resolution inMessagesProvider, a design change outside the approved spec.message-toolbarR25 was amended: a pending encrypted message in a thread keeps its toolbar (D6).<mid>-contentis dropped, as ondevelop, so it is not duplicated when the thread panel is open.develop's did; part 08 of the stack makes it stable.@rocket.chat/ui-message-list. This PR adds none for the private package; parts 08 and 09 of the stack do. The repo versions private packages (other private packages carry changesets), so 08 and 09 follow the repo, and 03 to 07 may need changesets too. Undecided.Not run
🤖 Generated with Claude Code