Maniaque
Maniaque

Reputation: 761

react-data-grid: Sortable column header. What dictates which side of the text does the sort icon render on?

I've built out a react data grid. I've added the sortable optional feature and on my system is working with the sort icon(s) rendering to the right of the header text, which is how I'd prefer it.

Others in my group have pulled my code when they run it the sort icon is rendered to the left of the header text (I'm assuming somehow inserting the pull-left style to the icon span).

I can find no information that outlines how exactly this can be controlled, or why it would work differently from one system another.

Hopefully someone is still using this component that can shed some light on this.

Upvotes: 0

Views: 1131

Answers (1)

Stefanni Becker
Stefanni Becker

Reputation: 131

You should be able to target the icon and override with CSS. If you inspect the element in Dev tools, it will tell you the classname of the icon. Use CSS to move its position.

Upvotes: 0

Related Questions