-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SvgChevronRight icon in SubRowExpander component rotates 180 degrees instead of 90 on expansion #1750
Comments
Could you provide a repro by forking this template? It works fine here: https://itwin.github.io/iTwinUI/react/?story=table--expandable-subrows&theme=dark |
Hi @mayank99, Here is the repro code: https://stackblitz.com/edit/github-cph1jx?file=src%2FApp.tsx. Apparently adding the "subComponent" property to the Table component adds the additional rotation. It is a bit confusing that adding/removing this property impacts chevron rotation, so I think SvgChevronRight style is good but the rotation as a side effect of "subComponent" property should be removed. Also, if it is okay, it would be good to make the chevron rotation smooth. |
I believe the But yes, the side effect you mentioned in #1749 seems to be duplicate because there already is CSS that applies a transform on iTwinUI/packages/itwinui-css/src/table/base.scss Lines 218 to 220 in 5aba6b4
|
@DenisMicha Could you share why you're passing In your sandbox,
|
@mayank99 I am not sure, but we probably started passing |
The alignment has been fixed in 3.3.1, so you can get rid of In the future, we might add some documentation or a runtime warning if more users attempt to use |
SvgChevronRight icon in SubRowExpander component rotates 180 degrees instead of 90 on expansion.
Actual behavior
Chevron points to the left side when sub rows expanded (rotates 180deg).
Expected behavior
Chevron points down when sub rows expanded (rotates 90deg).
This behavior happens because both SvgChevronRight component and its wrapping IconButton component include 90deg rotation on expansion, therefore total rotation becomes 180deg. The "transform" property which causes rotation should be removed from SvgChevronRight component styles.
The text was updated successfully, but these errors were encountered: