Skip to content

Conversation

@siriwatknp
Copy link
Member

closes #41072

Out of scope: determine which links should be external by updating the list.

Added arrow to external links using CSS to detect target="_blank".

docs-external-link.mp4

@siriwatknp siriwatknp added the scope: docs-infra Involves the docs-infra product (https://www.notion.so/mui-org/b9f676062eb94747b6768209f7751305). label Feb 16, 2024
@mui-bot
Copy link

mui-bot commented Feb 16, 2024

Netlify deploy preview

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

Bundle size report

No bundle size changes (Toolpad)
No bundle size changes

Generated by 🚫 dangerJS against 002a466

Copy link
Member

@alexfauquette alexfauquette left a comment

Choose a reason for hiding this comment

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

The technical solution looks good.

I taught the issue was about distinguishing internal cs external links. Something as follow:

a:not([href*="mui.com"]):not([href^="/"]):not([href^="#"])

But distinguishing by "open a new tab" vs "move in the same tab" seems good too 👍

Copy link
Collaborator

@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.

Love some CSS-only stuff like this 😊 Nice one, Jun, thanks for being so fast!

@danilo-leal danilo-leal added the design This is about UI or UX design, please involve a designer. label Feb 16, 2024
@siriwatknp siriwatknp merged commit 326beee into mui:master Feb 19, 2024
@oliviertassinari
Copy link
Member

oliviertassinari commented Feb 19, 2024

Nice, this could make it to the Link component #41129.


We might want to disable it for image links

SCR-20240219-mltb

https://deploy-preview-41129--material-ui.netlify.app/material-ui/discover-more/backers/#gold-sponsors

For ads, it feels like it shouldn't be here:

SCR-20240219-mmdw

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

@alexfauquette
Copy link
Member

Proposing a fix: #41181

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

design This is about UI or UX design, please involve a designer. scope: docs-infra Involves the docs-infra product (https://www.notion.so/mui-org/b9f676062eb94747b6768209f7751305). scope: link Changes related to the link.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[docs-infra] Style external (target blank) links differently

5 participants