Skip to content

Commit eef229e

Browse files
committed
Make labels optional
1 parent 40f65ca commit eef229e

File tree

3 files changed

+4
-9
lines changed

3 files changed

+4
-9
lines changed

site/src/components/PaginationWidget/PaginationWidget.tsx

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@ import {
1616
} from "./utils"
1717

1818
export type PaginationWidgetProps = {
19-
prevLabel: string
20-
nextLabel: string
19+
prevLabel?: string
20+
nextLabel?: string
2121
numRecords?: number
2222
containerStyle?: CSSProperties
2323
paginationRef: PaginationMachineRef
2424
}
2525

2626
export const PaginationWidget = ({
27-
prevLabel,
28-
nextLabel,
27+
prevLabel="",
28+
nextLabel="",
2929
numRecords,
3030
containerStyle,
3131
paginationRef,
@@ -34,7 +34,6 @@ export const PaginationWidget = ({
3434
const isMobile = useMediaQuery(theme.breakpoints.down("sm"))
3535
const styles = useStyles()
3636
const [paginationState, send] = useActor(paginationRef)
37-
console.log(paginationState.context, paginationState.event)
3837

3938
const [searchParams, _] = useSearchParams()
4039
const currentPage = getInitialPage(searchParams.get("page"))

site/src/pages/WorkspacesPage/WorkspacesPage.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ const WorkspacesPage: FC = () => {
2525
workspacesState.context
2626
const paginationRef = workspacesState.context.paginationRef as PaginationMachineRef
2727

28-
console.log(workspacesState.value, workspacesState.event)
29-
3028
return (
3129
<>
3230
<Helmet>

site/src/pages/WorkspacesPage/WorkspacesPageView.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,6 @@ export const WorkspacesPageView: FC<
108108
/>
109109

110110
<PaginationWidget
111-
prevLabel=""
112-
nextLabel=""
113111
numRecords={count}
114112
paginationRef={paginationRef}
115113
/>

0 commit comments

Comments
 (0)