From 3e3dbed6e64edeb45d9e3ace103d41ec41f41905 Mon Sep 17 00:00:00 2001 From: Schneider Roland Date: Fri, 31 Jan 2025 21:42:52 +0100 Subject: [PATCH] add faq page --- yoga-app/package-lock.json | 226 +++++++++++++++++- yoga-app/package.json | 1 + yoga-app/src/api/strapi/query/faq.json | 66 +++++ yoga-app/src/api/strapi/strapi-api.ts | 6 + yoga-app/src/app/faq/page.tsx | 27 ++- .../src/components/breadcrumbs.component.tsx | 1 + yoga-app/src/components/faq.component.tsx | 74 ++++++ yoga-app/src/components/faq.qa.component.tsx | 50 ++++ yoga-app/src/components/faq.qa.module.scss | 4 + .../api/faq-page.ts | 58 +++++ .../api/yoga-faq-component.ts | 38 +++ .../api/yoga-faq-qa.ts | 30 +++ .../api/faq-page.ts | 58 +++++ .../api/yoga-faq-component.ts | 38 +++ .../api/yoga-faq-qa.ts | 30 +++ .../content-types/faq-page/schema.json | 47 ++++ .../src/api/faq-page/controllers/faq-page.ts | 7 + yoga-cms/src/api/faq-page/routes/faq-page.ts | 7 + .../src/api/faq-page/services/faq-page.ts | 7 + .../yoga-faq-component/schema.json | 30 +++ .../controllers/yoga-faq-component.ts | 7 + .../routes/yoga-faq-component.ts | 7 + .../services/yoga-faq-component.ts | 7 + .../content-types/yoga-faq-qa/schema.json | 24 ++ .../yoga-faq-qa/controllers/yoga-faq-qa.ts | 7 + .../src/api/yoga-faq-qa/routes/yoga-faq-qa.ts | 7 + .../api/yoga-faq-qa/services/yoga-faq-qa.ts | 7 + yoga-cms/types/generated/contentTypes.d.ts | 119 +++++++++ 28 files changed, 970 insertions(+), 20 deletions(-) create mode 100644 yoga-app/src/api/strapi/query/faq.json create mode 100644 yoga-app/src/components/faq.component.tsx create mode 100644 yoga-app/src/components/faq.qa.component.tsx create mode 100644 yoga-app/src/components/faq.qa.module.scss create mode 100644 yoga-app/src/types/generated-strapi-interfaces/api/faq-page.ts create mode 100644 yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-component.ts create mode 100644 yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-qa.ts create mode 100644 yoga-cms/generated-strapi-interfaces/api/faq-page.ts create mode 100644 yoga-cms/generated-strapi-interfaces/api/yoga-faq-component.ts create mode 100644 yoga-cms/generated-strapi-interfaces/api/yoga-faq-qa.ts create mode 100644 yoga-cms/src/api/faq-page/content-types/faq-page/schema.json create mode 100644 yoga-cms/src/api/faq-page/controllers/faq-page.ts create mode 100644 yoga-cms/src/api/faq-page/routes/faq-page.ts create mode 100644 yoga-cms/src/api/faq-page/services/faq-page.ts create mode 100644 yoga-cms/src/api/yoga-faq-component/content-types/yoga-faq-component/schema.json create mode 100644 yoga-cms/src/api/yoga-faq-component/controllers/yoga-faq-component.ts create mode 100644 yoga-cms/src/api/yoga-faq-component/routes/yoga-faq-component.ts create mode 100644 yoga-cms/src/api/yoga-faq-component/services/yoga-faq-component.ts create mode 100644 yoga-cms/src/api/yoga-faq-qa/content-types/yoga-faq-qa/schema.json create mode 100644 yoga-cms/src/api/yoga-faq-qa/controllers/yoga-faq-qa.ts create mode 100644 yoga-cms/src/api/yoga-faq-qa/routes/yoga-faq-qa.ts create mode 100644 yoga-cms/src/api/yoga-faq-qa/services/yoga-faq-qa.ts diff --git a/yoga-app/package-lock.json b/yoga-app/package-lock.json index e11ac91..652b008 100644 --- a/yoga-app/package-lock.json +++ b/yoga-app/package-lock.json @@ -26,6 +26,7 @@ "pg": "^8.13.1", "qs": "^6.14.0", "react": "^19.0.0", + "react-bootstrap": "^2.10.9", "react-dom": "^19.0.0" }, "devDependencies": { @@ -40,6 +41,17 @@ "typescript": "^5" } }, + "node_modules/@babel/runtime": { + "version": "7.26.7", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.26.7.tgz", + "integrity": "sha512-AOPI3D+a8dXnja+iwsUqGRjr1BbZIe771sXdapOtYI531gSqpi92vXivKcq2asu/DFpdl1ceFAKZyRzK2PCVcQ==", + "dependencies": { + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, "node_modules/@emnapi/runtime": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.3.1.tgz", @@ -1091,6 +1103,70 @@ "url": "https://opencollective.com/popperjs" } }, + "node_modules/@react-aria/ssr": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/@react-aria/ssr/-/ssr-3.9.7.tgz", + "integrity": "sha512-GQygZaGlmYjmYM+tiNBA5C6acmiDWF52Nqd40bBp0Znk4M4hP+LTmI0lpI1BuKMw45T8RIhrAsICIfKwZvi2Gg==", + "dependencies": { + "@swc/helpers": "^0.5.0" + }, + "engines": { + "node": ">= 12" + }, + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" + } + }, + "node_modules/@restart/hooks": { + "version": "0.4.16", + "resolved": "https://registry.npmjs.org/@restart/hooks/-/hooks-0.4.16.tgz", + "integrity": "sha512-f7aCv7c+nU/3mF7NWLtVVr0Ra80RqsO89hO72r+Y/nvQr5+q0UFGkocElTH6MJApvReVh6JHUFYn2cw1WdHF3w==", + "dependencies": { + "dequal": "^2.0.3" + }, + "peerDependencies": { + "react": ">=16.8.0" + } + }, + "node_modules/@restart/ui": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@restart/ui/-/ui-1.9.4.tgz", + "integrity": "sha512-N4C7haUc3vn4LTwVUPlkJN8Ach/+yIMvRuTVIhjilNHqegY60SGLrzud6errOMNJwSnmYFnt1J0H/k8FE3A4KA==", + "dependencies": { + "@babel/runtime": "^7.26.0", + "@popperjs/core": "^2.11.8", + "@react-aria/ssr": "^3.5.0", + "@restart/hooks": "^0.5.0", + "@types/warning": "^3.0.3", + "dequal": "^2.0.3", + "dom-helpers": "^5.2.0", + "uncontrollable": "^8.0.4", + "warning": "^4.0.3" + }, + "peerDependencies": { + "react": ">=16.14.0", + "react-dom": ">=16.14.0" + } + }, + "node_modules/@restart/ui/node_modules/@restart/hooks": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/@restart/hooks/-/hooks-0.5.1.tgz", + "integrity": "sha512-EMoH04NHS1pbn07iLTjIjgttuqb7qu4+/EyhAx27MHpoENcB2ZdSsLTNxmKD+WEPnZigo62Qc8zjGnNxoSE/5Q==", + "dependencies": { + "dequal": "^2.0.3" + }, + "peerDependencies": { + "react": ">=16.8.0" + } + }, + "node_modules/@restart/ui/node_modules/uncontrollable": { + "version": "8.0.4", + "resolved": "https://registry.npmjs.org/uncontrollable/-/uncontrollable-8.0.4.tgz", + "integrity": "sha512-ulRWYWHvscPFc0QQXvyJjY6LIXU56f0h8pQFvhxiKk5V1fcI8gp9Ht9leVAhrVjzqMw0BgjspBINx9r6oyJUvQ==", + "peerDependencies": { + "react": ">=16.14.0" + } + }, "node_modules/@rtsao/scc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", @@ -1239,6 +1315,11 @@ "node": ">=12" } }, + "node_modules/@types/prop-types": { + "version": "15.7.14", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.14.tgz", + "integrity": "sha512-gNMvNH49DJ7OJYv+KAKn0Xp45p8PLl6zo2YnvDIbTd4J6MER2BmWN49TG7n9LvkyihINxeKW8+3bfS2yDC9dzQ==" + }, "node_modules/@types/qs": { "version": "6.9.18", "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.18.tgz", @@ -1249,7 +1330,6 @@ "version": "19.0.2", "resolved": "https://registry.npmjs.org/@types/react/-/react-19.0.2.tgz", "integrity": "sha512-USU8ZI/xyKJwFTpjSVIrSeHBVAGagkHQKPNbxeWwql/vDmnTIBgx+TJnhFnj1NXgz8XfprU0egV2dROLGpsBEg==", - "dev": true, "dependencies": { "csstype": "^3.0.2" } @@ -1263,6 +1343,19 @@ "@types/react": "^19.0.0" } }, + "node_modules/@types/react-transition-group": { + "version": "4.4.12", + "resolved": "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.12.tgz", + "integrity": "sha512-8TV6R3h2j7a91c+1DXdJi3Syo69zzIZbz7Lg5tORM5LEJG7X/E6a1V3drRyBRZq7/utz7A+c4OgYLiLcYGHG6w==", + "peerDependencies": { + "@types/react": "*" + } + }, + "node_modules/@types/warning": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/warning/-/warning-3.0.3.tgz", + "integrity": "sha512-D1XC7WK8K+zZEveUPY+cf4+kgauk8N4eHr/XIHXGlGYkHLud6hK9lYfZk1ry1TNh798cZUCgb6MqGEG8DkJt6Q==" + }, "node_modules/@typescript-eslint/eslint-plugin": { "version": "8.19.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.19.0.tgz", @@ -1928,6 +2021,11 @@ "integrity": "sha512-GzIjNdcEtH4ieA2S8NmrSxv7DfEV5fmixQeyTmqmRmRJPGpRBaSnA2a0VrCjyT8iW8JjEdMbKzDotAJf+ajgaQ==", "license": "Unlicense" }, + "node_modules/classnames": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==" + }, "node_modules/client-only": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz", @@ -2005,8 +2103,7 @@ "node_modules/csstype": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", - "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", - "dev": true + "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==" }, "node_modules/damerau-levenshtein": { "version": "1.0.8", @@ -2122,6 +2219,14 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/dequal": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", + "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==", + "engines": { + "node": ">=6" + } + }, "node_modules/detect-libc": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.3.tgz", @@ -2143,6 +2248,15 @@ "node": ">=0.10.0" } }, + "node_modules/dom-helpers": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/dom-helpers/-/dom-helpers-5.2.1.tgz", + "integrity": "sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==", + "dependencies": { + "@babel/runtime": "^7.8.7", + "csstype": "^3.0.2" + } + }, "node_modules/dotenv": { "version": "16.4.7", "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.7.tgz", @@ -3202,6 +3316,14 @@ "node": ">= 0.4" } }, + "node_modules/invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "dependencies": { + "loose-envify": "^1.0.0" + } + }, "node_modules/is-array-buffer": { "version": "3.0.5", "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.5.tgz", @@ -3609,8 +3731,7 @@ "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" }, "node_modules/js-yaml": { "version": "4.1.0", @@ -3746,7 +3867,6 @@ "version": "1.4.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "dev": true, "dependencies": { "js-tokens": "^3.0.0 || ^4.0.0" }, @@ -3899,7 +4019,6 @@ "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", - "dev": true, "engines": { "node": ">=0.10.0" } @@ -4320,13 +4439,24 @@ "version": "15.8.1", "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz", "integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==", - "dev": true, "dependencies": { "loose-envify": "^1.4.0", "object-assign": "^4.1.1", "react-is": "^16.13.1" } }, + "node_modules/prop-types-extra": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/prop-types-extra/-/prop-types-extra-1.1.1.tgz", + "integrity": "sha512-59+AHNnHYCdiC+vMwY52WmvP5dM3QLeoumYuEyceQDi9aEhtwN9zIQ2ZNo25sMyXnbh32h+P1ezDsUpUH3JAew==", + "dependencies": { + "react-is": "^16.3.2", + "warning": "^4.0.0" + }, + "peerDependencies": { + "react": ">=0.14.0" + } + }, "node_modules/punycode": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", @@ -4379,6 +4509,36 @@ "node": ">=0.10.0" } }, + "node_modules/react-bootstrap": { + "version": "2.10.9", + "resolved": "https://registry.npmjs.org/react-bootstrap/-/react-bootstrap-2.10.9.tgz", + "integrity": "sha512-TJUCuHcxdgYpOqeWmRApM/Dy0+hVsxNRFvq2aRFQuxhNi/+ivOxC5OdWIeHS3agxvzJ4Ev4nDw2ZdBl9ymd/JQ==", + "dependencies": { + "@babel/runtime": "^7.24.7", + "@restart/hooks": "^0.4.9", + "@restart/ui": "^1.9.4", + "@types/prop-types": "^15.7.12", + "@types/react-transition-group": "^4.4.6", + "classnames": "^2.3.2", + "dom-helpers": "^5.2.1", + "invariant": "^2.2.4", + "prop-types": "^15.8.1", + "prop-types-extra": "^1.1.0", + "react-transition-group": "^4.4.5", + "uncontrollable": "^7.2.1", + "warning": "^4.0.3" + }, + "peerDependencies": { + "@types/react": ">=16.14.8", + "react": ">=16.14.0", + "react-dom": ">=16.14.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, "node_modules/react-dom": { "version": "19.0.0", "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.0.0.tgz", @@ -4393,8 +4553,27 @@ "node_modules/react-is": { "version": "16.13.1", "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", - "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", - "dev": true + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" + }, + "node_modules/react-lifecycles-compat": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/react-lifecycles-compat/-/react-lifecycles-compat-3.0.4.tgz", + "integrity": "sha512-fBASbA6LnOU9dOU2eW7aQ8xmYBSXUIWr+UmF9b1efZBazGNO+rcXT/icdKnYm2pTwcRylVUYwW7H1PHfLekVzA==" + }, + "node_modules/react-transition-group": { + "version": "4.4.5", + "resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz", + "integrity": "sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==", + "dependencies": { + "@babel/runtime": "^7.5.5", + "dom-helpers": "^5.0.1", + "loose-envify": "^1.4.0", + "prop-types": "^15.6.2" + }, + "peerDependencies": { + "react": ">=16.6.0", + "react-dom": ">=16.6.0" + } }, "node_modules/readdirp": { "version": "4.0.2", @@ -4432,6 +4611,11 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==" + }, "node_modules/regexp.prototype.flags": { "version": "1.5.3", "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.3.tgz", @@ -5151,6 +5335,20 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/uncontrollable": { + "version": "7.2.1", + "resolved": "https://registry.npmjs.org/uncontrollable/-/uncontrollable-7.2.1.tgz", + "integrity": "sha512-svtcfoTADIB0nT9nltgjujTi7BzVmwjZClOmskKu/E8FW9BXzg9os8OLr4f8Dlnk0rYWJIWr4wv9eKUXiQvQwQ==", + "dependencies": { + "@babel/runtime": "^7.6.3", + "@types/react": ">=16.9.11", + "invariant": "^2.2.4", + "react-lifecycles-compat": "^3.0.4" + }, + "peerDependencies": { + "react": ">=15.0.0" + } + }, "node_modules/undici-types": { "version": "6.19.8", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", @@ -5165,6 +5363,14 @@ "punycode": "^2.1.0" } }, + "node_modules/warning": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/warning/-/warning-4.0.3.tgz", + "integrity": "sha512-rpJyN222KWIvHJ/F53XSZv0Zl/accqHR8et1kpaMTD/fLCRxtV8iX8czMzY7sVZupTI3zcUTg8eycS2kNF9l6w==", + "dependencies": { + "loose-envify": "^1.0.0" + } + }, "node_modules/which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", diff --git a/yoga-app/package.json b/yoga-app/package.json index 9158f0e..1dffde8 100644 --- a/yoga-app/package.json +++ b/yoga-app/package.json @@ -28,6 +28,7 @@ "pg": "^8.13.1", "qs": "^6.14.0", "react": "^19.0.0", + "react-bootstrap": "^2.10.9", "react-dom": "^19.0.0" }, "devDependencies": { diff --git a/yoga-app/src/api/strapi/query/faq.json b/yoga-app/src/api/strapi/query/faq.json new file mode 100644 index 0000000..2d17349 --- /dev/null +++ b/yoga-app/src/api/strapi/query/faq.json @@ -0,0 +1,66 @@ +{ + "fields": ["*"], + "populate": { + "questionsAndAnswers": { + "fields": ["*"], + "populate": { + "questionsAndAnswers": { + "fields": ["*"] + } + } + }, + "achievements": { + "fields": ["*"], + "populate": { + "achievements": { + "fields": ["*"], + "populate": { + "image": { + "fields": ["name","mime","url"] + } + } + } + } + }, + + "blogs": { + "fields": ["*"], + "populate": { + "button": { + "fields": ["*"] + }, + "posts": { + "fields": ["name", "id", "header","documentId" ], + "populate": { + "tags": { + "fields": ["*" ] + }, + "teaserImage": { + "fields": ["name","mime","url"] + } + } + } + } + }, + "subscribe": { + "fields": ["*"] + }, + "footer": { + "fields": ["*"], + "populate": { + "links": { + "fields": ["*"] + }, + "contactUsEmail": { + "fields": ["*"] + }, + "contactUsLocation": { + "fields": ["*"] + }, + "contactUsPhoneNumber": { + "fields": ["*"] + } + } + } + } +} diff --git a/yoga-app/src/api/strapi/strapi-api.ts b/yoga-app/src/api/strapi/strapi-api.ts index 02c2a82..a312e27 100644 --- a/yoga-app/src/api/strapi/strapi-api.ts +++ b/yoga-app/src/api/strapi/strapi-api.ts @@ -5,10 +5,12 @@ import aboutQuery from "@/api/strapi/query/about.json"; import homeQuery from "@/api/strapi/query/home.json"; import servicesQuery from "@/api/strapi/query/services.json"; import pricesQuery from "@/api/strapi/query/prices.json"; +import faqQuery from "@/api/strapi/query/faq.json"; import {YogaBlogPost_Plain} from "@/types/generated-strapi-interfaces/api/yoga-blog-post"; import {Home_Plain} from "@/types/generated-strapi-interfaces/api/home"; import {ServicesPage_Plain} from "@/types/generated-strapi-interfaces/api/services-page"; import {PricesPage_Plain} from "@/types/generated-strapi-interfaces/api/prices-page"; +import {FaqPage_Plain} from "@/types/generated-strapi-interfaces/api/faq-page"; class StrapiApi{ @@ -42,6 +44,10 @@ class StrapiApi{ return this.getJson("/api/prices-page?",pricesQuery); } + public getFaqPage(): Promise{ + return this.getJson("/api/faq-page?",faqQuery); + } + public getBlog(blogId: string): Promise{ return this.getJson("/api/yoga-blog-posts/"+blogId,undefined); diff --git a/yoga-app/src/app/faq/page.tsx b/yoga-app/src/app/faq/page.tsx index 7cd76ce..b2d15ef 100644 --- a/yoga-app/src/app/faq/page.tsx +++ b/yoga-app/src/app/faq/page.tsx @@ -9,19 +9,26 @@ import FeedbackComponent from "@/components/feedbackComponent"; import BlogPostsComponent from "@/components/blog.posts.component"; import FooterComponent from "@/components/footer.component"; import SubscribeComponent from "@/components/subscribe.component"; +import strapiApi from "@/api/strapi/strapi-api"; +import SubHeaderComponent from "@/components/subHeader.component"; +import FaqComponent from "@/components/faq.component"; -export default function About() { +export default async function About() { + const { + header, + description, + questionsAndAnswers, + blogs, + subscribe, + footer + } = await strapiApi.getFaqPage(); return ( <> - - - - - - - - - + { } + { questionsAndAnswers && } + { blogs && } + { subscribe && } + { footer && } diff --git a/yoga-app/src/components/breadcrumbs.component.tsx b/yoga-app/src/components/breadcrumbs.component.tsx index 19474cd..8cc68b0 100644 --- a/yoga-app/src/components/breadcrumbs.component.tsx +++ b/yoga-app/src/components/breadcrumbs.component.tsx @@ -13,6 +13,7 @@ const pathToBreadCrumbs = (path: string) => { '/' : 'Kezdőlap', 'about' : 'Rólam', 'services' : 'Szolgáltatásaim', + 'prices' : 'Áraim', } if ( mapping.hasOwnProperty(path)){ return mapping[path]; diff --git a/yoga-app/src/components/faq.component.tsx b/yoga-app/src/components/faq.component.tsx new file mode 100644 index 0000000..439d1a2 --- /dev/null +++ b/yoga-app/src/components/faq.component.tsx @@ -0,0 +1,74 @@ +"use client" +import {YogaFaqComponent_Plain} from "@/types/generated-strapi-interfaces/api/yoga-faq-component"; +import {useState} from "react"; +import FaqQaComponent from "@/components/faq.qa.component"; +import { MouseEvent } from 'react' + + +export interface Props { + config: YogaFaqComponent_Plain +} + +export default function FaqComponent({ + config: { + title, + header, + description, + questionsAndAnswers + } + }: Props) { + + const [selectedQAs, setSelectedQAs] = useState([] as number[]); + + const onQAClick = (id: number) => { + if (selectedQAs.includes(id)) { + setSelectedQAs(prevState => { + return prevState.filter(value => value != id); + }) + } else { + setSelectedQAs(prevState => { + return [...prevState, id] + }) + } + } + return ( +
+
+
+
+
+
{title}
+

{header}

+

{description}

+
+
+
+
+
+
+
+
+
+ { + questionsAndAnswers.map((qa, index) => { + return ( + + ); + }) + } +
+
+
+
+
+
+
+
+ + ) +} diff --git a/yoga-app/src/components/faq.qa.component.tsx b/yoga-app/src/components/faq.qa.component.tsx new file mode 100644 index 0000000..e13ac69 --- /dev/null +++ b/yoga-app/src/components/faq.qa.component.tsx @@ -0,0 +1,50 @@ +import YogaImageComponent from "@/components/yoga.image.component"; +import {YogaFaqQa_Plain} from "@/types/generated-strapi-interfaces/api/yoga-faq-qa"; +import clsx from "clsx"; + +import classes from "./faq.qa.module.scss"; +import {useEffect, useState} from "react"; + +export interface Props{ + id: number, + qa: YogaFaqQa_Plain, + isOpen: boolean, + onClick: (id: number) => void +} +export default function FaqQaComponent({id,qa,isOpen,onClick}: Props){ + + + + return ( + + + ); +} diff --git a/yoga-app/src/components/faq.qa.module.scss b/yoga-app/src/components/faq.qa.module.scss new file mode 100644 index 0000000..548a5d5 --- /dev/null +++ b/yoga-app/src/components/faq.qa.module.scss @@ -0,0 +1,4 @@ + +.accordionBody{ + //transition: all 1s; +} diff --git a/yoga-app/src/types/generated-strapi-interfaces/api/faq-page.ts b/yoga-app/src/types/generated-strapi-interfaces/api/faq-page.ts new file mode 100644 index 0000000..fd323f8 --- /dev/null +++ b/yoga-app/src/types/generated-strapi-interfaces/api/faq-page.ts @@ -0,0 +1,58 @@ +// Interface automatically generated by schemas-to-ts + +import { YogaFaqComponent } from './yoga-faq-component'; +import { YogaAchivementsComponent } from './yoga-achivements-component'; +import { YogaBlogPostsComponent } from './yoga-blog-posts-component'; +import { YogaSubscribeNowComponent } from './yoga-subscribe-now-component'; +import { YogaFooter } from './yoga-footer'; +import { YogaFaqComponent_Plain } from './yoga-faq-component'; +import { YogaAchivementsComponent_Plain } from './yoga-achivements-component'; +import { YogaBlogPostsComponent_Plain } from './yoga-blog-posts-component'; +import { YogaSubscribeNowComponent_Plain } from './yoga-subscribe-now-component'; +import { YogaFooter_Plain } from './yoga-footer'; +import { AdminPanelRelationPropertyModification } from '../common/AdminPanelRelationPropertyModification'; + +export interface FaqPage { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: { data: YogaFaqComponent }; + achievements?: { data: YogaAchivementsComponent }; + blogs?: { data: YogaBlogPostsComponent }; + subscribe?: { data: YogaSubscribeNowComponent }; + footer?: { data: YogaFooter }; + }; +} +export interface FaqPage_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: YogaFaqComponent_Plain; + achievements?: YogaAchivementsComponent_Plain; + blogs?: YogaBlogPostsComponent_Plain; + subscribe?: YogaSubscribeNowComponent_Plain; + footer?: YogaFooter_Plain; +} + +export interface FaqPage_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: number; + achievements?: number; + blogs?: number; + subscribe?: number; + footer?: number; +} + +export interface FaqPage_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: AdminPanelRelationPropertyModification; + achievements?: AdminPanelRelationPropertyModification; + blogs?: AdminPanelRelationPropertyModification; + subscribe?: AdminPanelRelationPropertyModification; + footer?: AdminPanelRelationPropertyModification; +} diff --git a/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-component.ts b/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-component.ts new file mode 100644 index 0000000..88d4eb6 --- /dev/null +++ b/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-component.ts @@ -0,0 +1,38 @@ +// Interface automatically generated by schemas-to-ts + +import { YogaFaqQa } from './yoga-faq-qa'; +import { YogaFaqQa_Plain } from './yoga-faq-qa'; +import { AdminPanelRelationPropertyModification } from '../common/AdminPanelRelationPropertyModification'; + +export interface YogaFaqComponent { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: { data: YogaFaqQa[] }; + }; +} +export interface YogaFaqComponent_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: YogaFaqQa_Plain[]; +} + +export interface YogaFaqComponent_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: number[]; +} + +export interface YogaFaqComponent_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: AdminPanelRelationPropertyModification; +} diff --git a/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-qa.ts b/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-qa.ts new file mode 100644 index 0000000..1586905 --- /dev/null +++ b/yoga-app/src/types/generated-strapi-interfaces/api/yoga-faq-qa.ts @@ -0,0 +1,30 @@ +// Interface automatically generated by schemas-to-ts + +export interface YogaFaqQa { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; + }; +} +export interface YogaFaqQa_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} + +export interface YogaFaqQa_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} + +export interface YogaFaqQa_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} diff --git a/yoga-cms/generated-strapi-interfaces/api/faq-page.ts b/yoga-cms/generated-strapi-interfaces/api/faq-page.ts new file mode 100644 index 0000000..fd323f8 --- /dev/null +++ b/yoga-cms/generated-strapi-interfaces/api/faq-page.ts @@ -0,0 +1,58 @@ +// Interface automatically generated by schemas-to-ts + +import { YogaFaqComponent } from './yoga-faq-component'; +import { YogaAchivementsComponent } from './yoga-achivements-component'; +import { YogaBlogPostsComponent } from './yoga-blog-posts-component'; +import { YogaSubscribeNowComponent } from './yoga-subscribe-now-component'; +import { YogaFooter } from './yoga-footer'; +import { YogaFaqComponent_Plain } from './yoga-faq-component'; +import { YogaAchivementsComponent_Plain } from './yoga-achivements-component'; +import { YogaBlogPostsComponent_Plain } from './yoga-blog-posts-component'; +import { YogaSubscribeNowComponent_Plain } from './yoga-subscribe-now-component'; +import { YogaFooter_Plain } from './yoga-footer'; +import { AdminPanelRelationPropertyModification } from '../common/AdminPanelRelationPropertyModification'; + +export interface FaqPage { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: { data: YogaFaqComponent }; + achievements?: { data: YogaAchivementsComponent }; + blogs?: { data: YogaBlogPostsComponent }; + subscribe?: { data: YogaSubscribeNowComponent }; + footer?: { data: YogaFooter }; + }; +} +export interface FaqPage_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: YogaFaqComponent_Plain; + achievements?: YogaAchivementsComponent_Plain; + blogs?: YogaBlogPostsComponent_Plain; + subscribe?: YogaSubscribeNowComponent_Plain; + footer?: YogaFooter_Plain; +} + +export interface FaqPage_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: number; + achievements?: number; + blogs?: number; + subscribe?: number; + footer?: number; +} + +export interface FaqPage_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; header?: string; + description?: string; + questionsAndAnswers?: AdminPanelRelationPropertyModification; + achievements?: AdminPanelRelationPropertyModification; + blogs?: AdminPanelRelationPropertyModification; + subscribe?: AdminPanelRelationPropertyModification; + footer?: AdminPanelRelationPropertyModification; +} diff --git a/yoga-cms/generated-strapi-interfaces/api/yoga-faq-component.ts b/yoga-cms/generated-strapi-interfaces/api/yoga-faq-component.ts new file mode 100644 index 0000000..88d4eb6 --- /dev/null +++ b/yoga-cms/generated-strapi-interfaces/api/yoga-faq-component.ts @@ -0,0 +1,38 @@ +// Interface automatically generated by schemas-to-ts + +import { YogaFaqQa } from './yoga-faq-qa'; +import { YogaFaqQa_Plain } from './yoga-faq-qa'; +import { AdminPanelRelationPropertyModification } from '../common/AdminPanelRelationPropertyModification'; + +export interface YogaFaqComponent { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: { data: YogaFaqQa[] }; + }; +} +export interface YogaFaqComponent_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: YogaFaqQa_Plain[]; +} + +export interface YogaFaqComponent_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: number[]; +} + +export interface YogaFaqComponent_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; title?: string; + header?: string; + description?: string; + questionsAndAnswers: AdminPanelRelationPropertyModification; +} diff --git a/yoga-cms/generated-strapi-interfaces/api/yoga-faq-qa.ts b/yoga-cms/generated-strapi-interfaces/api/yoga-faq-qa.ts new file mode 100644 index 0000000..1586905 --- /dev/null +++ b/yoga-cms/generated-strapi-interfaces/api/yoga-faq-qa.ts @@ -0,0 +1,30 @@ +// Interface automatically generated by schemas-to-ts + +export interface YogaFaqQa { + id: number; + attributes: { + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; + }; +} +export interface YogaFaqQa_Plain { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} + +export interface YogaFaqQa_NoRelations { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} + +export interface YogaFaqQa_AdminPanelLifeCycle { + id: number; + createdAt: Date; updatedAt: Date; publishedAt?: Date; name?: string; + question?: string; + answer?: string; +} diff --git a/yoga-cms/src/api/faq-page/content-types/faq-page/schema.json b/yoga-cms/src/api/faq-page/content-types/faq-page/schema.json new file mode 100644 index 0000000..f584e49 --- /dev/null +++ b/yoga-cms/src/api/faq-page/content-types/faq-page/schema.json @@ -0,0 +1,47 @@ +{ + "kind": "singleType", + "collectionName": "faq_pages", + "info": { + "singularName": "faq-page", + "pluralName": "faq-pages", + "displayName": "FAQPage", + "description": "" + }, + "options": { + "draftAndPublish": true + }, + "pluginOptions": {}, + "attributes": { + "header": { + "type": "string" + }, + "description": { + "type": "string" + }, + "questionsAndAnswers": { + "type": "relation", + "relation": "oneToOne", + "target": "api::yoga-faq-component.yoga-faq-component" + }, + "achievements": { + "type": "relation", + "relation": "oneToOne", + "target": "api::yoga-achivements-component.yoga-achivements-component" + }, + "blogs": { + "type": "relation", + "relation": "oneToOne", + "target": "api::yoga-blog-posts-component.yoga-blog-posts-component" + }, + "subscribe": { + "type": "relation", + "relation": "oneToOne", + "target": "api::yoga-subscribe-now-component.yoga-subscribe-now-component" + }, + "footer": { + "type": "relation", + "relation": "oneToOne", + "target": "api::yoga-footer.yoga-footer" + } + } +} diff --git a/yoga-cms/src/api/faq-page/controllers/faq-page.ts b/yoga-cms/src/api/faq-page/controllers/faq-page.ts new file mode 100644 index 0000000..40b557b --- /dev/null +++ b/yoga-cms/src/api/faq-page/controllers/faq-page.ts @@ -0,0 +1,7 @@ +/** + * faq-page controller + */ + +import { factories } from '@strapi/strapi' + +export default factories.createCoreController('api::faq-page.faq-page'); diff --git a/yoga-cms/src/api/faq-page/routes/faq-page.ts b/yoga-cms/src/api/faq-page/routes/faq-page.ts new file mode 100644 index 0000000..124dee5 --- /dev/null +++ b/yoga-cms/src/api/faq-page/routes/faq-page.ts @@ -0,0 +1,7 @@ +/** + * faq-page router + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreRouter('api::faq-page.faq-page'); diff --git a/yoga-cms/src/api/faq-page/services/faq-page.ts b/yoga-cms/src/api/faq-page/services/faq-page.ts new file mode 100644 index 0000000..8898523 --- /dev/null +++ b/yoga-cms/src/api/faq-page/services/faq-page.ts @@ -0,0 +1,7 @@ +/** + * faq-page service + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreService('api::faq-page.faq-page'); diff --git a/yoga-cms/src/api/yoga-faq-component/content-types/yoga-faq-component/schema.json b/yoga-cms/src/api/yoga-faq-component/content-types/yoga-faq-component/schema.json new file mode 100644 index 0000000..5e787d0 --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-component/content-types/yoga-faq-component/schema.json @@ -0,0 +1,30 @@ +{ + "kind": "collectionType", + "collectionName": "yoga_faq_components", + "info": { + "singularName": "yoga-faq-component", + "pluralName": "yoga-faq-components", + "displayName": "YogaFAQComponent", + "description": "" + }, + "options": { + "draftAndPublish": true + }, + "pluginOptions": {}, + "attributes": { + "title": { + "type": "string" + }, + "header": { + "type": "string" + }, + "description": { + "type": "text" + }, + "questionsAndAnswers": { + "type": "relation", + "relation": "oneToMany", + "target": "api::yoga-faq-qa.yoga-faq-qa" + } + } +} diff --git a/yoga-cms/src/api/yoga-faq-component/controllers/yoga-faq-component.ts b/yoga-cms/src/api/yoga-faq-component/controllers/yoga-faq-component.ts new file mode 100644 index 0000000..42074a8 --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-component/controllers/yoga-faq-component.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-component controller + */ + +import { factories } from '@strapi/strapi' + +export default factories.createCoreController('api::yoga-faq-component.yoga-faq-component'); diff --git a/yoga-cms/src/api/yoga-faq-component/routes/yoga-faq-component.ts b/yoga-cms/src/api/yoga-faq-component/routes/yoga-faq-component.ts new file mode 100644 index 0000000..5b8c955 --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-component/routes/yoga-faq-component.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-component router + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreRouter('api::yoga-faq-component.yoga-faq-component'); diff --git a/yoga-cms/src/api/yoga-faq-component/services/yoga-faq-component.ts b/yoga-cms/src/api/yoga-faq-component/services/yoga-faq-component.ts new file mode 100644 index 0000000..7847ea1 --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-component/services/yoga-faq-component.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-component service + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreService('api::yoga-faq-component.yoga-faq-component'); diff --git a/yoga-cms/src/api/yoga-faq-qa/content-types/yoga-faq-qa/schema.json b/yoga-cms/src/api/yoga-faq-qa/content-types/yoga-faq-qa/schema.json new file mode 100644 index 0000000..7fbf18c --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-qa/content-types/yoga-faq-qa/schema.json @@ -0,0 +1,24 @@ +{ + "kind": "collectionType", + "collectionName": "yoga_faq_qas", + "info": { + "singularName": "yoga-faq-qa", + "pluralName": "yoga-faq-qas", + "displayName": "YogaFAQQA" + }, + "options": { + "draftAndPublish": true + }, + "pluginOptions": {}, + "attributes": { + "name": { + "type": "string" + }, + "question": { + "type": "string" + }, + "answer": { + "type": "text" + } + } +} diff --git a/yoga-cms/src/api/yoga-faq-qa/controllers/yoga-faq-qa.ts b/yoga-cms/src/api/yoga-faq-qa/controllers/yoga-faq-qa.ts new file mode 100644 index 0000000..89c715d --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-qa/controllers/yoga-faq-qa.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-qa controller + */ + +import { factories } from '@strapi/strapi' + +export default factories.createCoreController('api::yoga-faq-qa.yoga-faq-qa'); diff --git a/yoga-cms/src/api/yoga-faq-qa/routes/yoga-faq-qa.ts b/yoga-cms/src/api/yoga-faq-qa/routes/yoga-faq-qa.ts new file mode 100644 index 0000000..cea2997 --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-qa/routes/yoga-faq-qa.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-qa router + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreRouter('api::yoga-faq-qa.yoga-faq-qa'); diff --git a/yoga-cms/src/api/yoga-faq-qa/services/yoga-faq-qa.ts b/yoga-cms/src/api/yoga-faq-qa/services/yoga-faq-qa.ts new file mode 100644 index 0000000..2e6a00c --- /dev/null +++ b/yoga-cms/src/api/yoga-faq-qa/services/yoga-faq-qa.ts @@ -0,0 +1,7 @@ +/** + * yoga-faq-qa service + */ + +import { factories } from '@strapi/strapi'; + +export default factories.createCoreService('api::yoga-faq-qa.yoga-faq-qa'); diff --git a/yoga-cms/types/generated/contentTypes.d.ts b/yoga-cms/types/generated/contentTypes.d.ts index 5400735..6a8192b 100644 --- a/yoga-cms/types/generated/contentTypes.d.ts +++ b/yoga-cms/types/generated/contentTypes.d.ts @@ -540,6 +540,56 @@ export interface ApiCategoryCategory extends Struct.CollectionTypeSchema { }; } +export interface ApiFaqPageFaqPage extends Struct.SingleTypeSchema { + collectionName: 'faq_pages'; + info: { + description: ''; + displayName: 'FAQPage'; + pluralName: 'faq-pages'; + singularName: 'faq-page'; + }; + options: { + draftAndPublish: true; + }; + attributes: { + achievements: Schema.Attribute.Relation< + 'oneToOne', + 'api::yoga-achivements-component.yoga-achivements-component' + >; + blogs: Schema.Attribute.Relation< + 'oneToOne', + 'api::yoga-blog-posts-component.yoga-blog-posts-component' + >; + createdAt: Schema.Attribute.DateTime; + createdBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + description: Schema.Attribute.String; + footer: Schema.Attribute.Relation< + 'oneToOne', + 'api::yoga-footer.yoga-footer' + >; + header: Schema.Attribute.String; + locale: Schema.Attribute.String & Schema.Attribute.Private; + localizations: Schema.Attribute.Relation< + 'oneToMany', + 'api::faq-page.faq-page' + > & + Schema.Attribute.Private; + publishedAt: Schema.Attribute.DateTime; + questionsAndAnswers: Schema.Attribute.Relation< + 'oneToOne', + 'api::yoga-faq-component.yoga-faq-component' + >; + subscribe: Schema.Attribute.Relation< + 'oneToOne', + 'api::yoga-subscribe-now-component.yoga-subscribe-now-component' + >; + updatedAt: Schema.Attribute.DateTime; + updatedBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + }; +} + export interface ApiGlobalGlobal extends Struct.SingleTypeSchema { collectionName: 'globals'; info: { @@ -1253,6 +1303,72 @@ export interface ApiYogaDiscountComponentYogaDiscountComponent }; } +export interface ApiYogaFaqComponentYogaFaqComponent + extends Struct.CollectionTypeSchema { + collectionName: 'yoga_faq_components'; + info: { + description: ''; + displayName: 'YogaFAQComponent'; + pluralName: 'yoga-faq-components'; + singularName: 'yoga-faq-component'; + }; + options: { + draftAndPublish: true; + }; + attributes: { + createdAt: Schema.Attribute.DateTime; + createdBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + description: Schema.Attribute.Text; + header: Schema.Attribute.String; + locale: Schema.Attribute.String & Schema.Attribute.Private; + localizations: Schema.Attribute.Relation< + 'oneToMany', + 'api::yoga-faq-component.yoga-faq-component' + > & + Schema.Attribute.Private; + publishedAt: Schema.Attribute.DateTime; + questionsAndAnswers: Schema.Attribute.Relation< + 'oneToMany', + 'api::yoga-faq-qa.yoga-faq-qa' + >; + title: Schema.Attribute.String; + updatedAt: Schema.Attribute.DateTime; + updatedBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + }; +} + +export interface ApiYogaFaqQaYogaFaqQa extends Struct.CollectionTypeSchema { + collectionName: 'yoga_faq_qas'; + info: { + displayName: 'YogaFAQQA'; + pluralName: 'yoga-faq-qas'; + singularName: 'yoga-faq-qa'; + }; + options: { + draftAndPublish: true; + }; + attributes: { + answer: Schema.Attribute.Text; + createdAt: Schema.Attribute.DateTime; + createdBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + locale: Schema.Attribute.String & Schema.Attribute.Private; + localizations: Schema.Attribute.Relation< + 'oneToMany', + 'api::yoga-faq-qa.yoga-faq-qa' + > & + Schema.Attribute.Private; + name: Schema.Attribute.String; + publishedAt: Schema.Attribute.DateTime; + question: Schema.Attribute.String; + updatedAt: Schema.Attribute.DateTime; + updatedBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> & + Schema.Attribute.Private; + }; +} + export interface ApiYogaFooterYogaFooter extends Struct.CollectionTypeSchema { collectionName: 'yoga_footers'; info: { @@ -2297,6 +2413,7 @@ declare module '@strapi/strapi' { 'api::article.article': ApiArticleArticle; 'api::author.author': ApiAuthorAuthor; 'api::category.category': ApiCategoryCategory; + 'api::faq-page.faq-page': ApiFaqPageFaqPage; 'api::global.global': ApiGlobalGlobal; 'api::home.home': ApiHomeHome; 'api::page.page': ApiPagePage; @@ -2313,6 +2430,8 @@ declare module '@strapi/strapi' { 'api::yoga-customer-feedback-component.yoga-customer-feedback-component': ApiYogaCustomerFeedbackComponentYogaCustomerFeedbackComponent; 'api::yoga-customer-feedback.yoga-customer-feedback': ApiYogaCustomerFeedbackYogaCustomerFeedback; 'api::yoga-discount-component.yoga-discount-component': ApiYogaDiscountComponentYogaDiscountComponent; + 'api::yoga-faq-component.yoga-faq-component': ApiYogaFaqComponentYogaFaqComponent; + 'api::yoga-faq-qa.yoga-faq-qa': ApiYogaFaqQaYogaFaqQa; 'api::yoga-footer.yoga-footer': ApiYogaFooterYogaFooter; 'api::yoga-main-header-component.yoga-main-header-component': ApiYogaMainHeaderComponentYogaMainHeaderComponent; 'api::yoga-our-services-component.yoga-our-services-component': ApiYogaOurServicesComponentYogaOurServicesComponent;