diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..0bd565e --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 35d6b90..0000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,38 +0,0 @@ ---- -name: Bug report -about: Create a report to help us improve - ---- - - - - - -## Bug Report - -#### Steps to reproduce - - - -#### What is current behaviour - - - -#### What is the expected behaviour - - - -#### Other relevant information - - -- [ ] Bug does still occur when all/other plugins are disabled? - -- Your OS: -- Node.js version: -- npm/yarn version: -- Browser version: -- Docsify version: -- Docsify plugins: - - diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 501e4de..0000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -name: Feature request -about: Suggest an idea for this project - ---- - - - - - -## Feature request - -#### What problem does this feature solve? - - - -#### What does the proposed API look like? - - - -#### How should this be implemented in your opinion? - - - -#### Are you willing to work on this yourself? diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index bb31bd4..79a5281 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,54 +1,5 @@ - - - - - - -**Summary** - -**What kind of change does this PR introduce?** (check at least one) - -- [ ] Bugfix -- [ ] Feature -- [ ] Code style update -- [ ] Refactor -- [ ] Docs -- [ ] Build-related changes -- [ ] Other, please describe: - -If changing the UI of default theme, please provide the **before/after** screenshot: - -**Does this PR introduce a breaking change?** (check one) - -- [ ] Yes -- [ ] No - -If yes, please describe the impact and migration path for existing applications: - -**The PR fulfills these requirements:** - -- [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix #xxx[,#xxx]`, where "xxx" is the issue number) - -You have tested in the following browsers: (Providing a detailed version will be better.) - -- [ ] Chrome -- [ ] Firefox -- [ ] Safari -- [ ] Edge -- [ ] IE - -If adding a **new feature**, the PR's description includes: - -- [ ] A convincing reason for adding this feature -- [ ] Related documents have been updated -- [ ] Related tests have been updated - -To avoid wasting your time, it's best to open a **feature request issue** first and wait for approval before working on it. - - -**Other information:** - ---- +Please makes sure these boxes are checked before submitting your PR, thank you! +* [ ] Make sure you are merging your commits to `master` branch. +* [ ] Add some descriptions and refer relative issues for you PR. * [ ] DO NOT include files inside `lib` directory. - diff --git a/.gitignore b/.gitignore index ea4b5b8..7235d84 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,8 @@ *.log .DS_Store -.idea +/themes/* +!.gitkeep node_modules -themes/ -lib/ +lib +.idea -# exceptions -!.gitkeep \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 267d402..5a50a98 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,23 +1,3 @@ - -## [4.9.4](https://github.com/docsifyjs/docsify/compare/v4.9.2...v4.9.4) (2019-05-05) - - - - -## [4.9.2](https://github.com/docsifyjs/docsify/compare/v4.9.1...v4.9.2) (2019-04-21) - - -### Bug Fixes - -* re-render gitalk when router changed ([11ea1f8](https://github.com/docsifyjs/docsify/commit/11ea1f8)) - - -### Features - -* allows relative path, fixed [#590](https://github.com/docsifyjs/docsify/issues/590) ([31654f1](https://github.com/docsifyjs/docsify/commit/31654f1)) - - - ## [4.9.1](https://github.com/docsifyjs/docsify/compare/v4.9.0...v4.9.1) (2019-02-21) diff --git a/README.md b/README.md index b8da0d8..a1ae1c8 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,6 @@ ## Links -- [`develop` branch preview](https://docsifyjs.netlify.com/) - [Documentation](https://docsify.js.org) - [CLI](https://github.com/docsifyjs/docsify-cli) - CDN: [UNPKG](https://unpkg.com/docsify/) | [jsDelivr](https://cdn.jsdelivr.net/npm/docsify/) | [cdnjs](https://cdnjs.com/libraries/docsify) @@ -41,7 +40,7 @@ - Smart full-text search plugin - Multiple themes - Useful plugin API -- Compatible with IE11 +- Compatible with IE10+ - Support SSR ([example](https://github.com/docsifyjs/docsify-ssr-demo)) - Support embedded files @@ -55,7 +54,7 @@ Look at [this tutorial](https://docsify.js.org/#/quickstart) These projects are using docsify to generate their sites. Pull requests welcome :blush: -Move to [awesome-docsify](https://github.com/docsifyjs/awesome-docsify#showcase) +Move to [awesome-docsify](https://github.com/docsifyjs/awesome-docsify) ## Similar projects diff --git a/build/build.js b/build/build.js index 7b61224..b9068b9 100644 --- a/build/build.js +++ b/build/build.js @@ -55,7 +55,6 @@ const buildAllPlugin = function () { var plugins = [ {name: 'search', input: 'search/index.js'}, {name: 'ga', input: 'ga.js'}, - {name: 'matomo', input: 'matomo.js'}, {name: 'emoji', input: 'emoji.js'}, {name: 'external-script', input: 'external-script.js'}, {name: 'front-matter', input: 'front-matter/index.js'}, diff --git a/build/release.sh b/build/release.sh old mode 100755 new mode 100644 index a328322..da15a38 --- a/build/release.sh +++ b/build/release.sh @@ -29,6 +29,7 @@ if [[ $REPLY =~ ^[Yy]$ ]]; then # commit git add -A + git add -f lib/ -A git commit -m "[build] $VERSION $RELEASE_TAG" npm --no-git-tag-version version $VERSION --message "[release] $VERSION $RELEASE_TAG" diff --git a/docs/README.md b/docs/README.md index e625420..d27f1ae 100644 --- a/docs/README.md +++ b/docs/README.md @@ -16,12 +16,12 @@ See the [Quick start](quickstart.md) guide for more details. - Multiple themes - Useful plugin API - Emoji support -- Compatible with IE11 +- Compatible with IE10+ - Support server-side rendering ([example](https://github.com/docsifyjs/docsify-ssr-demo)) ## Examples -Check out the [Showcase](https://github.com/docsifyjs/awesome-docsify#showcase) to see docsify in use. +Check out the [Showcase](https://github.com/docsifyjs/docsify/#showcase) to see docsify in use. ## Donate diff --git a/docs/_coverpage.md b/docs/_coverpage.md index 1decbd6..0a18f97 100644 --- a/docs/_coverpage.md +++ b/docs/_coverpage.md @@ -1,6 +1,6 @@  -# docsify 4.9.4 +# docsify 4.9.1 > A magical documentation site generator. diff --git a/docs/_sidebar.md b/docs/_sidebar.md index 051514b..c8ab579 100644 --- a/docs/_sidebar.md +++ b/docs/_sidebar.md @@ -23,6 +23,7 @@ - [Offline Mode(PWA)](pwa.md) - [Server-Side Rendering(SSR)](ssr.md) - [Embed Files](embed-files.md) + - [Generate static html](static.md) - [Awesome docsify](awesome.md) - [Changelog](changelog.md) diff --git a/docs/configuration.md b/docs/configuration.md index ba48475..830748f 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -150,46 +150,6 @@ window.$docsify = { }; ``` -## relativePath - -- Type: `Boolean` -- Default: `false` - -If **true** links are relative to the current context. - -For example, the directory structure is as follows: - -```text -. -โโโ docs - โโโ README.md - โโโ guide.md - โโโ zh-cn - โโโ README.md - โโโ guide.md - โโโ config - โโโ example.md -``` - -With relative path **enabled** and current URL `http://domain.com/zh-cn/README`, given links will resolve to: - -```text -guide.md => http://domain.com/zh-cn/guide -config/example.md => http://domain.com/zh-cn/config/example -../README.md => http://domain.com/README -/README.md => http://domain.com/README -``` - -```js -window.$docsify = { - // Relative path enabled - relativePath: true, - - // Relative path disabled (default value) - relativePath: false -}; -``` - ## coverpage - Type: `Boolean|String|String[]|Object` diff --git a/docs/deploy.md b/docs/deploy.md index a879f2e..7d47e0f 100644 --- a/docs/deploy.md +++ b/docs/deploy.md @@ -15,7 +15,7 @@ It is recommended that you save your files to the `./docs` subfolder of the `mas  !> You can also save files in the root directory and select `master branch`. -You'll need to place a `.nojekyll` file in the deploy location (such as `/docs` or the gh-pages branch) +You'll need to place a `.nojekyll` file in the deploy location (such as `/docs` or the gh-pages branch ## GitLab Pages diff --git a/docs/helpers.md b/docs/helpers.md index b047d36..9075448 100644 --- a/docs/helpers.md +++ b/docs/helpers.md @@ -7,24 +7,72 @@ docsify extends Markdown syntax to make your documents more readable. Important content like: ```markdown -!> **Time** is money, my friend! +> [!] **Time** is money, my friend! ``` is rendered as: -!> **Time** is money, my friend! +> [!] **Time** is money, my friend! ## General tips General tips like: ```markdown -?> _TODO_ unit test +> [?] _TODO_ unit test ``` are rendered as: -?> _TODO_ unit test +> [?] _TODO_ unit test + +## More tips + +```markdown +> [x] bad + +> [v] good +``` + +> [x] bad + +> [v] good + +## Details + +````markdown +> [details] Sample code +> +> js code +> +> ```javascript +> console.log("foo"); +> ``` + +> [details:open] Sample code open +> +> js code +> +> ```javascript +> console.log("foo"); +> ``` +```` + +> [details] Sample code +> +> js code +> +> ```javascript +> console.log("foo"); +> ``` + +> [details:open] Sample code open +> +> js code +> +> ```javascript +> console.log("foo"); +> ``` ## Ignore to compile link @@ -39,13 +87,13 @@ It will be compiled to `link` and will be loaded `/demo/R Now you can do that ```md -[link](/demo/ ':ignore') +[link](/demo/ ":ignore") ``` You will get `link`html. Do not worry, you can still set title for link. ```md -[link](/demo/ ':ignore title') +[link](/demo/ ":ignore title") link ``` @@ -53,14 +101,14 @@ You will get `link`html. Do not worry, you can still set ti ## Set target attribute for link ```md -[link](/demo ':target=_blank') -[link](/demo2 ':target=_self') +[link](/demo ":target=_blank") +[link](/demo2 ":target=_self") ``` ## Disable link ```md -[link](/demo ':disabled') +[link](/demo ":disabled") ``` ## Github Task Lists @@ -84,17 +132,17 @@ You will get `link`html. Do not worry, you can still set ti ## Image resizing ```md - - + + - + ``` - - - + + + ## Customise ID for headings diff --git a/docs/index.html b/docs/index.html index 6d0e008..bff4ca1 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1,104 +1,137 @@ +
+ +