From 3b6d104e9d89be41aba65acaf5d68f64fa422538 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Wed, 9 Oct 2019 15:33:37 +0200 Subject: [PATCH 1/5] refactor: updated not found component --- src/components/NotFound/NotFound.tsx | 63 ++++++++----------- src/components/NotFound/Notfound.test.tsx | 8 +-- .../__snapshots__/Notfound.test.tsx.snap | 32 +++++++++- src/components/NotFound/index.ts | 2 +- src/components/NotFound/styles.ts | 41 ------------ 5 files changed, 62 insertions(+), 84 deletions(-) delete mode 100644 src/components/NotFound/styles.ts diff --git a/src/components/NotFound/NotFound.tsx b/src/components/NotFound/NotFound.tsx index 14ab9c016..b642a8728 100644 --- a/src/components/NotFound/NotFound.tsx +++ b/src/components/NotFound/NotFound.tsx @@ -1,53 +1,44 @@ -import ListItem from '@material-ui/core/ListItem'; +import Box from '@material-ui/core/Box'; import Typography from '@material-ui/core/Typography'; -import withWidth, { isWidthUp, WithWidthProps } from '@material-ui/core/withWidth'; +import styled from 'react-emotion'; import React, { useCallback } from 'react'; -import { RouteComponentProps, withRouter } from 'react-router-dom'; +import { useHistory } from 'react-router-dom'; + +import Button from '../../muiComponents/Button'; import PackageImg from './img/package.svg'; -import { Card, EmptyPackage, Heading, Inner, List, Wrapper } from './styles'; -export const NOT_FOUND_TEXT = `Sorry, we couldn't find it...`; -export const LABEL_NOT_FOUND = `The page you're looking for doesn't exist.`; -export const LABEL_FOOTER_NOT_FOUND = 'Perhaps these links will help find what you are looking for:'; +export const NOT_FOUND_TEXT = "Sorry, we couldn't find it..."; +export const LABEL_NOT_FOUND = "The page you're looking for doesn't exist."; -export type NotFoundProps = RouteComponentProps & WithWidthProps; +const EmptyPackage = styled('img')({ + width: '150px', + margin: '0 auto', +}); -const HOME_LABEL = 'Home'; +const StyledHeading = styled(Typography)({ + color: '#4b5e40', + marginBottom: 16, +}); -const renderSubTitle = (): JSX.Element => ( - -
{LABEL_NOT_FOUND}
-
{LABEL_FOOTER_NOT_FOUND}
-
-); +const NotFound: React.FC = () => { + const history = useHistory(); -const NotFound: React.FC = ({ history, width }) => { const handleGomHome = useCallback(() => { history.push('/'); }, [history]); - const renderList = (): JSX.Element => ( - - - {HOME_LABEL} - - - ); - - /* eslint-disable @typescript-eslint/no-non-null-assertion */ return ( - - - - - {NOT_FOUND_TEXT} - - {renderSubTitle()} - {renderList()} - - + + + + {NOT_FOUND_TEXT} + + + ); }; -export default withRouter>(withWidth()(NotFound)); +export default NotFound; diff --git a/src/components/NotFound/Notfound.test.tsx b/src/components/NotFound/Notfound.test.tsx index a2b20dd0b..d6aee32d3 100644 --- a/src/components/NotFound/Notfound.test.tsx +++ b/src/components/NotFound/Notfound.test.tsx @@ -1,18 +1,16 @@ import React from 'react'; import { BrowserRouter as Router } from 'react-router-dom'; -import { shallow } from 'enzyme'; +import { render } from '@testing-library/react'; import NotFound from './NotFound'; -console.error = jest.fn(); - describe(' component', () => { test('should load the component in default state', () => { - const routerWrapper = shallow( + const { container } = render( ); - expect(routerWrapper.find(NotFound)).toMatchSnapshot(); + expect(container.firstChild).toMatchSnapshot(); }); }); diff --git a/src/components/NotFound/__snapshots__/Notfound.test.tsx.snap b/src/components/NotFound/__snapshots__/Notfound.test.tsx.snap index 02fe05796..8e17e4f9a 100644 --- a/src/components/NotFound/__snapshots__/Notfound.test.tsx.snap +++ b/src/components/NotFound/__snapshots__/Notfound.test.tsx.snap @@ -1,3 +1,33 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[` component should load the component in default state 1`] = ``; +exports[` component should load the component in default state 1`] = ` +
+ 404 - Page not found +

+ Sorry, we couldn't find it... +

+ +
+`; diff --git a/src/components/NotFound/index.ts b/src/components/NotFound/index.ts index 106131be3..cbfef773b 100644 --- a/src/components/NotFound/index.ts +++ b/src/components/NotFound/index.ts @@ -1 +1 @@ -export { default } from './NotFound'; +export { default, NOT_FOUND_TEXT } from './NotFound'; diff --git a/src/components/NotFound/styles.ts b/src/components/NotFound/styles.ts deleted file mode 100644 index 36478759c..000000000 --- a/src/components/NotFound/styles.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { default as MuiCard } from '@material-ui/core/Card'; -import { default as MuiList } from '@material-ui/core/List'; -import Typography from '@material-ui/core/Typography'; -import styled from 'react-emotion'; - -export const Wrapper = styled('div')({ - display: 'flex', - alignItems: 'center', - flexDirection: 'column', - justifyContent: 'center', - flex: 1, - padding: '16px', -}); - -export const Inner = styled('div')({ - maxWidth: '650px', - display: 'flex', - flexDirection: 'column', -}); - -export const EmptyPackage = styled('img')({ - width: '150px', - margin: '0 auto', -}); - -export const Heading = styled(Typography)({ - '&&': { - color: '#4b5e40', - }, -}); - -export const List = styled(MuiList)({ - '&&': { - padding: 0, - color: '#4b5e40', - }, -}); - -export const Card = styled(MuiCard)({ - marginTop: '24px', -}); From 391768bf6c95cacdd01e3f6757d4d469905e4a62 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Wed, 9 Oct 2019 15:52:26 +0200 Subject: [PATCH 2/5] chore: removed react-router --- package.json | 5 ++--- src/components/Versions/Versions.test.tsx | 2 +- yarn.lock | 26 +++++++++++------------ 3 files changed, 16 insertions(+), 17 deletions(-) diff --git a/package.json b/package.json index 5bd151f8e..4371cc979 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "@types/node": "12.7.8", "@types/react": "16.9.2", "@types/react-dom": "16.9.0", - "@types/react-router-dom": "4.3.5", + "@types/react-router-dom": "5.1.0", "@types/validator": "10.11.3", "@typescript-eslint/parser": "2.3.2", "@verdaccio/babel-preset": "2.0.0", @@ -87,8 +87,7 @@ "react-dom": "16.10.0", "react-emotion": "9.2.12", "react-hot-loader": "4.12.11", - "react-router": "5.0.1", - "react-router-dom": "5.0.1", + "react-router-dom": "5.1.2", "resolve-url-loader": "3.1.0", "rimraf": "3.0.0", "source-map-loader": "0.2.4", diff --git a/src/components/Versions/Versions.test.tsx b/src/components/Versions/Versions.test.tsx index e103eb30c..0d153348c 100644 --- a/src/components/Versions/Versions.test.tsx +++ b/src/components/Versions/Versions.test.tsx @@ -1,6 +1,6 @@ import React from 'react'; import { mount } from 'enzyme'; -import { MemoryRouter } from 'react-router'; +import { MemoryRouter } from 'react-router-dom'; import { render, cleanup } from '@testing-library/react'; import { DetailContext, DetailContextProps } from '../../pages/Version'; diff --git a/yarn.lock b/yarn.lock index 390461ae2..ded72b12d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1676,10 +1676,10 @@ dependencies: "@types/react" "*" -"@types/react-router-dom@4.3.5": - version "4.3.5" - resolved "https://registry.verdaccio.org/@types%2freact-router-dom/-/react-router-dom-4.3.5.tgz#72f229967690c890d00f96e6b85e9ee5780db31f" - integrity sha512-eFajSUASYbPHg2BDM1G8Btx+YqGgvROPIg6sBhl3O4kbDdYXdFdfrgQFf/pcBuQVObjfT9AL/dd15jilR5DIEA== +"@types/react-router-dom@5.1.0": + version "5.1.0" + resolved "https://registry.verdaccio.org/@types%2freact-router-dom/-/react-router-dom-5.1.0.tgz#8baa84a7fa8c8e7797fb3650ca51f93038cb4caf" + integrity sha512-YCh8r71pL5p8qDwQf59IU13hFy/41fDQG/GeOI3y+xmD4o0w3vEPxE8uBe+dvOgMoDl0W1WUZsWH0pxc1mcZyQ== dependencies: "@types/history" "*" "@types/react" "*" @@ -10946,23 +10946,23 @@ react-lifecycles-compat@^3.0.4: resolved "https://registry.verdaccio.org/react-lifecycles-compat/-/react-lifecycles-compat-3.0.4.tgz#4f1a273afdfc8f3488a8c516bfda78f872352362" integrity sha512-fBASbA6LnOU9dOU2eW7aQ8xmYBSXUIWr+UmF9b1efZBazGNO+rcXT/icdKnYm2pTwcRylVUYwW7H1PHfLekVzA== -react-router-dom@5.0.1: - version "5.0.1" - resolved "https://registry.verdaccio.org/react-router-dom/-/react-router-dom-5.0.1.tgz#ee66f4a5d18b6089c361958e443489d6bab714be" - integrity sha512-zaVHSy7NN0G91/Bz9GD4owex5+eop+KvgbxXsP/O+iW1/Ln+BrJ8QiIR5a6xNPtrdTvLkxqlDClx13QO1uB8CA== +react-router-dom@5.1.2: + version "5.1.2" + resolved "https://registry.verdaccio.org/react-router-dom/-/react-router-dom-5.1.2.tgz#06701b834352f44d37fbb6311f870f84c76b9c18" + integrity sha512-7BPHAaIwWpZS074UKaw1FjVdZBSVWEk8IuDXdB+OkLb8vd/WRQIpA4ag9WQk61aEfQs47wHyjWUoUGGZxpQXew== dependencies: "@babel/runtime" "^7.1.2" history "^4.9.0" loose-envify "^1.3.1" prop-types "^15.6.2" - react-router "5.0.1" + react-router "5.1.2" tiny-invariant "^1.0.2" tiny-warning "^1.0.0" -react-router@5.0.1: - version "5.0.1" - resolved "https://registry.verdaccio.org/react-router/-/react-router-5.0.1.tgz#04ee77df1d1ab6cb8939f9f01ad5702dbadb8b0f" - integrity sha512-EM7suCPNKb1NxcTZ2LEOWFtQBQRQXecLxVpdsP4DW4PbbqYWeRiLyV/Tt1SdCrvT2jcyXAXmVTmzvSzrPR63Bg== +react-router@5.1.2: + version "5.1.2" + resolved "https://registry.verdaccio.org/react-router/-/react-router-5.1.2.tgz#6ea51d789cb36a6be1ba5f7c0d48dd9e817d3418" + integrity sha512-yjEuMFy1ONK246B+rsa0cUam5OeAQ8pyclRDgpxuSCrAlJ1qN9uZ5IgyKC7gQg0w8OM50NXHEegPh/ks9YuR2A== dependencies: "@babel/runtime" "^7.1.2" history "^4.9.0" From 6571eee124e4a2fca93617f56a3d45f3c11dac49 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Fri, 11 Oct 2019 15:22:15 +0200 Subject: [PATCH 3/5] refactored: applied feedbacks --- src/components/NotFound/NotFound.tsx | 9 ++++++--- src/components/NotFound/Notfound.test.tsx | 1 + src/utils/styles/spacings.ts | 1 + 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/components/NotFound/NotFound.tsx b/src/components/NotFound/NotFound.tsx index b642a8728..2f5d290cd 100644 --- a/src/components/NotFound/NotFound.tsx +++ b/src/components/NotFound/NotFound.tsx @@ -5,11 +5,14 @@ import React, { useCallback } from 'react'; import { useHistory } from 'react-router-dom'; import Button from '../../muiComponents/Button'; +import colors from '../../utils/styles/colors'; +import { spacings } from '../../utils/styles/spacings'; import PackageImg from './img/package.svg'; export const NOT_FOUND_TEXT = "Sorry, we couldn't find it..."; export const LABEL_NOT_FOUND = "The page you're looking for doesn't exist."; +export const GO_TO_HOME_PAGE = 'Go to the home page'; const EmptyPackage = styled('img')({ width: '150px', @@ -17,8 +20,8 @@ const EmptyPackage = styled('img')({ }); const StyledHeading = styled(Typography)({ - color: '#4b5e40', - marginBottom: 16, + color: colors.primary, + marginBottom: spacings.sm, }); const NotFound: React.FC = () => { @@ -35,7 +38,7 @@ const NotFound: React.FC = () => { {NOT_FOUND_TEXT} ); diff --git a/src/components/NotFound/Notfound.test.tsx b/src/components/NotFound/Notfound.test.tsx index d6aee32d3..6207de59a 100644 --- a/src/components/NotFound/Notfound.test.tsx +++ b/src/components/NotFound/Notfound.test.tsx @@ -13,4 +13,5 @@ describe(' component', () => { ); expect(container.firstChild).toMatchSnapshot(); }); + test.todo('Test Button Click'); }); diff --git a/src/utils/styles/spacings.ts b/src/utils/styles/spacings.ts index 7c7c37254..7478d920f 100644 --- a/src/utils/styles/spacings.ts +++ b/src/utils/styles/spacings.ts @@ -3,4 +3,5 @@ export const spacings = { lg: '30px', + sm: '16px', }; From cbaeca3e77938ccbe7005583208c7a6af4774411 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Fri, 11 Oct 2019 16:56:03 +0200 Subject: [PATCH 4/5] fix: removed doc folder --- .eslintignore | 1 + .gitignore | 2 + doc/doc-filelist.js | 1 - doc/doc-script.js | 228 ------------------------- doc/doc-style.css | 403 -------------------------------------------- 5 files changed, 3 insertions(+), 632 deletions(-) delete mode 100644 doc/doc-filelist.js delete mode 100644 doc/doc-script.js delete mode 100644 doc/doc-style.css diff --git a/.eslintignore b/.eslintignore index 010a45cd7..a063e81be 100644 --- a/.eslintignore +++ b/.eslintignore @@ -11,3 +11,4 @@ Dockerfile *.html *.scss *.png +doc diff --git a/.gitignore b/.gitignore index 6922247ea..8101f3d0d 100755 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,8 @@ npm-debug.log verdaccio-*.tgz .DS_Store build/ +doc + ### node_modules package-lock.json diff --git a/doc/doc-filelist.js b/doc/doc-filelist.js deleted file mode 100644 index c2a398ff9..000000000 --- a/doc/doc-filelist.js +++ /dev/null @@ -1 +0,0 @@ -var tree={}; \ No newline at end of file diff --git a/doc/doc-script.js b/doc/doc-script.js deleted file mode 100644 index 7fa122605..000000000 --- a/doc/doc-script.js +++ /dev/null @@ -1,228 +0,0 @@ -// # res/script.js -// -// This is the script file that gets copied into the output. It mainly manages the display -// of the folder tree. The idea of this script file is to be minimal and standalone. So -// that means no jQuery. - -// Use localStorage to store data about the tree's state: whether or not -// the tree is visible and which directories are expanded. Unless the state -var sidebarVisible = (window.localStorage && window.localStorage.docker_showSidebar) ? - window.localStorage.docker_showSidebar == 'yes' : - defaultSidebar; - -/** - * ## makeTree - * - * Consructs the folder tree view - * - * @param {object} treeData Folder structure as in [queueFile](../src/docker.js.html#docker.prototype.queuefile) - * @param {string} root Path from current file to root (ie `'../../'` etc.) - * @param {string} filename The current file name - */ -function makeTree(treeData, root, filename) { - var treeNode = document.getElementById('tree'); - var treeHandle = document.getElementById('sidebar-toggle'); - treeHandle.addEventListener('click', toggleTree, false); - - // Build the html and add it to the container. - treeNode.innerHTML = nodeHtml('', treeData, '', root); - - // Root folder (whole tree) should always be open - treeNode.childNodes[0].className += ' open'; - - // Attach click event handler - treeNode.addEventListener('click', nodeClicked, false); - - if (sidebarVisible) document.body.className += ' sidebar'; - - // Restore scroll position from localStorage if set. And attach scroll handler - if (window.localStorage && window.localStorage.docker_treeScroll) treeNode.scrollTop = window.localStorage.docker_treeScroll; - treeNode.onscroll = treeScrolled; - - // Only set a class to allow CSS transitions after the tree state has been painted - setTimeout(function() { document.body.className += ' slidey'; }, 100); -} - -/** - * ## treeScrolled - * - * Called when the tree is scrolled. Stores the scroll position in localStorage - * so it can be restored on the next pageview. - */ -function treeScrolled() { - var tree = document.getElementById('tree'); - if (window.localStorage) window.localStorage.docker_treeScroll = tree.scrollTop; -} - -/** - * ## nodeClicked - * - * Called when a directory is clicked. Toggles open state of the directory - * - * @param {Event} e The click event - */ -function nodeClicked(e) { - // Find the target - var t = e.target; - - // If the click target is actually a file (rather than a directory), ignore it - if (t.tagName.toLowerCase() !== 'div' || t.className === 'children') return; - - // Recurse upwards until we find the actual directory node - while (t && t.className.substring(0, 3) != 'dir') t = t.parentNode; - - // If we're at the root node, then do nothing (we don't allow collapsing of the whole tree) - if (!t || t.parentNode.id == 'tree') return; - - // Find the path and toggle the state, saving the state in the localStorage variable - var path = t.getAttribute('rel'); - if (t.className.indexOf('open') !== -1) { - t.className = t.className.replace(/\s*open/g, ''); - if (window.localStorage) window.localStorage.removeItem('docker_openPath:' + path); - } else { - t.className += ' open'; - if (window.localStorage) window.localStorage['docker_openPath:' + path] = 'yes'; - } -} - - -/** - * ## nodeHtml - * - * Constructs the markup for a directory in the tree - * - * @param {string} nodename The node name. - * @param {object} node Node object of same format as whole tree. - * @param {string} path The path form the base to this node - * @param {string} root Relative path from current page to root - */ -function nodeHtml(nodename, node, path, root) { - // Firstly, figure out whether or not the directory is expanded from localStorage - var isOpen = window.localStorage && window.localStorage['docker_openPath:' + path] == 'yes'; - var out = '
'; - out += '
' + nodename + '
'; - out += '
'; - - // Loop through all child directories first - if (node.dirs) { - var dirs = []; - for (var i in node.dirs) { - if (node.dirs.hasOwnProperty(i)) dirs.push({ name: i, html: nodeHtml(i, node.dirs[i], path + i + '/', root) }); - } - // Have to store them in an array first and then sort them alphabetically here - dirs.sort(function(a, b) { return (a.name > b.name) ? 1 : (a.name == b.name) ? 0 : -1; }); - - for (var k = 0; k < dirs.length; k += 1) out += dirs[k].html; - } - - // Now loop through all the child files alphabetically - if (node.files) { - node.files.sort(); - for (var j = 0; j < node.files.length; j += 1) { - out += '' + node.files[j] + ''; - } - } - - // Close things off - out += '
'; - - return out; -} - -/** - * ## toggleTree - * - * Toggles the visibility of the folder tree - */ -function toggleTree() { - // Do the actual toggling by modifying the class on the body element. That way we can get some nice CSS transitions going. - if (sidebarVisible) { - document.body.className = document.body.className.replace(/\s*sidebar/g, ''); - sidebarVisible = false; - } else { - document.body.className += ' sidebar'; - sidebarVisible = true; - } - if (window.localStorage) { - if (sidebarVisible) { - window.localStorage.docker_showSidebar = 'yes'; - } else { - window.localStorage.docker_showSidebar = 'no'; - } - } -} - -/** - * ## wireUpTabs - * - * Wires up events on the sidebar tabe - */ -function wireUpTabs() { - var tabEl = document.getElementById('sidebar_switch'); - var children = tabEl.childNodes; - - // Each tab has a class corresponding of the id of its tab pane - for (var i = 0, l = children.length; i < l; i += 1) { - // Ignore text nodes - if (children[i].nodeType !== 1) continue; - children[i].addEventListener('click', function(c) { - return function() { switchTab(c); }; - }(children[i].className)); - } -} - -/** - * ## switchTab - * - * Switches tabs in the sidebar - * - * @param {string} tab The ID of the tab to switch to - */ -function switchTab(tab) { - var tabEl = document.getElementById('sidebar_switch'); - var children = tabEl.childNodes; - - // Easiest way to go through tabs without any kind of selector is just to look at the tab bar - for (var i = 0, l = children.length; i < l; i += 1) { - // Ignore text nodes - if (children[i].nodeType !== 1) continue; - - // Figure out what tab pane this tab button corresponts to - var t = children[i].className.replace(/\s.*$/, ''); - if (t === tab) { - // Show the tab pane, select the tab button - document.getElementById(t).style.display = 'block'; - if (children[i].className.indexOf('selected') === -1) children[i].className += ' selected'; - } else { - // Hide the tab pane, deselect the tab button - document.getElementById(t).style.display = 'none'; - children[i].className = children[i].className.replace(/\sselected/, ''); - } - } - - // Store the last open tab in localStorage - if (window.localStorage) window.localStorage.docker_sidebarTab = tab; -} - -/** - * ## window.onload - * - * When the document is ready, make the sidebar and all that jazz - */ -(function(init) { - if (window.addEventListener) { - window.addEventListener('DOMContentLoaded', init); - } else { // IE8 and below - window.onload = init; - } -}(function() { - makeTree(tree, relativeDir, thisFile); - wireUpTabs(); - - // Switch to the last viewed sidebar tab if stored, otherwise default to folder tree - if (window.localStorage && window.localStorage.docker_sidebarTab) { - switchTab(window.localStorage.docker_sidebarTab); - } else { - switchTab('tree'); - } -})); diff --git a/doc/doc-style.css b/doc/doc-style.css deleted file mode 100644 index 2019a1b76..000000000 --- a/doc/doc-style.css +++ /dev/null @@ -1,403 +0,0 @@ -/* - -Original highlight.js style (c) Ivan Sagalaev - -*/ -.hljs { - display: block; - overflow-x: auto; - padding: 0.5em; - background: #F0F0F0; -} -/* Base color: saturation 0; */ -.hljs, -.hljs-subst { - color: #444; -} -.hljs-comment { - color: #888888; -} -.hljs-keyword, -.hljs-attribute, -.hljs-selector-tag, -.hljs-meta-keyword, -.hljs-doctag, -.hljs-name { - font-weight: bold; -} -/* User color: hue: 0 */ -.hljs-type, -.hljs-string, -.hljs-number, -.hljs-selector-id, -.hljs-selector-class, -.hljs-quote, -.hljs-template-tag, -.hljs-deletion { - color: #880000; -} -.hljs-title, -.hljs-section { - color: #880000; - font-weight: bold; -} -.hljs-regexp, -.hljs-symbol, -.hljs-variable, -.hljs-template-variable, -.hljs-link, -.hljs-selector-attr, -.hljs-selector-pseudo { - color: #BC6060; -} -/* Language color: hue: 90; */ -.hljs-literal { - color: #78A960; -} -.hljs-built_in, -.hljs-bullet, -.hljs-code, -.hljs-addition { - color: #397300; -} -/* Meta color: hue: 200 */ -.hljs-meta { - color: #1f7199; -} -.hljs-meta-string { - color: #4d99bf; -} -/* Misc effects */ -.hljs-emphasis { - font-style: italic; -} -.hljs-strong { - font-weight: bold; -} -body { - font-family: 'Palatino Linotype', 'Book Antiqua', Palatino, FreeSerif, serif; - font-size: 15px; - line-height: 22px; - margin: 0; - padding: 0; - background: #ffffff; - color: #4d4d4d; -} -p, -h1, -h2, -h3, -h4, -h5, -h6 { - margin: 0 0 15px 0; -} -h1 { - margin-top: 40px; -} -a { - color: #880000; -} -a:visited { - color: #880000; -} -#tree, -#headings { - position: absolute; - top: 30px; - left: 0; - bottom: 0; - width: 290px; - padding: 10px 0; - overflow: auto; -} -#sidebar_wrapper { - position: fixed; - top: 0; - left: 0; - bottom: 0; - width: 0; - overflow: hidden; - background: #e7e7e7; -} -#sidebar_switch { - position: absolute; - top: 0; - left: 0; - width: 290px; - height: 29px; - border-bottom: 1px solid; - background: #e2e2e2; - border-bottom-color: #d6d6d6; -} -#sidebar_switch span { - display: block; - float: left; - width: 50%; - text-align: center; - line-height: 29px; - cursor: pointer; - color: #4b4b4b; -} -#sidebar_switch span:hover { - background: #e7e7e7; -} -#sidebar_switch .selected { - font-weight: bold; - background: #ededed; - color: #444; -} -.slidey #sidebar_wrapper { - -webkit-transition: width 250ms linear; - -moz-transition: width 250ms linear; - -ms-transition: width 250ms linear; - -o-transition: width 250ms linear; - transition: width 250ms linear; -} -.sidebar #sidebar_wrapper { - width: 290px; -} -#tree .nodename { - text-indent: 12px; - background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAg0lEQVQYlWNIS0tbAcSK////Z8CHGTIzM7+mp6d/ASouwqswKyvrO1DRfyg+CcRaxCgE4Z9A3AjEbIQUgjHQOQvwKgS6+ffChQt3AiUDcCqsra29d/v27R6ghCVWN2ZnZ/9YuXLlRqBAPBALYvVMR0fHmQcPHrQBOUZ4gwfqFj5CAQ4Al6wLIYDwo9QAAAAASUVORK5CYII="); - background-repeat: no-repeat; - background-position: left center; - cursor: pointer; -} -#tree .open > .nodename { - background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAlElEQVQYlWNIS0tbCsT/8eCN////Z2B49OhRfHZ29jdsioDiP27evJkNVggkONeuXbscm8Jly5atA8rzwRSCsG5DQ8MtZEU1NTUPgOLGUHm4QgaQFVlZWT9BijIzM39fuHChDCaHohBkBdCq9SCF8+bN2wHkC+FSCMLGkyZNOvb9+3dbNHEMhSDsDsRMxCjEiolWCADeUBHgU/IGQQAAAABJRU5ErkJggg=="); - background-position: left 7px; -} -#tree .dir, -#tree .file { - position: relative; - min-height: 20px; - line-height: 20px; - padding-left: 12px; -} -#tree .dir > .children, -#tree .file > .children { - display: none; -} -#tree .dir.open > .children, -#tree .file.open > .children { - display: block; -} -#tree .file { - padding-left: 24px; - display: block; - text-decoration: none; - color: #444; -} -#tree > .dir { - padding-left: 0; -} -#headings .heading a { - text-decoration: none; - padding-left: 10px; - display: block; - color: #444; -} -#headings .h1 { - padding-left: 0; - margin-top: 10px; - font-size: 1.3em; -} -#headings .h2 { - padding-left: 10px; - margin-top: 8px; - font-size: 1.1em; -} -#headings .h3 { - padding-left: 20px; - margin-top: 5px; - font-size: 1em; -} -#headings .h4 { - padding-left: 30px; - margin-top: 3px; - font-size: 0.9em; -} -#headings .h5 { - padding-left: 40px; - margin-top: 1px; - font-size: 0.8em; -} -#headings .h6 { - padding-left: 50px; - font-size: 0.75em; -} -#sidebar-toggle { - position: fixed; - top: 0; - left: 0; - width: 5px; - bottom: 0; - z-index: 2; - cursor: pointer; - background: #dfdfdf; -} -#sidebar-toggle:hover { - width: 10px; - background: #d6d6d6; -} -.slidey #sidebar-toggle, -.slidey #container { - -webkit-transition: all 250ms linear; - -moz-transition: all 250ms linear; - -ms-transition: all 250ms linear; - -o-transition: all 250ms linear; - transition: all 250ms linear; -} -.sidebar #sidebar-toggle { - left: 290px; -} -#container { - position: fixed; - left: 5px; - right: 0; - top: 0; - bottom: 0; - overflow: auto; -} -.sidebar #container { - left: 295px; -} -.no-sidebar #sidebar_wrapper, -.no-sidebar #sidebar-toggle { - display: none; -} -.no-sidebar #container { - left: 0; -} -#page { - padding-top: 40px; -} -table td { - border: 0; - outline: 0; -} -.docs.markdown { - padding: 10px 50px; -} -td.docs { - max-width: 450px; - min-width: 450px; - min-height: 5px; - padding: 10px 25px 1px 50px; - overflow-x: hidden; - vertical-align: top; - text-align: left; -} -.docs pre { - margin: 15px 0 15px; - padding: 5px; - padding-left: 10px; - border: 1px solid #d6d6d6; - background: #F0F0F0; - font-size: 12px; - overflow: auto; -} -.docs pre.code_stats { - font-size: 60%; -} -.docs p tt, -.docs li tt, -.docs p code, -.docs li code { - border: 1px solid #d6d6d6; - font-size: 12px; - padding: 0 0.2em; - background: #e7e7e7; -} -.dox { - border-top: 1px solid #dddddd; - padding-top: 10px; - padding-bottom: 10px; -} -.dox .details { - padding: 10px; - background: #F0F0F0; - border: 1px solid #d6d6d6; - margin-bottom: 10px; -} -.dox .dox_tag_title { - font-weight: bold; -} -.dox .dox_tag_detail { - margin-left: 10px; -} -.dox .dox_tag_detail span { - margin-right: 5px; -} -.dox .dox_type { - font-style: italic; -} -.dox .dox_tag_name { - font-weight: bold; -} -.pilwrap { - position: relative; - padding-top: 1px; -} -.pilwrap .pilcrow { - font: 12px Arial; - text-decoration: none; - color: #454545; - position: absolute; - left: -20px; - padding: 1px 2px; - opacity: 0; - -webkit-transition: opacity 0.2s linear; - -moz-transition: opacity 0.2s linear; - -ms-transition: opacity 0.2s linear; - -o-transition: opacity 0.2s linear; - transition: opacity 0.2s linear; - color: #555555; -} -.pilwrap .pilcrow:before { - content: '\b6'; -} -.pilwrap:hover .pilcrow { - opacity: 1; -} -td.code { - padding: 8px 15px 8px 25px; - width: 100%; - vertical-align: top; - border-left: 1px solid #d6d6d6; - background: #F0F0F0; -} -.background { - border-left: 1px solid #d6d6d6; - position: absolute; - z-index: -1; - top: 0; - right: 0; - bottom: 0; - left: 525px; - background: #F0F0F0; -} -pre, -tt, -code { - font-size: 12px; - line-height: 18px; - font-family: Menlo, Monaco, Consolas, "Lucida Console", monospace; - margin: 0; - padding: 0; - white-space: pre-wrap; - background: #F0F0F0; -} -.line-num { - display: inline-block; - width: 50px; - text-align: right; - opacity: 0.3; - margin-left: -20px; - text-decoration: none; - color: #888888; -} -.line-num:before { - content: attr(data-line); -} From 88e28e59f6eab8208f7d13970f01f462f3f4abb4 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Fri, 11 Oct 2019 17:10:02 +0200 Subject: [PATCH 5/5] refactor: rollback yarn.lock --- yarn.lock | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/yarn.lock b/yarn.lock index ded72b12d..d3ed99236 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1678,7 +1678,7 @@ "@types/react-router-dom@5.1.0": version "5.1.0" - resolved "https://registry.verdaccio.org/@types%2freact-router-dom/-/react-router-dom-5.1.0.tgz#8baa84a7fa8c8e7797fb3650ca51f93038cb4caf" + resolved "https://registry.yarnpkg.com/@types/react-router-dom/-/react-router-dom-5.1.0.tgz#8baa84a7fa8c8e7797fb3650ca51f93038cb4caf" integrity sha512-YCh8r71pL5p8qDwQf59IU13hFy/41fDQG/GeOI3y+xmD4o0w3vEPxE8uBe+dvOgMoDl0W1WUZsWH0pxc1mcZyQ== dependencies: "@types/history" "*" @@ -10948,7 +10948,7 @@ react-lifecycles-compat@^3.0.4: react-router-dom@5.1.2: version "5.1.2" - resolved "https://registry.verdaccio.org/react-router-dom/-/react-router-dom-5.1.2.tgz#06701b834352f44d37fbb6311f870f84c76b9c18" + resolved "https://registry.yarnpkg.com/react-router-dom/-/react-router-dom-5.1.2.tgz#06701b834352f44d37fbb6311f870f84c76b9c18" integrity sha512-7BPHAaIwWpZS074UKaw1FjVdZBSVWEk8IuDXdB+OkLb8vd/WRQIpA4ag9WQk61aEfQs47wHyjWUoUGGZxpQXew== dependencies: "@babel/runtime" "^7.1.2" @@ -10961,7 +10961,7 @@ react-router-dom@5.1.2: react-router@5.1.2: version "5.1.2" - resolved "https://registry.verdaccio.org/react-router/-/react-router-5.1.2.tgz#6ea51d789cb36a6be1ba5f7c0d48dd9e817d3418" + resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.1.2.tgz#6ea51d789cb36a6be1ba5f7c0d48dd9e817d3418" integrity sha512-yjEuMFy1ONK246B+rsa0cUam5OeAQ8pyclRDgpxuSCrAlJ1qN9uZ5IgyKC7gQg0w8OM50NXHEegPh/ks9YuR2A== dependencies: "@babel/runtime" "^7.1.2" @@ -14018,4 +14018,4 @@ yup@^0.27.0: lodash "^4.17.11" property-expr "^1.5.0" synchronous-promise "^2.0.6" - toposort "^2.0.2" + toposort "^2.0.2" \ No newline at end of file