Skip to content

"Copy link to line (link text from selection)" command fails to add alias if selection contains spaces #41

@churnish

Description

@churnish

Expected Behavior

Selected text is used as alias e.g. [[Note title#^block-id|Hello, world!]]

Current Behavior

The pasted link is missing an alias e.g.[[Note title#^block-id]]

Steps to Reproduce

  1. Select text that contains spaces e.g. Hello, world!
  2. Run "Copy link to line (link text from selection)" command
  3. Paste copied link

Context (Environment)

  • Obsidian version: 1.7.7
  • Carry Forward version: 1.4.5
  • I have tried it with all other plugins disabled and the error still occurs

Possible Solution

Workaround:

  1. Copy selection
  2. Use "Copy link to line (link text from clipboard)" command instead

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions