Skip to content

refactor(Pagination): overhaul stories to fix Storybook controls#23

Merged
garrity-miepub merged 1 commit into
mainfrom
feature/pagination-update
Jan 28, 2026
Merged

refactor(Pagination): overhaul stories to fix Storybook controls#23
garrity-miepub merged 1 commit into
mainfrom
feature/pagination-update

Conversation

@garrity-miepub

Copy link
Copy Markdown
Collaborator
  • Replace custom PaginationDemo render functions with args-connected pattern
  • Add PaginationWithState wrapper component that manages internal state
    while passing through all Storybook control props
  • Add proper argTypes for all props:
    • variant: select dropdown (default, outline, ghost)
    • size: select dropdown (sm, md, lg)
    • showFirstLast: boolean toggle
    • showPrevNext: boolean toggle
    • siblingCount: number input with min/max bounds
    • page/totalPages: number inputs
  • Convert all stories to use args objects with ...Default.args spread
  • Add SimplePaginationWithState wrapper for SimplePagination stories
  • Disable controls on showcase stories (AllVariants, AllSizes)

This fixes the docs page where controls were not working because the
previous implementation used render functions that didn't connect
props to Storybook's args system.

pagination-updates.mov

@garrity-miepub garrity-miepub marked this pull request as ready for review January 28, 2026 23:05
@garrity-miepub garrity-miepub merged commit 030ebd3 into main Jan 28, 2026
2 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant