From 2a20d5b1a970ff88129da8e46a135d3d48b4db44 Mon Sep 17 00:00:00 2001 From: Zach Badgett Date: Wed, 17 Apr 2019 20:06:52 -0600 Subject: [PATCH 1/3] refactor: refactor code tab split --- packages/docusaurus-1.x/lib/core/Doc.js | 110 ++++++++++++++++++++++-- 1 file changed, 101 insertions(+), 9 deletions(-) diff --git a/packages/docusaurus-1.x/lib/core/Doc.js b/packages/docusaurus-1.x/lib/core/Doc.js index d31505f0bb5f..d13044039ea7 100644 --- a/packages/docusaurus-1.x/lib/core/Doc.js +++ b/packages/docusaurus-1.x/lib/core/Doc.js @@ -20,16 +20,108 @@ const translateThisDoc = translate( ); const splitTabsToTitleAndContent = content => { - const titles = content.match(//gms); - const tabs = content.split(//gms); - if (!titles || !tabs || !titles.length || !tabs.length) { - return []; + const lines = content.split(/\n/g); + let first = false; + let inBlock = false; + let whitespace = false; + const tc = []; + let current = { + content: [], + }; + lines.forEach(line => { + let pos = 0; + const end = line.length; + const isToken = (cline, cpos, ...chars) => { + for (let i = 0; i < chars.length; i++) { + if (cline.charCodeAt(cpos) !== chars[i]) { + return false; + } + cpos++; + } + return true; + }; + while (pos + 1 < end) { + // Skip all the whitespace when we first start the scan. + for (let max = end; pos < max; pos++) { + if (line.charCodeAt(pos) !== 0x20 && line.charCodeAt(pos) !== 0x0a) { + break; + } + whitespace = true; + } + // Check for the start of a comment: + for (let max = end; pos < max; pos++) { + const b = line.charCodeAt(pos); + if (b0 === 0x2d /* - */ && b1 === 0x2d /* - */) { + if (b !== 0x3e /* > */) { + throw new Error(`Invalid comment sequence "--"`); + } + break; + } + buf.push(b); + b0 = b1; + b1 = b; + } + // Clear the line out before we add it to content. + // This also means tabs can only be defined on a line by itself. + line = '\n'; + // Trim the last 2 characters: -- + current.title = String.fromCharCode(...buf) + .substring(0, buf.length - 2) + .trim(); + } + // If the first thing in a code tab is not a title it's invalid. + if (!first) { + throw new Error(`Invalid code tab markdown`); + } + // Check for code block: ``` + // If the line begins with whitespace we don't consider it a code block. + if ( + isToken(line, pos, 0x60 /* ` */, 0x60 /* ` */, 0x60 /* ` */) && + !whitespace + ) { + pos += 3; + inBlock = !inBlock; + } + pos++; + whitespace = false; + } + current.content.push(line); + }); + if (current !== null && current.title !== undefined) { + tc.push({ + title: current.title, + content: current.content.join('\n'), + }); } - tabs.shift(); - return titles.map((title, idx) => ({ - title: title.substring(4, title.length - 3).trim(), - content: tabs[idx], - })); + return tc; }; const cleanTheCodeTag = content => { From a6d8f25e9eb3e575d5b45e39ac9e1b40f5eaf0c5 Mon Sep 17 00:00:00 2001 From: Zach Badgett Date: Wed, 24 Apr 2019 19:08:40 -0600 Subject: [PATCH 2/3] Add split tab unit test --- .eslintignore | 1 + package.json | 2 + .../__fixtures__/website/i18n/en.json | 10 + .../__fixtures__/website/siteConfig.js | 64 +++ .../lib/core/__tests__/split-tab.test.js | 93 ++++ yarn.lock | 431 ++++++++++++++---- 6 files changed, 523 insertions(+), 78 deletions(-) create mode 100644 packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/i18n/en.json create mode 100644 packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/siteConfig.js create mode 100644 packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js diff --git a/.eslintignore b/.eslintignore index 839e0614c446..41d132a32969 100644 --- a/.eslintignore +++ b/.eslintignore @@ -9,3 +9,4 @@ website/ scripts packages/docusaurus-1.x/lib/core/metadata.js packages/docusaurus-1.x/lib/core/MetadataBlog.js +packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js diff --git a/package.json b/package.json index b5ded2d10e33..00f756c60ef5 100644 --- a/package.json +++ b/package.json @@ -15,6 +15,8 @@ "devDependencies": { "babel-core": "^7.0.0-0", "babel-eslint": "8", + "enzyme": "^3.9.0", + "enzyme-adapter-react-16": "^1.12.1", "eslint": "4.x", "eslint-config-airbnb": "17.1.0", "eslint-config-prettier": "^2.9.0", diff --git a/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/i18n/en.json b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/i18n/en.json new file mode 100644 index 000000000000..43c508fe876d --- /dev/null +++ b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/i18n/en.json @@ -0,0 +1,10 @@ +{ + "_comment": "This file is auto-generated by write-translations.js", + "localized-strings": { + }, + "pages-strings": { + "Help Translate|recruit community translators for your project": "Help Us Translate", + "Edit this Doc|recruitment message asking to edit the doc source": "Edit", + "Translate this Doc|recruitment message asking to translate the docs": "Translate" + } +} diff --git a/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/siteConfig.js b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/siteConfig.js new file mode 100644 index 000000000000..c3aadfd8fcad --- /dev/null +++ b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/website/siteConfig.js @@ -0,0 +1,64 @@ +/** + * Copyright (c) 2017-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +/* List of projects/orgs using your project for the users page */ + +const siteConfig = { + title: 'Docusaurus', + tagline: 'Easy to Maintain Open Source Documentation Websites', + url: 'https://docusaurus.io', + baseUrl: '/', + organizationName: 'facebook', + projectName: 'Docusaurus', + cname: 'docusaurus.io', + noIndex: false, + editUrl: 'https://github.com/facebook/docusaurus/edit/master/docs/', + headerLinks: [], + headerIcon: 'img/docusaurus.svg', + footerIcon: 'img/docusaurus_monochrome.svg', + favicon: 'img/docusaurus.ico', + algolia: { + apiKey: '3eb9507824b8be89e7a199ecaa1a9d2c', + indexName: 'docusaurus', + algoliaOptions: { + facetFilters: ['language:LANGUAGE', 'version:VERSION'], + }, + }, + colors: { + primaryColor: '#2E8555', + secondaryColor: '#205C3B', + }, + translationRecruitingLink: 'https://crowdin.com/project/docusaurus', + copyright: `Copyright © ${new Date().getFullYear()} Facebook Inc.`, + usePrism: ['jsx'], + highlight: { + theme: 'atom-one-dark', + }, + scripts: [ + 'https://buttons.github.io/buttons.js', + 'https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.0/clipboard.min.js', + '/js/code-blocks-buttons.js', + ], + gaTrackingId: 'UA-44373548-31', + facebookAppId: '199138890728411', + facebookComments: true, + twitter: 'true', + twitterUsername: 'docusaurus', + ogImage: 'img/docusaurus.png', + twitterImage: 'img/docusaurus.png', + onPageNav: 'separate', + cleanUrl: true, + scrollToTop: true, + scrollToTopOptions: { + zIndex: 100, + }, + enableUpdateTime: true, + enableUpdateBy: true, + docsSideNavCollapsible: true, +}; + +module.exports = siteConfig; diff --git a/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js b/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js new file mode 100644 index 000000000000..2066375c39d0 --- /dev/null +++ b/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js @@ -0,0 +1,93 @@ +/** + * Copyright (c) 2017-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + * + * @jest-environment jsdom + */ +process.cwd = () => `${__dirname}/__fixtures__/website`; + +const React = require('react'); +const {configure, mount} = require('enzyme'); +const Adapter = require('enzyme-adapter-react-16'); +const Doc = require('../Doc.js'); + +configure({adapter: new Adapter()}); + +describe('when code tabs are used correctly', () => { + let props; + let mountedDoc; + const docPage = () => { + if (!mountedDoc) { + mountedDoc = mount(); + } + return mountedDoc; + }; + beforeEach(() => { + props = { + content: ` + + +\`\`\`js +console.log('Hello, world!'); +\`\`\` + +\`\`\`py +print('Hello, world!') +\`\`\` + + +\`\`\`C +#include + +int main() { + printf("Hello World!"); + return 0; +} +\`\`\` + + +\`\`\`Pascal +program HelloWorld; +begin + WriteLn('Hello, world!'); +end. +\`\`\` + + + `, + metadata: {}, + config: {}, + }; + mountedDoc = undefined; + }); + it('renders tabs correctly', () => { + const node = docPage().getDOMNode(); + const firstTab = node.querySelector('[data-tab$="-content-2"]').textContent; + expect('JavaScript').toEqual(firstTab); + const secondTab = node.querySelector('[data-tab$="-content-3"]') + .textContent; + expect('Python').toEqual(secondTab); + const thirdTab = node.querySelector('[data-tab$="-content-4"]').textContent; + expect('C').toEqual(thirdTab); + const fourthTab = node.querySelector('[data-tab$="-content-5"]') + .textContent; + expect('Pascal').toEqual(fourthTab); + }); + it('renders content correctly', () => { + const node = docPage().getDOMNode(); + const firstContent = node.querySelector('[id$="-content-7"]').textContent; + expect("console.log('Hello, world!');\n").toEqual(firstContent); + const secondContent = node.querySelector('[id$="-content-8"]').textContent; + expect("print('Hello, world!')\n").toEqual(secondContent); + const thirdContent = node.querySelector('[id$="-content-9"]').textContent; + expect( + '#include int main() { printf("Hello World!"); return 0;}\n', + ).toEqual(thirdContent); + const fourthContent = node.querySelector('[id$="-content-10"]').textContent; + expect("program HelloWorld;begin WriteLn('Hello, world!');end.\n").toEqual( + fourthContent, + ); + }); +}); diff --git a/yarn.lock b/yarn.lock index 21243ecdd5e7..9c3e8b761201 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2069,6 +2069,22 @@ agentkeepalive@^3.4.1: dependencies: humanize-ms "^1.2.1" +airbnb-prop-types@^2.12.0: + version "2.13.2" + resolved "https://registry.yarnpkg.com/airbnb-prop-types/-/airbnb-prop-types-2.13.2.tgz#43147a5062dd2a4a5600e748a47b64004cc5f7fc" + integrity sha512-2FN6DlHr6JCSxPPi25EnqGaXC4OC3/B3k1lCd6MMYrZ51/Gf/1qDfaR+JElzWa+Tl7cY2aYOlsYJGFeQyVHIeQ== + dependencies: + array.prototype.find "^2.0.4" + function.prototype.name "^1.1.0" + has "^1.0.3" + is-regex "^1.0.4" + object-is "^1.0.1" + object.assign "^4.1.0" + object.entries "^1.1.0" + prop-types "^15.7.2" + prop-types-exact "^1.2.0" + react-is "^16.8.6" + ajv-errors@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/ajv-errors/-/ajv-errors-1.0.1.tgz#f35986aceb91afadec4102fbd85014950cefa64d" @@ -2247,7 +2263,7 @@ argparse@~0.1.15: integrity sha1-z9AeD7uj1srtBJ+9dY1A9lGW9Xw= dependencies: underscore "~1.7.0" - underscore.string "~3.3.5" + underscore.string "~2.4.0" aria-query@^3.0.0: version "3.0.0" @@ -2282,6 +2298,11 @@ array-equal@^1.0.0: resolved "https://registry.yarnpkg.com/array-equal/-/array-equal-1.0.0.tgz#8c2a5ef2472fd9ea742b04c77a75093ba2757c93" integrity sha1-jCpe8kcv2ep0KwTHenUJO6J1fJM= +array-filter@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-filter/-/array-filter-1.0.0.tgz#baf79e62e6ef4c2a4c0b831232daffec251f9d83" + integrity sha1-uveeYubvTCpMC4MSMtr/7CUfnYM= + array-filter@~0.0.0: version "0.0.1" resolved "https://registry.yarnpkg.com/array-filter/-/array-filter-0.0.1.tgz#7da8cf2e26628ed732803581fd21f67cacd2eeec" @@ -2347,6 +2368,23 @@ array-unique@^0.3.2: resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= +array.prototype.find@^2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/array.prototype.find/-/array.prototype.find-2.0.4.tgz#556a5c5362c08648323ddaeb9de9d14bc1864c90" + integrity sha1-VWpcU2LAhkgyPdrrnenRS8GGTJA= + dependencies: + define-properties "^1.1.2" + es-abstract "^1.7.0" + +array.prototype.flat@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/array.prototype.flat/-/array.prototype.flat-1.2.1.tgz#812db8f02cad24d3fab65dd67eabe3b8903494a4" + integrity sha512-rVqIs330nLJvfC7JqYvEWwqVr5QjYF1ib02i3YJtR/fICO6527Tjpc/e4Mvmxh3GIePPreRXMdaGyC99YphWEw== + dependencies: + define-properties "^1.1.2" + es-abstract "^1.10.0" + function-bind "^1.1.1" + arrify@^1.0.0, arrify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" @@ -3277,6 +3315,18 @@ cheerio@0.22.0, cheerio@^0.22.0: lodash.reject "^4.4.0" lodash.some "^4.4.0" +cheerio@^1.0.0-rc.2: + version "1.0.0-rc.3" + resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.3.tgz#094636d425b2e9c0f4eb91a46c05630c9a1a8bf6" + integrity sha512-0td5ijfUPuubwLUu0OBoe98gZj8C/AA+RW3v67GPlGOrvxWjZmBXiBCRU+I8VEiNyJzjth40POfHiz2RB3gImA== + dependencies: + css-select "~1.2.0" + dom-serializer "~0.1.1" + entities "~1.1.1" + htmlparser2 "^3.9.1" + lodash "^4.15.0" + parse5 "^3.0.1" + chokidar@^2.0.0, chokidar@^2.1.5: version "2.1.5" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.5.tgz#0ae8434d962281a5f56c72869e79cb6d9d86ad4d" @@ -3870,7 +3920,7 @@ core-js@^1.0.0: resolved "https://registry.yarnpkg.com/core-js/-/core-js-1.2.7.tgz#652294c14651db28fa93bd2d5ff2983a4f08c636" integrity sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY= -core-js@^2.5.7, core-js@^2.6.5: +core-js@^2.6.5: version "2.6.5" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.5.tgz#44bc8d249e7fb2ff5d00e0341a7ffb94fbf67895" integrity sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A== @@ -4547,6 +4597,11 @@ dir-glob@^2.2.1: dependencies: path-type "^3.0.0" +discontinuous-range@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/discontinuous-range/-/discontinuous-range-1.0.0.tgz#e38331f0844bba49b9a9cb71c771585aab1bc65a" + integrity sha1-44Mx8IRLukm5qctxx3FYWqsbxlo= + dns-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/dns-equal/-/dns-equal-1.0.0.tgz#b39e7f1da6eb0a75ba9c17324b34753c47e0654d" @@ -4595,6 +4650,60 @@ doctrine@^2.1.0: dependencies: esutils "^2.0.2" +docusaurus@^2.0.0-alpha.10: + version "2.0.0-alpha.10" + resolved "https://registry.yarnpkg.com/docusaurus/-/docusaurus-2.0.0-alpha.10.tgz#3759ccdf7403a58483b41fffb1cfe662e2b98fca" + integrity sha512-sucBSgmtCA+DOSYGdhXV3TmeBR6On2n/6BFQCJs3/if06W6DzLCLb2sC2Jo1PpXpopYvAjd9Sf91zwEvovLPIw== + dependencies: + "@babel/core" "^7.0.0" + "@babel/plugin-proposal-class-properties" "^7.0.0" + "@babel/plugin-proposal-object-rest-spread" "^7.0.0" + "@babel/polyfill" "^7.0.0" + "@babel/preset-env" "^7.0.0" + "@babel/preset-react" "^7.0.0" + "@babel/register" "^7.0.0" + "@babel/traverse" "^7.0.0" + "@babel/types" "^7.1.2" + autoprefixer "^9.1.5" + babylon "^6.17.4" + chalk "^2.1.0" + classnames "^2.2.6" + color "^2.0.1" + commander "^2.18.0" + cross-spawn "^6.0.5" + crowdin-cli "^0.3.0" + cssnano "^3.10.0" + deepmerge "^2.1.1" + escape-string-regexp "^1.0.5" + express "^4.15.3" + feed "^1.1.0" + fs-extra "^5.0.0" + gaze "^1.1.2" + glob "^7.1.3" + highlight.js "^9.12.0" + imagemin "^6.0.0" + imagemin-gifsicle "^6.0.1" + imagemin-jpegtran "^6.0.0" + imagemin-optipng "^6.0.0" + imagemin-svgo "^7.0.0" + lodash "^4.17.11" + markdown-toc "^1.2.0" + mkdirp "^0.5.1" + portfinder "^1.0.17" + postcss "^7.0.1" + prismjs "^1.15.0" + react "^16.5.0" + react-dev-utils "^5.0.2" + react-dom "^16.5.0" + remarkable "^1.7.1" + request "^2.87.0" + shelljs "^0.7.8" + sitemap "^1.13.0" + tcp-port-used "^0.1.2" + tiny-lr "^1.1.1" + tree-node-cli "^1.2.5" + truncate-html "^1.0.1" + dom-converter@^0.2: version "0.2.0" resolved "https://registry.yarnpkg.com/dom-converter/-/dom-converter-0.2.0.tgz#6721a9daee2e293682955b6afe416771627bb768" @@ -4602,7 +4711,7 @@ dom-converter@^0.2: dependencies: utila "~0.4" -dom-serializer@0, dom-serializer@~0.1.0: +dom-serializer@0, dom-serializer@~0.1.0, dom-serializer@~0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.1.1.tgz#1ec4059e284babed36eec2941d4a970a189ce7c0" integrity sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA== @@ -4828,6 +4937,58 @@ envify@^4.0.0: esprima "^4.0.0" through "~2.3.4" +enzyme-adapter-react-16@^1.12.1: + version "1.12.1" + resolved "https://registry.yarnpkg.com/enzyme-adapter-react-16/-/enzyme-adapter-react-16-1.12.1.tgz#6a2d74c80559d35ac0a91ca162fa45f4186290cf" + integrity sha512-GB61gvY97XvrA6qljExGY+lgI6BBwz+ASLaRKct9VQ3ozu0EraqcNn3CcrUckSGIqFGa1+CxO5gj5is5t3lwrw== + dependencies: + enzyme-adapter-utils "^1.11.0" + object.assign "^4.1.0" + object.values "^1.1.0" + prop-types "^15.7.2" + react-is "^16.8.6" + react-test-renderer "^16.0.0-0" + semver "^5.6.0" + +enzyme-adapter-utils@^1.11.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/enzyme-adapter-utils/-/enzyme-adapter-utils-1.11.0.tgz#6ffff782b1b57dd46c72a845a91fc4103956a117" + integrity sha512-0VZeoE9MNx+QjTfsjmO1Mo+lMfunucYB4wt5ficU85WB/LoetTJrbuujmHP3PJx6pSoaAuLA+Mq877x4LoxdNg== + dependencies: + airbnb-prop-types "^2.12.0" + function.prototype.name "^1.1.0" + object.assign "^4.1.0" + object.fromentries "^2.0.0" + prop-types "^15.7.2" + semver "^5.6.0" + +enzyme@^3.9.0: + version "3.9.0" + resolved "https://registry.yarnpkg.com/enzyme/-/enzyme-3.9.0.tgz#2b491f06ca966eb56b6510068c7894a7e0be3909" + integrity sha512-JqxI2BRFHbmiP7/UFqvsjxTirWoM1HfeaJrmVSZ9a1EADKkZgdPcAuISPMpoUiHlac9J4dYt81MC5BBIrbJGMg== + dependencies: + array.prototype.flat "^1.2.1" + cheerio "^1.0.0-rc.2" + function.prototype.name "^1.1.0" + has "^1.0.3" + html-element-map "^1.0.0" + is-boolean-object "^1.0.0" + is-callable "^1.1.4" + is-number-object "^1.0.3" + is-regex "^1.0.4" + is-string "^1.0.4" + is-subset "^0.1.1" + lodash.escape "^4.0.1" + lodash.isequal "^4.5.0" + object-inspect "^1.6.0" + object-is "^1.0.1" + object.assign "^4.1.0" + object.entries "^1.0.4" + object.values "^1.0.4" + raf "^3.4.0" + rst-selector-parser "^2.2.3" + string.prototype.trim "^1.1.2" + err-code@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/err-code/-/err-code-1.1.2.tgz#06e0116d3028f6aef4806849eb0ea6a748ae6960" @@ -4855,7 +5016,7 @@ error@^7.0.0: string-template "~0.2.1" xtend "~4.0.0" -es-abstract@^1.11.0, es-abstract@^1.12.0, es-abstract@^1.5.1, es-abstract@^1.7.0: +es-abstract@^1.10.0, es-abstract@^1.11.0, es-abstract@^1.12.0, es-abstract@^1.5.0, es-abstract@^1.5.1, es-abstract@^1.7.0: version "1.13.0" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.13.0.tgz#ac86145fdd5099d8dd49558ccba2eaf9b88e24e9" integrity sha512-vDZfg/ykNxQVwup/8E1BZhVzFfBxs9NqMzGcvIJrqg5k2/5Za2bWo40dK2J1pgLngZ7c+Shh8lwYtLGyrwPutg== @@ -5844,11 +6005,20 @@ fstream@^1.0.0, fstream@^1.0.2: mkdirp ">=0.5 0" rimraf "2" -function-bind@^1.1.1: +function-bind@^1.0.2, function-bind@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== +function.prototype.name@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.0.tgz#8bd763cc0af860a859cc5d49384d74b932cd2327" + integrity sha512-Bs0VRrTz4ghD8pTmbJQD1mZ8A/mN0ur/jGz+A6FBxPDUPkm1tNfF6bhTYPA7i7aF4lZJVr+OXTNNrnnIl58Wfg== + dependencies: + define-properties "^1.1.2" + function-bind "^1.1.1" + is-callable "^1.1.3" + functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" @@ -6489,16 +6659,6 @@ hmac-drbg@^1.0.0: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.1" -hoek@5.x.x: - version "5.0.4" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-5.0.4.tgz#0f7fa270a1cafeb364a4b2ddfaa33f864e4157da" - integrity sha512-Alr4ZQgoMlnere5FZJsIyfIjORBqZll5POhDsF4q64dPuJR6rNxXdDxtHSQq8OXRurhmx+PWYEE8bXRROY8h0w== - -hoek@6.x.x: - version "6.1.3" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-6.1.3.tgz#73b7d33952e01fe27a38b0457294b79dd8da242c" - integrity sha512-YXXAAhmF9zpQbC7LEcREFtXfGq5K1fmd+4PHkBq8NUqmzW3G+Dq10bI/i0KucLRwss3YYFQ0fSfoxBZYiGUqtQ== - hogan.js@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/hogan.js/-/hogan.js-3.0.2.tgz#4cd9e1abd4294146e7679e41d7898732b02c7bfd" @@ -6546,6 +6706,13 @@ html-comment-regex@^1.1.0: resolved "https://registry.yarnpkg.com/html-comment-regex/-/html-comment-regex-1.1.2.tgz#97d4688aeb5c81886a364faa0cad1dda14d433a7" integrity sha512-P+M65QY2JQ5Y0G9KKdlDpo0zK+/OHptU5AaBwUfAIDJZk1MYf32Frm84EcOytfJE0t5JvkAnKlmjsXDnWzCJmQ== +html-element-map@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/html-element-map/-/html-element-map-1.0.1.tgz#3c4fcb4874ebddfe4283b51c8994e7713782b592" + integrity sha512-BZSfdEm6n706/lBfXKWa4frZRZcT5k1cOusw95ijZsHlI+GdgY0v95h6IzO3iIDf2ROwq570YTwqNPqHcNMozw== + dependencies: + array-filter "^1.0.0" + html-encoding-sniffer@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" @@ -7073,6 +7240,11 @@ is-binary-path@^1.0.0: dependencies: binary-extensions "^1.0.0" +is-boolean-object@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.0.0.tgz#98f8b28030684219a95f375cfbd88ce3405dff93" + integrity sha1-mPiygDBoQhmpXzdc+9iM40Bd/5M= + is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" @@ -7083,7 +7255,7 @@ is-buffer@^2.0.0: resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.3.tgz#4ecf3fcf749cbd1e472689e109ac66261a25e725" integrity sha512-U15Q7MXTuZlrbymiz95PJpZxu8IlipAp4dtS3wOdgPXx3mqBnslrWU14kxfHB+Py/+2PVKSr37dMAgM2A4uArw== -is-callable@^1.1.4: +is-callable@^1.1.3, is-callable@^1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" integrity sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA== @@ -7233,6 +7405,11 @@ is-natural-number@^4.0.1: resolved "https://registry.yarnpkg.com/is-natural-number/-/is-natural-number-4.0.1.tgz#ab9d76e1db4ced51e35de0c72ebecf09f734cde8" integrity sha1-q5124dtM7VHjXeDHLr7PCfc0zeg= +is-number-object@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.3.tgz#f265ab89a9f445034ef6aff15a8f00b00f551799" + integrity sha1-8mWrian0RQNO9q/xWo8AsA9VF5k= + is-number@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-2.1.0.tgz#01fcbbb393463a548f2f466cce16dece49db908f" @@ -7366,6 +7543,11 @@ is-stream@^1.0.0, is-stream@^1.0.1, is-stream@^1.1.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= +is-string@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.4.tgz#cc3a9b69857d621e963725a24caeec873b826e64" + integrity sha1-zDqbaYV9Yh6WNyWiTK7shzuCbmQ= + is-subset@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/is-subset/-/is-subset-0.1.1.tgz#8a59117d932de1de00f245fcdd39ce43f1e939a6" @@ -7458,13 +7640,6 @@ isarray@^2.0.1: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.4.tgz#38e7bcbb0f3ba1b7933c86ba1894ddfc3781bbb7" integrity sha512-GMxXOiUirWg1xTKRipM0Ek07rX+ubx4nNVElTJdNLYmNO/2YrDkgJGw9CljXn+r4EWiDQg/8lsRdHyg2PJuUaA== -isemail@3.x.x: - version "3.2.0" - resolved "https://registry.yarnpkg.com/isemail/-/isemail-3.2.0.tgz#59310a021931a9fb06bbb51e155ce0b3f236832c" - integrity sha512-zKqkK+O+dGqevc93KNsbZ/TqTUFd46MwWjYOoMrjIMZ51eU7DtQG3Wmd9SQQT7i7RVnuTPEiYEWHU3MSbxC1Tg== - dependencies: - punycode "2.x.x" - isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" @@ -7939,15 +8114,6 @@ jest@^24.1.0: import-local "^2.0.0" jest-cli "^24.5.0" -joi@^13.0.0: - version "13.7.0" - resolved "https://registry.yarnpkg.com/joi/-/joi-13.7.0.tgz#cfd85ebfe67e8a1900432400b4d03bbd93fb879f" - integrity sha512-xuY5VkHfeOYK3Hdi91ulocfuFopwgbSORmIwzcwHKESQhC7w1kD5jaVSPnqDxS2I8t3RZ9omCKAxNwXN5zG1/Q== - dependencies: - hoek "5.x.x" - isemail "3.x.x" - topo "3.x.x" - jpegtran-bin@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/jpegtran-bin/-/jpegtran-bin-4.0.0.tgz#d00aed809fba7aa6f30817e59eee4ddf198f8f10" @@ -8427,6 +8593,11 @@ lodash.defaults@^4.0.1: resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" integrity sha1-0JF4cW/+pN3p5ft7N/bwgCJ0WAw= +lodash.escape@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-4.0.1.tgz#c9044690c21e04294beaa517712fded1fa88de98" + integrity sha1-yQRGkMIeBClL6qUXcS/e0fqI3pg= + lodash.filter@^4.4.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.filter/-/lodash.filter-4.6.0.tgz#668b1d4981603ae1cc5a6fa760143e480b4c4ace" @@ -8437,6 +8608,11 @@ lodash.flatten@^4.2.0: resolved "https://registry.yarnpkg.com/lodash.flatten/-/lodash.flatten-4.4.0.tgz#f31c22225a9632d2bbf8e4addbef240aa765a61f" integrity sha1-8xwiIlqWMtK7+OSt2+8kCqdlph8= +lodash.flattendeep@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz#fb030917f86a3134e5bc9bec0d69e0013ddfedb2" + integrity sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI= + lodash.foreach@^4.3.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.foreach/-/lodash.foreach-4.5.0.tgz#1a6a35eace401280c7f06dddec35165ab27e3e53" @@ -8447,6 +8623,11 @@ lodash.get@^4.4.2: resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" integrity sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk= +lodash.isequal@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0" + integrity sha1-QVxEePK8wwEgwizhDtMib30+GOA= + lodash.map@^4.4.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.map/-/lodash.map-4.6.0.tgz#771ec7839e3473d9c4cde28b19394c3562f4f6d3" @@ -8517,7 +8698,7 @@ lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= -lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.2.1, lodash@^4.3.0, lodash@~4.17.10: +lodash@^4.15.0, lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.2.1, lodash@^4.3.0, lodash@~4.17.10: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== @@ -9071,6 +9252,11 @@ modify-values@^1.0.0: resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.1.tgz#b3939fa605546474e3e3e3c63d64bd43b4ee6022" integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw== +moo@^0.4.3: + version "0.4.3" + resolved "https://registry.yarnpkg.com/moo/-/moo-0.4.3.tgz#3f847a26f31cf625a956a87f2b10fbc013bfd10e" + integrity sha512-gFD2xGCl8YFgGHsqJ9NKRVdwlioeW3mI1iqfLNYQOv0+6JRwG58Zk9DIGQgyIaffSYaO1xsKnMaYzzNr1KyIAw== + move-concurrently@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/move-concurrently/-/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92" @@ -9153,6 +9339,17 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= +nearley@^2.7.10: + version "2.16.0" + resolved "https://registry.yarnpkg.com/nearley/-/nearley-2.16.0.tgz#77c297d041941d268290ec84b739d0ee297e83a7" + integrity sha512-Tr9XD3Vt/EujXbZBv6UAHYoLUSMQAxSsTnm9K3koXzjzNWY195NqALeyrzLZBKzAkL3gl92BcSogqrHjD8QuUg== + dependencies: + commander "^2.19.0" + moo "^0.4.3" + railroad-diagrams "^1.0.0" + randexp "0.4.6" + semver "^5.4.1" + needle@^2.2.1: version "2.2.4" resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.4.tgz#51931bff82533b1928b7d1d69e01f1b00ffd2a4e" @@ -9493,14 +9690,6 @@ nth-check@^1.0.2, nth-check@~1.0.1: dependencies: boolbase "~1.0.0" -null-loader@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/null-loader/-/null-loader-1.0.0.tgz#90e85798e50e9dd1d568495a44e74829dec26744" - integrity sha512-mYLDjDVTkjTlFoidxRhzO75rdcwfVXfw5G5zpj8sXnBkHtKJxMk4hTcRR4i5SOhDB6EvcQuYriy6IV23eq6uog== - dependencies: - loader-utils "^1.2.3" - schema-utils "^1.0.0" - num2fraction@^1.2.2: version "1.2.2" resolved "https://registry.yarnpkg.com/num2fraction/-/num2fraction-1.2.2.tgz#6f682b6a027a4e9ddfa4564cd2589d1d4e669ede" @@ -9535,6 +9724,16 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" +object-inspect@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.6.0.tgz#c70b6cbf72f274aab4c34c0c82f5167bf82cf15b" + integrity sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ== + +object-is@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.0.1.tgz#0aa60ec9989a0b3ed795cf4d06f62cf1ad6539b6" + integrity sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY= + object-keys@^1.0.11, object-keys@^1.0.12, object-keys@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.0.tgz#11bd22348dd2e096a045ab06f6c85bcc340fa032" @@ -9557,7 +9756,7 @@ object.assign@^4.1.0: has-symbols "^1.0.0" object-keys "^1.0.11" -object.entries@^1.0.4: +object.entries@^1.0.4, object.entries@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.0.tgz#2024fc6d6ba246aee38bdb0ffd5cfbcf371b7519" integrity sha512-l+H6EQ8qzGRxbkHOd5I/aHRhHDKoQXQ8g0BYt4uSweQU1/J6dZUOyWh9a2Vky35YCKjzmgxOzta2hH6kf9HuXA== @@ -9592,7 +9791,7 @@ object.pick@^1.2.0, object.pick@^1.3.0: dependencies: isobject "^3.0.1" -object.values@^1.1.0: +object.values@^1.0.4, object.values@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.0.tgz#bf6810ef5da3e5325790eaaa2be213ea84624da9" integrity sha512-8mf0nKLAoFX6VlNVdhGj31SVYpaNFtUnuoOXWyFEstsWRgU837AK+JYM0iAxwkSzGRbwn8cbFmgbyxj1j4VbXg== @@ -10017,6 +10216,13 @@ parse5@4.0.0: resolved "https://registry.yarnpkg.com/parse5/-/parse5-4.0.0.tgz#6d78656e3da8d78b4ec0b906f7c08ef1dfe3f608" integrity sha512-VrZ7eOd3T1Fk4XWNXMgiGBK/z0MG48BWG2uQNU4I72fkQuKUTZpl+u9k+CxEG0twMVzSmXEEz12z5Fnw1jIQFA== +parse5@^3.0.1: + version "3.0.3" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-3.0.3.tgz#042f792ffdd36851551cf4e9e066b3874ab45b5c" + integrity sha512-rgO9Zg5LLLkfJF9E6CCmXlSE4UVceloys8JrFqCcHloC3usd/kJCyPDwH2SOlzix2j3xaP9sUX3e8+kvkuleAA== + dependencies: + "@types/node" "*" + parse5@^5.0.0: version "5.1.0" resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.0.tgz#c59341c9723f414c452975564c7c00a68d58acd2" @@ -10649,7 +10855,16 @@ promzard@^0.3.0: dependencies: read "1" -prop-types@^15.5.0, prop-types@^15.5.4, prop-types@^15.6.2: +prop-types-exact@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/prop-types-exact/-/prop-types-exact-1.2.0.tgz#825d6be46094663848237e3925a98c6e944e9869" + integrity sha512-K+Tk3Kd9V0odiXFP9fwDHUYRyvK3Nun3GVyPapSIs5OBkITAm15W0CPFD/YKTkMUAbc0b9CUwRQp2ybiBIq+eA== + dependencies: + has "^1.0.3" + object.assign "^4.1.0" + reflect.ownkeys "^0.2.0" + +prop-types@^15.5.0, prop-types@^15.5.3, prop-types@^15.5.4, prop-types@^15.6.2, prop-types@^15.7.2: version "15.7.2" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5" integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== @@ -10747,16 +10962,16 @@ punycode@1.3.2: resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" integrity sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0= -punycode@2.x.x, punycode@^2.1.0, punycode@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" - integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== - punycode@^1.2.4, punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= +punycode@^2.1.0, punycode@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + q@0.9.7: version "0.9.7" resolved "https://registry.yarnpkg.com/q/-/q-0.9.7.tgz#4de2e6cb3b29088c9e4cbc03bf9d42fb96ce2f75" @@ -10814,6 +11029,26 @@ quick-lru@^1.0.0: resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" integrity sha1-Q2CxfGETatOAeDl/8RQW4Ybc+7g= +raf@^3.4.0: + version "3.4.1" + resolved "https://registry.yarnpkg.com/raf/-/raf-3.4.1.tgz#0742e99a4a6552f445d73e3ee0328af0ff1ede39" + integrity sha512-Sq4CW4QhwOHE8ucn6J34MqtZCeWFP2aQSmrlroYgqAV1PjStIhJXxYuTgUIfkEk7zTLjmIjLmU5q+fbD1NnOJA== + dependencies: + performance-now "^2.1.0" + +railroad-diagrams@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/railroad-diagrams/-/railroad-diagrams-1.0.0.tgz#eb7e6267548ddedfb899c1b90e57374559cddb7e" + integrity sha1-635iZ1SN3t+4mcG5Dlc3RVnN234= + +randexp@0.4.6: + version "0.4.6" + resolved "https://registry.yarnpkg.com/randexp/-/randexp-0.4.6.tgz#e986ad5e5e31dae13ddd6f7b3019aa7c87f60ca3" + integrity sha512-80WNmd9DA0tmZrw9qQa62GPPWfuXJknrmVmLcxvq4uZBdYqb1wYoKTmnlGUchvVWe0XiLupYkBoXVOxz3C8DYQ== + dependencies: + discontinuous-range "1.0.0" + ret "~0.1.10" + randomatic@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/randomatic/-/randomatic-3.1.1.tgz#b776efc59375984e36c537b2f51a1f0aff0da1ed" @@ -10961,7 +11196,7 @@ react-helmet@^6.0.0-beta: react-fast-compare "^2.0.2" react-side-effect "^1.1.0" -react-is@^16.6.0, react-is@^16.7.0: +react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.6: version "16.8.6" resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz#5bbc1e2d29141c9fbdfed456343fe2bc430a6a16" integrity sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA== @@ -11027,6 +11262,25 @@ react-side-effect@^1.1.0: exenv "^1.2.1" shallowequal "^1.0.1" +react-test-renderer@^16.0.0-0: + version "16.8.6" + resolved "https://registry.yarnpkg.com/react-test-renderer/-/react-test-renderer-16.8.6.tgz#188d8029b8c39c786f998aa3efd3ffe7642d5ba1" + integrity sha512-H2srzU5IWYT6cZXof6AhUcx/wEyJddQ8l7cLM/F7gDXYyPr4oq+vCIxJYXVGhId1J706sqziAjuOEjyNkfgoEw== + dependencies: + object-assign "^4.1.1" + prop-types "^15.6.2" + react-is "^16.8.6" + scheduler "^0.13.6" + +react-youtube@^7.9.0: + version "7.9.0" + resolved "https://registry.yarnpkg.com/react-youtube/-/react-youtube-7.9.0.tgz#cf513c253581e1e45aa412a77d03420dfd7f7ba7" + integrity sha512-2+nBF4qP8nStYEILIO1/SylKOCnnJUxuZm+qCeWA0eeZxnWZIIixfAeAqbzblwx5L1n/26ACocy3epm9Glox8w== + dependencies: + fast-deep-equal "^2.0.1" + prop-types "^15.5.3" + youtube-player "^5.5.1" + react@^16.5.0, react@^16.8.4: version "16.8.5" resolved "https://registry.yarnpkg.com/react/-/react-16.8.5.tgz#49be3b655489d74504ad994016407e8a0445de66" @@ -11250,6 +11504,11 @@ reduce@^1.0.1: dependencies: object-keys "^1.1.0" +reflect.ownkeys@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/reflect.ownkeys/-/reflect.ownkeys-0.2.0.tgz#749aceec7f3fdf8b63f927a04809e90c5c0b3460" + integrity sha1-dJrO7H8/34tj+SegSAnpDFwLNGA= + refractor@^2.3.0: version "2.7.0" resolved "https://registry.yarnpkg.com/refractor/-/refractor-2.7.0.tgz#3ed9a96a619e75326a429e644241dea51be070a3" @@ -11502,7 +11761,7 @@ request-promise-native@^1.0.5: stealthy-require "^1.1.1" tough-cookie "^2.3.3" -request@^2.53.0, request@^2.87.0, request@^2.88.0: +request@^2.53.0, request@^2.87.0: version "2.88.0" resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== @@ -11648,6 +11907,14 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: hash-base "^3.0.0" inherits "^2.0.1" +rst-selector-parser@^2.2.3: + version "2.2.3" + resolved "https://registry.yarnpkg.com/rst-selector-parser/-/rst-selector-parser-2.2.3.tgz#81b230ea2fcc6066c89e3472de794285d9b03d91" + integrity sha1-gbIw6i/MYGbInjRy3nlChdmwPZE= + dependencies: + lodash.flattendeep "^4.4.0" + nearley "^2.7.10" + rsvp@^4.8.4: version "4.8.4" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.8.4.tgz#b50e6b34583f3dd89329a2f23a8a2be072845911" @@ -11684,11 +11951,6 @@ rx-lite@*, rx-lite@^4.0.8: resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= -rx@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" - integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I= - rxjs@^6.1.0, rxjs@^6.3.3, rxjs@^6.4.0: version "6.4.0" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.4.0.tgz#f3bb0fe7bda7fb69deac0c16f17b50b0b8790504" @@ -11746,6 +12008,14 @@ scheduler@^0.13.5: loose-envify "^1.1.0" object-assign "^4.1.1" +scheduler@^0.13.6: + version "0.13.6" + resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.13.6.tgz#466a4ec332467b31a91b9bf74e5347072e4cd889" + integrity sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + schema-utils@^0.4.5: version "0.4.7" resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-0.4.7.tgz#ba74f597d2be2ea880131746ee17d0a093c68187" @@ -11986,6 +12256,11 @@ simple-swizzle@^0.2.2: dependencies: is-arrayish "^0.3.1" +sister@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/sister/-/sister-3.0.1.tgz#a36ba6a1d1e46415ba16cb4ecefe14cbd8d82d1f" + integrity sha512-aG41gNRHRRxPq52MpX4vtm9tapnr6ENmHUx8LMAJWCOplEMwXzh/dp5WIo52Wl8Zlc/VUyHLJ2snX0ck+Nma9g== + sisteransi@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.0.tgz#77d9622ff909080f1c19e5f4a1df0c1b0a27b88c" @@ -12436,6 +12711,15 @@ string-width@^1.0.1: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" +string.prototype.trim@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/string.prototype.trim/-/string.prototype.trim-1.1.2.tgz#d04de2c89e137f4d7d206f086b5ed2fae6be8cea" + integrity sha1-0E3iyJ4Tf019IG8Ia17S+ua+jOo= + dependencies: + define-properties "^1.1.2" + es-abstract "^1.5.0" + function-bind "^1.0.2" + string_decoder@0.10: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" @@ -12942,13 +13226,6 @@ toml@^2.3.2: resolved "https://registry.yarnpkg.com/toml/-/toml-2.3.6.tgz#25b0866483a9722474895559088b436fd11f861b" integrity sha512-gVweAectJU3ebq//Ferr2JUY4WKSDe5N+z0FvjDncLGyHmIDoxgY/2Ie4qfEIDm4IS7OA6Rmdm7pdEEdMcV/xQ== -topo@3.x.x: - version "3.0.3" - resolved "https://registry.yarnpkg.com/topo/-/topo-3.0.3.tgz#d5a67fb2e69307ebeeb08402ec2a2a6f5f7ad95c" - integrity sha512-IgpPtvD4kjrJ7CRA3ov2FhWQADwv+Tdqbsf1ZnPUSAtCJ9e1Z44MmoSGDXGk4IppoZA7jd/QRkNddlLJWlUZsQ== - dependencies: - hoek "6.x.x" - tough-cookie@^2.3.3, tough-cookie@^2.3.4: version "2.5.0" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" @@ -13120,10 +13397,10 @@ unbzip2-stream@^1.0.9: buffer "^5.2.1" through "^2.3.8" -underscore.string@~3.3.5: - version "3.3.5" - resolved "https://registry.npmjs.org/underscore.string/-/underscore.string-3.3.5.tgz" - integrity sha512-g+dpmgn+XBneLmXXo+sGlW5xQEt4ErkS3mgeN2GFbremYeMBSJKr9Wf2KJplQVaiPY/f7FN6atosWYNm9ovrYg== +underscore.string@~2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/underscore.string/-/underscore.string-2.4.0.tgz#8cdd8fbac4e2d2ea1e7e2e8097c42f442280f85b" + integrity sha1-jN2PusTi0uoefi6Al8QvRCKA+Fs= underscore@^1.7.0: version "1.9.1" @@ -13500,17 +13777,6 @@ w3c-hr-time@^1.0.1: dependencies: browser-process-hrtime "^0.1.2" -wait-on@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/wait-on/-/wait-on-3.2.0.tgz#c83924df0fc42a675c678324c49c769d378bcb85" - integrity sha512-QUGNKlKLDyY6W/qHdxaRlXUAgLPe+3mLL/tRByHpRNcHs/c7dZXbu+OnJWGNux6tU1WFh/Z8aEwvbuzSAu79Zg== - dependencies: - core-js "^2.5.7" - joi "^13.0.0" - minimist "^1.2.0" - request "^2.88.0" - rx "^4.1.0" - walker@~1.0.5: version "1.0.7" resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.7.tgz#2f7f9b8fd10d677262b18a884e28d19618e028fb" @@ -14007,6 +14273,15 @@ yauzl@^2.4.2: buffer-crc32 "~0.2.3" fd-slicer "~1.1.0" +youtube-player@^5.5.1: + version "5.5.2" + resolved "https://registry.yarnpkg.com/youtube-player/-/youtube-player-5.5.2.tgz#052b86b1eabe21ff331095ffffeae285fa7f7cb5" + integrity sha512-ZGtsemSpXnDky2AUYWgxjaopgB+shFHgXVpiJFeNB5nWEugpW1KWYDaHKuLqh2b67r24GtP6HoSW5swvf0fFIQ== + dependencies: + debug "^2.6.6" + load-script "^1.0.0" + sister "^3.0.0" + zepto@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/zepto/-/zepto-1.2.0.tgz#e127bd9e66fd846be5eab48c1394882f7c0e4f98" From 1a6897ecb6abda5b72ff2a40fe6908310546aeaa Mon Sep 17 00:00:00 2001 From: Zach Badgett Date: Mon, 29 Apr 2019 13:13:11 -0400 Subject: [PATCH 3/3] Fix code tab list bug --- packages/docusaurus-1.x/lib/core/Doc.js | 71 ++++++--- .../__tests__/__fixtures__/split-tab_doc1.md | 29 ++++ .../__tests__/__fixtures__/split-tab_doc2.md | 32 ++++ .../lib/core/__tests__/split-tab.test.js | 127 +++++++++------ yarn.lock | 150 ++++++++---------- 5 files changed, 250 insertions(+), 159 deletions(-) create mode 100644 packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc1.md create mode 100644 packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc2.md diff --git a/packages/docusaurus-1.x/lib/core/Doc.js b/packages/docusaurus-1.x/lib/core/Doc.js index d13044039ea7..3b64b787dff6 100644 --- a/packages/docusaurus-1.x/lib/core/Doc.js +++ b/packages/docusaurus-1.x/lib/core/Doc.js @@ -19,8 +19,7 @@ const translateThisDoc = translate( 'Translate this Doc|recruitment message asking to translate the docs', ); -const splitTabsToTitleAndContent = content => { - const lines = content.split(/\n/g); +const splitTabsToTitleAndContent = (lines, indents) => { let first = false; let inBlock = false; let whitespace = false; @@ -29,6 +28,9 @@ const splitTabsToTitleAndContent = content => { content: [], }; lines.forEach(line => { + if (indents) { + line = line.replace(new RegExp(`^((\\t|\\s{4}){${indents}})`, 'g'), ''); + } let pos = 0; const end = line.length; const isToken = (cline, cpos, ...chars) => { @@ -124,7 +126,13 @@ const splitTabsToTitleAndContent = content => { return tc; }; -const cleanTheCodeTag = content => { +const cleanTheCodeTag = (content, indents) => { + const prepend = (line, indent) => { + if (indent) { + return ' '.repeat(indent) + line; + } + return line; + }; const contents = content.split(/(
)(.*?)(<\/pre>)/gms);
   let inCodeBlock = false;
   const cleanContents = contents.map(c => {
@@ -139,7 +147,7 @@ const cleanTheCodeTag = content => {
     if (inCodeBlock) {
       return c.replace(/\n/g, '
'); } - return c; + return prepend(c, indents); }); return cleanContents.join(''); }; @@ -148,32 +156,43 @@ const cleanTheCodeTag = content => { class Doc extends React.Component { renderContent() { const {content} = this.props; - let inCodeTabs = false; - const contents = content.split( - /(\n)(.*?)(\n)/gms, - ); - - const renderResult = contents.map(c => { - if (c === '\n') { - inCodeTabs = true; - return ''; - } - if (c === '\n') { - inCodeTabs = false; - return ''; - } - if (inCodeTabs) { + let indents = 0; + return content.replace( + /(\t|\s{4})*?(\n)(.*?)((\n|\t|\s{4}))/gms, + m => { + const contents = m.split('\n').filter(c => { + if (!indents) { + indents = ( + c.match(/((\t|\s{4})+)/) || [] + ).length; + } + if (c.match(/(\t|\s{4})+/)) { + return false; + } + if ( + c.match( + /|/, + ) || + (indents > 0 && + c.match( + /(\t|\s{4})+(|)/, + )) + ) { + return false; + } + return true; + }); + if (indents) { + indents -= 1; + } const codeTabsMarkdownBlock = renderToStaticMarkup( - {splitTabsToTitleAndContent(c)} + {splitTabsToTitleAndContent(contents, indents)} , ); - return cleanTheCodeTag(codeTabsMarkdownBlock); - } - return c; - }); - - return renderResult.join(''); + return cleanTheCodeTag(codeTabsMarkdownBlock, indents); + }, + ); } render() { diff --git a/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc1.md b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc1.md new file mode 100644 index 000000000000..1e89fe34f56d --- /dev/null +++ b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc1.md @@ -0,0 +1,29 @@ + + +```js +console.log('Hello, world!'); +``` + +```py +print('Hello, world!') +``` + + +```C +#include + +int main() { + printf("Hello World!"); + return 0; +} +``` + + +```Pascal +program HelloWorld; +begin + WriteLn('Hello, world!'); +end. +``` + + diff --git a/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc2.md b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc2.md new file mode 100644 index 000000000000..14a7da6a4ecb --- /dev/null +++ b/packages/docusaurus-1.x/lib/core/__tests__/__fixtures__/split-tab_doc2.md @@ -0,0 +1,32 @@ +1. Doc + * Hello + + + ```js + console.log('Hello, world!'); + ``` + + ```py + print('Hello, world!') + ``` + + + ```C + #include + + int main() { + printf("Hello World!"); + return 0; + } + ``` + + + ```Pascal + program HelloWorld; + begin + WriteLn('Hello, world!'); + end. + ``` + + + 1. Do that \ No newline at end of file diff --git a/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js b/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js index 2066375c39d0..9d35617f4d66 100644 --- a/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js +++ b/packages/docusaurus-1.x/lib/core/__tests__/split-tab.test.js @@ -11,12 +11,23 @@ process.cwd = () => `${__dirname}/__fixtures__/website`; const React = require('react'); const {configure, mount} = require('enzyme'); const Adapter = require('enzyme-adapter-react-16'); +const fs = require('fs'); +const _ = require('lodash'); const Doc = require('../Doc.js'); configure({adapter: new Adapter()}); describe('when code tabs are used correctly', () => { - let props; + // clear unique id counter + _.uniqueId = _.runInContext().uniqueId; + const props = { + content: fs.readFileSync( + `${__dirname}/__fixtures__/split-tab_doc1.md`, + 'utf-8', + ), + metadata: {}, + config: {}, + }; let mountedDoc; const docPage = () => { if (!mountedDoc) { @@ -24,46 +35,62 @@ describe('when code tabs are used correctly', () => { } return mountedDoc; }; - beforeEach(() => { - props = { - content: ` - - -\`\`\`js -console.log('Hello, world!'); -\`\`\` - -\`\`\`py -print('Hello, world!') -\`\`\` - - -\`\`\`C -#include - -int main() { - printf("Hello World!"); - return 0; -} -\`\`\` - - -\`\`\`Pascal -program HelloWorld; -begin - WriteLn('Hello, world!'); -end. -\`\`\` - - - `, - metadata: {}, - config: {}, - }; - mountedDoc = undefined; + const page = docPage(); + it('renders tabs correctly', () => { + const node = page.getDOMNode(); + const firstTab = node.querySelector('[data-tab$="-content-2"]').textContent; + expect('JavaScript').toEqual(firstTab); + const secondTab = node.querySelector('[data-tab$="-content-3"]') + .textContent; + expect('Python').toEqual(secondTab); + const thirdTab = node.querySelector('[data-tab$="-content-4"]').textContent; + expect('C').toEqual(thirdTab); + const fourthTab = node.querySelector('[data-tab$="-content-5"]') + .textContent; + expect('Pascal').toEqual(fourthTab); + }); + it('renders content correctly', () => { + const node = page.getDOMNode(); + const firstContent = node.querySelector('[id$="-content-2"] code') + .textContent; + expect("console.log('Hello, world!');").toEqual(firstContent); + const secondContent = node.querySelector('[id$="-content-3"] code') + .textContent; + expect("print('Hello, world!')").toEqual(secondContent); + const thirdContent = node.querySelector('[id$="-content-4"] code') + .textContent; + expect( + '#include int main() { printf("Hello World!"); return 0;}', + ).toEqual(thirdContent); + const fourthContent = node.querySelector('[id$="-content-5"] code') + .textContent; + expect("program HelloWorld;begin WriteLn('Hello, world!');end.").toEqual( + fourthContent, + ); }); +}); + +describe('when code tab is used in a list', () => { + // clear unique id counter + _.uniqueId = _.runInContext().uniqueId; + const props = { + content: fs.readFileSync( + `${__dirname}/__fixtures__/split-tab_doc2.md`, + 'utf-8', + ), + metadata: {}, + config: {}, + }; + let mountedDoc; + const docPage = () => { + if (!mountedDoc) { + mountedDoc = mount(); + } + return mountedDoc; + }; + const page = docPage(); it('renders tabs correctly', () => { - const node = docPage().getDOMNode(); + const node = page.getDOMNode(); const firstTab = node.querySelector('[data-tab$="-content-2"]').textContent; expect('JavaScript').toEqual(firstTab); const secondTab = node.querySelector('[data-tab$="-content-3"]') @@ -76,17 +103,21 @@ end. expect('Pascal').toEqual(fourthTab); }); it('renders content correctly', () => { - const node = docPage().getDOMNode(); - const firstContent = node.querySelector('[id$="-content-7"]').textContent; - expect("console.log('Hello, world!');\n").toEqual(firstContent); - const secondContent = node.querySelector('[id$="-content-8"]').textContent; - expect("print('Hello, world!')\n").toEqual(secondContent); - const thirdContent = node.querySelector('[id$="-content-9"]').textContent; + const node = page.getDOMNode(); + const firstContent = node.querySelector('[id$="-content-2"] code') + .textContent; + expect("console.log('Hello, world!');").toEqual(firstContent); + const secondContent = node.querySelector('[id$="-content-3"] code') + .textContent; + expect("print('Hello, world!')").toEqual(secondContent); + const thirdContent = node.querySelector('[id$="-content-4"] code') + .textContent; expect( - '#include int main() { printf("Hello World!"); return 0;}\n', + '#include int main() { printf("Hello World!"); return 0;}', ).toEqual(thirdContent); - const fourthContent = node.querySelector('[id$="-content-10"]').textContent; - expect("program HelloWorld;begin WriteLn('Hello, world!');end.\n").toEqual( + const fourthContent = node.querySelector('[id$="-content-5"] code') + .textContent; + expect("program HelloWorld;begin WriteLn('Hello, world!');end.").toEqual( fourthContent, ); }); diff --git a/yarn.lock b/yarn.lock index 9c3e8b761201..21bde1c6f610 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3920,7 +3920,7 @@ core-js@^1.0.0: resolved "https://registry.yarnpkg.com/core-js/-/core-js-1.2.7.tgz#652294c14651db28fa93bd2d5ff2983a4f08c636" integrity sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY= -core-js@^2.6.5: +core-js@^2.5.7, core-js@^2.6.5: version "2.6.5" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.5.tgz#44bc8d249e7fb2ff5d00e0341a7ffb94fbf67895" integrity sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A== @@ -4650,60 +4650,6 @@ doctrine@^2.1.0: dependencies: esutils "^2.0.2" -docusaurus@^2.0.0-alpha.10: - version "2.0.0-alpha.10" - resolved "https://registry.yarnpkg.com/docusaurus/-/docusaurus-2.0.0-alpha.10.tgz#3759ccdf7403a58483b41fffb1cfe662e2b98fca" - integrity sha512-sucBSgmtCA+DOSYGdhXV3TmeBR6On2n/6BFQCJs3/if06W6DzLCLb2sC2Jo1PpXpopYvAjd9Sf91zwEvovLPIw== - dependencies: - "@babel/core" "^7.0.0" - "@babel/plugin-proposal-class-properties" "^7.0.0" - "@babel/plugin-proposal-object-rest-spread" "^7.0.0" - "@babel/polyfill" "^7.0.0" - "@babel/preset-env" "^7.0.0" - "@babel/preset-react" "^7.0.0" - "@babel/register" "^7.0.0" - "@babel/traverse" "^7.0.0" - "@babel/types" "^7.1.2" - autoprefixer "^9.1.5" - babylon "^6.17.4" - chalk "^2.1.0" - classnames "^2.2.6" - color "^2.0.1" - commander "^2.18.0" - cross-spawn "^6.0.5" - crowdin-cli "^0.3.0" - cssnano "^3.10.0" - deepmerge "^2.1.1" - escape-string-regexp "^1.0.5" - express "^4.15.3" - feed "^1.1.0" - fs-extra "^5.0.0" - gaze "^1.1.2" - glob "^7.1.3" - highlight.js "^9.12.0" - imagemin "^6.0.0" - imagemin-gifsicle "^6.0.1" - imagemin-jpegtran "^6.0.0" - imagemin-optipng "^6.0.0" - imagemin-svgo "^7.0.0" - lodash "^4.17.11" - markdown-toc "^1.2.0" - mkdirp "^0.5.1" - portfinder "^1.0.17" - postcss "^7.0.1" - prismjs "^1.15.0" - react "^16.5.0" - react-dev-utils "^5.0.2" - react-dom "^16.5.0" - remarkable "^1.7.1" - request "^2.87.0" - shelljs "^0.7.8" - sitemap "^1.13.0" - tcp-port-used "^0.1.2" - tiny-lr "^1.1.1" - tree-node-cli "^1.2.5" - truncate-html "^1.0.1" - dom-converter@^0.2: version "0.2.0" resolved "https://registry.yarnpkg.com/dom-converter/-/dom-converter-0.2.0.tgz#6721a9daee2e293682955b6afe416771627bb768" @@ -6659,6 +6605,16 @@ hmac-drbg@^1.0.0: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.1" +hoek@5.x.x: + version "5.0.4" + resolved "https://registry.yarnpkg.com/hoek/-/hoek-5.0.4.tgz#0f7fa270a1cafeb364a4b2ddfaa33f864e4157da" + integrity sha512-Alr4ZQgoMlnere5FZJsIyfIjORBqZll5POhDsF4q64dPuJR6rNxXdDxtHSQq8OXRurhmx+PWYEE8bXRROY8h0w== + +hoek@6.x.x: + version "6.1.3" + resolved "https://registry.yarnpkg.com/hoek/-/hoek-6.1.3.tgz#73b7d33952e01fe27a38b0457294b79dd8da242c" + integrity sha512-YXXAAhmF9zpQbC7LEcREFtXfGq5K1fmd+4PHkBq8NUqmzW3G+Dq10bI/i0KucLRwss3YYFQ0fSfoxBZYiGUqtQ== + hogan.js@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/hogan.js/-/hogan.js-3.0.2.tgz#4cd9e1abd4294146e7679e41d7898732b02c7bfd" @@ -7640,6 +7596,13 @@ isarray@^2.0.1: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.4.tgz#38e7bcbb0f3ba1b7933c86ba1894ddfc3781bbb7" integrity sha512-GMxXOiUirWg1xTKRipM0Ek07rX+ubx4nNVElTJdNLYmNO/2YrDkgJGw9CljXn+r4EWiDQg/8lsRdHyg2PJuUaA== +isemail@3.x.x: + version "3.2.0" + resolved "https://registry.yarnpkg.com/isemail/-/isemail-3.2.0.tgz#59310a021931a9fb06bbb51e155ce0b3f236832c" + integrity sha512-zKqkK+O+dGqevc93KNsbZ/TqTUFd46MwWjYOoMrjIMZ51eU7DtQG3Wmd9SQQT7i7RVnuTPEiYEWHU3MSbxC1Tg== + dependencies: + punycode "2.x.x" + isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" @@ -8114,6 +8077,15 @@ jest@^24.1.0: import-local "^2.0.0" jest-cli "^24.5.0" +joi@^13.0.0: + version "13.7.0" + resolved "https://registry.yarnpkg.com/joi/-/joi-13.7.0.tgz#cfd85ebfe67e8a1900432400b4d03bbd93fb879f" + integrity sha512-xuY5VkHfeOYK3Hdi91ulocfuFopwgbSORmIwzcwHKESQhC7w1kD5jaVSPnqDxS2I8t3RZ9omCKAxNwXN5zG1/Q== + dependencies: + hoek "5.x.x" + isemail "3.x.x" + topo "3.x.x" + jpegtran-bin@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/jpegtran-bin/-/jpegtran-bin-4.0.0.tgz#d00aed809fba7aa6f30817e59eee4ddf198f8f10" @@ -9690,6 +9662,14 @@ nth-check@^1.0.2, nth-check@~1.0.1: dependencies: boolbase "~1.0.0" +null-loader@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/null-loader/-/null-loader-1.0.0.tgz#90e85798e50e9dd1d568495a44e74829dec26744" + integrity sha512-mYLDjDVTkjTlFoidxRhzO75rdcwfVXfw5G5zpj8sXnBkHtKJxMk4hTcRR4i5SOhDB6EvcQuYriy6IV23eq6uog== + dependencies: + loader-utils "^1.2.3" + schema-utils "^1.0.0" + num2fraction@^1.2.2: version "1.2.2" resolved "https://registry.yarnpkg.com/num2fraction/-/num2fraction-1.2.2.tgz#6f682b6a027a4e9ddfa4564cd2589d1d4e669ede" @@ -10864,7 +10844,7 @@ prop-types-exact@^1.2.0: object.assign "^4.1.0" reflect.ownkeys "^0.2.0" -prop-types@^15.5.0, prop-types@^15.5.3, prop-types@^15.5.4, prop-types@^15.6.2, prop-types@^15.7.2: +prop-types@^15.5.0, prop-types@^15.5.4, prop-types@^15.6.2, prop-types@^15.7.2: version "15.7.2" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5" integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== @@ -10962,16 +10942,16 @@ punycode@1.3.2: resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" integrity sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0= +punycode@2.x.x, punycode@^2.1.0, punycode@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + punycode@^1.2.4, punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= -punycode@^2.1.0, punycode@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" - integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== - q@0.9.7: version "0.9.7" resolved "https://registry.yarnpkg.com/q/-/q-0.9.7.tgz#4de2e6cb3b29088c9e4cbc03bf9d42fb96ce2f75" @@ -11272,15 +11252,6 @@ react-test-renderer@^16.0.0-0: react-is "^16.8.6" scheduler "^0.13.6" -react-youtube@^7.9.0: - version "7.9.0" - resolved "https://registry.yarnpkg.com/react-youtube/-/react-youtube-7.9.0.tgz#cf513c253581e1e45aa412a77d03420dfd7f7ba7" - integrity sha512-2+nBF4qP8nStYEILIO1/SylKOCnnJUxuZm+qCeWA0eeZxnWZIIixfAeAqbzblwx5L1n/26ACocy3epm9Glox8w== - dependencies: - fast-deep-equal "^2.0.1" - prop-types "^15.5.3" - youtube-player "^5.5.1" - react@^16.5.0, react@^16.8.4: version "16.8.5" resolved "https://registry.yarnpkg.com/react/-/react-16.8.5.tgz#49be3b655489d74504ad994016407e8a0445de66" @@ -11761,7 +11732,7 @@ request-promise-native@^1.0.5: stealthy-require "^1.1.1" tough-cookie "^2.3.3" -request@^2.53.0, request@^2.87.0: +request@^2.53.0, request@^2.87.0, request@^2.88.0: version "2.88.0" resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== @@ -11951,6 +11922,11 @@ rx-lite@*, rx-lite@^4.0.8: resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= +rx@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" + integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I= + rxjs@^6.1.0, rxjs@^6.3.3, rxjs@^6.4.0: version "6.4.0" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.4.0.tgz#f3bb0fe7bda7fb69deac0c16f17b50b0b8790504" @@ -12256,11 +12232,6 @@ simple-swizzle@^0.2.2: dependencies: is-arrayish "^0.3.1" -sister@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/sister/-/sister-3.0.1.tgz#a36ba6a1d1e46415ba16cb4ecefe14cbd8d82d1f" - integrity sha512-aG41gNRHRRxPq52MpX4vtm9tapnr6ENmHUx8LMAJWCOplEMwXzh/dp5WIo52Wl8Zlc/VUyHLJ2snX0ck+Nma9g== - sisteransi@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.0.tgz#77d9622ff909080f1c19e5f4a1df0c1b0a27b88c" @@ -13226,6 +13197,13 @@ toml@^2.3.2: resolved "https://registry.yarnpkg.com/toml/-/toml-2.3.6.tgz#25b0866483a9722474895559088b436fd11f861b" integrity sha512-gVweAectJU3ebq//Ferr2JUY4WKSDe5N+z0FvjDncLGyHmIDoxgY/2Ie4qfEIDm4IS7OA6Rmdm7pdEEdMcV/xQ== +topo@3.x.x: + version "3.0.3" + resolved "https://registry.yarnpkg.com/topo/-/topo-3.0.3.tgz#d5a67fb2e69307ebeeb08402ec2a2a6f5f7ad95c" + integrity sha512-IgpPtvD4kjrJ7CRA3ov2FhWQADwv+Tdqbsf1ZnPUSAtCJ9e1Z44MmoSGDXGk4IppoZA7jd/QRkNddlLJWlUZsQ== + dependencies: + hoek "6.x.x" + tough-cookie@^2.3.3, tough-cookie@^2.3.4: version "2.5.0" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" @@ -13777,6 +13755,17 @@ w3c-hr-time@^1.0.1: dependencies: browser-process-hrtime "^0.1.2" +wait-on@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/wait-on/-/wait-on-3.2.0.tgz#c83924df0fc42a675c678324c49c769d378bcb85" + integrity sha512-QUGNKlKLDyY6W/qHdxaRlXUAgLPe+3mLL/tRByHpRNcHs/c7dZXbu+OnJWGNux6tU1WFh/Z8aEwvbuzSAu79Zg== + dependencies: + core-js "^2.5.7" + joi "^13.0.0" + minimist "^1.2.0" + request "^2.88.0" + rx "^4.1.0" + walker@~1.0.5: version "1.0.7" resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.7.tgz#2f7f9b8fd10d677262b18a884e28d19618e028fb" @@ -14273,15 +14262,6 @@ yauzl@^2.4.2: buffer-crc32 "~0.2.3" fd-slicer "~1.1.0" -youtube-player@^5.5.1: - version "5.5.2" - resolved "https://registry.yarnpkg.com/youtube-player/-/youtube-player-5.5.2.tgz#052b86b1eabe21ff331095ffffeae285fa7f7cb5" - integrity sha512-ZGtsemSpXnDky2AUYWgxjaopgB+shFHgXVpiJFeNB5nWEugpW1KWYDaHKuLqh2b67r24GtP6HoSW5swvf0fFIQ== - dependencies: - debug "^2.6.6" - load-script "^1.0.0" - sister "^3.0.0" - zepto@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/zepto/-/zepto-1.2.0.tgz#e127bd9e66fd846be5eab48c1394882f7c0e4f98"