Skip to content

refactor(OrderList.stories): use Badge component and add Storybook co…#66

Merged
garrity-miepub merged 2 commits intomainfrom
feature/orderlist-stories-refactor
Feb 3, 2026
Merged

refactor(OrderList.stories): use Badge component and add Storybook co…#66
garrity-miepub merged 2 commits intomainfrom
feature/orderlist-stories-refactor

Conversation

@garrity-miepub
Copy link
Copy Markdown
Contributor

…ntrols

Component Integration:

  • Replace custom status badge styling with Badge component (variant mapping)
  • Use CSS variables for container styling (border-border, bg-background, bg-muted)
  • Button component already in use for actions

Storybook Controls:

  • Add comprehensive argTypes for all props with descriptions
  • Add control types (boolean, text) for interactive props
  • Add component-level documentation description
  • Add story-level descriptions for each variant

Stories Updated:

  • Default, WithSearch, WithActions, WithSearchAndActions
  • SimpleTabs, Loading, Empty, CustomEmptyIcon
  • All stories now have parameter docs descriptions
order-list.mov

…ntrols

Component Integration:
- Replace custom status badge styling with Badge component (variant mapping)
- Use CSS variables for container styling (border-border, bg-background, bg-muted)
- Button component already in use for actions

Storybook Controls:
- Add comprehensive argTypes for all props with descriptions
- Add control types (boolean, text) for interactive props
- Add component-level documentation description
- Add story-level descriptions for each variant

Stories Updated:
- Default, WithSearch, WithActions, WithSearchAndActions
- SimpleTabs, Loading, Empty, CustomEmptyIcon
- All stories now have parameter docs descriptions
Copilot AI review requested due to automatic review settings February 3, 2026 23:12
@garrity-miepub garrity-miepub marked this pull request as ready for review February 3, 2026 23:12
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the OrderList Storybook stories to use the shared Badge component, align styling with the design system tokens, and enhance Storybook documentation/controls for OrderList.

Changes:

  • Integrates the design-system Badge component into the OrderItem renderer, using a status-to-variant mapping consistent with OrderCard.
  • Updates container and text styling to use semantic design tokens (bg-background, text-foreground, text-muted-foreground, border-border, bg-muted/50) instead of hardcoded Tailwind gray scale classes.
  • Adds Storybook docs metadata and argTypes for all OrderList props, including actions for callbacks and descriptive documentation for each story variant.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…ayout fixes

Stories refactoring:
- Add Badge component integration with status-to-variant mapping
- Add comprehensive argTypes with descriptions for all props
- Create PlaygroundDemo wrapper for proper hook usage with Storybook args
- Update Default story to use args pattern so controls work on docs page
- Add default args (showSearch, isLoading, emptyMessage, searchPlaceholder)

Component improvements:
- Add h-full to root container for proper flex layout and scrolling
- Change header padding from pb-4 to py-4 for equal top/bottom spacing
- Tabs now stay fixed while order list scrolls independently

UI polish:
- Change action button to ghost variant
- Simplify button label to '+ New' with whitespace-nowrap
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages bot commented Feb 3, 2026

Deploying ui with  Cloudflare Pages  Cloudflare Pages

Latest commit: dc18c5b
Status: ✅  Deploy successful!
Preview URL: https://cd431d7b.ui-6d0.pages.dev
Branch Preview URL: https://feature-orderlist-stories-re.ui-6d0.pages.dev

View logs

@garrity-miepub garrity-miepub merged commit cca1a77 into main Feb 3, 2026
10 checks passed
@garrity-miepub garrity-miepub deleted the feature/orderlist-stories-refactor branch February 3, 2026 23:20
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.

2 participants