Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Assistant renders Markdown tables #249

Merged
merged 5 commits into from
Jun 14, 2024

Conversation

dcalhoun
Copy link
Member

@dcalhoun dcalhoun commented Jun 13, 2024

Fixes https://github.com/Automattic/dotcom-forge/issues/7720.

Proposed Changes

  • Leverage remark-gfm to parse and render Markdown table syntax to improve
    legibility of assistant responses.
  • Allow horizontal scrolling of assistant messages to ensure wide content, like
    large tabular data, is visible.

Testing Instructions

  1. Request tabular data containing a large number of columns from the AI assistant.
  2. Verify a styled table is rendered and is scrollable to view all information.
markdown-table

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

Enable rendering Markdown table syntax.
Improve legibility of tabular data.
Ensure wide content, like large tabular data, is viewable.
@dcalhoun dcalhoun added the [Type] Enhancement Improvement upon an existing feature label Jun 13, 2024
@dcalhoun dcalhoun self-assigned this Jun 13, 2024
Mock this ESM-only package for compatibility with existing CJS code.
@dcalhoun dcalhoun marked this pull request as ready for review June 13, 2024 20:03
@dcalhoun dcalhoun requested review from a team June 13, 2024 20:03
Copy link
Contributor

@jeroenpf jeroenpf left a comment

Choose a reason for hiding this comment

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

The tables are rendering for me and the horizontal scroll appears when the content is too wide.

Thanks for adding this fix!

@dcalhoun dcalhoun merged commit ba3fae4 into trunk Jun 14, 2024
12 checks passed
@dcalhoun dcalhoun deleted the feat/assistant-renders-markdown-tables branch June 14, 2024 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Enhancement Improvement upon an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants