Skip to content

[codex] Implement editable composer resources#286

Merged
crazygo merged 3 commits into
mainfrom
codex/editable-composer-resources
Jul 3, 2026
Merged

[codex] Implement editable composer resources#286
crazygo merged 3 commits into
mainfrom
codex/editable-composer-resources

Conversation

@crazygo

@crazygo crazygo commented Jul 3, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add composer support for Shift+Enter newline while keeping Enter as send.
  • Add web clipboard image paste handling for the composer and route pasted images through the existing draft image upload flow.
  • Make todo resource previews editable via checkbox updates and refresh the resource list after save.
  • Make note resource previews editable with Markdown formatting controls, edit/preview modes, and Save action.
  • Address review findings: guard async pasted-image callbacks after disposal, keep todo/note editors visible on update failures, and align task docs/code maps with the implemented Markdown editing scope.
  • Move the related task lifecycle files to docs/tasks/done/ and update code maps for the changed feature/test surfaces.

Validation

  • ./tools/init_dev_env.sh
  • dart format apps/mobile_chat_app/lib/features/chat/chat_navigation_page.dart apps/mobile_chat_app/test/chat_navigation_page_test.dart
  • cd apps/mobile_chat_app && flutter test test/composer_bar_test.dart test/chat_navigation_page_test.dart
  • cd apps/mobile_chat_app && flutter analyze
  • cd apps/mobile_chat_app && flutter test -d chrome test/composer_bar_test.dart
  • apps/node_backend/node_modules/.bin/js-yaml docs/code_maps/feature_map.yaml
  • apps/node_backend/node_modules/.bin/js-yaml docs/code_maps/logic_map.yaml
  • git diff --check

Notes

  • This branch was cut from the current local main, so it also contains the prior local task-status cleanup commit 8fc9c74.

@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown

Deployment failed with the following error:

Hobby accounts are limited to daily cron jobs. This cron expression (* * * * *) would run more than once per day. Upgrade to the Pro plan to unlock all Cron Jobs features on Vercel.

Learn More: https://vercel.link/3Fpeeb1

@crazygo crazygo marked this pull request as ready for review July 3, 2026 11:28
Copilot AI review requested due to automatic review settings July 3, 2026 11:28
@crazygo crazygo merged commit 35e3ea8 into main Jul 3, 2026
11 of 14 checks passed
@crazygo crazygo deleted the codex/editable-composer-resources branch July 3, 2026 11:28

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 enhances the Bricks chat composer and Resources UX by adding desktop-friendly keyboard behavior, web clipboard image paste routed through the existing draft upload pipeline, and inline editing for todo/note resource previews. It also updates task lifecycle docs and code maps to reflect the new feature surfaces and regression risks.

Changes:

  • Add Shift+Enter newline insertion while keeping Enter as “send” in the composer, with widget test coverage.
  • Add Flutter Web clipboard image paste handling and connect it to the existing draft image upload flow (with lifecycle safety guards).
  • Make Resources previews editable for todo checkboxes and note Markdown (toolbar + edit/preview + save), including refresh callbacks and widget tests; update tasks + code maps accordingly.

Reviewed changes

Copilot reviewed 15 out of 23 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
docs/tasks/done/2026-07-03-17-41-CST-pr-286-code-review-fixes.md Documents the follow-up review scope and acceptance criteria for PR 286 fixes.
docs/tasks/done/2026-07-03-17-14-CST-task-status-cleanup.md Records the task lifecycle cleanup and validation steps.
docs/tasks/done/2026-07-03-15-47-CST-editable-todo-and-note-resources.md Captures requirements/AC for editable todo + note resources.
docs/tasks/done/2026-07-03-14-54-CST-puzzle-pack-maker-app-shell.md Task moved to done/; referenced by code maps.
docs/tasks/done/2026-07-03-09-58-CST-chat-input-shift-enter-newline.md Task artifact for Shift+Enter behavior.
docs/tasks/done/2026-07-02-12-49-CST-paste-image-upload-flow.md Task artifact for paste-image upload parity with normal uploads.
docs/tasks/done/2026-06-30-16-39-CST-dokku-preview-github-deployment-button.md Task moved to done/; referenced by code maps.
docs/tasks/done/2026-06-30-15-23-CST-flutter-web-static-cache.md Task moved to done/; referenced by code maps.
docs/tasks/done/2026-06-30-15-02-CST-auth-limiter-scope.md Task moved to done/; referenced by code maps.
docs/tasks/done/2026-06-30-14-33-CST-media-fullscreen-download-action.md Task moved to done/; referenced by code maps.
docs/tasks/done/2026-06-30-13-09-CST-media-preview-download-actions.md Task moved to done/; referenced by code maps.
docs/code_maps/logic_map.yaml Updates logic index/doc/test references and change risks for composer paste + Shift+Enter + editable resources.
docs/code_maps/feature_map.yaml Updates product smoke checks and entry paths for Shift+Enter, paste-image upload, and editable resource previews.
apps/mobile_chat_app/test/composer_bar_test.dart Adds widget tests for Shift+Enter newline vs Enter send.
apps/mobile_chat_app/test/chat_navigation_page_test.dart Adds widget tests for todo checkbox editing + note markdown editing/preview/save/failure behavior.
apps/mobile_chat_app/lib/features/chat/widgets/composer_pasted_image.dart Introduces pasted-image payload model + subscription interface.
apps/mobile_chat_app/lib/features/chat/widgets/composer_paste_image.dart Adds conditional-import façade for paste-image listening (web vs stub).
apps/mobile_chat_app/lib/features/chat/widgets/composer_paste_image_web.dart Implements Flutter Web paste listener to extract clipboard images and emit base64 payloads.
apps/mobile_chat_app/lib/features/chat/widgets/composer_paste_image_stub.dart No-op implementation for non-web platforms.
apps/mobile_chat_app/lib/features/chat/widgets/composer_bar.dart Wires paste-image subscription + callback; adds Shortcuts/Actions for Enter vs Shift+Enter.
apps/mobile_chat_app/lib/features/chat/note_api_service.dart Adds updateNote API client method for PATCHing note fields.
apps/mobile_chat_app/lib/features/chat/chat_screen.dart Routes composer pasted-image events into the existing draft upload pipeline with generation/mounted guards.
apps/mobile_chat_app/lib/features/chat/chat_navigation_page.dart Adds editable todo and note resource previews, including markdown toolbar, edit/preview toggle, save, and refresh callback.

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

final items = event.clipboardData?.items;
if (items == null) return;

final itemCount = items.length ?? 0;
Comment on lines +1249 to +1254
child: Column(
crossAxisAlignment: CrossAxisAlignment.stretch,
children: [
for (final line in lines) _MarkdownPreviewLine(line: line),
],
),
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