Commit 1257a90c authored by Jure's avatar Jure

chore(components): remove unused dependencies using depcheck

parent f30786f3
Pipeline #13297 failed with stages
in 8 minutes and 56 seconds
**/_build
**/node_modules
**/coverage
**/dist
packages/styleguide/styleguide
......@@ -3,6 +3,7 @@ coverage
*.log
coverage/
uploads/
dist/
docs/styleguide
# Created by https://www.gitignore.io/api/osx,linux
......
package.json
.config/configstore/update-notifier-npm.json
coverage/
......@@ -15,22 +15,18 @@
"styled-components": "^4.1.3"
},
"peerDependencies": {
"@apollo/react-hoc": "^3.0.1",
"config": "^3.0.1",
"graphql-tag": "^2.10.0",
"lodash": "^4.17.11",
"@apollo/react-hoc": ">=3.0.1",
"config": ">=3.0.1",
"graphql-tag": ">=2.10.0",
"lodash": ">=4.17.11",
"pubsweet-client": ">=1.0.0",
"react": ">=16.9",
"styled-components": "^4.1.3"
"styled-components": ">=4.1.3"
},
"repository": {
"type": "git",
"url": "https://gitlab.coko.foundation/pubsweet/pubsweet",
"path": "Login"
},
"devDependencies": {
"@apollo/react-testing": "^3.0.1",
"@babel/plugin-transform-runtime": "^7.2.0"
"path": "components/client/component-login"
},
"gitHead": "6b100b76f21785e5e50fca082a2743d3d0b1c88a"
}
......@@ -8,18 +8,14 @@
"dependencies": {
"@pubsweet/ui": "^12.1.0",
"@pubsweet/ui-toolkit": "^2.2.14",
"formik": "^1.3.0",
"lodash": "^4.17.11",
"prop-types": "^15.5.10",
"react-autosuggest": "^9.4.3",
"react-feather": "^1.1.6",
"recompose": "^0.30.0"
"prop-types": "^15.5.10"
},
"peerDependencies": {
"graphql-tag": "^2.10.0",
"graphql-tag": ">=2.10.0",
"pubsweet-client": ">=1.0.0",
"react": ">=16.9",
"styled-components": "^4.1.3"
"styled-components": ">=4.1.3"
},
"repository": {
"type": "git",
......
......@@ -9,20 +9,19 @@
"@pubsweet/ui": "^12.1.0",
"@pubsweet/ui-toolkit": "^2.2.14",
"formik": "^1.3.0",
"prop-types": "^15.5.10",
"recompose": "^0.30.0"
},
"peerDependencies": {
"@apollo/react-hoc": "^3.0.1",
"graphql-tag": "^2.10.0",
"@apollo/react-hoc": ">=3.0.1",
"graphql-tag": ">=2.10.0",
"pubsweet-client": ">=1.0.0",
"react": ">=16.9",
"styled-components": "^4.1.3"
"styled-components": ">=4.1.3"
},
"repository": {
"type": "git",
"url": "https://gitlab.coko.foundation/pubsweet/pubsweet",
"path": "Signup"
"path": "components/client/component-signup"
},
"publishConfig": {
"access": "public"
......
......@@ -15,35 +15,18 @@
"classnames": "^2.2.5",
"lodash": "^4.17.4",
"prop-types": "^15.5.10",
"pubsweet-component-ink-frontend": "^1.0.2",
"react-dropzone": "^4.1.2",
"react-moment": "^0.9.6",
"react-router-dom": "^5.0.0",
"recompose": "^0.30.0",
"styled-components": "^4.1.1",
"xpub-connect": "^2.1.0",
"xpub-journal": "^0.1.0",
"xpub-upload": "^1.0.22",
"xpub-with-context": "^0.2.0"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-loader": "^8.0.5",
"css-loader": "^0.28.4",
"enzyme": "^3.7.0",
"enzyme-adapter-react-16": "^1.12.1",
"faker": "^4.1.0",
"identity-obj-proxy": "^3.0.0",
"jest": "^24.7.1",
"react-test-renderer": "^16.5.2"
},
"peerDependencies": {
"@apollo/react-components": "^3.0.1",
"@apollo/react-hoc": "^3.0.1",
"config": "^3.0.1",
"graphql-tag": "^2.10.0",
"@apollo/react-components": ">=3.0.1",
"@apollo/react-hoc": ">=3.0.1",
"config": ">=3.0.1",
"graphql-tag": ">=2.10.0",
"pubsweet-client": ">=1.0.0",
"react": ">=16.9"
},
......
import React from 'react'
import { useQuery, useMutation, ApolloConsumer } from '@apollo/react-hooks'
// import { XpubContext } from 'xpub-with-context'
import Authorize from 'pubsweet-client/src/helpers/Authorize'
import config from 'config'
import queries from '../graphql/queries/'
import mutations from '../graphql/mutations/'
// import Dashboard from './Dashboard'
// import upload from '../lib/upload'
import { Page, Section, Heading, UploadContainer } from './molecules/Page'
import UploadManuscript from './UploadManuscript'
import EditorItem from './sections/EditorItem'
......
// import { compose, withProps } from 'recompose'
// import { graphql } from '@apollo/react-hoc'
// import { withLoader } from 'pubsweet-client'
// import config from 'config'
// import queries from '../graphql/queries/'
// import mutations from '../graphql/mutations/'
// import Dashboard from './Dashboard'
// import upload from '../lib/upload'
// const { acceptUploadFiles } = config['pubsweet-component-xpub-dashboard'] || {}
// const acceptFiles =
// acceptUploadFiles.length > 0
// ? acceptUploadFiles.join()
// : 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
// const updateReviewer = (proxy, { data: { reviewerResponse } }) => {
// const id = reviewerResponse.object.objectId
// const data = proxy.readQuery({
// query: queries.dashboard,
// variables: {
// id,
// },
// })
// const manuscriptIndex = data.journals.manuscripts.findIndex(
// manu => manu.id === id,
// )
// const teamIndex = data.journals.manuscripts[manuscriptIndex].teams.findIndex(
// team => team.id === reviewerResponse.id,
// )
// data.journals.manuscripts[manuscriptIndex].teams[teamIndex] = reviewerResponse
// proxy.writeQuery({ query: queries.dashboard, data })
// }
// export default compose(
// graphql(queries.dashboard, {
// props: data => data,
// }),
// graphql(mutations.reviewerResponseMutation, {
// props: ({ mutate }) => ({
// reviewerResponse: (currentUserId, action, teamId) =>
// mutate({
// variables: { currentUserId, action, teamId },
// update: updateReviewer,
// }),
// }),
// }),
// graphql(mutations.deleteManuscriptMutation, {
// props: ({ mutate }) => ({
// deleteManuscript: manuscript =>
// mutate({ variables: { id: manuscript.id } }),
// }),
// options: {
// update: (proxy, { data: { deleteManuscript } }) => {
// const data = proxy.readQuery({ query: queries.dashboard })
// const manuscriptIndex = data.journals.manuscripts.findIndex(
// manuscript => manuscript.id === deleteManuscript,
// )
// if (manuscriptIndex > -1) {
// data.journals.manuscripts.splice(manuscriptIndex, 1)
// proxy.writeQuery({ query: queries.dashboard, data })
// }
// },
// },
// }),
// withLoader(),
// withProps(({ journals, currentUser }) => ({
// dashboard: (journals || {}).manuscripts || [],
// journals,
// currentUser,
// acceptFiles,
// })),
// upload,
// )(Dashboard)
......@@ -4,7 +4,7 @@ import { XpubContext } from 'xpub-with-context'
import Dropzone from 'react-dropzone'
import { Icon } from '@pubsweet/ui'
import { th } from '@pubsweet/ui-toolkit'
import upload from '../lib/upload'
import upload from '../upload'
const StyledDropzone = styled(({ disableUpload, ...props }) => (
<Dropzone {...props} />
......
export { default as DashboardPage } from './DashboardPage'
export { default as DashboardPage } from './Dashboard'
......@@ -3,8 +3,8 @@
// import { withApollo } from '@apollo/react-hoc'
import config from 'config'
import request from 'pubsweet-client/src/helpers/api'
import queries from '../graphql/queries/'
import mutations from '../graphql/mutations/'
import queries from './graphql/queries'
import mutations from './graphql/mutations'
import { extractTitle, generateTitle } from './title'
// import { XpubContext } from 'xpub-with-context'
// import { useContext } from 'react'
......
......@@ -21,19 +21,12 @@
"xpub-edit": "^2.6.0",
"xpub-selectors": "^0.2.8"
},
"devDependencies": {
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-core": "^6.26.0",
"babel-loader": "^8.0.5",
"faker": "^4.1.0"
},
"peerDependencies": {
"config": "^3.0.1",
"lodash": "^4.17.11",
"config": ">=3.0.1",
"lodash": ">=4.17.11",
"react": ">=16",
"react-redux": "^5.0.2",
"react-router-dom": "^5.0.0",
"redux-form": "^8.1.0"
"react-redux": ">=5.0.2",
"react-router-dom": ">=5.0.0",
"redux-form": ">=8.1.0"
}
}
......@@ -2,7 +2,7 @@ import React from 'react'
import { Button } from '@pubsweet/ui'
import classes from './AuthorLayout.local.scss'
import Paper from './Paper'
import { publicationYears } from '../lib/author'
import { publicationYears } from '../shared/author'
const AuthorLayout = ({ author, assignReviewer, project, version }) => (
<div className={classes.root}>
......
......@@ -6,8 +6,7 @@ import { actions } from 'pubsweet-client'
import { ConnectPage } from 'xpub-connect'
import { selectCollection, selectFragment } from 'xpub-selectors'
import AuthorLayout from './AuthorLayout'
import { scholar } from '../lib/scholar'
// import { newestFirst } from '../lib/sort'
import { scholar } from '../shared/scholar'
class AuthorPage extends React.Component {
state = {
......
......@@ -5,7 +5,7 @@ import { actions } from 'pubsweet-client'
import { ink } from 'pubsweet-component-ink-frontend/actions'
import { ConnectPage } from 'xpub-connect'
import { selectCollection, selectFragment } from 'xpub-selectors'
import { calculateAuthorScores, calculatePaperScores } from '../lib/score'
import { calculateAuthorScores, calculatePaperScores } from '../shared/score'
import FindReviewersLayout from './FindReviewersLayout'
class FindReviewersPage extends React.Component {
......
import React from 'react'
import classes from './PaperLayout.local.scss'
import { newestFirst } from '../lib/sort'
import { newestFirst } from '../shared/sort'
import Paper from './Paper'
import ProjectLink from './ProjectLink'
......
......@@ -5,7 +5,7 @@ import { actions } from 'pubsweet-client'
import { ConnectPage } from 'xpub-connect'
import { selectCollection, selectFragment } from 'xpub-selectors'
import PaperLayout from './PaperLayout'
import { scholar } from '../lib/scholar'
import { scholar } from '../shared/scholar'
class PaperPage extends React.Component {
state = {
......
......@@ -16,31 +16,17 @@
"formik": "^1.4.2",
"passport": "^0.4.0",
"prop-types": "^15.5.10",
"pubsweet-component-ink-frontend": "^1.0.2",
"react-dom": "^16.2.0",
"react-redux": "^5.0.6",
"recompose": "^0.30.0",
"redux": "^3.7.2",
"redux-form": "^7.4.2",
"styled-components": "^4.1.1",
"xpub-connect": "^2.1.0",
"xpub-edit": "^2.6.0"
},
"devDependencies": {
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-core": "^6.26.0",
"babel-loader": "^8.0.5",
"enzyme": "^3.7.0",
"enzyme-adapter-react-16": "^1.8.0",
"faker": "^4.1.0"
},
"peerDependencies": {
"config": "^3.0.1",
"graphql-tag": "^2.10.0",
"lodash": "^4.17.11",
"config": ">=3.0.1",
"graphql-tag": ">=2.10.0",
"lodash": ">=4.17.11",
"pubsweet-client": ">=2.1.0",
"react": ">=16",
"react-apollo": "^2.3.3"
"react-apollo": ">=2.3.3"
}
}
......@@ -8,35 +8,18 @@
],
"main": "src",
"dependencies": {
"prop-types": "^15.5.10",
"recompose": "^0.30.0",
"wax-prosemirror-core": "^0.0.2",
"wax-prosemirror-schema": "^0.0.2",
"wax-prosemirror-themes": "^0.0.2",
"xpub-connect": "^2.1.0"
"wax-prosemirror-themes": "^0.0.2"
},
"peerDependencies": {
"@apollo/react-hoc": "^3.0.1",
"apollo-client-preset": "^1.0.8",
"@apollo/react-hoc": ">=3.0.1",
"apollo-client-preset": ">=1.0.8",
"pubsweet-client": ">=2.1.0",
"react": ">=16.9",
"react-router-dom": ">=5.0.0",
"styled-components": "^4.1.3"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-loader": "^8.0.5",
"faker": "^4.1.0",
"file-loader": "^3.0.1",
"prop-types": "^15.5.10",
"pubsweet-client": "^10.1.0",
"react": "^16.9.0",
"react-dom": "^16.9.0",
"react-router-dom": "^5.0.0",
"recompose": "^0.26.0",
"rimraf": "^2.6.1"
"styled-components": ">=4.1.3"
},
"gitHead": "6b100b76f21785e5e50fca082a2743d3d0b1c88a"
}
......@@ -12,46 +12,28 @@
"@apollo/react-hoc": "^3.1.3",
"@pubsweet/ui": "^12.1.0",
"@pubsweet/ui-toolkit": "^2.2.14",
"classnames": "^2.2.5",
"formik": "^1.4.2",
"lodash": "^4.17.4",
"moment": "^2.18.1",
"prop-types": "^15.5.10",
"react-select": "^1.0.0-rc.10",
"recompose": "^0.30.0",
"striptags": "^3.1.0",
"styled-components": "^4.1.1",
"uuid": "^3.1.0",
"wax-prosemirror-core": "^0.0.2",
"wax-prosemirror-schema": "^0.0.2",
"wax-prosemirror-themes": "^0.0.2",
"xpub-connect": "^2.1.0",
"xpub-edit": "^2.6.0",
"xpub-journal": "^0.1.0",
"xpub-selectors": "^0.2.8",
"xpub-upload": "^1.0.22",
"xpub-validators": "^0.0.6"
},
"devDependencies": {
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-core": "^6.26.0",
"babel-loader": "^8.0.5",
"css-loader": "^0.28.4",
"faker": "^4.1.0",
"file-loader": "^3.0.1",
"style-loader": "^0.19.0",
"webpack": "^4.29.0",
"webpack-node-externals": "^1.6.0"
},
"peerDependencies": {
"apollo-client-preset": "^1.0.8",
"config": "^3.0.1",
"formik": "^1.4.2",
"apollo-client-preset": ">=1.0.8",
"config": ">=3.0.1",
"formik": ">=1.4.2",
"pubsweet-client": ">=2.1.0",
"react": ">=16",
"react-apollo": "^2.3.3",
"react-redux": "^5.0.2",
"react-router-dom": "^5.0.0"
"react-apollo": ">=2.3.3",
"react-redux": ">=5.0.2",
"react-router-dom": ">=5.0.0"
}
}
......@@ -17,31 +17,18 @@
"lodash": "^4.17.11",
"moment": "^2.23.0",
"prop-types": "^15.5.10",
"react-dropzone": "^4.3.0",
"react-feather": "^1.1.5",
"react-html-parser": "^2.0.2",
"recompose": "^0.30.0",
"striptags": "^3.1.0",
"styled-components": "^4.1.1",
"xpub-connect": "^2.1.0",
"xpub-edit": "^2.6.0",
"xpub-journal": "^0.1.0",
"xpub-upload": "^1.0.22",
"xpub-validators": "^0.0.28"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-loader": "^8.0.5",
"enzyme": "^3.7.0",
"enzyme-adapter-react-16": "^1.12.1",
"faker": "^4.1.0"
},
"peerDependencies": {
"pubsweet-client": ">=2.1.0",
"react": ">=16.9",
"react-router-dom": "^5.0.0"
"react-router-dom": ">=5.0.0"
},
"gitHead": "6b100b76f21785e5e50fca082a2743d3d0b1c88a"
}
......@@ -13,24 +13,15 @@
"@pubsweet/ui": "^12.1.0",
"@pubsweet/ui-toolkit": "^2.2.14",
"lodash": "^4.17.11",
"prop-types": "^15.5.10",
"react-dom": "^16.9.0",
"recompose": "^0.30.0",
"styled-components": "^4.1.1",
"xpub-connect": "^2.1.0"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-loader": "^8.0.5",
"faker": "^4.1.0"
"styled-components": "^4.1.1"
},
"peerDependencies": {
"@apollo/react-hoc": "^3.0.1",
"apollo-client-preset": "^1.0.8",
"config": "^3.0.1",
"graphql-tag": "^2.10.0",
"@apollo/react-hoc": ">=3.0.1",
"apollo-client-preset": ">=1.0.8",
"config": ">=3.0.1",
"graphql-tag": ">=2.10.0",
"pubsweet-client": ">=2.1.0",
"react": ">=16.9"
},
......
......@@ -24,18 +24,11 @@
"prosemirror-tables": "^0.7.11",
"prosemirror-view": "^1.0.0"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-react": "^7.0.0",
"babel-loader": "^8.0.5",
"faker": "^4.1.0"
},
"peerDependencies": {
"lodash": "^4.17.11",
"prop-types": "^15.6.2",
"lodash": ">=4.17.11",
"prop-types": ">=15.6.2",
"react": ">=16.9",
"styled-components": "^4.1.3"
"styled-components": ">=4.1.3"
},
"gitHead": "6b100b76f21785e5e50fca082a2743d3d0b1c88a"
}
......@@ -9,8 +9,7 @@
"dist"
],
"dependencies": {
"react-router-dom": "^5.0.0",
"recompose": "^0.30.0"
"react-router-dom": "^5.0.0"
},
"peerDependencies": {
"pubsweet-client": ">=2.1.0",
......
......@@ -8,9 +8,6 @@
"src",
"dist"
],
"dependencies": {
"recompose": "^0.30.0"
},
"peerDependencies": {
"react": ">=16.9"
},
......
......@@ -11,29 +11,23 @@
"dependencies": {
"archiver": "^3.0.0",
"aws-sdk": "^2.185.0",
"body-parser": "^1.17.2",
"dotenv": "^6.2.0",
"lodash": "^4.17.11",
"multer": "^1.3.0",
"multer-s3": "^2.7.0",
"node-mocks-http": "^1.6.6",
"nodemailer": "^4.4.2",
"uuid": "^3.3.2"
},
"peerDependencies": {
"@hapi/joi": "^14.3.1",
"@hapi/joi": ">=14.3.1",
"@pubsweet/logger": ">=0.0.1",
"config": "^3.0.1",
"config": ">=3.0.1",
"pubsweet-server": ">=11.0.0"
},
"devDependencies": {
"jest": "^24.7.1",
"supertest": "^3.0.0"
},
"repository": {
"type": "git",
"url": "https://gitlab.coko.foundation/pubsweet/pubsweet",
"path": "AWSS3"
"path": "components/server/component-aws-s3"
},
"publishConfig": {
"access": "public"
......
......@@ -9,10 +9,8 @@
"dependencies": {
"@pubsweet/component-send-email": "^0.3.0",
"@pubsweet/errors": "^2.0.25",
"body-parser": "^1.17.2",
"config": "^3.0.1",
"moment": "^2.18.1",
"nodemailer": "^4.0.1"
"moment": "^2.18.1"
},
"peerDependencies": {
"@pubsweet/logger": ">=0.0.1",
......
module.exports = require('./src/SendEmail')
......@@ -7,19 +7,18 @@
"files": [
"src"
],
"main": "index.js",
"main": "src/index.js",
"dependencies": {
"aws-sdk": "^2.185.0",
"nodemailer": "^4.4.2"
},
"peerDependencies": {
"@pubsweet/logger": "^0.0.1",
"config": "^3.0.1"
"@pubsweet/logger": ">=0.0.1",
"config": ">=3.0.1"
},
"repository": {
"type": "git",
"url": "https://gitlab.coko.foundation/pubsweet/pubsweet",
"path": "SendEmail"
"path": "components/server/component-send-email"
},
"publishConfig": {
"access": "public"
......
module.exports = require('./SendEmail')
......@@ -7,22 +7,14 @@
"license": "MIT",
"dependencies": {
"@pubsweet/component-send-email": "^0.3.0",
"@pubsweet/db-manager": "^3.1.0",
"@pubsweet/errors": "^2.0.25",
"@pubsweet/models": "^0.3.0",
"lodash": "^4.17.11",
"moment": "^2.18.1",
"passport": "^0.4.0"
},
"devDependencies": {
"body-parser": "^1.17.2",
"jest": "^24.7.1",
"superagent": "^3.8.2",
"supertest": "^3.0.0"
},
"peerDependencies": {
"@pubsweet/logger": ">=0.0.1",
"config": "^3.0.1",
"config": ">=3.0.1",
"pubsweet-server": ">=1.0.0"
},
"gitHead": "6b100b76f21785e5e50fca082a2743d3d0b1c88a"
......