Skip to content

Conversation

@Chasen-Zhang
Copy link
Member

@Chasen-Zhang Chasen-Zhang commented Oct 28, 2025

fix: step-content

@vercel
Copy link

vercel bot commented Oct 28, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
docs Ready Ready Preview Comment Oct 28, 2025 10:55am
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines 108 to 125
<div>
{isCollapsed !== undefined && (
<button
onClick={() => setIsCollapsed((v) => !v)}
className="collapsible-btn"
aria-expanded={!isCollapsed}
>
<span className={`collapsible-icon ${isCollapsed ? "" : "open"}`}>
<DownArrow width={16} height={16} />
</span>
{isCollapsed ? "Show Details" : "Hide Details"}
</button>
)}
{childrenArray?.[0]}
{isCollapsed !== undefined ? (
<> {isCollapsed ? null : childrenArray?.slice(1)}</>
) : (
childrenArray?.slice(1)

Choose a reason for hiding this comment

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

P1 Badge Collapsed content hides headings when markdown adds leading whitespace

The new collapse rendering keeps childrenArray[0] visible and hides slice(1) when defaultCollapsed is defined. In MDX usage the first child is commonly the whitespace string that separates the opening tag from the first heading (e.g. {"\n"}, then <h2>). As soon as defaultCollapsed is true, the heading and the rest of the content live in childrenArray[1...] and are therefore hidden, so a collapsed release-note block renders only the toggle button without the version title. The previous implementation injected the button after the first <h2> so the header always remained visible. Consider skipping leading text nodes or explicitly preserving the first element node before hiding the remaining children.

Useful? React with 👍 / 👎.

@Chasen-Zhang Chasen-Zhang merged commit d682b56 into main Oct 28, 2025
3 of 4 checks passed
@Chasen-Zhang Chasen-Zhang deleted the remove-useless branch October 28, 2025 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants