Skip to content
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

[Bug]: TableToolbarMenu size and color incorrect #10058

Closed
2 tasks done
TastyDucks opened this issue Nov 5, 2021 · 2 comments · Fixed by #10296
Closed
2 tasks done

[Bug]: TableToolbarMenu size and color incorrect #10058

TastyDucks opened this issue Nov 5, 2021 · 2 comments · Fixed by #10296

Comments

@TastyDucks
Copy link

Package

carbon-components

Browser

Chrome

Package version

@carbon/[email protected]

Description

The element does not respect the size constraints when <TableToolbar size="sm">, causing the icon to be misaligned:
image
The parent to the svg element does not have a set color and thus the svg fill cannot correspond to the current theme:
image
This should probably be $icon-01.

CodeSandbox example

https://codesandbox.io/s/youthful-driscoll-vbjk5?file=/src/index.js

Steps to reproduce

  1. Using @carbon/[email protected], create a TableTooblar with a TableToolbarMenu.
  2. Inspect the SVG and note the fill property is set to currentcolor
  3. Inspect the OverflowContainer and note that it does not conform to the height of the containing TableToolbarMenu

The icon fill can be fixed by adding color: var(--cds-icon-primary) to the TableToolbarMenu, although IMO it would be nice if every icon had the fill property defaulting to $icon-01 instead of needing to inherit that from its parents color.

Code of Conduct

@TastyDucks
Copy link
Author

Addendum: the scss rules for

th .cds--table-sort__flex {
    min-height
}

.cds--data-table--sort th, .cds--data-table th[aria-sort] {
    height
}

cause sortable headers to break out of the xs TableHeader:
Actual:
image
Expected (with those properties unset):
image

@jnm2377
Copy link
Contributor

jnm2377 commented Jan 27, 2022

@TastyDucks I have a PR up for the scope of the original issue. Can you open a different issue for any other data table bugs you might find? We try to keep each issue/PR scoped to a specific bug or feature so it's easier to track for us. Thank you :)

Repository owner moved this from 🏗 In Progress to ✅ Done in Design System Jan 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

5 participants