Skip to content

refactor(UI): The rich text editing box uses the tiptap component#1139

Merged
benjamin-747 merged 2 commits into
gitmono-dev:mainfrom
Ceron-CSS:tiptapToMr
Jun 18, 2025
Merged

refactor(UI): The rich text editing box uses the tiptap component#1139
benjamin-747 merged 2 commits into
gitmono-dev:mainfrom
Ceron-CSS:tiptapToMr

Conversation

@Ceron-CSS

Copy link
Copy Markdown
Contributor

No description provided.

@vercel

vercel Bot commented Jun 18, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
mega ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 18, 2025 6:38am

This comment was marked as outdated.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the rich text editing box in the merge request detail page to use the tiptap-based SimpleNoteContent component, replacing the previous rich editor implementation.

  • Replaces the old RichEditor component with the new SimpleNoteContent component.
  • Updates comment submission logic to retrieve HTML from the tiptap editor and clear the editor via a ref after successful submission.
  • Adopts new loading states on action buttons and updates markdown rendering in comment display.

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
moon/apps/web/pages/[org]/mr/[id].tsx Replaced RichEditor and associated state with SimpleNoteContent and a ref‑based approach for comment submission.
moon/apps/web/components/SimpleNoteEditor/useSimpleNoteEditor.tsx Introduced a new hook wrapping tiptap editor configuration with updated extension handling.
moon/apps/web/components/SimpleNoteEditor/SimpleNoteContent.tsx Added a new component for note editing with support for file drops, attachments, and hotkeys.
moon/apps/web/components/MrView/MRComment.tsx Updated comment rendering logic to use RichTextRenderer with markdown extensions.
Comments suppressed due to low confidence (2)

moon/apps/web/components/MrView/MRComment.tsx:66

  • [nitpick] Consider renaming 'extensions' to a more descriptive identifier (e.g., 'markdownExtensions') to better communicate its purpose in the markdown rendering flow.
  const extensions = useMemo(() => getMarkdownExtensions({ linkUnfurl: {} }), [])

moon/apps/web/pages/[org]/mr/[id].tsx:90

  • [nitpick] Ensure that the indentation and brace structure within the send_comment function is clear, matching the team’s style guidelines to enhance readability and ease future maintenance.
    const send_comment = () => {

@benjamin-747
benjamin-747 added this pull request to the merge queue Jun 18, 2025
Merged via the queue into gitmono-dev:main with commit d3d4ddd Jun 18, 2025
6 checks passed
@Ceron-CSS
Ceron-CSS deleted the tiptapToMr branch June 20, 2025 09:11
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.

3 participants