How to right justify on decimal point #790
candcconsulting
started this conversation in
General
Replies: 1 comment 4 replies
-
Hey @candcconsulting, We are using flex on our table, so textAlign will not work. We could update our storybook to provide at least one story with numbers aligned to the right. |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The examples here
https://itwin.github.io/iTwinUI-react/?path=/story/core-table--basic
are great but it is a common requirement to right justify on decimal places
If I add text-align as this discussion
https://stackoverflow.com/questions/53605342/how-to-make-some-columns-align-left-and-some-column-align-center-in-react-table
columns: [
{
accessor: "firstName",
Header: "S Column 1",
style: {
textAlign: 'right'
}
}
]
Then the text is not right aligned ... if it is added to the cell
<span style = {{textAlign: "right"}} title={props.value}>{props.value}
Then the does not fill the
Is this possible and if so which style should be used ?
Beta Was this translation helpful? Give feedback.
All reactions