Skip to content

MM-69160: Fix capitalization and text size in agent mention reminder - #917

Merged
nickmisasi merged 3 commits into
masterfrom
cursor/matty-fixer-mm-69160-9551
Jul 23, 2026
Merged

MM-69160: Fix capitalization and text size in agent mention reminder#917
nickmisasi merged 3 commits into
masterfrom
cursor/matty-fixer-mm-69160-9551

Conversation

@cursor

@cursor cursor Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Summary

The ephemeral "To respond to an agent you must @mention them" reminder (custom post type custom_agent_mention_reminder, rendered by AgentMentionReminderPost) had two small UI defects reported in MM-69160:

  • The loop-in link read lowercase "click here to loop in @matty" instead of "Click here to loop in @matty".
  • The reminder text was forced to font-size: 13px (with line-height: 18px), making it visibly smaller than regular post text.

This PR:

  • Capitalizes the link copy in agent_mention_reminder_post.tsx and re-extracts the webapp i18n string.
  • Removes the font-size / line-height override on the Hint styled-component so the reminder inherits the standard post text size.

Verified end-to-end in a real Mattermost 11.9 container with the plugin deployed (Testcontainers). Before the fix the reminder rendered at 13px; after the fix it renders at 14px, matching the sibling regular post (14px), and the link is capitalized.

QA test steps

  1. In a channel (not a DM/GM), @mention an agent in a message so the agent replies in a thread.
  2. In that same thread, post a reply that does not @mention the agent.
  3. Observe the ephemeral reminder ("Only visible to you").
  4. Confirm the link reads "Click here to loop in @<Agent>" and the text size matches the surrounding posts.

Ticket Link

Jira https://mattermost.atlassian.net/browse/MM-69160

Screenshots

before after
Before: lowercase After: capitalized

Release Note

Fixed the capitalization and text size of the "To respond to an agent you must @mention them" reminder so its loop-in link is capitalized and its text matches regular post text.
Open in Web Open in Cursor 

Summary by CodeRabbit

  • Improvements

    • Updated the agent reminder link text to begin with “Click here” for improved readability and consistency.
    • Preserved fallback messaging when no agent username is available.
    • Refined reminder text styling to better align with surrounding content.
  • Quality

    • Added automated tests covering link text, fallback behaviour, click actions, confirmation messaging, and missing-agent scenarios.

cursoragent and others added 2 commits July 23, 2026 16:19
The ephemeral "To respond to an agent" reminder rendered its loop-in
link as lowercase "click here" and forced a 13px font that was smaller
than regular post text. Capitalize the link copy and drop the font-size
override so the reminder inherits the standard post text size.

Co-authored-by: mattermost-code <mattermost-code@users.noreply.github.com>
Co-authored-by: mattermost-code <mattermost-code@users.noreply.github.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: f78d66dd-09d0-4edf-a5a7-d6c70025a9e8

📥 Commits

Reviewing files that changed from the base of the PR and between f217c75 and ee55c20.

📒 Files selected for processing (1)
  • webapp/src/components/agent_mention_reminder_post.test.tsx
💤 Files with no reviewable changes (1)
  • webapp/src/components/agent_mention_reminder_post.test.tsx

📝 Walkthrough

Walkthrough

The agent mention reminder link text is capitalized, hint typography overrides are removed, and a test suite covers display-name fallback, loop-in interaction, confirmation rendering, and the no-username state.

Changes

Agent mention reminder

Layer / File(s) Summary
Update reminder presentation
webapp/src/components/agent_mention_reminder_post.tsx, webapp/src/i18n/en.json
Capitalizes the loop-in link prompt and removes explicit font-size and line-height styles from the hint.
Cover reminder behaviour
webapp/src/components/agent_mention_reminder_post.test.tsx
Tests link labels, fallback usernames, loop-in invocation, confirmation text, and rendering without a bot username.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: fixing the reminder's capitalization and text size.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cursor/matty-fixer-mm-69160-9551

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown

🤖 LLM Evaluation Results

OpenAI

⚠️ Overall: 21/28 tests passed (75.0%)

Provider Total Passed Failed Pass Rate
⚠️ OPENAI 28 21 7 75.0%

❌ Failed Evaluations

Show 7 failures

OPENAI

1. TestReactEval/[openai]_react_cat_message

  • Score: 0.00
  • Rubric: The word/emoji is a cat emoji or a heart/love emoji
  • Reason: The output is the text string "heart_eyes_cat", not an actual cat emoji (e.g., 😺) or heart/love emoji (e.g., ❤️).

2. TestConversationMentionHandling/[openai]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: is a list of bugs
  • Reason: The output does not provide any list of bugs; it explains lack of access and asks the user to paste bug reports, offering a template for future compilation.

3. TestConversationMentionHandling/[openai]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: includes a description of each bug
  • Reason: The output does not include any bug descriptions; it only explains that it lacks access to the bug reports and asks the user to paste them. Therefore it cannot include a description of each bug.

4. TestConversationMentionHandling/[openai]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: attributes each bug to a user
  • Reason: The output does not list any bugs and does not attribute any bug to a specific user; it only proposes a future format including a 'Reported by' field.

