russross / blackfriday

Blackfriday: a markdown processor for Go
Other
5.45k stars 602 forks source link

parse bitcoin uri's as links #692

Open t-900-a opened 3 years ago

t-900-a commented 3 years ago

when parsing markdown and rendering it into html bitcoin and monero uri's are not rendered as a link

example markdown [donate](monero:83UXh3SQZGk63yCWA8cQcQFrYL6xat3aNASZcz7USgy94neK8proFxU1BJhxr4PWNPJy1ScKX2oxy6TX3BmcGJk67JbJmXG) current output <a target="_blank" rel="noopener">donate</a> desired output <a target="monero:83UXh3SQZGk63yCWA8cQcQFrYL6xat3aNASZcz7USgy94neK8proFxU1BJhxr4PWNPJy1ScKX2oxy6TX3BmcGJk67JbJmXG" rel="noopener">donate</a>

https://www.iana.org/assignments/uri-schemes/prov/bitcoin

For a live example see: https://bounties.monero.social/posts/3/twitter-bot-for-comit-btc-atomic-swaps

plowsof commented 3 years ago

Just add the custom uri's here (posting here for visibility) https://github.com/russross/blackfriday/blob/e96880f42b9343aea6cbfd99693adae0e5fe2b2a/inline.go#L824

elibroftw commented 2 years ago

Can you guys just fork black Friday and then fork fider to use your forked black Friday. Then you don't have to wait for a dead project to be revived.