Browse Source

Revert "Re-enables custom schemes auto linking" https://github.com/wekan/wekan/pull/4059 because Markdown links did not work, commented out some code.

Thanks to mfilser and xet7 !

Related https://github.com/wekan/wekan/pull/4059
Lauri Ojansivu 3 years ago
parent
commit
a3d41c560b
2 changed files with 2 additions and 9 deletions
  1. 0 2
      CHANGELOG.md
  2. 2 7
      packages/markdown/src/template-integration.js

+ 0 - 2
CHANGELOG.md

@@ -60,8 +60,6 @@ and fixes the following bugs:
   Thanks to mfilser and xet7.
 - [Long labels on card and minicard are wrapped if too long](https://github.com/wekan/wekan/pull/4073).
   Thanks to mfilser.
-- [Re-enables custom schemes auto linking](https://github.com/wekan/wekan/pull/4059).
-  Thanks to chrisi51.
 - [Card dates, if deleted rules didn't apply on "unset date fields"](https://github.com/wekan/wekan/pull/4075).
   Thanks to mfilser.
 - [Comment, added confirm delete popup](https://github.com/wekan/wekan/pull/4077).

+ 2 - 7
packages/markdown/src/template-integration.js

@@ -9,6 +9,7 @@ var Markdown = require('markdown-it')({
 
 import markdownItMermaid from "@wekanteam/markdown-it-mermaid";
 
+/*
 
 // Static URL Scheme Listing
 var urlschemes = [
@@ -22,10 +23,6 @@ var urlschemes = [
   "mailspring"
 ];
 
-
-
-
-
 // Better would be a field in the admin backend to set this dynamically
 // instead of putting all known or wanted url schemes here hard into code
 // but i was not able to access those settings
@@ -38,6 +35,7 @@ for(var i=0; i<urlschemes.length;i++){
 }
 
 
+
 // build fitting regex
 var regex = RegExp('^(' + urlschemes.join('|') + '):', 'gim');
 
@@ -70,9 +68,6 @@ DOMPurify.addHook('afterSanitizeAttributes', function (node) {
 });
 
 
-
-
-/*
 // Additional  safeAttrValue function to allow for other specific protocols
 // See https://github.com/leizongmin/js-xss/issues/52#issuecomment-241354114
 function mySafeAttrValue(tag, name, value, cssFilter) {