KyberNetwork / kyberswap-widgets

4 stars 15 forks source link

Customizing the width #17

Closed SGB555 closed 8 months ago

SGB555 commented 8 months ago

The documentation mentions the ability to customize the width, but the width property is not being accepted in the widget's props.

WX20240116-104920@2x

image

The width of the Wrapper component is also not being applied to the width property that may be passed in.

image
viet-nv commented 8 months ago

hi @SGB555, You can wrap the widget in a div and then add a CSS selector like this to customize the widget:

<div className="widget">
   <Widget />
</div>
.widget {
 > div {
     width: 32rem;
   }
}