Thanks to visit codestin.com
Credit goes to github.com

Skip to content

chore(docs): update documentation #1892

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

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

AVGVSTVS96
Copy link
Contributor

@AVGVSTVS96 AVGVSTVS96 commented Apr 22, 2025

Some minor documentation updates


Important

Updated SyntaxHighlighting.mdx documentation for react-shiki and react-syntax-highlighter options, including rephrased callouts and updated default values.

  • Documentation Updates:
    • Rephrased warning about syntax highlighting not being enabled by default in SyntaxHighlighting.mdx.
    • Updated information callout to clarify assistant-ui provides two options for syntax highlighting.
    • Updated default theme for react-shiki to github-dark and added links to type descriptions in SyntaxHighlighting.mdx.
    • Added note about potential removal of react-syntax-highlighter in future releases.

This description was created by Ellipsis for 1312c39. You can customize this summary. It will automatically update as commits are pushed.

Copy link

changeset-bot bot commented Apr 22, 2025

⚠️ No Changeset found

Latest commit: f3506a4

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

LGTM 👍

@AVGVSTVS96 AVGVSTVS96 force-pushed the bassim/docs-4/21 branch 2 times, most recently from bc424eb to 1eb32a4 Compare April 22, 2025 19:11
Copy link

vercel bot commented Apr 22, 2025

@AVGVSTVS96 is attempting to deploy a commit to the assistant-ui Team on Vercel.

A member of the Team first needs to authorize it.

@AVGVSTVS96 AVGVSTVS96 force-pushed the bassim/docs-4/21 branch 2 times, most recently from d8bf583 to c164d2f Compare April 24, 2025 06:11
@AVGVSTVS96 AVGVSTVS96 marked this pull request as ready for review April 24, 2025 06:22
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

Updated the SyntaxHighlighting documentation with improved clarity and technical accuracy around syntax highlighting configuration and options.

  • Added warning callout clarifying syntax highlighting is not enabled by default in markdown
  • Enhanced options table with direct links to type definitions in react-shiki source code
  • Added explanation for type table order reversal due to fumadocs update on 4/22/25
  • Improved formatting of code examples and callouts for better readability
  • Updated default values and type descriptions for better technical accuracy

💡 (2/5) Greptile learns from your feedback when you react with 👍/👎!

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link
Contributor

promptless bot commented Apr 24, 2025

📝 Documentation updates detected! You can review documentation updates here

Copy link

@mrge-io mrge-io bot left a comment

Choose a reason for hiding this comment

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

mrge reviewed 1 file and found no issues. Review this PR in mrge.io.

Copy link
Contributor

coderabbitai bot commented Apr 24, 2025

Walkthrough

The changes in this update focus exclusively on revising documentation content within the SyntaxHighlighting.mdx file. The edits include rephrasing the warning about syntax highlighting, reformatting descriptions of syntax highlighting options from bulleted lists to a more compact style, and adjusting whitespace in installation instructions. The TypeTable component's type prop documentation was extensively refined by specifying more precise property types with links to their source definitions in relevant GitHub repositories. The default theme was updated from "vitesse-dark" to "github-dark", and the default style value was changed from an empty object to undefined. The type name for customLanguages was changed from TextmateLanguage[] to Language[]. Additionally, the options object order was reversed before rendering, with a comment explaining this change. Minor formatting improvements were made to callouts related to react-syntax-highlighter. No code logic or exported entities were modified.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Lite

📥 Commits

Reviewing files that changed from the base of the PR and between f3506a4 and 1312c39.

