Skip to content

Commit

Permalink
feat(demo): update all tables to have appropriate width that fits the…
Browse files Browse the repository at this point in the history
… data (#1293)

* feat: update the width of columns of tables

* feat: update the width of files tables
  • Loading branch information
bishalshrestha013 authored Dec 16, 2024
1 parent f04be6c commit 5bedefc
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 12 deletions.
12 changes: 6 additions & 6 deletions apps/demo/src/Views/Ui/components/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ export const TableDemo = () => {
{
accessorKey: "name",
header: () => <span>Full name</span>,
width: "10rem",
maxWidth: "10rem",
minWidth: "10rem",
width: "14rem",
maxWidth: "14rem",
minWidth: "14rem",
},
{
accessorKey: "age",
Expand All @@ -51,9 +51,9 @@ export const TableDemo = () => {
{
accessorKey: "city",
header: () => <span>City</span>,
width: "8rem",
maxWidth: "8rem",
minWidth: "8rem",
width: "13rem",
maxWidth: "13rem",
minWidth: "13rem",
},
];

Expand Down
8 changes: 8 additions & 0 deletions apps/demo/src/Views/User/components/InvitationsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,14 @@ export const InvitationsTableDemo = () => {
invitations={invitations}
onInvitationAdded={() => {}}
initialSorting={[{ id: "email", desc: false }]}
columns={[
{
accessorKey: "invitedBy",
maxWidth: "20rem",
minWidth: "20rem",
width: "20rem",
},
]}
/>
</Section>
</Page>
Expand Down
12 changes: 6 additions & 6 deletions packages/ui/src/assets/css/files-table.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
}

.table-files .column-lastDownloadedAt {
max-width: 10rem;
min-width: 10rem;
width: 10rem;
max-width: 12rem;
min-width: 12rem;
width: 12rem;
}

.table-files .column-uploadedAt {
max-width: 10rem;
min-width: 10rem;
width: 10rem;
max-width: 12rem;
min-width: 12rem;
width: 12rem;
}

.table-files .column-uploadedBy {
Expand Down

0 comments on commit 5bedefc

Please sign in to comment.