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

fix: dont treat escapes as flow #1040

Merged
merged 1 commit into from
Dec 11, 2024
Merged

fix: dont treat escapes as flow #1040

merged 1 commit into from
Dec 11, 2024

Conversation

kellyjosephprice
Copy link
Collaborator

@kellyjosephprice kellyjosephprice commented Dec 11, 2024

PR App Ref CX-1610

🧰 Changes

Fixes migrating tables with leading escapes.

The phrasing util is not aware of the escape node type, as it is from a previous version of mdast. This was confusing our tables-to-jsx transformer. It would look at tables and decide if it could be compiled to markdown format, eg:

| a | b |
|---|---|
| 1 | 2 |

or if it should be compiled to JSX format, eg:

<Table>
  <TableHead>
    <TableRow>
      <TableCell>a</TableCell>
      <TableCell>b</TableCell>
    </TableRow>
  </TableHead>
  <TableBody>
    <TableRow>
      <TableCell>1</TableCell>
      <TableCell>2</TableCell>
    </TableRow>
  </TableBody>
</Table>

🧬 QA & Testing

@kellyjosephprice kellyjosephprice marked this pull request as ready for review December 11, 2024 23:38
@kellyjosephprice kellyjosephprice merged commit 4692ece into next Dec 11, 2024
13 checks passed
@kellyjosephprice kellyjosephprice deleted the fix/table-escapes branch December 11, 2024 23:48
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