📒 Files selected for processing (1)
  • apps/docs/content/docs/ui/SyntaxHighlighting.mdx (4 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • apps/docs/content/docs/ui/SyntaxHighlighting.mdx

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 6

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bdaa68d and aef96cf.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (1)
  • apps/docs/content/docs/ui/SyntaxHighlighting.mdx (4 hunks)
🧰 Additional context used
🪛 LanguageTool
apps/docs/content/docs/ui/SyntaxHighlighting.mdx

[grammar] ~11-~11: Did you mean the formatting language “Markdown” (= proper noun)?
Context: ...">Syntax highlighting is not enabled in markdown by default. <Callout type="i...

(MARKDOWN_NNP)

⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: mrge · AI code reviewer
🔇 Additional comments (6)
apps/docs/content/docs/ui/SyntaxHighlighting.mdx (6)

57-66: Verify updated default theme and type link.

The default theme was changed to github-dark, and the link points to a specific commit. Please confirm:

  • github-dark is the intended default in the latest react-shiki release.
  • The typeDescriptionLink stays valid over time (consider linking to a tag or branch instead of a SHA).

67-74: Review the language default and type URL.

The language prop now defaults to "text". Ensure this aligns with the Language type in react-shiki and that the link correctly references the source:

-      language: {
-        type: "Language",
-        default: "text",
+      language: {
+        type: "Language",
+        default: "text",

75-84: Approve className and style props.

The entries for className (default "") and style (default undefined) follow common React conventions and improve clarity.


85-98: Approve cssVariablePrefix and defaultColor updates.

The cssVariablePrefix default and the change of defaultColor default to undefined (from earlier {}) both enhance flexibility. The type links appear correct.


112-118: Approve transformers entry.

The transformers prop has an accurate description, type link, and default value.


126-126: Approve upcoming feature callout.

The info callout about full Shiki option support coming soon is clear and helpful.

<Callout type="warn">
Syntax highlighting is not included by default.
</Callout>
<Callout type="warn">Syntax highlighting is not enabled in markdown by default.</Callout>
Copy link
Contributor

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Capitalize 'Markdown' in warning callout.

To follow proper noun usage, change "markdown" to "Markdown" in the warning:

-<Callout type="warn">Syntax highlighting is not enabled in markdown by default.</Callout>
+<Callout type="warn">Syntax highlighting is not enabled in Markdown by default.</Callout>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<Callout type="warn">Syntax highlighting is not enabled in markdown by default.</Callout>
<Callout type="warn">Syntax highlighting is not enabled in Markdown by default.</Callout>
🧰 Tools
🪛 LanguageTool

[grammar] ~11-~11: Did you mean the formatting language “Markdown” (= proper noun)?
Context: ...">Syntax highlighting is not enabled in markdown by default. <Callout type="i...

(MARKDOWN_NNP)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (3)
apps/docs/content/docs/ui/SyntaxHighlighting.mdx (3)

11-11: Capitalize 'Markdown' in warning callout
To follow proper noun usage, change "markdown" to "Markdown".

-<Callout type="warn">Syntax highlighting is not enabled in markdown by default.</Callout>
+<Callout type="warn">Syntax highlighting is not enabled in Markdown by default.</Callout>

105-111: Refine customLanguages default display
The default value is shown as a string; use an actual empty array literal for clarity.

-      customLanguages: {
-        description: "Custom languages to preload for highlighting",
-        type: "Language[]",
-        typeDescriptionLink: ".../types.ts#L24",
-        default: "[]",
-      },
+      customLanguages: {
+        description: "Custom languages to preload for highlighting",
+        type: "Language[]",
+        typeDescriptionLink: ".../types.ts#L24",
+        default: [],
+      },

14-16: 🧹 Nitpick (assertive)

Replace ampersand with 'and' for consistency
Use "and" instead of "&" to match the wording style in other callouts.

-  - **react-shiki** (recommended for performance & dynamic language support)
+  - **react-shiki** (recommended for performance and dynamic language support)
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Lite

📥 Commits

Reviewing files that changed from the base of the PR and between a26b6b4 and f3506a4.

📒 Files selected for processing (1)
  • apps/docs/content/docs/ui/SyntaxHighlighting.mdx (4 hunks)
🔇 Additional comments (11)
apps/docs/content/docs/ui/SyntaxHighlighting.mdx (11)

32-34: The file path is already wrapped in backticks, so no further change is needed here.


57-66: Approve theme entry enhancements
The theme property now accurately links to its type definition, defaults to github-dark, and marks the field as required.


67-74: Approve language entry improvements
The language property is clearly specified, linked, and marked as required—good documentation update.


75-79: Approve className entry
Clear description and sensible default for the <pre> element’s CSS classes.


80-84: Approve style entry
Using undefined as the default for inline styles is appropriate and clearly documented.


85-90: Approve cssVariablePrefix entry
Prefix logic is well-described and the default value is sensible.


91-98: Approve defaultColor entry
Detailed description, correct type link, and undefined default align with intended behavior.


99-104: Approve delay entry
Millisecond delay documentation is clear and defaulting to 0 makes sense.


119-121: The inline comment placement above .reverse() has already been addressed.


126-126: No action needed for this informational callout.


178-181: Documentation warning for deprecation is clear
The callout clearly advises using react-shiki over the legacy option.

Copy link

trag-bot bot commented Apr 24, 2025

@trag-bot didn't find any issues in the code! ✅✨

Copy link

trag-bot bot commented Apr 24, 2025

Pull request summary

  • Updated the warning message to clarify that syntax highlighting is not enabled in markdown by default.
  • Improved the formatting of the options for syntax highlighting, including clearer descriptions and type links.
  • Changed the default theme from "vitesse-dark" to "github-dark" for better visibility.
  • Enhanced the type definitions for the highlighting options, including more specific types and links to their definitions.
  • Reversed the order of the type table to align with recent changes in the documentation.
  • Added a note about the upcoming support for all Shiki options in the react-shiki library.
  • Clarified the warning regarding the potential removal of the react-syntax-highlighter option in future releases.

@AVGVSTVS96 AVGVSTVS96 marked this pull request as draft April 25, 2025 00:55
@AVGVSTVS96 AVGVSTVS96 marked this pull request as ready for review April 27, 2025 07:16
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

Based on the most recent changes to the SyntaxHighlighting documentation, here's a concise summary of the key updates:

Documentation updates to improve clarity and technical accuracy in the SyntaxHighlighting component configuration.

  • Fixed capitalization of "Markdown" in warning callout for proper noun usage
  • Changed ampersand to "and" in react-shiki description for consistent documentation style
  • Updated customLanguages default value display to use proper array literal format
  • Improved type descriptions and links for better source code reference

Note: This summary focuses only on the most recent changes not covered in previous reviews, avoiding repetition of points already mentioned.

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

@mrge-io mrge-io bot left a comment

Choose a reason for hiding this comment

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

mrge reviewed 1 file and found no issues. Review this PR in mrge.io.

Copy link
Contributor

promptless bot commented Apr 27, 2025

📝 Documentation updates detected! You can review documentation updates here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants