JavaScript UI Libraries & Blazor Components Suite – Smart UI › Forums › Data Grid › Set the width and height of a grid › Reply To: Set the width and height of a grid
November 2, 2022 at 9:50 am
#103940
svetoslav_borislavov
Participant
Hi,
You can change the following CSS variable: –smart-grid-default-width. This will set the default width of the Grid or you can locally change the width to your grid:
<div class=”border border-primary rounded p-2 my-auto bg-light”>
<Grid id=”grid” @ref=”grid”></Grid>
</div>
<style>
#grid {
width: 100%;
}
</style>
@code {
Grid grid;
}
I hope this helps! If not, do not hesitate to contact us!
Best Regards,
Svetoslav Borislavov
Smart UI Team
https://www.htmlelements.com/
- This reply was modified 2 years, 2 months ago by svetoslav_borislavov.