RocketChat / RocketChat/Rocket.Chat

🐛 Markdown Toolbar Formatting Issues (Bold / Italic / Strikethrough / Code) buttons doesn't get pressed even after clicking

Open
#39,300 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type: bug
Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

🐛 Markdown Toolbar Buttons Do Not Toggle Properly
Description

The markdown formatting toolbar buttons (Bold, Italic, Strikethrough, Inline Code, Multiline Code) do not behave as toggle buttons.

Currently, when a formatting button is pressed, it inserts the corresponding markdown symbols but the button itself does not remain in an active state.

This makes the formatting experience inconsistent and confusing for users.


🔴 Issue: Button Activation Behavior

Formatting buttons should behave as toggle buttons.

Expected behavior:

  • When pressed once → formatting mode becomes active
  • When pressed again → formatting mode becomes inactive
  • The button should visually indicate when it is active

Current behavior:

  • Pressing the button only inserts markdown symbols
  • The button does not stay in an active state
  • Users cannot clearly see whether formatting is enabled or disabled

🧪 Affected Formatting Buttons
  • Bold (**)
  • Italic (*)
  • Strikethrough (~~)
  • Inline Code (`)
  • Multiline Code (```)

💡 Suggested Improvement
  • Implement proper toggle state for formatting buttons
  • Provide visual feedback (active/pressed state)
  • Ensure pressing the button again disables the formatting

Environment
  • Latest develop branch
  • Reproducible in the message composer

Note

Other formatting issues such as nested or duplicate markdown symbols have already been resolved, so this issue only focuses on the button toggle behavior.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in the message composer and locate the Markdown toolbar implementation for the Bold, Italic, Strikethrough, Inline Code, and Multiline Code buttons. Reproduce the current behavior, then verify that each button shows an active state after one press and returns to inactive after a second press without reintroducing nested or duplicate markdown symbols.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.