Skip to content

Commit

Permalink
fix(actions): nicer code
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksasiriski committed Feb 9, 2025
1 parent cc61cdc commit 78ecd58
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
20 changes: 10 additions & 10 deletions src/routes/(dashboard)/columns.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,17 +43,17 @@ export function createColumns(
header: 'State'
},
{
id: 'togglestate',
header: 'Toggle State',
cell: ({ row }) => {
id: 'actions',
header: 'Actions',
cell: ({ row: { original: person } }) => {
return renderComponent(DataTableActions, {
personId: row.original.id,
guarantorFname: row.original.guarantorFname,
guarantorLname: row.original.guarantorLname,
guarantorIdentifier: row.original.guarantorIdentifier,
personType: row.original.type,
personState: row.original.state,
building: row.original.building,
personId: person.id,
guarantorFname: person.guarantorFname,
guarantorLname: person.guarantorLname,
guarantorIdentifier: person.guarantorIdentifier,
personType: person.type,
personState: person.state,
building: person.building,
userBuilding,
toggleStateFormSubmit,
toggleGuestStateFormSubmit,
Expand Down
2 changes: 1 addition & 1 deletion src/routes/(dashboard)/data-table-actions.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
class="w-full"
>
<Handshake />
<span class="sr-only">Show guests</span>
<span class="hidden sm:block">Show guests</span>
</Button>
{/if}
</div>

0 comments on commit 78ecd58

Please sign in to comment.