Skip to content

Feature/create task - #32

Merged
Alejandroq12 merged 6 commits into
devfrom
feature/create-task
Aug 7, 2026
Merged

Feature/create task#32
Alejandroq12 merged 6 commits into
devfrom
feature/create-task

Conversation

@Alejandroq12

@Alejandroq12 Alejandroq12 commented Aug 7, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • New Features

    • Added task creation from desktop and mobile toolbars.
    • Added estimate, label, assignee, due-date, and validation support.
    • Added calendar date selection with month navigation and a Today shortcut.
    • Added user and avatar support for task assignments.
    • Added responsive layouts, focus management, and creation error alerts.
  • Bug Fixes

    • Updated assignee avatars for improved compatibility.
    • Removed unsupported attachment, fork, and comment indicators.
    • Improved accessibility by exposing add-task controls as buttons.
  • Documentation

    • Updated task card icon documentation.

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.
@coderabbitai

coderabbitai Bot commented Aug 7, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 48af4322-3a60-4012-9095-e17eee2f56d2

📥 Commits

Reviewing files that changed from the base of the PR and between 9c03b33 and 6580a1c.

📒 Files selected for processing (1)
  • src/features/tasks/CreateTaskModal.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/features/tasks/CreateTaskModal.tsx

📝 Walkthrough

Walkthrough

The 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.

Changes

Task creation and dashboard UI

Layer / File(s) Summary
Shared task display and controls
src/features/tasks/icons.tsx, src/features/tasks/task-display.ts, src/features/tasks/TaskCard.tsx, README.md, src/index.css
The task interface adds selection and navigation icons, exports point estimates, converts legacy DiceBear avatar URLs, removes unsupported task-card icons, and adds typography tokens.
Date selection components
src/features/tasks/DatePicker.tsx
Desktop and dialog date pickers support calendar navigation, date selection, Today, Cancel, and OK actions.
Task creation modal
src/features/tasks/queries.ts, src/features/tasks/CreateTaskModal.tsx
The modal loads users, manages task fields, validates input, submits task creation through GraphQL, invalidates task queries, and displays errors.
Toolbar integration and test contract
src/features/tasks/Toolbar.tsx, src/app/router.test.tsx
Desktop and mobile add-task controls open the modal as buttons. The dashboard test checks the button role.

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
Loading

Possibly related PRs

Suggested labels: ui

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the main change: adding task creation functionality.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/create-task

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (1)
src/app/router.test.tsx (1)

112-112: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Test the Add task interaction.

Click an Add task button. Assert that the Create task dialog 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

📥 Commits

Reviewing files that changed from the base of the PR and between 82a74a6 and 75be877.

⛔ Files ignored due to path filters (2)
  • src/graphql/generated/gql.ts is excluded by !**/generated/**
  • src/graphql/generated/graphql.ts is excluded by !**/generated/**
📒 Files selected for processing (10)
  • README.md
  • src/app/router.test.tsx
  • src/features/tasks/CreateTaskModal.tsx
  • src/features/tasks/DatePicker.tsx
  • src/features/tasks/TaskCard.tsx
  • src/features/tasks/Toolbar.tsx
  • src/features/tasks/icons.tsx
  • src/features/tasks/queries.ts
  • src/features/tasks/task-display.ts
  • src/index.css

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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

📥 Commits

Reviewing files that changed from the base of the PR and between 75be877 and 9c03b33.

📒 Files selected for processing (1)
  • src/features/tasks/CreateTaskModal.tsx

@vercel

vercel Bot commented Aug 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
task-flow Ready Ready Preview Aug 7, 2026 5:46pm

Repository owner deleted a comment from coderabbitai Bot Aug 7, 2026
Repository owner deleted a comment from coderabbitai Bot Aug 7, 2026
Repository owner deleted a comment from coderabbitai Bot Aug 7, 2026
@Alejandroq12
Alejandroq12 merged commit 073ded4 into dev Aug 7, 2026
5 checks passed
@claude

claude Bot commented Aug 7, 2026

Copy link
Copy Markdown

Code review

No issues found. Checked for bugs and CLAUDE.md compliance.

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