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

button.loading deprecation #15

Open
sandeepc24 opened this issue Aug 24, 2024 · 4 comments
Open

button.loading deprecation #15

sandeepc24 opened this issue Aug 24, 2024 · 4 comments

Comments

@sandeepc24
Copy link

I have upgraded to latest DaisyUI and get following warning

image

How can I fix this?

@Dzoukr
Copy link
Owner

Dzoukr commented Aug 26, 2024

@sandeepc24
Copy link
Author

How can I show spinner inside button as is the case with this button.

@sandeepc24
Copy link
Author

Something like
image

@Freymaurer
Copy link

@sandeepc24 daisyui uses css classes for styling. So the you if you are unable to find something in Feliz.DaisyUI you can always click on the "HTML" tab next to "Preview" and find the following:

<button class="btn">
  <span class="loading loading-spinner"></span>
  loading
</button>

Which you can translate to Feliz style with

Html.button [
  prop.className "btn"
  prop.children [
    Html.span [prop.className "loading loading-spinner"]
    Html.text "loading"
  ]
]

Feliz.DaisyUI provides wrappers for these functions to make you write less "prop.children"/"prop.className" with discoverable api, but if everything fails you can always fallback to this.

Hope this helped 🙂

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