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

FixMarkdownEditor preview overflowing its container #2639

Merged
merged 3 commits into from
Dec 5, 2022

Conversation

iansan5653
Copy link
Contributor

The MarkdownEditor's "Preview" view can overflow its container. For example, previewing a very long line of code in a code block will cause it to overflow. This issue is noted in https://github.com/github/memex/issues/12747.

This is because the entire editor is contained inside a <fieldset> element (for accessibility semantics) and this element has a default browser style of min-inline-size: max-content.

This PR fixes this by adding minInlineSize: auto to the fieldset.

@iansan5653 iansan5653 requested a review from a team December 2, 2022 19:56
@iansan5653 iansan5653 self-assigned this Dec 2, 2022
@changeset-bot
Copy link

changeset-bot bot commented Dec 2, 2022

🦋 Changeset detected

Latest commit: 1ca2467

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Patch

Not sure what this means? Click here to learn what changesets are.

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

@github-actions
Copy link
Contributor

github-actions bot commented Dec 2, 2022

size-limit report 📦

Path Size
dist/browser.esm.js 78.95 KB (0%)
dist/browser.umd.js 79.58 KB (0%)

@iansan5653 iansan5653 enabled auto-merge (squash) December 5, 2022 15:40
@iansan5653 iansan5653 temporarily deployed to github-pages December 5, 2022 15:55 Inactive
@iansan5653 iansan5653 merged commit fd9ab39 into main Dec 5, 2022
@iansan5653 iansan5653 deleted the fix-markdowneditor-overflow branch December 5, 2022 15:56
@primer-css primer-css mentioned this pull request Dec 5, 2022
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.

3 participants