From 33f322383c8a34a538b312acb231a0469554cb36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?N=C3=A4ser?= Date: Mon, 16 Jan 2023 13:06:10 +0100 Subject: [PATCH 1/2] chore: add postgres configuration --- apps/backend/config/api.ts | 7 +- apps/backend/config/database.ts | 25 +- apps/backend/package-lock.json | 931 ++++++++++++++++++++++++++++---- apps/backend/package.json | 12 +- apps/backend/postgres.yml | 20 + docker-compose.yml | 25 + package.json | 3 + 7 files changed, 906 insertions(+), 117 deletions(-) create mode 100644 apps/backend/postgres.yml create mode 100644 docker-compose.yml diff --git a/apps/backend/config/api.ts b/apps/backend/config/api.ts index 37f7c14..cebc9f3 100644 --- a/apps/backend/config/api.ts +++ b/apps/backend/config/api.ts @@ -1,7 +1,10 @@ export default { + responses: { + privateAttributes: ['_v', 'id', 'created_at'], + }, rest: { - defaultLimit: 25, - maxLimit: 100, + defaultLimit: 100, + maxLimit: 250, withCount: true, }, }; diff --git a/apps/backend/config/database.ts b/apps/backend/config/database.ts index a239a7f..a162e94 100644 --- a/apps/backend/config/database.ts +++ b/apps/backend/config/database.ts @@ -1,11 +1,24 @@ -import path from 'path'; - -export default ({ env }) => ({ +export default ({env}) => ({ connection: { - client: 'sqlite', + client: 'postgres', connection: { - filename: path.join(__dirname, '..', '..', env('DATABASE_FILENAME', '.tmp/data.db')), + host: env('DATABASE_HOST', 'localhost'), + port: env.int('DATABASE_PORT', 5432), + database: env('DATABASE_NAME', 'bank'), + user: env('DATABASE_USERNAME', 'postgres'), + password: env('DATABASE_PASSWORD', '0000'), + schema: env('DATABASE_SCHEMA', 'public'), // Not required + ssl: { + rejectUnauthorized: env.bool('DATABASE_SSL_SELF', false), + }, }, - useNullAsDefault: true, + debug: false, }, + // connection: { + // client: 'sqlite', + // connection: { + // filename: path.join(__dirname, '..', '..', env('DATABASE_FILENAME', '.tmp/data.db')), + // }, + // useNullAsDefault: true, + // }, }); diff --git a/apps/backend/package-lock.json b/apps/backend/package-lock.json index ae3100a..8cd8e45 100644 --- a/apps/backend/package-lock.json +++ b/apps/backend/package-lock.json @@ -12,9 +12,10 @@ "@strapi/plugin-i18n": "4.5.4", "@strapi/plugin-users-permissions": "4.5.4", "@strapi/strapi": "4.5.4", - "better-sqlite3": "7.4.6" + "@strapi/utils": "^4.5.6", + "better-sqlite3": "7.4.6", + "strapi-plugin-menus": "^1.2.1" }, - "devDependencies": {}, "engines": { "node": ">=14.19.1 <=18.x.x", "npm": ">=6.0.0" @@ -2698,6 +2699,14 @@ "resolved": "https://registry.npmjs.org/@react-dnd/shallowequal/-/shallowequal-2.0.0.tgz", "integrity": "sha512-Pc/AFTdwZwEKJxFJvlxrSmGe/di+aAOBn60sremrpLo6VI/6cmiUYNNwlI5KNYttg7uypzA3ILPMPgxB2GYZEg==" }, + "node_modules/@remix-run/router": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.2.1.tgz", + "integrity": "sha512-XiY0IsyHR+DXYS5vBxpoBe/8veTeoRpMHP+vDosLZxL5bnpetzI0igkxkLZS235ldLzyfkxF+2divEwWHP3vMQ==", + "engines": { + "node": ">=14" + } + }, "node_modules/@rushstack/ts-command-line": { "version": "4.13.1", "resolved": "https://registry.npmjs.org/@rushstack/ts-command-line/-/ts-command-line-4.13.1.tgz", @@ -2992,6 +3001,67 @@ "@strapi/strapi": "^4.3.4" } }, + "node_modules/@strapi/admin/node_modules/@strapi/helper-plugin": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.4.tgz", + "integrity": "sha512-WUXFvcapN1PuKc42DTgp/2yu+XNCYxoI9nN0ddyfjcIy91lRm7VkDScK/q4dPpIEgt1eQYshCI974oKhQfyYTA==", + "dependencies": { + "@fortawesome/fontawesome-free": "^5.15.2", + "@fortawesome/fontawesome-svg-core": "6.2.0", + "@fortawesome/free-brands-svg-icons": "^5.15.2", + "@fortawesome/free-solid-svg-icons": "^5.15.3", + "@fortawesome/react-fontawesome": "^0.2.0", + "axios": "0.27.2", + "date-fns": "2.29.2", + "formik": "^2.2.6", + "immer": "9.0.6", + "invariant": "^2.2.1", + "lodash": "4.17.21", + "match-sorter": "^4.0.2", + "qs": "6.10.1", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "react-helmet": "^6.1.0", + "react-intl": "5.25.1", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "react-select": "5.6.0", + "styled-components": "5.3.3", + "whatwg-fetch": "^3.6.2" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + }, + "peerDependencies": { + "webpack": "^5.74.0" + } + }, + "node_modules/@strapi/admin/node_modules/@strapi/helper-plugin/node_modules/immer": { + "version": "9.0.6", + "resolved": "https://registry.npmjs.org/immer/-/immer-9.0.6.tgz", + "integrity": "sha512-G95ivKpy+EvVAnAab4fVa4YGYn24J1SpEktnJX7JJ45Bd7xqME/SCplFzYFmTbrkwZbQ4xJK1xMTUYBkN6pWsQ==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "node_modules/@strapi/admin/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, "node_modules/@strapi/admin/node_modules/cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", @@ -3155,6 +3225,23 @@ "which": "bin/which" } }, + "node_modules/@strapi/admin/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@strapi/babel-plugin-switch-ee-ce": { "version": "4.5.4", "resolved": "https://registry.npmjs.org/@strapi/babel-plugin-switch-ee-ce/-/babel-plugin-switch-ee-ce-4.5.4.tgz", @@ -3370,24 +3457,53 @@ "npm": ">=6.0.0" } }, - "node_modules/@strapi/helper-plugin": { + "node_modules/@strapi/generators/node_modules/@strapi/utils": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.4.tgz", - "integrity": "sha512-WUXFvcapN1PuKc42DTgp/2yu+XNCYxoI9nN0ddyfjcIy91lRm7VkDScK/q4dPpIEgt1eQYshCI974oKhQfyYTA==", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", "dependencies": { - "@fortawesome/fontawesome-free": "^5.15.2", - "@fortawesome/fontawesome-svg-core": "6.2.0", - "@fortawesome/free-brands-svg-icons": "^5.15.2", - "@fortawesome/free-solid-svg-icons": "^5.15.3", - "@fortawesome/react-fontawesome": "^0.2.0", - "axios": "0.27.2", + "@sindresorhus/slugify": "1.1.0", "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/generators/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@strapi/helper-plugin": { + "version": "4.5.6", + "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.6.tgz", + "integrity": "sha512-yUduRi6qxcBJCPmT+ws3jAKf09nBjQSNxV2FLmhejtlDtOKZ+kLlkHRhGf9P/EV869E+C8OTxnK+SwxlmVijEg==", + "peer": true, + "dependencies": { + "axios": "1.2.1", + "date-fns": "2.29.3", "formik": "^2.2.6", "immer": "9.0.6", "invariant": "^2.2.1", "lodash": "4.17.21", "match-sorter": "^4.0.2", - "qs": "6.10.1", + "qs": "6.11.0", "react": "^17.0.2", "react-dom": "^17.0.2", "react-helmet": "^6.1.0", @@ -3406,6 +3522,45 @@ "webpack": "^5.74.0" } }, + "node_modules/@strapi/helper-plugin/node_modules/axios": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.2.1.tgz", + "integrity": "sha512-I88cFiGu9ryt/tfVEi4kX2SITsvDddTajXTOFmt2uK1ZVA8LytjtdeyefdQWEf5PU8w+4SSJDoYnggflB5tW4A==", + "peer": true, + "dependencies": { + "follow-redirects": "^1.15.0", + "form-data": "^4.0.0", + "proxy-from-env": "^1.1.0" + } + }, + "node_modules/@strapi/helper-plugin/node_modules/date-fns": { + "version": "2.29.3", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.29.3.tgz", + "integrity": "sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA==", + "peer": true, + "engines": { + "node": ">=0.11" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/date-fns" + } + }, + "node_modules/@strapi/helper-plugin/node_modules/qs": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", + "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "peer": true, + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/@strapi/icons": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/@strapi/icons/-/icons-1.4.0.tgz", @@ -3443,6 +3598,39 @@ "npm": ">=6.0.0" } }, + "node_modules/@strapi/permissions/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/permissions/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@strapi/plugin-content-manager": { "version": "4.5.4", "resolved": "https://registry.npmjs.org/@strapi/plugin-content-manager/-/plugin-content-manager-4.5.4.tgz", @@ -3457,6 +3645,39 @@ "npm": ">=6.0.0" } }, + "node_modules/@strapi/plugin-content-manager/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-content-manager/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@strapi/plugin-content-type-builder": { "version": "4.5.4", "resolved": "https://registry.npmjs.org/@strapi/plugin-content-type-builder/-/plugin-content-type-builder-4.5.4.tgz", @@ -3484,125 +3705,473 @@ "npm": ">=6.0.0" } }, - "node_modules/@strapi/plugin-email": { + "node_modules/@strapi/plugin-content-type-builder/node_modules/@strapi/helper-plugin": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/plugin-email/-/plugin-email-4.5.4.tgz", - "integrity": "sha512-E5WjmOpLu966oCMDoYq8qTycWqW+dRHqFn8ejpqrFu0Xl5ksctOVcCke5EctWjFj1TsPkFH1os9WX5+4Ih3tNg==", + "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.4.tgz", + "integrity": "sha512-WUXFvcapN1PuKc42DTgp/2yu+XNCYxoI9nN0ddyfjcIy91lRm7VkDScK/q4dPpIEgt1eQYshCI974oKhQfyYTA==", + "dependencies": { + "@fortawesome/fontawesome-free": "^5.15.2", + "@fortawesome/fontawesome-svg-core": "6.2.0", + "@fortawesome/free-brands-svg-icons": "^5.15.2", + "@fortawesome/free-solid-svg-icons": "^5.15.3", + "@fortawesome/react-fontawesome": "^0.2.0", + "axios": "0.27.2", + "date-fns": "2.29.2", + "formik": "^2.2.6", + "immer": "9.0.6", + "invariant": "^2.2.1", + "lodash": "4.17.21", + "match-sorter": "^4.0.2", + "qs": "6.10.1", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "react-helmet": "^6.1.0", + "react-intl": "5.25.1", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "react-select": "5.6.0", + "styled-components": "5.3.3", + "whatwg-fetch": "^3.6.2" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + }, + "peerDependencies": { + "webpack": "^5.74.0" + } + }, + "node_modules/@strapi/plugin-content-type-builder/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-content-type-builder/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@strapi/plugin-email": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/plugin-email/-/plugin-email-4.5.4.tgz", + "integrity": "sha512-E5WjmOpLu966oCMDoYq8qTycWqW+dRHqFn8ejpqrFu0Xl5ksctOVcCke5EctWjFj1TsPkFH1os9WX5+4Ih3tNg==", + "dependencies": { + "@strapi/provider-email-sendmail": "4.5.4", + "@strapi/utils": "4.5.4", + "lodash": "4.17.21" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-email/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-email/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@strapi/plugin-i18n": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/plugin-i18n/-/plugin-i18n-4.5.4.tgz", + "integrity": "sha512-JcQ11abuZu+VOp0WoW4YX+axIStYAT1bT1yyDW1iAzqUcmM4L6TdJn0y9BZgHmrZP6L3/rIeTEvdYlc3PvP6Mg==", + "dependencies": { + "@strapi/utils": "4.5.4", + "lodash": "4.17.21" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-i18n/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-i18n/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@strapi/plugin-upload": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/plugin-upload/-/plugin-upload-4.5.4.tgz", + "integrity": "sha512-yFiQmu3HjhWtsMp0WY3TBxgg4Y5TfzOkMFHUK4QnvjuEVf8qPIH/4Mw3gIXUd2kgOoFI2bOQzagq9Cfan30GoQ==", + "dependencies": { + "@strapi/helper-plugin": "4.5.4", + "@strapi/provider-upload-local": "4.5.4", + "@strapi/utils": "4.5.4", + "byte-size": "7.0.1", + "cropperjs": "1.5.12", + "date-fns": "2.29.2", + "fs-extra": "10.0.0", + "immer": "9.0.15", + "koa-range": "0.3.0", + "koa-static": "5.0.0", + "lodash": "4.17.21", + "mime-types": "2.1.35", + "react": "^17.0.2", + "react-copy-to-clipboard": "^5.1.0", + "react-dom": "^17.0.2", + "react-intl": "5.25.1", + "react-redux": "7.2.8", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "sharp": "0.31.2" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-upload/node_modules/@strapi/helper-plugin": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.4.tgz", + "integrity": "sha512-WUXFvcapN1PuKc42DTgp/2yu+XNCYxoI9nN0ddyfjcIy91lRm7VkDScK/q4dPpIEgt1eQYshCI974oKhQfyYTA==", + "dependencies": { + "@fortawesome/fontawesome-free": "^5.15.2", + "@fortawesome/fontawesome-svg-core": "6.2.0", + "@fortawesome/free-brands-svg-icons": "^5.15.2", + "@fortawesome/free-solid-svg-icons": "^5.15.3", + "@fortawesome/react-fontawesome": "^0.2.0", + "axios": "0.27.2", + "date-fns": "2.29.2", + "formik": "^2.2.6", + "immer": "9.0.6", + "invariant": "^2.2.1", + "lodash": "4.17.21", + "match-sorter": "^4.0.2", + "qs": "6.10.1", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "react-helmet": "^6.1.0", + "react-intl": "5.25.1", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "react-select": "5.6.0", + "styled-components": "5.3.3", + "whatwg-fetch": "^3.6.2" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + }, + "peerDependencies": { + "webpack": "^5.74.0" + } + }, + "node_modules/@strapi/plugin-upload/node_modules/@strapi/helper-plugin/node_modules/immer": { + "version": "9.0.6", + "resolved": "https://registry.npmjs.org/immer/-/immer-9.0.6.tgz", + "integrity": "sha512-G95ivKpy+EvVAnAab4fVa4YGYn24J1SpEktnJX7JJ45Bd7xqME/SCplFzYFmTbrkwZbQ4xJK1xMTUYBkN6pWsQ==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "node_modules/@strapi/plugin-upload/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-upload/node_modules/immer": { + "version": "9.0.15", + "resolved": "https://registry.npmjs.org/immer/-/immer-9.0.15.tgz", + "integrity": "sha512-2eB/sswms9AEUSkOm4SbV5Y7Vmt/bKRwByd52jfLkW4OLYeaTP3EEiJ9agqU0O/tq6Dk62Zfj+TJSqfm1rLVGQ==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "node_modules/@strapi/plugin-upload/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@strapi/plugin-users-permissions": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/plugin-users-permissions/-/plugin-users-permissions-4.5.4.tgz", + "integrity": "sha512-Vf3BOpLVlkXikzNCso27vCj0n+eCYgaP50p9uv1cQ+ZdmLl8l9Mat333gjCNY87q8faTC/NifNkfGgPK6kikBQ==", + "dependencies": { + "@strapi/helper-plugin": "4.5.4", + "@strapi/utils": "4.5.4", + "bcryptjs": "2.4.3", + "grant-koa": "5.4.8", + "jsonwebtoken": "^8.1.0", + "koa": "^2.13.4", + "koa2-ratelimit": "^1.1.2", + "lodash": "4.17.21", + "purest": "4.0.2", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "react-intl": "5.25.1", + "react-redux": "7.2.8", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "request": "^2.83.0", + "url-join": "4.0.1" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-users-permissions/node_modules/@strapi/helper-plugin": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/helper-plugin/-/helper-plugin-4.5.4.tgz", + "integrity": "sha512-WUXFvcapN1PuKc42DTgp/2yu+XNCYxoI9nN0ddyfjcIy91lRm7VkDScK/q4dPpIEgt1eQYshCI974oKhQfyYTA==", + "dependencies": { + "@fortawesome/fontawesome-free": "^5.15.2", + "@fortawesome/fontawesome-svg-core": "6.2.0", + "@fortawesome/free-brands-svg-icons": "^5.15.2", + "@fortawesome/free-solid-svg-icons": "^5.15.3", + "@fortawesome/react-fontawesome": "^0.2.0", + "axios": "0.27.2", + "date-fns": "2.29.2", + "formik": "^2.2.6", + "immer": "9.0.6", + "invariant": "^2.2.1", + "lodash": "4.17.21", + "match-sorter": "^4.0.2", + "qs": "6.10.1", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "react-helmet": "^6.1.0", + "react-intl": "5.25.1", + "react-router": "^5.2.0", + "react-router-dom": "5.3.4", + "react-select": "5.6.0", + "styled-components": "5.3.3", + "whatwg-fetch": "^3.6.2" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + }, + "peerDependencies": { + "webpack": "^5.74.0" + } + }, + "node_modules/@strapi/plugin-users-permissions/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, + "node_modules/@strapi/plugin-users-permissions/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", "dependencies": { - "@strapi/provider-email-sendmail": "4.5.4", - "@strapi/utils": "4.5.4", - "lodash": "4.17.21" + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" }, "engines": { - "node": ">=14.19.1 <=18.x.x", - "npm": ">=6.0.0" + "node": ">=10" } }, - "node_modules/@strapi/plugin-i18n": { + "node_modules/@strapi/provider-email-sendmail": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/plugin-i18n/-/plugin-i18n-4.5.4.tgz", - "integrity": "sha512-JcQ11abuZu+VOp0WoW4YX+axIStYAT1bT1yyDW1iAzqUcmM4L6TdJn0y9BZgHmrZP6L3/rIeTEvdYlc3PvP6Mg==", + "resolved": "https://registry.npmjs.org/@strapi/provider-email-sendmail/-/provider-email-sendmail-4.5.4.tgz", + "integrity": "sha512-2CVzJkBcFoJeM8Kl8MRRWnfuoEJ5Py+BEoIQTajZTEdNVQymdC7Sb+Svr/05W3nFQ4io5kQvb+HNAoRxo2xFKg==", "dependencies": { "@strapi/utils": "4.5.4", - "lodash": "4.17.21" + "sendmail": "^1.6.1" }, "engines": { "node": ">=14.19.1 <=18.x.x", "npm": ">=6.0.0" } }, - "node_modules/@strapi/plugin-upload": { + "node_modules/@strapi/provider-email-sendmail/node_modules/@strapi/utils": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/plugin-upload/-/plugin-upload-4.5.4.tgz", - "integrity": "sha512-yFiQmu3HjhWtsMp0WY3TBxgg4Y5TfzOkMFHUK4QnvjuEVf8qPIH/4Mw3gIXUd2kgOoFI2bOQzagq9Cfan30GoQ==", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", "dependencies": { - "@strapi/helper-plugin": "4.5.4", - "@strapi/provider-upload-local": "4.5.4", - "@strapi/utils": "4.5.4", - "byte-size": "7.0.1", - "cropperjs": "1.5.12", + "@sindresorhus/slugify": "1.1.0", "date-fns": "2.29.2", - "fs-extra": "10.0.0", - "immer": "9.0.15", - "koa-range": "0.3.0", - "koa-static": "5.0.0", + "http-errors": "1.8.1", "lodash": "4.17.21", - "mime-types": "2.1.35", - "react": "^17.0.2", - "react-copy-to-clipboard": "^5.1.0", - "react-dom": "^17.0.2", - "react-intl": "5.25.1", - "react-redux": "7.2.8", - "react-router": "^5.2.0", - "react-router-dom": "5.3.4", - "sharp": "0.31.2" + "yup": "0.32.9" }, "engines": { "node": ">=14.19.1 <=18.x.x", "npm": ">=6.0.0" } }, - "node_modules/@strapi/plugin-upload/node_modules/immer": { - "version": "9.0.15", - "resolved": "https://registry.npmjs.org/immer/-/immer-9.0.15.tgz", - "integrity": "sha512-2eB/sswms9AEUSkOm4SbV5Y7Vmt/bKRwByd52jfLkW4OLYeaTP3EEiJ9agqU0O/tq6Dk62Zfj+TJSqfm1rLVGQ==", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/immer" + "node_modules/@strapi/provider-email-sendmail/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" } }, - "node_modules/@strapi/plugin-users-permissions": { + "node_modules/@strapi/provider-upload-local": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/plugin-users-permissions/-/plugin-users-permissions-4.5.4.tgz", - "integrity": "sha512-Vf3BOpLVlkXikzNCso27vCj0n+eCYgaP50p9uv1cQ+ZdmLl8l9Mat333gjCNY87q8faTC/NifNkfGgPK6kikBQ==", + "resolved": "https://registry.npmjs.org/@strapi/provider-upload-local/-/provider-upload-local-4.5.4.tgz", + "integrity": "sha512-oPDqQziLCtfyKgXMS7ZjUfIH7dlDymFt0h4uozChaznu1HZ1RCUlcw0ooIxelX2iXoX8pL5413ts2OdGf1eo0Q==", "dependencies": { - "@strapi/helper-plugin": "4.5.4", "@strapi/utils": "4.5.4", - "bcryptjs": "2.4.3", - "grant-koa": "5.4.8", - "jsonwebtoken": "^8.1.0", - "koa": "^2.13.4", - "koa2-ratelimit": "^1.1.2", - "lodash": "4.17.21", - "purest": "4.0.2", - "react": "^17.0.2", - "react-dom": "^17.0.2", - "react-intl": "5.25.1", - "react-redux": "7.2.8", - "react-router": "^5.2.0", - "react-router-dom": "5.3.4", - "request": "^2.83.0", - "url-join": "4.0.1" + "fs-extra": "10.0.0" }, "engines": { "node": ">=14.19.1 <=18.x.x", "npm": ">=6.0.0" } }, - "node_modules/@strapi/provider-email-sendmail": { + "node_modules/@strapi/provider-upload-local/node_modules/@strapi/utils": { "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/provider-email-sendmail/-/provider-email-sendmail-4.5.4.tgz", - "integrity": "sha512-2CVzJkBcFoJeM8Kl8MRRWnfuoEJ5Py+BEoIQTajZTEdNVQymdC7Sb+Svr/05W3nFQ4io5kQvb+HNAoRxo2xFKg==", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", "dependencies": { - "@strapi/utils": "4.5.4", - "sendmail": "^1.6.1" + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" }, "engines": { "node": ">=14.19.1 <=18.x.x", "npm": ">=6.0.0" } }, - "node_modules/@strapi/provider-upload-local": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/provider-upload-local/-/provider-upload-local-4.5.4.tgz", - "integrity": "sha512-oPDqQziLCtfyKgXMS7ZjUfIH7dlDymFt0h4uozChaznu1HZ1RCUlcw0ooIxelX2iXoX8pL5413ts2OdGf1eo0Q==", + "node_modules/@strapi/provider-upload-local/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", "dependencies": { - "@strapi/utils": "4.5.4", - "fs-extra": "10.0.0" + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" }, "engines": { - "node": ">=14.19.1 <=18.x.x", - "npm": ">=6.0.0" + "node": ">=10" } }, "node_modules/@strapi/strapi": { @@ -3673,6 +4242,22 @@ "npm": ">=6.0.0" } }, + "node_modules/@strapi/strapi/node_modules/@strapi/utils": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", + "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "dependencies": { + "@sindresorhus/slugify": "1.1.0", + "date-fns": "2.29.2", + "http-errors": "1.8.1", + "lodash": "4.17.21", + "yup": "0.32.9" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + } + }, "node_modules/@strapi/strapi/node_modules/depd": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", @@ -3722,6 +4307,23 @@ "node": ">= 0.6" } }, + "node_modules/@strapi/strapi/node_modules/yup": { + "version": "0.32.9", + "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", + "integrity": "sha512-Ci1qN+i2H0XpY7syDQ0k5zKQ/DoxO0LzPg8PAR/X4Mpj6DqaeCoIYEEjDJwhArh3Fa7GWbQQVDZKeXYlSH4JMg==", + "dependencies": { + "@babel/runtime": "^7.10.5", + "@types/lodash": "^4.14.165", + "lodash": "^4.17.20", + "lodash-es": "^4.17.15", + "nanoclone": "^0.2.1", + "property-expr": "^2.0.4", + "toposort": "^2.0.2" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@strapi/typescript-utils": { "version": "4.5.4", "resolved": "https://registry.npmjs.org/@strapi/typescript-utils/-/typescript-utils-4.5.4.tgz", @@ -3753,12 +4355,12 @@ } }, "node_modules/@strapi/utils": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.4.tgz", - "integrity": "sha512-LtARhACDp//kJ5My+oQeuFYOCdtxP8BMwVHlqEf1jdT6GnAbqNNCrN85nevZ1mJuZ5BCkQjlwb1wWLGn2GHdDQ==", + "version": "4.5.6", + "resolved": "https://registry.npmjs.org/@strapi/utils/-/utils-4.5.6.tgz", + "integrity": "sha512-kSu7AIoJm0q6uQxiS94FA8huQ0VIvd4B38hDRZLv/BKEOORgfDTflxyxCOW1YIrvuCzJunWC2oZGCphOjMH8jQ==", "dependencies": { "@sindresorhus/slugify": "1.1.0", - "date-fns": "2.29.2", + "date-fns": "2.29.3", "http-errors": "1.8.1", "lodash": "4.17.21", "yup": "0.32.9" @@ -3768,6 +4370,18 @@ "npm": ">=6.0.0" } }, + "node_modules/@strapi/utils/node_modules/date-fns": { + "version": "2.29.3", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.29.3.tgz", + "integrity": "sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA==", + "engines": { + "node": ">=0.11" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/date-fns" + } + }, "node_modules/@strapi/utils/node_modules/yup": { "version": "0.32.9", "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.9.tgz", @@ -12576,6 +13190,12 @@ "node": ">= 0.10" } }, + "node_modules/proxy-from-env": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", + "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==", + "peer": true + }, "node_modules/psl": { "version": "1.9.0", "resolved": "https://registry.npmjs.org/psl/-/psl-1.9.0.tgz", @@ -12871,6 +13491,15 @@ "resolved": "https://registry.npmjs.org/react-fast-compare/-/react-fast-compare-3.2.0.tgz", "integrity": "sha512-rtGImPZ0YyLrscKI9xTpV8psd6I8VAtjKCzQDlzyDvqJA8XOW78TXYQwNRNd8g8JZnDu8q9Fu/1v4HPAVwVdHA==" }, + "node_modules/react-flip-move": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/react-flip-move/-/react-flip-move-3.0.5.tgz", + "integrity": "sha512-Mf4XpbkUNZy9eu80iXXFIjToDvw+bnHxmKHVoositbMpV87O/EQswnXUqVovRHoTx/F+4dE+p//PyJnAT7OtPA==", + "peerDependencies": { + "react": ">=16.3.x", + "react-dom": ">=16.3.x" + } + }, "node_modules/react-helmet": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/react-helmet/-/react-helmet-6.1.0.tgz", @@ -14624,6 +15253,115 @@ "resolved": "https://registry.npmjs.org/std-env/-/std-env-3.3.1.tgz", "integrity": "sha512-3H20QlwQsSm2OvAxWIYhs+j01MzzqwMwGiiO1NQaJYZgJZFPuAbf95/DiKRBSTYIJ2FeGUc+B/6mPGcWP9dO3Q==" }, + "node_modules/strapi-plugin-menus": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/strapi-plugin-menus/-/strapi-plugin-menus-1.2.1.tgz", + "integrity": "sha512-r/vHYAZ/efZ4TyhsTTydX7d9w30ZoX5TdU6ojj8ze4CpkJw9yiyVlML5UKe+VVqADkOCgxAfcpUau+/vZpVQsg==", + "dependencies": { + "axios": "^0.27.2", + "lodash": "4.17.21", + "prop-types": "^15.8.1", + "qs": "^6.10.3", + "react": "^17.0.2", + "react-flip-move": "^3.0.4", + "react-intl": "^5.24.6", + "react-query": "^3.34.15", + "react-redux": "^7.2.6", + "react-router-dom": "^6.2.1", + "react-select": "^5.2.2", + "styled-components": "^5.3.3" + }, + "engines": { + "node": ">=14.19.1 <=18.x.x", + "npm": ">=6.0.0" + }, + "peerDependencies": { + "@strapi/design-system": "^1.4.0", + "@strapi/helper-plugin": "^4.5.6", + "@strapi/icons": "^1.4.0", + "@strapi/strapi": "^4.5.6", + "@strapi/utils": "^4.5.6", + "formik": "^2.2.9" + } + }, + "node_modules/strapi-plugin-menus/node_modules/match-sorter": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/match-sorter/-/match-sorter-6.3.1.tgz", + "integrity": "sha512-mxybbo3pPNuA+ZuCUhm5bwNkXrJTbsk5VWbR5wiwz/GC6LIiegBGn2w3O08UG/jdbYLinw51fSQ5xNU1U3MgBw==", + "dependencies": { + "@babel/runtime": "^7.12.5", + "remove-accents": "0.4.2" + } + }, + "node_modules/strapi-plugin-menus/node_modules/qs": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", + "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/strapi-plugin-menus/node_modules/react-query": { + "version": "3.39.2", + "resolved": "https://registry.npmjs.org/react-query/-/react-query-3.39.2.tgz", + "integrity": "sha512-F6hYDKyNgDQfQOuR1Rsp3VRzJnWHx6aRnnIZHMNGGgbL3SBgpZTDg8MQwmxOgpCAoqZJA+JSNCydF1xGJqKOCA==", + "dependencies": { + "@babel/runtime": "^7.5.5", + "broadcast-channel": "^3.4.1", + "match-sorter": "^6.0.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + }, + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "react-dom": { + "optional": true + }, + "react-native": { + "optional": true + } + } + }, + "node_modules/strapi-plugin-menus/node_modules/react-router-dom": { + "version": "6.6.2", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.6.2.tgz", + "integrity": "sha512-6SCDXxRQqW5af8ImOqKza7icmQ47/EMbz572uFjzvcArg3lZ+04PxSPp8qGs+p2Y+q+b+S/AjXv8m8dyLndIIA==", + "dependencies": { + "@remix-run/router": "1.2.1", + "react-router": "6.6.2" + }, + "engines": { + "node": ">=14" + }, + "peerDependencies": { + "react": ">=16.8", + "react-dom": ">=16.8" + } + }, + "node_modules/strapi-plugin-menus/node_modules/react-router-dom/node_modules/react-router": { + "version": "6.6.2", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.6.2.tgz", + "integrity": "sha512-uJPG55Pek3orClbURDvfljhqFvMgJRo59Pktywkk8hUUkTY2aRfza8Yhl/vZQXs+TNQyr6tu+uqz/fLxPICOGQ==", + "dependencies": { + "@remix-run/router": "1.2.1" + }, + "engines": { + "node": ">=14" + }, + "peerDependencies": { + "react": ">=16.8" + } + }, "node_modules/stream-browserify": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-3.0.0.tgz", @@ -16313,23 +17051,6 @@ "funding": { "url": "https://github.com/sponsors/sindresorhus" } - }, - "node_modules/yup": { - "version": "0.32.11", - "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.11.tgz", - "integrity": "sha512-Z2Fe1bn+eLstG8DRR6FTavGD+MeAwyfmouhHsIUgaADz8jvFKbO/fXc2trJKZg+5EBjh4gGm3iU/t3onKlXHIg==", - "dependencies": { - "@babel/runtime": "^7.15.4", - "@types/lodash": "^4.14.175", - "lodash": "^4.17.21", - "lodash-es": "^4.17.21", - "nanoclone": "^0.2.1", - "property-expr": "^2.0.4", - "toposort": "^2.0.2" - }, - "engines": { - "node": ">=10" - } } } } diff --git a/apps/backend/package.json b/apps/backend/package.json index f0eb66d..6b151d6 100644 --- a/apps/backend/package.json +++ b/apps/backend/package.json @@ -9,12 +9,16 @@ "build": "strapi build", "strapi": "strapi" }, - "devDependencies": {}, + "overrides": { + "@strapi/strapi": "4.5.4" + }, "dependencies": { - "@strapi/strapi": "4.5.4", - "@strapi/plugin-users-permissions": "4.5.4", "@strapi/plugin-i18n": "4.5.4", - "better-sqlite3": "7.4.6" + "@strapi/plugin-users-permissions": "4.5.4", + "@strapi/strapi": "4.5.4", + "@strapi/utils": "^4.5.6", + "better-sqlite3": "7.4.6", + "strapi-plugin-menus": "^1.2.1" }, "author": { "name": "A Strapi developer" diff --git a/apps/backend/postgres.yml b/apps/backend/postgres.yml new file mode 100644 index 0000000..432ed1b --- /dev/null +++ b/apps/backend/postgres.yml @@ -0,0 +1,20 @@ +services: + gs_postgres: + image: postgres:14-alpine + container_name: gs_postgres + shm_size: '4gb' + environment: + POSTGRES_USER: ${DATABASE_USERNAME} + POSTGRES_PASSWORD: ${DATABASE_PASSWORD} + POSTGRES_DB: ${DATABASE_NAME} + TZ: Europe/Paris + healthcheck: + test: 'PGPASSWORD="${DATABASE_PASSWORD}" psql --host ${DATABASE_HOST} --username ${DATABASE_USERNAME} --dbname ${DATABASE_NAME} -c "select 1" ; [ "0" -eq "$$?" ]; echo $$?' + interval: 30s + timeout: 10s + retries: 3 + volumes: + - gs_postgres-master:/var/lib/postgresql/data:z + - ./.db/init:/docker-entrypoint-initdb.d + ports: + - ${DATABASE_PORT}:5432 # DB diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..3948b2f --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,25 @@ +services: + + # PostgreSQL (Database) + gs_postgres: + extends: + file: apps/backend/postgres.yml + service: gs_postgres + + gs_redis: + image: "redis:alpine" + ports: + - "6379:6379" + + gs_redis_commander: + image: rediscommander/redis-commander:latest + environment: + - REDIS_HOSTS=local:gs_redis:6379 + ports: + - "8081:8081" + depends_on: + - gs_redis + +volumes: + gs_postgres-master: + driver: local diff --git a/package.json b/package.json index bff0c10..c2d216b 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,10 @@ "version": "0.0.0", "license": "MIT", "scripts": { + "start:docker": "env $(cat apps/backend/.env) docker-compose up -d", + "install:backend": "cd apps/backend && npm install", "build:backend": "cd apps/backend && npm run build", + "predevelop:backend": "npm run start:docker && npm run build:backend", "develop:backend": "cd apps/backend && npm run develop", "start": "nx serve", "build": "nx build", From f8fbd9aaa45233dd000ea68c97f702e6b41372f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?N=C3=A4ser?= Date: Tue, 17 Jan 2023 14:46:55 +0100 Subject: [PATCH 2/2] feat: Add global layout Features added : - Add tailwind CSS framework - Built Layout with header / footer - Build dynamic Menu from Strapi - Build dynamic SEO parameters --- apps/backend/config/database.ts | 4 +- apps/backend/package-lock.json | 138 ++- apps/backend/package.json | 4 +- .../api/page/content-types/page/schema.json | 28 + apps/backend/src/api/page/controllers/page.ts | 7 + apps/backend/src/api/page/routes/page.ts | 7 + apps/backend/src/api/page/services/page.ts | 7 + apps/backend/src/components/meta/meta.json | 16 + apps/backend/src/components/shared/seo.json | 36 + .../src/components/shared/shared-image.json | 24 + apps/client/.env | 1 + .../components/carousel/carousel.module.scss | 7 + .../components/carousel/carousel.spec.tsx | 10 + apps/client/components/carousel/carousel.tsx | 14 + .../components/footer/footer.module.scss | 7 + apps/client/components/footer/footer.spec.tsx | 10 + apps/client/components/footer/footer.tsx | 36 + .../components/header/header.module.scss | 7 + apps/client/components/header/header.spec.tsx | 10 + apps/client/components/header/header.tsx | 152 ++++ .../components/layout/layout.module.scss | 12 + apps/client/components/layout/layout.spec.tsx | 10 + apps/client/components/layout/layout.tsx | 18 + .../seo-config/seo-config.module.scss | 7 + .../components/seo-config/seo-config.spec.tsx | 10 + .../components/seo-config/seo-config.tsx | 69 ++ apps/client/config.ts | 44 + apps/client/libs/api.ts | 37 + apps/client/pages/_app.tsx | 12 +- apps/client/pages/index.tsx | 433 +-------- apps/client/pages/styles.css | 405 +-------- apps/client/postcss.config.js | 15 + apps/client/tailwind.config.js | 20 + package-lock.json | 825 ++++++++++++++++-- package.json | 9 + 35 files changed, 1571 insertions(+), 880 deletions(-) create mode 100644 apps/backend/src/api/page/content-types/page/schema.json create mode 100644 apps/backend/src/api/page/controllers/page.ts create mode 100644 apps/backend/src/api/page/routes/page.ts create mode 100644 apps/backend/src/api/page/services/page.ts create mode 100644 apps/backend/src/components/meta/meta.json create mode 100644 apps/backend/src/components/shared/seo.json create mode 100644 apps/backend/src/components/shared/shared-image.json create mode 100644 apps/client/.env create mode 100644 apps/client/components/carousel/carousel.module.scss create mode 100644 apps/client/components/carousel/carousel.spec.tsx create mode 100644 apps/client/components/carousel/carousel.tsx create mode 100644 apps/client/components/footer/footer.module.scss create mode 100644 apps/client/components/footer/footer.spec.tsx create mode 100644 apps/client/components/footer/footer.tsx create mode 100644 apps/client/components/header/header.module.scss create mode 100644 apps/client/components/header/header.spec.tsx create mode 100644 apps/client/components/header/header.tsx create mode 100644 apps/client/components/layout/layout.module.scss create mode 100644 apps/client/components/layout/layout.spec.tsx create mode 100644 apps/client/components/layout/layout.tsx create mode 100644 apps/client/components/seo-config/seo-config.module.scss create mode 100644 apps/client/components/seo-config/seo-config.spec.tsx create mode 100644 apps/client/components/seo-config/seo-config.tsx create mode 100644 apps/client/config.ts create mode 100644 apps/client/libs/api.ts create mode 100644 apps/client/postcss.config.js create mode 100644 apps/client/tailwind.config.js diff --git a/apps/backend/config/database.ts b/apps/backend/config/database.ts index a162e94..e838feb 100644 --- a/apps/backend/config/database.ts +++ b/apps/backend/config/database.ts @@ -8,9 +8,7 @@ export default ({env}) => ({ user: env('DATABASE_USERNAME', 'postgres'), password: env('DATABASE_PASSWORD', '0000'), schema: env('DATABASE_SCHEMA', 'public'), // Not required - ssl: { - rejectUnauthorized: env.bool('DATABASE_SSL_SELF', false), - }, + ssl: false, }, debug: false, }, diff --git a/apps/backend/package-lock.json b/apps/backend/package-lock.json index 8cd8e45..c7ed4ef 100644 --- a/apps/backend/package-lock.json +++ b/apps/backend/package-lock.json @@ -14,7 +14,9 @@ "@strapi/strapi": "4.5.4", "@strapi/utils": "^4.5.6", "better-sqlite3": "7.4.6", - "strapi-plugin-menus": "^1.2.1" + "pg": "^8.8.0", + "strapi-plugin-menus": "^1.2.1", + "strapi-plugin-populate-deep": "^1.1.2" }, "engines": { "node": ">=14.19.1 <=18.x.x", @@ -5926,6 +5928,14 @@ "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" }, + "node_modules/buffer-writer": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/buffer-writer/-/buffer-writer-2.0.0.tgz", + "integrity": "sha512-a7ZpuTZU1TRtnwyCNW3I5dc0wWNC3VR9S++Ewyk2HHZdrO3CQJqSpd+95Us590V6AL7JqUAH2IwZ/398PmNFgw==", + "engines": { + "node": ">=4" + } + }, "node_modules/buffer-xor": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/buffer-xor/-/buffer-xor-1.0.3.tgz", @@ -12328,6 +12338,11 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/packet-reader": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/packet-reader/-/packet-reader-1.0.0.tgz", + "integrity": "sha512-HAKu/fG3HpHFO0AA8WE8q2g+gBJaZ9MG7fcKk+IJPLTGAD6Psw4443l+9DGRbOIh3/aXr7Phy0TjilYivJo5XQ==" + }, "node_modules/pako": { "version": "1.0.11", "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", @@ -12616,11 +12631,80 @@ "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", "integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==" }, + "node_modules/pg": { + "version": "8.8.0", + "resolved": "https://registry.npmjs.org/pg/-/pg-8.8.0.tgz", + "integrity": "sha512-UXYN0ziKj+AeNNP7VDMwrehpACThH7LUl/p8TDFpEUuSejCUIwGSfxpHsPvtM6/WXFy6SU4E5RG4IJV/TZAGjw==", + "dependencies": { + "buffer-writer": "2.0.0", + "packet-reader": "1.0.0", + "pg-connection-string": "^2.5.0", + "pg-pool": "^3.5.2", + "pg-protocol": "^1.5.0", + "pg-types": "^2.1.0", + "pgpass": "1.x" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "pg-native": ">=3.0.1" + }, + "peerDependenciesMeta": { + "pg-native": { + "optional": true + } + } + }, "node_modules/pg-connection-string": { "version": "2.5.0", "resolved": "https://registry.npmjs.org/pg-connection-string/-/pg-connection-string-2.5.0.tgz", "integrity": "sha512-r5o/V/ORTA6TmUnyWZR9nCj1klXCO2CEKNRlVuJptZe85QuhFayC7WeMic7ndayT5IRIR0S0xFxFi2ousartlQ==" }, + "node_modules/pg-int8": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/pg-int8/-/pg-int8-1.0.1.tgz", + "integrity": "sha512-WCtabS6t3c8SkpDBUlb1kjOs7l66xsGdKpIPZsg4wR+B3+u9UAum2odSsF9tnvxg80h4ZxLWMy4pRjOsFIqQpw==", + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/pg-pool": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/pg-pool/-/pg-pool-3.5.2.tgz", + "integrity": "sha512-His3Fh17Z4eg7oANLob6ZvH8xIVen3phEZh2QuyrIl4dQSDVEabNducv6ysROKpDNPSD+12tONZVWfSgMvDD9w==", + "peerDependencies": { + "pg": ">=8.0" + } + }, + "node_modules/pg-protocol": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.5.0.tgz", + "integrity": "sha512-muRttij7H8TqRNu/DxrAJQITO4Ac7RmX3Klyr/9mJEOBeIpgnF8f9jAfRz5d3XwQZl5qBjF9gLsUtMPJE0vezQ==" + }, + "node_modules/pg-types": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz", + "integrity": "sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA==", + "dependencies": { + "pg-int8": "1.0.1", + "postgres-array": "~2.0.0", + "postgres-bytea": "~1.0.0", + "postgres-date": "~1.0.4", + "postgres-interval": "^1.1.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pgpass": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/pgpass/-/pgpass-1.0.5.tgz", + "integrity": "sha512-FdW9r/jQZhSeohs1Z3sI1yxFQNFvMcnmfuj4WBMUTxOrAyLMaTcE1aAMBiTlbMNaXvBCQuVi0R7hd8udDSP7ug==", + "dependencies": { + "split2": "^4.1.0" + } + }, "node_modules/picocolors": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", @@ -13081,6 +13165,41 @@ "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz", "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==" }, + "node_modules/postgres-array": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/postgres-array/-/postgres-array-2.0.0.tgz", + "integrity": "sha512-VpZrUqU5A69eQyW2c5CA1jtLecCsN2U/bD6VilrFDWq5+5UIEVO7nazS3TEcHf1zuPYO/sqGvUvW62g86RXZuA==", + "engines": { + "node": ">=4" + } + }, + "node_modules/postgres-bytea": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/postgres-bytea/-/postgres-bytea-1.0.0.tgz", + "integrity": "sha512-xy3pmLuQqRBZBXDULy7KbaitYqLcmxigw14Q5sj8QBVLqEwXfeybIKVWiqAXTlcvdvb0+xkOtDbfQMOf4lST1w==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/postgres-date": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/postgres-date/-/postgres-date-1.0.7.tgz", + "integrity": "sha512-suDmjLVQg78nMK2UZ454hAG+OAW+HQPZ6n++TNDUX+L0+uUlLywnoxJKDou51Zm+zTCjrCl0Nq6J9C5hP9vK/Q==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/postgres-interval": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/postgres-interval/-/postgres-interval-1.2.0.tgz", + "integrity": "sha512-9ZhXKM/rw350N1ovuWHbGxnGh/SNJ4cnxHiM0rxE4VN41wsg8P8zWn9hv/buK00RP4WvlOyr/RBDiptyxVbkZQ==", + "dependencies": { + "xtend": "^4.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/prebuild-install": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.1.tgz", @@ -15110,6 +15229,14 @@ "node": ">=0.10.0" } }, + "node_modules/split2": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/split2/-/split2-4.1.0.tgz", + "integrity": "sha512-VBiJxFkxiXRlUIeyMQi8s4hgvKCSjtknJv/LVYbrgALPwf5zSKmEwV9Lst25AkvMDnvxODugjdl6KZgwKM1WYQ==", + "engines": { + "node": ">= 10.x" + } + }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -15362,6 +15489,15 @@ "react": ">=16.8" } }, + "node_modules/strapi-plugin-populate-deep": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/strapi-plugin-populate-deep/-/strapi-plugin-populate-deep-1.1.2.tgz", + "integrity": "sha512-fKw1BMRpdWbi1D+E0Yq08lZFxrTHgdPQ2P5jKEuXEE5YHvHiepSHVQtymDJGQ3WRWierem8ZBpnz2nl6iRx8Gw==", + "engines": { + "node": ">=12.x.x <=16.x.x", + "npm": ">=6.0.0" + } + }, "node_modules/stream-browserify": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-3.0.0.tgz", diff --git a/apps/backend/package.json b/apps/backend/package.json index 6b151d6..748e862 100644 --- a/apps/backend/package.json +++ b/apps/backend/package.json @@ -18,7 +18,9 @@ "@strapi/strapi": "4.5.4", "@strapi/utils": "^4.5.6", "better-sqlite3": "7.4.6", - "strapi-plugin-menus": "^1.2.1" + "pg": "^8.8.0", + "strapi-plugin-menus": "^1.2.1", + "strapi-plugin-populate-deep": "^1.1.2" }, "author": { "name": "A Strapi developer" diff --git a/apps/backend/src/api/page/content-types/page/schema.json b/apps/backend/src/api/page/content-types/page/schema.json new file mode 100644 index 0000000..5100f7e --- /dev/null +++ b/apps/backend/src/api/page/content-types/page/schema.json @@ -0,0 +1,28 @@ +{ + "kind": "collectionType", + "collectionName": "pages", + "info": { + "singularName": "page", + "pluralName": "pages", + "displayName": "Pages", + "description": "" + }, + "options": { + "draftAndPublish": true + }, + "pluginOptions": {}, + "attributes": { + "label": { + "type": "string" + }, + "slug": { + "type": "uid", + "targetField": "label" + }, + "seo": { + "type": "component", + "repeatable": false, + "component": "shared.seo" + } + } +} diff --git a/apps/backend/src/api/page/controllers/page.ts b/apps/backend/src/api/page/controllers/page.ts new file mode 100644 index 0000000..f513618 --- /dev/null +++ b/apps/backend/src/api/page/controllers/page.ts @@ -0,0 +1,7 @@ +/** + * page controller + */ + +import { factories } from '@strapi/strapi' + +export default factories.createCoreController('api::page.page'); diff --git a/apps/backend/src/api/page/routes/page.ts b/apps/backend/src/api/page/routes/page.ts new file mode 100644 index 0000000..8e5ddfc --- /dev/null +++ b/apps/backend/src/api/page/routes/page.ts @@ -0,0 +1,7 @@ +/** + * page router + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreRouter('api::page.page'); diff --git a/apps/backend/src/api/page/services/page.ts b/apps/backend/src/api/page/services/page.ts new file mode 100644 index 0000000..eaf07ff --- /dev/null +++ b/apps/backend/src/api/page/services/page.ts @@ -0,0 +1,7 @@ +/** + * page service + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreService('api::page.page'); diff --git a/apps/backend/src/components/meta/meta.json b/apps/backend/src/components/meta/meta.json new file mode 100644 index 0000000..cb9ba70 --- /dev/null +++ b/apps/backend/src/components/meta/meta.json @@ -0,0 +1,16 @@ +{ + "collectionName": "components_meta_metas", + "info": { + "displayName": "meta", + "icon": "network-wired" + }, + "options": {}, + "attributes": { + "property": { + "type": "string" + }, + "content": { + "type": "string" + } + } +} diff --git a/apps/backend/src/components/shared/seo.json b/apps/backend/src/components/shared/seo.json new file mode 100644 index 0000000..c9f433e --- /dev/null +++ b/apps/backend/src/components/shared/seo.json @@ -0,0 +1,36 @@ +{ + "collectionName": "components_shared_seos", + "info": { + "displayName": "Seo", + "icon": "book", + "description": "" + }, + "options": {}, + "attributes": { + "metaTitle": { + "type": "string" + }, + "metaDescription": { + "type": "string" + }, + "SharedImage": { + "displayName": "SharedImage", + "type": "component", + "repeatable": false, + "component": "shared.shared-image" + }, + "Meta": { + "displayName": "meta", + "type": "component", + "repeatable": true, + "component": "meta.meta" + }, + "preventIndexing": { + "type": "boolean", + "default": false + }, + "structuredData": { + "type": "json" + } + } +} diff --git a/apps/backend/src/components/shared/shared-image.json b/apps/backend/src/components/shared/shared-image.json new file mode 100644 index 0000000..4424287 --- /dev/null +++ b/apps/backend/src/components/shared/shared-image.json @@ -0,0 +1,24 @@ +{ + "collectionName": "components_shared_shared_images", + "info": { + "displayName": "SharedImage", + "icon": "file-image", + "description": "" + }, + "options": {}, + "attributes": { + "alt": { + "type": "string" + }, + "media": { + "allowedTypes": [ + "images", + "files", + "videos", + "audios" + ], + "type": "media", + "multiple": false + } + } +} diff --git a/apps/client/.env b/apps/client/.env new file mode 100644 index 0000000..172e20c --- /dev/null +++ b/apps/client/.env @@ -0,0 +1 @@ +STRAPI_URL=http://127.0.0.1:1337/api diff --git a/apps/client/components/carousel/carousel.module.scss b/apps/client/components/carousel/carousel.module.scss new file mode 100644 index 0000000..45c2aa4 --- /dev/null +++ b/apps/client/components/carousel/carousel.module.scss @@ -0,0 +1,7 @@ +/* + * Replace this with your own classes + * + * e.g. + * .container { + * } +*/ diff --git a/apps/client/components/carousel/carousel.spec.tsx b/apps/client/components/carousel/carousel.spec.tsx new file mode 100644 index 0000000..4201b81 --- /dev/null +++ b/apps/client/components/carousel/carousel.spec.tsx @@ -0,0 +1,10 @@ +import { render } from '@testing-library/react'; + +import Carousel from './carousel'; + +describe('Carousel', () => { + it('should render successfully', () => { + const { baseElement } = render(); + expect(baseElement).toBeTruthy(); + }); +}); diff --git a/apps/client/components/carousel/carousel.tsx b/apps/client/components/carousel/carousel.tsx new file mode 100644 index 0000000..42fe9e1 --- /dev/null +++ b/apps/client/components/carousel/carousel.tsx @@ -0,0 +1,14 @@ +import styles from './carousel.module.scss'; + +/* eslint-disable-next-line */ +export interface CarouselProps {} + +export function Carousel(props: CarouselProps) { + return ( +
+

Welcome to Carousel!

+
+ ); +} + +export default Carousel; diff --git a/apps/client/components/footer/footer.module.scss b/apps/client/components/footer/footer.module.scss new file mode 100644 index 0000000..45c2aa4 --- /dev/null +++ b/apps/client/components/footer/footer.module.scss @@ -0,0 +1,7 @@ +/* + * Replace this with your own classes + * + * e.g. + * .container { + * } +*/ diff --git a/apps/client/components/footer/footer.spec.tsx b/apps/client/components/footer/footer.spec.tsx new file mode 100644 index 0000000..97c820b --- /dev/null +++ b/apps/client/components/footer/footer.spec.tsx @@ -0,0 +1,10 @@ +import { render } from '@testing-library/react'; + +import Footer from './footer'; + +describe('Footer', () => { + it('should render successfully', () => { + const { baseElement } = render(