diff --git a/.gitignore b/.gitignore index d4b2026c183d21a8015f621d5951128a23273257..1eb612ec0b5a7618cc8c727849239478eb7f893d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +node_modules +*.log # Created by https://www.gitignore.io/api/osx,linux diff --git a/package.json b/package.json index 02ea9568281b8a6032886abc943228cd65a0290a..07570500f4fb6245bba34ede238889ca8e029179 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,11 @@ { + "name": "pubsweet-monorepo", + "private": true, "devDependencies": { "lerna": "^2.5.1" - } + }, + "workspaces": [ + "packages/*", + "packages/pubsweet-components/packages/*" + ] } diff --git a/packages/pubsweet-styleguide/src/config/journal/article-sections.js b/packages/pubsweet-styleguide/src/config/journal/article-sections.js deleted file mode 100644 index f258a498836451ea9f6b30abf64b44a2bf4c6c47..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/article-sections.js +++ /dev/null @@ -1,30 +0,0 @@ -export default [ - { - value: 'cognitive-psychology', - label: 'Cognitive Psychology', - }, - { - value: 'social-psychology', - label: 'Social Psychology', - }, - { - value: 'personality-psychology', - label: 'Personality Psychology', - }, - { - value: 'developmental-psychology', - label: 'Developmental Psychology', - }, - { - value: 'clinical-psychology', - label: 'Clinical Psychology', - }, - { - value: 'organizational-behavior', - label: 'Organizational Behavior', - }, - { - value: 'methodology', - label: 'Methodology and Research Practice', - }, -] diff --git a/packages/pubsweet-styleguide/src/config/journal/article-types.js b/packages/pubsweet-styleguide/src/config/journal/article-types.js deleted file mode 100644 index bdaa9f9e39346a55815221a86b57050db13a97ac..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/article-types.js +++ /dev/null @@ -1,18 +0,0 @@ -export default [ - { - value: 'original-research', - label: 'Original Research Report', - }, - { - value: 'review', - label: 'Review', - }, - { - value: 'opinion', - label: 'Opinion/Commentary', - }, - { - value: 'registered-report', - label: 'Registered Report', - }, -] diff --git a/packages/pubsweet-styleguide/src/config/journal/decisions.js b/packages/pubsweet-styleguide/src/config/journal/decisions.js deleted file mode 100644 index 6a91c806aee2ea843eaa301739387e7522a103de..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/decisions.js +++ /dev/null @@ -1,23 +0,0 @@ -export default { - accept: { - label: 'Accept', - color: 'green', - message: 'The submission has been accepted for publication', - }, - minor: { - label: 'Minor revisions', - color: 'orange', - message: - 'The submission will be accepted for publication after minor changes', - }, - major: { - label: 'Major revisions', - color: 'yellow', - message: 'The requested changes must be made before submission for review', - }, - reject: { - label: 'Reject', - color: 'red', - message: 'The submission is not acceptable for publication', - }, -} diff --git a/packages/pubsweet-styleguide/src/config/journal/declarations.js b/packages/pubsweet-styleguide/src/config/journal/declarations.js deleted file mode 100644 index 012e4d46c2bfe3b20da969a9277a391d61c18094..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/declarations.js +++ /dev/null @@ -1,28 +0,0 @@ -export default { - questions: [ - { - id: 'openData', - legend: 'Data is open', - }, - { - id: 'previouslySubmitted', - legend: 'Previously submitted', - }, - { - id: 'openPeerReview', - legend: 'Open peer review', - }, - { - id: 'streamlinedReview', - legend: 'Streamlined review', - }, - { - id: 'researchNexus', - legend: 'Submitted as part of the research nexus?', - }, - { - id: 'preregistered', - legend: 'Pre-registered?', - }, - ], -} diff --git a/packages/pubsweet-styleguide/src/config/journal/editors.js b/packages/pubsweet-styleguide/src/config/journal/editors.js deleted file mode 100644 index e19de06a9df69826e9e7667f9ff7d4d2ca44944f..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/editors.js +++ /dev/null @@ -1,32 +0,0 @@ -export default { - managingEditor: [ - { - user: 1, - name: 'Managing Editor One', - }, - { - user: 2, - name: 'Managing Editor Two', - }, - ], - seniorEditor: [ - { - user: 3, - name: 'Senior Editor One', - }, - { - user: 4, - name: 'Senior Editor Two', - }, - ], - handlingEditor: [ - { - user: 5, - name: 'Handling Editor One', - }, - { - user: 6, - name: 'Handling Editor Two', - }, - ], -} diff --git a/packages/pubsweet-styleguide/src/config/journal/index.js b/packages/pubsweet-styleguide/src/config/journal/index.js deleted file mode 100644 index 30bc3a405632a2e2ff3972ac0c490a26666ce330..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/index.js +++ /dev/null @@ -1,9 +0,0 @@ -export { default as metadata } from './metadata' -export { default as declarations } from './declarations' -export { default as decisions } from './decisions' -export { default as recommendations } from './recommendations' -export { default as sections } from './sections' -export { default as articleSections } from './article-sections' -export { default as articleTypes } from './article-types' -export { default as editors } from './editors' -export { default as roles } from './roles' diff --git a/packages/pubsweet-styleguide/src/config/journal/metadata.js b/packages/pubsweet-styleguide/src/config/journal/metadata.js deleted file mode 100644 index 940970ae1d4d51ac0889b940344d453af3e48360..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/metadata.js +++ /dev/null @@ -1,4 +0,0 @@ -export default { - name: 'Example Journal', - issn: '1234-1234', -} diff --git a/packages/pubsweet-styleguide/src/config/journal/recommendations.js b/packages/pubsweet-styleguide/src/config/journal/recommendations.js deleted file mode 100644 index ad4a252206cd22d092ada66a38271ab86881f2c9..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/recommendations.js +++ /dev/null @@ -1,17 +0,0 @@ -export default [ - { - value: 'accept', - label: 'Accept', - color: 'green', - }, - { - value: 'revise', - label: 'Revise', - color: 'orange', - }, - { - value: 'reject', - label: 'Reject', - color: 'red', - }, -] diff --git a/packages/pubsweet-styleguide/src/config/journal/roles.js b/packages/pubsweet-styleguide/src/config/journal/roles.js deleted file mode 100644 index 0f9334d4c66a69a75359e50150a8f7b40f153ee6..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/roles.js +++ /dev/null @@ -1,6 +0,0 @@ -export default { - author: 'Author', - handlingEditor: 'Handling Editor', - managingEditor: 'Managing Editor', - seniorEditor: 'Senior Editor', -} diff --git a/packages/pubsweet-styleguide/src/config/journal/sections.js b/packages/pubsweet-styleguide/src/config/journal/sections.js deleted file mode 100644 index 72bbd760b76499147343cb51e9a73954f71eade3..0000000000000000000000000000000000000000 --- a/packages/pubsweet-styleguide/src/config/journal/sections.js +++ /dev/null @@ -1,6 +0,0 @@ -export default [ - { - id: 'submissions', - label: 'My Submissions', - }, -] diff --git a/packages/pubsweet-ui/webpack.config.js b/packages/pubsweet-ui/webpack.config.js deleted file mode 100644 index 4aa149ad2cbf750326137fc79ccd7e7685271ad3..0000000000000000000000000000000000000000 --- a/packages/pubsweet-ui/webpack.config.js +++ /dev/null @@ -1,3 +0,0 @@ -const webpackConfig = require('xpub-styleguide/src/webpack-config') - -module.exports = webpackConfig(__dirname) diff --git a/packages/pubsweet-styleguide/package.json b/packages/styleguide/package.json similarity index 87% rename from packages/pubsweet-styleguide/package.json rename to packages/styleguide/package.json index 8f10e73f6e17a2fb7b618e88b156fede82a099ad..46e9ef0f565e8c56f72f81f8b9d9a244fd37ae89 100644 --- a/packages/pubsweet-styleguide/package.json +++ b/packages/styleguide/package.json @@ -1,5 +1,5 @@ { - "name": "@pubweet/styleguide", + "name": "@pubsweet/styleguide", "version": "0.1.0", "files": [ "src", @@ -7,15 +7,14 @@ ], "main": "src", "dependencies": { + "@pubsweet/theme": "^0.1.0", "react": "^15.6.1", "react-dom": "^15.6.1", "react-redux": "^5.0.2", "react-router-dom": "^4.2.2", "recompose": "^0.26.0", "redux": "^3.6.0", - "redux-form": "^7.0.3", - "xpub-journal": "^0.0.2", - "xpub-theme": "^0.0.2" + "redux-form": "^7.0.3" }, "devDependencies": { "babel-core": "^6.26.0", diff --git a/packages/pubsweet-styleguide/src/components/StyleGuideRenderer.js b/packages/styleguide/src/components/StyleGuideRenderer.js similarity index 100% rename from packages/pubsweet-styleguide/src/components/StyleGuideRenderer.js rename to packages/styleguide/src/components/StyleGuideRenderer.js diff --git a/packages/pubsweet-styleguide/src/components/StyleGuideRenderer.local.scss b/packages/styleguide/src/components/StyleGuideRenderer.local.scss similarity index 100% rename from packages/pubsweet-styleguide/src/components/StyleGuideRenderer.local.scss rename to packages/styleguide/src/components/StyleGuideRenderer.local.scss diff --git a/packages/pubsweet-styleguide/src/components/Wrapper.js b/packages/styleguide/src/components/Wrapper.js similarity index 71% rename from packages/pubsweet-styleguide/src/components/Wrapper.js rename to packages/styleguide/src/components/Wrapper.js index b0df3e215880398c8f3c948ea2d3cab36ac5b270..497248b4afba4bbb31f63f76235e38809b210a16 100644 --- a/packages/pubsweet-styleguide/src/components/Wrapper.js +++ b/packages/styleguide/src/components/Wrapper.js @@ -3,11 +3,8 @@ import { Provider } from 'react-redux' import { BrowserRouter as Router } from 'react-router-dom' import { reducer as formReducer } from 'redux-form' import { createStore, combineReducers } from 'redux' -import { JournalProvider } from 'xpub-journal' -import 'xpub-theme' - -import * as journal from '../config/journal' +import "@pubsweet/theme" import classes from './Wrapper.local.scss' @@ -23,9 +20,7 @@ const store = createStore( const Wrapper = ({ children }) => ( <Provider store={store}> <Router> - <JournalProvider journal={journal}> - <div className={classes.root}>{children}</div> - </JournalProvider> + <div className={classes.root}>{children}</div> </Router> </Provider> ) diff --git a/packages/pubsweet-styleguide/src/components/Wrapper.local.scss b/packages/styleguide/src/components/Wrapper.local.scss similarity index 100% rename from packages/pubsweet-styleguide/src/components/Wrapper.local.scss rename to packages/styleguide/src/components/Wrapper.local.scss diff --git a/packages/pubsweet-styleguide/src/components/index.js b/packages/styleguide/src/components/index.js similarity index 100% rename from packages/pubsweet-styleguide/src/components/index.js rename to packages/styleguide/src/components/index.js diff --git a/packages/pubsweet-styleguide/src/index.js b/packages/styleguide/src/index.js similarity index 100% rename from packages/pubsweet-styleguide/src/index.js rename to packages/styleguide/src/index.js diff --git a/packages/pubsweet-styleguide/src/webpack-config.js b/packages/styleguide/src/webpack-config.js similarity index 98% rename from packages/pubsweet-styleguide/src/webpack-config.js rename to packages/styleguide/src/webpack-config.js index 71c81cef1c423f1a706dd4cc76ce5f07cc55a936..01800d6d9758f9d214bc0242de86c7fd882250b2 100644 --- a/packages/pubsweet-styleguide/src/webpack-config.js +++ b/packages/styleguide/src/webpack-config.js @@ -12,6 +12,8 @@ module.exports = dir => { /xpub-[^/]+\/src/, /wax-[^/]+\/src/, /@pubsweet\/[^/]+\/src/, + /styleguide\/src/, + /ui\/src/ ] return { diff --git a/packages/pubsweet-styleguide/webpack.config.js b/packages/styleguide/webpack.config.js similarity index 100% rename from packages/pubsweet-styleguide/webpack.config.js rename to packages/styleguide/webpack.config.js diff --git a/packages/pubsweet-ui/.eslintrc b/packages/ui/.eslintrc similarity index 100% rename from packages/pubsweet-ui/.eslintrc rename to packages/ui/.eslintrc diff --git a/packages/pubsweet-ui/docs/colors.md b/packages/ui/docs/colors.md similarity index 100% rename from packages/pubsweet-ui/docs/colors.md rename to packages/ui/docs/colors.md diff --git a/packages/pubsweet-ui/docs/fonts.md b/packages/ui/docs/fonts.md similarity index 100% rename from packages/pubsweet-ui/docs/fonts.md rename to packages/ui/docs/fonts.md diff --git a/packages/pubsweet-ui/package.json b/packages/ui/package.json similarity index 93% rename from packages/pubsweet-ui/package.json rename to packages/ui/package.json index 59319dc89e14e0c2ffb4fcda283a2654339ce6cc..c88fb6264ce298122a6863c6073aa3c1f1e910f0 100644 --- a/packages/pubsweet-ui/package.json +++ b/packages/ui/package.json @@ -1,6 +1,6 @@ { - "name": "pubsweet-ui", - "version": "0.0.2", + "name": "@pubsweet/ui", + "version": "0.1.0", "files": [ "docs", "dist", @@ -27,6 +27,7 @@ "redux-form": "^7.0.3" }, "devDependencies": { + "@pubsweet/styleguide": "^0.1.0", "babel-core": "^6.26.0", "babel-loader": "^7.1.2", "babel-preset-env": "^1.6.0", @@ -43,8 +44,7 @@ "sass-loader": "^6.0.6", "style-loader": "^0.19.0", "webpack": "^3.8.1", - "webpack-node-externals": "^1.6.0", - "xpub-styleguide": "^0.0.2" + "webpack-node-externals": "^1.6.0" }, "jest": { "moduleNameMapper": { diff --git a/packages/pubsweet-ui/src/atoms/Attachment.js b/packages/ui/src/atoms/Attachment.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Attachment.js rename to packages/ui/src/atoms/Attachment.js diff --git a/packages/pubsweet-ui/src/atoms/Attachment.local.scss b/packages/ui/src/atoms/Attachment.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Attachment.local.scss rename to packages/ui/src/atoms/Attachment.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Attachment.md b/packages/ui/src/atoms/Attachment.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Attachment.md rename to packages/ui/src/atoms/Attachment.md diff --git a/packages/pubsweet-ui/src/atoms/Avatar.js b/packages/ui/src/atoms/Avatar.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Avatar.js rename to packages/ui/src/atoms/Avatar.js diff --git a/packages/pubsweet-ui/src/atoms/Avatar.local.scss b/packages/ui/src/atoms/Avatar.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Avatar.local.scss rename to packages/ui/src/atoms/Avatar.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Avatar.md b/packages/ui/src/atoms/Avatar.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Avatar.md rename to packages/ui/src/atoms/Avatar.md diff --git a/packages/pubsweet-ui/src/atoms/Badge.js b/packages/ui/src/atoms/Badge.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Badge.js rename to packages/ui/src/atoms/Badge.js diff --git a/packages/pubsweet-ui/src/atoms/Badge.local.scss b/packages/ui/src/atoms/Badge.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Badge.local.scss rename to packages/ui/src/atoms/Badge.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Badge.md b/packages/ui/src/atoms/Badge.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Badge.md rename to packages/ui/src/atoms/Badge.md diff --git a/packages/pubsweet-ui/src/atoms/Button.js b/packages/ui/src/atoms/Button.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Button.js rename to packages/ui/src/atoms/Button.js diff --git a/packages/pubsweet-ui/src/atoms/Button.local.scss b/packages/ui/src/atoms/Button.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Button.local.scss rename to packages/ui/src/atoms/Button.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Button.md b/packages/ui/src/atoms/Button.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Button.md rename to packages/ui/src/atoms/Button.md diff --git a/packages/pubsweet-ui/src/atoms/Checkbox.js b/packages/ui/src/atoms/Checkbox.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Checkbox.js rename to packages/ui/src/atoms/Checkbox.js diff --git a/packages/pubsweet-ui/src/atoms/Checkbox.local.scss b/packages/ui/src/atoms/Checkbox.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Checkbox.local.scss rename to packages/ui/src/atoms/Checkbox.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Checkbox.md b/packages/ui/src/atoms/Checkbox.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Checkbox.md rename to packages/ui/src/atoms/Checkbox.md diff --git a/packages/pubsweet-ui/src/atoms/File.js b/packages/ui/src/atoms/File.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/File.js rename to packages/ui/src/atoms/File.js diff --git a/packages/pubsweet-ui/src/atoms/File.local.scss b/packages/ui/src/atoms/File.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/File.local.scss rename to packages/ui/src/atoms/File.local.scss diff --git a/packages/pubsweet-ui/src/atoms/File.md b/packages/ui/src/atoms/File.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/File.md rename to packages/ui/src/atoms/File.md diff --git a/packages/pubsweet-ui/src/atoms/Icon.js b/packages/ui/src/atoms/Icon.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Icon.js rename to packages/ui/src/atoms/Icon.js diff --git a/packages/pubsweet-ui/src/atoms/Icon.local.scss b/packages/ui/src/atoms/Icon.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Icon.local.scss rename to packages/ui/src/atoms/Icon.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Icon.md b/packages/ui/src/atoms/Icon.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Icon.md rename to packages/ui/src/atoms/Icon.md diff --git a/packages/pubsweet-ui/src/atoms/Menu.js b/packages/ui/src/atoms/Menu.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Menu.js rename to packages/ui/src/atoms/Menu.js diff --git a/packages/pubsweet-ui/src/atoms/Menu.local.scss b/packages/ui/src/atoms/Menu.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Menu.local.scss rename to packages/ui/src/atoms/Menu.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Menu.md b/packages/ui/src/atoms/Menu.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Menu.md rename to packages/ui/src/atoms/Menu.md diff --git a/packages/pubsweet-ui/src/atoms/Radio.js b/packages/ui/src/atoms/Radio.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Radio.js rename to packages/ui/src/atoms/Radio.js diff --git a/packages/pubsweet-ui/src/atoms/Radio.local.scss b/packages/ui/src/atoms/Radio.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Radio.local.scss rename to packages/ui/src/atoms/Radio.local.scss diff --git a/packages/pubsweet-ui/src/atoms/Radio.md b/packages/ui/src/atoms/Radio.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Radio.md rename to packages/ui/src/atoms/Radio.md diff --git a/packages/pubsweet-ui/src/atoms/Tags.js b/packages/ui/src/atoms/Tags.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/Tags.js rename to packages/ui/src/atoms/Tags.js diff --git a/packages/pubsweet-ui/src/atoms/Tags.md b/packages/ui/src/atoms/Tags.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/Tags.md rename to packages/ui/src/atoms/Tags.md diff --git a/packages/pubsweet-ui/src/atoms/Tags.scss b/packages/ui/src/atoms/Tags.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/Tags.scss rename to packages/ui/src/atoms/Tags.scss diff --git a/packages/pubsweet-ui/src/atoms/TextField.js b/packages/ui/src/atoms/TextField.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/TextField.js rename to packages/ui/src/atoms/TextField.js diff --git a/packages/pubsweet-ui/src/atoms/TextField.local.scss b/packages/ui/src/atoms/TextField.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/TextField.local.scss rename to packages/ui/src/atoms/TextField.local.scss diff --git a/packages/pubsweet-ui/src/atoms/TextField.md b/packages/ui/src/atoms/TextField.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/TextField.md rename to packages/ui/src/atoms/TextField.md diff --git a/packages/pubsweet-ui/src/atoms/UploadingFile.js b/packages/ui/src/atoms/UploadingFile.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/UploadingFile.js rename to packages/ui/src/atoms/UploadingFile.js diff --git a/packages/pubsweet-ui/src/atoms/UploadingFile.local.scss b/packages/ui/src/atoms/UploadingFile.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/UploadingFile.local.scss rename to packages/ui/src/atoms/UploadingFile.local.scss diff --git a/packages/pubsweet-ui/src/atoms/UploadingFile.md b/packages/ui/src/atoms/UploadingFile.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/UploadingFile.md rename to packages/ui/src/atoms/UploadingFile.md diff --git a/packages/pubsweet-ui/src/atoms/ValidatedField.js b/packages/ui/src/atoms/ValidatedField.js similarity index 100% rename from packages/pubsweet-ui/src/atoms/ValidatedField.js rename to packages/ui/src/atoms/ValidatedField.js diff --git a/packages/pubsweet-ui/src/atoms/ValidatedField.local.scss b/packages/ui/src/atoms/ValidatedField.local.scss similarity index 100% rename from packages/pubsweet-ui/src/atoms/ValidatedField.local.scss rename to packages/ui/src/atoms/ValidatedField.local.scss diff --git a/packages/pubsweet-ui/src/atoms/ValidatedField.md b/packages/ui/src/atoms/ValidatedField.md similarity index 100% rename from packages/pubsweet-ui/src/atoms/ValidatedField.md rename to packages/ui/src/atoms/ValidatedField.md diff --git a/packages/pubsweet-ui/src/index.js b/packages/ui/src/index.js similarity index 100% rename from packages/pubsweet-ui/src/index.js rename to packages/ui/src/index.js diff --git a/packages/pubsweet-ui/src/lib/animation.scss b/packages/ui/src/lib/animation.scss similarity index 100% rename from packages/pubsweet-ui/src/lib/animation.scss rename to packages/ui/src/lib/animation.scss diff --git a/packages/pubsweet-ui/src/lib/colors.local.scss b/packages/ui/src/lib/colors.local.scss similarity index 100% rename from packages/pubsweet-ui/src/lib/colors.local.scss rename to packages/ui/src/lib/colors.local.scss diff --git a/packages/pubsweet-ui/src/molecules/AppBar.js b/packages/ui/src/molecules/AppBar.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/AppBar.js rename to packages/ui/src/molecules/AppBar.js diff --git a/packages/pubsweet-ui/src/molecules/AppBar.local.scss b/packages/ui/src/molecules/AppBar.local.scss similarity index 100% rename from packages/pubsweet-ui/src/molecules/AppBar.local.scss rename to packages/ui/src/molecules/AppBar.local.scss diff --git a/packages/pubsweet-ui/src/molecules/AppBar.md b/packages/ui/src/molecules/AppBar.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/AppBar.md rename to packages/ui/src/molecules/AppBar.md diff --git a/packages/pubsweet-ui/src/molecules/Attachments.js b/packages/ui/src/molecules/Attachments.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/Attachments.js rename to packages/ui/src/molecules/Attachments.js diff --git a/packages/pubsweet-ui/src/molecules/Attachments.local.scss b/packages/ui/src/molecules/Attachments.local.scss similarity index 100% rename from packages/pubsweet-ui/src/molecules/Attachments.local.scss rename to packages/ui/src/molecules/Attachments.local.scss diff --git a/packages/pubsweet-ui/src/molecules/Attachments.md b/packages/ui/src/molecules/Attachments.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/Attachments.md rename to packages/ui/src/molecules/Attachments.md diff --git a/packages/pubsweet-ui/src/molecules/CheckboxGroup.js b/packages/ui/src/molecules/CheckboxGroup.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/CheckboxGroup.js rename to packages/ui/src/molecules/CheckboxGroup.js diff --git a/packages/pubsweet-ui/src/molecules/CheckboxGroup.md b/packages/ui/src/molecules/CheckboxGroup.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/CheckboxGroup.md rename to packages/ui/src/molecules/CheckboxGroup.md diff --git a/packages/pubsweet-ui/src/molecules/Files.js b/packages/ui/src/molecules/Files.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/Files.js rename to packages/ui/src/molecules/Files.js diff --git a/packages/pubsweet-ui/src/molecules/Files.local.scss b/packages/ui/src/molecules/Files.local.scss similarity index 100% rename from packages/pubsweet-ui/src/molecules/Files.local.scss rename to packages/ui/src/molecules/Files.local.scss diff --git a/packages/pubsweet-ui/src/molecules/Files.md b/packages/ui/src/molecules/Files.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/Files.md rename to packages/ui/src/molecules/Files.md diff --git a/packages/pubsweet-ui/src/molecules/PlainButton.js b/packages/ui/src/molecules/PlainButton.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/PlainButton.js rename to packages/ui/src/molecules/PlainButton.js diff --git a/packages/pubsweet-ui/src/molecules/PlainButton.local.scss b/packages/ui/src/molecules/PlainButton.local.scss similarity index 100% rename from packages/pubsweet-ui/src/molecules/PlainButton.local.scss rename to packages/ui/src/molecules/PlainButton.local.scss diff --git a/packages/pubsweet-ui/src/molecules/PlainButton.md b/packages/ui/src/molecules/PlainButton.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/PlainButton.md rename to packages/ui/src/molecules/PlainButton.md diff --git a/packages/pubsweet-ui/src/molecules/RadioGroup.js b/packages/ui/src/molecules/RadioGroup.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/RadioGroup.js rename to packages/ui/src/molecules/RadioGroup.js diff --git a/packages/pubsweet-ui/src/molecules/RadioGroup.md b/packages/ui/src/molecules/RadioGroup.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/RadioGroup.md rename to packages/ui/src/molecules/RadioGroup.md diff --git a/packages/pubsweet-ui/src/molecules/Supplementary.js b/packages/ui/src/molecules/Supplementary.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/Supplementary.js rename to packages/ui/src/molecules/Supplementary.js diff --git a/packages/pubsweet-ui/src/molecules/Supplementary.md b/packages/ui/src/molecules/Supplementary.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/Supplementary.md rename to packages/ui/src/molecules/Supplementary.md diff --git a/packages/pubsweet-ui/src/molecules/Upload.js b/packages/ui/src/molecules/Upload.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/Upload.js rename to packages/ui/src/molecules/Upload.js diff --git a/packages/pubsweet-ui/src/molecules/YesOrNo.js b/packages/ui/src/molecules/YesOrNo.js similarity index 100% rename from packages/pubsweet-ui/src/molecules/YesOrNo.js rename to packages/ui/src/molecules/YesOrNo.js diff --git a/packages/pubsweet-ui/src/molecules/YesOrNo.local.scss b/packages/ui/src/molecules/YesOrNo.local.scss similarity index 100% rename from packages/pubsweet-ui/src/molecules/YesOrNo.local.scss rename to packages/ui/src/molecules/YesOrNo.local.scss diff --git a/packages/pubsweet-ui/src/molecules/YesOrNo.md b/packages/ui/src/molecules/YesOrNo.md similarity index 100% rename from packages/pubsweet-ui/src/molecules/YesOrNo.md rename to packages/ui/src/molecules/YesOrNo.md diff --git a/packages/pubsweet-ui/styleguide.config.js b/packages/ui/styleguide.config.js similarity index 77% rename from packages/pubsweet-ui/styleguide.config.js rename to packages/ui/styleguide.config.js index 8b14c4584ffe5d7db00e06d7fcfc6fa4042ffe97..00c0f2396fc676020a0e9c4807aeba98f3101ef6 100644 --- a/packages/pubsweet-ui/styleguide.config.js +++ b/packages/ui/styleguide.config.js @@ -23,9 +23,9 @@ module.exports = { skipComponentsWithoutExample: true, styleguideComponents: { StyleGuideRenderer: require.resolve( - 'xpub-styleguide/src/components/StyleGuideRenderer', + '@pubsweet/styleguide/src/components/StyleGuideRenderer', ), - Wrapper: require.resolve('xpub-styleguide/src/components/Wrapper'), + Wrapper: require.resolve('@pubsweet/styleguide/src/components/Wrapper'), }, theme: { color: { @@ -35,5 +35,5 @@ module.exports = { base: '"Fira Sans", sans-serif', }, }, - title: 'xpub-ui style guide', + title: 'PubSweet UI style guide', } diff --git a/packages/pubsweet-ui/test/AppBar.test.js b/packages/ui/test/AppBar.test.js similarity index 100% rename from packages/pubsweet-ui/test/AppBar.test.js rename to packages/ui/test/AppBar.test.js diff --git a/packages/pubsweet-ui/test/Menu.test.js b/packages/ui/test/Menu.test.js similarity index 100% rename from packages/pubsweet-ui/test/Menu.test.js rename to packages/ui/test/Menu.test.js diff --git a/packages/pubsweet-ui/test/Radio.test.js b/packages/ui/test/Radio.test.js similarity index 100% rename from packages/pubsweet-ui/test/Radio.test.js rename to packages/ui/test/Radio.test.js diff --git a/packages/pubsweet-ui/test/RadioGroup.test.js b/packages/ui/test/RadioGroup.test.js similarity index 100% rename from packages/pubsweet-ui/test/RadioGroup.test.js rename to packages/ui/test/RadioGroup.test.js diff --git a/packages/pubsweet-ui/test/YesOrNo.test.js b/packages/ui/test/YesOrNo.test.js similarity index 100% rename from packages/pubsweet-ui/test/YesOrNo.test.js rename to packages/ui/test/YesOrNo.test.js diff --git a/packages/pubsweet-ui/test/__snapshots__/AppBar.test.js.snap b/packages/ui/test/__snapshots__/AppBar.test.js.snap similarity index 100% rename from packages/pubsweet-ui/test/__snapshots__/AppBar.test.js.snap rename to packages/ui/test/__snapshots__/AppBar.test.js.snap diff --git a/packages/pubsweet-ui/test/__snapshots__/Menu.test.js.snap b/packages/ui/test/__snapshots__/Menu.test.js.snap similarity index 100% rename from packages/pubsweet-ui/test/__snapshots__/Menu.test.js.snap rename to packages/ui/test/__snapshots__/Menu.test.js.snap diff --git a/packages/pubsweet-ui/test/__snapshots__/Radio.test.js.snap b/packages/ui/test/__snapshots__/Radio.test.js.snap similarity index 100% rename from packages/pubsweet-ui/test/__snapshots__/Radio.test.js.snap rename to packages/ui/test/__snapshots__/Radio.test.js.snap diff --git a/packages/pubsweet-ui/test/__snapshots__/RadioGroup.test.js.snap b/packages/ui/test/__snapshots__/RadioGroup.test.js.snap similarity index 100% rename from packages/pubsweet-ui/test/__snapshots__/RadioGroup.test.js.snap rename to packages/ui/test/__snapshots__/RadioGroup.test.js.snap diff --git a/packages/pubsweet-ui/test/__snapshots__/YesOrNo.test.js.snap b/packages/ui/test/__snapshots__/YesOrNo.test.js.snap similarity index 100% rename from packages/pubsweet-ui/test/__snapshots__/YesOrNo.test.js.snap rename to packages/ui/test/__snapshots__/YesOrNo.test.js.snap diff --git a/packages/pubsweet-ui/test/config/transform.js b/packages/ui/test/config/transform.js similarity index 100% rename from packages/pubsweet-ui/test/config/transform.js rename to packages/ui/test/config/transform.js diff --git a/packages/pubsweet-ui/test/setup/enzyme.js b/packages/ui/test/setup/enzyme.js similarity index 100% rename from packages/pubsweet-ui/test/setup/enzyme.js rename to packages/ui/test/setup/enzyme.js diff --git a/packages/ui/webpack.config.js b/packages/ui/webpack.config.js new file mode 100644 index 0000000000000000000000000000000000000000..4709531b59eca773c8d2f8bb2d141e79d51f2b05 --- /dev/null +++ b/packages/ui/webpack.config.js @@ -0,0 +1,3 @@ +const webpackConfig = require('@pubsweet/styleguide/src/webpack-config') + +module.exports = webpackConfig(__dirname)