From 1a76d8e307c78be729720062956ccfdef0225a9c Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 8 Oct 2018 01:19:35 +0800 Subject: [PATCH 01/48] chore: update documentation link --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 3fc1522b56..1e85f2a1f8 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ > Minimalistic docs generator with Vue component based layout system -https://vuepress.vuejs.org/ +https://v0.vuepress.vuejs.org/ ## Features From 5295bec9c38e53c045c86b4d76d49c3b783ead0a Mon Sep 17 00:00:00 2001 From: Thiemo <305926+thiemo@users.noreply.github.com> Date: Wed, 17 Oct 2018 08:05:17 +0200 Subject: [PATCH 02/48] docs: override.styl to style.styl for custom page class (#939) --- docs/default-theme-config/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/default-theme-config/README.md b/docs/default-theme-config/README.md index f05425ab18..f6737edd30 100644 --- a/docs/default-theme-config/README.md +++ b/docs/default-theme-config/README.md @@ -492,7 +492,7 @@ pageClass: custom-page-class Then you can write CSS targeting that page only: ``` css -/* .vuepress/override.styl */ +/* .vuepress/style.styl */ .theme-container.custom-page-class { /* page-specific rules */ From 9fe80db5471105351cc3764e36b42af21b0ce977 Mon Sep 17 00:00:00 2001 From: Thiemo <305926+thiemo@users.noreply.github.com> Date: Wed, 17 Oct 2018 08:06:28 +0200 Subject: [PATCH 03/48] chore: update index.js (#938) Updated URL of docs (v0.vuepress.vuejs.org) to fix broken link --- lib/prepare/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/prepare/index.js b/lib/prepare/index.js index 7561f79158..e6b8ebb409 100644 --- a/lib/prepare/index.js +++ b/lib/prepare/index.js @@ -36,7 +36,7 @@ module.exports = async function prepare (sourceDir) { if (hasUserOverride && !hasUserStyle) { logger.tip( `${chalk.magenta('override.styl')} has been split into 2 APIs, we recommend you upgrade to continue.\n` + - ` See: ${chalk.magenta('https://vuepress.vuejs.org/default-theme-config/#simple-css-override')}` + ` See: ${chalk.magenta('https://v0.vuepress.vuejs.org/default-theme-config/#simple-css-override')}` ) } From 600ca3e7fac645c908edd47a998fc35033fb11c2 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Wed, 14 Nov 2018 04:06:57 +0800 Subject: [PATCH 04/48] fix($core): css cannot be extracted together (close: #977) This is because mini-css-extract-plugin had a internal change at https://github.com/webpack-contrib/mini-css-extract-plugin/pull/265 which will cause issue to VuePress. --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index afdec2156d..ec937845d7 100644 --- a/package.json +++ b/package.json @@ -71,7 +71,7 @@ "markdown-it-container": "^2.0.0", "markdown-it-emoji": "^1.4.0", "markdown-it-table-of-contents": "^0.4.0", - "mini-css-extract-plugin": "^0.4.1", + "mini-css-extract-plugin": "0.4.1", "nprogress": "^0.2.0", "optimize-css-assets-webpack-plugin": "^4.0.0", "portfinder": "^1.0.13", From 9ae64a1fb3af5cd5e3546d5146ec3070180aea48 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Wed, 14 Nov 2018 04:07:55 +0800 Subject: [PATCH 05/48] 0.14.5 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ec937845d7..e21d617614 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.4", + "version": "0.14.5", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From bec093d0bd928fe4ae80515045ff39be14cfbf8f Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Wed, 14 Nov 2018 04:07:57 +0800 Subject: [PATCH 06/48] chore: changelog --- CHANGELOG.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 92e86b0420..c0a4ddc542 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,14 @@ + +## [0.14.5](https://github.com/vuejs/vuepress/compare/v0.14.4...v0.14.5) (2018-11-13) + + +### Bug Fixes + +* **$core:** css cannot be extracted together (close: [#977](https://github.com/vuejs/vuepress/issues/977)) ([600ca3e](https://github.com/vuejs/vuepress/commit/600ca3e)) +* **dev:** Prevent files at node_modules from being watched (close: [#855](https://github.com/vuejs/vuepress/issues/855)) ([#856](https://github.com/vuejs/vuepress/issues/856)) ([2348e75](https://github.com/vuejs/vuepress/commit/2348e75)) + + + ## [0.14.4](https://github.com/vuejs/vuepress/compare/v0.14.3...v0.14.4) (2018-09-15) From 32c32c9dbc3139a75e090e9451af565aefc6d039 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Sun, 25 Nov 2018 23:47:11 +0800 Subject: [PATCH 07/48] fix($core): build error when VuePress runs in non-TTY device (close: #1037) --- lib/prepare/util.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/prepare/util.js b/lib/prepare/util.js index efa96cc9b7..64c9b60185 100644 --- a/lib/prepare/util.js +++ b/lib/prepare/util.js @@ -75,6 +75,11 @@ exports.encodePath = function (userpath) { return userpath.split('/').map(item => encodeURIComponent(item)).join('/') } -exports.getGitLastUpdatedTimeStamp = function (filepath) { - return parseInt(spawn.sync('git', ['log', '-1', '--format=%ct', filepath]).stdout.toString('utf-8')) * 1000 +exports.getGitLastUpdatedTimeStamp = function (filePath) { + let lastUpdated + try { + lastUpdated = parseInt(spawn.sync('git', ['log', '-1', '--format=%ct', filePath]).stdout.toString('utf-8')) * 1000 + } catch (e) { /* do not handle for now */ } + return lastUpdated } + From dcc108718a71b34e613b8049167531a55c60dbae Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Sun, 25 Nov 2018 23:47:41 +0800 Subject: [PATCH 08/48] 0.14.6 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e21d617614..c7e41a4865 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.5", + "version": "0.14.6", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From ac6f69a21476832a01c0895d2344767d2ffc2c00 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Sun, 25 Nov 2018 23:47:44 +0800 Subject: [PATCH 09/48] chore: changelog --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c0a4ddc542..c0b966d057 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,13 @@ + +## [0.14.6](https://github.com/vuejs/vuepress/compare/v0.14.5...v0.14.6) (2018-11-25) + + +### Bug Fixes + +* **$core:** build error when VuePress runs in non-TTY device (close: [#1037](https://github.com/vuejs/vuepress/issues/1037)) ([32c32c9](https://github.com/vuejs/vuepress/commit/32c32c9)) + + + ## [0.14.5](https://github.com/vuejs/vuepress/compare/v0.14.4...v0.14.5) (2018-11-13) From c6484e7e6b9a1e7c209af52e66cb17d100aa11f4 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 01:58:28 +0800 Subject: [PATCH 10/48] chore: changelog --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c0b966d057..29bf3bc8b7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,16 @@ + +## [0.14.6](https://github.com/vuejs/vuepress/compare/v0.14.5...v0.14.6) (2018-11-25) + + +### Bug Fixes + +* **$core:** build error when VuePress runs in non-TTY device (close: [#1037](https://github.com/vuejs/vuepress/issues/1037)) ([32c32c9](https://github.com/vuejs/vuepress/commit/32c32c9)) + + + ## [0.14.5](https://github.com/vuejs/vuepress/compare/v0.14.4...v0.14.5) (2018-11-13) From 1340e37e9509e6b129ae99548b4f44fcd26b5fa5 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 02:00:22 +0800 Subject: [PATCH 11/48] fix($core): "index" is dropped in a link with "*index" pattern (close: #996) --- lib/markdown/link.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/markdown/link.js b/lib/markdown/link.js index bbe9550d63..9a6c20c64c 100644 --- a/lib/markdown/link.js +++ b/lib/markdown/link.js @@ -2,7 +2,7 @@ // 1. adding target="_blank" to external links // 2. converting internal links to -const indexRE = /(.*)(index|readme).md(#?.*)$/i +const indexRE = /(^|.*\/)(index|readme).md(#?.*)$/i module.exports = (md, externalAttrs) => { let hasOpenRouterLink = false From cf4d478cf8902387c7d869f0a1f231e3640b370c Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 02:02:14 +0800 Subject: [PATCH 12/48] 0.14.7 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c7e41a4865..8fb54c7b82 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.6", + "version": "0.14.7", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From 31fb1f15d5b8c3d98aa3bde3925ac2a38080e10d Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 02:02:17 +0800 Subject: [PATCH 13/48] chore: changelog --- CHANGELOG.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 29bf3bc8b7..3d389dfe51 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,10 +1,10 @@ - -## [0.14.6](https://github.com/vuejs/vuepress/compare/v0.14.5...v0.14.6) (2018-11-25) + +## [0.14.7](https://github.com/vuejs/vuepress/compare/v0.14.6...v0.14.7) (2018-11-25) ### Bug Fixes -* **$core:** build error when VuePress runs in non-TTY device (close: [#1037](https://github.com/vuejs/vuepress/issues/1037)) ([32c32c9](https://github.com/vuejs/vuepress/commit/32c32c9)) +* **$core:** "index" is dropped in a link with "*index" pattern (close: [#996](https://github.com/vuejs/vuepress/issues/996)) ([1340e37](https://github.com/vuejs/vuepress/commit/1340e37)) From 838332965c2747a5b1481f681611ef749182174b Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 14:24:49 +0800 Subject: [PATCH 14/48] feat($markdown): pass rest options to instantiate markdown-it Close: #1040 e.g. markdown: { config: md => { md.set({linkify: true}); } } shortcut: markdown: { linkify: true }, --- lib/markdown/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/markdown/index.js b/lib/markdown/index.js index f4942f6ce6..ec39e83299 100644 --- a/lib/markdown/index.js +++ b/lib/markdown/index.js @@ -17,10 +17,10 @@ module.exports = ({ markdown = {}} = {}) => { // allow user config slugify const slugify = markdown.slugify || _slugify - const md = require('markdown-it')({ + const md = require('markdown-it')(Object.assign({ html: true, highlight - }) + }, markdown)) // custom plugins .use(component) .use(highlightLines) From bec6322436067d08edeb58a6fc823d2403dc4ded Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 14:28:35 +0800 Subject: [PATCH 15/48] 0.14.8 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 8fb54c7b82..fc466cf2a7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.7", + "version": "0.14.8", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From ba208588df1f2e4b0436aa7fdac6c228e1e11d0d Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 26 Nov 2018 14:28:38 +0800 Subject: [PATCH 16/48] chore: changelog --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3d389dfe51..d4c0a35f5a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,13 @@ + +## [0.14.8](https://github.com/vuejs/vuepress/compare/v0.14.7...v0.14.8) (2018-11-26) + + +### Features + +* **$markdown:** pass rest options to instantiate markdown-it ([8383329](https://github.com/vuejs/vuepress/commit/8383329)), closes [#1040](https://github.com/vuejs/vuepress/issues/1040) + + + ## [0.14.7](https://github.com/vuejs/vuepress/compare/v0.14.6...v0.14.7) (2018-11-25) From cb8fce97c0ada9b84d943f4478ecc8f4ca9efc9e Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Wed, 19 Dec 2018 00:20:13 +0800 Subject: [PATCH 17/48] docs: disable algolia search for 0.x docs --- docs/.vuepress/config.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index f56003051c..42cf063b2b 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -30,10 +30,10 @@ module.exports = { editLinks: true, docsDir: 'docs', // #697 Provided by the official algolia team. - algolia: { - apiKey: '3a539aab83105f01761a137c61004d85', - indexName: 'vuepress' - }, + // algolia: { + // apiKey: '3a539aab83105f01761a137c61004d85', + // indexName: 'vuepress' + // }, locales: { '/': { label: 'English', From b7f3ac48dcf6866c2b552be8ad1e1c45a729a1f0 Mon Sep 17 00:00:00 2001 From: Matthieu Mota Date: Tue, 8 Jan 2019 18:27:20 +0100 Subject: [PATCH 18/48] fix: sidebar button should be hidden when there are no sidebars in mobile side (#1159) --- lib/default-theme/styles/theme.styl | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/default-theme/styles/theme.styl b/lib/default-theme/styles/theme.styl index a733861fa6..5821c070ba 100644 --- a/lib/default-theme/styles/theme.styl +++ b/lib/default-theme/styles/theme.styl @@ -172,12 +172,17 @@ th, td display: block &.no-navbar .content:not(.custom) > h1, h2, h3, h4, h5, h6 - margin-top 1.5rem - padding-top 0 + margin-top 1.5rem + padding-top 0 .sidebar top 0 .custom-layout padding-top 0 + &.no-sidebar + .sidebar-button + display: none + .navbar + padding-left 1.5rem @media (min-width: ($MQMobile + 1px)) From 2f315d7097117508a5dabc2a91b9e4d2952baff4 Mon Sep 17 00:00:00 2001 From: Matthieu Mota Date: Tue, 8 Jan 2019 18:53:18 +0100 Subject: [PATCH 19/48] docs: documentation theme logo (#1150) --- docs/.vuepress/config.js | 1 + docs/default-theme-config/README.md | 13 +++++++++++++ 2 files changed, 14 insertions(+) diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index 42cf063b2b..e5ffe9ef06 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -29,6 +29,7 @@ module.exports = { repo: 'vuejs/vuepress', editLinks: true, docsDir: 'docs', + docsBranch: '0.x', // #697 Provided by the official algolia team. // algolia: { // apiKey: '3a539aab83105f01761a137c61004d85', diff --git a/docs/default-theme-config/README.md b/docs/default-theme-config/README.md index f6737edd30..2643db6de1 100644 --- a/docs/default-theme-config/README.md +++ b/docs/default-theme-config/README.md @@ -39,6 +39,19 @@ If you want to use a completely custom homepage layout, you can also use a [Cust The Navbar may contain your page title, [Search Box](#search-box), [Navbar Links](#navbar-links), [Languages](../guide/i18n.md) and [Repository Link](#git-repo-and-edit-links), all of them depends on your configuration. +### Navbar Logo + +You can add a logo to the navbar via `themeConfig.logo`. Logo can be placed in [public folder](../guide/assets.md#public-files). + +``` js +// .vuepress/config.js +module.exports = { + themeConfig: { + logo: '/assets/img/logo.png', + } +} +``` + ### Navbar Links You can add links to the navbar via `themeConfig.nav`: From 947a70f524aae6131a02536973f2529ba36bd1a9 Mon Sep 17 00:00:00 2001 From: Wolfgang Ziegler Date: Mon, 11 Feb 2019 15:41:45 +0100 Subject: [PATCH 20/48] fix($theme-default): bitbucket edit link goes to wrong link (#1277) This backports the fix from #1235 to 0.x --- lib/default-theme/Page.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/default-theme/Page.vue b/lib/default-theme/Page.vue index 37d65b41a7..0a45b0b222 100644 --- a/lib/default-theme/Page.vue +++ b/lib/default-theme/Page.vue @@ -147,6 +147,7 @@ export default { : repo return ( base.replace(endingSlashRE, '') + + `/src` + `/${docsBranch}` + (docsDir ? '/' + docsDir.replace(endingSlashRE, '') : '') + path + From 3b15f9fd04321f2abff631588697009ec2f7842a Mon Sep 17 00:00:00 2001 From: Shigma <33423008+Shigma@users.noreply.github.com> Date: Sun, 17 Feb 2019 18:10:54 +0800 Subject: [PATCH 21/48] fix: remove colon as separator (close: #1297) (#1305) --- lib/markdown/snippet.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/markdown/snippet.js b/lib/markdown/snippet.js index a677e12f77..b21c0df93a 100644 --- a/lib/markdown/snippet.js +++ b/lib/markdown/snippet.js @@ -24,7 +24,7 @@ module.exports = function snippet (md, options = {}) { const start = pos + 3 const end = state.skipSpacesBack(max, pos) const rawPath = state.src.slice(start, end).trim().replace(/^@/, root) - const filename = rawPath.split(/[{:\s]/).shift() + const filename = rawPath.split(/[{\s]/).shift() const content = fs.existsSync(filename) ? fs.readFileSync(filename).toString() : 'Not found: ' + filename const meta = rawPath.replace(filename, '') From e87df7353f950771a21406912db8fd3a417834a6 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 18 Feb 2019 01:28:02 +0800 Subject: [PATCH 22/48] 0.14.9 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index fc466cf2a7..c2835569f4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.8", + "version": "0.14.9", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From e8f272c476483f93f53a48f25374c721fb93995a Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 18 Feb 2019 01:28:04 +0800 Subject: [PATCH 23/48] chore: changelog --- CHANGELOG.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d4c0a35f5a..5582686af2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,15 @@ + +## [0.14.9](https://github.com/vuejs/vuepress/compare/v0.14.8...v0.14.9) (2019-02-17) + + +### Bug Fixes + +* **$theme-default:** bitbucket edit link goes to wrong link ([#1277](https://github.com/vuejs/vuepress/issues/1277)) ([947a70f](https://github.com/vuejs/vuepress/commit/947a70f)), closes [#1235](https://github.com/vuejs/vuepress/issues/1235) +* remove colon as separator (close: [#1297](https://github.com/vuejs/vuepress/issues/1297)) ([#1305](https://github.com/vuejs/vuepress/issues/1305)) ([3b15f9f](https://github.com/vuejs/vuepress/commit/3b15f9f)) +* sidebar button should be hidden when there are no sidebars in mobile side ([#1159](https://github.com/vuejs/vuepress/issues/1159)) ([b7f3ac4](https://github.com/vuejs/vuepress/commit/b7f3ac4)) + + + ## [0.14.8](https://github.com/vuejs/vuepress/compare/v0.14.7...v0.14.8) (2018-11-26) From 1c3b7f7c458e707edcbe0c90c41a267e7e6bd4c9 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Mon, 18 Feb 2019 01:30:38 +0800 Subject: [PATCH 24/48] chore: changelog --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5582686af2..0b9ae098ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,8 +5,8 @@ ### Bug Fixes * **$theme-default:** bitbucket edit link goes to wrong link ([#1277](https://github.com/vuejs/vuepress/issues/1277)) ([947a70f](https://github.com/vuejs/vuepress/commit/947a70f)), closes [#1235](https://github.com/vuejs/vuepress/issues/1235) -* remove colon as separator (close: [#1297](https://github.com/vuejs/vuepress/issues/1297)) ([#1305](https://github.com/vuejs/vuepress/issues/1305)) ([3b15f9f](https://github.com/vuejs/vuepress/commit/3b15f9f)) -* sidebar button should be hidden when there are no sidebars in mobile side ([#1159](https://github.com/vuejs/vuepress/issues/1159)) ([b7f3ac4](https://github.com/vuejs/vuepress/commit/b7f3ac4)) +* **$theme-default:** sidebar button should be hidden when there are no sidebars in mobile side ([#1159](https://github.com/vuejs/vuepress/issues/1159)) ([b7f3ac4](https://github.com/vuejs/vuepress/commit/b7f3ac4)) +* **$core:** remove colon as separator (close: [#1297](https://github.com/vuejs/vuepress/issues/1297)) ([#1305](https://github.com/vuejs/vuepress/issues/1305)) ([3b15f9f](https://github.com/vuejs/vuepress/commit/3b15f9f)) From 566a0235d5f27d8b4c4496e6fc3c8656ac984f9d Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Fri, 22 Feb 2019 23:30:13 +0800 Subject: [PATCH 25/48] docs: add nav link to 1.x doc and update changelog link --- docs/.vuepress/config.js | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index e5ffe9ef06..c6b62e7cd5 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -62,8 +62,12 @@ module.exports = { }, { text: 'Changelog', - link: 'https://github.com/vuejs/vuepress/blob/master/CHANGELOG.md' - } + link: 'https://github.com/vuejs/vuepress/blob/0.x/CHANGELOG.md' + }, + { + text: '1.x', + link: 'https://v1.vuepress.vuejs.org/' + }, ], sidebar: { '/guide/': genSidebarConfig('Guide') @@ -95,8 +99,12 @@ module.exports = { }, { text: 'Changelog', - link: 'https://github.com/vuejs/vuepress/blob/master/CHANGELOG.md' - } + link: 'https://github.com/vuejs/vuepress/blob/0.x/CHANGELOG.md' + }, + { + text: '1.x', + link: 'https://v1.vuepress.vuejs.org/' + }, ], sidebar: { '/zh/guide/': genSidebarConfig('指南') From a30f6fa363a2f424d8c8494f34bfe4689bc6c03c Mon Sep 17 00:00:00 2001 From: Evan You Date: Fri, 22 Feb 2019 14:16:04 -0500 Subject: [PATCH 26/48] fix bit image --- docs/.vuepress/components/Bit.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/.vuepress/components/Bit.vue b/docs/.vuepress/components/Bit.vue index efb6fa931f..51d4048aba 100644 --- a/docs/.vuepress/components/Bit.vue +++ b/docs/.vuepress/components/Bit.vue @@ -2,7 +2,7 @@

