coinbase / onchainkit

React components and TypeScript utilities to help you build top-tier onchain apps.
https://onchainkit.xyz
MIT License
537 stars 125 forks source link

Bug: [Avatar] - className overrides not working as expected #696

Closed sergical closed 3 months ago

sergical commented 3 months ago

Describe the bug and the steps to reproduce it

adding className="h-4 w-4 mr-2" doesn't update the default 32x32 svg

What's the expected behavior?

The avatar circle becomes smaller

What version of the libraries are you using?

No response

kyhyco commented 3 months ago

What's good buddy. Fix coming right up

sergical commented 3 months ago

What's good buddy. Fix coming right up

My brother 🤍

kyhyco commented 3 months ago

Are you intending to use attestation badge with the small Avatar?

This only fixes the className override and does not handle Badge sizing if you do something like this

<Avatar className="h-4 w-4 mr-2">
  <Badge />
</Avatar>
sergical commented 3 months ago

Wasn't planning on it, but shouldn't Badge be able to consume a className as well? just thinking out loud here, no clue how it's set up 😅

kyhyco commented 3 months ago

Working on a system that will allow you to override the entire presentation layer. Not there yet though!

kyhyco commented 3 months ago

Cutting a new release. One sec.

sergical commented 3 months ago

I got a bit of a problem bumping versions from 0.16 to past 20 now with wagmi too btw 😅

im using wagmi provider from privy but onchain provider complains that it doesn't see it

context: https://docs.privy.io/guide/react/wallets/usage/wagmi

Also theres a typescript mismatch with a viem version im using vs latest onchainkit viem version where chain is incompatible.

i can submit those 2 separately though.

thank you for building 🤍

kyhyco commented 3 months ago

Could you open up a new issue? Let's discuss it there. 1 issue for those would be great.

kyhyco commented 3 months ago

Aight 0.22.3 is out now. This should fix the avatar className override bug

sergical commented 3 months ago

Okay ill update and open up an issue for the other ones with the repo so it's contextual, thank you so much Ky!