8000 fix(notes): keep typing when a thing's page is first saved, and open only web links by adeelahmad · Pull Request #124 · adeelahmad/lense · GitHub
[go: up one dir, main page]

Skip to content

fix(notes): keep typing when a thing's page is first saved, and open only web links - #124

Merged
adeelahmad merged 1 commit into
mainfrom
claude/notes-module-j9j30y
Oct 4, 2026
Merged

adeelahmad merged 1 commit into
mainfrom
claude/notes-module-j9j30y

Conversation

@adeelahmad
Copy link
Copy Markdown
Owner

Description

Before: on the page of a recording or entity, the first save turned the draft into a page and remounted the editor. Text typed while that request was in flight was lost, and the title, summary, date and place snapped back. A Markdown link with any scheme, such as javascript:, also opened when clicked.

After: the editor and form stay put across the first save. Clicking a link in a note opens only http(s) and mailto addresses, plus Lens links, which open in the app.

Motivation and Context

Review finding on #122. The editor and form were keyed on page.id, which changes on the first save. They are now keyed on what the page is about, or on its id for a free note. BlockSuite 0.19.5 renders the href from the delta unchecked, and the assistant can write note Markdown, so the editor's capture-phase click handler now blocks other schemes on click and middle-click.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change; ! in the title)

Checklist:

  • The title is a Conventional Commit.
  • My code follows the code style of this project (make hooks checks it on commit).
  • I added or updated tests.
  • My change requires documentation updates, and I have updated docs/ accordingly.
  • Users need more than the title to understand it, so I wrote it under ## Unreleased in CHANGELOG.md.

Checked locally: tsc and eslint pass.

🤖 Generated with Claude Code

https://claude.ai/code/session_01XZQXJtCvJgbG1Z2H312KcS


Generated by Claude Code

…only web links

The editor and form were keyed on the page id, so the first save of a
recording's or entity's page remounted them and lost what was typed
meanwhile. Key on what the page is about instead. BlockSuite renders any
href from the Markdown, so links other than http(s), mailto and Lens
links no longer open.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XZQXJtCvJgbG1Z2H312KcS
@adeelahmad
adeelahmad merged commit 432b756 into main Oct 4, 2026
0 of 5 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

0