This project is sponsored by - bit + bit

From ae7013f09489ac3c060273c830f79cde2bda1eaa Mon Sep 17 00:00:00 2001 From: Jeff Wen Date: Wed, 27 Feb 2019 23:49:30 +0800 Subject: [PATCH 27/48] fix: missing sidebar button on a mobile homepage (close: #1355) (#1361) * Revert "fix: sidebar button should be hidden when there are no sidebars in mobile side (#1159)" This reverts commit b7f3ac48dcf6866c2b552be8ad1e1c45a729a1f0. * Fix indent --- lib/default-theme/styles/theme.styl | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lib/default-theme/styles/theme.styl b/lib/default-theme/styles/theme.styl index 5821c070ba..f54654a36c 100644 --- a/lib/default-theme/styles/theme.styl +++ b/lib/default-theme/styles/theme.styl @@ -178,11 +178,6 @@ th, td top 0 .custom-layout padding-top 0 - &.no-sidebar - .sidebar-button - display: none - .navbar - padding-left 1.5rem @media (min-width: ($MQMobile + 1px)) From 7246e5ef787f544855c58b4b60a440f5f3308dac Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Sun, 3 Mar 2019 01:48:28 +0800 Subject: [PATCH 28/48] 0.14.10 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c2835569f4..6c60917474 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress", - "version": "0.14.9", + "version": "0.14.10", "description": "Minimalistic doc generator with Vue component based layout system", "main": "lib/index.js", "bin": { From 2d22869882b3c15facb473e46f40a464d12be053 Mon Sep 17 00:00:00 2001 From: ULIVZ <472590061@qq.com> Date: Sun, 3 Mar 2019 01:48:31 +0800 Subject: [PATCH 29/48] chore: changelog --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0b9ae098ff..cc86b1be1e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,13 @@ + +## [0.14.10](https://github.com/vuejs/vuepress/compare/v0.14.9...v0.14.10) (2019-03-02) + + +### Bug Fixes + +* missing sidebar button on a mobile homepage (close: [#1355](https://github.com/vuejs/vuepress/issues/1355)) ([#1361](https://github.com/vuejs/vuepress/issues/1361)) ([ae7013f](https://github.com/vuejs/vuepress/commit/ae7013f)), closes [#1159](https://github.com/vuejs/vuepress/issues/1159) + + + ## [0.14.9](https://github.com/vuejs/vuepress/compare/v0.14.8...v0.14.9) (2019-02-17) From 23d71d7b6d542fbbf73e99c7bb5ef2552c092337 Mon Sep 17 00:00:00 2001 From: Danny Guo Date: Wed, 13 Mar 2019 10:35:22 -0400 Subject: [PATCH 30/48] docs: fix a typo (#1437) --- docs/guide/markdown.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/guide/markdown.md b/docs/guide/markdown.md index 9831cfb13f..53421a1b06 100644 --- a/docs/guide/markdown.md +++ b/docs/guide/markdown.md @@ -48,7 +48,7 @@ Given the following directory structure: ### External Links -Outbound links automatically gets `target="_blank" rel="noopener noreferrer"`: +Outbound links automatically get `target="_blank" rel="noopener noreferrer"`: - [vuejs.org](https://vuejs.org) - [VuePress on GitHub](https://github.com/vuejs/vuepress) From cfb275a700fb6e8d15c3b7945850532ec4a7cb32 Mon Sep 17 00:00:00 2001 From: Jaemin Date: Thu, 14 Mar 2019 01:17:49 +0900 Subject: [PATCH 31/48] chore($theme-default): cursor pointer (#867) --- lib/default-theme/SidebarButton.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/default-theme/SidebarButton.vue b/lib/default-theme/SidebarButton.vue index 0a22243456..5e823d36a8 100644 --- a/lib/default-theme/SidebarButton.vue +++ b/lib/default-theme/SidebarButton.vue @@ -17,6 +17,7 @@ padding 0.6rem top 0.6rem left 1rem + cursor pointer .icon display block width 1.25rem From 3cc805d9a231bda00a91b253716e0882a4a2bb4a Mon Sep 17 00:00:00 2001 From: Rob Muhlestein Date: Wed, 13 Mar 2019 12:25:55 -0400 Subject: [PATCH 32/48] fix($theme-default): hero image resizing (#873) --- lib/default-theme/Home.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/default-theme/Home.vue b/lib/default-theme/Home.vue index a172eb9b3c..38270f2fcb 100644 --- a/lib/default-theme/Home.vue +++ b/lib/default-theme/Home.vue @@ -80,6 +80,7 @@ export default { .hero text-align center img + max-width 100% max-height 280px display block margin 3rem auto 1.5rem From 7b4c4b0d3daf30f29b65671290b11b8fa830c8e4 Mon Sep 17 00:00:00 2001 From: Nick Evans Date: Wed, 3 Apr 2019 10:34:17 -0500 Subject: [PATCH 33/48] fix($markdown): code snippets should not split path on space (close: #1505)(#1509) --- lib/markdown/snippet.js | 2 +- test/markdown/__snapshots__/snippet.spec.js.snap | 9 +++++++++ .../fragments/code-snippet-with-space-in-path.md | 1 + test/markdown/fragments/snippet with spaces.js | 3 +++ test/markdown/snippet.spec.js | 6 ++++++ 5 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 test/markdown/fragments/code-snippet-with-space-in-path.md create mode 100644 test/markdown/fragments/snippet with spaces.js diff --git a/lib/markdown/snippet.js b/lib/markdown/snippet.js index b21c0df93a..b8d93fc753 100644 --- a/lib/markdown/snippet.js +++ b/lib/markdown/snippet.js @@ -24,7 +24,7 @@ module.exports = function snippet (md, options = {}) { const start = pos + 3 const end = state.skipSpacesBack(max, pos) const rawPath = state.src.slice(start, end).trim().replace(/^@/, root) - const filename = rawPath.split(/[{\s]/).shift() + const filename = rawPath.split(/{/).shift().trim() const content = fs.existsSync(filename) ? fs.readFileSync(filename).toString() : 'Not found: ' + filename const meta = rawPath.replace(filename, '') diff --git a/test/markdown/__snapshots__/snippet.spec.js.snap b/test/markdown/__snapshots__/snippet.spec.js.snap index 3c97bcddcc..f2f3ae5d89 100644 --- a/test/markdown/__snapshots__/snippet.spec.js.snap +++ b/test/markdown/__snapshots__/snippet.spec.js.snap @@ -1,5 +1,14 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`snippet import snipets when the file has a space in the file path 1`] = ` +
+
 
+
+
+
+
export default function () { // .. } +`; + exports[`snippet import snippet 1`] = `
export default function () {
   // ..
diff --git a/test/markdown/fragments/code-snippet-with-space-in-path.md b/test/markdown/fragments/code-snippet-with-space-in-path.md
new file mode 100644
index 0000000000..57351aadbf
--- /dev/null
+++ b/test/markdown/fragments/code-snippet-with-space-in-path.md
@@ -0,0 +1 @@
+<<< @/test/markdown/fragments/snippet with spaces.js {1}
diff --git a/test/markdown/fragments/snippet with spaces.js b/test/markdown/fragments/snippet with spaces.js
new file mode 100644
index 0000000000..575039d1ec
--- /dev/null
+++ b/test/markdown/fragments/snippet with spaces.js	
@@ -0,0 +1,3 @@
+export default function () {
+  // ..
+}
diff --git a/test/markdown/snippet.spec.js b/test/markdown/snippet.spec.js
index 0131132916..e99ed956ad 100644
--- a/test/markdown/snippet.spec.js
+++ b/test/markdown/snippet.spec.js
@@ -23,4 +23,10 @@ describe('snippet', () => {
     const output = mdH.render(input)
     expect(output).toMatchSnapshot()
   })
+
+  test('import snipets when the file has a space in the file path', async () => {
+    const input = await getFragment('code-snippet-with-space-in-path')
+    const output = mdH.render(input)
+    expect(output).toMatchSnapshot()
+  })
 })

From 09f53469eaaae527bcaf18e40d01b5d7bc42962e Mon Sep 17 00:00:00 2001
From: Siddhartha Crypto <33014953+siddhartha-crypto@users.noreply.github.com>
Date: Sat, 6 Apr 2019 08:57:57 -0800
Subject: [PATCH 34/48] docs: add information about absolute paths for
 `.vuepress/public` dir (#1511)

---
 docs/guide/assets.md | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/docs/guide/assets.md b/docs/guide/assets.md
index 04a6eb31fe..c458a03754 100644
--- a/docs/guide/assets.md
+++ b/docs/guide/assets.md
@@ -35,6 +35,15 @@ module.exports = {
 
 Sometimes you may need to provide static assets that are not directly referenced in any of your markdown or theme components - for example, favicons and PWA icons. In such cases you can put them inside `.vuepress/public` and they will be copied to the root of the generated directory.
 
+Always use absolute paths when calling assets from the `.vuepress/public` directory:
+
+```css
+@font-face {
+  font-family: 'Roboto';
+  src: url('http://github.com/Roboto-Regular.woff2') format('woff2');
+}
+```
+
 ## Base URL
 
 If your site is deployed to a non-root URL, you will need to set the `base` option in `.vuepress/config.js`. For example, if you plan to deploy your site to `https://foo.github.io/bar/`, then `base` should be set to `"/bar/"` (it should always start and end with a slash).

From aaf4a7bca073aa50e8da110a06baef2030a396c9 Mon Sep 17 00:00:00 2001
From: EGOIST <0x142857@gmail.com>
Date: Sat, 13 Apr 2019 23:49:13 +0800
Subject: [PATCH 35/48] fix($core): unexpected webpack externals (close: #451)
 (#1539)

---
 lib/webpack/createServerConfig.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/webpack/createServerConfig.js b/lib/webpack/createServerConfig.js
index e9f098354b..f0f05092d8 100644
--- a/lib/webpack/createServerConfig.js
+++ b/lib/webpack/createServerConfig.js
@@ -11,7 +11,7 @@ module.exports = function createServerConfig (options, cliOptions) {
 
   config
     .target('node')
-    .externals([/^vue|vue-router$/])
+    .externals([/^(vue|vue-router)$/])
     .devtool('source-map')
 
   // no need to minimize server build

From 6897b421b5d3ce0e07a2942ad961adb2f0401271 Mon Sep 17 00:00:00 2001
From: ULIVZ <472590061@qq.com>
Date: Sat, 13 Apr 2019 23:53:40 +0800
Subject: [PATCH 36/48] 0.14.11

---
 package.json | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package.json b/package.json
index 6c60917474..26571fc032 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "vuepress",
-  "version": "0.14.10",
+  "version": "0.14.11",
   "description": "Minimalistic doc generator with Vue component based layout system",
   "main": "lib/index.js",
   "bin": {

From 15377f6c7460dc8459c388d7f56b0b494a8ad4b9 Mon Sep 17 00:00:00 2001
From: ULIVZ <472590061@qq.com>
Date: Sat, 13 Apr 2019 23:53:43 +0800
Subject: [PATCH 37/48] chore: changelog

---
 CHANGELOG.md | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index cc86b1be1e..229de1874b 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,15 @@
+
+## [0.14.11](https://github.com/vuejs/vuepress/compare/v0.14.10...v0.14.11) (2019-04-13)
+
+
+### Bug Fixes
+
+* **$core:** unexpected webpack externals (close: [#451](https://github.com/vuejs/vuepress/issues/451)) ([#1539](https://github.com/vuejs/vuepress/issues/1539)) ([aaf4a7b](https://github.com/vuejs/vuepress/commit/aaf4a7b))
+* **$markdown:** code snippets should not split path on space (close: [#1505](https://github.com/vuejs/vuepress/issues/1505))([#1509](https://github.com/vuejs/vuepress/issues/1509)) ([7b4c4b0](https://github.com/vuejs/vuepress/commit/7b4c4b0))
+* **$theme-default:** hero image resizing ([#873](https://github.com/vuejs/vuepress/issues/873)) ([3cc805d](https://github.com/vuejs/vuepress/commit/3cc805d))
+
+
+
 
 ## [0.14.10](https://github.com/vuejs/vuepress/compare/v0.14.9...v0.14.10) (2019-03-02)
 

From ab5814d66b35f9a97a107aa30b3d3b4b382ea47d Mon Sep 17 00:00:00 2001
From: Charles Villard 
Date: Sun, 14 Apr 2019 13:44:08 -0400
Subject: [PATCH 38/48] docs: add CSS preprocessor tip to Build Pipeline
 section (#1522)

---
 docs/config/README.md | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/docs/config/README.md b/docs/config/README.md
index 1899496557..096f5c6e1f 100644
--- a/docs/config/README.md
+++ b/docs/config/README.md
@@ -199,6 +199,10 @@ module.exports = {
 
 ## Build Pipeline
 
+:::tip Configuring CSS Pre-processors
+VuePress comes with built-in webpack config for the CSS pre-processors listed below. For more information on installation these or pre-processors without built-in support, see [Using Pre-Processors](../guide/using-vue.md#using-pre-processors) for more information.
+:::
+
 ### postcss
 
 - Type: `Object`

From 6e4d8f475862f57486e906e812efa1545b629c90 Mon Sep 17 00:00:00 2001
From: Ed Bailey 
Date: Wed, 1 May 2019 06:30:50 +0100
Subject: [PATCH 39/48] docs: correct the link for 0.x slugify source (#1571)

---
 docs/config/README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/config/README.md b/docs/config/README.md
index 096f5c6e1f..403deb186c 100644
--- a/docs/config/README.md
+++ b/docs/config/README.md
@@ -154,7 +154,7 @@ Whether to show line numbers to the left of each code blocks.
 ### markdown.slugify
 
 - Type: `Function`
-- Default: [source](https://github.com/vuejs/vuepress/blob/master/lib/markdown/slugify.js)
+- Default: [source](https://github.com/vuejs/vuepress/blob/0.x/lib/markdown/slugify.js)
 
 Function for transforming header texts into slugs. This affects the ids/links generated for header anchors, table of contents and sidebar links.
 

From 3852645fa508043b9b80c913da9660959e990ab0 Mon Sep 17 00:00:00 2001
From: Evan You 
Date: Wed, 8 May 2019 09:00:31 +0800
Subject: [PATCH 40/48] chore: update sponsor link

---
 docs/.vuepress/components/Bit.vue | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/.vuepress/components/Bit.vue b/docs/.vuepress/components/Bit.vue
index 51d4048aba..0f3d562117 100644
--- a/docs/.vuepress/components/Bit.vue
+++ b/docs/.vuepress/components/Bit.vue
@@ -1,6 +1,6 @@