mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
Merge branch 'master' of github.com:Human-Connection/Human-Connection into 1707-reporting-with-specific-information
This commit is contained in:
commit
6dff10b236
@ -1,4 +1,4 @@
|
||||
FROM node:12.11.1-alpine as base
|
||||
FROM node:12.12.0-alpine as base
|
||||
LABEL Description="Backend of the Social Network Human-Connection.org" Vendor="Human Connection gGmbH" Version="0.0.1" Maintainer="Human Connection gGmbH (developer@human-connection.org)"
|
||||
|
||||
EXPOSE 4000
|
||||
|
||||
@ -42,13 +42,13 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@hapi/joi": "^16.1.7",
|
||||
"@sentry/node": "^5.6.2",
|
||||
"@sentry/node": "^5.7.0",
|
||||
"apollo-cache-inmemory": "~1.6.3",
|
||||
"apollo-client": "~2.6.4",
|
||||
"apollo-link-context": "~1.0.19",
|
||||
"apollo-link-http": "~1.5.16",
|
||||
"apollo-server": "~2.9.5",
|
||||
"apollo-server-express": "^2.9.4",
|
||||
"apollo-server": "~2.9.6",
|
||||
"apollo-server-express": "^2.9.6",
|
||||
"babel-plugin-transform-runtime": "^6.23.0",
|
||||
"bcryptjs": "~2.4.3",
|
||||
"cheerio": "~1.0.0-rc.3",
|
||||
@ -105,13 +105,13 @@
|
||||
"xregexp": "^4.2.4"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/cli": "~7.6.3",
|
||||
"@babel/core": "~7.6.2",
|
||||
"@babel/cli": "~7.6.4",
|
||||
"@babel/core": "~7.6.4",
|
||||
"@babel/node": "~7.6.3",
|
||||
"@babel/plugin-proposal-throw-expressions": "^7.2.0",
|
||||
"@babel/preset-env": "~7.6.3",
|
||||
"@babel/register": "~7.6.2",
|
||||
"apollo-server-testing": "~2.9.5",
|
||||
"apollo-server-testing": "~2.9.6",
|
||||
"babel-core": "~7.0.0-0",
|
||||
"babel-eslint": "~10.0.3",
|
||||
"babel-jest": "~24.9.0",
|
||||
@ -121,7 +121,7 @@
|
||||
"eslint-config-prettier": "~6.4.0",
|
||||
"eslint-config-standard": "~14.1.0",
|
||||
"eslint-plugin-import": "~2.18.2",
|
||||
"eslint-plugin-jest": "~22.17.0",
|
||||
"eslint-plugin-jest": "~22.19.0",
|
||||
"eslint-plugin-node": "~10.0.0",
|
||||
"eslint-plugin-prettier": "~3.1.1",
|
||||
"eslint-plugin-promise": "~4.2.1",
|
||||
|
||||
@ -18,7 +18,6 @@ export default async function fileUpload(params, { file, url }, uploadCallback =
|
||||
const fileLocation = `/uploads/${Date.now()}-${slug(name)}`
|
||||
await uploadCallback({ createReadStream, fileLocation })
|
||||
delete params[file]
|
||||
|
||||
params[url] = fileLocation
|
||||
}
|
||||
|
||||
|
||||
@ -1,31 +1,49 @@
|
||||
import { GraphQLClient } from 'graphql-request'
|
||||
import { createTestClient } from 'apollo-server-testing'
|
||||
import Factory from '../../seed/factories'
|
||||
import { host, login, gql } from '../../jest/helpers'
|
||||
import { gql } from '../../jest/helpers'
|
||||
import { neode as getNeode, getDriver } from '../../bootstrap/neo4j'
|
||||
import createServer from '../../server'
|
||||
|
||||
const factory = Factory()
|
||||
let user
|
||||
let badge
|
||||
const driver = getDriver()
|
||||
const instance = getNeode()
|
||||
|
||||
let authenticatedUser, regularUser, administrator, moderator, badge, query, mutate
|
||||
|
||||
describe('rewards', () => {
|
||||
const variables = {
|
||||
from: 'indiegogo_en_rhino',
|
||||
to: 'u1',
|
||||
to: 'regular-user-id',
|
||||
}
|
||||
|
||||
beforeAll(async () => {
|
||||
const { server } = createServer({
|
||||
context: () => {
|
||||
return {
|
||||
driver,
|
||||
neode: instance,
|
||||
user: authenticatedUser,
|
||||
}
|
||||
},
|
||||
})
|
||||
query = createTestClient(server).query
|
||||
mutate = createTestClient(server).mutate
|
||||
})
|
||||
|
||||
beforeEach(async () => {
|
||||
user = await factory.create('User', {
|
||||
id: 'u1',
|
||||
regularUser = await factory.create('User', {
|
||||
id: 'regular-user-id',
|
||||
role: 'user',
|
||||
email: 'user@example.org',
|
||||
password: '1234',
|
||||
})
|
||||
await factory.create('User', {
|
||||
id: 'u2',
|
||||
moderator = await factory.create('User', {
|
||||
id: 'moderator-id',
|
||||
role: 'moderator',
|
||||
email: 'moderator@example.org',
|
||||
})
|
||||
await factory.create('User', {
|
||||
id: 'u3',
|
||||
administrator = await factory.create('User', {
|
||||
id: 'admin-id',
|
||||
role: 'admin',
|
||||
email: 'admin@example.org',
|
||||
})
|
||||
@ -42,7 +60,7 @@ describe('rewards', () => {
|
||||
})
|
||||
|
||||
describe('reward', () => {
|
||||
const mutation = gql`
|
||||
const rewardMutation = gql`
|
||||
mutation($from: ID!, $to: ID!) {
|
||||
reward(badgeKey: $from, userId: $to) {
|
||||
id
|
||||
@ -54,51 +72,61 @@ describe('rewards', () => {
|
||||
`
|
||||
|
||||
describe('unauthenticated', () => {
|
||||
let client
|
||||
|
||||
it('throws authorization error', async () => {
|
||||
client = new GraphQLClient(host)
|
||||
await expect(client.request(mutation, variables)).rejects.toThrow('Not Authorised')
|
||||
authenticatedUser = null
|
||||
await expect(mutate({ mutation: rewardMutation, variables })).resolves.toMatchObject({
|
||||
data: { reward: null },
|
||||
errors: [{ message: 'Not Authorised!' }],
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('authenticated admin', () => {
|
||||
let client
|
||||
beforeEach(async () => {
|
||||
const headers = await login({ email: 'admin@example.org', password: '1234' })
|
||||
client = new GraphQLClient(host, { headers })
|
||||
authenticatedUser = await administrator.toJson()
|
||||
})
|
||||
|
||||
describe('badge for id does not exist', () => {
|
||||
it('rejects with a telling error message', async () => {
|
||||
it('rejects with an informative error message', async () => {
|
||||
await expect(
|
||||
client.request(mutation, {
|
||||
...variables,
|
||||
from: 'bullshit',
|
||||
mutate({
|
||||
mutation: rewardMutation,
|
||||
variables: { to: 'regular-user-id', from: 'non-existent-badge-id' },
|
||||
}),
|
||||
).rejects.toThrow("Couldn't find a badge with that id")
|
||||
).resolves.toMatchObject({
|
||||
data: { reward: null },
|
||||
errors: [{ message: "Couldn't find a badge with that id" }],
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('user for id does not exist', () => {
|
||||
describe('non-existent user', () => {
|
||||
it('rejects with a telling error message', async () => {
|
||||
await expect(
|
||||
client.request(mutation, {
|
||||
...variables,
|
||||
to: 'bullshit',
|
||||
mutate({
|
||||
mutation: rewardMutation,
|
||||
variables: { to: 'non-existent-user-id', from: 'indiegogo_en_rhino' },
|
||||
}),
|
||||
).rejects.toThrow("Couldn't find a user with that id")
|
||||
).resolves.toMatchObject({
|
||||
data: { reward: null },
|
||||
errors: [{ message: "Couldn't find a user with that id" }],
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
it('rewards a badge to user', async () => {
|
||||
const expected = {
|
||||
reward: {
|
||||
id: 'u1',
|
||||
badges: [{ id: 'indiegogo_en_rhino' }],
|
||||
data: {
|
||||
reward: {
|
||||
id: 'regular-user-id',
|
||||
badges: [{ id: 'indiegogo_en_rhino' }],
|
||||
},
|
||||
},
|
||||
errors: undefined,
|
||||
}
|
||||
await expect(client.request(mutation, variables)).resolves.toEqual(expected)
|
||||
await expect(mutate({ mutation: rewardMutation, variables })).resolves.toMatchObject(
|
||||
expected,
|
||||
)
|
||||
})
|
||||
|
||||
it('rewards a second different badge to same user', async () => {
|
||||
@ -108,42 +136,74 @@ describe('rewards', () => {
|
||||
})
|
||||
const badges = [{ id: 'indiegogo_en_racoon' }, { id: 'indiegogo_en_rhino' }]
|
||||
const expected = {
|
||||
reward: {
|
||||
id: 'u1',
|
||||
badges: expect.arrayContaining(badges),
|
||||
data: {
|
||||
reward: {
|
||||
id: 'regular-user-id',
|
||||
badges: expect.arrayContaining(badges),
|
||||
},
|
||||
},
|
||||
errors: undefined,
|
||||
}
|
||||
await client.request(mutation, variables)
|
||||
await mutate({
|
||||
mutation: rewardMutation,
|
||||
variables: {
|
||||
to: 'regular-user-id',
|
||||
from: 'indiegogo_en_rhino',
|
||||
},
|
||||
})
|
||||
await expect(
|
||||
client.request(mutation, {
|
||||
...variables,
|
||||
from: 'indiegogo_en_racoon',
|
||||
mutate({
|
||||
mutation: rewardMutation,
|
||||
variables: {
|
||||
to: 'regular-user-id',
|
||||
from: 'indiegogo_en_racoon',
|
||||
},
|
||||
}),
|
||||
).resolves.toEqual(expected)
|
||||
).resolves.toMatchObject(expected)
|
||||
})
|
||||
|
||||
it('rewards the same badge as well to another user', async () => {
|
||||
const expected = {
|
||||
reward: {
|
||||
id: 'u2',
|
||||
badges: [{ id: 'indiegogo_en_rhino' }],
|
||||
data: {
|
||||
reward: {
|
||||
id: 'regular-user-2-id',
|
||||
badges: [{ id: 'indiegogo_en_rhino' }],
|
||||
},
|
||||
},
|
||||
errors: undefined,
|
||||
}
|
||||
await factory.create('User', {
|
||||
id: 'regular-user-2-id',
|
||||
email: 'regular2@email.com',
|
||||
})
|
||||
await mutate({
|
||||
mutation: rewardMutation,
|
||||
variables,
|
||||
})
|
||||
await expect(
|
||||
client.request(mutation, {
|
||||
...variables,
|
||||
to: 'u2',
|
||||
mutate({
|
||||
mutation: rewardMutation,
|
||||
variables: {
|
||||
to: 'regular-user-2-id',
|
||||
from: 'indiegogo_en_rhino',
|
||||
},
|
||||
}),
|
||||
).resolves.toEqual(expected)
|
||||
).resolves.toMatchObject(expected)
|
||||
})
|
||||
|
||||
it('creates no duplicate reward relationships', async () => {
|
||||
await client.request(mutation, variables)
|
||||
await client.request(mutation, variables)
|
||||
await mutate({
|
||||
mutation: rewardMutation,
|
||||
variables,
|
||||
})
|
||||
await mutate({
|
||||
mutation: rewardMutation,
|
||||
variables,
|
||||
})
|
||||
|
||||
const query = gql`
|
||||
const userQuery = gql`
|
||||
{
|
||||
User(id: "u1") {
|
||||
User(id: "regular-user-id") {
|
||||
badgesCount
|
||||
badges {
|
||||
id
|
||||
@ -151,22 +211,26 @@ describe('rewards', () => {
|
||||
}
|
||||
}
|
||||
`
|
||||
const expected = { User: [{ badgesCount: 1, badges: [{ id: 'indiegogo_en_rhino' }] }] }
|
||||
const expected = {
|
||||
data: { User: [{ badgesCount: 1, badges: [{ id: 'indiegogo_en_rhino' }] }] },
|
||||
errors: undefined,
|
||||
}
|
||||
|
||||
await expect(client.request(query)).resolves.toEqual(expected)
|
||||
await expect(query({ query: userQuery })).resolves.toMatchObject(expected)
|
||||
})
|
||||
})
|
||||
|
||||
describe('authenticated moderator', () => {
|
||||
let client
|
||||
beforeEach(async () => {
|
||||
const headers = await login({ email: 'moderator@example.org', password: '1234' })
|
||||
client = new GraphQLClient(host, { headers })
|
||||
authenticatedUser = moderator.toJson()
|
||||
})
|
||||
|
||||
describe('rewards bage to user', () => {
|
||||
describe('rewards badge to user', () => {
|
||||
it('throws authorization error', async () => {
|
||||
await expect(client.request(mutation, variables)).rejects.toThrow('Not Authorised')
|
||||
await expect(mutate({ mutation: rewardMutation, variables })).resolves.toMatchObject({
|
||||
data: { reward: null },
|
||||
errors: [{ message: 'Not Authorised!' }],
|
||||
})
|
||||
})
|
||||
})
|
||||
})
|
||||
@ -174,11 +238,14 @@ describe('rewards', () => {
|
||||
|
||||
describe('unreward', () => {
|
||||
beforeEach(async () => {
|
||||
await user.relateTo(badge, 'rewarded')
|
||||
await regularUser.relateTo(badge, 'rewarded')
|
||||
})
|
||||
const expected = { unreward: { id: 'u1', badges: [] } }
|
||||
const expected = {
|
||||
data: { unreward: { id: 'regular-user-id', badges: [] } },
|
||||
errors: undefined,
|
||||
}
|
||||
|
||||
const mutation = gql`
|
||||
const unrewardMutation = gql`
|
||||
mutation($from: ID!, $to: ID!) {
|
||||
unreward(badgeKey: $from, userId: $to) {
|
||||
id
|
||||
@ -191,9 +258,10 @@ describe('rewards', () => {
|
||||
|
||||
describe('check test setup', () => {
|
||||
it('user has one badge', async () => {
|
||||
const query = gql`
|
||||
authenticatedUser = regularUser.toJson()
|
||||
const userQuery = gql`
|
||||
{
|
||||
User(id: "u1") {
|
||||
User(id: "regular-user-id") {
|
||||
badgesCount
|
||||
badges {
|
||||
id
|
||||
@ -201,48 +269,54 @@ describe('rewards', () => {
|
||||
}
|
||||
}
|
||||
`
|
||||
const expected = { User: [{ badgesCount: 1, badges: [{ id: 'indiegogo_en_rhino' }] }] }
|
||||
const client = new GraphQLClient(host)
|
||||
await expect(client.request(query)).resolves.toEqual(expected)
|
||||
const expected = {
|
||||
data: { User: [{ badgesCount: 1, badges: [{ id: 'indiegogo_en_rhino' }] }] },
|
||||
errors: undefined,
|
||||
}
|
||||
await expect(query({ query: userQuery })).resolves.toMatchObject(expected)
|
||||
})
|
||||
})
|
||||
|
||||
describe('unauthenticated', () => {
|
||||
let client
|
||||
|
||||
it('throws authorization error', async () => {
|
||||
client = new GraphQLClient(host)
|
||||
await expect(client.request(mutation, variables)).rejects.toThrow('Not Authorised')
|
||||
authenticatedUser = null
|
||||
await expect(mutate({ mutation: unrewardMutation, variables })).resolves.toMatchObject({
|
||||
data: { unreward: null },
|
||||
errors: [{ message: 'Not Authorised!' }],
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('authenticated admin', () => {
|
||||
let client
|
||||
beforeEach(async () => {
|
||||
const headers = await login({ email: 'admin@example.org', password: '1234' })
|
||||
client = new GraphQLClient(host, { headers })
|
||||
authenticatedUser = await administrator.toJson()
|
||||
})
|
||||
|
||||
it('removes a badge from user', async () => {
|
||||
await expect(client.request(mutation, variables)).resolves.toEqual(expected)
|
||||
await expect(mutate({ mutation: unrewardMutation, variables })).resolves.toMatchObject(
|
||||
expected,
|
||||
)
|
||||
})
|
||||
|
||||
it('does not crash when unrewarding multiple times', async () => {
|
||||
await client.request(mutation, variables)
|
||||
await expect(client.request(mutation, variables)).resolves.toEqual(expected)
|
||||
await mutate({ mutation: unrewardMutation, variables })
|
||||
await expect(mutate({ mutation: unrewardMutation, variables })).resolves.toMatchObject(
|
||||
expected,
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
describe('authenticated moderator', () => {
|
||||
let client
|
||||
beforeEach(async () => {
|
||||
const headers = await login({ email: 'moderator@example.org', password: '1234' })
|
||||
client = new GraphQLClient(host, { headers })
|
||||
authenticatedUser = await moderator.toJson()
|
||||
})
|
||||
|
||||
describe('removes bage from user', () => {
|
||||
it('throws authorization error', async () => {
|
||||
await expect(client.request(mutation, variables)).rejects.toThrow('Not Authorised')
|
||||
await expect(mutate({ mutation: unrewardMutation, variables })).resolves.toMatchObject({
|
||||
data: { unreward: null },
|
||||
errors: [{ message: 'Not Authorised!' }],
|
||||
})
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
@ -14,10 +14,10 @@
|
||||
resolved "https://registry.yarnpkg.com/@apollographql/graphql-playground-html/-/graphql-playground-html-1.6.24.tgz#3ce939cb127fb8aaa3ffc1e90dff9b8af9f2e3dc"
|
||||
integrity sha512-8GqG48m1XqyXh4mIZrtB5xOhUwSsh1WsrrsaZQOEYYql3YN9DEu9OOSg0ILzXHZo/h2Q74777YE4YzlArQzQEQ==
|
||||
|
||||
"@babel/cli@~7.6.3":
|
||||
version "7.6.3"
|
||||
resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.6.3.tgz#1b0c62098c8a5e01e4a4a59a52cba9682e7e0906"
|
||||
integrity sha512-kWKOEeuylpa781yCeA5//eEx1u3WtLZqbi2VWXLKmb3QDPb5T2f7Yk311MK7bvvjR70dluAeiu4VXXsG1WwJsw==
|
||||
"@babel/cli@~7.6.4":
|
||||
version "7.6.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.6.4.tgz#9b35a4e15fa7d8f487418aaa8229c8b0bc815f20"
|
||||
integrity sha512-tqrDyvPryBM6xjIyKKUwr3s8CzmmYidwgdswd7Uc/Cv0ogZcuS1TYQTLx/eWKP3UbJ6JxZAiYlBZabXm/rtRsQ==
|
||||
dependencies:
|
||||
commander "^2.8.1"
|
||||
convert-source-map "^1.1.0"
|
||||
@ -27,7 +27,7 @@
|
||||
mkdirp "^0.5.1"
|
||||
output-file-sync "^2.0.0"
|
||||
slash "^2.0.0"
|
||||
source-map "^0.6.1"
|
||||
source-map "^0.5.0"
|
||||
optionalDependencies:
|
||||
chokidar "^2.1.8"
|
||||
|
||||
@ -38,18 +38,18 @@
|
||||
dependencies:
|
||||
"@babel/highlight" "^7.0.0"
|
||||
|
||||
"@babel/core@^7.1.0", "@babel/core@~7.6.2":
|
||||
version "7.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.2.tgz#069a776e8d5e9eefff76236bc8845566bd31dd91"
|
||||
integrity sha512-l8zto/fuoZIbncm+01p8zPSDZu/VuuJhAfA7d/AbzM09WR7iVhavvfNDYCNpo1VvLk6E6xgAoP9P+/EMJHuRkQ==
|
||||
"@babel/core@^7.1.0", "@babel/core@~7.6.4":
|
||||
version "7.6.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.4.tgz#6ebd9fe00925f6c3e177bb726a188b5f578088ff"
|
||||
integrity sha512-Rm0HGw101GY8FTzpWSyRbki/jzq+/PkNQJ+nSulrdY6gFGOsNseCqD6KHRYe2E+EdzuBdr2pxCp6s4Uk6eJ+XQ==
|
||||
dependencies:
|
||||
"@babel/code-frame" "^7.5.5"
|
||||
"@babel/generator" "^7.6.2"
|
||||
"@babel/generator" "^7.6.4"
|
||||
"@babel/helpers" "^7.6.2"
|
||||
"@babel/parser" "^7.6.2"
|
||||
"@babel/parser" "^7.6.4"
|
||||
"@babel/template" "^7.6.0"
|
||||
"@babel/traverse" "^7.6.2"
|
||||
"@babel/types" "^7.6.0"
|
||||
"@babel/traverse" "^7.6.3"
|
||||
"@babel/types" "^7.6.3"
|
||||
convert-source-map "^1.1.0"
|
||||
debug "^4.1.0"
|
||||
json5 "^2.1.0"
|
||||
@ -58,12 +58,12 @@
|
||||
semver "^5.4.1"
|
||||
source-map "^0.5.0"
|
||||
|
||||
"@babel/generator@^7.4.0", "@babel/generator@^7.6.2":
|
||||
version "7.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.6.2.tgz#dac8a3c2df118334c2a29ff3446da1636a8f8c03"
|
||||
integrity sha512-j8iHaIW4gGPnViaIHI7e9t/Hl8qLjERI6DcV9kEpAIDJsAOrcnXqRS7t+QbhL76pwbtqP+QCQLL0z1CyVmtjjQ==
|
||||
"@babel/generator@^7.4.0", "@babel/generator@^7.6.3", "@babel/generator@^7.6.4":
|
||||
version "7.6.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.6.4.tgz#a4f8437287bf9671b07f483b76e3bb731bc97671"
|
||||
integrity sha512-jsBuXkFoZxk0yWLyGI9llT9oiQ2FeTASmRFE32U+aaDTfoE92t78eroO7PTpU/OrYq38hlcDM6vbfLDaOLy+7w==
|
||||
dependencies:
|
||||
"@babel/types" "^7.6.0"
|
||||
"@babel/types" "^7.6.3"
|
||||
jsesc "^2.5.1"
|
||||
lodash "^4.17.13"
|
||||
source-map "^0.5.0"
|
||||
@ -254,10 +254,10 @@
|
||||
regenerator-runtime "^0.13.3"
|
||||
v8flags "^3.1.1"
|
||||
|
||||
"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.4.3", "@babel/parser@^7.6.0", "@babel/parser@^7.6.2":
|
||||
version "7.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.6.2.tgz#205e9c95e16ba3b8b96090677a67c9d6075b70a1"
|
||||
integrity sha512-mdFqWrSPCmikBoaBYMuBulzTIKuXVPtEISFbRRVNwMWpCms/hmE2kRq0bblUHaNRKrjRlmVbx1sDHmjmRgD2Xg==
|
||||
"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.4.3", "@babel/parser@^7.6.0", "@babel/parser@^7.6.3", "@babel/parser@^7.6.4":
|
||||
version "7.6.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.6.4.tgz#cb9b36a7482110282d5cb6dd424ec9262b473d81"
|
||||
integrity sha512-D8RHPW5qd0Vbyo3qb+YjO5nvUVRTXFLQ/FsDxJU2Nqz4uB5EnUN0ZQSEYpvTIbRuttig1XbHWU5oMeQwQSAA+A==
|
||||
|
||||
"@babel/plugin-proposal-async-generator-functions@^7.2.0":
|
||||
version "7.2.0"
|
||||
@ -696,17 +696,17 @@
|
||||
"@babel/parser" "^7.6.0"
|
||||
"@babel/types" "^7.6.0"
|
||||
|
||||
"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.4.4", "@babel/traverse@^7.5.5", "@babel/traverse@^7.6.2":
|
||||
version "7.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.6.2.tgz#b0e2bfd401d339ce0e6c05690206d1e11502ce2c"
|
||||
integrity sha512-8fRE76xNwNttVEF2TwxJDGBLWthUkHWSldmfuBzVRmEDWOtu4XdINTgN7TDWzuLg4bbeIMLvfMFD9we5YcWkRQ==
|
||||
"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.4.4", "@babel/traverse@^7.5.5", "@babel/traverse@^7.6.2", "@babel/traverse@^7.6.3":
|
||||
version "7.6.3"
|
||||
resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.6.3.tgz#66d7dba146b086703c0fb10dd588b7364cec47f9"
|
||||
integrity sha512-unn7P4LGsijIxaAJo/wpoU11zN+2IaClkQAxcJWBNCMS6cmVh802IyLHNkAjQ0iYnRS3nnxk5O3fuXW28IMxTw==
|
||||
dependencies:
|
||||
"@babel/code-frame" "^7.5.5"
|
||||
"@babel/generator" "^7.6.2"
|
||||
"@babel/generator" "^7.6.3"
|
||||
"@babel/helper-function-name" "^7.1.0"
|
||||
"@babel/helper-split-export-declaration" "^7.4.4"
|
||||
"@babel/parser" "^7.6.2"
|
||||
"@babel/types" "^7.6.0"
|
||||
"@babel/parser" "^7.6.3"
|
||||
"@babel/types" "^7.6.3"
|
||||
debug "^4.1.0"
|
||||
globals "^11.1.0"
|
||||
lodash "^4.17.13"
|
||||
@ -1042,60 +1042,60 @@
|
||||
resolved "https://registry.yarnpkg.com/@protobufjs/utf8/-/utf8-1.1.0.tgz#a777360b5b39a1a2e5106f8e858f2fd2d060c570"
|
||||
integrity sha1-p3c2C1s5oaLlEG+OhY8v0tBgxXA=
|
||||
|
||||
"@sentry/core@5.6.2":
|
||||
version "5.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-5.6.2.tgz#8c5477654a83ebe41a72e86a79215deb5025e418"
|
||||
integrity sha512-grbjvNmyxP5WSPR6UobN2q+Nss7Hvz+BClBT8QTr7VTEG5q89TwNddn6Ej3bGkaUVbct/GpVlI3XflWYDsnU6Q==
|
||||
"@sentry/core@5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-5.7.0.tgz#c2aa5341e703ec7cf2acc69e51971a0b1f7d102a"
|
||||
integrity sha512-gQel0d7LBSWJGHc7gfZllYAu+RRGD9GcYGmkRfemurmDyDGQDf/sfjiBi8f9QxUc2iFTHnvIR5nMTyf0U3yl3Q==
|
||||
dependencies:
|
||||
"@sentry/hub" "5.6.1"
|
||||
"@sentry/minimal" "5.6.1"
|
||||
"@sentry/types" "5.6.1"
|
||||
"@sentry/utils" "5.6.1"
|
||||
"@sentry/hub" "5.7.0"
|
||||
"@sentry/minimal" "5.7.0"
|
||||
"@sentry/types" "5.7.0"
|
||||
"@sentry/utils" "5.7.0"
|
||||
tslib "^1.9.3"
|
||||
|
||||
"@sentry/hub@5.6.1":
|
||||
version "5.6.1"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-5.6.1.tgz#9f355c0abcc92327fbd10b9b939608aa4967bece"
|
||||
integrity sha512-m+OhkIV5yTAL3R1+XfCwzUQka0UF/xG4py8sEfPXyYIcoOJ2ZTX+1kQJLy8QQJ4RzOBwZA+DzRKP0cgzPJ3+oQ==
|
||||
"@sentry/hub@5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-5.7.0.tgz#f7c356202a9db1daae82ce7f48ebf1139e4e9d02"
|
||||
integrity sha512-qNdYheJ6j4P9Sk0eqIINpJohImmu/+trCwFb4F8BGLQth5iGMVQD6D0YUrgjf4ZaQwfhw9tv4W6VEfF5tyASoA==
|
||||
dependencies:
|
||||
"@sentry/types" "5.6.1"
|
||||
"@sentry/utils" "5.6.1"
|
||||
"@sentry/types" "5.7.0"
|
||||
"@sentry/utils" "5.7.0"
|
||||
tslib "^1.9.3"
|
||||
|
||||
"@sentry/minimal@5.6.1":
|
||||
version "5.6.1"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-5.6.1.tgz#09d92b26de0b24555cd50c3c33ba4c3e566009a1"
|
||||
integrity sha512-ercCKuBWHog6aS6SsJRuKhJwNdJ2oRQVWT2UAx1zqvsbHT9mSa8ZRjdPHYOtqY3DoXKk/pLUFW/fkmAnpdMqRw==
|
||||
"@sentry/minimal@5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-5.7.0.tgz#832d26bcd862c6ea628d48ad199ac7f966a2d907"
|
||||
integrity sha512-0sizE2prS9nmfLyVUKmVzFFFqRNr9iorSCCejwnlRe3crqKqjf84tuRSzm6NkZjIyYj9djuuo9l9XN12NLQ/4A==
|
||||
dependencies:
|
||||
"@sentry/hub" "5.6.1"
|
||||
"@sentry/types" "5.6.1"
|
||||
"@sentry/hub" "5.7.0"
|
||||
"@sentry/types" "5.7.0"
|
||||
tslib "^1.9.3"
|
||||
|
||||
"@sentry/node@^5.6.2":
|
||||
version "5.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/node/-/node-5.6.2.tgz#4b62f056031da65cad78220d48c546b8bfbfaed7"
|
||||
integrity sha512-A9CELco6SjF4zt8iS1pO3KdUVI2WVhtTGhSH6X04OVf2en1fimPR+Vs8YVY/04udwd7o+3mI6byT+rS9+/Qzow==
|
||||
"@sentry/node@^5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/node/-/node-5.7.0.tgz#153777f06b2fcd346edbff9adbb6b231c7e5fa0a"
|
||||
integrity sha512-iqQbGAJDBlpQkp1rl9RkDCIfnukr4cOtHPgJPmLY19m/KXIHD2cdKhvbqoCvIPBTIAeSGQIvDT9jD5zT46eoqQ==
|
||||
dependencies:
|
||||
"@sentry/core" "5.6.2"
|
||||
"@sentry/hub" "5.6.1"
|
||||
"@sentry/types" "5.6.1"
|
||||
"@sentry/utils" "5.6.1"
|
||||
cookie "0.3.1"
|
||||
https-proxy-agent "2.2.1"
|
||||
lru_map "0.3.3"
|
||||
"@sentry/core" "5.7.0"
|
||||
"@sentry/hub" "5.7.0"
|
||||
"@sentry/types" "5.7.0"
|
||||
"@sentry/utils" "5.7.0"
|
||||
cookie "^0.3.1"
|
||||
https-proxy-agent "^3.0.0"
|
||||
lru_map "^0.3.3"
|
||||
tslib "^1.9.3"
|
||||
|
||||
"@sentry/types@5.6.1":
|
||||
version "5.6.1"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-5.6.1.tgz#5915e1ee4b7a678da3ac260c356b1cb91139a299"
|
||||
integrity sha512-Kub8TETefHpdhvtnDj3kKfhCj0u/xn3Zi2zIC7PB11NJHvvPXENx97tciz4roJGp7cLRCJsFqCg4tHXniqDSnQ==
|
||||
"@sentry/types@5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-5.7.0.tgz#e8677e57b40c2c63cad42c02add12b238e647c10"
|
||||
integrity sha512-bFRVortg713dE2yJXNFgNe6sNBVVSkpoELLkGPatdVQi0dYc6OggIIX4UZZvkynFx72GwYqO1NOrtUcJY2gmMg==
|
||||
|
||||
"@sentry/utils@5.6.1":
|
||||
version "5.6.1"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-5.6.1.tgz#69d9e151e50415bc91f2428e3bcca8beb9bc2815"
|
||||
integrity sha512-rfgha+UsHW816GqlSRPlniKqAZylOmQWML2JsujoUP03nPu80zdN43DK9Poy/d9OxBxv0gd5K2n+bFdM2kqLQQ==
|
||||
"@sentry/utils@5.7.0":
|
||||
version "5.7.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-5.7.0.tgz#a6850aa4f5476fa26517cd5c6248f871d8d9939b"
|
||||
integrity sha512-XmwQpLqea9mj8x1N7P/l4JvnEb0Rn5Py5OtBgl0ctk090W+GB1uM8rl9mkMf6698o1s1Z8T/tI/QY0yFA5uZXg==
|
||||
dependencies:
|
||||
"@sentry/types" "5.6.1"
|
||||
"@sentry/types" "5.7.0"
|
||||
tslib "^1.9.3"
|
||||
|
||||
"@sindresorhus/is@^0.14.0":
|
||||
@ -1444,7 +1444,7 @@ acorn@^7.0.0:
|
||||
resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.0.0.tgz#26b8d1cd9a9b700350b71c0905546f64d1284e7a"
|
||||
integrity sha512-PaF/MduxijYYt7unVGRuds1vBC9bFxbNf+VWqhOClfdgy7RlVkQqt610ig1/yxTgsDIfW1cWDel5EBbOy3jdtQ==
|
||||
|
||||
agent-base@^4.1.0:
|
||||
agent-base@^4.3.0:
|
||||
version "4.3.0"
|
||||
resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.3.0.tgz#8165f01c436009bccad0b1d122f05ed770efc6ee"
|
||||
integrity sha512-salcGninV0nPrwpGNn4VTXBb1SOuXQBiqbrNXoeizJsHrsL6ERFM2Ne3JUSBWRE6aeNJI2ROP/WEEIDUiDe3cg==
|
||||
@ -1523,13 +1523,13 @@ anymatch@^2.0.0:
|
||||
micromatch "^3.1.4"
|
||||
normalize-path "^2.1.1"
|
||||
|
||||
apollo-cache-control@^0.8.4:
|
||||
version "0.8.4"
|
||||
resolved "https://registry.yarnpkg.com/apollo-cache-control/-/apollo-cache-control-0.8.4.tgz#a3650d5e4173953e2a3af995bea62147f1ffe4d7"
|
||||
integrity sha512-IZ1d3AXZtkZhLYo0kWqTbZ6nqLFaeUvLdMESs+9orMadBZ7mvzcAfBwrhKyCWPGeAAZ/jKv8FtYHybpchHgFAg==
|
||||
apollo-cache-control@^0.8.5:
|
||||
version "0.8.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-cache-control/-/apollo-cache-control-0.8.5.tgz#d4b34691f6ca1cefac9d82b99a94a0815a85a5a8"
|
||||
integrity sha512-2yQ1vKgJQ54SGkoQS/ZLZrDX3La6cluAYYdruFYJMJtL4zQrSdeOCy11CQliCMYEd6eKNyE70Rpln51QswW2Og==
|
||||
dependencies:
|
||||
apollo-server-env "^2.4.3"
|
||||
graphql-extensions "^0.10.3"
|
||||
graphql-extensions "^0.10.4"
|
||||
|
||||
apollo-cache-inmemory@~1.6.3:
|
||||
version "1.6.3"
|
||||
@ -1572,27 +1572,27 @@ apollo-datasource@^0.6.3:
|
||||
apollo-server-caching "^0.5.0"
|
||||
apollo-server-env "^2.4.3"
|
||||
|
||||
apollo-engine-reporting-protobuf@^0.4.0:
|
||||
version "0.4.0"
|
||||
resolved "https://registry.yarnpkg.com/apollo-engine-reporting-protobuf/-/apollo-engine-reporting-protobuf-0.4.0.tgz#e34c192d86493b33a73181fd6be75721559111ec"
|
||||
integrity sha512-cXHZSienkis8v4RhqB3YG3DkaksqLpcxApRLTpRMs7IXNozgV7CUPYGFyFBEra1ZFgUyHXx4G9MpelV+n2cCfA==
|
||||
apollo-engine-reporting-protobuf@^0.4.1:
|
||||
version "0.4.1"
|
||||
resolved "https://registry.yarnpkg.com/apollo-engine-reporting-protobuf/-/apollo-engine-reporting-protobuf-0.4.1.tgz#c0a35bcf28487f87dcbc452b03277f575192f5d2"
|
||||
integrity sha512-d7vFFZ2oUrvGaN0Hpet8joe2ZG0X0lIGilN+SwgVP38dJnOuadjsaYMyrD9JudGQJg0bJA5wVQfYzcCVy0slrw==
|
||||
dependencies:
|
||||
protobufjs "^6.8.6"
|
||||
|
||||
apollo-engine-reporting@^1.4.6:
|
||||
version "1.4.6"
|
||||
resolved "https://registry.yarnpkg.com/apollo-engine-reporting/-/apollo-engine-reporting-1.4.6.tgz#83af6689c4ab82d1c62c3f5dde7651975508114f"
|
||||
integrity sha512-acfb7oFnru/8YQdY4x6+7WJbZfzdVETI8Cl+9ImgUrvUnE8P+f2SsGTKXTC1RuUvve4c56PAvaPgE+z8X1a1Mw==
|
||||
apollo-engine-reporting@^1.4.7:
|
||||
version "1.4.7"
|
||||
resolved "https://registry.yarnpkg.com/apollo-engine-reporting/-/apollo-engine-reporting-1.4.7.tgz#6ca69ebdc1c17200969e2e4e07a0be64d748c27e"
|
||||
integrity sha512-qsKDz9VkoctFhojM3Nj3nvRBO98t8TS2uTgtiIjUGs3Hln2poKMP6fIQ37Nm2Q2B3JJst76HQtpPwXmRJd1ZUg==
|
||||
dependencies:
|
||||
apollo-engine-reporting-protobuf "^0.4.0"
|
||||
apollo-graphql "^0.3.3"
|
||||
apollo-engine-reporting-protobuf "^0.4.1"
|
||||
apollo-graphql "^0.3.4"
|
||||
apollo-server-caching "^0.5.0"
|
||||
apollo-server-env "^2.4.3"
|
||||
apollo-server-types "^0.2.4"
|
||||
apollo-server-types "^0.2.5"
|
||||
async-retry "^1.2.1"
|
||||
graphql-extensions "^0.10.3"
|
||||
graphql-extensions "^0.10.4"
|
||||
|
||||
apollo-env@0.5.1:
|
||||
apollo-env@0.5.1, apollo-env@^0.5.1:
|
||||
version "0.5.1"
|
||||
resolved "https://registry.yarnpkg.com/apollo-env/-/apollo-env-0.5.1.tgz#b9b0195c16feadf0fe9fd5563edb0b9b7d9e97d3"
|
||||
integrity sha512-fndST2xojgSdH02k5hxk1cbqA9Ti8RX4YzzBoAB4oIe1Puhq7+YlhXGXfXB5Y4XN0al8dLg+5nAkyjNAR2qZTw==
|
||||
@ -1609,12 +1609,12 @@ apollo-errors@^1.9.0:
|
||||
assert "^1.4.1"
|
||||
extendable-error "^0.1.5"
|
||||
|
||||
apollo-graphql@^0.3.3:
|
||||
version "0.3.3"
|
||||
resolved "https://registry.yarnpkg.com/apollo-graphql/-/apollo-graphql-0.3.3.tgz#ce1df194f6e547ad3ce1e35b42f9c211766e1658"
|
||||
integrity sha512-t3CO/xIDVsCG2qOvx2MEbuu4b/6LzQjcBBwiVnxclmmFyAxYCIe7rpPlnLHSq7HyOMlCWDMozjoeWfdqYSaLqQ==
|
||||
apollo-graphql@^0.3.4:
|
||||
version "0.3.4"
|
||||
resolved "https://registry.yarnpkg.com/apollo-graphql/-/apollo-graphql-0.3.4.tgz#c1f68591a4775945441d049eff9323542ab0401f"
|
||||
integrity sha512-w+Az1qxePH4oQ8jvbhQBl5iEVvqcqynmU++x/M7MM5xqN1C7m1kyIzpN17gybXlTJXY4Oxej2WNURC2/hwpfYw==
|
||||
dependencies:
|
||||
apollo-env "0.5.1"
|
||||
apollo-env "^0.5.1"
|
||||
lodash.sortby "^4.7.0"
|
||||
|
||||
apollo-link-context@~1.0.19:
|
||||
@ -1660,26 +1660,26 @@ apollo-server-caching@^0.5.0:
|
||||
dependencies:
|
||||
lru-cache "^5.0.0"
|
||||
|
||||
apollo-server-core@^2.9.5:
|
||||
version "2.9.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-2.9.5.tgz#b2d9188d7acce5fe92a5460d276794988ffa6737"
|
||||
integrity sha512-SlM/vhjhWb0ayXV3d4gnpq9gh2BsQj+UPfQXfq2X2KG9EH5I1JUH6EtlsctgMCZozirOZmEmUzlqZWSSUOUPgQ==
|
||||
apollo-server-core@^2.9.6:
|
||||
version "2.9.6"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-2.9.6.tgz#b6dc087200633f47ca4f08244d3e606b4d616320"
|
||||
integrity sha512-2tHAWQxP7HrETI/BZvg2fem6YlahF9HUp4Y6SSL95WP3uNMOJBlN12yM1y+O2u5K5e4jwdPNaLjoL2A/26XrLw==
|
||||
dependencies:
|
||||
"@apollographql/apollo-tools" "^0.4.0"
|
||||
"@apollographql/graphql-playground-html" "1.6.24"
|
||||
"@types/graphql-upload" "^8.0.0"
|
||||
"@types/ws" "^6.0.0"
|
||||
apollo-cache-control "^0.8.4"
|
||||
apollo-cache-control "^0.8.5"
|
||||
apollo-datasource "^0.6.3"
|
||||
apollo-engine-reporting "^1.4.6"
|
||||
apollo-engine-reporting "^1.4.7"
|
||||
apollo-server-caching "^0.5.0"
|
||||
apollo-server-env "^2.4.3"
|
||||
apollo-server-errors "^2.3.3"
|
||||
apollo-server-plugin-base "^0.6.4"
|
||||
apollo-server-types "^0.2.4"
|
||||
apollo-tracing "^0.8.4"
|
||||
apollo-server-plugin-base "^0.6.5"
|
||||
apollo-server-types "^0.2.5"
|
||||
apollo-tracing "^0.8.5"
|
||||
fast-json-stable-stringify "^2.0.0"
|
||||
graphql-extensions "^0.10.3"
|
||||
graphql-extensions "^0.10.4"
|
||||
graphql-tag "^2.9.2"
|
||||
graphql-tools "^4.0.0"
|
||||
graphql-upload "^8.0.2"
|
||||
@ -1700,10 +1700,10 @@ apollo-server-errors@^2.3.3:
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-errors/-/apollo-server-errors-2.3.3.tgz#83763b00352c10dc68fbb0d41744ade66de549ff"
|
||||
integrity sha512-MO4oJ129vuCcbqwr5ZwgxqGGiLz3hCyowz0bstUF7MR+vNGe4oe3DWajC9lv4CxrhcqUHQOeOPViOdIo1IxE3g==
|
||||
|
||||
apollo-server-express@^2.9.4, apollo-server-express@^2.9.5:
|
||||
version "2.9.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-express/-/apollo-server-express-2.9.5.tgz#383e0a5cb80cf1172b0bc1e565797edd629d750a"
|
||||
integrity sha512-6gonP7g5u2Kr+9cvKE+NuGPe+As7wRbz2yWoyLOym/TdXBmTRU4AKW2Qs+wpNanurzm2xbTa7sEfzrHGmembrQ==
|
||||
apollo-server-express@^2.9.6:
|
||||
version "2.9.6"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-express/-/apollo-server-express-2.9.6.tgz#eec2ec43b829b059278e14994d06bd23e43266f9"
|
||||
integrity sha512-j80azBeXvLvyZsbqCnus7GH+w8vk+2IOnYzROZu/f0D2roDZtsu1XZkn+aplDJZXMcEXtqB6t4qNpyvV4zY0XQ==
|
||||
dependencies:
|
||||
"@apollographql/graphql-playground-html" "1.6.24"
|
||||
"@types/accepts" "^1.3.5"
|
||||
@ -1711,8 +1711,8 @@ apollo-server-express@^2.9.4, apollo-server-express@^2.9.5:
|
||||
"@types/cors" "^2.8.4"
|
||||
"@types/express" "4.17.1"
|
||||
accepts "^1.3.5"
|
||||
apollo-server-core "^2.9.5"
|
||||
apollo-server-types "^0.2.4"
|
||||
apollo-server-core "^2.9.6"
|
||||
apollo-server-types "^0.2.5"
|
||||
body-parser "^1.18.3"
|
||||
cors "^2.8.4"
|
||||
express "^4.17.1"
|
||||
@ -1722,47 +1722,47 @@ apollo-server-express@^2.9.4, apollo-server-express@^2.9.5:
|
||||
subscriptions-transport-ws "^0.9.16"
|
||||
type-is "^1.6.16"
|
||||
|
||||
apollo-server-plugin-base@^0.6.4:
|
||||
version "0.6.4"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-0.6.4.tgz#63ea4fd0bbb6c4510bc8d0d2ad0a0684c8d0da8c"
|
||||
integrity sha512-4rY+cBAIpQomGWYBtk8hHkLQWHrh5hgIBPQqmhXh00YFdcY+Ob1/cU2/2iqTcIzhtcaezsc8OZ63au6ahSBQqg==
|
||||
apollo-server-plugin-base@^0.6.5:
|
||||
version "0.6.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-0.6.5.tgz#eebe27734c51bf6a45b6a9ec8738750b132ffde7"
|
||||
integrity sha512-z2ve7HEPWmZI3EzL0iiY9qyt1i0hitT+afN5PzssCw594LB6DfUQWsI14UW+W+gcw8hvl8VQUpXByfUntAx5vw==
|
||||
dependencies:
|
||||
apollo-server-types "^0.2.4"
|
||||
apollo-server-types "^0.2.5"
|
||||
|
||||
apollo-server-testing@~2.9.5:
|
||||
version "2.9.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-testing/-/apollo-server-testing-2.9.5.tgz#ff5bbe3fefdf4d639bb138277d3dfc846b309438"
|
||||
integrity sha512-IoElvnJ0Zex6i1QZj9v0szbDvCM6LF1gSZlQswRuIeTwvvquzixFVGMpLZKItojmjrCSxsT7DHJxeUFugZJUWA==
|
||||
apollo-server-testing@~2.9.6:
|
||||
version "2.9.6"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-testing/-/apollo-server-testing-2.9.6.tgz#1cae51c93a8865b85e877e2c9927964cf32625e6"
|
||||
integrity sha512-pbURQD5VjNFk4GMVVxyCds9rY4/NIqjvjE4tyf1k89RHwMdk+zuVggt/DGudteorZtqAqtsOIHWojMBU4s2klA==
|
||||
dependencies:
|
||||
apollo-server-core "^2.9.5"
|
||||
apollo-server-core "^2.9.6"
|
||||
|
||||
apollo-server-types@^0.2.4:
|
||||
version "0.2.4"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-types/-/apollo-server-types-0.2.4.tgz#28864900ffc7f9711a859297c143a833fdb6aa43"
|
||||
integrity sha512-G4FvBVgGQcTW6ZBS2+hvcDQkSfdOIKV+cHADduXA275v+5zl42g+bCaGd/hCCKTDRjmQvObLiMxH/BJ6pDMQgA==
|
||||
apollo-server-types@^0.2.5:
|
||||
version "0.2.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server-types/-/apollo-server-types-0.2.5.tgz#2d63924706ffc1a59480cbbc93e9fe86655a57a5"
|
||||
integrity sha512-6iJQsPh59FWu4K7ABrVmpnQVgeK8Ockx8BcawBh+saFYWTlVczwcLyGSZPeV1tPSKwFwKZutyEslrYSafcarXQ==
|
||||
dependencies:
|
||||
apollo-engine-reporting-protobuf "^0.4.0"
|
||||
apollo-engine-reporting-protobuf "^0.4.1"
|
||||
apollo-server-caching "^0.5.0"
|
||||
apollo-server-env "^2.4.3"
|
||||
|
||||
apollo-server@~2.9.5:
|
||||
version "2.9.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server/-/apollo-server-2.9.5.tgz#4f616337d04f2f0886d4bbe46b047a32a649b1fd"
|
||||
integrity sha512-hbWZAZ3g186NG9U9bVmMpPcbUJ+/f/CSL+/tJsK6iQPp5L3hcVYoe+/qDw3zpfDMA5R2Jq/yHZtF2LcI5ylVnQ==
|
||||
apollo-server@~2.9.6:
|
||||
version "2.9.6"
|
||||
resolved "https://registry.yarnpkg.com/apollo-server/-/apollo-server-2.9.6.tgz#11b6f1128ddb674d2651bb289e0c0fc28aa18653"
|
||||
integrity sha512-sDvrGpMQsTGQ9FTkFm3xracrSUi8nFoh3svlD98pe6qb75UDDrXAZgxwQCSOwZ3BkaJ7UkdndfhnruhFstTeMw==
|
||||
dependencies:
|
||||
apollo-server-core "^2.9.5"
|
||||
apollo-server-express "^2.9.5"
|
||||
apollo-server-core "^2.9.6"
|
||||
apollo-server-express "^2.9.6"
|
||||
express "^4.0.0"
|
||||
graphql-subscriptions "^1.0.0"
|
||||
graphql-tools "^4.0.0"
|
||||
|
||||
apollo-tracing@^0.8.4:
|
||||
version "0.8.4"
|
||||
resolved "https://registry.yarnpkg.com/apollo-tracing/-/apollo-tracing-0.8.4.tgz#0117820c3f0ad3aa6daf7bf13ddbb923cbefa6de"
|
||||
integrity sha512-DjbFW0IvHicSlTVG+vK+1WINfBMRCdPPHJSW/j65JMir9Oe56WGeqL8qz8hptdUUmLYEb+azvcyyGsJsiR3zpQ==
|
||||
apollo-tracing@^0.8.5:
|
||||
version "0.8.5"
|
||||
resolved "https://registry.yarnpkg.com/apollo-tracing/-/apollo-tracing-0.8.5.tgz#f07c4584d95bcf750e44bfe9845e073b03774941"
|
||||
integrity sha512-lZn10/GRBZUlMxVYLghLMFsGcLN0jTYDd98qZfBtxw+wEWUx+PKkZdljDT+XNoOm/kDvEutFGmi5tSLhArIzWQ==
|
||||
dependencies:
|
||||
apollo-server-env "^2.4.3"
|
||||
graphql-extensions "^0.10.3"
|
||||
graphql-extensions "^0.10.4"
|
||||
|
||||
apollo-utilities@1.3.2, apollo-utilities@^1.0.1, apollo-utilities@^1.3.0, apollo-utilities@^1.3.2:
|
||||
version "1.3.2"
|
||||
@ -2565,16 +2565,16 @@ cookie-signature@1.0.6:
|
||||
resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c"
|
||||
integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw=
|
||||
|
||||
cookie@0.3.1:
|
||||
version "0.3.1"
|
||||
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.3.1.tgz#e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb"
|
||||
integrity sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s=
|
||||
|
||||
cookie@0.4.0:
|
||||
version "0.4.0"
|
||||
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.0.tgz#beb437e7022b3b6d49019d088665303ebe9c14ba"
|
||||
integrity sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==
|
||||
|
||||
cookie@^0.3.1:
|
||||
version "0.3.1"
|
||||
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.3.1.tgz#e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb"
|
||||
integrity sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s=
|
||||
|
||||
cookiejar@^2.1.0:
|
||||
version "2.1.2"
|
||||
resolved "https://registry.yarnpkg.com/cookiejar/-/cookiejar-2.1.2.tgz#dd8a235530752f988f9a0844f3fc589e3111125c"
|
||||
@ -3259,10 +3259,10 @@ eslint-plugin-import@~2.18.2:
|
||||
read-pkg-up "^2.0.0"
|
||||
resolve "^1.11.0"
|
||||
|
||||
eslint-plugin-jest@~22.17.0:
|
||||
version "22.17.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-22.17.0.tgz#dc170ec8369cd1bff9c5dd8589344e3f73c88cf6"
|
||||
integrity sha512-WT4DP4RoGBhIQjv+5D0FM20fAdAUstfYAf/mkufLNTojsfgzc5/IYW22cIg/Q4QBavAZsROQlqppiWDpFZDS8Q==
|
||||
eslint-plugin-jest@~22.19.0:
|
||||
version "22.19.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-22.19.0.tgz#0cf90946a8c927d40a2c64458c89bb635d0f2a0b"
|
||||
integrity sha512-4zUc3rh36ds0SXdl2LywT4YWA3zRe8sfLhz8bPp8qQPIKvynTTkNGwmSCMpl5d9QiZE2JxSinGF+WD8yU+O0Lg==
|
||||
dependencies:
|
||||
"@typescript-eslint/experimental-utils" "^1.13.0"
|
||||
|
||||
@ -3988,14 +3988,14 @@ graphql-custom-directives@~0.2.14:
|
||||
moment "^2.22.2"
|
||||
numeral "^2.0.6"
|
||||
|
||||
graphql-extensions@^0.10.3:
|
||||
version "0.10.3"
|
||||
resolved "https://registry.yarnpkg.com/graphql-extensions/-/graphql-extensions-0.10.3.tgz#9e37f3bd26309c40b03a0be0e63e02b3f99d52ea"
|
||||
integrity sha512-kwU0gUe+Qdfr8iZYT91qrPSwQNgPhB/ClF1m1LEPdxlptk5FhFmjpxAcbMZ8q7j0kjfnbp2IeV1OhRDCEPqz2w==
|
||||
graphql-extensions@^0.10.4:
|
||||
version "0.10.4"
|
||||
resolved "https://registry.yarnpkg.com/graphql-extensions/-/graphql-extensions-0.10.4.tgz#af851b0d44ea6838cf54de9df3cfc6a8e575e571"
|
||||
integrity sha512-lE6MroluEYocbR/ICwccv39w+Pz4cBPadJ11z1rJkbZv5wstISEganbDOwl9qN21rcZGiWzh7QUNxUiFUXXEDw==
|
||||
dependencies:
|
||||
"@apollographql/apollo-tools" "^0.4.0"
|
||||
apollo-server-env "^2.4.3"
|
||||
apollo-server-types "^0.2.4"
|
||||
apollo-server-types "^0.2.5"
|
||||
|
||||
graphql-import@0.7.1:
|
||||
version "0.7.1"
|
||||
@ -4332,12 +4332,12 @@ http-signature@~1.2.0:
|
||||
jsprim "^1.2.2"
|
||||
sshpk "^1.7.0"
|
||||
|
||||
https-proxy-agent@2.2.1:
|
||||
version "2.2.1"
|
||||
resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.2.1.tgz#51552970fa04d723e04c56d04178c3f92592bbc0"
|
||||
integrity sha512-HPCTS1LW51bcyMYbxUIOO4HEOlQ1/1qRaFWcyxvwaqUS9TY88aoEuHUY33kuAh1YhVVaDQhLZsnPd+XNARWZlQ==
|
||||
https-proxy-agent@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-3.0.0.tgz#0106efa5d63d6d6f3ab87c999fa4877a3fd1ff97"
|
||||
integrity sha512-y4jAxNEihqvBI5F3SaO2rtsjIOnnNA8sEbuiP+UhJZJHeM2NRm6c09ax2tgqme+SgUUvjao2fJXF4h3D6Cb2HQ==
|
||||
dependencies:
|
||||
agent-base "^4.1.0"
|
||||
agent-base "^4.3.0"
|
||||
debug "^3.1.0"
|
||||
|
||||
iconv-lite@0.4.24, iconv-lite@^0.4.24, iconv-lite@^0.4.4:
|
||||
@ -5641,7 +5641,7 @@ lru-cache@^5.0.0:
|
||||
dependencies:
|
||||
yallist "^3.0.2"
|
||||
|
||||
lru_map@0.3.3:
|
||||
lru_map@^0.3.3:
|
||||
version "0.3.3"
|
||||
resolved "https://registry.yarnpkg.com/lru_map/-/lru_map-0.3.3.tgz#b5c8351b9464cbd750335a79650a0ec0e56118dd"
|
||||
integrity sha1-tcg1G5Rky9dQM1p5ZQoOwOVhGN0=
|
||||
|
||||
@ -26,6 +26,7 @@
|
||||
"cypress-cucumber-preprocessor": "^1.16.2",
|
||||
"cypress-file-upload": "^3.3.4",
|
||||
"cypress-plugin-retries": "^1.3.0",
|
||||
"date-fns": "^2.4.1",
|
||||
"dotenv": "^8.1.0",
|
||||
"faker": "Marak/faker.js#master",
|
||||
"graphql-request": "^1.8.2",
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
FROM node:12.11.1-alpine as base
|
||||
FROM node:12.12.0-alpine as base
|
||||
LABEL Description="Web Frontend of the Social Network Human-Connection.org" Vendor="Human-Connection gGmbH" Version="0.0.1" Maintainer="Human-Connection gGmbH (developer@human-connection.org)"
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
FROM node:12.11.1-alpine as build
|
||||
FROM node:12.12.0-alpine as build
|
||||
LABEL Description="Web Frontend of the Social Network Human-Connection.org" Vendor="Human-Connection gGmbH" Version="0.0.1" Maintainer="Human-Connection gGmbH (developer@human-connection.org)"
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
@ -262,7 +262,7 @@ export default {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
<style lang="scss" scoped>
|
||||
.smallTag {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
|
||||
@ -36,6 +36,7 @@
|
||||
import Dropdown from '~/components/Dropdown'
|
||||
import find from 'lodash/find'
|
||||
import orderBy from 'lodash/orderBy'
|
||||
import locales from '~/locales'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
@ -47,7 +48,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
locales: orderBy(process.env.locales, 'name'),
|
||||
locales: orderBy(locales, 'name'),
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
||||
@ -131,10 +131,11 @@ export default {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
<style lang="scss" scoped>
|
||||
.ds-card-image img {
|
||||
width: 100%;
|
||||
max-height: 300px;
|
||||
max-height: 2000px;
|
||||
object-fit: contain;
|
||||
-o-object-fit: cover;
|
||||
object-fit: cover;
|
||||
-o-object-position: center;
|
||||
|
||||
@ -61,7 +61,9 @@ describe('CreateUserAccount', () => {
|
||||
wrapper.find('input#password').setValue('hellopassword')
|
||||
wrapper.find('textarea#about').setValue('Hello I am the `about` attribute')
|
||||
wrapper.find('input#passwordConfirmation').setValue('hellopassword')
|
||||
wrapper.find('input#checkbox').setChecked()
|
||||
wrapper.find('input#checkbox0').setChecked()
|
||||
wrapper.find('input#checkbox1').setChecked()
|
||||
wrapper.find('input#checkbox2').setChecked()
|
||||
await wrapper.find('form').trigger('submit')
|
||||
await wrapper.html()
|
||||
}
|
||||
|
||||
@ -64,7 +64,7 @@
|
||||
|
||||
<ds-text>
|
||||
<input
|
||||
id="checkbox"
|
||||
id="checkbox0"
|
||||
type="checkbox"
|
||||
v-model="termsAndConditionsConfirmed"
|
||||
:checked="termsAndConditionsConfirmed"
|
||||
@ -74,12 +74,24 @@
|
||||
v-html="$t('termsAndConditions.termsAndConditionsConfirmed')"
|
||||
></label>
|
||||
</ds-text>
|
||||
<p>
|
||||
<label>
|
||||
<input id="checkbox1" type="checkbox" v-model="dataPrivacy" :checked="dataPrivacy" />
|
||||
<span v-html="$t('components.registration.signup.form.data-privacy')"></span>
|
||||
</label>
|
||||
</p>
|
||||
<p>
|
||||
<label>
|
||||
<input id="checkbox2" type="checkbox" v-model="minimumAge" :checked="minimumAge" />
|
||||
<span v-html="$t('components.registration.signup.form.minimum-age')"></span>
|
||||
</label>
|
||||
</p>
|
||||
<ds-button
|
||||
style="float: right;"
|
||||
icon="check"
|
||||
type="submit"
|
||||
:loading="$apollo.loading"
|
||||
:disabled="errors || !termsAndConditionsConfirmed"
|
||||
:disabled="errors || !termsAndConditionsConfirmed || !dataPrivacy || !minimumAge"
|
||||
primary
|
||||
>
|
||||
{{ $t('actions.save') }}
|
||||
@ -129,6 +141,8 @@ export default {
|
||||
// Integrate termsAndConditionsConfirmed into `this.formData` once we
|
||||
// have checkmarks available.
|
||||
termsAndConditionsConfirmed: false,
|
||||
dataPrivacy: false,
|
||||
minimumAge: false,
|
||||
}
|
||||
},
|
||||
props: {
|
||||
|
||||
@ -3,17 +3,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getDateFnsLocale } from '~/locales'
|
||||
import formatRelative from 'date-fns/formatRelative'
|
||||
import { enUS, de, nl, fr, pt, es } from 'date-fns/locale' // pl currently not working library wise
|
||||
const locales = {
|
||||
en: enUS,
|
||||
de,
|
||||
nl,
|
||||
fr,
|
||||
es,
|
||||
pt,
|
||||
// pl
|
||||
}
|
||||
|
||||
export default {
|
||||
name: 'HcRelativeDateTime',
|
||||
@ -25,8 +16,7 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
relativeDateTime() {
|
||||
let locale = locales[this.$i18n.locale() || 'en']
|
||||
return formatRelative(new Date(this.dateTime), new Date(), { locale })
|
||||
return formatRelative(new Date(this.dateTime), new Date(), { locale: getDateFnsLocale(this) })
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
@ -25,17 +25,6 @@ describe('TeaserImage.vue', () => {
|
||||
wrapper = Wrapper()
|
||||
})
|
||||
|
||||
describe('File upload', () => {
|
||||
const imageUpload = [
|
||||
{ file: { filename: 'avataar.svg', previewElement: '' }, url: 'someUrlToImage' },
|
||||
]
|
||||
|
||||
it('supports adding a teaser image', () => {
|
||||
wrapper.vm.addTeaserImage(imageUpload)
|
||||
expect(wrapper.emitted().addTeaserImage[0]).toEqual(imageUpload)
|
||||
})
|
||||
})
|
||||
|
||||
describe('handles errors', () => {
|
||||
beforeEach(() => jest.useFakeTimers())
|
||||
const message = 'File upload failed'
|
||||
|
||||
@ -5,25 +5,24 @@
|
||||
id="postdropzone"
|
||||
class="ds-card-image"
|
||||
:use-custom-slot="true"
|
||||
@vdropzone-thumbnail="thumbnail"
|
||||
@vdropzone-error="verror"
|
||||
@vdropzone-thumbnail="transformImage"
|
||||
@vdropzone-drop="dropzoneDrop"
|
||||
>
|
||||
<div class="dz-message">
|
||||
<div
|
||||
:class="{
|
||||
'hc-attachments-upload-area-post': true,
|
||||
'hc-attachments-upload-area-update-post': contribution,
|
||||
}"
|
||||
>
|
||||
<slot></slot>
|
||||
<div
|
||||
:class="{
|
||||
'hc-attachments-upload-area-post': true,
|
||||
'hc-attachments-upload-area-update-post': contribution,
|
||||
'hc-drag-marker-post': true,
|
||||
'hc-drag-marker-update-post': contribution,
|
||||
}"
|
||||
>
|
||||
<slot></slot>
|
||||
<div
|
||||
:class="{
|
||||
'hc-drag-marker-post': true,
|
||||
'hc-drag-marker-update-post': contribution,
|
||||
}"
|
||||
>
|
||||
<ds-icon name="image" size="xxx-large" />
|
||||
</div>
|
||||
<ds-icon name="image" size="xxx-large" />
|
||||
</div>
|
||||
</div>
|
||||
</vue-dropzone>
|
||||
@ -31,6 +30,8 @@
|
||||
|
||||
<script>
|
||||
import vueDropzone from 'nuxt-dropzone'
|
||||
import Cropper from 'cropperjs'
|
||||
import 'cropperjs/dist/cropper.css'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
@ -42,7 +43,7 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
dropzoneOptions: {
|
||||
url: this.addTeaserImage,
|
||||
url: () => '',
|
||||
maxFilesize: 5.0,
|
||||
previewTemplate: this.template(),
|
||||
},
|
||||
@ -70,27 +71,50 @@ export default {
|
||||
this.error = true
|
||||
this.$toast.error(file.status, message)
|
||||
},
|
||||
addTeaserImage(file) {
|
||||
this.$emit('addTeaserImage', file[0])
|
||||
return ''
|
||||
transformImage(file) {
|
||||
let thumbnailElement, editor, confirm, thumbnailPreview, contributionImage
|
||||
// Create the image editor overlay
|
||||
editor = document.createElement('div')
|
||||
thumbnailElement = document.querySelectorAll('#postdropzone')[0]
|
||||
thumbnailPreview = document.querySelectorAll('.thumbnail-preview')[0]
|
||||
if (thumbnailPreview) thumbnailPreview.remove()
|
||||
contributionImage = document.querySelectorAll('.contribution-image')[0]
|
||||
if (contributionImage) contributionImage.remove()
|
||||
editor.classList.add('crop-overlay')
|
||||
thumbnailElement.appendChild(editor)
|
||||
// Create the confirm button
|
||||
confirm = document.createElement('button')
|
||||
confirm.classList.add('crop-confirm', 'ds-button', 'ds-button-primary')
|
||||
confirm.textContent = this.$t('contribution.teaserImage.cropperConfirm')
|
||||
confirm.addEventListener('click', () => {
|
||||
// Get the canvas with image data from Cropper.js
|
||||
let canvas = cropper.getCroppedCanvas()
|
||||
canvas.toBlob(blob => {
|
||||
this.$refs.el.manuallyAddFile(blob, canvas.toDataURL(), null, null, {
|
||||
dontSubstractMaxFiles: false,
|
||||
addToFiles: true,
|
||||
})
|
||||
image = new Image()
|
||||
image.src = canvas.toDataURL()
|
||||
image.classList.add('thumbnail-preview')
|
||||
thumbnailElement.appendChild(image)
|
||||
// Remove the editor from view
|
||||
editor.parentNode.removeChild(editor)
|
||||
this.$emit('addTeaserImage', blob)
|
||||
})
|
||||
})
|
||||
editor.appendChild(confirm)
|
||||
|
||||
// Load the image
|
||||
let image = new Image()
|
||||
image.src = URL.createObjectURL(file)
|
||||
editor.appendChild(image)
|
||||
// Create Cropper.js and pass image
|
||||
let cropper = new Cropper(image, { zoomable: false })
|
||||
},
|
||||
thumbnail: (file, dataUrl) => {
|
||||
let thumbnailElement, contributionImage, uploadArea, thumbnailPreview, image
|
||||
if (file.previewElement) {
|
||||
thumbnailElement = document.querySelectorAll('#postdropzone')[0]
|
||||
contributionImage = document.querySelectorAll('.contribution-image')[0]
|
||||
thumbnailPreview = document.querySelectorAll('.thumbnail-preview')[0]
|
||||
if (contributionImage) {
|
||||
uploadArea = document.querySelectorAll('.hc-attachments-upload-area-update-post')[0]
|
||||
uploadArea.removeChild(contributionImage)
|
||||
uploadArea.classList.remove('hc-attachments-upload-area-update-post')
|
||||
}
|
||||
image = new Image()
|
||||
image.src = URL.createObjectURL(file)
|
||||
image.classList.add('thumbnail-preview')
|
||||
if (thumbnailPreview) return thumbnailElement.replaceChild(image, thumbnailPreview)
|
||||
thumbnailElement.appendChild(image)
|
||||
}
|
||||
dropzoneDrop() {
|
||||
let cropOverlay = document.querySelectorAll('.crop-overlay')[0]
|
||||
if (cropOverlay) cropOverlay.remove()
|
||||
},
|
||||
},
|
||||
}
|
||||
@ -98,16 +122,10 @@ export default {
|
||||
<style lang="scss">
|
||||
#postdropzone {
|
||||
width: 100%;
|
||||
min-height: 300px;
|
||||
min-height: 500px;
|
||||
background-color: $background-color-softest;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 960px) {
|
||||
#postdropzone {
|
||||
min-height: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
.hc-attachments-upload-area-post {
|
||||
position: relative;
|
||||
display: flex;
|
||||
@ -134,11 +152,10 @@ export default {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin: 180px 5px;
|
||||
color: hsl(0, 0%, 25%);
|
||||
transition: all 0.2s ease-out;
|
||||
font-size: 60px;
|
||||
margin: 80px 5px;
|
||||
|
||||
background-color: $background-color-softest;
|
||||
opacity: 0.65;
|
||||
|
||||
@ -178,7 +195,17 @@ export default {
|
||||
border-top: $border-size-base solid $border-color-softest;
|
||||
}
|
||||
|
||||
.contribution-image {
|
||||
max-height: 300px;
|
||||
.crop-overlay {
|
||||
max-height: 2000px;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
background-color: #000;
|
||||
}
|
||||
|
||||
.crop-confirm {
|
||||
position: absolute;
|
||||
left: 10px;
|
||||
top: 10px;
|
||||
z-index: 1;
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -30,6 +30,9 @@
|
||||
"title": "Mach mit bei Human Connection!",
|
||||
"form": {
|
||||
"description": "Um loszulegen, gib deine E-Mail Adresse ein:",
|
||||
"terms-and-condition": "Ich stimme den <a href=\"/terms-and-conditions\"><ds-text bold color=\"primary\" > Nutzungsbedingungen</ds-text></a>zu.",
|
||||
"data-privacy": "Ich habe die <a href=\"https://human-connection.org/datenschutz/\" target=\"_blank\"><ds-text bold color=\"primary\" >Datenschutzerklärungen!</ds-text></a> gelesen und verstanden",
|
||||
"minimum-age": "Ich bin 18 Jahre oder älter.",
|
||||
"invitation-code": "Dein Einladungscode lautet: <b>{code}</b>",
|
||||
"errors": {
|
||||
"email-exists": "Es gibt schon ein Benutzerkonto mit dieser E-Mail Adresse!",
|
||||
@ -586,6 +589,9 @@
|
||||
"it-internet-data-privacy": "IT, Internet & Datenschutz",
|
||||
"art-culture-sport": "Kunst, Kultur & Sport"
|
||||
}
|
||||
},
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Bestätigen"
|
||||
}
|
||||
},
|
||||
"code-of-conduct": {
|
||||
|
||||
@ -31,6 +31,9 @@
|
||||
"title": "Join Human Connection!",
|
||||
"form": {
|
||||
"description": "To get started, enter your email address:",
|
||||
"terms-and-condition": "I confirm to the <a href=\"/terms-and-conditions\"><ds-text bold color=\"primary\" > Terms and conditions</ds-text></a>.",
|
||||
"data-privacy": " I have read and understood the <a href=\"https://human-connection.org/datenschutz/\" target=\"_blank\"><ds-text bold color=\"primary\" >Privacy Statement</ds-text></a> ",
|
||||
"minimum-age": "I'm 18 years or older.",
|
||||
"invitation-code": "Your invitation code is: <b>{code}</b>",
|
||||
"errors": {
|
||||
"email-exists": "There is already a user account with this email address!",
|
||||
@ -587,6 +590,9 @@
|
||||
"it-internet-data-privacy": "IT, Internet & Data Privacy",
|
||||
"art-culture-sport": "Art, Culture, & Sport"
|
||||
}
|
||||
},
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Confirm"
|
||||
}
|
||||
},
|
||||
"code-of-conduct": {
|
||||
|
||||
@ -292,6 +292,11 @@
|
||||
"message": "¿Realmente quieres liberar el comentario de \"<b>{name}</b>\"?"
|
||||
}
|
||||
},
|
||||
"contribution": {
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Confirmar"
|
||||
}
|
||||
},
|
||||
"user": {
|
||||
"avatar": {
|
||||
"submitted": "Carga con éxito"
|
||||
|
||||
@ -287,6 +287,11 @@
|
||||
"message": "Voulez-vous vraiment publier le commentaire de \"<b>{name}</b>\"?"
|
||||
}
|
||||
},
|
||||
"contribution": {
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Confirmer"
|
||||
}
|
||||
},
|
||||
"user": {
|
||||
"avatar": {
|
||||
"submitted": "Téléchargement réussi"
|
||||
|
||||
@ -1,50 +1,67 @@
|
||||
module.exports = [
|
||||
import { enUS, de, nl, fr, es, it, pt, pl } from 'date-fns/locale'
|
||||
import find from 'lodash/find'
|
||||
|
||||
const locales = [
|
||||
{
|
||||
name: 'English',
|
||||
code: 'en',
|
||||
iso: 'en-US',
|
||||
enabled: true,
|
||||
dateFnsLocale: enUS,
|
||||
},
|
||||
{
|
||||
name: 'Deutsch',
|
||||
code: 'de',
|
||||
iso: 'de-DE',
|
||||
enabled: true,
|
||||
dateFnsLocale: de,
|
||||
},
|
||||
{
|
||||
name: 'Nederlands',
|
||||
code: 'nl',
|
||||
iso: 'nl-NL',
|
||||
enabled: true,
|
||||
dateFnsLocale: nl,
|
||||
},
|
||||
{
|
||||
name: 'Français',
|
||||
code: 'fr',
|
||||
iso: 'fr-FR',
|
||||
enabled: true,
|
||||
dateFnsLocale: fr,
|
||||
},
|
||||
{
|
||||
name: 'Italiano',
|
||||
code: 'it',
|
||||
iso: 'it-IT',
|
||||
enabled: true,
|
||||
dateFnsLocale: it,
|
||||
},
|
||||
{
|
||||
name: 'Español',
|
||||
code: 'es',
|
||||
iso: 'es-ES',
|
||||
enabled: true,
|
||||
dateFnsLocale: es,
|
||||
},
|
||||
{
|
||||
name: 'Português',
|
||||
code: 'pt',
|
||||
iso: 'pt-PT',
|
||||
enabled: true,
|
||||
dateFnsLocale: pt,
|
||||
},
|
||||
{
|
||||
name: 'Polski',
|
||||
code: 'pl',
|
||||
iso: 'pl-PL',
|
||||
enabled: true,
|
||||
dateFnsLocale: pl,
|
||||
},
|
||||
]
|
||||
|
||||
export default locales
|
||||
export function getDateFnsLocale({ $i18n }) {
|
||||
const { dateFnsLocale } = find(locales, { code: $i18n.locale() }) || {}
|
||||
return dateFnsLocale || enUS
|
||||
}
|
||||
|
||||
@ -140,5 +140,10 @@
|
||||
"save": "Salva",
|
||||
"edit": "Modifica",
|
||||
"delete": "Cancella"
|
||||
},
|
||||
"contribution": {
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Confermare"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -158,7 +158,10 @@
|
||||
},
|
||||
"contribution": {
|
||||
"edit": "Bijdrage bewerken",
|
||||
"delete": "Bijdrage verwijderen"
|
||||
"delete": "Bijdrage verwijderen",
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Bevestigen"
|
||||
}
|
||||
},
|
||||
"comment": {
|
||||
"edit": "Commentaar bewerken",
|
||||
|
||||
@ -362,6 +362,9 @@
|
||||
"languageSelectLabel": "Język",
|
||||
"categories": {
|
||||
"infoSelectedNoOfMaxCategories": "{chosen} z {max} wybrane kategorie"
|
||||
},
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Potwierdzać"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -203,7 +203,10 @@
|
||||
},
|
||||
"contribution": {
|
||||
"edit": "Editar Contribuição",
|
||||
"delete": "Apagar Contribuição"
|
||||
"delete": "Apagar Contribuição",
|
||||
"teaserImage": {
|
||||
"cropperConfirm": "Confirmar"
|
||||
}
|
||||
},
|
||||
"comment": {
|
||||
"content": {
|
||||
|
||||
@ -1,16 +1,10 @@
|
||||
import defaultConfig from './nuxt.config.js'
|
||||
|
||||
const {
|
||||
css,
|
||||
styleResources,
|
||||
env: { locales },
|
||||
manifest,
|
||||
} = defaultConfig
|
||||
const { css, styleResources, manifest } = defaultConfig
|
||||
|
||||
export default {
|
||||
css,
|
||||
styleResources,
|
||||
env: { locales },
|
||||
manifest,
|
||||
|
||||
head: {
|
||||
|
||||
@ -52,8 +52,6 @@ export default {
|
||||
],
|
||||
// pages to keep alive
|
||||
keepAlivePages: ['index'],
|
||||
// active locales
|
||||
locales: require('./locales'),
|
||||
},
|
||||
/*
|
||||
** Headers of the page
|
||||
|
||||
@ -44,7 +44,8 @@
|
||||
],
|
||||
"moduleNameMapper": {
|
||||
"^@/(.*)$": "<rootDir>/src/$1",
|
||||
"^~/(.*)$": "<rootDir>/$1"
|
||||
"^~/(.*)$": "<rootDir>/$1",
|
||||
"\\.(css|less)$": "identity-obj-proxy"
|
||||
},
|
||||
"testMatch": [
|
||||
"**/?(*.)+(spec|test).js?(x)"
|
||||
@ -52,16 +53,17 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@human-connection/styleguide": "0.5.21",
|
||||
"@nuxtjs/apollo": "^4.0.0-rc14",
|
||||
"@nuxtjs/apollo": "^4.0.0-rc15",
|
||||
"@nuxtjs/axios": "~5.6.0",
|
||||
"@nuxtjs/dotenv": "~1.4.1",
|
||||
"@nuxtjs/pwa": "^3.0.0-beta.19",
|
||||
"@nuxtjs/sentry": "^3.0.0",
|
||||
"@nuxtjs/sentry": "^3.0.1",
|
||||
"@nuxtjs/style-resources": "~1.0.0",
|
||||
"accounting": "~0.4.1",
|
||||
"apollo-cache-inmemory": "~1.6.3",
|
||||
"apollo-client": "~2.6.4",
|
||||
"cookie-universal-nuxt": "~2.0.18",
|
||||
"cropperjs": "^1.5.5",
|
||||
"cross-env": "~6.0.3",
|
||||
"date-fns": "2.4.1",
|
||||
"express": "~4.17.1",
|
||||
@ -70,7 +72,7 @@
|
||||
"jsonwebtoken": "~8.5.1",
|
||||
"linkify-it": "~2.2.0",
|
||||
"node-fetch": "^2.6.0",
|
||||
"nuxt": "~2.10.0",
|
||||
"nuxt": "~2.10.1",
|
||||
"nuxt-dropzone": "^1.0.4",
|
||||
"nuxt-env": "~0.1.0",
|
||||
"stack-utils": "^1.0.2",
|
||||
@ -90,13 +92,13 @@
|
||||
"zxcvbn": "^4.4.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "~7.6.3",
|
||||
"@babel/core": "~7.6.4",
|
||||
"@babel/plugin-syntax-dynamic-import": "^7.2.0",
|
||||
"@babel/preset-env": "~7.6.3",
|
||||
"@storybook/addon-a11y": "^5.2.3",
|
||||
"@storybook/addon-actions": "^5.2.3",
|
||||
"@storybook/vue": "~5.2.3",
|
||||
"@vue/cli-shared-utils": "~3.11.0",
|
||||
"@storybook/addon-a11y": "^5.2.4",
|
||||
"@storybook/addon-actions": "^5.2.4",
|
||||
"@storybook/vue": "~5.2.4",
|
||||
"@vue/cli-shared-utils": "~3.12.0",
|
||||
"@vue/eslint-config-prettier": "~5.0.0",
|
||||
"@vue/server-test-utils": "~1.0.0-beta.29",
|
||||
"@vue/test-utils": "~1.0.0-beta.29",
|
||||
@ -106,14 +108,14 @@
|
||||
"babel-jest": "~24.9.0",
|
||||
"babel-loader": "~8.0.6",
|
||||
"babel-preset-vue": "~2.0.2",
|
||||
"core-js": "~2.6.9",
|
||||
"core-js": "~2.6.10",
|
||||
"css-loader": "~3.2.0",
|
||||
"eslint": "~5.16.0",
|
||||
"eslint-config-prettier": "~6.4.0",
|
||||
"eslint-config-standard": "~12.0.0",
|
||||
"eslint-loader": "~3.0.2",
|
||||
"eslint-plugin-import": "~2.18.2",
|
||||
"eslint-plugin-jest": "~22.17.0",
|
||||
"eslint-plugin-jest": "~22.19.0",
|
||||
"eslint-plugin-node": "~10.0.0",
|
||||
"eslint-plugin-prettier": "~3.1.1",
|
||||
"eslint-plugin-promise": "~4.2.1",
|
||||
@ -121,6 +123,7 @@
|
||||
"eslint-plugin-vue": "~5.2.3",
|
||||
"flush-promises": "^1.0.2",
|
||||
"fuse.js": "^3.4.5",
|
||||
"identity-obj-proxy": "^3.0.0",
|
||||
"jest": "~24.9.0",
|
||||
"mutation-observer": "^1.0.3",
|
||||
"node-sass": "~4.12.0",
|
||||
@ -133,4 +136,4 @@
|
||||
"vue-svg-loader": "~0.12.0",
|
||||
"vue-template-compiler": "^2.6.10"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -190,6 +190,11 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.ds-card-image img {
|
||||
max-height: 2000px;
|
||||
object-fit: contain;
|
||||
}
|
||||
|
||||
.masonry-grid {
|
||||
display: grid;
|
||||
grid-gap: 10px;
|
||||
|
||||
@ -200,8 +200,8 @@ export default {
|
||||
|
||||
.ds-card-image {
|
||||
img {
|
||||
max-height: 710px;
|
||||
object-fit: cover;
|
||||
max-height: 2000px;
|
||||
object-fit: contain;
|
||||
object-position: center;
|
||||
}
|
||||
}
|
||||
|
||||
@ -87,9 +87,5 @@ export default {
|
||||
<style lang="scss">
|
||||
.related-post {
|
||||
box-shadow: $box-shadow-base;
|
||||
|
||||
.ds-card-image {
|
||||
max-height: 80px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
import Vue from 'vue'
|
||||
import vuexI18n from 'vuex-i18n/dist/vuex-i18n.umd.js'
|
||||
import { isEmpty, find } from 'lodash'
|
||||
import locales from '~/locales'
|
||||
|
||||
/**
|
||||
* TODO: Refactor and simplify browser detection
|
||||
@ -76,7 +77,7 @@ export default ({ app, req, cookie, store }) => {
|
||||
}
|
||||
}
|
||||
|
||||
const availableLocales = process.env.locales.filter(lang => !!lang.enabled)
|
||||
const availableLocales = locales.filter(lang => !!lang.enabled)
|
||||
const locale = find(availableLocales, ['code', userLocale]) ? userLocale : 'en'
|
||||
|
||||
if (locale !== 'en') {
|
||||
|
||||
@ -1,36 +1,21 @@
|
||||
import Vue from 'vue'
|
||||
|
||||
import { enUS, de, nl, fr, es } from 'date-fns/locale'
|
||||
import format from 'date-fns/format'
|
||||
import accounting from 'accounting'
|
||||
import trunc from 'trunc-html'
|
||||
import { getDateFnsLocale } from '~/locales'
|
||||
|
||||
export default ({ app = {} }) => {
|
||||
const locales = {
|
||||
en: enUS,
|
||||
de: de,
|
||||
nl: nl,
|
||||
fr: fr,
|
||||
es: es,
|
||||
pt: es,
|
||||
pl: de,
|
||||
}
|
||||
const getLocalizedFormat = () => {
|
||||
let locale = app.$i18n.locale()
|
||||
locale = locales[locale] ? locale : 'en'
|
||||
return locales[locale]
|
||||
}
|
||||
app.$filters = Object.assign(app.$filters || {}, {
|
||||
date: (value, fmt = 'dd. MMM yyyy') => {
|
||||
if (!value) return ''
|
||||
return format(new Date(value), fmt, {
|
||||
locale: getLocalizedFormat(),
|
||||
locale: getDateFnsLocale(app),
|
||||
})
|
||||
},
|
||||
dateTime: (value, fmt = 'dd. MMM yyyy HH:mm') => {
|
||||
if (!value) return ''
|
||||
return format(new Date(value), fmt, {
|
||||
locale: getLocalizedFormat(),
|
||||
locale: getDateFnsLocale(app),
|
||||
})
|
||||
},
|
||||
number: (value, precision = 2, thousands = '.', decimals = ',', fallback = null) => {
|
||||
|
||||
1742
webapp/yarn.lock
1742
webapp/yarn.lock
File diff suppressed because it is too large
Load Diff
@ -1965,6 +1965,11 @@ date-fns@^1.27.2:
|
||||
resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-1.30.1.tgz#2e71bf0b119153dbb4cc4e88d9ea5acfb50dc05c"
|
||||
integrity sha512-hBSVCvSmWC+QypYObzwGOd9wqdDpOt+0wl0KbU+R+uuZBS1jN8VsD1ss3irQDknRj5NvxiTF6oj/nDRnN/UQNw==
|
||||
|
||||
date-fns@^2.4.1:
|
||||
version "2.4.1"
|
||||
resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.4.1.tgz#b53f9bb65ae6bd9239437035710e01cf383b625e"
|
||||
integrity sha512-2RhmH/sjDSCYW2F3ZQxOUx/I7PvzXpi89aQL2d3OAxSTwLx6NilATeUbe0menFE3Lu5lFkOFci36ivimwYHHxw==
|
||||
|
||||
date-now@^0.1.4:
|
||||
version "0.1.4"
|
||||
resolved "https://registry.yarnpkg.com/date-now/-/date-now-0.1.4.tgz#eaf439fd4d4848ad74e5cc7dbef200672b9e345b"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user