Skip to content

fix(editor): treat scheme-less hosts as https links - #71

Merged
chasehuh merged 1 commit into
mainfrom
fix/scheme-less-links
Aug 3, 2026
Merged

fix(editor): treat scheme-less hosts as https links#71
chasehuh merged 1 commit into
mainfrom
fix/scheme-less-links

Conversation

@chasehuh

@chasehuh chasehuh commented Aug 3, 2026

Copy link
Copy Markdown
Member

Summary

  • [mobidoo docs](docs.sume.com/…) and bare docs.sume.com/… / www.… did not open because resolveHref only accepted http(s): / mailto: / in-app paths.
  • Prefix https:// for host-like destinations (and https: for //host…); expand bare-link scanning; keep rejecting javascript: and file-like names (README.md).

Test plan

  • pnpm exec vitest run lib/editor/links.test.ts
  • Manual: - [mobidoo docs](docs.sume.com/enterprise/mobidoo) click opens https URL
  • Manual: bare www.example.com clickable; README.md not a link

Made with Cursor

Allow [label](docs.example.com/path), www.…, and bare host.tld URLs to
navigate by prefixing https://, while still rejecting javascript: and
file-like names such as README.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
@vercel

vercel Bot commented Aug 3, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
memo Ready Ready Preview Aug 3, 2026 12:10am

Request Review

@chasehuh
chasehuh merged commit 1aa4a3f into main Aug 3, 2026
2 checks passed
@chasehuh
chasehuh deleted the fix/scheme-less-links branch August 3, 2026 00:10
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