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

[website] Fix FlashCode position #42139

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

oliviertassinari
Copy link
Member

A quick one I noticed

Before:
SCR-20240505-rbai

After:
SCR-20240505-raxf

@oliviertassinari oliviertassinari added bug 🐛 Something doesn't work website Pages that are not documentation-related, marketing-focused. regression A bug, but worse labels May 5, 2024
@mui-bot
Copy link

mui-bot commented May 5, 2024

Netlify deploy preview

https://deploy-preview-42139--material-ui.netlify.app/

Bundle size report

No bundle size changes (Toolpad)
No bundle size changes

Generated by 🚫 dangerJS against 78d8d0e

@zannager zannager requested a review from danilo-leal May 6, 2024 16:21
Copy link
Contributor

@danilo-leal danilo-leal left a comment

Choose a reason for hiding this comment

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

Cool! Left a couple of remarks. I'm also touching on these components somewhat significantly at another PR (#38604). Lastly, I wonder if this is really a regression? It sounds too severe as it's non-functional and non-blocking—a bug rings as more reasonable.

<Box
sx={{
position: 'relative',
overflow: 'clip',
Copy link
Contributor

Choose a reason for hiding this comment

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

We still need overflow: clip here, otherwise:

Screenshot 2024-05-06 at 17 45 54

}}
>
<HighlightedCode copyButtonHidden plainStyle code={code} language="jsx" />
<FlashCode startLine={startLine[index]} endLine={endLine[index]} sx={{ mx: 1 }} />
<Box sx={{ position: 'relative' }}>
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm curious why an extra DOM node here (as opposed to having position: 'relative' in the Frame.Info) is better than sx={{ mx: 1 }} in the FlashCode component?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work regression A bug, but worse website Pages that are not documentation-related, marketing-focused.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants