Feature/create task - #32
Conversation
The mutation selects the same fields as the tasks query so the created task matches the board's shape. The users query feeds the assignee picker in the create modal. Generated types committed per the repo's codegen convention.
The two add-task affordances become real buttons (aria-haspopup=dialog) that open a Figma-matched modal: title input, estimate/assignee/label dropdown chips, and a due-date chip backed by an invisible native date input. Create stays disabled until name, estimate, and due date are set because CreateTaskInput requires them; status defaults to BACKLOG since the design has no status field. On success the tasks query is invalidated so the board refetches; on failure a role=alert banner keeps the modal open with the form intact for retry. The due date is sent as noon UTC so the calendar day survives any timezone. The existing toolbar test assertion moves from img to button role to match the upgrade. Verified live: task created through the UI appears in Backlog with the chosen points, date, tag, and assignee; error path verified by forcing fetch to fail.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThe dashboard now supports responsive task creation with user assignment, estimates, tags, and due dates. It adds GraphQL documents, date-picker components, task icons, avatar URL conversion, accessible toolbar buttons, and updated task-card display behavior. ChangesTask creation and dashboard UI
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant Toolbar
participant CreateTaskModal
participant GraphQL
participant QueryClient
Toolbar->>CreateTaskModal: Open creation modal
CreateTaskModal->>GraphQL: Load users
GraphQL-->>CreateTaskModal: Return user data
CreateTaskModal->>GraphQL: Create task
GraphQL-->>CreateTaskModal: Return created task
CreateTaskModal->>QueryClient: Invalidate task queries
CreateTaskModal-->>Toolbar: Close modal
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (1)
src/app/router.test.tsx (1)
112-112: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winTest the Add task interaction.
Click an
Add taskbutton. Assert that theCreate taskdialog appears. Close the dialog through its accessible close button and assert that it is removed.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/app/router.test.tsx` at line 112, Extend the test around the Add task button query to click an Add task button, assert that the Create task dialog appears, then activate its accessible close button and assert the dialog is removed. Use the existing screen queries and preserve the current assertion that at least one Add task button is rendered.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/features/tasks/CreateTaskModal.tsx`:
- Around line 100-115: Update the CreateTaskModal dialog to trap keyboard focus
within the open modal, preventing Tab navigation to toolbar or page controls.
When the modal closes, restore focus to the invoking Add task button, while
preserving the existing menu-overlay behavior and dialog accessibility
attributes.
- Around line 53-61: Prevent dismissal while task creation is pending by routing
the Escape handler in the useEffect and the modal’s overlay, close button, and
Cancel actions through a shared pending-aware close handler instead of calling
onClose directly. Use the existing createTask mutation pending state, preserving
normal dismissal once the request is no longer pending.
---
Nitpick comments:
In `@src/app/router.test.tsx`:
- Line 112: Extend the test around the Add task button query to click an Add
task button, assert that the Create task dialog appears, then activate its
accessible close button and assert the dialog is removed. Use the existing
screen queries and preserve the current assertion that at least one Add task
button is rendered.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: d00f8d1b-d4bd-4973-8298-b455d990b20d
⛔ Files ignored due to path filters (2)
src/graphql/generated/gql.tsis excluded by!**/generated/**src/graphql/generated/graphql.tsis excluded by!**/generated/**
📒 Files selected for processing (10)
README.mdsrc/app/router.test.tsxsrc/features/tasks/CreateTaskModal.tsxsrc/features/tasks/DatePicker.tsxsrc/features/tasks/TaskCard.tsxsrc/features/tasks/Toolbar.tsxsrc/features/tasks/icons.tsxsrc/features/tasks/queries.tssrc/features/tasks/task-display.tssrc/index.css
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/features/tasks/CreateTaskModal.tsx`:
- Around line 70-92: Update CreateTaskModal’s focus management to capture the
invoking element before autoFocus runs, such as by receiving it from Toolbar,
and restore focus to that element on cleanup. Attach trapFocus to the element
with role="dialog" and query focusable descendants there, excluding the desktop
backdrop button from the trap’s focus cycle.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: ce1c7ce0-fcd7-413a-ae76-4bbefcedea66
📒 Files selected for processing (1)
src/features/tasks/CreateTaskModal.tsx
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. |
Summary by CodeRabbit
New Features
Bug Fixes
Documentation