getgrav / getgrav/grav-plugin-admin

Bug: Hyperlink button in editor misses backspace in headings

Open
#1,625 1 comment 0 reactions 0 assignees View on GitHub
evaluating
Dominant language
PHP
Stars
377
Forks
225
Avg merge
11h 51m
Merged PRs (30d)
4

Description

This is a very small bug, but it's there...

If you highlight a section of existing text and click the hyperlink button, the text gets properly surrounded by brackets and the cursor is placed between the parentheses.

If you highlight a `# Heading` (of any size) and select the heading's text, the formatting is done properly, but the cursor is to the right of the closing parenthesis. This only requires a one-key left arrow workaround, but I thought you'd want to know it's there.

Contributor guide

Open the contributing guide

Research direction

Reproduce the issue in the Grav Admin editor by selecting ordinary text and then heading text before using the hyperlink button. Compare the cursor position after each insertion, and consider the issue complete when heading selections place the cursor consistently inside the link target without the left-arrow workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, markdown
Domain
content, frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.