Skip to content

Commit

Permalink
Clean up/remove various responsive Sass files/modifiers
Browse files Browse the repository at this point in the history
+ remove `.euiTableRowCell--isMobileHeader` - isn't used anywhere that I can tell 🤷
  • Loading branch information
cee-chen committed Mar 26, 2024
1 parent a197141 commit 4bf8c22
Show file tree
Hide file tree
Showing 9 changed files with 6 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ exports[`EuiBasicTable renders (bare-bones) 1`] = `
>
<div>
<table
class="euiTable euiTable--responsive emotion-euiTable-fixed-uncompressed-desktop"
class="euiTable emotion-euiTable-fixed-uncompressed-desktop"
id="__table_generated-id"
tabindex="-1"
>
Expand Down Expand Up @@ -122,7 +122,7 @@ exports[`EuiBasicTable renders (kitchen sink) with pagination, selection, sortin
>
<div>
<table
class="euiTable euiTable--responsive emotion-euiTable-fixed-uncompressed-desktop"
class="euiTable emotion-euiTable-fixed-uncompressed-desktop"
id="__table_generated-id"
tabindex="-1"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ exports[`EuiInMemoryTable empty array 1`] = `
>
<div>
<table
class="euiTable euiTable--responsive emotion-euiTable-fixed-uncompressed-desktop"
class="euiTable emotion-euiTable-fixed-uncompressed-desktop"
id="__table_generated-id"
tabindex="-1"
>
Expand Down Expand Up @@ -199,7 +199,7 @@ exports[`EuiInMemoryTable with items 1`] = `
>
<div>
<table
class="euiTable euiTable--responsive emotion-euiTable-fixed-uncompressed-desktop"
class="euiTable emotion-euiTable-fixed-uncompressed-desktop"
id="__table_generated-id"
tabindex="-1"
>
Expand Down
2 changes: 1 addition & 1 deletion src/components/table/__snapshots__/table.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
exports[`renders EuiTable 1`] = `
<table
aria-label="aria-label"
class="euiTable testClass1 testClass2 euiTable--responsive emotion-euiTable-fixed-uncompressed-desktop-euiTestCss"
class="euiTable testClass1 testClass2 emotion-euiTable-fixed-uncompressed-desktop-euiTestCss"
data-test-subj="test subject string"
tabindex="-1"
>
Expand Down
3 changes: 0 additions & 3 deletions src/components/table/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,3 @@
@import 'mixins';

@import 'table';
@import 'responsive';

@import 'mobile/index';
Empty file.
4 changes: 0 additions & 4 deletions src/components/table/_table.scss
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,6 @@
&--baseline {
vertical-align: baseline;
}

&.euiTableRowCell--isMobileHeader {
display: none; // Hide if not mobile breakpoint
}
}

.euiTableRowCellCheckbox {
Expand Down
1 change: 0 additions & 1 deletion src/components/table/mobile/_index.scss

This file was deleted.

Empty file.
4 changes: 1 addition & 3 deletions src/components/table/table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@ export const EuiTable: FunctionComponent<EuiTableProps> = ({
// TODO: Make the table responsive breakpoint customizable via prop
const isResponsive = useIsWithinMaxBreakpoint('s') && responsive;

const classes = classNames('euiTable', className, {
'euiTable--responsive': responsive,
});
const classes = classNames('euiTable', className);

const styles = useEuiMemoizedStyles(euiTableStyles);
const cssStyles = [
Expand Down

0 comments on commit 4bf8c22

Please sign in to comment.