Skip to content

feat: markdown toolbar and AI-assisted note proofreading - #1

Merged
yattdev merged 3 commits into
mainfrom
feature/enhance-the-note-tak-xoj
Aug 9, 2026
Merged

feat: markdown toolbar and AI-assisted note proofreading#1
yattdev merged 3 commits into
mainfrom
feature/enhance-the-note-tak-xoj

Conversation

@yattdev

@yattdev yattdev commented Aug 8, 2026

Copy link
Copy Markdown
Owner

Overview

Enhances the Note Taking plugin's note editor with markdown formatting, a formatting toolbar, AI-assisted proofreading, and a fixed-size scrollable modal.

Changes

  • Replaced the plain <textarea>-only note editing surface with a unified markdown-capable editor (shared by both the task panel and kanban modal) backed by a MarkdownToolbar component supporting bold, italic, headings, bullet/numbered lists, links, inline code, and code blocks.
  • Added an "Enhance with AI" button that POSTs note content to a new enhance webhook, following the same request/loading/error UX pattern as the existing "enhance prompt" feature; results are shown via a preview/accept/discard flow (enhancePreviewReducer).
  • Implemented backend HandleWebhook support for the enhance key in server/plugin.go, invoking the configured utility agent to proofread note content, with proper HTTP status mapping (400 bad input, 412 not configured, 502 other errors, 503 missing host).
  • Updated manifest.yaml to declare capabilities.agent_invoke, the enhance webhook, and the utility_agent config schema; bumped plugin version to 0.2.0 (Makefile updated to match).
  • Fixed the note edit modal to a constrained height (70vh, overflow: hidden) with overflow-y: auto on the note content textarea, so the modal no longer grows/overflows as content is typed.
  • Extended Go and JS unit tests to cover the new webhook handler, manifest fields, markdown transforms, AI enhance client, and preview reducer; QA follow-up fix (a1c18cd) addressed toolbar list-formatting behavior on blank notes.
  • Updated README.md to document the new features and the privacy trade-off of sending note content to an AI utility agent.

Motivation

The existing notes editor only supported plain text, requiring manual markdown syntax knowledge with no formatting affordances, and had no way to proofread/improve note content with AI — unlike the existing "enhance prompt" feature elsewhere in the app. The modal also grew unbounded and overflowed the screen as users typed.

Testing

  • go test ./server/... — all tests pass (19/19), including new webhook and manifest tests.
  • node --test "ui/**/*.test.mjs" — all tests pass (49/49), including new transform/toolbar/AI-client/reducer tests.
  • gofmt -l . and go vet ./server/... — clean.
  • make package-host — verified the 0.2.0 plugin tarball builds and packages correctly.
  • QA rerun performed a focused pass on behavior/error paths plus a full make test run; no unresolved findings, worktree clean.

Breaking Changes

None. The stored note format remains markdown-compatible plain text; existing notes continue to render and edit correctly in the new editor.

Related Issues

N/A

ayattara-sfl and others added 2 commits August 8, 2026 06:13
…te modal

- Unify the task panel and kanban modal on one markdown editor: drop the
  editorKind/host.ui.RichTextEditor branch (NotesEditor now always renders
  a scrollable markdown <textarea>, sidestepping the modal's ToastProvider
  gap for both surfaces).
- Add a formatting toolbar (bold, italic, heading, bullet/numbered list,
  link, inline code, code block) backed by pure, unit-tested markdown
  transform helpers (applyBold/Italic/Heading/BulletList/NumberedList/
  Link/InlineCode/CodeBlock).
- Add an "Enhance with AI" button (both surfaces) that POSTs the note's
  markdown to a new `enhance` plugin webhook, previews the proofread
  result, and only replaces the note on Accept (Discard leaves it
  untouched) — enhancePreviewReducer models idle/loading/preview/error.
- server/plugin.go: implement HandleWebhook for the "enhance" key via
  Host.InvokeUtilityAgent, mapping gRPC FailedPrecondition (no utility
  agent configured) to a distinguishable 412 response.
- manifest.yaml: declare capabilities.agent_invoke, the enhance webhook,
  and a config_schema.utility_agent picker; bump version to 0.2.0 (and
  Makefile VERSION in lockstep).
- Fix the note modal to a constrained height (was min-height, which let
  it grow unbounded) with an internally scrolling (overflow-y: auto)
  textarea.
- README: document the toolbar, AI enhance feature, and the privacy
  trade-off of sending note content to the configured utility agent.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@yattdev

yattdev commented Aug 8, 2026

Copy link
Copy Markdown
Owner Author

@claude review

go mod tidy moved google.golang.org/grpc from an indirect to a direct
require, matching the CI "Check module files are tidy" step.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@yattdev
yattdev marked this pull request as ready for review August 8, 2026 06:39
@yattdev
yattdev merged commit 04ad9d5 into main Aug 9, 2026
3 checks passed
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