Skip to content

Commit 527752b

Browse files
Bill LeoutsakosBill Leoutsakos
authored andcommitted
improvement(ui): share inline filter and pagination actions
1 parent 1640556 commit 527752b

2 files changed

Lines changed: 4 additions & 10 deletions

File tree

‎apps/sim/app/workspace/[workspaceId]/components/resource/resource.tsx‎

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -536,12 +536,10 @@ const Pagination = memo(function Pagination({
536536
<Button
537537
key={page}
538538
type='button'
539-
variant='ghost'
539+
variant={page === currentPage ? 'subtle' : 'ghost'}
540+
size='inline'
541+
aria-current={page === currentPage ? 'page' : undefined}
540542
onClick={() => onPageChange(page)}
541-
className={cn(
542-
'h-auto p-0 text-sm hover-hover:bg-transparent hover-hover:text-[var(--text-body)]',
543-
page === currentPage ? 'text-[var(--text-body)]' : ''
544-
)}
545543
>
546544
{page}
547545
</Button>

‎apps/sim/app/workspace/[workspaceId]/knowledge/components/knowledge-filter-heading.tsx‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,7 @@ export function KnowledgeFilterHeading({ title, active, onClear }: KnowledgeFilt
1313
<div className='flex h-5 items-center justify-between'>
1414
<span className={FILTER_SECTION_LABEL_CLASS}>{title}</span>
1515
{active && (
16-
<Button
17-
variant='ghost'
18-
onClick={onClear}
19-
className='-mr-1 h-auto px-1 py-0.5 text-[var(--text-muted)] text-xs hover-hover:text-[var(--text-secondary)]'
20-
>
16+
<Button variant='ghost-secondary' size='inline' onClick={onClear} className='-mr-1'>
2117
Clear
2218
</Button>
2319
)}

0 commit comments

Comments
 (0)