mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-10 01:19:45 +08:00
11 lines
261 B
JavaScript
11 lines
261 B
JavaScript
|
//= require quill
|
||
|
|
||
|
// Globally overwrite links handling in Quill rich text editor
|
||
|
var Link = Quill.import('formats/link');
|
||
|
Link.sanitize = function(url) {
|
||
|
if (url.includes('http:') || url.includes('https:')) {
|
||
|
return url;
|
||
|
}
|
||
|
return 'http://' + url;
|
||
|
};
|