Skip to content

About

Turn selected text into a Markdown link by pasting a URL in Flarum's default composer.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

7 Commits

Folders and files

Repository files navigation

FFans Paste Link

License Flarum Version Release Date Total Downloads Monthly Downloads

A Flarum extension. Turns selected text into a Markdown link when paste a URL. This is a tiny quality-of-life enhancement for the default Markdown composer. No settings, no permissions, just one paste listener inside the default composer.

FoF Rich Text for Flarum 2.x provides similar paste-link behavior as part of its full rich-text editing experience. Paste Link is intended for communities that prefer default Markdown composer or still run Flarum 1.x.

Features

Select Flarum then paste https://flarum.org, results:

[Flarum](https://flarum.org)

Rules

Use the same behavior of JetBrains IDEA, avoid wrapping selections that overlap recognized inline Markdown links, images, or plain links.

e.g.

  • ^ marks the selected characters.
  • ✅️ means the selection will convert into a Markdown link.
  • ❌️ means the extension leaves the paste to the editor's default behavior.
[Flarum](https://flarum.org) ❌️
^^^^^^

abc [Flarum](https://flarum.org) xyz ❌️
^^^^^^^^^^^^^

def opq ✅️
^^^

https://jetbrains.com/abc.html ❌️
^^^^^^^^^^^^

www.jetbrains.com/abc.html ❌️
^^^^^^^^^^^^

jetbrains.com/abc.html ✅️
^^^^^^

Requirements

Flarum Extension Version Branch
2.x 1.0.0 main
1.8 1.0.0 main

Installation

Install with Composer:

composer require ffans/paste-link:"*"

Updating

composer update ffans/paste-link
php flarum cache:clear

Links

License

MIT.

About

Turn selected text into a Markdown link by pasting a URL in Flarum's default composer.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages