ov-igloo-ui icon indicating copy to clipboard operation
ov-igloo-ui copied to clipboard

[Bug]: The Igloo css' are included multiple times when looking at the DevTools

Open CarolineSabourin-Jean opened this issue 1 year ago • 4 comments

Contact Details

No response

What happened?

When we look at the css of all Igloo components via the DevTools, we can see that it is included multiple times. See an example with a Button: ids-btn css

I expect to see the css there only one time.

Component

All the components

Component Version

0.0.0

Which browsers are you seeing the problem on?

No response

Mobile Device

No response

Relevant log output

No response

CarolineSabourin-Jean avatar Jan 23 '24 19:01 CarolineSabourin-Jean

I'm pretty sure it has always been like this. This is really not ideal. What happens is that a component's css file is included from its component and each component is included inside OV. If an Igloo component includes another component like a Button, you will see the Button css for each Igloo component that includes it. I'm not really sure how to go about fixing this for Igloo. I know hopper will not be like this thankfully. Maybe @alexasselin008 has an idea of how we can easily improve this.

vicky-comeau avatar Jan 23 '24 22:01 vicky-comeau

It is the way it currently works due to the fact that each components are self contained. TagPicker has a peer dependency on the button component, therefore loading it's CSS.

Edit: when I published my comment Vicky's comment showed up. What she says.

We also have to take into consideration that one component can have a dependency on a particular version of another component, loading a single CSS file is not currently possible.

fraincs avatar Jan 24 '24 01:01 fraincs

Since this issue has been present for all of igloo's existence, we will tolerate it for now. The plan would be to develop Hopper asap, and migrate Officevibe to it.

We'll make sure this kind of issue is not present in the next Design system.

I've talked with Alex Martel and he agrees with this course of action

alexasselin008 avatar Jan 24 '24 16:01 alexasselin008

Ok! Thank you all for your answers!

CarolineSabourin-Jean avatar Jan 24 '24 16:01 CarolineSabourin-Jean