5. TestConversationMentionHandling/[openai]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: attributes the bug about trying to save without a color and the save button not doing anything to @maria.nunez
  • Reason: The output does not mention the specific bug ('trying to save without a color' and 'the save button not doing anything') nor does it attribute it to @maria.nunez; it only asks for source bug reports to be provided.

6. TestConversationMentionHandling/[openai]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: the bug about the end user being able to change channel banner is attributed to @maria.nunez
  • Reason: The output does not list any bugs or attribute the channel banner change bug to @maria.nunez; it only requests that bug reports be provided.

7. TestDirectMessageConversations/[openai]_bot_dm_tool_introspection

  • Score: 0.00
  • Rubric: mentions Github and refers to the documentation
  • Reason: The output refers to documentation (Mattermost documentation link) but it does not mention GitHub anywhere, so it fails the rubric requirement to mention GitHub and refer to the documentation.

Anthropic

⚠️ Overall: 21/28 tests passed (75.0%)

Provider Total Passed Failed Pass Rate
⚠️ ANTHROPIC 28 21 7 75.0%

❌ Failed Evaluations

Show 7 failures

ANTHROPIC

1. TestReactEval/[anthropic]_react_cat_message

  • Score: 0.00
  • Rubric: The word/emoji is a cat emoji or a heart/love emoji
  • Reason: The output is the text string "heart_eyes_cat", not an actual cat emoji (e.g., 😺) or a heart/love emoji (e.g., ❤️).

2. TestConversationMentionHandling/[anthropic]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: is a list of bugs
  • Reason: The provided output does not contain a list of bugs. It states lack of access to trackers and suggests where to look, but no actual bug entries are listed.

3. TestConversationMentionHandling/[anthropic]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: includes a description of each bug
  • Reason: The output does not describe any bugs; it only states lack of access to trackers and suggests where to look, so it does not include a description of each bug.

4. TestConversationMentionHandling/[anthropic]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: attributes each bug to a user
  • Reason: The output does not list any bugs, nor does it attribute bugs to specific users. It instead states it cannot access trackers and suggests places to look.

5. TestConversationMentionHandling/[anthropic]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: attributes the bug about trying to save without a color and the save button not doing anything to @maria.nunez
  • Reason: The output does not attribute any bug to @maria.nunez, nor does it mention a bug about saving without a color or the save button not doing anything. It only states inability to access trackers and suggests where to look.

6. TestConversationMentionHandling/[anthropic]_conversation_from_attribution_long_thread.json

  • Score: 0.00
  • Rubric: the bug about the end user being able to change channel banner is attributed to @maria.nunez
  • Reason: The output does not mention the specific bug about an end user being able to change the channel banner, nor does it attribute that bug to @maria.nunez.

7. TestDirectMessageConversations/[anthropic]_bot_dm_tool_introspection

  • Score: 0.00
  • Rubric: mentions Github and refers to the documentation
  • Reason: The output refers to the documentation (docs.mattermost.com) but does not mention GitHub, so it does not satisfy both rubric requirements.

This comment was automatically generated by the eval CI pipeline.

@nickmisasi

Copy link
Copy Markdown
Collaborator

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Comment thread webapp/src/components/agent_mention_reminder_post.test.tsx Outdated
@mattermost-code

Copy link
Copy Markdown
Contributor

Looking! Follow along here: https://cursor.com/agents/bc-bfecf8f1-38d7-45ee-bff8-8efa7e7201ce

@mm-cloud-bot

Copy link
Copy Markdown

Test server destroyed

@mattermost-code

Copy link
Copy Markdown
Contributor

Looking!

⟪factory:970990f3-c5ed-4f79-8c89-4c45dfdc3412:looking:mattermost_2f_mattermost-plugin-agents:917:4766495185:looking-comment⟫

Addresses review feedback: the dedicated capitalized "Click here" test
is redundant since the fallback test already asserts the capitalized
link label. Drop it to keep the suite focused.

Co-authored-by: mattermost-code <mattermost-code@users.noreply.github.com>
@mattermost-code

Copy link
Copy Markdown
Contributor

Thanks for the review! Addressed the feedback:

  • Removed the excessive test (renders the loop-in link with a capitalized "Click here" (MM-69160)) as requested. Its capitalization assertion is already implicitly covered by the falls back to the bot username when no display name is set test, which asserts the link label Click here to loop in @matty. The remaining three tests (fallback username, loop-in click + confirmation, plain fallback message) still pass.

Other feedback reviewed and no action needed:

  • CodeRabbit approved with no actionable comments.
  • CodeRabbit "Docstring Coverage 0%" pre-merge warning is a generic false positive for a TS test file.
  • The eval-CI failures (conversation attribution, react emoji, tool introspection) are pre-existing LLM eval flakiness unrelated to this webapp copy/style change.

npx jest and eslint both pass on the affected file. Ready for another look.

⟪factory:970990f3-c5ed-4f79-8c89-4c45dfdc3412:fe09142b-b44d-4eea-b509-cbd4a2c56e4d:summary-comment⟫

@nickmisasi
nickmisasi merged commit ed6efd9 into master Jul 23, 2026
32 checks passed
@nickmisasi
nickmisasi deleted the cursor/matty-fixer-mm-69160-9551 branch July 23, 2026 18:03
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.

5 participants