Skip to content

feat(packages/ui): support inline code in sidebar titles #95

Open

Description

@zrosenbauer

Summary

Allow backtick-delimited inline code in sidebar titles, such as `Config` object or `foobar()` function.

Current behavior

Sidebar titles are resolved and serialized as plain strings, so code-like identifiers cannot use the same inline-code treatment as document content.

Proposed scope

  • Treat backticks in title strings as inline-code delimiters.
  • Preserve the plain string through config and sync; parse it only in the UI renderer.
  • Apply the behavior to sidebar labels first. Navbar support is out of scope unless it already shares the same renderer.
  • Render text safely without accepting arbitrary HTML.

Acceptance criteria

  • Mixed text/code titles render the delimited segment with code styling.
  • Titles without backticks are unchanged.
  • Escaped or unmatched backticks degrade to readable text.
  • Tooltips and accessible names expose the complete plain-text title.
  • Tests cover plain, mixed, escaped, and malformed input.

Activity

  1. changed the title [-]feat: support inline code styling in sidebar titles[/-] [+]feat(packages/ui): support inline code in sidebar titles[/+] on Aug 15, 2026
  2. zrosenbauer commented on Oct 28, 2026

    @zrosenbauer
    MemberAuthor

    Current Rspress already renders backtick-delimited sidebar titles as inline code, so the original missing-feature description is outdated.

    Remaining scope: escaped-backtick handling and verification of safe rendering, tooltips, accessible names, and malformed input.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or improvement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions