Semantic-UI-React icon indicating copy to clipboard operation
Semantic-UI-React copied to clipboard

Image: Inconsistent prop usage between Image and Icon for circular shape

Open zxlin opened this issue 9 years ago • 5 comments

Steps

Currently to create a circular image and a circular icon, we would do the following:

<Image shape='circular' src='url' />

<Icon circular name='icon' />

but that's really inconsistent, especially where Image and Icon can be used interchangeably such as in Header

Expected Result

Ideally, both Image and Icon would use bool props for adjective based attributes as it is the case with many other attributes like disabled, bordered, etc...

<Image circular src='url' />

<Icon circular name='icon' />

Version

0.75.1

Please let me know if there is a reason to keep it the way it is.

zxlin avatar Oct 19 '17 07:10 zxlin

Image supports also rounded shape, that's why we have rounded prop. I think that the better solution will replace circular prop with shape. @levithomason what you think?

layershifter avatar Oct 19 '17 17:10 layershifter

That's fine too, there just needs to be some consistency with this.

zxlin avatar Oct 19 '17 17:10 zxlin

@zxlin feel free to open PR :+1:

layershifter avatar Oct 19 '17 18:10 layershifter

Yes on consistency. The shape grouping is the odd ball here:

<Buton circular />
<Label circular />
<Segment circular />
<Icon circular />

Let's fix the Image to be consistent.

levithomason avatar Oct 20 '17 00:10 levithomason

I think this is what @levithomason was getting at, please review and let me know if there's anything wrong.

I'm pretty new to this whole open source thing.

RetroCraft avatar Oct 20 '17 17:10 RetroCraft