apostrophecms / apostrophecms/apostrophe

Rich-text editor: Internal link autocomplete

Open
#3,714 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
JavaScript
Stars
4.6k
Forks
650
Avg merge
19h 21m
Merged PRs (30d)
23

Description

## Context
I was playing around with ApostropheCMS this morning in order to evaluate if ApostropheCMS could be a good replacement for an old php-based solution I am currently using. (For reference: neos.io) It looks great (Congratulations!), apart from one small detail…

## The problem to solve
A highly used feature of my editors is linking pages and anchors (I saw the official anchor extension!) within other pages‘ content. While this is absolutely possible now, it requires them to
- navigate to the page they want to link
- copy it‘s url
- go back to the page where they want to create the link
- paste the url in the rich-text editors url field.

## Proposed solution
It would be great to have some kind of autocomplete suggestions for internal urls in the rich-text editor.

An example: Assuming there is a page „Lorem Ipsum“ at path /foo/bar/lorem-ipsum. When typing „Lor“ in the url field, there should be a clickable suggestion to select that page and paste its url.

## Alternatives
There seems to be a similar thing for Apostrophe 2.0 with even more functionality: https://github.com/apostrophecms/apostrophe-rich-text-permalinks Maybe it is possible to port that to 3.0? (Although - just from looking at the screenshots - an autocomplete field seems to be easier to use.)

## Additional context
Such an autocomplete for urls could be restricted to pages (+anchors when using that plugin) only or could also work with pieces and maybe even with files. Not sure if this would help or disturb the UX.

Contributor guide

Open the contributing guide

Research direction

Start with the rich-text editor behavior described in the issue and review the referenced apostrophe-rich-text-permalinks project for prior functionality. Done means editors can autocomplete and select internal page URLs while typing, with the supported scope for anchors, pieces, or files clearly established.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
content, frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.