Skip to content

Commit

Permalink
Revert responsive behaviour of tables
Browse files Browse the repository at this point in the history
  • Loading branch information
kudlajz committed Jul 9, 2024
1 parent a1287e3 commit a142ebf
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 16 deletions.
7 changes: 0 additions & 7 deletions src/elements/Table/Table.scss
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
@import "styles/variables";

.prezly-slate-table-container {
width: 100%;
overflow-x: auto;
}

.prezly-slate-table {
width: 100%;
max-width: 100%;
border-collapse: collapse;
table-layout: auto;

Expand All @@ -31,7 +25,6 @@
outline: none !important;
text-align: left;
vertical-align: middle;
white-space: nowrap;

> *:first-child {
margin-top: 0;
Expand Down
16 changes: 7 additions & 9 deletions src/elements/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,13 @@ interface Props extends HTMLAttributes<HTMLTableElement> {
export function Table({ children, node }: Props) {
return (
<TableContextProvider table={node}>
<div className="prezly-slate-table-container">
<table
className={classNames('prezly-slate-table', {
'prezly-slate-table--withBorders': node.border,
})}
>
<tbody>{children}</tbody>
</table>
</div>
<table
className={classNames('prezly-slate-table', {
'prezly-slate-table--withBorders': node.border,
})}
>
<tbody>{children}</tbody>
</table>
</TableContextProvider>
);
}

0 comments on commit a142ebf

Please sign in to comment.