Skip to content

Commit

Permalink
scroll
Browse files Browse the repository at this point in the history
Signed-off-by: Miki <[email protected]>
  • Loading branch information
AMoo-Miki committed Jan 31, 2024
1 parent 7b896aa commit 71143df
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,17 @@ doc-table {
.osdDiscoverTable {
@include ouiCodeFont;

tr:not(.osdDiscoverInViewRow) {
& > tbody > tr:not(.osdDiscoverInViewRow):not(.osdDiscoverExpandedRow) {
visibility: hidden;
}

.osdDiscoverExpandedRow {
background: $euiColorEmptyShade;

& > td {
padding: 2em;
}
}
}

.osdDocTable__row {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,10 @@ export const LegacyDiscoverTable = ({
});
}, options);

const tableRows = (tableRef.current! as HTMLTableElement).rows;
Array.from(tableRows).forEach((el: HTMLTableRowElement) => {
const tableRows = (tableRef.current! as HTMLTableElement).querySelectorAll(
'tr:not(.osdDiscoverExpandedRow)'
);
tableRows.forEach((el) => {
observer.observe(el);
});

Expand Down

0 comments on commit 71143df

Please sign in to comment.