Enable auto-linking in Markdown

This get's feature-completition to plain-text auto-linking.
Fixes https://github.com/PrivateBin/PrivateBin/issues/336
pull/348/head
rugk 2018-07-01 20:22:21 +02:00
parent 8386141322
commit c1ab1dd8c5
No known key found for this signature in database
GPG Key ID: 05D40A636AFAB34D
3 changed files with 5 additions and 3 deletions

View File

@ -1773,7 +1773,9 @@ jQuery.PrivateBin = (function($, sjcl, Base64, RawDeflate) {
var converter = new showdown.Converter({
strikethrough: true,
tables: true,
tablesHeaderId: true
tablesHeaderId: true,
simplifiedAutoLink: true,
excludeTrailingPunctuationFromURLs: true
});
// let showdown convert the HTML and sanitize HTML *afterwards*!
$plainText.html(

View File

@ -75,7 +75,7 @@ if ($MARKDOWN):
<?php
endif;
?>
<script type="text/javascript" data-cfasync="false" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-w/zjLcgT4cJcMplN6yncy2EDu3+hxuto0Flxwa4ShhK2ceO/JRQJglZXB1lD9TLTf9EnwsHnaqh4dt7dGxiMxA==" crossorigin="anonymous"></script>
<script type="text/javascript" data-cfasync="false" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-0G0kfqJ9im61vY7wBS3UlCjwLvQw8EeNppPy/SWDIuX+2iS6hgM4KbvgTQ6nJwDZPwbsT3R2bPanQKBWKTXcqA==" crossorigin="anonymous"></script>
<!--[if lt IE 10]>
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
<![endif]-->

View File

@ -54,7 +54,7 @@ if ($QRCODE):
<?php
endif;
?>
<script type="text/javascript" data-cfasync="false" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-w/zjLcgT4cJcMplN6yncy2EDu3+hxuto0Flxwa4ShhK2ceO/JRQJglZXB1lD9TLTf9EnwsHnaqh4dt7dGxiMxA==" crossorigin="anonymous"></script>
<script type="text/javascript" data-cfasync="false" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-0G0kfqJ9im61vY7wBS3UlCjwLvQw8EeNppPy/SWDIuX+2iS6hgM4KbvgTQ6nJwDZPwbsT3R2bPanQKBWKTXcqA==" crossorigin="anonymous"></script>
<!--[if lt IE 10]>
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
<![endif]-->