Skip to content

Rename ".button-link" to ".button-ghost" #24670

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

Merged
merged 3 commits into from
May 12, 2023

Conversation

wxiaoguang
Copy link
Contributor

@wxiaoguang wxiaoguang commented May 12, 2023

Mainstream frameworks:

All (at least most?) of them make "link" button have "underline" when hovering.

So, a "link" is a "link", when it's hovered, it should have the underline by default. To be strict, Gitea's "button-link" is not link-style, so it needs a better name.

Actually, for the "plain" button, there are some different approaches:

  • Some frameworks just make "default" button as no style (not feasible in Gitea/Fomantic UI)
  • Primer uses "btn-invisible", which is not a proper word
  • NextUI uses "light", which is not a proper word, either ...
  • CoreUI / ChakraUI uses "ghost", I think this name is acceptable.

Welcome to suggest better name for such button.

Or, we just call it ".button-plain" or ".button-simple", in fact I prefer such simple and clear name.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label May 12, 2023
@wxiaoguang wxiaoguang requested review from delvh and silverwind May 12, 2023 02:27
@wxiaoguang wxiaoguang added the skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. label May 12, 2023
@wxiaoguang wxiaoguang added this to the 1.20.0 milestone May 12, 2023
@silverwind
Copy link
Member

silverwind commented May 12, 2023

👍 for following chakra-ui naming, I think it's probably the most well thought-out UI framework around currently.

@wxiaoguang
Copy link
Contributor Author

Then let's go with it? After this PR, I will change .ui.tertiary.button to this.

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels May 12, 2023
@silverwind
Copy link
Member

silverwind commented May 12, 2023

Yes, .ui.tertiary.button needs to go. We can also add hover/active background to this later, but I'd say it depends on color-mix to obtain the low-alpha shades which I'm still a bit wary to use because it's so new.

image

@silverwind silverwind added topic/ui Change the appearance of the Gitea UI type/refactoring Existing code has been cleaned up. There should be no new functionality. labels May 12, 2023
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels May 12, 2023
@delvh
Copy link
Member

delvh commented May 12, 2023

Yup, I can also live with both.
I probably prefer ".button-plain" too.

@silverwind
Copy link
Member

I prefer the chakra naming, we can later have a true button-link, if the need arises.

https://chakra-ui.com/docs/components/button/usage#button-variants

@silverwind silverwind enabled auto-merge (squash) May 12, 2023 14:06
@silverwind silverwind added the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label May 12, 2023
@silverwind silverwind merged commit ec8ea58 into go-gitea:main May 12, 2023
@GiteaBot GiteaBot removed the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label May 12, 2023
@wxiaoguang wxiaoguang deleted the fix-button-link branch May 12, 2023 15:03
silverwind pushed a commit to silverwind/gitea that referenced this pull request May 12, 2023
Mainstream frameworks:

* https://getbootstrap.com/docs/5.0/components/buttons/
* https://primer.style/css/components/buttons#link-button
* https://nextui.org/docs/components/button#light
* https://coreui.io/react/docs/components/button/
* https://design-system.hpe.design/components/button
* https://chakra-ui.com/docs/components/button/usage#button-variants
* https://mui.com/material-ui/react-button/

All (at least most?) of them make "link" button have "underline" when
hovering.

So, a "link" is a "link", when it's hovered, it should have the
underline by default. To be strict, Gitea's "button-link" is not
link-style, so it needs a better name.

Actually, for the "plain" button, there are some different approaches:

* Some frameworks just make "default" button as no style (not feasible
in Gitea/Fomantic UI)
* Primer uses "btn-invisible", which is not a proper word
* NextUI uses "light", which is not a proper word, either ...
* CoreUI / ChakraUI uses "ghost", I think this name is acceptable.


Welcome to suggest better name for such button.

Or, we just call it ".button-plain" or ".button-simple", in fact I
prefer such simple and clear name.
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Aug 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. topic/ui Change the appearance of the Gitea UI type/refactoring Existing code has been cleaned up. There should be no new functionality.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants