diff --git a/README.md b/README.md index 350fc9af..a2454f3d 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,6 @@ # LibCrowds [![Greenkeeper badge](https://badges.greenkeeper.io/LibCrowds/libcrowds.svg)](https://greenkeeper.io/) - [![Build Status](https://travis-ci.org/LibCrowds/libcrowds.svg?branch=master)](https://travis-ci.org/LibCrowds/libcrowds) [![DOI](https://zenodo.org/badge/92406558.svg)](https://zenodo.org/badge/latestdoi/92406558) diff --git a/assets/style/main.scss b/assets/style/main.scss index c5c858c1..29171476 100644 --- a/assets/style/main.scss +++ b/assets/style/main.scss @@ -5,7 +5,6 @@ @import '~bootstrap/scss/bootstrap', - '~bootstrap-vue/dist/bootstrap-vue', '~chartist/dist/scss/chartist', 'partials/cards', 'partials/charts', diff --git a/components/modals/Leaderboard.vue b/components/modals/Leaderboard.vue index c3449dce..72b1e419 100644 --- a/components/modals/Leaderboard.vue +++ b/components/modals/Leaderboard.vue @@ -2,7 +2,6 @@ - + @@ -71,12 +71,12 @@ Sign Out - + - + Sign up - + diff --git a/components/navbars/Collection.vue b/components/navbars/Collection.vue index 68bd49f7..2943e452 100644 --- a/components/navbars/Collection.vue +++ b/components/navbars/Collection.vue @@ -40,7 +40,7 @@ - + Data - + - + @@ -147,32 +147,30 @@ Sign Out - + - - - - Sign in - - - Sign up - - + + + Sign in + + + Sign up + + - diff --git a/nuxt.config.js b/nuxt.config.js index 8ef15b13..523968e3 100644 --- a/nuxt.config.js +++ b/nuxt.config.js @@ -26,10 +26,10 @@ const config = { ], build: { vendor: [ - 'bootstrap-vue', '~/plugins/filters.js', '~/plugins/libcrowds-viewer', '~/plugins/notifications', + 'bootstrap-vue', 'progressbar.js', 'vue-awesome', 'vue-chartist', @@ -78,7 +78,6 @@ const config = { } }, plugins: [ - { src: '~/plugins/bootstrap-vue' }, { src: '~/plugins/filters' }, { src: '~/plugins/libcrowds-viewer', ssr: false }, { src: '~/plugins/notifications', ssr: false }, @@ -98,7 +97,8 @@ const config = { modules: [ '@nuxtjs/axios', '@nuxtjs/pwa', - '@nuxtjs/proxy' + '@nuxtjs/proxy', + ['bootstrap-vue/nuxt', { css: false }] ], axios: { baseURL: localConfig.pybossa.host, diff --git a/package-lock.json b/package-lock.json index 3130991d..649fcd8b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "libcrowds", - "version": "1.0.0-beta.5", + "version": "1.0.0-beta.6", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -1676,11 +1676,14 @@ "integrity": "sha512-DzGtdTlKbrMoGMpz0LigKSqJ+MgtFKxA791PU/q062OlRG0HybNZcTLH7rpDAmLS66Y3esN9yzKHLLbqa5UR3w==" }, "bootstrap-vue": { - "version": "1.0.0-beta.9", - "resolved": "https://registry.npmjs.org/bootstrap-vue/-/bootstrap-vue-1.0.0-beta.9.tgz", - "integrity": "sha512-0wYWRebZROB+IXpatXgr/pUsiZ7ZUl/uJmc3bpIKlsi9sciE7wIdjV9PhdHnqoipU0kYylHfdcHimOHl5aIbjA==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bootstrap-vue/-/bootstrap-vue-1.0.2.tgz", + "integrity": "sha512-jDvCyXsjUTx6mDqrgaM9ZtsBiH6gJ1wCo4FmRr8/Ne03G3qSepKpzuk7rXouzVsSMBXU3mRx/i4UowmRCUW8lg==", "requires": { - "bootstrap": "4.0.0-beta.2" + "lodash.startcase": "4.4.0", + "opencollective": "1.0.3", + "popper.js": "1.12.6", + "vue-functional-data-merge": "1.0.6" } }, "boxen": { @@ -6246,9 +6249,9 @@ } }, "libcrowds-viewer": { - "version": "3.4.5", - "resolved": "https://registry.npmjs.org/libcrowds-viewer/-/libcrowds-viewer-3.4.5.tgz", - "integrity": "sha512-cJJm2u709jn4pHkFOR7m0bPrciJPWmGgE5gnyEZww29c6adL4YJMV6Hn8eiV1Gn0DcxcBRDdMWjtp6IfKTZJVA==", + "version": "3.4.7", + "resolved": "https://registry.npmjs.org/libcrowds-viewer/-/libcrowds-viewer-3.4.7.tgz", + "integrity": "sha512-gJdV0g1kzeNOxqphCgcqsu72Fm/UDx/a/h9YnOvXs0RN+imFFDtIAVUQ8yo+jddERakuzDdbmPf9X9gaBa7M+w==", "requires": { "clipboard": "1.7.1", "es6-object-assign": "1.1.0", @@ -6517,6 +6520,11 @@ "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", "integrity": "sha1-7dFMgk4sycHgsKG0K7UhBRakJDg=" }, + "lodash.startcase": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/lodash.startcase/-/lodash.startcase-4.4.0.tgz", + "integrity": "sha1-lDbjTtJgk+1/+uGTYUQ1CRXZrdg=" + }, "lodash.tail": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/lodash.tail/-/lodash.tail-4.1.1.tgz", @@ -12013,6 +12021,11 @@ "resolved": "https://registry.npmjs.org/vue-form-generator/-/vue-form-generator-2.1.1.tgz", "integrity": "sha1-D1dFIAXC0xD75UXKK/MBU1YvTyg=" }, + "vue-functional-data-merge": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/vue-functional-data-merge/-/vue-functional-data-merge-1.0.6.tgz", + "integrity": "sha512-wzUHcvLBiVJcDais1HdmFObi2VagMB5jd/dZuacDO0GCdHURxkvPrReaAyAhW/+g29j5gRu0QKP1DH7CaBRwmQ==" + }, "vue-gravatar": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/vue-gravatar/-/vue-gravatar-1.1.3.tgz", diff --git a/package.json b/package.json index 53383991..326716ae 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "libcrowds", - "version": "1.0.0-beta.5", + "version": "1.0.0-beta.6", "description": "A Vue.js frontend for PYBOSSA.", "author": "Alex Mendes ", "private": true, @@ -19,7 +19,7 @@ "@nuxtjs/proxy": "^1.1.2", "@nuxtjs/pwa": "^1.0.2", "bootstrap": "4.0.0-beta.2", - "bootstrap-vue": "^1.0.0-beta.9", + "bootstrap-vue": "^1.0.2", "capitalize": "^1.0.0", "chartist-plugin-legend": "^0.6.2", "chartist-plugin-tooltips": "0.0.17", @@ -32,11 +32,10 @@ "git-rev-sync": "^1.9.1", "hamburgers": "^0.9.1", "izitoast": "^1.1.5", - "libcrowds-viewer": "^3.4.5", + "libcrowds-viewer": "^3.4.7", "lodash": "^4.17.4", "moment": "^2.19.1", "nuxt": "1.0.0-rc11", - "popper.js": "^1.12.5", "progressbar.js": "^1.0.1", "raven": "^2.2.1", "raven-js": "^3.19.1", diff --git a/plugins/bootstrap-vue.js b/plugins/bootstrap-vue.js deleted file mode 100644 index 5734e917..00000000 --- a/plugins/bootstrap-vue.js +++ /dev/null @@ -1,4 +0,0 @@ -import Vue from 'vue' -import BootstrapVue from 'bootstrap-vue' - -Vue.use(BootstrapVue) diff --git a/test/fixtures/routes.js b/test/fixtures/routes.js index 4d9fc6c6..a8a74d41 100644 --- a/test/fixtures/routes.js +++ b/test/fixtures/routes.js @@ -5,9 +5,9 @@ export const routes = [ name: 'index' }, { - path: '/admin/site/collections', + path: '/help/tos', component: jest.fn(), - name: 'admin-site-collections' + name: 'help-tos' }, { path: '/help/privacy', @@ -15,14 +15,9 @@ export const routes = [ name: 'help-privacy' }, { - path: '/admin/site/dashboard', - component: jest.fn(), - name: 'admin-site-dashboard' - }, - { - path: '/account/signin', + path: '/help/cookies', component: jest.fn(), - name: 'account-signin' + name: 'help-cookies' }, { path: '/account/newsletter', @@ -30,49 +25,49 @@ export const routes = [ name: 'account-newsletter' }, { - path: '/account/register', + path: '/admin/collection', component: jest.fn(), - name: 'account-register' + name: 'admin-collection' }, { - path: '/admin/site/featured', + path: '/help/api', component: jest.fn(), - name: 'admin-site-featured' + name: 'help-api' }, { - path: '/admin/site/announcements', + path: '/account/signin', component: jest.fn(), - name: 'admin-site-announcements' + name: 'account-signin' }, { - path: '/help/tos', + path: '/account/register', component: jest.fn(), - name: 'help-tos' + name: 'account-register' }, { - path: '/admin/site/jobs', + path: '/admin/project/open', component: jest.fn(), - name: 'admin-site-jobs' + name: 'admin-project-open' }, { - path: '/help/api', + path: '/admin/site/users', component: jest.fn(), - name: 'help-api' + name: 'admin-site-users' }, { - path: '/admin/site/users', + path: '/admin/site/jobs', component: jest.fn(), - name: 'admin-site-users' + name: 'admin-site-jobs' }, { - path: '/help/cookies', + path: '/admin/site/dashboard', component: jest.fn(), - name: 'help-cookies' + name: 'admin-site-dashboard' }, { - path: '/admin/site/announcements/new', + path: '/admin/collection/new', component: jest.fn(), - name: 'admin-site-announcements-new' + name: 'admin-collection-new' }, { path: '/account/password/reset', @@ -80,14 +75,19 @@ export const routes = [ name: 'account-password-reset' }, { - path: '/admin/site/collections/new', + path: '/account/password/forgotten', component: jest.fn(), - name: 'admin-site-collections-new' + name: 'account-password-forgotten' }, { - path: '/account/password/forgotten', + path: '/admin/site/announcements', component: jest.fn(), - name: 'account-password-forgotten' + name: 'admin-site-announcements' + }, + { + path: '/admin/site/announcements/new', + component: jest.fn(), + name: 'admin-site-announcements-new' }, { path: '/admin/site/announcements/:id/update', @@ -95,24 +95,24 @@ export const routes = [ name: 'admin-site-announcements-id-update' }, { - path: '/admin/site/collections/:id/update', + path: '/admin/project/:short_name?/tags', component: jest.fn(), - name: 'admin-site-collections-id-update' + name: 'admin-project-short_name-tags' }, { - path: '/account/:name?', + path: '/admin/project/:short_name?/collection', component: jest.fn(), - name: 'account-name' + name: 'admin-project-short_name-collection' }, { - path: '/collection/:short_name?', + path: '/admin/project/:short_name?/settings', component: jest.fn(), - name: 'collection-short_name' + name: 'admin-project-short_name-settings' }, { - path: '/collection/:short_name?/projects', + path: '/admin/collection/:short_name/settings', component: jest.fn(), - name: 'collection-short_name-projects' + name: 'admin-collection-short_name-settings' }, { path: '/admin/project/:short_name?/thumbnail', @@ -120,24 +120,39 @@ export const routes = [ name: 'admin-project-short_name-thumbnail' }, { - path: '/admin/project/:short_name?/tags', + path: '/admin/collection/:short_name/content', component: jest.fn(), - name: 'admin-project-short_name-tags' + name: 'admin-collection-short_name-content' }, { - path: '/admin/project/:short_name?/settings', + path: '/admin/collection/:short_name/delete', component: jest.fn(), - name: 'admin-project-short_name-settings' + name: 'admin-collection-short_name-delete' }, { - path: '/admin/project/open', + path: '/admin/collection/:short_name/tags', component: jest.fn(), - name: 'admin-project-open' + name: 'admin-collection-short_name-tags' }, { - path: '/account/:name?/announcements', + path: '/admin/collection/:short_name/terminology', component: jest.fn(), - name: 'account-name-announcements' + name: 'admin-collection-short_name-terminology' + }, + { + path: '/admin/collection/:short_name/featured', + component: jest.fn(), + name: 'admin-collection-short_name-featured' + }, + { + path: '/collection/:short_name?', + component: jest.fn(), + name: 'collection-short_name' + }, + { + path: '/account/:name?', + component: jest.fn(), + name: 'account-name' }, { path: '/collection/:short_name?/about', @@ -145,33 +160,48 @@ export const routes = [ name: 'collection-short_name-about' }, { - path: '/collection/:short_name?/data', + path: '/collection/:short_name?/projects', component: jest.fn(), - name: 'collection-short_name-data' + name: 'collection-short_name-projects' }, { - path: '/account/:name?/settings/avatar', + path: '/account/:name?/announcements', component: jest.fn(), - name: 'account-name-settings-avatar' + name: 'account-name-announcements' }, { - path: '/account/:name?/settings/api', + path: '/collection/:short_name?/data', component: jest.fn(), - name: 'account-name-settings-api' + name: 'collection-short_name-data' }, { path: '/account/:name?/settings/profile', component: jest.fn(), name: 'account-name-settings-profile' }, + { + path: '/account/:name?/settings/avatar', + component: jest.fn(), + name: 'account-name-settings-avatar' + }, { path: '/account/:name?/settings/security', component: jest.fn(), name: 'account-name-settings-security' }, { - path: '/collection/:short_name?/projects/:id', + path: '/account/:name?/settings/api', + component: jest.fn(), + name: 'account-name-settings-api' + }, + { + path: '/collection/:short_name?/projects/:id/:presenter.vue?', + component: jest.fn(), + name: 'collection-short_name-projects-id-presenter.vue' + }, + { + path: '/collection/:short_name?/projects/:id/:presenter?', component: jest.fn(), - name: 'collection-short_name-projects-id' + name: 'collection-short_name-projects-id-presenter' } ] diff --git a/test/unit/specs/components/buttons/__snapshots__/projectContrib.spec.js.snap b/test/unit/specs/components/buttons/__snapshots__/projectContrib.spec.js.snap index 1eecc332..f3e932b5 100644 --- a/test/unit/specs/components/buttons/__snapshots__/projectContrib.spec.js.snap +++ b/test/unit/specs/components/buttons/__snapshots__/projectContrib.spec.js.snap @@ -4,7 +4,6 @@ exports[`ProjectContrib button is active by default 1`] = ` diff --git a/test/unit/specs/components/navbars/__snapshots__/app.spec.js.snap b/test/unit/specs/components/navbars/__snapshots__/app.spec.js.snap index b08d3b0d..94bf5ea7 100644 --- a/test/unit/specs/components/navbars/__snapshots__/app.spec.js.snap +++ b/test/unit/specs/components/navbars/__snapshots__/app.spec.js.snap @@ -18,7 +18,7 @@ exports[`App navbar renders correctly when signed in as admin 1`] = `