From 4226abf5b2f6167ea983e0a8a07ce3ac27e6babd Mon Sep 17 00:00:00 2001 From: Parth Patel Date: Thu, 20 Jun 2019 13:51:22 -0400 Subject: [PATCH 1/6] Replace apostrophe with empty string in header This change is to replicate the github behviour with respect to apostrophe in headers. When there is an apostrophe in a header, github replaces it with empty string when creating an anchor link to that header. Docusaurus should follow the same convention. --- packages/docusaurus-1.x/lib/core/toSlug.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/docusaurus-1.x/lib/core/toSlug.js b/packages/docusaurus-1.x/lib/core/toSlug.js index 27d37153467a..2b649283423a 100644 --- a/packages/docusaurus-1.x/lib/core/toSlug.js +++ b/packages/docusaurus-1.x/lib/core/toSlug.js @@ -45,8 +45,8 @@ module.exports = (string, context = {}) => { .replace(new RegExp(`[${accents}]`, 'g'), c => without.charAt(accents.indexOf(c)), ) - // Replace `.`, `(` and `?` with blank string like Github does - .replace(/\.|\(|\?/g, '') + // Replace `’`, .`, `(` and `?` with blank string like Github does + .replace(/’|\.|\(|\?/g, '') // Dash special characters except '_' (underscore) .replace(exceptAlphanumAndUnderscore, '-') // Compress multiple dash From 177b13c5b653b8eb7bdd4b504951d575d0d49038 Mon Sep 17 00:00:00 2001 From: spaghettiwews Date: Fri, 21 Jun 2019 17:51:06 +0200 Subject: [PATCH 2/6] docs: showcase user paynow (#1619) --- website-1.x/data/users.js | 7 +++++++ website-1.x/static/img/users/paynow.svg | 19 +++++++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 website-1.x/static/img/users/paynow.svg diff --git a/website-1.x/data/users.js b/website-1.x/data/users.js index da2d4259f443..7a70aaebac17 100644 --- a/website-1.x/data/users.js +++ b/website-1.x/data/users.js @@ -337,6 +337,13 @@ module.exports = [ fbOpenSource: false, pinned: false, }, + { + caption: 'Paynow', + image: '/img/users/paynow.svg', + infoLink: 'https://developers.paynow.co.zw/', + fbOpenSource: false, + pinned: false, + }, { caption: 'pnpm', image: 'https://pnpm.js.org/img/pnpm.svg', diff --git a/website-1.x/static/img/users/paynow.svg b/website-1.x/static/img/users/paynow.svg new file mode 100644 index 000000000000..a39d0629cd6b --- /dev/null +++ b/website-1.x/static/img/users/paynow.svg @@ -0,0 +1,19 @@ + + + + + + From 9e84525bcfbbd91e53ad00aebb8be36cddb8feaf Mon Sep 17 00:00:00 2001 From: Dennis Effa Amponsah Date: Fri, 21 Jun 2019 17:16:51 -0700 Subject: [PATCH 3/6] docs: showcase user Libra (#1616) --- website-1.x/data/users.js | 7 +++++++ website-1.x/static/img/users/libra.svg | 1 + 2 files changed, 8 insertions(+) create mode 100644 website-1.x/static/img/users/libra.svg diff --git a/website-1.x/data/users.js b/website-1.x/data/users.js index 7a70aaebac17..1c3b772a22a4 100644 --- a/website-1.x/data/users.js +++ b/website-1.x/data/users.js @@ -245,6 +245,13 @@ module.exports = [ fbOpenSource: false, pinned: false, }, + { + caption: 'Libra', + image: '/img/users/libra.svg', + infoLink: 'https://developers.libra.org', + fbOpenSource: false, + pinned: true, + }, { caption: 'MakeItOpen', image: '/img/users/makeitopen.png', diff --git a/website-1.x/static/img/users/libra.svg b/website-1.x/static/img/users/libra.svg new file mode 100644 index 000000000000..b2ad30823bd0 --- /dev/null +++ b/website-1.x/static/img/users/libra.svg @@ -0,0 +1 @@ + From d645a78ad8fc4c6b6900083f0a31446d0d1cd3b4 Mon Sep 17 00:00:00 2001 From: Yangshun Tay Date: Fri, 21 Jun 2019 17:22:36 -0700 Subject: [PATCH 4/6] Update toSlug.js --- packages/docusaurus-1.x/lib/core/toSlug.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/docusaurus-1.x/lib/core/toSlug.js b/packages/docusaurus-1.x/lib/core/toSlug.js index 2b649283423a..cc53e66a0896 100644 --- a/packages/docusaurus-1.x/lib/core/toSlug.js +++ b/packages/docusaurus-1.x/lib/core/toSlug.js @@ -45,8 +45,8 @@ module.exports = (string, context = {}) => { .replace(new RegExp(`[${accents}]`, 'g'), c => without.charAt(accents.indexOf(c)), ) - // Replace `’`, .`, `(` and `?` with blank string like Github does - .replace(/’|\.|\(|\?/g, '') + // Replace `'`, `.`, `(` and `?` with blank string like GitHub does + .replace(/'|\.|\(|\?/g, '') // Dash special characters except '_' (underscore) .replace(exceptAlphanumAndUnderscore, '-') // Compress multiple dash From 2561fc64ec1647205fe56022adc255c33278df35 Mon Sep 17 00:00:00 2001 From: Yangshun Tay Date: Fri, 21 Jun 2019 17:28:14 -0700 Subject: [PATCH 5/6] Update toSlug.js --- packages/docusaurus-1.x/lib/core/toSlug.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/docusaurus-1.x/lib/core/toSlug.js b/packages/docusaurus-1.x/lib/core/toSlug.js index cc53e66a0896..202f608b92b5 100644 --- a/packages/docusaurus-1.x/lib/core/toSlug.js +++ b/packages/docusaurus-1.x/lib/core/toSlug.js @@ -45,8 +45,8 @@ module.exports = (string, context = {}) => { .replace(new RegExp(`[${accents}]`, 'g'), c => without.charAt(accents.indexOf(c)), ) - // Replace `'`, `.`, `(` and `?` with blank string like GitHub does - .replace(/'|\.|\(|\?/g, '') + // Replace `’`, `.`, `(` and `?` with blank string like GitHub does + .replace(/’|\.|\(|\?/g, '') // Dash special characters except '_' (underscore) .replace(exceptAlphanumAndUnderscore, '-') // Compress multiple dash From 380bab423b52a17e618f2c2cb6f2d85f26ec667c Mon Sep 17 00:00:00 2001 From: Yangshun Tay Date: Fri, 21 Jun 2019 17:31:14 -0700 Subject: [PATCH 6/6] Update toSlug.js --- packages/docusaurus-1.x/lib/core/toSlug.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/docusaurus-1.x/lib/core/toSlug.js b/packages/docusaurus-1.x/lib/core/toSlug.js index 202f608b92b5..e81f7d73f2c2 100644 --- a/packages/docusaurus-1.x/lib/core/toSlug.js +++ b/packages/docusaurus-1.x/lib/core/toSlug.js @@ -45,8 +45,8 @@ module.exports = (string, context = {}) => { .replace(new RegExp(`[${accents}]`, 'g'), c => without.charAt(accents.indexOf(c)), ) - // Replace `’`, `.`, `(` and `?` with blank string like GitHub does - .replace(/’|\.|\(|\?/g, '') + // Replace `'`, `’`, `.`, `(` and `?` with blank string like GitHub does + .replace(/'|’|\.|\(|\?/g, '') // Dash special characters except '_' (underscore) .replace(exceptAlphanumAndUnderscore, '-') // Compress multiple dash