Skip to content

Commit 30f07b1

Browse files
committed
[build] 4.5.9
1 parent 4157173 commit 30f07b1

File tree

5 files changed

+21
-16
lines changed

5 files changed

+21
-16
lines changed

docs/_coverpage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
![logo](_media/icon.svg)
22

3-
# docsify <small>4.5.8</small>
3+
# docsify <small>4.5.9</small>
44

55
> A magical documentation site generator.
66

lib/docsify.js

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -578,6 +578,7 @@ var marked = createCommonjsModule(function (module, exports) {
578578
*/
579579

580580
(function() {
581+
'use strict';
581582

582583
/**
583584
* Block-Level Grammar
@@ -612,6 +613,10 @@ block.list = replace(block.list)
612613
('def', '\\n+(?=' + block.def.source + ')')
613614
();
614615

616+
block.blockquote = replace(block.blockquote)
617+
('def', block.def)
618+
();
619+
615620
block._tag = '(?!(?:'
616621
+ 'a|em|strong|small|s|cite|q|dfn|abbr|data|time|code'
617622
+ '|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo'
@@ -1020,9 +1025,9 @@ Lexer.prototype.token = function(src, top, bq) {
10201025

10211026
var inline = {
10221027
escape: /^\\([\\`*{}\[\]()#+\-.!_>])/,
1023-
autolink: /^<([^ >]+(@|:\/)[^ >]+)>/,
1028+
autolink: /^<([^ <>]+(@|:\/)[^ <>]+)>/,
10241029
url: noop,
1025-
tag: /^<!--[\s\S]*?-->|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,
1030+
tag: /^<!--[\s\S]*?-->|^<\/?\w+(?:"[^"]*"|'[^']*'|[^<'">])*?>/,
10261031
link: /^!?\[(inside)\]\(href\)/,
10271032
reflink: /^!?\[(inside)\]\s*\[([^\]]*)\]/,
10281033
nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,
@@ -1034,7 +1039,7 @@ var inline = {
10341039
text: /^[\s\S]+?(?=[\\<!\[_*`]| {2,}\n|$)/
10351040
};
10361041

1037-
inline._inside = /(?:\[[^\]]*\]|[^\[\]]|\](?=[^\[]*\]))*/;
1042+
inline._inside = /(?:\[[^\]]*\]|\\[\[\]]|[^\[\]]|\](?=[^\[]*\]))*/;
10381043
inline._href = /\s*<?([\s\S]*?)>?(?:\s+['"]([\s\S]*?)['"])?\s*/;
10391044

10401045
inline.link = replace(inline.link)
@@ -1448,10 +1453,10 @@ Renderer.prototype.link = function(href, title, text) {
14481453
.replace(/[^\w:]/g, '')
14491454
.toLowerCase();
14501455
} catch (e) {
1451-
return '';
1456+
return text;
14521457
}
14531458
if (prot.indexOf('javascript:') === 0 || prot.indexOf('vbscript:') === 0 || prot.indexOf('data:') === 0) {
1454-
return '';
1459+
return text;
14551460
}
14561461
}
14571462
if (this.options.baseUrl && !originIndependentUrl.test(href)) {
@@ -1720,15 +1725,15 @@ function resolveUrl(base, href) {
17201725
base = baseUrls[' ' + base];
17211726

17221727
if (href.slice(0, 2) === '//') {
1723-
return base.replace(/:[^]*/, ':') + href;
1728+
return base.replace(/:[\s\S]*/, ':') + href;
17241729
} else if (href.charAt(0) === '/') {
1725-
return base.replace(/(:\/*[^/]*)[^]*/, '$1') + href;
1730+
return base.replace(/(:\/*[^/]*)[\s\S]*/, '$1') + href;
17261731
} else {
17271732
return base + href;
17281733
}
17291734
}
1730-
baseUrls = {};
1731-
originIndependentUrl = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
1735+
var baseUrls = {};
1736+
var originIndependentUrl = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
17321737

17331738
function noop() {}
17341739
noop.exec = noop;
@@ -1833,7 +1838,7 @@ function marked(src, opt, callback) {
18331838
} catch (e) {
18341839
e.message += '\nPlease report this to https://github.com/chjj/marked.';
18351840
if ((opt || marked.defaults).silent) {
1836-
return '<p>An error occured:</p><pre>'
1841+
return '<p>An error occurred:</p><pre>'
18371842
+ escape(e.message + '', true)
18381843
+ '</pre>';
18391844
}
@@ -4092,7 +4097,7 @@ initGlobalAPI();
40924097
/**
40934098
* Version
40944099
*/
4095-
Docsify.version = '4.5.8';
4100+
Docsify.version = '4.5.9';
40964101

40974102
/**
40984103
* Run Docsify

lib/docsify.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/docsify-server-renderer/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/docsify-server-renderer/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "docsify-server-renderer",
3-
"version": "4.5.8",
3+
"version": "4.5.9",
44
"description": "docsify server renderer",
55
"author": {
66
"name": "qingwei-li",

0 commit comments

Comments
 (0)