mirror of
https://github.com/wahyd4/docsify.git
synced 2026-08-24 12:46:08 +10:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9c62fb41b8 | ||
|
|
9b73b0bf8a | ||
|
|
9d43051791 | ||
|
|
f0aca1905c | ||
|
|
2959497874 | ||
|
|
5a9921f5e7 | ||
|
|
c9d556d829 | ||
|
|
a0e1ea811a | ||
|
|
f82f41900e | ||
|
|
7a4d9bc5cd | ||
|
|
5e522879dd | ||
|
|
a72e7a3a3f | ||
|
|
26c22a9843 | ||
|
|
4ce118d60f | ||
|
|
3ad1645b90 | ||
|
|
41967fa8fa | ||
|
|
48276db15d | ||
|
|
b67ea62c75 | ||
|
|
f4800e09f1 | ||
|
|
ac10de1c5b | ||
|
|
d6ac7031b0 | ||
|
|
4417f4669d | ||
|
|
b7735066ff | ||
|
|
10045249d3 | ||
|
|
190710733e | ||
|
|
b292d819fc | ||
|
|
7f270f93c6 | ||
|
|
c3a149679a | ||
|
|
5efa763075 | ||
|
|
03a04f7898 | ||
|
|
a88252c6b2 | ||
|
|
2f5f90750a | ||
|
|
709c152950 | ||
|
|
b09a5a317e | ||
|
|
628e2115a3 | ||
|
|
271dde8f5e | ||
|
|
1fa1619278 | ||
|
|
3de3def8a8 | ||
|
|
fb25726426 | ||
|
|
36ddc42e91 | ||
|
|
abb0f6019f | ||
|
|
b8dd346baf | ||
|
|
7191d702e1 | ||
|
|
c039f1bfc0 |
+108
@@ -1,3 +1,111 @@
|
|||||||
|
<a name="4.3.3"></a>
|
||||||
|
## [4.3.3](https://github.com/QingWei-Li/docsify/compare/v4.3.2...v4.3.3) (2017-09-06)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **buble.css:** tweaks code block style, fixed [#249](https://github.com/QingWei-Li/docsify/issues/249) ([9d43051](https://github.com/QingWei-Li/docsify/commit/9d43051))
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* add doc for react and vue demo box plugin ([#247](https://github.com/QingWei-Li/docsify/issues/247)) ([f0aca19](https://github.com/QingWei-Li/docsify/commit/f0aca19))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.3.2"></a>
|
||||||
|
## [4.3.2](https://github.com/QingWei-Li/docsify/compare/v4.3.1...v4.3.2) (2017-09-01)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* sidebar highlight ([f82f419](https://github.com/QingWei-Li/docsify/commit/f82f419))
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* add Edit on github plugin (thanks [@njleonzhang](https://github.com/njleonzhang)) ([a0e1ea8](https://github.com/QingWei-Li/docsify/commit/a0e1ea8))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.3.1"></a>
|
||||||
|
## [4.3.1](https://github.com/QingWei-Li/docsify/compare/v4.2.9...v4.3.1) (2017-08-30)
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* **markdown:** supports mermaid [#137](https://github.com/QingWei-Li/docsify/issues/137) ([f4800e0](https://github.com/QingWei-Li/docsify/commit/f4800e0))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.3.0"></a>
|
||||||
|
# [4.3.0](https://github.com/QingWei-Li/docsify/compare/v4.2.9...v4.3.0) (2017-08-17)
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* **markdown:** supports mermaid [#137](https://github.com/QingWei-Li/docsify/issues/137) ([f4800e0](https://github.com/QingWei-Li/docsify/commit/f4800e0))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.2.9"></a>
|
||||||
|
## [4.2.9](https://github.com/QingWei-Li/docsify/compare/v4.2.8...v4.2.9) (2017-08-15)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* ensure document ready before init Docsify [#233](https://github.com/QingWei-Li/docsify/issues/233)
|
||||||
|
|
||||||
|
<a name="4.2.8"></a>
|
||||||
|
## [4.2.8](https://github.com/QingWei-Li/docsify/compare/v4.2.7...v4.2.8) (2017-08-10)
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* **compiler:** support for setting target attribute for link, fixed [#230](https://github.com/QingWei-Li/docsify/issues/230) ([7f270f9](https://github.com/QingWei-Li/docsify/commit/7f270f9))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.2.7"></a>
|
||||||
|
## [4.2.7](https://github.com/QingWei-Li/docsify/compare/v4.2.4...v4.2.7) (2017-08-05)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **release:** release shell ([628e211](https://github.com/QingWei-Li/docsify/commit/628e211))
|
||||||
|
* **style:** nowrap => pre-wrap, fixed [#228](https://github.com/QingWei-Li/docsify/issues/228) ([a88252c](https://github.com/QingWei-Li/docsify/commit/a88252c))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.2.6"></a>
|
||||||
|
## [4.2.6](https://github.com/QingWei-Li/docsify/compare/v4.2.4...v4.2.6) (2017-07-27)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **css:** hide the nav when the content has not yet been loaded ([1fa1619](https://github.com/QingWei-Li/docsify/commit/1fa1619))
|
||||||
|
* **release:** release shell ([628e211](https://github.com/QingWei-Li/docsify/commit/628e211))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="4.2.4"></a>
|
||||||
|
## [4.2.4](https://github.com/QingWei-Li/docsify/compare/v4.2.2...v4.2.4) (2017-07-26)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **render:** Remove getRootNode to be compatible with the lower version of Chrome, fixed [#225](https://github.com/QingWei-Li/docsify/issues/225) ([b8dd346](https://github.com/QingWei-Li/docsify/commit/b8dd346))
|
||||||
|
|
||||||
|
<a name="4.2.3"></a>
|
||||||
|
## [4.2.3](https://github.com/QingWei-Li/docsify/compare/v4.2.2...v4.2.3) (2017-07-26)
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* **search:** Supports the max depth of the search headline, fixed [#223](https://github.com/QingWei-Li/docsify/issues/223), resolve [#129](https://github.com/QingWei-Li/docsify/issues/129) ([b7b589b](https://github.com/QingWei-Li/docsify/commit/b7b589b))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="4.2.2"></a>
|
<a name="4.2.2"></a>
|
||||||
## [4.2.2](https://github.com/QingWei-Li/docsify/compare/v4.2.1...v4.2.2) (2017-07-24)
|
## [4.2.2](https://github.com/QingWei-Li/docsify/compare/v4.2.1...v4.2.2) (2017-07-24)
|
||||||
|
|
||||||
|
|||||||
@@ -20,6 +20,7 @@
|
|||||||
|
|
||||||
- [Documentation](https://docsify.js.org)
|
- [Documentation](https://docsify.js.org)
|
||||||
- [CLI](https://github.com/QingWei-Li/docsify-cli)
|
- [CLI](https://github.com/QingWei-Li/docsify-cli)
|
||||||
|
- CDN: [UNPKG](https://unpkg.com/docsify/) | [jsDelivr](https://cdn.jsdelivr.net/npm/docsify/)
|
||||||
|
|
||||||
## Features
|
## Features
|
||||||
|
|
||||||
@@ -74,6 +75,7 @@ These projects are using docsify to generate their sites. Pull requests welcome
|
|||||||
| [palettify](https://dobromir-hristov.github.io/palettify/) | A color palette effects assistant |
|
| [palettify](https://dobromir-hristov.github.io/palettify/) | A color palette effects assistant |
|
||||||
| [commitlint](https://marionebl.github.io/commitlint/) | Lint commit messages |
|
| [commitlint](https://marionebl.github.io/commitlint/) | Lint commit messages |
|
||||||
| [vue-data-tables](https://github.com/njleonzhang/vue-data-tables/) | A simple and customizable data table,based on vue2 and element-ui. |
|
| [vue-data-tables](https://github.com/njleonzhang/vue-data-tables/) | A simple and customizable data table,based on vue2 and element-ui. |
|
||||||
|
| [Noty](http://ned.im/noty/) | A Dependency-free notification library |
|
||||||
|
|
||||||
## Similar projects
|
## Similar projects
|
||||||
|
|
||||||
|
|||||||
+3
-2
@@ -30,15 +30,16 @@ if [[ $REPLY =~ ^[Yy]$ ]]; then
|
|||||||
# commit
|
# commit
|
||||||
git add -A
|
git add -A
|
||||||
git commit -m "[build] $VERSION $RELEASE_TAG"
|
git commit -m "[build] $VERSION $RELEASE_TAG"
|
||||||
npm version $VERSION --message "[release] $VERSION $RELEASE_TAG"
|
npm --no-git-tag-version version $VERSION --message "[release] $VERSION $RELEASE_TAG"
|
||||||
|
|
||||||
# changelog
|
# changelog
|
||||||
node_modules/.bin/conventional-changelog -p angular -i CHANGELOG.md -s -r 2
|
node_modules/.bin/conventional-changelog -p angular -i CHANGELOG.md -s
|
||||||
|
|
||||||
git add .
|
git add .
|
||||||
git commit -m "chore: add changelog $VERSION"
|
git commit -m "chore: add changelog $VERSION"
|
||||||
|
|
||||||
# publish
|
# publish
|
||||||
|
git tag v$VERSION
|
||||||
git push origin refs/tags/v$VERSION
|
git push origin refs/tags/v$VERSION
|
||||||
git push
|
git push
|
||||||
if [[ -z $RELEASE_TAG ]]; then
|
if [[ -z $RELEASE_TAG ]]; then
|
||||||
|
|||||||
@@ -29,7 +29,7 @@
|
|||||||
loadSidebar: true,
|
loadSidebar: true,
|
||||||
coverpage: true,
|
coverpage: true,
|
||||||
name: 'docsify',
|
name: 'docsify',
|
||||||
subMaxLevel: 0,
|
subMaxLevel: 2,
|
||||||
mergeNavbar: true,
|
mergeNavbar: true,
|
||||||
formatUpdated: '{MM}/{DD} {HH}:{mm}',
|
formatUpdated: '{MM}/{DD} {HH}:{mm}',
|
||||||
plugins: [
|
plugins: [
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||

|

|
||||||
|
|
||||||
# docsify <small>4.2.3</small>
|
# docsify <small>4.3.3</small>
|
||||||
|
|
||||||
> A magical documentation site generator.
|
> A magical documentation site generator.
|
||||||
|
|
||||||
|
|||||||
@@ -49,3 +49,10 @@ You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set ti
|
|||||||
|
|
||||||
<a href="/demo/" title="title">link</a>
|
<a href="/demo/" title="title">link</a>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Set target attribute for link
|
||||||
|
|
||||||
|
```md
|
||||||
|
[link](/demo ":target=_blank")
|
||||||
|
[link](/demo2 ":target=_self")
|
||||||
|
```
|
||||||
|
|||||||
@@ -28,3 +28,30 @@ window.$docsify = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## Supports mermaid
|
||||||
|
|
||||||
|
```js
|
||||||
|
// Import mermaid
|
||||||
|
// <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.css">
|
||||||
|
// <script src="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
|
||||||
|
|
||||||
|
mermaid.initialize({ startOnLoad: false });
|
||||||
|
|
||||||
|
window.$docsify = {
|
||||||
|
markdown: {
|
||||||
|
renderer: {
|
||||||
|
code: function(code, lang) {
|
||||||
|
if (lang === "mermaid") {
|
||||||
|
return (
|
||||||
|
'<div class="mermaid">' + mermaid.render(lang, code) + "</div>"
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return this.origin.code.apply(this, arguments);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -96,3 +96,7 @@ Medium's Bilderzoom. Basierend auf [zoom-image](https://github.com/egoist/zoom-i
|
|||||||
```html
|
```html
|
||||||
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.min.js"></script>
|
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.min.js"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Edit on github
|
||||||
|
|
||||||
|
Add `Edit on github` button on every pages. provided by 3rd party, check [document](https://github.com/njleonzhang/docsify-edit-on-github)
|
||||||
|
|||||||
@@ -50,3 +50,10 @@ You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set ti
|
|||||||
<a href="/demo/" title="title">link</a>
|
<a href="/demo/" title="title">link</a>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Set target attribute for link
|
||||||
|
|
||||||
|
```md
|
||||||
|
[link](/demo ":target=_blank")
|
||||||
|
[link](/demo2 ":target=_self")
|
||||||
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -28,3 +28,28 @@ window.$docsify = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Supports mermaid
|
||||||
|
|
||||||
|
```js
|
||||||
|
// Import mermaid
|
||||||
|
// <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.css">
|
||||||
|
// <script src="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
|
||||||
|
|
||||||
|
mermaid.initialize({ startOnLoad: false });
|
||||||
|
|
||||||
|
window.$docsify = {
|
||||||
|
markdown: {
|
||||||
|
renderer: {
|
||||||
|
code: function(code, lang) {
|
||||||
|
if (lang === "mermaid") {
|
||||||
|
return (
|
||||||
|
'<div class="mermaid">' + mermaid.render(lang, code) + "</div>"
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return this.origin.code.apply(this, arguments);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|||||||
@@ -96,3 +96,15 @@ Medium's Image Zoom. Based on [zoom-image](https://github.com/egoist/zoom-image)
|
|||||||
```html
|
```html
|
||||||
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.min.js"></script>
|
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.min.js"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Edit on github
|
||||||
|
|
||||||
|
Add `Edit on github` button on every pages. provided by 3rd party, check [document](https://github.com/njleonzhang/docsify-edit-on-github)
|
||||||
|
|
||||||
|
## Demo code with instant preview and jsfiddle integration
|
||||||
|
|
||||||
|
With this plugin, sample code can be rendered on the page instantly, so that the readers can see the preview immediately.
|
||||||
|
When readers expand the demo box, the source code and description are shown there. if they click the button `Try in Jsfiddle`,
|
||||||
|
`jsfiddle.net` will be open with the code of this sample, which allow readers to revise the code and try on their own.
|
||||||
|
|
||||||
|
[Vue](https://njleonzhang.github.io/docsify-demo-box-vue/) and [React](https://njleonzhang.github.io/docsify-demo-box-react/) are both supported.
|
||||||
|
|||||||
@@ -49,3 +49,10 @@ You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set ti
|
|||||||
<a href="/demo/" title="title">link</a>
|
<a href="/demo/" title="title">link</a>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## Set target attribute for link
|
||||||
|
|
||||||
|
```md
|
||||||
|
[link](/demo ":target=_blank")
|
||||||
|
[link](/demo2 ":target=_self")
|
||||||
|
```
|
||||||
|
|||||||
@@ -28,3 +28,29 @@ window.$docsify = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## Supports mermaid
|
||||||
|
|
||||||
|
```js
|
||||||
|
// Import mermaid
|
||||||
|
// <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.css">
|
||||||
|
// <script src="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
|
||||||
|
|
||||||
|
mermaid.initialize({ startOnLoad: false });
|
||||||
|
|
||||||
|
window.$docsify = {
|
||||||
|
markdown: {
|
||||||
|
renderer: {
|
||||||
|
code: function(code, lang) {
|
||||||
|
if (lang === "mermaid") {
|
||||||
|
return (
|
||||||
|
'<div class="mermaid">' + mermaid.render(lang, code) + "</div>"
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return this.origin.code.apply(this, arguments);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|||||||
@@ -90,3 +90,8 @@ Medium's 风格的图片缩放插件. 基于 [zoom-image](https://github.com/ego
|
|||||||
```html
|
```html
|
||||||
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.js"></script>
|
<script src="//unpkg.com/docsify/lib/plugins/zoom-image.js"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## Edit on github
|
||||||
|
|
||||||
|
Add `Edit on github` button on every pages. provided by 3rd party, check [document](https://github.com/njleonzhang/docsify-edit-on-github)
|
||||||
|
|||||||
+156
-12
@@ -80,7 +80,7 @@ var config = merge({
|
|||||||
mergeNavbar: false,
|
mergeNavbar: false,
|
||||||
formatUpdated: '',
|
formatUpdated: '',
|
||||||
externalLinkTarget: '_blank',
|
externalLinkTarget: '_blank',
|
||||||
routerModel: 'hash',
|
routerMode: 'hash',
|
||||||
noCompileLinks: []
|
noCompileLinks: []
|
||||||
}, window.$docsify);
|
}, window.$docsify);
|
||||||
|
|
||||||
@@ -2817,11 +2817,13 @@ Compiler.prototype._initRenderer = function _initRenderer () {
|
|||||||
var router = ref.router;
|
var router = ref.router;
|
||||||
var contentBase = ref.contentBase;
|
var contentBase = ref.contentBase;
|
||||||
var _self = this;
|
var _self = this;
|
||||||
|
var origin = {};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* render anchor tag
|
* render anchor tag
|
||||||
* @link https://github.com/chjj/marked#overriding-renderer-methods
|
* @link https://github.com/chjj/marked#overriding-renderer-methods
|
||||||
*/
|
*/
|
||||||
renderer.heading = function (text, level) {
|
origin.heading = renderer.heading = function (text, level) {
|
||||||
var nextToc = { level: level, title: text };
|
var nextToc = { level: level, title: text };
|
||||||
|
|
||||||
if (/{docsify-ignore}/g.test(text)) {
|
if (/{docsify-ignore}/g.test(text)) {
|
||||||
@@ -2844,14 +2846,14 @@ Compiler.prototype._initRenderer = function _initRenderer () {
|
|||||||
return ("<h" + level + " id=\"" + slug + "\"><a href=\"" + url + "\" data-id=\"" + slug + "\" class=\"anchor\"><span>" + text + "</span></a></h" + level + ">")
|
return ("<h" + level + " id=\"" + slug + "\"><a href=\"" + url + "\" data-id=\"" + slug + "\" class=\"anchor\"><span>" + text + "</span></a></h" + level + ">")
|
||||||
};
|
};
|
||||||
// highlight code
|
// highlight code
|
||||||
renderer.code = function (code, lang) {
|
origin.code = renderer.code = function (code, lang) {
|
||||||
if ( lang === void 0 ) lang = '';
|
if ( lang === void 0 ) lang = '';
|
||||||
|
|
||||||
var hl = prism.highlight(code, prism.languages[lang] || prism.languages.markup);
|
var hl = prism.highlight(code, prism.languages[lang] || prism.languages.markup);
|
||||||
|
|
||||||
return ("<pre v-pre data-lang=\"" + lang + "\"><code class=\"lang-" + lang + "\">" + hl + "</code></pre>")
|
return ("<pre v-pre data-lang=\"" + lang + "\"><code class=\"lang-" + lang + "\">" + hl + "</code></pre>")
|
||||||
};
|
};
|
||||||
renderer.link = function (href, title, text) {
|
origin.link = renderer.link = function (href, title, text) {
|
||||||
var blank = '';
|
var blank = '';
|
||||||
|
|
||||||
if (!/:|(\/{2})/.test(href) &&
|
if (!/:|(\/{2})/.test(href) &&
|
||||||
@@ -2863,12 +2865,19 @@ Compiler.prototype._initRenderer = function _initRenderer () {
|
|||||||
title = title && title.replace(/:ignore/g, '').trim();
|
title = title && title.replace(/:ignore/g, '').trim();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var target = title && title.match(/:target=\w+/);
|
||||||
|
if (target) {
|
||||||
|
target = target[0];
|
||||||
|
title = title.replace(target, '');
|
||||||
|
blank = ' ' + target.slice(1);
|
||||||
|
}
|
||||||
|
|
||||||
if (title) {
|
if (title) {
|
||||||
title = " title=\"" + title + "\"";
|
title = " title=\"" + title + "\"";
|
||||||
}
|
}
|
||||||
return ("<a href=\"" + href + "\"" + (title || '') + blank + ">" + text + "</a>")
|
return ("<a href=\"" + href + "\"" + (title || '') + blank + ">" + text + "</a>")
|
||||||
};
|
};
|
||||||
renderer.paragraph = function (text) {
|
origin.paragraph = renderer.paragraph = function (text) {
|
||||||
if (/^!>/.test(text)) {
|
if (/^!>/.test(text)) {
|
||||||
return helper('tip', text)
|
return helper('tip', text)
|
||||||
} else if (/^\?>/.test(text)) {
|
} else if (/^\?>/.test(text)) {
|
||||||
@@ -2876,7 +2885,7 @@ Compiler.prototype._initRenderer = function _initRenderer () {
|
|||||||
}
|
}
|
||||||
return ("<p>" + text + "</p>")
|
return ("<p>" + text + "</p>")
|
||||||
};
|
};
|
||||||
renderer.image = function (href, title, text) {
|
origin.image = renderer.image = function (href, title, text) {
|
||||||
var url = href;
|
var url = href;
|
||||||
var titleHTML = title ? (" title=\"" + title + "\"") : '';
|
var titleHTML = title ? (" title=\"" + title + "\"") : '';
|
||||||
|
|
||||||
@@ -2887,6 +2896,8 @@ Compiler.prototype._initRenderer = function _initRenderer () {
|
|||||||
return ("<img src=\"" + url + "\" data-origin=\"" + href + "\" alt=\"" + text + "\"" + titleHTML + ">")
|
return ("<img src=\"" + url + "\" data-origin=\"" + href + "\" alt=\"" + text + "\"" + titleHTML + ">")
|
||||||
};
|
};
|
||||||
|
|
||||||
|
renderer.origin = origin;
|
||||||
|
|
||||||
return renderer
|
return renderer
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -3020,15 +3031,127 @@ function getAndActive (router, el, isParent, autoTitle) {
|
|||||||
return target
|
return target
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) { descriptor.writable = true; } Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) { defineProperties(Constructor.prototype, protoProps); } if (staticProps) { defineProperties(Constructor, staticProps); } return Constructor; }; }();
|
||||||
|
|
||||||
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
||||||
|
|
||||||
|
var Tweezer = function () {
|
||||||
|
function Tweezer() {
|
||||||
|
var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
||||||
|
|
||||||
|
_classCallCheck(this, Tweezer);
|
||||||
|
|
||||||
|
this.duration = opts.duration || 1000;
|
||||||
|
this.ease = opts.easing || this._defaultEase;
|
||||||
|
this.start = opts.start;
|
||||||
|
this.end = opts.end;
|
||||||
|
|
||||||
|
this.frame = null;
|
||||||
|
this.next = null;
|
||||||
|
this.isRunning = false;
|
||||||
|
this.events = {};
|
||||||
|
this.direction = this.start < this.end ? 'up' : 'down';
|
||||||
|
}
|
||||||
|
|
||||||
|
_createClass(Tweezer, [{
|
||||||
|
key: 'begin',
|
||||||
|
value: function begin() {
|
||||||
|
if (!this.isRunning && this.next !== this.end) {
|
||||||
|
this.frame = window.requestAnimationFrame(this._tick.bind(this));
|
||||||
|
}
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: 'stop',
|
||||||
|
value: function stop() {
|
||||||
|
window.cancelAnimationFrame(this.frame);
|
||||||
|
this.isRunning = false;
|
||||||
|
this.frame = null;
|
||||||
|
this.timeStart = null;
|
||||||
|
this.next = null;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: 'on',
|
||||||
|
value: function on(name, handler) {
|
||||||
|
this.events[name] = this.events[name] || [];
|
||||||
|
this.events[name].push(handler);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: 'emit',
|
||||||
|
value: function emit(name, val) {
|
||||||
|
var _this = this;
|
||||||
|
|
||||||
|
var e = this.events[name];
|
||||||
|
e && e.forEach(function (handler) {
|
||||||
|
return handler.call(_this, val);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: '_tick',
|
||||||
|
value: function _tick(currentTime) {
|
||||||
|
this.isRunning = true;
|
||||||
|
|
||||||
|
var lastTick = this.next || this.start;
|
||||||
|
|
||||||
|
if (!this.timeStart) { this.timeStart = currentTime; }
|
||||||
|
this.timeElapsed = currentTime - this.timeStart;
|
||||||
|
this.next = Math.round(this.ease(this.timeElapsed, this.start, this.end - this.start, this.duration));
|
||||||
|
|
||||||
|
if (this._shouldTick(lastTick)) {
|
||||||
|
this.emit('tick', this.next);
|
||||||
|
this.frame = window.requestAnimationFrame(this._tick.bind(this));
|
||||||
|
} else {
|
||||||
|
this.emit('tick', this.end);
|
||||||
|
this.emit('done', null);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: '_shouldTick',
|
||||||
|
value: function _shouldTick(lastTick) {
|
||||||
|
return {
|
||||||
|
up: this.next < this.end && lastTick <= this.next,
|
||||||
|
down: this.next > this.end && lastTick >= this.next
|
||||||
|
}[this.direction];
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
key: '_defaultEase',
|
||||||
|
value: function _defaultEase(t, b, c, d) {
|
||||||
|
if ((t /= d / 2) < 1) { return c / 2 * t * t + b; }
|
||||||
|
return -c / 2 * (--t * (t - 2) - 1) + b;
|
||||||
|
}
|
||||||
|
}]);
|
||||||
|
|
||||||
|
return Tweezer;
|
||||||
|
}();
|
||||||
|
|
||||||
var nav = {};
|
var nav = {};
|
||||||
var hoverOver = false;
|
var hoverOver = false;
|
||||||
|
var scroller = null;
|
||||||
|
var enableScrollEvent = true;
|
||||||
|
|
||||||
|
function scrollTo (el) {
|
||||||
|
if (scroller) { scroller.stop(); }
|
||||||
|
enableScrollEvent = false;
|
||||||
|
scroller = new Tweezer({
|
||||||
|
start: window.scrollY,
|
||||||
|
end: el.getBoundingClientRect().top + window.scrollY,
|
||||||
|
duration: 500
|
||||||
|
})
|
||||||
|
.on('tick', function (v) { return window.scrollTo(0, v); })
|
||||||
|
.on('done', function () { enableScrollEvent = true; scroller = null; })
|
||||||
|
.begin();
|
||||||
|
}
|
||||||
|
|
||||||
function highlight () {
|
function highlight () {
|
||||||
|
if (!enableScrollEvent) { return }
|
||||||
var sidebar = getNode('.sidebar');
|
var sidebar = getNode('.sidebar');
|
||||||
var anchors = findAll('.anchor');
|
var anchors = findAll('.anchor');
|
||||||
var wrap = find(sidebar, '.sidebar-nav');
|
var wrap = find(sidebar, '.sidebar-nav');
|
||||||
var active = find(sidebar, 'li.active');
|
var active = find(sidebar, 'li.active');
|
||||||
var top = body.scrollTop;
|
var doc = document.documentElement;
|
||||||
|
var top = doc && doc.scrollTop || document.body.scrollTop;
|
||||||
var last;
|
var last;
|
||||||
|
|
||||||
for (var i = 0, len = anchors.length; i < len; i += 1) {
|
for (var i = 0, len = anchors.length; i < len; i += 1) {
|
||||||
@@ -3087,7 +3210,7 @@ function scrollActiveSidebar (router) {
|
|||||||
href = router.parse(href).query.id;
|
href = router.parse(href).query.id;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav[decodeURIComponent(href)] = li;
|
if (href) { nav[decodeURIComponent(href)] = li; }
|
||||||
}
|
}
|
||||||
|
|
||||||
off('scroll', highlight);
|
off('scroll', highlight);
|
||||||
@@ -3097,8 +3220,16 @@ function scrollActiveSidebar (router) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function scrollIntoView (id) {
|
function scrollIntoView (id) {
|
||||||
|
if (!id) { return }
|
||||||
|
|
||||||
var section = find('#' + id);
|
var section = find('#' + id);
|
||||||
section && section.scrollIntoView();
|
section && scrollTo(section);
|
||||||
|
|
||||||
|
var li = nav[id];
|
||||||
|
var sidebar = getNode('.sidebar');
|
||||||
|
var active = find(sidebar, 'li.active');
|
||||||
|
active && active.classList.remove('active');
|
||||||
|
li && li.classList.add('active');
|
||||||
}
|
}
|
||||||
|
|
||||||
var scrollEl = $.scrollingElement || $.documentElement;
|
var scrollEl = $.scrollingElement || $.documentElement;
|
||||||
@@ -3319,7 +3450,7 @@ function initRender (vm) {
|
|||||||
|
|
||||||
if (config.themeColor) {
|
if (config.themeColor) {
|
||||||
$.head.appendChild(
|
$.head.appendChild(
|
||||||
create('div', theme(config.themeColor)).getRootNode()
|
create('div', theme(config.themeColor)).firstElementChild
|
||||||
);
|
);
|
||||||
// Polyfll
|
// Polyfll
|
||||||
cssVars(config.themeColor);
|
cssVars(config.themeColor);
|
||||||
@@ -3782,6 +3913,19 @@ var initGlobalAPI = function () {
|
|||||||
window.Prism = prism;
|
window.Prism = prism;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Fork https://github.com/bendrucker/document-ready/blob/master/index.js
|
||||||
|
*/
|
||||||
|
function ready (callback) {
|
||||||
|
var state = document.readyState;
|
||||||
|
|
||||||
|
if (state === 'complete' || state === 'interactive') {
|
||||||
|
return setTimeout(callback, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', callback);
|
||||||
|
}
|
||||||
|
|
||||||
function Docsify () {
|
function Docsify () {
|
||||||
this._init();
|
this._init();
|
||||||
}
|
}
|
||||||
@@ -3802,11 +3946,11 @@ initGlobalAPI();
|
|||||||
/**
|
/**
|
||||||
* Version
|
* Version
|
||||||
*/
|
*/
|
||||||
Docsify.version = '4.2.3';
|
Docsify.version = '4.3.3';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Run Docsify
|
* Run Docsify
|
||||||
*/
|
*/
|
||||||
setTimeout(function (_) { return new Docsify(); }, 0);
|
ready(function (_) { return new Docsify(); });
|
||||||
|
|
||||||
}());
|
}());
|
||||||
|
|||||||
Vendored
+2
-2
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
Generated
+2649
-406
File diff suppressed because it is too large
Load Diff
+2
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "docsify",
|
"name": "docsify",
|
||||||
"version": "4.2.3",
|
"version": "4.3.3",
|
||||||
"description": "A magical documentation generator.",
|
"description": "A magical documentation generator.",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "qingwei-li",
|
"name": "qingwei-li",
|
||||||
@@ -33,6 +33,7 @@
|
|||||||
"marked": "^0.3.6",
|
"marked": "^0.3.6",
|
||||||
"prismjs": "^1.6.0",
|
"prismjs": "^1.6.0",
|
||||||
"tinydate": "^1.0.0",
|
"tinydate": "^1.0.0",
|
||||||
|
"tweezer.js": "^1.4.0",
|
||||||
"zoom-image": "^0.1.4"
|
"zoom-image": "^0.1.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
## Install
|
## Install
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
yarn add docsify-server-render
|
yarn add docsify-server-renderer
|
||||||
```
|
```
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|||||||
+1
-1
@@ -37,5 +37,5 @@
|
|||||||
"integrity": "sha1-6DWIAbhrg7F1YNTjw4LXrvIQCUQ="
|
"integrity": "sha1-6DWIAbhrg7F1YNTjw4LXrvIQCUQ="
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"version": "4.2.3"
|
"version": "4.3.3"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "docsify-server-renderer",
|
"name": "docsify-server-renderer",
|
||||||
"version": "4.2.3",
|
"version": "4.3.3",
|
||||||
"description": "docsify server renderer",
|
"description": "docsify server renderer",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "qingwei-li",
|
"name": "qingwei-li",
|
||||||
|
|||||||
+1
-1
@@ -21,7 +21,7 @@ const config = merge({
|
|||||||
mergeNavbar: false,
|
mergeNavbar: false,
|
||||||
formatUpdated: '',
|
formatUpdated: '',
|
||||||
externalLinkTarget: '_blank',
|
externalLinkTarget: '_blank',
|
||||||
routerModel: 'hash',
|
routerMode: 'hash',
|
||||||
noCompileLinks: []
|
noCompileLinks: []
|
||||||
}, window.$docsify)
|
}, window.$docsify)
|
||||||
|
|
||||||
|
|||||||
@@ -1,15 +1,33 @@
|
|||||||
import { isMobile } from '../util/env'
|
import { isMobile } from '../util/env'
|
||||||
import * as dom from '../util/dom'
|
import * as dom from '../util/dom'
|
||||||
|
import Tweezer from 'tweezer.js'
|
||||||
|
|
||||||
const nav = {}
|
const nav = {}
|
||||||
let hoverOver = false
|
let hoverOver = false
|
||||||
|
let scroller = null
|
||||||
|
let enableScrollEvent = true
|
||||||
|
|
||||||
|
function scrollTo (el) {
|
||||||
|
if (scroller) scroller.stop()
|
||||||
|
enableScrollEvent = false
|
||||||
|
scroller = new Tweezer({
|
||||||
|
start: window.scrollY,
|
||||||
|
end: el.getBoundingClientRect().top + window.scrollY,
|
||||||
|
duration: 500
|
||||||
|
})
|
||||||
|
.on('tick', v => window.scrollTo(0, v))
|
||||||
|
.on('done', () => { enableScrollEvent = true; scroller = null })
|
||||||
|
.begin()
|
||||||
|
}
|
||||||
|
|
||||||
function highlight () {
|
function highlight () {
|
||||||
|
if (!enableScrollEvent) return
|
||||||
const sidebar = dom.getNode('.sidebar')
|
const sidebar = dom.getNode('.sidebar')
|
||||||
const anchors = dom.findAll('.anchor')
|
const anchors = dom.findAll('.anchor')
|
||||||
const wrap = dom.find(sidebar, '.sidebar-nav')
|
const wrap = dom.find(sidebar, '.sidebar-nav')
|
||||||
let active = dom.find(sidebar, 'li.active')
|
let active = dom.find(sidebar, 'li.active')
|
||||||
const top = dom.body.scrollTop
|
const doc = document.documentElement
|
||||||
|
const top = doc && doc.scrollTop || document.body.scrollTop
|
||||||
let last
|
let last
|
||||||
|
|
||||||
for (let i = 0, len = anchors.length; i < len; i += 1) {
|
for (let i = 0, len = anchors.length; i < len; i += 1) {
|
||||||
@@ -68,7 +86,7 @@ export function scrollActiveSidebar (router) {
|
|||||||
href = router.parse(href).query.id
|
href = router.parse(href).query.id
|
||||||
}
|
}
|
||||||
|
|
||||||
nav[decodeURIComponent(href)] = li
|
if (href) nav[decodeURIComponent(href)] = li
|
||||||
}
|
}
|
||||||
|
|
||||||
dom.off('scroll', highlight)
|
dom.off('scroll', highlight)
|
||||||
@@ -78,8 +96,16 @@ export function scrollActiveSidebar (router) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function scrollIntoView (id) {
|
export function scrollIntoView (id) {
|
||||||
|
if (!id) return
|
||||||
|
|
||||||
const section = dom.find('#' + id)
|
const section = dom.find('#' + id)
|
||||||
section && section.scrollIntoView()
|
section && scrollTo(section)
|
||||||
|
|
||||||
|
const li = nav[id]
|
||||||
|
const sidebar = dom.getNode('.sidebar')
|
||||||
|
const active = dom.find(sidebar, 'li.active')
|
||||||
|
active && active.classList.remove('active')
|
||||||
|
li && li.classList.add('active')
|
||||||
}
|
}
|
||||||
|
|
||||||
const scrollEl = dom.$.scrollingElement || dom.$.documentElement
|
const scrollEl = dom.$.scrollingElement || dom.$.documentElement
|
||||||
|
|||||||
+14
-1
@@ -5,6 +5,19 @@ import { fetchMixin } from './fetch'
|
|||||||
import { eventMixin } from './event'
|
import { eventMixin } from './event'
|
||||||
import initGlobalAPI from './global-api'
|
import initGlobalAPI from './global-api'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Fork https://github.com/bendrucker/document-ready/blob/master/index.js
|
||||||
|
*/
|
||||||
|
function ready (callback) {
|
||||||
|
const state = document.readyState
|
||||||
|
|
||||||
|
if (state === 'complete' || state === 'interactive') {
|
||||||
|
return setTimeout(callback, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', callback)
|
||||||
|
}
|
||||||
|
|
||||||
function Docsify () {
|
function Docsify () {
|
||||||
this._init()
|
this._init()
|
||||||
}
|
}
|
||||||
@@ -30,4 +43,4 @@ Docsify.version = '__VERSION__'
|
|||||||
/**
|
/**
|
||||||
* Run Docsify
|
* Run Docsify
|
||||||
*/
|
*/
|
||||||
setTimeout(_ => new Docsify(), 0)
|
ready(_ => new Docsify())
|
||||||
|
|||||||
@@ -61,11 +61,13 @@ export class Compiler {
|
|||||||
const renderer = new marked.Renderer()
|
const renderer = new marked.Renderer()
|
||||||
const { linkTarget, router, contentBase } = this
|
const { linkTarget, router, contentBase } = this
|
||||||
const _self = this
|
const _self = this
|
||||||
|
const origin = {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* render anchor tag
|
* render anchor tag
|
||||||
* @link https://github.com/chjj/marked#overriding-renderer-methods
|
* @link https://github.com/chjj/marked#overriding-renderer-methods
|
||||||
*/
|
*/
|
||||||
renderer.heading = function (text, level) {
|
origin.heading = renderer.heading = function (text, level) {
|
||||||
const nextToc = { level, title: text }
|
const nextToc = { level, title: text }
|
||||||
|
|
||||||
if (/{docsify-ignore}/g.test(text)) {
|
if (/{docsify-ignore}/g.test(text)) {
|
||||||
@@ -88,12 +90,12 @@ export class Compiler {
|
|||||||
return `<h${level} id="${slug}"><a href="${url}" data-id="${slug}" class="anchor"><span>${text}</span></a></h${level}>`
|
return `<h${level} id="${slug}"><a href="${url}" data-id="${slug}" class="anchor"><span>${text}</span></a></h${level}>`
|
||||||
}
|
}
|
||||||
// highlight code
|
// highlight code
|
||||||
renderer.code = function (code, lang = '') {
|
origin.code = renderer.code = function (code, lang = '') {
|
||||||
const hl = Prism.highlight(code, Prism.languages[lang] || Prism.languages.markup)
|
const hl = Prism.highlight(code, Prism.languages[lang] || Prism.languages.markup)
|
||||||
|
|
||||||
return `<pre v-pre data-lang="${lang}"><code class="lang-${lang}">${hl}</code></pre>`
|
return `<pre v-pre data-lang="${lang}"><code class="lang-${lang}">${hl}</code></pre>`
|
||||||
}
|
}
|
||||||
renderer.link = function (href, title, text) {
|
origin.link = renderer.link = function (href, title, text) {
|
||||||
let blank = ''
|
let blank = ''
|
||||||
|
|
||||||
if (!/:|(\/{2})/.test(href) &&
|
if (!/:|(\/{2})/.test(href) &&
|
||||||
@@ -105,12 +107,19 @@ export class Compiler {
|
|||||||
title = title && title.replace(/:ignore/g, '').trim()
|
title = title && title.replace(/:ignore/g, '').trim()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let target = title && title.match(/:target=\w+/)
|
||||||
|
if (target) {
|
||||||
|
target = target[0]
|
||||||
|
title = title.replace(target, '')
|
||||||
|
blank = ' ' + target.slice(1)
|
||||||
|
}
|
||||||
|
|
||||||
if (title) {
|
if (title) {
|
||||||
title = ` title="${title}"`
|
title = ` title="${title}"`
|
||||||
}
|
}
|
||||||
return `<a href="${href}"${title || ''}${blank}>${text}</a>`
|
return `<a href="${href}"${title || ''}${blank}>${text}</a>`
|
||||||
}
|
}
|
||||||
renderer.paragraph = function (text) {
|
origin.paragraph = renderer.paragraph = function (text) {
|
||||||
if (/^!>/.test(text)) {
|
if (/^!>/.test(text)) {
|
||||||
return helperTpl('tip', text)
|
return helperTpl('tip', text)
|
||||||
} else if (/^\?>/.test(text)) {
|
} else if (/^\?>/.test(text)) {
|
||||||
@@ -118,7 +127,7 @@ export class Compiler {
|
|||||||
}
|
}
|
||||||
return `<p>${text}</p>`
|
return `<p>${text}</p>`
|
||||||
}
|
}
|
||||||
renderer.image = function (href, title, text) {
|
origin.image = renderer.image = function (href, title, text) {
|
||||||
let url = href
|
let url = href
|
||||||
const titleHTML = title ? ` title="${title}"` : ''
|
const titleHTML = title ? ` title="${title}"` : ''
|
||||||
|
|
||||||
@@ -129,6 +138,8 @@ export class Compiler {
|
|||||||
return `<img src="${url}" data-origin="${href}" alt="${text}"${titleHTML}>`
|
return `<img src="${url}" data-origin="${href}" alt="${text}"${titleHTML}>`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
renderer.origin = origin
|
||||||
|
|
||||||
return renderer
|
return renderer
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -212,7 +212,7 @@ export function initRender (vm) {
|
|||||||
|
|
||||||
if (config.themeColor) {
|
if (config.themeColor) {
|
||||||
dom.$.head.appendChild(
|
dom.$.head.appendChild(
|
||||||
dom.create('div', tpl.theme(config.themeColor)).getRootNode()
|
dom.create('div', tpl.theme(config.themeColor)).firstElementChild
|
||||||
)
|
)
|
||||||
// Polyfll
|
// Polyfll
|
||||||
cssVars(config.themeColor)
|
cssVars(config.themeColor)
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
body:not(.ready) {
|
body:not(.ready) {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
[data-cloak], .app-nav {
|
[data-cloak], .app-nav, > nav {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ $sidebar-width: 16rem;
|
|||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
font-family: Inconsolata;
|
font-family: Inconsolata;
|
||||||
padding: 0.2em 0.4rem;
|
padding: 0.2em 0.4rem;
|
||||||
white-space: pre;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-section pre {
|
.markdown-section pre {
|
||||||
@@ -226,6 +226,7 @@ $sidebar-width: 16rem;
|
|||||||
overflow: inherit;
|
overflow: inherit;
|
||||||
padding: 20px 0.8em 20px;
|
padding: 20px 0.8em 20px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
white-space: inherit;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-section code::after, .markdown-section code::before {
|
.markdown-section code::after, .markdown-section code::before {
|
||||||
|
|||||||
+1
-1
@@ -134,7 +134,7 @@ body {
|
|||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
margin: 0 2px;
|
margin: 0 2px;
|
||||||
padding: 3px 5px;
|
padding: 3px 5px;
|
||||||
white-space: nowrap;
|
white-space: pre-wrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-section pre {
|
.markdown-section pre {
|
||||||
|
|||||||
+1
-1
@@ -145,7 +145,7 @@ body {
|
|||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
margin: 0 2px;
|
margin: 0 2px;
|
||||||
padding: 3px 5px;
|
padding: 3px 5px;
|
||||||
white-space: nowrap;
|
white-space: pre-wrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-section pre {
|
.markdown-section pre {
|
||||||
|
|||||||
Reference in New Issue
Block a user