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

[Emotion] Convert final EuiDataGrid cell styles (Part 5) #8013

Merged
merged 28 commits into from
Sep 12, 2024

Commits on Sep 10, 2024

  1. Convert remaining .euiDataGridRowCell styles

    + flatten specificity with `:where` selector
    cee-chen committed Sep 10, 2024
    Configuration menu
    Copy the full SHA
    175b2f8 View commit details
    Browse the repository at this point in the history
  2. Convert remaining .euiDataGridRowCell__content styles

    - JS logic lets us flatten and add more explanatory comments for the different height types
    cee-chen committed Sep 10, 2024
    Configuration menu
    Copy the full SHA
    046bfef View commit details
    Browse the repository at this point in the history
  3. Update downstream snapshots

    cee-chen committed Sep 10, 2024
    Configuration menu
    Copy the full SHA
    ba408b6 View commit details
    Browse the repository at this point in the history

Commits on Sep 11, 2024

  1. Convert remaining .euiDataGridHeaderCell styles

    - fairly straightforward
    - DRY out flex CSS between cell and focus trap div
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    91a349c View commit details
    Browse the repository at this point in the history
  2. [refactor] Remove unnecessary CellContent FC

    - just inline it, it's only used once
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    89ad354 View commit details
    Browse the repository at this point in the history
  3. Convert .euiDataGridHeaderCell__content styles

    - flatten left/right CSS since we have the prop right here
    
    + remove unnecessary flex-shrink CSS on the arrow - `EuiIcon` already takes care of that inherently
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    45aeb31 View commit details
    Browse the repository at this point in the history
  4. [refactor] Clean up column actions button/icon DOM+CSS

    - just reuse EuiButtonIcon with transform/animations unset and remove `__icon` - simplifies a ton of CSS
    
    - handle fontSize sizing of actions button in top level data grid styles
    
    - use `:not()` CSS to handle hidden state instead, which simplifies even more CSS
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    95548bb View commit details
    Browse the repository at this point in the history
  5. Convert .euiDataGridHeaderCell__button styles

    + convert inline Emotion to styles & fix line-height shenanigans
    
    + move complex selectors to new util
    
    + wrap transition in animation media query
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    ccde288 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    c9327ca View commit details
    Browse the repository at this point in the history
  7. [refactor] clean up header control column DOM

    - remove unnecessary `.euiDataGridHeaderCell__content` div element in control columns - it's not doing anything useful, so we might as well delete it
    
    + fix `focus_utils` rendering a `null` in control column `aria-describedby`
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    8320712 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    25d92ff View commit details
    Browse the repository at this point in the history
  9. [Enhancement] Replace unused header cell actions CSS

    - font weight appears to be unused from an old theme
    
    - let's replace it with actual english text instead that indicates what clicking the button will do
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    480f098 View commit details
    Browse the repository at this point in the history
  10. Convert column resizer styles

    + [enhancement] improve smoothness of dragging visibility with an `isDragging` modifier
    
    - clean up unnecessary inline style (only useful when dragging, we don't need it during, e.g. snapshots)
    
    + convert enzyme tests to RTL (requires using a ref for class methods instead of `.instance()`)
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    22f27c8 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    18ce982 View commit details
    Browse the repository at this point in the history
  12. changelog

    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    2a80790 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    64d3ce5 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    9e68f6f View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    d70c124 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    5d47175 View commit details
    Browse the repository at this point in the history
  17. Fix Storybook control docgen for gridStyle/rowHeightsOptions/`too…

    …lbarVisibility` stories
    
    - for some reason the ref was breaking the docgen??
    
    - we didn't actually need the stateful grid for the ref tests, so just get rid of it
    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    d7d70c2 View commit details
    Browse the repository at this point in the history
  18. Fix Cypress axe test

    cee-chen committed Sep 11, 2024
    Configuration menu
    Copy the full SHA
    456f5ef View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    64f1748 View commit details
    Browse the repository at this point in the history
  20. Configuration menu
    Copy the full SHA
    fb0178c View commit details
    Browse the repository at this point in the history

Commits on Sep 12, 2024

  1. [refactor] avoid render prop + unmemoized array by creating a new fun…

    …ction component
    
    - not sure how much performance this is gaining us (if at all, it might be losing?) so IMO this is primarily a dev readability enhancement
    
    + make a few more props not overrideable via `setCellProps` (& update types)
    
    + write tests for merged `setCellProps` props
    cee-chen committed Sep 12, 2024
    Configuration menu
    Copy the full SHA
    3e6c32b View commit details
    Browse the repository at this point in the history
  2. [a11y] Fix VO not correctly reading out SR text due to newlines in JSX

    - otherwise, it continuously reads out "and 3 more items" instead of the full SR text :/
    cee-chen committed Sep 12, 2024
    Configuration menu
    Copy the full SHA
    7594ac8 View commit details
    Browse the repository at this point in the history
  3. [refactor] remove non-content children out of EuiDataGridCellContent

    - neither the SR text or the cell actions are dependent on the renderCellValue content, and they don't need to be parsed by `HandleInteractiveChildren`, so move them out to the parent EuiDataGridCell
    
    + clean up now-unnecessary waterfalled props
    
    - move screen reader text out to its own function component to continue using useEuiI18n
    cee-chen committed Sep 12, 2024
    Configuration menu
    Copy the full SHA
    bf7853e View commit details
    Browse the repository at this point in the history
  4. [cleanup] Replace hidden attribute with conditional JSX

    cleaner snapshots, less DOM rendered, and and behaves the same way for screen readers, so why not
    cee-chen committed Sep 12, 2024
    Configuration menu
    Copy the full SHA
    f53c710 View commit details
    Browse the repository at this point in the history
  5. [refactor] clean up focus trap aria-describedby text

    - aria-describedby text doesn't need to be visible at all, we can just use `hidden`, which removes it from the copy clipboard
    
    + condense down to a single element
    cee-chen committed Sep 12, 2024
    Configuration menu
    Copy the full SHA
    0b29898 View commit details
    Browse the repository at this point in the history