Skip to content

Conversation

@siriwatknp
Copy link
Member

@siriwatknp siriwatknp commented Jul 3, 2025

Preview: https://deploy-preview-46480--material-ui.netlify.app/material-ui/react-button/

This PR aims to connect docs with MUI Chat. It begins with an idea to have a button on each demo that opens MUI Chat to let users extend the demo with prompts.

Screen.Recording.2568-07-15.at.08.44.21.mov

@siriwatknp siriwatknp added the docs Improvements or additions to the documentation. label Jul 3, 2025
@mui-bot
Copy link

mui-bot commented Jul 3, 2025

Netlify deploy preview

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

Bundle size report

Bundle Parsed Size Gzip Size
@mui/material 0B(0.00%) 0B(0.00%)
@mui/lab 0B(0.00%) 0B(0.00%)
@mui/system 0B(0.00%) 0B(0.00%)
@mui/utils 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against 9449b1e

@oliviertassinari
Copy link
Member

oliviertassinari commented Jul 3, 2025

Linking the original one for context: mui/mui-x#17250 and clarity.

The strategy to deploy this is available in: https://www.notion.so/mui-org/store-Weekly-meeting-2025-06-16-214cbfe7b66080f7a10cd3c74d5a2aa5?source=copy_link#222cbfe7b660808a9866ca671dc45b39. We are eventually adding it to all the demos.

data-ga-event-category="mui-chat"
data-ga-event-label={demo.gaLabel}
data-ga-event-action="open-in-mui-chat"
{...getControlProps(10)}
Copy link
Member

Choose a reason for hiding this comment

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

Something strange is happing here, this button is not accessible with the keyboard like all the other controls on the toolbar.

@siriwatknp

This comment was marked as resolved.

@siriwatknp siriwatknp requested a review from hasdfa July 4, 2025 07:10
@siriwatknp siriwatknp marked this pull request as ready for review July 8, 2025 06:16
@siriwatknp siriwatknp changed the title [WIP][docs] Add "Edit in Mui Chat" button on demos [docs] Add "Edit in Mui Chat" button on demos Jul 8, 2025
@DiegoAndai
Copy link
Member

What about something like this?

Screen.Recording.2025-07-08.at.15.08.30.mov

@siriwatknp
Copy link
Member Author

What about something like this?

Screen.Recording.2025-07-08.at.15.08.30.mov

Thanks for the feedback, I think it's harder to notice. For starter I would go with a label to let user see at first glance.

@DiegoAndai
Copy link
Member

Thanks for the feedback, I think it's harder to notice

Sure, that was part of the idea, to make this new button look more in line with existing options, but make it stand out a bit more (with the gradient border).

For me, the "Edit in MUI Chat" button looks out of place, like it was crammed into the current UI without considering the existing hierarchy. For me, as a user, it looks a bit messy.

Copy link
Member

@hasdfa hasdfa left a comment

Choose a reason for hiding this comment

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

Look good, the button in the code area looks more in place 😄

I think we may remove env variable for production Material UI docs to not show a button at start and test it only on MUI X docs, and after we would have some feedback and make it more stable add to Material UI docs. WDYT?

@siriwatknp
Copy link
Member Author

I think we may remove env variable for production Material UI docs to not show a button at start and test it only on MUI X docs, and after we would have some feedback and make it more stable add to Material UI docs. WDYT?

Yes, let's do that.

@siriwatknp siriwatknp merged commit 9ec27c5 into mui:master Jul 16, 2025
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants