-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
enhancementNew feature or requestNew feature or request
Description
๐ Setup Storybook and Add Stories for TodoItem Dumb Component
๐ Overview
Set up Storybook for the project and create stories for the TodoItem presentational (dumb) component only. The stories should provide comprehensive coverage of all UI states for TodoItem, with no inclusion of business logic or HOC wrapping logic.
๐ฏ Acceptance Criteria
- Storybook is installed and configured to work with the project
-
components/ui/TodoItem/TodoItem.stories.tsxis created with stories forTodoItem - Stories cover all relevant visual and accessibility states:
- Normal (not completed)
- Completed
- Editing mode
- Focused/active states
- Error/boundary states if applicable
- Only the pure
TodoItemis included in Storybook (do not wrap with any HOC logic) - All props are either controlled by Storybook or mocked appropriately
- Storybook build and runs without errors or warnings
๐ง Technical Requirements
- No
anytypes usedโadhere to strict typing for all story props and mocks - Use realistic mock data for
TodoItemstories - Use CSF (Component Story Format) for story definitions
- Minimum: Add a Storybook controls panel for dynamic prop editing/tests
๐ Resources
๐ก Tips
- Separate "dumb" components from "smart"/HOC-wrapped logic in your stories
- Add documentation (short prop descriptions) for every story
- Leverage Storybook controls for props like
isEditing,completed, andeditText
๐ซ Out of Scope
- No stories or coverage for HOC logic (
withTodoItemLogic) - No stories for other components
- No integration into automated CI/CD (manual Storybook build/run only)
- Integration of Storybook's a11y addon
๐๏ธ Acceptance Checklist
- Storybook added and working for the project
-
TodoItem.stories.tsxexists and demonstrates all UI states - All dumb component props are documented
- No HOC or business logic in stories
- Storybook passes lint, types, and accessibility
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request