vincjo / datatables

A toolkit for creating datatable components with Svelte
https://vincjo.fr/datatables
MIT License
363 stars 15 forks source link

Adjusting the width of a specific TD #89

Open Vichondrias1 opened 5 months ago

Vichondrias1 commented 5 months ago

i tried adjusting the width of this td inline to see if it changes but it doesnt, can you please help me with this. thanks in advance image

Vichondrias1 commented 5 months ago

also this example, i want the header to be vertically align not collapse so i want also to adjust its width image

vincjo commented 1 month ago

Sorry for the late response.

I used to set style directly in the markup for specific requirements, especialy for column sizing:

<tbody>
    <tr>
      <td style:min-width="400px">{row.smth}</td>
[...]

Or with table :global(th) CSS selector.

The ideal way would be to create your own Th component, and add a width property. I will think about adding it in a future version.