Skip to content

Commit 2ffb33d

Browse files
committed
improve display of OverflowText elements in tables when printed
1 parent 299073b commit 2ffb33d

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

src/components/Table/table.scss

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -356,3 +356,25 @@ tr.#{$prefix}--parent-row.#{$prefix}--expandable-row + tr[data-child-row] {
356356
min-height: $eccgui-size-tablecell-height-regular;
357357
}
358358
}
359+
360+
@media print {
361+
.#{$eccgui}-simpletable:has(.#{$eccgui}-simpletable__cell > .#{$eccgui}-typography__overflowtext) {
362+
// allow 2 lines of text in `<OverflowText />` elements that are direct children of table cells
363+
.#{$eccgui}-simpletable__cell {
364+
& > .#{$eccgui}-typography__overflowtext,
365+
& > .#{$eccgui}-typography__overflowtext--passdown {
366+
display: inline;
367+
overflow: visible;
368+
text-overflow: unset;
369+
white-space: unset;
370+
}
371+
& > .#{$eccgui}-typography__overflowtext {
372+
display: -webkit-box;
373+
overflow: hidden;
374+
-webkit-line-clamp: 2;
375+
line-clamp: 2;
376+
-webkit-box-orient: vertical;
377+
}
378+
}
379+
}
380+
}

0 commit comments

Comments
 (0)