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

Btn class on Link is not working with "-primary" suffix #214

Closed
zemian opened this issue Sep 6, 2023 · 3 comments
Closed

Btn class on Link is not working with "-primary" suffix #214

zemian opened this issue Sep 6, 2023 · 3 comments

Comments

@zemian
Copy link

zemian commented Sep 6, 2023

This works fine:

<a class="btn" target="_blank" href="https://google.com">TEST</a>

But this failed:

<a class="btn-primary" target="_blank" **href="https://google.com">TEST</a>**
@MacFJA
Copy link

MacFJA commented Sep 9, 2023

The class btn is required on <a> tag (cf. documentation)

The correct code is:

<a class="btn btn-primary" target="_blank" href="https://google.com">TEST</a>

@zemian
Copy link
Author

zemian commented Sep 11, 2023

Ah okay got it. However I have to point out that this is inconsistent compare to <input> or <button>. Both of these does not require separate "btn" but only <a> requires it? Please consider making them consistent would be helpful.

@Spiderpig86
Copy link
Owner

The only exceptions that don't need the btn class are <button> and <input type="submit"> since having that is redundant. We know the intention is that they would be buttons. All other tags like <div> or <a> will require btn to be specified.

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

3 participants