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

Add a link with custom classes in CoreComponents wrapping the built-in link component #5909

Open
francois08 opened this issue Aug 24, 2024 · 1 comment

Comments

@francois08
Copy link

In generated CoreComponents we are provided a set of components encapsulating their TW classes (which avoids us repeating these classes application-wide).

I think we should add a <.link> component wrapping the built-in link component which allows the developer to customize the styling of the links.

This would be more consistent where other basic components such as button, label, etc. have their styling encapsulated (while for <.link>, by default in a generated application, we have to copy the TW classes application-wide).

Therefore it would be more logical and consistent to have a link component in CoreComponents alongside the other basic components.

@SteffenDE
Copy link
Contributor

Related: #5820

The main issue I see with wrapping the link component is that we’d need to mirror the API of Phoenix.Component.link/1 and there’s currently no nice way to do this. I didn’t test this but there would probably also be a conflict when useing Phoenix.Component.

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

No branches or pull requests

2 participants