From a6362685baeb3b3c5068cde3bb499dcc50d6ffc4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Mon, 16 Oct 2023 13:11:12 +0100 Subject: [PATCH 01/13] chore: Bump API memory (and CPU) (#2312) --- infrastructure/application/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/infrastructure/application/index.ts b/infrastructure/application/index.ts index 6b23995a7b..b29e8a1710 100644 --- a/infrastructure/application/index.ts +++ b/infrastructure/application/index.ts @@ -285,7 +285,7 @@ export = async () => { context: "../../api.planx.uk", target: "production", }), - memory: 2048 /*MB*/, + memory: 4096 /*MB*/, portMappings: [apiListenerHttp], environment: [ { name: "NODE_ENV", value: env }, From 102393e989978c9cf691c2adbcad1faea08ecd14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Tue, 17 Oct 2023 10:08:26 +0100 Subject: [PATCH 02/13] fix: Disable grant_new_user_template_team_access trigger in DB sync (#2315) --- scripts/seed-database/write/users.sql | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/seed-database/write/users.sql b/scripts/seed-database/write/users.sql index d814f880fc..adcd172074 100644 --- a/scripts/seed-database/write/users.sql +++ b/scripts/seed-database/write/users.sql @@ -11,6 +11,11 @@ CREATE TEMPORARY TABLE sync_users ( \copy sync_users FROM '/tmp/users.csv' WITH (FORMAT csv, DELIMITER ';'); +-- Do not automatically generate team_member records for the templates team +-- We manually truncate and replace the team_members table in another step +ALTER TABLE + users DISABLE TRIGGER grant_new_user_template_team_access; + INSERT INTO users ( id, first_name, @@ -27,4 +32,7 @@ SELECT FROM sync_users ON CONFLICT (id) DO NOTHING; +ALTER TABLE + users ENABLE TRIGGER grant_new_user_template_team_access; + SELECT setval('users_id_seq', max(id)) FROM users; From bf52435ce4e891b57c1d7c70de330c602f685a06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Tue, 17 Oct 2023 10:18:18 +0100 Subject: [PATCH 03/13] feat: Explicitly handle redaction (#2313) * chore: Handle redactions more explicitly * test: Update tests * chore: Bump planx-core --- api.planx.uk/admin/session/bops.test.ts | 4 +- api.planx.uk/admin/session/bops.ts | 2 +- api.planx.uk/admin/session/csv.test.ts | 17 +- api.planx.uk/admin/session/csv.ts | 4 +- api.planx.uk/admin/session/html.ts | 4 +- api.planx.uk/admin/session/oneAppXML.test.ts | 4 +- api.planx.uk/admin/session/oneAppXML.ts | 2 +- api.planx.uk/package.json | 2 +- api.planx.uk/pnpm-lock.yaml | 154 ++++++++--------- api.planx.uk/send/bops.ts | 2 +- api.planx.uk/send/email.test.ts | 17 +- api.planx.uk/send/exportZip.test.ts | 20 +-- api.planx.uk/send/exportZip.ts | 5 +- api.planx.uk/send/uniform.ts | 2 +- e2e/tests/api-driven/package.json | 2 +- e2e/tests/api-driven/pnpm-lock.yaml | 139 ++++++++------- e2e/tests/ui-driven/package.json | 2 +- e2e/tests/ui-driven/pnpm-lock.yaml | 139 ++++++++------- editor.planx.uk/package.json | 2 +- editor.planx.uk/pnpm-lock.yaml | 167 +++++++++++-------- 20 files changed, 370 insertions(+), 320 deletions(-) diff --git a/api.planx.uk/admin/session/bops.test.ts b/api.planx.uk/admin/session/bops.test.ts index 825ff8ce6e..5665ae9c09 100644 --- a/api.planx.uk/admin/session/bops.test.ts +++ b/api.planx.uk/admin/session/bops.test.ts @@ -6,9 +6,7 @@ import { expectedPayload } from "../../tests/mocks/bopsMocks"; const endpoint = (strings: TemplateStringsArray) => `/admin/session/${strings[0]}/bops`; -const mockGenerateBOPSPayload = jest.fn().mockResolvedValue({ - exportData: expectedPayload, -}); +const mockGenerateBOPSPayload = jest.fn().mockResolvedValue(expectedPayload); jest.mock("@opensystemslab/planx-core", () => { return { diff --git a/api.planx.uk/admin/session/bops.ts b/api.planx.uk/admin/session/bops.ts index 56d2e78f8f..09a44a43c2 100644 --- a/api.planx.uk/admin/session/bops.ts +++ b/api.planx.uk/admin/session/bops.ts @@ -20,7 +20,7 @@ export const getBOPSPayload = async ( next: NextFunction, ) => { try { - const { exportData } = await $api.export.bopsPayload(req.params.sessionId); + const exportData = await $api.export.bopsPayload(req.params.sessionId); res.set("content-type", "application/json"); return res.send(exportData); } catch (error) { diff --git a/api.planx.uk/admin/session/csv.test.ts b/api.planx.uk/admin/session/csv.test.ts index a493fb410d..a40152a272 100644 --- a/api.planx.uk/admin/session/csv.test.ts +++ b/api.planx.uk/admin/session/csv.test.ts @@ -5,16 +5,13 @@ import { authHeader } from "../../tests/mockJWT"; const endpoint = (strings: TemplateStringsArray) => `/admin/session/${strings[0]}/csv`; -const mockGenerateCSVData = jest.fn().mockResolvedValue({ - responses: [ - { - question: "Is this a test?", - responses: [{ value: "Yes" }], - metadata: {}, - }, - ], - redactedResponses: [], -}); +const mockGenerateCSVData = jest.fn().mockResolvedValue([ + { + question: "Is this a test?", + responses: [{ value: "Yes" }], + metadata: {}, + }, +]); jest.mock("@opensystemslab/planx-core", () => { return { CoreDomainClient: jest.fn().mockImplementation(() => ({ diff --git a/api.planx.uk/admin/session/csv.ts b/api.planx.uk/admin/session/csv.ts index 06d0bb00be..df4d348f45 100644 --- a/api.planx.uk/admin/session/csv.ts +++ b/api.planx.uk/admin/session/csv.ts @@ -27,7 +27,7 @@ export async function getCSVData( ) { try { const $client = getClient(); - const { responses } = await $client.export.csvData(req.params.sessionId); + const responses = await $client.export.csvData(req.params.sessionId); if (req.query?.download) { stringify(responses, { @@ -71,7 +71,7 @@ export async function getRedactedCSVData( ) { try { const $client = getClient(); - const { redactedResponses } = await $client.export.csvData( + const redactedResponses = await $client.export.csvDataRedacted( req.params.sessionId, ); diff --git a/api.planx.uk/admin/session/html.ts b/api.planx.uk/admin/session/html.ts index 52560d79da..a83a5e8245 100644 --- a/api.planx.uk/admin/session/html.ts +++ b/api.planx.uk/admin/session/html.ts @@ -24,7 +24,7 @@ export const getHTMLExport: HTMLExportHandler = async (req, res, next) => { const session = await $client.session.find(req.params.sessionId); if (!session) throw Error(`Unable to find session ${req.params.sessionId}`); - const { responses } = await $client.export.csvData(req.params.sessionId); + const responses = await $client.export.csvData(req.params.sessionId); const boundingBox = session.data.passport.data["property.boundary.site.buffered"]; @@ -65,7 +65,7 @@ export const getRedactedHTMLExport: HTMLExportHandler = async ( const session = await $client.session.find(req.params.sessionId); if (!session) throw Error(`Unable to find session ${req.params.sessionId}`); - const { redactedResponses } = await $client.export.csvData( + const redactedResponses = await $client.export.csvDataRedacted( req.params.sessionId, ); const boundingBox = diff --git a/api.planx.uk/admin/session/oneAppXML.test.ts b/api.planx.uk/admin/session/oneAppXML.test.ts index 8a67e626b2..4b8dc3bfe3 100644 --- a/api.planx.uk/admin/session/oneAppXML.test.ts +++ b/api.planx.uk/admin/session/oneAppXML.test.ts @@ -12,7 +12,9 @@ const mockGenerateOneAppXML = jest jest.mock("../../client", () => { return { $api: { - generateOneAppXML: () => mockGenerateOneAppXML(), + export: { + oneAppPayload: () => mockGenerateOneAppXML(), + }, }, }; }); diff --git a/api.planx.uk/admin/session/oneAppXML.ts b/api.planx.uk/admin/session/oneAppXML.ts index d1c1e51fb8..7b1ef90601 100644 --- a/api.planx.uk/admin/session/oneAppXML.ts +++ b/api.planx.uk/admin/session/oneAppXML.ts @@ -20,7 +20,7 @@ export const getOneAppXML = async ( next: NextFunction, ) => { try { - const xml = await $api.generateOneAppXML(req.params.sessionId); + const xml = await $api.export.oneAppPayload(req.params.sessionId); res.set("content-type", "text/xml"); return res.send(xml); } catch (error) { diff --git a/api.planx.uk/package.json b/api.planx.uk/package.json index a8d81c4717..2c9e8c3c74 100644 --- a/api.planx.uk/package.json +++ b/api.planx.uk/package.json @@ -4,7 +4,7 @@ "private": true, "dependencies": { "@airbrake/node": "^2.1.8", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#d92224b", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", "@types/isomorphic-fetch": "^0.0.36", "adm-zip": "^0.5.10", "aws-sdk": "^2.1467.0", diff --git a/api.planx.uk/pnpm-lock.yaml b/api.planx.uk/pnpm-lock.yaml index 7948276e87..7129f470f5 100644 --- a/api.planx.uk/pnpm-lock.yaml +++ b/api.planx.uk/pnpm-lock.yaml @@ -9,8 +9,8 @@ dependencies: specifier: ^2.1.8 version: 2.1.8 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#d92224b - version: github.com/theopensystemslab/planx-core/d92224b + specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 + version: github.com/theopensystemslab/planx-core/3a85966 '@types/isomorphic-fetch': specifier: ^0.0.36 version: 0.0.36 @@ -743,18 +743,18 @@ packages: - supports-color dev: true - /@babel/runtime@7.22.15: - resolution: {integrity: sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==} + /@babel/runtime@7.22.6: + resolution: {integrity: sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ==} engines: {node: '>=6.9.0'} dependencies: - regenerator-runtime: 0.14.0 + regenerator-runtime: 0.13.11 dev: false - /@babel/runtime@7.22.6: - resolution: {integrity: sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ==} + /@babel/runtime@7.23.2: + resolution: {integrity: sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg==} engines: {node: '>=6.9.0'} dependencies: - regenerator-runtime: 0.13.11 + regenerator-runtime: 0.14.0 dev: false /@babel/template@7.22.5: @@ -844,7 +844,7 @@ packages: resolution: {integrity: sha512-m4HEDZleaaCH+XgDDsPF15Ht6wTLsgDTeR3WYj9Q/k76JtWhrJjcP4+/XlG8LGT/Rol9qUfOIztXeA84ATpqPQ==} dependencies: '@babel/helper-module-imports': 7.22.5 - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/hash': 0.9.1 '@emotion/memoize': 0.8.1 '@emotion/serialize': 1.1.2 @@ -891,7 +891,7 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/cache': 11.11.0 '@emotion/serialize': 1.1.2 @@ -928,7 +928,7 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/is-prop-valid': 1.2.1 '@emotion/react': 11.11.1(react@18.2.0) @@ -1169,13 +1169,13 @@ packages: eslint-visitor-keys: 3.4.3 dev: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.50.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.51.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.50.0 + eslint: 8.51.0 eslint-visitor-keys: 3.4.3 dev: false @@ -1209,8 +1209,8 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@eslint/js@8.50.0: - resolution: {integrity: sha512-NCC3zz2+nvYd+Ckfh87rA47zfu2QsQpvc6k1yzTk+b9KzRj0wkGa8LSoGOXN6Zv4lRf/EIoZ80biDh9HOI+RNQ==} + /@eslint/js@8.51.0: + resolution: {integrity: sha512-HxjQ8Qn+4SI3/AFv6sOrDB+g6PpUTDwSJiQqOrnneEk8L71161srI9gjzzZvYVbzHiVg/BvcH95+cK/zfIt4pg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: false @@ -1624,8 +1624,8 @@ packages: resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} dev: false - /@mui/base@5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-xNbk7iOXrglNdIxFBN0k3ySsPIFLWCnFxqsAYl7CIcDkD9low4kJ7IUuy6ctwx/HAy2fenrT3KXHr1sGjAMgpQ==} + /@mui/base@5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-maNBgAscddyPNzFZQUJDF/puxM27Li+NqSBsr/lAP8TLns2VvWS2SoL3OKFOIoRnAMKGY/Ic6Aot6gCYeQnssA==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -1639,10 +1639,10 @@ packages: react-dom: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@floating-ui/react-dom': 2.0.2(react-dom@18.2.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) '@popperjs/core': 2.11.8 clsx: 2.0.0 prop-types: 15.8.1 @@ -1650,12 +1650,12 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false - /@mui/core-downloads-tracker@5.14.11: - resolution: {integrity: sha512-uY8FLQURhXe3f3O4dS5OSGML9KDm9+IE226cBu78jarVIzdQGPlXwGIlSI9VJR8MvZDA6C0+6XfWDhWCHruC5Q==} + /@mui/core-downloads-tracker@5.14.13: + resolution: {integrity: sha512-3ZUbzcH4yloLKlV6Y+S0Edn2wef9t+EGHSfEkwVCn8E0ULdshifEFgfEroKRegQifDIwcKS/ofccxuZ8njTAYg==} dev: false - /@mui/material@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-DnSdJzcR7lwG12JA5L2t8JF+RDzMygu5rCNW+logWb/KW2/TRzwLyVWO+CorHTBjBRd38DBxnwOCDiYkDd+N3A==} + /@mui/material@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-iPEFwhoVG789UVsXX4gqd1eJUlcLW1oceqwJYQN8Z4MpcAKfL9Lv3fda65AwG7pQ5lf+d7IbHzm4m48SWZxI2g==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -1675,15 +1675,15 @@ packages: react-dom: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/base': 5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0) - '@mui/core-downloads-tracker': 5.14.11 - '@mui/system': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) - '@types/react-transition-group': 4.4.6 + '@mui/base': 5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0) + '@mui/core-downloads-tracker': 5.14.13 + '@mui/system': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) + '@types/react-transition-group': 4.4.7 clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 @@ -1693,8 +1693,8 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - /@mui/private-theming@5.14.11(react@18.2.0): - resolution: {integrity: sha512-MSnNNzTu9pfKLCKs1ZAKwOTgE4bz+fQA0fNr8Jm7NDmuWmw0CaN9Vq2/MHsatE7+S0A25IAKby46Uv1u53rKVQ==} + /@mui/private-theming@5.14.13(react@18.2.0): + resolution: {integrity: sha512-5EFqk4tqiSwPguj4NW/6bUf4u1qoUWXy9lrKfNh9H6oAohM+Ijv/7qSxFjnxPGBctj469/Sc5aKAR35ILBKZLQ==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -1705,14 +1705,14 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 - '@mui/utils': 5.14.11(react@18.2.0) + '@babel/runtime': 7.23.2 + '@mui/utils': 5.14.13(react@18.2.0) prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/styled-engine@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-jdUlqRgTYQ8RMtPX4MbRZqar6W2OiIb6J5KEFbIu4FqvPrk44Each4ppg/LAqp1qNlBYq5i+7Q10MYLMpDxX9A==} + /@mui/styled-engine@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-1ff/egFQl26hiwcUtCMKAkp4Sgqpm3qIewmXq+GN27fb44lDIACquehMFBuadOjceOFmbIXbayzbA46ZyqFYzA==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.4.1 @@ -1726,7 +1726,7 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/cache': 11.11.0 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) @@ -1735,8 +1735,8 @@ packages: react: 18.2.0 dev: false - /@mui/system@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-yl8xV+y0k7j6dzBsHabKwoShmjqLa8kTxrhUI3JpqLG358VRVMJRW/ES0HhvfcCi4IVXde+Tc2P3K1akGL8zoA==} + /@mui/system@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-+5+Dx50lG4csbx2sGjrKLozXQJeCpJ4dIBZolyFLkZ+XphD1keQWouLUvJkPQ3MSglLLKuD37pp52YjMncZMEQ==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -1753,30 +1753,30 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/private-theming': 5.14.11(react@18.2.0) - '@mui/styled-engine': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/private-theming': 5.14.13(react@18.2.0) + '@mui/styled-engine': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/types@7.2.4: - resolution: {integrity: sha512-LBcwa8rN84bKF+f5sDyku42w1NTxaPgPyYKODsh01U1fVstTClbUoSA96oyRBnSNyEiAVjKm6Gwx9vjR+xyqHA==} + /@mui/types@7.2.6: + resolution: {integrity: sha512-7sjLQrUmBwufm/M7jw/quNiPK/oor2+pGUQP2CULRcFCArYTq78oJ3D5esTaL0UMkXKJvDqXn6Ike69yAOBQng==} peerDependencies: - '@types/react': '*' + '@types/react': ^17.0.0 || ^18.0.0 peerDependenciesMeta: '@types/react': optional: true dev: false - /@mui/utils@5.14.11(react@18.2.0): - resolution: {integrity: sha512-fmkIiCPKyDssYrJ5qk+dime1nlO3dmWfCtaPY/uVBqCRMBZ11JhddB9m8sjI2mgqQQwRJG5bq3biaosNdU/s4Q==} + /@mui/utils@5.14.13(react@18.2.0): + resolution: {integrity: sha512-2AFpyXWw7uDCIqRu7eU2i/EplZtks5LAMzQvIhC79sPV9IhOZU2qwOWVnPtdctRXiQJOAaXulg+A37pfhEueQw==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -1787,8 +1787,8 @@ packages: react: optional: true dependencies: - '@babel/runtime': 7.22.15 - '@types/prop-types': 15.7.5 + '@babel/runtime': 7.23.2 + '@types/prop-types': 15.7.8 prop-types: 15.8.1 react: 18.2.0 react-is: 18.2.0 @@ -2118,8 +2118,8 @@ packages: resolution: {integrity: sha512-GSCjjH6mDS8jgpT22rEOkZVqZcYj7i9AHJu4ntpvoohEpa0mLAKP/Kz3POMKqABaFsS4TyNHOeoyWpzycddcoQ==} dev: false - /@types/prop-types@15.7.5: - resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} + /@types/prop-types@15.7.8: + resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} dev: false /@types/qs@6.9.7: @@ -2128,8 +2128,8 @@ packages: /@types/range-parser@1.2.4: resolution: {integrity: sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==} - /@types/react-transition-group@4.4.6: - resolution: {integrity: sha512-VnCdSxfcm08KjsJVQcfBmhEQAPnLB8G08hAxn39azX1qYBQ/5RVQuoHuKIcfKOdncuaUvEpFKFzEvbtIMsfVew==} + /@types/react-transition-group@4.4.7: + resolution: {integrity: sha512-ICCyBl5mvyqYp8Qeq9B5G/fyBSRC0zx3XM3sCC6KkcMsNeAHqXBKkmat4GqdJET5jtYUpZXrxI5flve5qhi2Eg==} dependencies: '@types/react': 18.2.14 dev: false @@ -2137,7 +2137,7 @@ packages: /@types/react@18.2.14: resolution: {integrity: sha512-A0zjq+QN/O0Kpe30hA1GidzyFjatVvrpIvWLxD+xv67Vt91TWWgco9IvrJBkeyHm1trGaFS/FSGqPlhyeZRm0g==} dependencies: - '@types/prop-types': 15.7.5 + '@types/prop-types': 15.7.8 '@types/scheduler': 0.16.3 csstype: 3.1.2 dev: false @@ -2679,7 +2679,7 @@ packages: resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} engines: {node: '>=10', npm: '>=6'} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 cosmiconfig: 7.1.0 resolve: 1.22.2 dev: false @@ -3489,7 +3489,7 @@ packages: /dom-helpers@5.2.1: resolution: {integrity: sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 csstype: 3.1.2 dev: false @@ -3758,15 +3758,15 @@ packages: - supports-color dev: true - /eslint@8.50.0: - resolution: {integrity: sha512-FOnOGSuFuFLv/Sa+FDVRZl4GGVAAFFi8LecRsI5a1tMO5HIE8nCm4ivAlzt4dT3ol/PaaGC0rJEEXQmHJBGoOg==} + /eslint@8.51.0: + resolution: {integrity: sha512-2WuxRZBrlwnXi+/vFSJyjMqrNjtJqiasMzehF0shoLaW7DzS3/9Yvrmq5JiT66+pNjiX4UBnLDiKHcWAr/OInA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.50.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) '@eslint-community/regexpp': 4.6.2 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.50.0 + '@eslint/js': 8.51.0 '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 @@ -4117,8 +4117,8 @@ packages: punycode: 1.4.1 dev: false - /fast-xml-parser@4.3.1: - resolution: {integrity: sha512-viVv3xb8D+SiS1W4cv4tva3bni08kAkx0gQnWrykMM8nXPc1FxqZPU00dCEVjkiCg4HoXd2jC4x29Nzg/l2DAA==} + /fast-xml-parser@4.3.2: + resolution: {integrity: sha512-rmrXUXwbJedoXkStenj1kkljNF7ugn5ZjR9FJcwmCfcCbtOMDghPajbc+Tck6vE6F5XsDmx+Pr2le9fw8+pXBg==} hasBin: true dependencies: strnum: 1.0.5 @@ -6778,7 +6778,7 @@ packages: react-dom: optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dom-helpers: 5.2.1 loose-envify: 1.4.0 prop-types: 15.8.1 @@ -7741,8 +7741,8 @@ packages: engines: {node: '>=10'} dev: true - /type-fest@4.3.3: - resolution: {integrity: sha512-bxhiFii6BBv6UiSDq7uKTMyADT9unXEl3ydGefndVLxFeB44LRbT4K7OJGDYSyDrKnklCC1Pre68qT2wbUl2Aw==} + /type-fest@4.4.0: + resolution: {integrity: sha512-HT3RRs7sTfY22KuPQJkD/XjbTbxgP2Je5HPt6H6JEGvcjHd5Lqru75EbrP3tb4FYjNJ+DjLp+MNQTFQU0mhXNw==} engines: {node: '>=16'} dev: false @@ -8103,8 +8103,12 @@ packages: resolution: {integrity: sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==} dev: false - github.com/theopensystemslab/planx-core/d92224b: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/d92224b} + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + dev: false + + github.com/theopensystemslab/planx-core/3a85966: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true @@ -8112,14 +8116,14 @@ packages: dependencies: '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/material': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) '@types/geojson': 7946.0.11 ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) copyfiles: 2.4.1 docx: 8.2.3 - eslint: 8.50.0 - fast-xml-parser: 4.3.1 + eslint: 8.51.0 + fast-xml-parser: 4.3.2 graphql: 16.8.1 graphql-request: 6.1.0(graphql@16.8.1) json-schema-to-typescript: 13.1.1 @@ -8138,9 +8142,9 @@ packages: react: 18.2.0 react-dom: 18.2.0(react@18.2.0) striptags: 3.2.0 - type-fest: 4.3.3 + type-fest: 4.4.0 uuid: 9.0.1 - zod: 3.22.3 + zod: 3.22.4 transitivePeerDependencies: - '@types/react' - encoding diff --git a/api.planx.uk/send/bops.ts b/api.planx.uk/send/bops.ts index b0e07058f4..80d1edebb1 100644 --- a/api.planx.uk/send/bops.ts +++ b/api.planx.uk/send/bops.ts @@ -70,7 +70,7 @@ const sendToBOPS = async (req: Request, res: Response, next: NextFunction) => { ); } const target = `${bopsSubmissionURL}/api/v1/planning_applications`; - const { exportData } = await $api.export.bopsPayload(payload?.sessionId); + const exportData = await $api.export.bopsPayload(payload?.sessionId); try { const bopsResponse = await axios({ diff --git a/api.planx.uk/send/email.test.ts b/api.planx.uk/send/email.test.ts index 12cb25ab54..398f6d8889 100644 --- a/api.planx.uk/send/email.test.ts +++ b/api.planx.uk/send/email.test.ts @@ -2,16 +2,13 @@ import supertest from "supertest"; import { queryMock } from "../tests/graphqlQueryMock"; import app from "../server"; -const mockGenerateCSVData = jest.fn().mockResolvedValue({ - responses: [ - { - question: "Is this a test?", - responses: [{ value: "Yes" }], - metadata: {}, - }, - ], - redactedResponses: [], -}); +const mockGenerateCSVData = jest.fn().mockResolvedValue([ + { + question: "Is this a test?", + responses: [{ value: "Yes" }], + metadata: {}, + }, +]); jest.mock("@opensystemslab/planx-core", () => { return { Passport: jest.fn().mockImplementation(() => ({ diff --git a/api.planx.uk/send/exportZip.test.ts b/api.planx.uk/send/exportZip.test.ts index 39ce06e6b2..2ecb05da89 100644 --- a/api.planx.uk/send/exportZip.test.ts +++ b/api.planx.uk/send/exportZip.test.ts @@ -58,7 +58,6 @@ const mockGenerateOneAppXML = jest jest.mock("../client", () => { return { $api: { - generateOneAppXML: () => mockGenerateOneAppXML(), getDocumentTemplateNamesForSession: jest .fn() .mockResolvedValue(["X", "Y"]), @@ -66,16 +65,15 @@ jest.mock("../client", () => { find: () => mockGetSessionById(), }, export: { - csvData: jest.fn().mockResolvedValue({ - responses: [ - { - question: "Test", - responses: [{ value: "Answer" }], - metadata: {}, - }, - ], - redactedResponses: [], - }), + csvData: jest.fn().mockResolvedValue([ + { + question: "Test", + responses: [{ value: "Answer" }], + metadata: {}, + }, + ]), + csvDataRedacted: jest.fn().mockResolvedValue([]), + oneAppPayload: () => mockGenerateOneAppXML(), }, }, }; diff --git a/api.planx.uk/send/exportZip.ts b/api.planx.uk/send/exportZip.ts index 9c2e6ffbe6..c342e43ff8 100644 --- a/api.planx.uk/send/exportZip.ts +++ b/api.planx.uk/send/exportZip.ts @@ -39,7 +39,7 @@ export async function buildSubmissionExportZip({ // add OneApp XML to the zip if (includeOneAppXML) { try { - const xml = await $api.generateOneAppXML(sessionId); + const xml = await $api.export.oneAppPayload(sessionId); const xmlStream = str(xml.trim()); await zip.addStream({ name: "proposal.xml", // must be named "proposal.xml" to be processed by Uniform @@ -65,7 +65,8 @@ export async function buildSubmissionExportZip({ } // generate csv data - const { responses, redactedResponses } = await $api.export.csvData(sessionId); + const responses = await $api.export.csvData(sessionId); + const redactedResponses = await $api.export.csvDataRedacted(sessionId); // write csv to the zip try { diff --git a/api.planx.uk/send/uniform.ts b/api.planx.uk/send/uniform.ts index 4140a14146..919eb32cba 100644 --- a/api.planx.uk/send/uniform.ts +++ b/api.planx.uk/send/uniform.ts @@ -373,7 +373,7 @@ const createUniformApplicationAuditRecord = async ({ localAuthority: string; submissionDetails: UniformSubmissionResponse; }): Promise => { - const xml = await $api.generateOneAppXML(payload?.sessionId); + const xml = await $api.export.oneAppPayload(payload?.sessionId); const application: Record< "insert_uniform_applications_one", diff --git a/e2e/tests/api-driven/package.json b/e2e/tests/api-driven/package.json index 5d607b6297..48f20ab556 100644 --- a/e2e/tests/api-driven/package.json +++ b/e2e/tests/api-driven/package.json @@ -6,7 +6,7 @@ }, "dependencies": { "@cucumber/cucumber": "^9.3.0", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#d92224b", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", "axios": "^1.4.0", "dotenv": "^16.3.1", "dotenv-expand": "^10.0.0", diff --git a/e2e/tests/api-driven/pnpm-lock.yaml b/e2e/tests/api-driven/pnpm-lock.yaml index 88e4c5bfa6..05d1617b15 100644 --- a/e2e/tests/api-driven/pnpm-lock.yaml +++ b/e2e/tests/api-driven/pnpm-lock.yaml @@ -9,8 +9,8 @@ dependencies: specifier: ^9.3.0 version: 9.3.0 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#d92224b - version: github.com/theopensystemslab/planx-core/d92224b + specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 + version: github.com/theopensystemslab/planx-core/3a85966 axios: specifier: ^1.4.0 version: 1.4.0 @@ -101,6 +101,13 @@ packages: regenerator-runtime: 0.13.11 dev: false + /@babel/runtime@7.23.2: + resolution: {integrity: sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg==} + engines: {node: '>=6.9.0'} + dependencies: + regenerator-runtime: 0.14.0 + dev: false + /@babel/types@7.22.5: resolution: {integrity: sha512-zo3MIHGOkPOfoRXitsgHLjEXmlDaD/5KU1Uzuc9GNiZPhSqVxVRtxuPaSBZDsYZ9qV88AjtMtWW7ww98loJ9KA==} engines: {node: '>=6.9.0'} @@ -381,13 +388,13 @@ packages: resolution: {integrity: sha512-EsBwpc7hBUJWAsNPBmJy4hxWx12v6bshQsldrVmjxJoc3isbxhOrF2IcCpaXxfvq03NwkI7sbsOLXbYuqF/8Ww==} dev: false - /@eslint-community/eslint-utils@4.4.0(eslint@8.50.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.51.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.50.0 + eslint: 8.51.0 eslint-visitor-keys: 3.4.3 dev: false @@ -413,8 +420,8 @@ packages: - supports-color dev: false - /@eslint/js@8.50.0: - resolution: {integrity: sha512-NCC3zz2+nvYd+Ckfh87rA47zfu2QsQpvc6k1yzTk+b9KzRj0wkGa8LSoGOXN6Zv4lRf/EIoZ80biDh9HOI+RNQ==} + /@eslint/js@8.51.0: + resolution: {integrity: sha512-HxjQ8Qn+4SI3/AFv6sOrDB+g6PpUTDwSJiQqOrnneEk8L71161srI9gjzzZvYVbzHiVg/BvcH95+cK/zfIt4pg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: false @@ -494,8 +501,8 @@ packages: resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} dev: false - /@mui/base@5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-xNbk7iOXrglNdIxFBN0k3ySsPIFLWCnFxqsAYl7CIcDkD9low4kJ7IUuy6ctwx/HAy2fenrT3KXHr1sGjAMgpQ==} + /@mui/base@5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-maNBgAscddyPNzFZQUJDF/puxM27Li+NqSBsr/lAP8TLns2VvWS2SoL3OKFOIoRnAMKGY/Ic6Aot6gCYeQnssA==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -505,10 +512,10 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@floating-ui/react-dom': 2.0.2(react-dom@18.2.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) '@popperjs/core': 2.11.8 clsx: 2.0.0 prop-types: 15.8.1 @@ -516,12 +523,12 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false - /@mui/core-downloads-tracker@5.14.11: - resolution: {integrity: sha512-uY8FLQURhXe3f3O4dS5OSGML9KDm9+IE226cBu78jarVIzdQGPlXwGIlSI9VJR8MvZDA6C0+6XfWDhWCHruC5Q==} + /@mui/core-downloads-tracker@5.14.13: + resolution: {integrity: sha512-3ZUbzcH4yloLKlV6Y+S0Edn2wef9t+EGHSfEkwVCn8E0ULdshifEFgfEroKRegQifDIwcKS/ofccxuZ8njTAYg==} dev: false - /@mui/material@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-DnSdJzcR7lwG12JA5L2t8JF+RDzMygu5rCNW+logWb/KW2/TRzwLyVWO+CorHTBjBRd38DBxnwOCDiYkDd+N3A==} + /@mui/material@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-iPEFwhoVG789UVsXX4gqd1eJUlcLW1oceqwJYQN8Z4MpcAKfL9Lv3fda65AwG7pQ5lf+d7IbHzm4m48SWZxI2g==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -537,15 +544,15 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/base': 5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0) - '@mui/core-downloads-tracker': 5.14.11 - '@mui/system': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) - '@types/react-transition-group': 4.4.6 + '@mui/base': 5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0) + '@mui/core-downloads-tracker': 5.14.13 + '@mui/system': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) + '@types/react-transition-group': 4.4.7 clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 @@ -555,8 +562,8 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - /@mui/private-theming@5.14.11(react@18.2.0): - resolution: {integrity: sha512-MSnNNzTu9pfKLCKs1ZAKwOTgE4bz+fQA0fNr8Jm7NDmuWmw0CaN9Vq2/MHsatE7+S0A25IAKby46Uv1u53rKVQ==} + /@mui/private-theming@5.14.13(react@18.2.0): + resolution: {integrity: sha512-5EFqk4tqiSwPguj4NW/6bUf4u1qoUWXy9lrKfNh9H6oAohM+Ijv/7qSxFjnxPGBctj469/Sc5aKAR35ILBKZLQ==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -565,14 +572,14 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@mui/utils': 5.14.11(react@18.2.0) + '@babel/runtime': 7.23.2 + '@mui/utils': 5.14.13(react@18.2.0) prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/styled-engine@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-jdUlqRgTYQ8RMtPX4MbRZqar6W2OiIb6J5KEFbIu4FqvPrk44Each4ppg/LAqp1qNlBYq5i+7Q10MYLMpDxX9A==} + /@mui/styled-engine@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-1ff/egFQl26hiwcUtCMKAkp4Sgqpm3qIewmXq+GN27fb44lDIACquehMFBuadOjceOFmbIXbayzbA46ZyqFYzA==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.4.1 @@ -584,7 +591,7 @@ packages: '@emotion/styled': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/cache': 11.11.0 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) @@ -593,8 +600,8 @@ packages: react: 18.2.0 dev: false - /@mui/system@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-yl8xV+y0k7j6dzBsHabKwoShmjqLa8kTxrhUI3JpqLG358VRVMJRW/ES0HhvfcCi4IVXde+Tc2P3K1akGL8zoA==} + /@mui/system@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-+5+Dx50lG4csbx2sGjrKLozXQJeCpJ4dIBZolyFLkZ+XphD1keQWouLUvJkPQ3MSglLLKuD37pp52YjMncZMEQ==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -609,30 +616,30 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/private-theming': 5.14.11(react@18.2.0) - '@mui/styled-engine': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/private-theming': 5.14.13(react@18.2.0) + '@mui/styled-engine': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/types@7.2.4: - resolution: {integrity: sha512-LBcwa8rN84bKF+f5sDyku42w1NTxaPgPyYKODsh01U1fVstTClbUoSA96oyRBnSNyEiAVjKm6Gwx9vjR+xyqHA==} + /@mui/types@7.2.6: + resolution: {integrity: sha512-7sjLQrUmBwufm/M7jw/quNiPK/oor2+pGUQP2CULRcFCArYTq78oJ3D5esTaL0UMkXKJvDqXn6Ike69yAOBQng==} peerDependencies: - '@types/react': '*' + '@types/react': ^17.0.0 || ^18.0.0 peerDependenciesMeta: '@types/react': optional: true dev: false - /@mui/utils@5.14.11(react@18.2.0): - resolution: {integrity: sha512-fmkIiCPKyDssYrJ5qk+dime1nlO3dmWfCtaPY/uVBqCRMBZ11JhddB9m8sjI2mgqQQwRJG5bq3biaosNdU/s4Q==} + /@mui/utils@5.14.13(react@18.2.0): + resolution: {integrity: sha512-2AFpyXWw7uDCIqRu7eU2i/EplZtks5LAMzQvIhC79sPV9IhOZU2qwOWVnPtdctRXiQJOAaXulg+A37pfhEueQw==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -641,8 +648,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@types/prop-types': 15.7.5 + '@babel/runtime': 7.23.2 + '@types/prop-types': 15.7.8 prop-types: 15.8.1 react: 18.2.0 react-is: 18.2.0 @@ -741,8 +748,12 @@ packages: resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} dev: false - /@types/react-transition-group@4.4.6: - resolution: {integrity: sha512-VnCdSxfcm08KjsJVQcfBmhEQAPnLB8G08hAxn39azX1qYBQ/5RVQuoHuKIcfKOdncuaUvEpFKFzEvbtIMsfVew==} + /@types/prop-types@15.7.8: + resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} + dev: false + + /@types/react-transition-group@4.4.7: + resolution: {integrity: sha512-ICCyBl5mvyqYp8Qeq9B5G/fyBSRC0zx3XM3sCC6KkcMsNeAHqXBKkmat4GqdJET5jtYUpZXrxI5flve5qhi2Eg==} dependencies: '@types/react': 18.2.18 dev: false @@ -1138,7 +1149,7 @@ packages: /dom-helpers@5.2.1: resolution: {integrity: sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 csstype: 3.1.2 dev: false @@ -1236,15 +1247,15 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: false - /eslint@8.50.0: - resolution: {integrity: sha512-FOnOGSuFuFLv/Sa+FDVRZl4GGVAAFFi8LecRsI5a1tMO5HIE8nCm4ivAlzt4dT3ol/PaaGC0rJEEXQmHJBGoOg==} + /eslint@8.51.0: + resolution: {integrity: sha512-2WuxRZBrlwnXi+/vFSJyjMqrNjtJqiasMzehF0shoLaW7DzS3/9Yvrmq5JiT66+pNjiX4UBnLDiKHcWAr/OInA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.50.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) '@eslint-community/regexpp': 4.6.2 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.50.0 + '@eslint/js': 8.51.0 '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 @@ -1345,8 +1356,8 @@ packages: resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} dev: false - /fast-xml-parser@4.3.1: - resolution: {integrity: sha512-viVv3xb8D+SiS1W4cv4tva3bni08kAkx0gQnWrykMM8nXPc1FxqZPU00dCEVjkiCg4HoXd2jC4x29Nzg/l2DAA==} + /fast-xml-parser@4.3.2: + resolution: {integrity: sha512-rmrXUXwbJedoXkStenj1kkljNF7ugn5ZjR9FJcwmCfcCbtOMDghPajbc+Tck6vE6F5XsDmx+Pr2le9fw8+pXBg==} hasBin: true dependencies: strnum: 1.0.5 @@ -2170,7 +2181,7 @@ packages: react: '>=16.6.0' react-dom: '>=16.6.0' dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dom-helpers: 5.2.1 loose-envify: 1.4.0 prop-types: 15.8.1 @@ -2531,8 +2542,8 @@ packages: engines: {node: '>=10'} dev: false - /type-fest@4.3.3: - resolution: {integrity: sha512-bxhiFii6BBv6UiSDq7uKTMyADT9unXEl3ydGefndVLxFeB44LRbT4K7OJGDYSyDrKnklCC1Pre68qT2wbUl2Aw==} + /type-fest@4.4.0: + resolution: {integrity: sha512-HT3RRs7sTfY22KuPQJkD/XjbTbxgP2Je5HPt6H6JEGvcjHd5Lqru75EbrP3tb4FYjNJ+DjLp+MNQTFQU0mhXNw==} engines: {node: '>=16'} dev: false @@ -2711,12 +2722,12 @@ packages: toposort: 2.0.2 dev: false - /zod@3.22.3: - resolution: {integrity: sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==} + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - github.com/theopensystemslab/planx-core/d92224b: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/d92224b} + github.com/theopensystemslab/planx-core/3a85966: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true @@ -2724,14 +2735,14 @@ packages: dependencies: '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/material': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) '@types/geojson': 7946.0.11 ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) copyfiles: 2.4.1 docx: 8.2.3 - eslint: 8.50.0 - fast-xml-parser: 4.3.1 + eslint: 8.51.0 + fast-xml-parser: 4.3.2 graphql: 16.8.1 graphql-request: 6.1.0(graphql@16.8.1) json-schema-to-typescript: 13.1.1 @@ -2750,9 +2761,9 @@ packages: react: 18.2.0 react-dom: 18.2.0(react@18.2.0) striptags: 3.2.0 - type-fest: 4.3.3 + type-fest: 4.4.0 uuid: 9.0.1 - zod: 3.22.3 + zod: 3.22.4 transitivePeerDependencies: - '@types/react' - encoding diff --git a/e2e/tests/ui-driven/package.json b/e2e/tests/ui-driven/package.json index 65fcf76221..f029be3d67 100644 --- a/e2e/tests/ui-driven/package.json +++ b/e2e/tests/ui-driven/package.json @@ -8,7 +8,7 @@ "postinstall": "./install-dependencies.sh" }, "dependencies": { - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#d92224b", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", "axios": "^1.4.0", "dotenv": "^16.3.1", "eslint": "^8.44.0", diff --git a/e2e/tests/ui-driven/pnpm-lock.yaml b/e2e/tests/ui-driven/pnpm-lock.yaml index cf65f35302..cedd2fda9c 100644 --- a/e2e/tests/ui-driven/pnpm-lock.yaml +++ b/e2e/tests/ui-driven/pnpm-lock.yaml @@ -6,8 +6,8 @@ settings: dependencies: '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#d92224b - version: github.com/theopensystemslab/planx-core/d92224b + specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 + version: github.com/theopensystemslab/planx-core/3a85966 axios: specifier: ^1.4.0 version: 1.4.0 @@ -94,6 +94,13 @@ packages: regenerator-runtime: 0.14.0 dev: false + /@babel/runtime@7.23.2: + resolution: {integrity: sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg==} + engines: {node: '>=6.9.0'} + dependencies: + regenerator-runtime: 0.14.0 + dev: false + /@babel/types@7.22.10: resolution: {integrity: sha512-obaoigiLrlDZ7TUQln/8m4mSqIW2QFeOrCQc9r+xsaHGNoplVNYlRVpsfE8Vj35GEm2ZH4ZhrNYogs/3fj85kg==} engines: {node: '>=6.9.0'} @@ -236,13 +243,13 @@ packages: eslint: 8.47.0 eslint-visitor-keys: 3.4.3 - /@eslint-community/eslint-utils@4.4.0(eslint@8.50.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.51.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.50.0 + eslint: 8.51.0 eslint-visitor-keys: 3.4.3 dev: false @@ -270,8 +277,8 @@ packages: resolution: {integrity: sha512-P6omY1zv5MItm93kLM8s2vr1HICJH8v0dvddDhysbIuZ+vcjOHg5Zbkf1mTkcmi2JA9oBG2anOkRnW8WJTS8Og==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - /@eslint/js@8.50.0: - resolution: {integrity: sha512-NCC3zz2+nvYd+Ckfh87rA47zfu2QsQpvc6k1yzTk+b9KzRj0wkGa8LSoGOXN6Zv4lRf/EIoZ80biDh9HOI+RNQ==} + /@eslint/js@8.51.0: + resolution: {integrity: sha512-HxjQ8Qn+4SI3/AFv6sOrDB+g6PpUTDwSJiQqOrnneEk8L71161srI9gjzzZvYVbzHiVg/BvcH95+cK/zfIt4pg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: false @@ -343,8 +350,8 @@ packages: resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} dev: false - /@mui/base@5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-xNbk7iOXrglNdIxFBN0k3ySsPIFLWCnFxqsAYl7CIcDkD9low4kJ7IUuy6ctwx/HAy2fenrT3KXHr1sGjAMgpQ==} + /@mui/base@5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-maNBgAscddyPNzFZQUJDF/puxM27Li+NqSBsr/lAP8TLns2VvWS2SoL3OKFOIoRnAMKGY/Ic6Aot6gCYeQnssA==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -354,10 +361,10 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@floating-ui/react-dom': 2.0.2(react-dom@18.2.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) '@popperjs/core': 2.11.8 clsx: 2.0.0 prop-types: 15.8.1 @@ -365,12 +372,12 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false - /@mui/core-downloads-tracker@5.14.11: - resolution: {integrity: sha512-uY8FLQURhXe3f3O4dS5OSGML9KDm9+IE226cBu78jarVIzdQGPlXwGIlSI9VJR8MvZDA6C0+6XfWDhWCHruC5Q==} + /@mui/core-downloads-tracker@5.14.13: + resolution: {integrity: sha512-3ZUbzcH4yloLKlV6Y+S0Edn2wef9t+EGHSfEkwVCn8E0ULdshifEFgfEroKRegQifDIwcKS/ofccxuZ8njTAYg==} dev: false - /@mui/material@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-DnSdJzcR7lwG12JA5L2t8JF+RDzMygu5rCNW+logWb/KW2/TRzwLyVWO+CorHTBjBRd38DBxnwOCDiYkDd+N3A==} + /@mui/material@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-iPEFwhoVG789UVsXX4gqd1eJUlcLW1oceqwJYQN8Z4MpcAKfL9Lv3fda65AwG7pQ5lf+d7IbHzm4m48SWZxI2g==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -386,15 +393,15 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/base': 5.0.0-beta.17(react-dom@18.2.0)(react@18.2.0) - '@mui/core-downloads-tracker': 5.14.11 - '@mui/system': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) - '@types/react-transition-group': 4.4.6 + '@mui/base': 5.0.0-beta.19(react-dom@18.2.0)(react@18.2.0) + '@mui/core-downloads-tracker': 5.14.13 + '@mui/system': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) + '@types/react-transition-group': 4.4.7 clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 @@ -404,8 +411,8 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - /@mui/private-theming@5.14.11(react@18.2.0): - resolution: {integrity: sha512-MSnNNzTu9pfKLCKs1ZAKwOTgE4bz+fQA0fNr8Jm7NDmuWmw0CaN9Vq2/MHsatE7+S0A25IAKby46Uv1u53rKVQ==} + /@mui/private-theming@5.14.13(react@18.2.0): + resolution: {integrity: sha512-5EFqk4tqiSwPguj4NW/6bUf4u1qoUWXy9lrKfNh9H6oAohM+Ijv/7qSxFjnxPGBctj469/Sc5aKAR35ILBKZLQ==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -414,14 +421,14 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@mui/utils': 5.14.11(react@18.2.0) + '@babel/runtime': 7.23.2 + '@mui/utils': 5.14.13(react@18.2.0) prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/styled-engine@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-jdUlqRgTYQ8RMtPX4MbRZqar6W2OiIb6J5KEFbIu4FqvPrk44Each4ppg/LAqp1qNlBYq5i+7Q10MYLMpDxX9A==} + /@mui/styled-engine@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-1ff/egFQl26hiwcUtCMKAkp4Sgqpm3qIewmXq+GN27fb44lDIACquehMFBuadOjceOFmbIXbayzbA46ZyqFYzA==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.4.1 @@ -433,7 +440,7 @@ packages: '@emotion/styled': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/cache': 11.11.0 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) @@ -442,8 +449,8 @@ packages: react: 18.2.0 dev: false - /@mui/system@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-yl8xV+y0k7j6dzBsHabKwoShmjqLa8kTxrhUI3JpqLG358VRVMJRW/ES0HhvfcCi4IVXde+Tc2P3K1akGL8zoA==} + /@mui/system@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-+5+Dx50lG4csbx2sGjrKLozXQJeCpJ4dIBZolyFLkZ+XphD1keQWouLUvJkPQ3MSglLLKuD37pp52YjMncZMEQ==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -458,30 +465,30 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/private-theming': 5.14.11(react@18.2.0) - '@mui/styled-engine': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4 - '@mui/utils': 5.14.11(react@18.2.0) + '@mui/private-theming': 5.14.13(react@18.2.0) + '@mui/styled-engine': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6 + '@mui/utils': 5.14.13(react@18.2.0) clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/types@7.2.4: - resolution: {integrity: sha512-LBcwa8rN84bKF+f5sDyku42w1NTxaPgPyYKODsh01U1fVstTClbUoSA96oyRBnSNyEiAVjKm6Gwx9vjR+xyqHA==} + /@mui/types@7.2.6: + resolution: {integrity: sha512-7sjLQrUmBwufm/M7jw/quNiPK/oor2+pGUQP2CULRcFCArYTq78oJ3D5esTaL0UMkXKJvDqXn6Ike69yAOBQng==} peerDependencies: - '@types/react': '*' + '@types/react': ^17.0.0 || ^18.0.0 peerDependenciesMeta: '@types/react': optional: true dev: false - /@mui/utils@5.14.11(react@18.2.0): - resolution: {integrity: sha512-fmkIiCPKyDssYrJ5qk+dime1nlO3dmWfCtaPY/uVBqCRMBZ11JhddB9m8sjI2mgqQQwRJG5bq3biaosNdU/s4Q==} + /@mui/utils@5.14.13(react@18.2.0): + resolution: {integrity: sha512-2AFpyXWw7uDCIqRu7eU2i/EplZtks5LAMzQvIhC79sPV9IhOZU2qwOWVnPtdctRXiQJOAaXulg+A37pfhEueQw==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -490,8 +497,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@types/prop-types': 15.7.5 + '@babel/runtime': 7.23.2 + '@types/prop-types': 15.7.8 prop-types: 15.8.1 react: 18.2.0 react-is: 18.2.0 @@ -572,8 +579,12 @@ packages: resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} dev: false - /@types/react-transition-group@4.4.6: - resolution: {integrity: sha512-VnCdSxfcm08KjsJVQcfBmhEQAPnLB8G08hAxn39azX1qYBQ/5RVQuoHuKIcfKOdncuaUvEpFKFzEvbtIMsfVew==} + /@types/prop-types@15.7.8: + resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} + dev: false + + /@types/react-transition-group@4.4.7: + resolution: {integrity: sha512-ICCyBl5mvyqYp8Qeq9B5G/fyBSRC0zx3XM3sCC6KkcMsNeAHqXBKkmat4GqdJET5jtYUpZXrxI5flve5qhi2Eg==} dependencies: '@types/react': 18.2.20 dev: false @@ -1003,7 +1014,7 @@ packages: /dom-helpers@5.2.1: resolution: {integrity: sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 csstype: 3.1.2 dev: false @@ -1152,15 +1163,15 @@ packages: transitivePeerDependencies: - supports-color - /eslint@8.50.0: - resolution: {integrity: sha512-FOnOGSuFuFLv/Sa+FDVRZl4GGVAAFFi8LecRsI5a1tMO5HIE8nCm4ivAlzt4dT3ol/PaaGC0rJEEXQmHJBGoOg==} + /eslint@8.51.0: + resolution: {integrity: sha512-2WuxRZBrlwnXi+/vFSJyjMqrNjtJqiasMzehF0shoLaW7DzS3/9Yvrmq5JiT66+pNjiX4UBnLDiKHcWAr/OInA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.50.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) '@eslint-community/regexpp': 4.6.2 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.50.0 + '@eslint/js': 8.51.0 '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 @@ -1269,8 +1280,8 @@ packages: punycode: 1.4.1 dev: false - /fast-xml-parser@4.3.1: - resolution: {integrity: sha512-viVv3xb8D+SiS1W4cv4tva3bni08kAkx0gQnWrykMM8nXPc1FxqZPU00dCEVjkiCg4HoXd2jC4x29Nzg/l2DAA==} + /fast-xml-parser@4.3.2: + resolution: {integrity: sha512-rmrXUXwbJedoXkStenj1kkljNF7ugn5ZjR9FJcwmCfcCbtOMDghPajbc+Tck6vE6F5XsDmx+Pr2le9fw8+pXBg==} hasBin: true dependencies: strnum: 1.0.5 @@ -2023,7 +2034,7 @@ packages: react: '>=16.6.0' react-dom: '>=16.6.0' dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dom-helpers: 5.2.1 loose-envify: 1.4.0 prop-types: 15.8.1 @@ -2336,8 +2347,8 @@ packages: engines: {node: '>=12.20'} dev: false - /type-fest@4.3.3: - resolution: {integrity: sha512-bxhiFii6BBv6UiSDq7uKTMyADT9unXEl3ydGefndVLxFeB44LRbT4K7OJGDYSyDrKnklCC1Pre68qT2wbUl2Aw==} + /type-fest@4.4.0: + resolution: {integrity: sha512-HT3RRs7sTfY22KuPQJkD/XjbTbxgP2Je5HPt6H6JEGvcjHd5Lqru75EbrP3tb4FYjNJ+DjLp+MNQTFQU0mhXNw==} engines: {node: '>=16'} dev: false @@ -2487,12 +2498,12 @@ packages: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} - /zod@3.22.3: - resolution: {integrity: sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==} + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - github.com/theopensystemslab/planx-core/d92224b: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/d92224b} + github.com/theopensystemslab/planx-core/3a85966: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true @@ -2500,14 +2511,14 @@ packages: dependencies: '@emotion/react': 11.11.1(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(react@18.2.0) - '@mui/material': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0) '@types/geojson': 7946.0.11 ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) copyfiles: 2.4.1 docx: 8.2.3 - eslint: 8.50.0 - fast-xml-parser: 4.3.1 + eslint: 8.51.0 + fast-xml-parser: 4.3.2 graphql: 16.8.1 graphql-request: 6.1.0(graphql@16.8.1) json-schema-to-typescript: 13.1.1 @@ -2526,9 +2537,9 @@ packages: react: 18.2.0 react-dom: 18.2.0(react@18.2.0) striptags: 3.2.0 - type-fest: 4.3.3 + type-fest: 4.4.0 uuid: 9.0.1 - zod: 3.22.3 + zod: 3.22.4 transitivePeerDependencies: - '@types/react' - encoding diff --git a/editor.planx.uk/package.json b/editor.planx.uk/package.json index 7424e59526..8ea7b375b7 100644 --- a/editor.planx.uk/package.json +++ b/editor.planx.uk/package.json @@ -14,7 +14,7 @@ "@mui/styles": "^5.14.5", "@mui/utils": "^5.14.5", "@opensystemslab/map": "^0.7.5", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#d92224b", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", "@tiptap/core": "^2.0.3", "@tiptap/extension-bold": "^2.0.3", "@tiptap/extension-bubble-menu": "^2.1.6", diff --git a/editor.planx.uk/pnpm-lock.yaml b/editor.planx.uk/pnpm-lock.yaml index d9cb4b60e1..b10d4bc73c 100644 --- a/editor.planx.uk/pnpm-lock.yaml +++ b/editor.planx.uk/pnpm-lock.yaml @@ -46,8 +46,8 @@ dependencies: specifier: ^0.7.5 version: 0.7.5 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#d92224b - version: git/github.com+theopensystemslab/planx-core/d92224b(@types/react@18.2.20) + specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 + version: github.com/theopensystemslab/planx-core/3a85966(@types/react@18.2.20) '@tiptap/core': specifier: ^2.0.3 version: 2.0.3(@tiptap/pm@2.0.3) @@ -3324,6 +3324,12 @@ packages: dependencies: regenerator-runtime: 0.13.11 + /@babel/runtime@7.23.2: + resolution: {integrity: sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg==} + engines: {node: '>=6.9.0'} + dependencies: + regenerator-runtime: 0.14.0 + /@babel/template@7.22.5: resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} engines: {node: '>=6.9.0'} @@ -4443,13 +4449,13 @@ packages: eslint: 8.44.0 eslint-visitor-keys: 3.4.3 - /@eslint-community/eslint-utils@4.4.0(eslint@8.50.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.51.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.50.0 + eslint: 8.51.0 eslint-visitor-keys: 3.4.3 dev: false @@ -4499,8 +4505,8 @@ packages: resolution: {integrity: sha512-Ag+9YM4ocKQx9AarydN0KY2j0ErMHNIocPDrVo8zAE44xLTjEtz81OdR68/cydGtk6m6jDb5Za3r2useMzYmSw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - /@eslint/js@8.50.0: - resolution: {integrity: sha512-NCC3zz2+nvYd+Ckfh87rA47zfu2QsQpvc6k1yzTk+b9KzRj0wkGa8LSoGOXN6Zv4lRf/EIoZ80biDh9HOI+RNQ==} + /@eslint/js@8.51.0: + resolution: {integrity: sha512-HxjQ8Qn+4SI3/AFv6sOrDB+g6PpUTDwSJiQqOrnneEk8L71161srI9gjzzZvYVbzHiVg/BvcH95+cK/zfIt4pg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: false @@ -5215,7 +5221,7 @@ packages: '@babel/runtime': 7.22.15 '@emotion/is-prop-valid': 1.2.1 '@mui/types': 7.2.4(@types/react@18.2.20) - '@mui/utils': 5.14.10(@types/react@18.2.20)(react@18.2.0) + '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) '@popperjs/core': 2.11.8 '@types/react': 18.2.20 clsx: 2.0.0 @@ -5225,8 +5231,8 @@ packages: react-is: 18.2.0 dev: false - /@mui/base@5.0.0-beta.17(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-xNbk7iOXrglNdIxFBN0k3ySsPIFLWCnFxqsAYl7CIcDkD9low4kJ7IUuy6ctwx/HAy2fenrT3KXHr1sGjAMgpQ==} + /@mui/base@5.0.0-beta.19(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-maNBgAscddyPNzFZQUJDF/puxM27Li+NqSBsr/lAP8TLns2VvWS2SoL3OKFOIoRnAMKGY/Ic6Aot6gCYeQnssA==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -5236,10 +5242,10 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@floating-ui/react-dom': 2.0.2(react-dom@18.2.0)(react@18.2.0) - '@mui/types': 7.2.4(@types/react@18.2.20) - '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@mui/types': 7.2.6(@types/react@18.2.20) + '@mui/utils': 5.14.13(@types/react@18.2.20)(react@18.2.0) '@popperjs/core': 2.11.8 '@types/react': 18.2.20 clsx: 2.0.0 @@ -5248,8 +5254,8 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false - /@mui/core-downloads-tracker@5.14.11: - resolution: {integrity: sha512-uY8FLQURhXe3f3O4dS5OSGML9KDm9+IE226cBu78jarVIzdQGPlXwGIlSI9VJR8MvZDA6C0+6XfWDhWCHruC5Q==} + /@mui/core-downloads-tracker@5.14.13: + resolution: {integrity: sha512-3ZUbzcH4yloLKlV6Y+S0Edn2wef9t+EGHSfEkwVCn8E0ULdshifEFgfEroKRegQifDIwcKS/ofccxuZ8njTAYg==} dev: false /@mui/core-downloads-tracker@5.14.5: @@ -5273,8 +5279,8 @@ packages: react: 18.2.0 dev: false - /@mui/material@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-DnSdJzcR7lwG12JA5L2t8JF+RDzMygu5rCNW+logWb/KW2/TRzwLyVWO+CorHTBjBRd38DBxnwOCDiYkDd+N3A==} + /@mui/material@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-iPEFwhoVG789UVsXX4gqd1eJUlcLW1oceqwJYQN8Z4MpcAKfL9Lv3fda65AwG7pQ5lf+d7IbHzm4m48SWZxI2g==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -5290,16 +5296,16 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) - '@mui/base': 5.0.0-beta.17(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) - '@mui/core-downloads-tracker': 5.14.11 - '@mui/system': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react@18.2.0) - '@mui/types': 7.2.4(@types/react@18.2.20) - '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@mui/base': 5.0.0-beta.19(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) + '@mui/core-downloads-tracker': 5.14.13 + '@mui/system': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react@18.2.0) + '@mui/types': 7.2.6(@types/react@18.2.20) + '@mui/utils': 5.14.13(@types/react@18.2.20)(react@18.2.0) '@types/react': 18.2.20 - '@types/react-transition-group': 4.4.6 + '@types/react-transition-group': 4.4.7 clsx: 2.0.0 csstype: 3.1.2 prop-types: 15.8.1 @@ -5345,8 +5351,8 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - /@mui/private-theming@5.14.10(@types/react@18.2.20)(react@18.2.0): - resolution: {integrity: sha512-f67xOj3H06wWDT9xBg7hVL/HSKNF+HG1Kx0Pm23skkbEqD2Ef2Lif64e5nPdmWVv+7cISCYtSuE2aeuzrZe78w==} + /@mui/private-theming@5.14.11(@types/react@18.2.20)(react@18.2.0): + resolution: {integrity: sha512-MSnNNzTu9pfKLCKs1ZAKwOTgE4bz+fQA0fNr8Jm7NDmuWmw0CaN9Vq2/MHsatE7+S0A25IAKby46Uv1u53rKVQ==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -5362,8 +5368,8 @@ packages: react: 18.2.0 dev: false - /@mui/private-theming@5.14.11(@types/react@18.2.20)(react@18.2.0): - resolution: {integrity: sha512-MSnNNzTu9pfKLCKs1ZAKwOTgE4bz+fQA0fNr8Jm7NDmuWmw0CaN9Vq2/MHsatE7+S0A25IAKby46Uv1u53rKVQ==} + /@mui/private-theming@5.14.13(@types/react@18.2.20)(react@18.2.0): + resolution: {integrity: sha512-5EFqk4tqiSwPguj4NW/6bUf4u1qoUWXy9lrKfNh9H6oAohM+Ijv/7qSxFjnxPGBctj469/Sc5aKAR35ILBKZLQ==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -5372,8 +5378,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@babel/runtime': 7.23.2 + '@mui/utils': 5.14.13(@types/react@18.2.20)(react@18.2.0) '@types/react': 18.2.20 prop-types: 15.8.1 react: 18.2.0 @@ -5396,8 +5402,8 @@ packages: react: 18.2.0 dev: false - /@mui/styled-engine@5.14.10(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-EJckxmQHrsBvDbFu1trJkvjNw/1R7jfNarnqPSnL+jEQawCkQIqVELWLrlOa611TFtxSJGkdUfCFXeJC203HVg==} + /@mui/styled-engine@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-jdUlqRgTYQ8RMtPX4MbRZqar6W2OiIb6J5KEFbIu4FqvPrk44Each4ppg/LAqp1qNlBYq5i+7Q10MYLMpDxX9A==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.4.1 @@ -5418,8 +5424,8 @@ packages: react: 18.2.0 dev: false - /@mui/styled-engine@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): - resolution: {integrity: sha512-jdUlqRgTYQ8RMtPX4MbRZqar6W2OiIb6J5KEFbIu4FqvPrk44Each4ppg/LAqp1qNlBYq5i+7Q10MYLMpDxX9A==} + /@mui/styled-engine@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0): + resolution: {integrity: sha512-1ff/egFQl26hiwcUtCMKAkp4Sgqpm3qIewmXq+GN27fb44lDIACquehMFBuadOjceOFmbIXbayzbA46ZyqFYzA==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.4.1 @@ -5431,7 +5437,7 @@ packages: '@emotion/styled': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/cache': 11.11.0 '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) @@ -5471,8 +5477,8 @@ packages: react: 18.2.0 dev: false - /@mui/system@5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react@18.2.0): - resolution: {integrity: sha512-yl8xV+y0k7j6dzBsHabKwoShmjqLa8kTxrhUI3JpqLG358VRVMJRW/ES0HhvfcCi4IVXde+Tc2P3K1akGL8zoA==} + /@mui/system@5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react@18.2.0): + resolution: {integrity: sha512-+5+Dx50lG4csbx2sGjrKLozXQJeCpJ4dIBZolyFLkZ+XphD1keQWouLUvJkPQ3MSglLLKuD37pp52YjMncZMEQ==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 @@ -5487,13 +5493,13 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) - '@mui/private-theming': 5.14.11(@types/react@18.2.20)(react@18.2.0) - '@mui/styled-engine': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.4(@types/react@18.2.20) - '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@mui/private-theming': 5.14.13(@types/react@18.2.20)(react@18.2.0) + '@mui/styled-engine': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/types': 7.2.6(@types/react@18.2.20) + '@mui/utils': 5.14.13(@types/react@18.2.20)(react@18.2.0) '@types/react': 18.2.20 clsx: 2.0.0 csstype: 3.1.2 @@ -5520,10 +5526,10 @@ packages: '@babel/runtime': 7.22.15 '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) - '@mui/private-theming': 5.14.10(@types/react@18.2.20)(react@18.2.0) - '@mui/styled-engine': 5.14.10(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) + '@mui/private-theming': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@mui/styled-engine': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react@18.2.0) '@mui/types': 7.2.4(@types/react@18.2.20) - '@mui/utils': 5.14.10(@types/react@18.2.20)(react@18.2.0) + '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) '@types/react': 18.2.20 clsx: 2.0.0 csstype: 3.1.2 @@ -5542,8 +5548,19 @@ packages: '@types/react': 18.2.20 dev: false - /@mui/utils@5.14.10(@types/react@18.2.20)(react@18.2.0): - resolution: {integrity: sha512-Rn+vYQX7FxkcW0riDX/clNUwKuOJFH45HiULxwmpgnzQoQr3A0lb+QYwaZ+FAkZrR7qLoHKmLQlcItu6LT0y/Q==} + /@mui/types@7.2.6(@types/react@18.2.20): + resolution: {integrity: sha512-7sjLQrUmBwufm/M7jw/quNiPK/oor2+pGUQP2CULRcFCArYTq78oJ3D5esTaL0UMkXKJvDqXn6Ike69yAOBQng==} + peerDependencies: + '@types/react': ^17.0.0 || ^18.0.0 + peerDependenciesMeta: + '@types/react': + optional: true + dependencies: + '@types/react': 18.2.20 + dev: false + + /@mui/utils@5.14.11(@types/react@18.2.20)(react@18.2.0): + resolution: {integrity: sha512-fmkIiCPKyDssYrJ5qk+dime1nlO3dmWfCtaPY/uVBqCRMBZ11JhddB9m8sjI2mgqQQwRJG5bq3biaosNdU/s4Q==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -5560,8 +5577,8 @@ packages: react-is: 18.2.0 dev: false - /@mui/utils@5.14.11(@types/react@18.2.20)(react@18.2.0): - resolution: {integrity: sha512-fmkIiCPKyDssYrJ5qk+dime1nlO3dmWfCtaPY/uVBqCRMBZ11JhddB9m8sjI2mgqQQwRJG5bq3biaosNdU/s4Q==} + /@mui/utils@5.14.13(@types/react@18.2.20)(react@18.2.0): + resolution: {integrity: sha512-2AFpyXWw7uDCIqRu7eU2i/EplZtks5LAMzQvIhC79sPV9IhOZU2qwOWVnPtdctRXiQJOAaXulg+A37pfhEueQw==} engines: {node: '>=12.0.0'} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -5570,8 +5587,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@types/prop-types': 15.7.5 + '@babel/runtime': 7.23.2 + '@types/prop-types': 15.7.8 '@types/react': 18.2.20 prop-types: 15.8.1 react: 18.2.0 @@ -8077,6 +8094,10 @@ packages: /@types/prop-types@15.7.5: resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} + /@types/prop-types@15.7.8: + resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} + dev: false + /@types/q@1.5.5: resolution: {integrity: sha512-L28j2FcJfSZOnL1WBjDYp2vUHCeIFlyYI/53EwD/rKUBQ7MtUUfbQWiyKJGpcnv4/WgrhWsFKrcPstcAt/J0tQ==} @@ -8143,6 +8164,12 @@ packages: dependencies: '@types/react': 18.2.20 + /@types/react-transition-group@4.4.7: + resolution: {integrity: sha512-ICCyBl5mvyqYp8Qeq9B5G/fyBSRC0zx3XM3sCC6KkcMsNeAHqXBKkmat4GqdJET5jtYUpZXrxI5flve5qhi2Eg==} + dependencies: + '@types/react': 18.2.20 + dev: false + /@types/react@18.2.20: resolution: {integrity: sha512-WKNtmsLWJM/3D5mG4U84cysVY31ivmyw85dE84fOCk5Hx78wezB/XEjVPWl2JTZ5FkEeaTJf+VgUAUn3PE7Isw==} dependencies: @@ -10845,7 +10872,7 @@ packages: /dom-helpers@5.2.1: resolution: {integrity: sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 csstype: 3.1.2 /dom-serializer@0.2.2: @@ -11804,15 +11831,15 @@ packages: transitivePeerDependencies: - supports-color - /eslint@8.50.0: - resolution: {integrity: sha512-FOnOGSuFuFLv/Sa+FDVRZl4GGVAAFFi8LecRsI5a1tMO5HIE8nCm4ivAlzt4dT3ol/PaaGC0rJEEXQmHJBGoOg==} + /eslint@8.51.0: + resolution: {integrity: sha512-2WuxRZBrlwnXi+/vFSJyjMqrNjtJqiasMzehF0shoLaW7DzS3/9Yvrmq5JiT66+pNjiX4UBnLDiKHcWAr/OInA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.50.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) '@eslint-community/regexpp': 4.6.2 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.50.0 + '@eslint/js': 8.51.0 '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 @@ -12126,8 +12153,8 @@ packages: resolution: {integrity: sha512-HPtaa38cPgWvaCFmRNhlc6NG7pv6NUHqjPgVAkWGoB9mQMwYB27/K0CvOM5Czy+qpT3e8XJ6Q4aPAnzpNpzNaw==} dev: false - /fast-xml-parser@4.3.1: - resolution: {integrity: sha512-viVv3xb8D+SiS1W4cv4tva3bni08kAkx0gQnWrykMM8nXPc1FxqZPU00dCEVjkiCg4HoXd2jC4x29Nzg/l2DAA==} + /fast-xml-parser@4.3.2: + resolution: {integrity: sha512-rmrXUXwbJedoXkStenj1kkljNF7ugn5ZjR9FJcwmCfcCbtOMDghPajbc+Tck6vE6F5XsDmx+Pr2le9fw8+pXBg==} hasBin: true dependencies: strnum: 1.0.5 @@ -17875,7 +17902,7 @@ packages: react: '>=16.6.0' react-dom: '>=16.6.0' dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dom-helpers: 5.2.1 loose-envify: 1.4.0 prop-types: 15.8.1 @@ -19850,8 +19877,8 @@ packages: engines: {node: '>=16'} dev: false - /type-fest@4.3.3: - resolution: {integrity: sha512-bxhiFii6BBv6UiSDq7uKTMyADT9unXEl3ydGefndVLxFeB44LRbT4K7OJGDYSyDrKnklCC1Pre68qT2wbUl2Aw==} + /type-fest@4.4.0: + resolution: {integrity: sha512-HT3RRs7sTfY22KuPQJkD/XjbTbxgP2Je5HPt6H6JEGvcjHd5Lqru75EbrP3tb4FYjNJ+DjLp+MNQTFQU0mhXNw==} engines: {node: '>=16'} dev: false @@ -20909,6 +20936,10 @@ packages: resolution: {integrity: sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==} dev: false + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + dev: false + /zustand@4.3.9(immer@9.0.21)(react@18.2.0): resolution: {integrity: sha512-Tat5r8jOMG1Vcsj8uldMyqYKC5IZvQif8zetmLHs9WoZlntTHmIoNM8TpLRY31ExncuUvUOXehd0kvahkuHjDw==} engines: {node: '>=12.7.0'} @@ -20926,9 +20957,9 @@ packages: use-sync-external-store: 1.2.0(react@18.2.0) dev: false - git/github.com+theopensystemslab/planx-core/d92224b(@types/react@18.2.20): - resolution: {commit: d92224b, repo: git@github.com:theopensystemslab/planx-core.git, type: git} - id: git@github.com+theopensystemslab/planx-core/d92224b + github.com/theopensystemslab/planx-core/3a85966(@types/react@18.2.20): + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} + id: github.com/theopensystemslab/planx-core/3a85966 name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true @@ -20936,14 +20967,14 @@ packages: dependencies: '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) - '@mui/material': 5.14.11(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.14.13(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) '@types/geojson': 7946.0.11 ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) copyfiles: 2.4.1 docx: 8.2.3 - eslint: 8.50.0 - fast-xml-parser: 4.3.1 + eslint: 8.51.0 + fast-xml-parser: 4.3.2 graphql: 16.8.1 graphql-request: 6.1.0(graphql@16.8.1) json-schema-to-typescript: 13.1.1 @@ -20962,9 +20993,9 @@ packages: react: 18.2.0 react-dom: 18.2.0(react@18.2.0) striptags: 3.2.0 - type-fest: 4.3.3 + type-fest: 4.4.0 uuid: 9.0.1 - zod: 3.22.3 + zod: 3.22.4 transitivePeerDependencies: - '@types/react' - encoding From c835985d7674924345da2a125896b625b0519a20 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 10:41:41 +0100 Subject: [PATCH 04/13] [skip pizza] bump @babel/traverse in /hasura.planx.uk/tests (#2317) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.22.8 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- hasura.planx.uk/tests/pnpm-lock.yaml | 97 +++++++++++++++++++++++----- 1 file changed, 80 insertions(+), 17 deletions(-) diff --git a/hasura.planx.uk/tests/pnpm-lock.yaml b/hasura.planx.uk/tests/pnpm-lock.yaml index 951da664c9..075b3a1fcc 100644 --- a/hasura.planx.uk/tests/pnpm-lock.yaml +++ b/hasura.planx.uk/tests/pnpm-lock.yaml @@ -34,6 +34,14 @@ packages: '@jridgewell/trace-mapping': 0.3.18 dev: false + /@babel/code-frame@7.22.13: + resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/highlight': 7.22.20 + chalk: 2.4.2 + dev: false + /@babel/code-frame@7.22.5: resolution: {integrity: sha512-Xmwn266vad+6DAqEB2A6V/CcZVp62BbwVmcOJc2RPuwih1kw02TjQvWVWlcKGbBPd+8/0V5DEkOcizRGYsspYQ==} engines: {node: '>=6.9.0'} @@ -58,7 +66,7 @@ packages: '@babel/helpers': 7.22.6 '@babel/parser': 7.22.7 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.5 '@nicolo-ribaudo/semver-v6': 6.3.3 convert-source-map: 1.9.0 @@ -79,6 +87,16 @@ packages: jsesc: 2.5.2 dev: false + /@babel/generator@7.23.0: + resolution: {integrity: sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.23.0 + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.18 + jsesc: 2.5.2 + dev: false + /@babel/helper-compilation-targets@7.22.6(@babel/core@7.22.8): resolution: {integrity: sha512-534sYEqWD9VfUm3IPn2SLcH4Q3P86XL+QvqdC7ZsFrzyyPF3T4XGiVghF6PTYNdWg6pXuoqXxNQAhbYeEInTzA==} engines: {node: '>=6.9.0'} @@ -93,24 +111,29 @@ packages: lru-cache: 5.1.1 dev: false + /@babel/helper-environment-visitor@7.22.20: + resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} + engines: {node: '>=6.9.0'} + dev: false + /@babel/helper-environment-visitor@7.22.5: resolution: {integrity: sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==} engines: {node: '>=6.9.0'} dev: false - /@babel/helper-function-name@7.22.5: - resolution: {integrity: sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==} + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.22.5 - '@babel/types': 7.22.5 + '@babel/template': 7.22.15 + '@babel/types': 7.23.0 dev: false /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 dev: false /@babel/helper-module-imports@7.22.5: @@ -130,7 +153,7 @@ packages: '@babel/helper-split-export-declaration': 7.22.6 '@babel/helper-validator-identifier': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.5 transitivePeerDependencies: - supports-color @@ -152,7 +175,7 @@ packages: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 dev: false /@babel/helper-string-parser@7.22.5: @@ -160,6 +183,11 @@ packages: engines: {node: '>=6.9.0'} dev: false + /@babel/helper-validator-identifier@7.22.20: + resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} + engines: {node: '>=6.9.0'} + dev: false + /@babel/helper-validator-identifier@7.22.5: resolution: {integrity: sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==} engines: {node: '>=6.9.0'} @@ -175,12 +203,21 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.5 transitivePeerDependencies: - supports-color dev: false + /@babel/highlight@7.22.20: + resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-validator-identifier': 7.22.20 + chalk: 2.4.2 + js-tokens: 4.0.0 + dev: false + /@babel/highlight@7.22.5: resolution: {integrity: sha512-BSKlD1hgnedS5XRnGOljZawtag7H1yPfQp0tdNJCHoH6AZ+Pcm9VvkrK59/Yy593Ypg0zMxH2BxD1VPYUQ7UIw==} engines: {node: '>=6.9.0'} @@ -198,6 +235,14 @@ packages: '@babel/types': 7.22.5 dev: false + /@babel/parser@7.23.0: + resolution: {integrity: sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==} + engines: {node: '>=6.0.0'} + hasBin: true + dependencies: + '@babel/types': 7.23.0 + dev: false + /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.22.8): resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} peerDependencies: @@ -327,6 +372,15 @@ packages: '@babel/helper-plugin-utils': 7.22.5 dev: false + /@babel/template@7.22.15: + resolution: {integrity: sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/code-frame': 7.22.13 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 + dev: false + /@babel/template@7.22.5: resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} engines: {node: '>=6.9.0'} @@ -336,18 +390,18 @@ packages: '@babel/types': 7.22.5 dev: false - /@babel/traverse@7.22.8: - resolution: {integrity: sha512-y6LPR+wpM2I3qJrsheCTwhIinzkETbplIgPBbwvqPKc+uljeA5gP+3nP8irdYt1mjQaDnlIcG+dw8OjAco4GXw==} + /@babel/traverse@7.23.2: + resolution: {integrity: sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.5 - '@babel/generator': 7.22.7 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 + '@babel/code-frame': 7.22.13 + '@babel/generator': 7.23.0 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.7 - '@babel/types': 7.22.5 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: @@ -363,6 +417,15 @@ packages: to-fast-properties: 2.0.0 dev: false + /@babel/types@7.23.0: + resolution: {integrity: sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-string-parser': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 + to-fast-properties: 2.0.0 + dev: false + /@bcoe/v8-coverage@0.2.3: resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} dev: false From 3bc7483f70d16a7f6d4cf55fe7070191da8bbe28 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 11:54:38 +0100 Subject: [PATCH 05/13] chore(deps): bump @babel/traverse in /editor.planx.uk (#2318) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.22.8 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- editor.planx.uk/pnpm-lock.yaml | 207 ++++++++++++++++++++------------- 1 file changed, 124 insertions(+), 83 deletions(-) diff --git a/editor.planx.uk/pnpm-lock.yaml b/editor.planx.uk/pnpm-lock.yaml index b10d4bc73c..7d75980a5b 100644 --- a/editor.planx.uk/pnpm-lock.yaml +++ b/editor.planx.uk/pnpm-lock.yaml @@ -571,6 +571,13 @@ packages: default-browser-id: 3.0.0 dev: true + /@babel/code-frame@7.22.13: + resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/highlight': 7.22.20 + chalk: 2.4.2 + /@babel/code-frame@7.22.5: resolution: {integrity: sha512-Xmwn266vad+6DAqEB2A6V/CcZVp62BbwVmcOJc2RPuwih1kw02TjQvWVWlcKGbBPd+8/0V5DEkOcizRGYsspYQ==} engines: {node: '>=6.9.0'} @@ -597,7 +604,7 @@ packages: '@babel/helpers': 7.22.6 '@babel/parser': 7.22.7 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.5 '@nicolo-ribaudo/semver-v6': 6.3.3 convert-source-map: 1.9.0 @@ -619,8 +626,8 @@ packages: '@babel/helpers': 7.22.6 '@babel/parser': 7.22.7 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 convert-source-map: 1.9.0 debug: 4.3.4 gensync: 1.0.0-beta.2 @@ -646,7 +653,7 @@ packages: resolution: {integrity: sha512-p+jPjMG+SI8yvIaxGgeW24u7q9+5+TGpZh8/CuB7RhBKd7RCy8FayNEFNNKrNK/eUcY/4ExQqLmyrvBXKsIcwQ==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.18 jsesc: 2.5.2 @@ -655,7 +662,16 @@ packages: resolution: {integrity: sha512-KtLMbmicyuK2Ak/FTCJVbDnkN1SlT8/kceFTiuDiiRUUSMnHMidxSCdG4ndkTOHHpoomWe/4xkvHkEOncwjYIw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.18 + jsesc: 2.5.2 + + /@babel/generator@7.23.0: + resolution: {integrity: sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.23.0 '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.18 jsesc: 2.5.2 @@ -664,13 +680,13 @@ packages: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-builder-binary-assignment-operator-visitor@7.22.5: resolution: {integrity: sha512-m1EP3lVOPptR+2DwD125gziZNcmoNSHGmJROKoy87loWUQyJaVXDgpmruWqDARZSmtYQ+Dl25okU8+qhVzuykw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-compilation-targets@7.22.6(@babel/core@7.22.8): resolution: {integrity: sha512-534sYEqWD9VfUm3IPn2SLcH4Q3P86XL+QvqdC7ZsFrzyyPF3T4XGiVghF6PTYNdWg6pXuoqXxNQAhbYeEInTzA==} @@ -733,7 +749,7 @@ packages: dependencies: '@babel/core': 7.22.8 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-member-expression-to-functions': 7.23.0 '@babel/helper-optimise-call-expression': 7.22.5 @@ -751,7 +767,7 @@ packages: dependencies: '@babel/core': 7.22.9 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-member-expression-to-functions': 7.23.0 '@babel/helper-optimise-call-expression': 7.22.5 @@ -768,7 +784,7 @@ packages: dependencies: '@babel/core': 7.22.8 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-member-expression-to-functions': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 @@ -788,7 +804,7 @@ packages: dependencies: '@babel/core': 7.22.9 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-member-expression-to-functions': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 @@ -855,28 +871,31 @@ packages: resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} engines: {node: '>=6.9.0'} - /@babel/helper-environment-visitor@7.22.5: - resolution: {integrity: sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==} - engines: {node: '>=6.9.0'} - /@babel/helper-function-name@7.22.5: resolution: {integrity: sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==} engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.5 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 + + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/template': 7.22.15 + '@babel/types': 7.23.0 /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-member-expression-to-functions@7.22.5: resolution: {integrity: sha512-aBiH1NKMG0H2cGZqspNvsaBe6wNGjbJjuLy29aU+eDZjSbbN53BaxlpB02xm9v34pLTZ1nIQPFYn2qMZoa5BQQ==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-member-expression-to-functions@7.23.0: resolution: {integrity: sha512-6gfrPwh7OuT6gZyJZvd6WbTfrqAo7vm4xCzAXOusKqq/vWdKXphTpj5klHKNmRUU6/QRGlBsyU9mAIPaWHlqJA==} @@ -894,20 +913,20 @@ packages: resolution: {integrity: sha512-8Dl6+HD/cKifutF5qGd/8ZJi84QeAKh+CEe1sBzz8UayBBGg1dAIJrdHOcOM5b2MpzWL2yuotJTtGjETq0qjXg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-module-transforms@7.22.5: resolution: {integrity: sha512-+hGKDt/Ze8GFExiVHno/2dvG5IdstpzCq0y4Qc9OJ25D4q3pKfiIP/4Vp3/JvhDkLKsDK2api3q3fpIgiIF5bw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 '@babel/helper-validator-identifier': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color @@ -918,11 +937,11 @@ packages: '@babel/core': ^7.0.0 dependencies: '@babel/core': 7.22.9 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 /@babel/helper-module-transforms@7.23.0(@babel/core@7.22.8): resolution: {integrity: sha512-WhDWw1tdrlT0gMgUJSlX0IQvoO1eN279zrAUbVB+KpV2c3Tylz8+GnKOLllCS6Z/iZQEyVYxhZVUdPTqs2YYPw==} @@ -955,7 +974,7 @@ packages: resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-plugin-utils@7.22.5: resolution: {integrity: sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==} @@ -969,9 +988,9 @@ packages: dependencies: '@babel/core': 7.22.8 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-wrap-function': 7.22.5 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color dev: true @@ -984,9 +1003,9 @@ packages: dependencies: '@babel/core': 7.22.9 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-wrap-function': 7.22.5 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color @@ -1017,12 +1036,12 @@ packages: resolution: {integrity: sha512-aLdNM5I3kdI/V9xGNyKSF3X/gTyMUBohTZ+/3QdQKAA9vxIiy12E+8E2HoOP1/DjeqU+g6as35QHJNMDDYpuCg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-member-expression-to-functions': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color @@ -1030,19 +1049,19 @@ packages: resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-skip-transparent-expression-wrappers@7.22.5: resolution: {integrity: sha512-tK14r66JZKiC43p8Ki33yLBVJKlQDFoA8GYN67lWCDCqoL6EMMSuM9b+Iff2jHaM/RRFYl7K+iiru7hbRqNx8Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-split-export-declaration@7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@babel/helper-string-parser@7.22.5: resolution: {integrity: sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==} @@ -1070,8 +1089,8 @@ packages: dependencies: '@babel/helper-function-name': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color @@ -1080,16 +1099,24 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 transitivePeerDependencies: - supports-color + /@babel/highlight@7.22.20: + resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-validator-identifier': 7.22.20 + chalk: 2.4.2 + js-tokens: 4.0.0 + /@babel/highlight@7.22.5: resolution: {integrity: sha512-BSKlD1hgnedS5XRnGOljZawtag7H1yPfQp0tdNJCHoH6AZ+Pcm9VvkrK59/Yy593Ypg0zMxH2BxD1VPYUQ7UIw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 chalk: 2.4.2 js-tokens: 4.0.0 @@ -1098,7 +1125,14 @@ packages: engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 + + /@babel/parser@7.23.0: + resolution: {integrity: sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==} + engines: {node: '>=6.0.0'} + hasBin: true + dependencies: + '@babel/types': 7.23.0 /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.22.5(@babel/core@7.22.8): resolution: {integrity: sha512-NP1M5Rf+u2Gw9qfSO4ihjcTGW5zXTi36ITLd4/EoAcEhIZ0yjMqmftDNl3QC19CX7olhrjpyU454g/2W7X0jvQ==} @@ -1701,7 +1735,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.22.8 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-remap-async-to-generator': 7.22.5(@babel/core@7.22.8) '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.8) @@ -1716,7 +1750,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.22.9 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-remap-async-to-generator': 7.22.5(@babel/core@7.22.9) '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.9) @@ -1849,7 +1883,7 @@ packages: '@babel/core': 7.22.8 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-compilation-targets': 7.22.6(@babel/core@7.22.8) - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 @@ -1869,7 +1903,7 @@ packages: '@babel/core': 7.22.9 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-compilation-targets': 7.22.6(@babel/core@7.22.9) - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 @@ -2250,7 +2284,7 @@ packages: '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-module-transforms': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 transitivePeerDependencies: - supports-color dev: true @@ -2265,7 +2299,7 @@ packages: '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-module-transforms': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 transitivePeerDependencies: - supports-color @@ -3180,7 +3214,7 @@ packages: '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.9) '@babel/plugin-transform-unicode-sets-regex': 7.22.5(@babel/core@7.22.9) '@babel/preset-modules': 0.1.5(@babel/core@7.22.9) - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 babel-plugin-polyfill-corejs2: 0.4.4(@babel/core@7.22.9) babel-plugin-polyfill-corejs3: 0.8.2(@babel/core@7.22.9) babel-plugin-polyfill-regenerator: 0.5.1(@babel/core@7.22.9) @@ -3223,7 +3257,7 @@ packages: '@babel/helper-plugin-utils': 7.22.5 '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.22.8) '@babel/plugin-transform-dotall-regex': 7.22.5(@babel/core@7.22.8) - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 esutils: 2.0.3 dev: true @@ -3236,7 +3270,7 @@ packages: '@babel/helper-plugin-utils': 7.22.5 '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.22.9) '@babel/plugin-transform-dotall-regex': 7.22.5(@babel/core@7.22.9) - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 esutils: 2.0.3 /@babel/preset-react@7.22.5(@babel/core@7.22.8): @@ -3330,26 +3364,34 @@ packages: dependencies: regenerator-runtime: 0.14.0 + /@babel/template@7.22.15: + resolution: {integrity: sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/code-frame': 7.22.13 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 + /@babel/template@7.22.5: resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.5 '@babel/parser': 7.22.7 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 - /@babel/traverse@7.22.8: - resolution: {integrity: sha512-y6LPR+wpM2I3qJrsheCTwhIinzkETbplIgPBbwvqPKc+uljeA5gP+3nP8irdYt1mjQaDnlIcG+dw8OjAco4GXw==} + /@babel/traverse@7.23.2: + resolution: {integrity: sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.5 - '@babel/generator': 7.22.7 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 + '@babel/code-frame': 7.22.13 + '@babel/generator': 7.23.0 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.7 - '@babel/types': 7.22.5 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: @@ -5045,8 +5087,8 @@ packages: '@babel/plugin-proposal-export-namespace-from': 7.18.9(@babel/core@7.22.9) '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.9) '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.9) - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 '@linaria/logger': 4.0.0 babel-merge: 3.0.0(@babel/core@7.22.9) transitivePeerDependencies: @@ -5102,13 +5144,13 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@material-ui/styles': 4.11.5(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) '@material-ui/system': 4.12.2(@types/react@18.2.20)(react-dom@18.2.0)(react@18.2.0) '@material-ui/types': 5.1.0(@types/react@18.2.20) '@material-ui/utils': 4.11.3(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.20 - '@types/react-transition-group': 4.4.6 + '@types/react-transition-group': 4.4.7 clsx: 1.2.1 hoist-non-react-statics: 3.3.2 popper.js: 1.16.1-lts @@ -5131,7 +5173,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/hash': 0.8.0 '@material-ui/types': 5.1.0(@types/react@18.2.20) '@material-ui/utils': 4.11.3(react-dom@18.2.0)(react@18.2.0) @@ -5163,7 +5205,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@material-ui/utils': 4.11.3(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.20 csstype: 2.6.21 @@ -5190,7 +5232,7 @@ packages: react: ^16.8.0 || ^17.0.0 react-dom: ^16.8.0 || ^17.0.0 dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 prop-types: 15.8.1 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) @@ -6513,7 +6555,7 @@ packages: dependencies: '@babel/core': 7.22.9 '@babel/preset-env': 7.22.9(@babel/core@7.22.9) - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@ndelangen/get-tarball': 3.0.9 '@storybook/codemod': 7.1.1 '@storybook/core-common': 7.1.1 @@ -6589,7 +6631,7 @@ packages: dependencies: '@babel/core': 7.22.9 '@babel/preset-env': 7.22.9(@babel/core@7.22.9) - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@storybook/csf': 0.1.1 '@storybook/csf-tools': 7.1.1 '@storybook/node-logger': 7.1.1 @@ -6753,8 +6795,8 @@ packages: dependencies: '@babel/generator': 7.22.9 '@babel/parser': 7.22.7 - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 '@storybook/csf': 0.1.1 '@storybook/types': 7.1.1 fs-extra: 11.1.1 @@ -7269,7 +7311,7 @@ packages: resolution: {integrity: sha512-cAaR/CAiZRB8GP32N+1jocovUtvlj0+e65TB50/6Lcime+EA49m/8l+P2ko+XPJ4dw3xaPS3jOL4F2X4KWxoeQ==} engines: {node: '>=10'} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@svgr/plugin-jsx@5.5.0: resolution: {integrity: sha512-V/wVh33j12hGh05IDg8GpIUXbjAPnTdPTKuP4VNLggnwaHMPNQNae2pRnyTAILWCQdz5GyMqtO488g7CKM8CBA==} @@ -7803,7 +7845,7 @@ packages: resolution: {integrity: sha512-aACu/U/omhdk15O4Nfb+fHgH/z3QsfQzpnvRZhYhThms83ZnAOZz7zZAWO7mn2yyNQaA4xTO8GLK3uqFU4bYYw==} dependencies: '@babel/parser': 7.22.7 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@types/babel__generator': 7.6.4 '@types/babel__template': 7.4.1 '@types/babel__traverse': 7.20.1 @@ -7811,18 +7853,18 @@ packages: /@types/babel__generator@7.6.4: resolution: {integrity: sha512-tFkciB9j2K755yrTALxD44McOrk+gfpIpvC3sxHjRawj6PfnQxrse4Clq5y/Rq+G3mrBurMax/lG8Qn2t9mSsg==} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@types/babel__template@7.4.1: resolution: {integrity: sha512-azBFKemX6kMg5Io+/rdGT0dkGreboUVR0Cdm3fz9QJWpaQGJRQXl7C+6hOTCZcMll7KFyEQpgbYI2lHdsS4U7g==} dependencies: '@babel/parser': 7.22.7 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@types/babel__traverse@7.20.1: resolution: {integrity: sha512-MitHFXnhtgwsGZWtT68URpOvLN4EREih1u3QtQiN4VdAxWKRVvGCSvw/Qth0M0Qq3pJpnGOu5JaM/ydK7OGbqg==} dependencies: - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 /@types/body-parser@1.19.2: resolution: {integrity: sha512-ALYone6pm6QmwZoAgeyNksccT9Q4AWZQ6PvfwR37GT6r6FWUPguq6sUmNGSMV2Wr761oQoBxwGGa6DR5o1DC9g==} @@ -8163,12 +8205,12 @@ packages: resolution: {integrity: sha512-VnCdSxfcm08KjsJVQcfBmhEQAPnLB8G08hAxn39azX1qYBQ/5RVQuoHuKIcfKOdncuaUvEpFKFzEvbtIMsfVew==} dependencies: '@types/react': 18.2.20 + dev: false /@types/react-transition-group@4.4.7: resolution: {integrity: sha512-ICCyBl5mvyqYp8Qeq9B5G/fyBSRC0zx3XM3sCC6KkcMsNeAHqXBKkmat4GqdJET5jtYUpZXrxI5flve5qhi2Eg==} dependencies: '@types/react': 18.2.20 - dev: false /@types/react@18.2.20: resolution: {integrity: sha512-WKNtmsLWJM/3D5mG4U84cysVY31ivmyw85dE84fOCk5Hx78wezB/XEjVPWl2JTZ5FkEeaTJf+VgUAUn3PE7Isw==} @@ -9181,7 +9223,7 @@ packages: engines: {node: '>= 10.14.2'} dependencies: '@babel/template': 7.22.5 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@types/babel__core': 7.20.1 '@types/babel__traverse': 7.20.1 dev: true @@ -9191,7 +9233,7 @@ packages: engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: '@babel/template': 7.22.5 - '@babel/types': 7.22.5 + '@babel/types': 7.23.0 '@types/babel__core': 7.20.1 '@types/babel__traverse': 7.20.1 @@ -11922,8 +11964,8 @@ packages: resolution: {integrity: sha512-YNF+mZ/Wu2FU/gvmzuWtYc8rloubL7wfXCTgouFrnjGVXPA/EeYYA7pupXWrb3Iv1cTBeSSxxJIbK23l4MRNqg==} engines: {node: '>=8.3.0'} dependencies: - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 c8: 7.14.0 transitivePeerDependencies: - supports-color @@ -14215,8 +14257,8 @@ packages: '@babel/core': 7.22.9 '@babel/generator': 7.22.9 '@babel/plugin-syntax-typescript': 7.22.5(@babel/core@7.22.9) - '@babel/traverse': 7.22.8 - '@babel/types': 7.22.5 + '@babel/traverse': 7.23.2 + '@babel/types': 7.23.0 '@jest/transform': 27.5.1 '@jest/types': 27.5.1 '@types/babel__traverse': 7.20.1 @@ -20962,7 +21004,6 @@ packages: id: github.com/theopensystemslab/planx-core/3a85966 name: '@opensystemslab/planx-core' version: 1.0.0 - prepare: true requiresBuild: true dependencies: '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) From 34f51590dc3a4e064103df88a8e68c85d8741b94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Tue, 17 Oct 2023 12:05:18 +0100 Subject: [PATCH 06/13] chore: Convert remain /admin endpoint to client (#2320) --- api.planx.uk/admin/session/csv.ts | 8 +++----- api.planx.uk/admin/session/html.ts | 12 +++++------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/api.planx.uk/admin/session/csv.ts b/api.planx.uk/admin/session/csv.ts index df4d348f45..c0c3f2f1c0 100644 --- a/api.planx.uk/admin/session/csv.ts +++ b/api.planx.uk/admin/session/csv.ts @@ -1,6 +1,6 @@ import { stringify } from "csv-stringify"; import { NextFunction, Request, Response } from "express"; -import { getClient } from "../../client"; +import { $api } from "../../client"; /** * @swagger @@ -26,8 +26,7 @@ export async function getCSVData( next: NextFunction, ) { try { - const $client = getClient(); - const responses = await $client.export.csvData(req.params.sessionId); + const responses = await $api.export.csvData(req.params.sessionId); if (req.query?.download) { stringify(responses, { @@ -70,8 +69,7 @@ export async function getRedactedCSVData( next: NextFunction, ) { try { - const $client = getClient(); - const redactedResponses = await $client.export.csvDataRedacted( + const redactedResponses = await $api.export.csvDataRedacted( req.params.sessionId, ); diff --git a/api.planx.uk/admin/session/html.ts b/api.planx.uk/admin/session/html.ts index a83a5e8245..493bd58dd5 100644 --- a/api.planx.uk/admin/session/html.ts +++ b/api.planx.uk/admin/session/html.ts @@ -1,5 +1,5 @@ import { generateApplicationHTML } from "@opensystemslab/planx-core"; -import { getClient } from "../../client"; +import { $api } from "../../client"; import type { RequestHandler } from "express"; import type { PlanXExportData } from "@opensystemslab/planx-core/types"; @@ -20,11 +20,10 @@ type HTMLExportHandler = RequestHandler<{ sessionId: string }, string>; */ export const getHTMLExport: HTMLExportHandler = async (req, res, next) => { try { - const $client = getClient(); - const session = await $client.session.find(req.params.sessionId); + const session = await $api.session.find(req.params.sessionId); if (!session) throw Error(`Unable to find session ${req.params.sessionId}`); - const responses = await $client.export.csvData(req.params.sessionId); + const responses = await $api.export.csvData(req.params.sessionId); const boundingBox = session.data.passport.data["property.boundary.site.buffered"]; @@ -61,11 +60,10 @@ export const getRedactedHTMLExport: HTMLExportHandler = async ( next, ) => { try { - const $client = getClient(); - const session = await $client.session.find(req.params.sessionId); + const session = await $api.session.find(req.params.sessionId); if (!session) throw Error(`Unable to find session ${req.params.sessionId}`); - const redactedResponses = await $client.export.csvDataRedacted( + const redactedResponses = await $api.export.csvDataRedacted( req.params.sessionId, ); const boundingBox = From 7dba169d4ca94ffc1c1e5a44b90aaf0af63e7ec8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 12:12:21 +0100 Subject: [PATCH 07/13] chore(deps-dev): bump @babel/traverse in /api.planx.uk (#2316) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.22.8 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- api.planx.uk/pnpm-lock.yaml | 114 +++++++++++++++++++++++++----------- 1 file changed, 79 insertions(+), 35 deletions(-) diff --git a/api.planx.uk/pnpm-lock.yaml b/api.planx.uk/pnpm-lock.yaml index 7129f470f5..8089877bfe 100644 --- a/api.planx.uk/pnpm-lock.yaml +++ b/api.planx.uk/pnpm-lock.yaml @@ -335,6 +335,14 @@ packages: '@babel/highlight': 7.22.10 chalk: 2.4.2 + /@babel/code-frame@7.22.13: + resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/highlight': 7.22.20 + chalk: 2.4.2 + dev: true + /@babel/compat-data@7.22.9: resolution: {integrity: sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ==} engines: {node: '>=6.9.0'} @@ -352,7 +360,7 @@ packages: '@babel/helpers': 7.22.10 '@babel/parser': 7.22.10 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.10 convert-source-map: 1.9.0 debug: 4.3.4 @@ -373,6 +381,16 @@ packages: jsesc: 2.5.2 dev: true + /@babel/generator@7.23.0: + resolution: {integrity: sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.23.0 + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.18 + jsesc: 2.5.2 + dev: true + /@babel/helper-annotate-as-pure@7.22.5: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} @@ -411,6 +429,11 @@ packages: - supports-color dev: true + /@babel/helper-environment-visitor@7.22.20: + resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} + engines: {node: '>=6.9.0'} + dev: true + /@babel/helper-environment-visitor@7.22.5: resolution: {integrity: sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==} engines: {node: '>=6.9.0'} @@ -424,11 +447,19 @@ packages: '@babel/types': 7.22.10 dev: true + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/template': 7.22.15 + '@babel/types': 7.23.0 + dev: true + /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.10 + '@babel/types': 7.23.0 dev: true /@babel/helper-member-expression-to-functions@7.22.5: @@ -454,7 +485,7 @@ packages: '@babel/helper-split-export-declaration': 7.22.6 '@babel/helper-validator-identifier': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.10 transitivePeerDependencies: - supports-color @@ -494,7 +525,7 @@ packages: '@babel/helper-member-expression-to-functions': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/template': 7.22.5 - '@babel/traverse': 7.22.8 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.10 transitivePeerDependencies: - supports-color @@ -518,13 +549,18 @@ packages: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.10 + '@babel/types': 7.23.0 dev: true /@babel/helper-string-parser@7.22.5: resolution: {integrity: sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==} engines: {node: '>=6.9.0'} + /@babel/helper-validator-identifier@7.22.20: + resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} + engines: {node: '>=6.9.0'} + dev: true + /@babel/helper-validator-identifier@7.22.5: resolution: {integrity: sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==} engines: {node: '>=6.9.0'} @@ -539,7 +575,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.10 transitivePeerDependencies: - supports-color @@ -553,6 +589,15 @@ packages: chalk: 2.4.2 js-tokens: 4.0.0 + /@babel/highlight@7.22.20: + resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-validator-identifier': 7.22.20 + chalk: 2.4.2 + js-tokens: 4.0.0 + dev: true + /@babel/parser@7.22.10: resolution: {integrity: sha512-lNbdGsQb9ekfsnjFGhEiF4hfFqGgfOP3H3d27re3n+CGhNuTSUEQdfWk556sTLNTloczcdM5TYF2LhzmDQKyvQ==} engines: {node: '>=6.0.0'} @@ -561,12 +606,12 @@ packages: '@babel/types': 7.22.10 dev: true - /@babel/parser@7.22.7: - resolution: {integrity: sha512-7NF8pOkHP5o2vpmGgNGcfAeCvOYhGLyA3Z4eBQkT1RJlWu47n63bCs93QfJ2hIAFCil7L5P2IWhs1oToVgrL0Q==} + /@babel/parser@7.23.0: + resolution: {integrity: sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==} engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.22.10 + '@babel/types': 7.23.0 dev: true /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.22.10): @@ -757,45 +802,36 @@ packages: regenerator-runtime: 0.14.0 dev: false - /@babel/template@7.22.5: - resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} + /@babel/template@7.22.15: + resolution: {integrity: sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.10 - '@babel/parser': 7.22.10 - '@babel/types': 7.22.10 + '@babel/code-frame': 7.22.13 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 dev: true - /@babel/traverse@7.22.10: - resolution: {integrity: sha512-Q/urqV4pRByiNNpb/f5OSv28ZlGJiFiiTh+GAHktbIrkPhPbl90+uW6SmpoLyZqutrg9AEaEf3Q/ZBRHBXgxig==} + /@babel/template@7.22.5: + resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 - '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-split-export-declaration': 7.22.6 '@babel/parser': 7.22.10 '@babel/types': 7.22.10 - debug: 4.3.4 - globals: 11.12.0 - transitivePeerDependencies: - - supports-color dev: true - /@babel/traverse@7.22.8: - resolution: {integrity: sha512-y6LPR+wpM2I3qJrsheCTwhIinzkETbplIgPBbwvqPKc+uljeA5gP+3nP8irdYt1mjQaDnlIcG+dw8OjAco4GXw==} + /@babel/traverse@7.23.2: + resolution: {integrity: sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 + '@babel/code-frame': 7.22.13 + '@babel/generator': 7.23.0 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.10 - '@babel/types': 7.22.10 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: @@ -810,6 +846,15 @@ packages: '@babel/helper-validator-identifier': 7.22.5 to-fast-properties: 2.0.0 + /@babel/types@7.23.0: + resolution: {integrity: sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-string-parser': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 + to-fast-properties: 2.0.0 + dev: true + /@bcherny/json-schema-ref-parser@10.0.5-fork: resolution: {integrity: sha512-E/jKbPoca1tfUPj3iSbitDZTGnq6FUFjkH6L8U2oDwSuwK1WhnnVtCG7oFOTg/DDnyoXbQYUiUiGOibHqaGVnw==} engines: {node: '>= 16'} @@ -1862,7 +1907,7 @@ packages: /@types/babel__core@7.20.1: resolution: {integrity: sha512-aACu/U/omhdk15O4Nfb+fHgH/z3QsfQzpnvRZhYhThms83ZnAOZz7zZAWO7mn2yyNQaA4xTO8GLK3uqFU4bYYw==} dependencies: - '@babel/parser': 7.22.7 + '@babel/parser': 7.22.10 '@babel/types': 7.22.10 '@types/babel__generator': 7.6.4 '@types/babel__template': 7.4.1 @@ -8111,7 +8156,6 @@ packages: resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} name: '@opensystemslab/planx-core' version: 1.0.0 - prepare: true requiresBuild: true dependencies: '@emotion/react': 11.11.1(react@18.2.0) From 44eebf07716b8248bdb3b20f3e46f86422ae7691 Mon Sep 17 00:00:00 2001 From: Jessica McInchak Date: Tue, 17 Oct 2023 20:50:37 +0100 Subject: [PATCH 08/13] chore: update local development instructions in README (#2321) --- .env.example | 6 ++++-- README.md | 32 ++++++++++++++++++++++++++++++-- editor.planx.uk/.env | 1 + 3 files changed, 35 insertions(+), 4 deletions(-) diff --git a/.env.example b/.env.example index 4e8efb2dfb..9923f8542a 100644 --- a/.env.example +++ b/.env.example @@ -6,10 +6,12 @@ API_PORT=7002 API_URL_EXT=http://localhost:${API_PORT} +# JWT_SECRET must be at least 32 characters JWT_SECRET=👻 SESSION_SECRET=👻 +# Google Cloud OAuth 2.0 Client ID GOOGLE_CLIENT_ID=👻 GOOGLE_CLIENT_SECRET=👻 @@ -49,9 +51,9 @@ MINIO_ADMIN_PORT=9001 # PostgreSQL PG_PORT=7001 -PG_DATABASE=👻 +PG_DATABASE=planxdb +PG_USERNAME=dbuser PG_PASSWORD=👻 -PG_USERNAME=👻 # PG user with permission to sync content between environments PRODUCTION_PG_URL_FOR_USER_GITHUB_ACTIONS=👻 diff --git a/README.md b/README.md index 975dba3547..fddfd4c0e5 100644 --- a/README.md +++ b/README.md @@ -26,11 +26,14 @@ planx-new is a monorepo containing our full application stack. Here's a quick su 1. Download and install the following dependencies if you don't have them already: - [Docker](https://docs.docker.com/get-docker/) -- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) +- [Docker Compose](https://docs.docker.com/compose/install/) - [PNPM](https://github.com/pnpm/pnpm) `npm install -g pnpm@8.6.6` - [Node](https://nodejs.org/en/download) `pnpm env use --global 18.16.1` +- [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) -1. Clone this repository. +**If you're an OSL developer:** + +1. Clone this repository 2. Setup your AWS CLI client with SSO - [detailed guide here](https://github.com/theopensystemslab/planx-new/blob/main/doc/how-to/how-to-setup-aws-sso-credentials.md) @@ -48,6 +51,30 @@ planx-new is a monorepo containing our full application stack. Here's a quick su 9. Open `http://localhost:3000` and login with your Google email address +**If you're not a member of OSL, follow these steps:** + +1. Fork or clone this repository + +2. Copy all `.example` env files into their respective directories and replace 👻 with a string like "SECRET" or longer where noted + +3. Setup free OAuth Client ID credentails in the [Google Cloud APIs console](https://console.cloud.google.com/apis/credentials) + - Application type = "Web application" + - Authorised JavaScript origins = "http://localhost:3000" + - Authorised redirect URIs = "http://localhost:7002/auth/google/callback" + - Update the `GOOGLE_CLIENT_ID` & `GOOGLE_CLIENT_SECRET` env vars with your new credentials + +4. Run `pnpm start` from the project root to set up docker containers for the application's backend (postgres, sharedb, api and hasura server processes). Please note you will not be able to run commands that sync seed data from production. + +5. Move into the hasura directory `cd ../hasura.planx.uk` and install dependencies `pnpm i`. + +6. Open [Hasura's](https://hasura.io/) web console (`cd hasura.planx.uk` then `pnpm start`) and add your Google email address to the `users` table. You'll also likely want to create an initial `team`. This will eventually allow you to authenticate into the application as an admin. + +7. Follow steps 7-9 above to start the editor and login ! + +At this point you'll be running the full Planx application locally in a docker container. See our Github Actions pull request workflow as an example of how to deploy via docker to a virtual linux server, or explore the `infrastructure` directory for how to deploy via Pulumi infrastructure-as-code to AWS. + +We'd love to hear what you're building on Planx, don't hesitate to get in touch with questions. + ### Docker The root of the project has several scripts set up to help you manage your docker containers: @@ -111,3 +138,4 @@ There are a few dependent packages that are closely related to this project: - https://github.com/theopensystemslab/planx-core - https://github.com/theopensystemslab/map + - https://github.com/theopensystemslab/digital-planning-data-schemas diff --git a/editor.planx.uk/.env b/editor.planx.uk/.env index bfc257b33f..033982c6fe 100644 --- a/editor.planx.uk/.env +++ b/editor.planx.uk/.env @@ -1,5 +1,6 @@ # Used in local development and testing, overwritten in .env.production # This file does not (and should not) contain secrets - all values here are publicly exposed +# If you're working off a fork of Planx, please replace the AIRBRAKE and FEEDBACK_FISH values with a mock value like "SECRET" REACT_APP_AIRBRAKE_PROJECT_ID=329753 REACT_APP_AIRBRAKE_PROJECT_KEY=388fe6f4cc0d6644c923500d5672a5b6 From a58803e5ee6e046156107251962557724541a410 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Wed, 18 Oct 2023 08:40:29 +0100 Subject: [PATCH 09/13] fix: Unique key for `FormWrapper` in `ChecklistComponent` (#2324) * fix: Give FormWrapper unique id, tighten Option type * fix: Linting --- .../src/@planx/components/Checklist/Public.tsx | 8 ++++---- .../src/@planx/components/NextSteps/Public.tsx | 6 +----- .../src/@planx/components/shared/index.ts | 4 ++-- .../pages/FlowEditor/lib/analyticsProvider.tsx | 2 +- editor.planx.uk/src/pages/Preview/StatusPage.tsx | 4 +++- editor.planx.uk/src/ui/NextStepsList.tsx | 16 ++++++++++------ 6 files changed, 21 insertions(+), 19 deletions(-) diff --git a/editor.planx.uk/src/@planx/components/Checklist/Public.tsx b/editor.planx.uk/src/@planx/components/Checklist/Public.tsx index e583700818..f944eac47d 100644 --- a/editor.planx.uk/src/@planx/components/Checklist/Public.tsx +++ b/editor.planx.uk/src/@planx/components/Checklist/Public.tsx @@ -41,7 +41,7 @@ function getFlatOptions({ return options; } if (groupedOptions) { - return groupedOptions.flatMap((group: any) => group.children); + return groupedOptions.flatMap((group) => group.children); } return []; } @@ -142,9 +142,9 @@ const ChecklistComponent: React.FC = ({ {options ? ( - options.map((option: any) => + options.map((option) => layout === ChecklistLayout.Basic ? ( - + = ({ isExpanded ? "-expanded" : "" }`} > - {group.children.map((option: any) => ( + {group.children.map((option) => ( = (props) => { policyRef={props.policyRef} howMeasured={props.howMeasured} /> - + ); }; diff --git a/editor.planx.uk/src/@planx/components/shared/index.ts b/editor.planx.uk/src/@planx/components/shared/index.ts index 2c5bda3cfd..364bc753bd 100644 --- a/editor.planx.uk/src/@planx/components/shared/index.ts +++ b/editor.planx.uk/src/@planx/components/shared/index.ts @@ -19,12 +19,12 @@ export const parseMoreInformation = ( }); export interface Option { - id?: string; + id: string; data: { description?: string; flag?: string; img?: string; - text?: string; + text: string; val?: string; }; } diff --git a/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx b/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx index 3aef3a108f..e7d88a68a8 100644 --- a/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx +++ b/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx @@ -10,7 +10,7 @@ export type AnalyticsType = "init" | "resume"; type AnalyticsLogDirection = AnalyticsType | "forwards" | "backwards"; export type HelpClickMetadata = Record; -export type SelectedUrlsMetadata = Record<'selectedUrls', string[]>; +export type SelectedUrlsMetadata = Record<"selectedUrls", string[]>; let lastAnalyticsLogId: number | undefined = undefined; diff --git a/editor.planx.uk/src/pages/Preview/StatusPage.tsx b/editor.planx.uk/src/pages/Preview/StatusPage.tsx index 898fb0a494..9f80b4003c 100644 --- a/editor.planx.uk/src/pages/Preview/StatusPage.tsx +++ b/editor.planx.uk/src/pages/Preview/StatusPage.tsx @@ -96,7 +96,9 @@ const StatusPage: React.FC = ({ onClick={removeSessionIdSearchParam} sx={contentFlowSpacing} > - Start new application + + Start new application + )} diff --git a/editor.planx.uk/src/ui/NextStepsList.tsx b/editor.planx.uk/src/ui/NextStepsList.tsx index e7feb561f1..5d8bf5b3a8 100644 --- a/editor.planx.uk/src/ui/NextStepsList.tsx +++ b/editor.planx.uk/src/ui/NextStepsList.tsx @@ -80,7 +80,11 @@ function LinkStep(props: ListItemProps) { href={props.url} target="_blank" rel="noopener" - onClick={() => props.handleSelectingUrl && props.url && props.handleSelectingUrl(props.url)} + onClick={() => + props.handleSelectingUrl && + props.url && + props.handleSelectingUrl(props.url) + } > @@ -119,19 +123,19 @@ const Step = ({ title, description, url }: ListItemProps) => ( function NextStepsList(props: NextStepsListProps) { const [selectedUrls, setSelectedUrls] = useState([]); - const { trackNextStepsLinkClick } = useAnalyticsTracking() + const { trackNextStepsLinkClick } = useAnalyticsTracking(); const handleSelectingUrl = (newUrl: string) => { - setSelectedUrls(prevSelectedUrls => [...prevSelectedUrls, newUrl]); - trackNextStepsLinkClick({'selectedUrls': [...selectedUrls, newUrl]}) - } + setSelectedUrls((prevSelectedUrls) => [...prevSelectedUrls, newUrl]); + trackNextStepsLinkClick({ selectedUrls: [...selectedUrls, newUrl] }); + }; return ( {props.steps?.map((step, i) => ( {step.url ? ( - + ) : ( )} From 08f4e1b1fca2441ef1de2640b9745655736245e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Wed, 18 Oct 2023 09:06:26 +0100 Subject: [PATCH 10/13] fix: Drop redundant (and error-throwing) `:first-child` selector (#2325) * fix: Remove redundant :first-child selector * chore: Linting --- editor.planx.uk/src/ui/InputLabel.tsx | 3 --- 1 file changed, 3 deletions(-) diff --git a/editor.planx.uk/src/ui/InputLabel.tsx b/editor.planx.uk/src/ui/InputLabel.tsx index 1cff695688..0ee71532dc 100644 --- a/editor.planx.uk/src/ui/InputLabel.tsx +++ b/editor.planx.uk/src/ui/InputLabel.tsx @@ -6,9 +6,6 @@ import React, { ReactNode } from "react"; const Root = styled("label")(() => ({ display: "block", width: "100%", - "& > :not(:first-child)": { - width: "100%", - }, })); export default function InputLabel(props: { From 35150343a51d585fb62debc3bc9b5eabab3d46e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Wed, 18 Oct 2023 09:25:54 +0100 Subject: [PATCH 11/13] chore: Convert download-schema endpoint to public client (#2305) --- api.planx.uk/server.ts | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/api.planx.uk/server.ts b/api.planx.uk/server.ts index e6d5910e9f..6264fdf11b 100644 --- a/api.planx.uk/server.ts +++ b/api.planx.uk/server.ts @@ -40,7 +40,6 @@ import { } from "./modules/auth/middleware"; import airbrake from "./airbrake"; -import { adminGraphQLClient as adminClient } from "./hasura"; import { sendEmailLimiter, apiLimiter } from "./rateLimit"; import { privateDownloadController, @@ -73,6 +72,7 @@ import webhookRoutes from "./modules/webhooks/routes"; import analyticsRoutes from "./modules/analytics/routes"; import { useSwaggerDocs } from "./docs"; import { Role } from "@opensystemslab/planx-core/types"; +import { $public } from "./client"; const router = express.Router(); @@ -279,13 +279,21 @@ app.get( copyPortalAsFlow, ); -// unauthenticated because accessing flow schema only, no user data +interface FlowSchema { + node: string; + type: string; + text: string; + planx_variable: string; +} + app.get("/flows/:flowId/download-schema", async (req, res, next) => { try { - const schema = await adminClient.request( + const { flowSchema } = await $public.client.request<{ + flowSchema: FlowSchema[]; + }>( gql` query ($flow_id: String!) { - get_flow_schema(args: { published_flow_id: $flow_id }) { + flowSchema: get_flow_schema(args: { published_flow_id: $flow_id }) { node type text @@ -296,7 +304,7 @@ app.get("/flows/:flowId/download-schema", async (req, res, next) => { { flow_id: req.params.flowId }, ); - if (schema.get_flow_schema.length < 1) { + if (!flowSchema.length) { next({ status: 404, message: @@ -304,7 +312,7 @@ app.get("/flows/:flowId/download-schema", async (req, res, next) => { }); } else { // build a CSV and stream it - stringify(schema.get_flow_schema, { header: true }).pipe(res); + stringify(flowSchema, { header: true }).pipe(res); res.header("Content-type", "text/csv"); res.attachment(`${req.params.flowId}.csv`); From 017f77c16e625cea9fed0c98a5d4c3a6520b050c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dafydd=20Ll=C5=B7r=20Pearson?= Date: Wed, 18 Oct 2023 10:00:47 +0100 Subject: [PATCH 12/13] chore: Update `planx-core` (#2323) --- .../inviteToPay/createPaymentSendEvents.ts | 2 +- api.planx.uk/inviteToPay/inviteToPay.ts | 6 +-- api.planx.uk/package.json | 2 +- api.planx.uk/pnpm-lock.yaml | 9 +++-- e2e/tests/api-driven/package.json | 2 +- e2e/tests/api-driven/pnpm-lock.yaml | 29 +++++--------- .../api-driven/src/permissions/helpers.ts | 4 +- e2e/tests/api-driven/src/permissions/steps.ts | 3 +- e2e/tests/ui-driven/package.json | 2 +- e2e/tests/ui-driven/pnpm-lock.yaml | 29 +++++--------- e2e/tests/ui-driven/src/context.ts | 12 +++--- editor.planx.uk/package.json | 2 +- editor.planx.uk/pnpm-lock.yaml | 39 ++++++++++--------- 13 files changed, 62 insertions(+), 79 deletions(-) diff --git a/api.planx.uk/inviteToPay/createPaymentSendEvents.ts b/api.planx.uk/inviteToPay/createPaymentSendEvents.ts index 8a6bee74b9..75f1245ed5 100644 --- a/api.planx.uk/inviteToPay/createPaymentSendEvents.ts +++ b/api.planx.uk/inviteToPay/createPaymentSendEvents.ts @@ -40,7 +40,7 @@ const createPaymentSendEvents = async ( const now = new Date(); const combinedResponse: CombinedResponse = {}; - const session = await $api.getSessionById(payload.sessionId); + const session = await $api.session.find(payload.sessionId); if (!session) { return next({ status: 400, diff --git a/api.planx.uk/inviteToPay/inviteToPay.ts b/api.planx.uk/inviteToPay/inviteToPay.ts index 8d781ca6d5..6dfa87267e 100644 --- a/api.planx.uk/inviteToPay/inviteToPay.ts +++ b/api.planx.uk/inviteToPay/inviteToPay.ts @@ -39,7 +39,7 @@ export async function inviteToPay( } // lock session before creating a payment request - const locked = await $api.lockSession(sessionId); + const locked = await $api.session.lock(sessionId); if (locked === null) { return next( new ServerError({ @@ -63,7 +63,7 @@ export async function inviteToPay( let paymentRequest: PaymentRequest | undefined; try { - paymentRequest = await $api.createPaymentRequest({ + paymentRequest = await $api.paymentRequest.create({ sessionId, applicantName, payeeName, @@ -72,7 +72,7 @@ export async function inviteToPay( }); } catch (e: unknown) { // revert the session lock on failure - await $api.unlockSession(sessionId); + await $api.session.unlock(sessionId); return next( new ServerError({ message: diff --git a/api.planx.uk/package.json b/api.planx.uk/package.json index 2c9e8c3c74..cb4db427f9 100644 --- a/api.planx.uk/package.json +++ b/api.planx.uk/package.json @@ -4,7 +4,7 @@ "private": true, "dependencies": { "@airbrake/node": "^2.1.8", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#c2d6f35", "@types/isomorphic-fetch": "^0.0.36", "adm-zip": "^0.5.10", "aws-sdk": "^2.1467.0", diff --git a/api.planx.uk/pnpm-lock.yaml b/api.planx.uk/pnpm-lock.yaml index 8089877bfe..e2ed371839 100644 --- a/api.planx.uk/pnpm-lock.yaml +++ b/api.planx.uk/pnpm-lock.yaml @@ -9,8 +9,8 @@ dependencies: specifier: ^2.1.8 version: 2.1.8 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 - version: github.com/theopensystemslab/planx-core/3a85966 + specifier: git+https://github.com/theopensystemslab/planx-core#c2d6f35 + version: github.com/theopensystemslab/planx-core/c2d6f35 '@types/isomorphic-fetch': specifier: ^0.0.36 version: 0.0.36 @@ -8152,10 +8152,11 @@ packages: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - github.com/theopensystemslab/planx-core/3a85966: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} + github.com/theopensystemslab/planx-core/c2d6f35: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/c2d6f35} name: '@opensystemslab/planx-core' version: 1.0.0 + prepare: true requiresBuild: true dependencies: '@emotion/react': 11.11.1(react@18.2.0) diff --git a/e2e/tests/api-driven/package.json b/e2e/tests/api-driven/package.json index 48f20ab556..b9a344bcb8 100644 --- a/e2e/tests/api-driven/package.json +++ b/e2e/tests/api-driven/package.json @@ -6,7 +6,7 @@ }, "dependencies": { "@cucumber/cucumber": "^9.3.0", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#c2d6f35", "axios": "^1.4.0", "dotenv": "^16.3.1", "dotenv-expand": "^10.0.0", diff --git a/e2e/tests/api-driven/pnpm-lock.yaml b/e2e/tests/api-driven/pnpm-lock.yaml index 05d1617b15..a3b2a2f2bc 100644 --- a/e2e/tests/api-driven/pnpm-lock.yaml +++ b/e2e/tests/api-driven/pnpm-lock.yaml @@ -9,8 +9,8 @@ dependencies: specifier: ^9.3.0 version: 9.3.0 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 - version: github.com/theopensystemslab/planx-core/3a85966 + specifier: git+https://github.com/theopensystemslab/planx-core#c2d6f35 + version: github.com/theopensystemslab/planx-core/c2d6f35 axios: specifier: ^1.4.0 version: 1.4.0 @@ -87,13 +87,6 @@ packages: js-tokens: 4.0.0 dev: false - /@babel/runtime@7.22.15: - resolution: {integrity: sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==} - engines: {node: '>=6.9.0'} - dependencies: - regenerator-runtime: 0.14.0 - dev: false - /@babel/runtime@7.22.6: resolution: {integrity: sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ==} engines: {node: '>=6.9.0'} @@ -278,7 +271,7 @@ packages: resolution: {integrity: sha512-m4HEDZleaaCH+XgDDsPF15Ht6wTLsgDTeR3WYj9Q/k76JtWhrJjcP4+/XlG8LGT/Rol9qUfOIztXeA84ATpqPQ==} dependencies: '@babel/helper-module-imports': 7.22.5 - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/hash': 0.9.1 '@emotion/memoize': 0.8.1 '@emotion/serialize': 1.1.2 @@ -323,7 +316,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/cache': 11.11.0 '@emotion/serialize': 1.1.2 @@ -358,7 +351,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/is-prop-valid': 1.2.1 '@emotion/react': 11.11.1(react@18.2.0) @@ -744,10 +737,6 @@ packages: resolution: {integrity: sha512-+68kP9yzs4LMp7VNh8gdzMSPZFL44MLGqiHWvttYJe+6qnuVr4Ek9wSBQoveqY/r+LwjCcU29kNVkidwim+kYA==} dev: false - /@types/prop-types@15.7.5: - resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} - dev: false - /@types/prop-types@15.7.8: resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} dev: false @@ -761,7 +750,7 @@ packages: /@types/react@18.2.18: resolution: {integrity: sha512-da4NTSeBv/P34xoZPhtcLkmZuJ+oYaCxHmyHzwaDQo9RQPBeXV+06gEk2FpqEcsX9XrnNLvRpVh6bdavDSjtiQ==} dependencies: - '@types/prop-types': 15.7.5 + '@types/prop-types': 15.7.8 '@types/scheduler': 0.16.3 csstype: 3.1.2 dev: false @@ -892,7 +881,7 @@ packages: resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} engines: {node: '>=10', npm: '>=6'} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 cosmiconfig: 7.1.0 resolve: 1.22.2 dev: false @@ -2726,8 +2715,8 @@ packages: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - github.com/theopensystemslab/planx-core/3a85966: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} + github.com/theopensystemslab/planx-core/c2d6f35: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/c2d6f35} name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true diff --git a/e2e/tests/api-driven/src/permissions/helpers.ts b/e2e/tests/api-driven/src/permissions/helpers.ts index 0f6d829a28..c191c0cfd9 100644 --- a/e2e/tests/api-driven/src/permissions/helpers.ts +++ b/e2e/tests/api-driven/src/permissions/helpers.ts @@ -58,6 +58,8 @@ export const setup = async () => { return world; }; +export type GQLQueryResult = unknown[] | Record<"returning", unknown[]> | null; + export const performGQLQuery = async ({ world, action, @@ -66,7 +68,7 @@ export const performGQLQuery = async ({ const query = queries[table][action]; const variables = buildVariables(query, world); const client = (await getClient(world.activeUserEmail)).client; - const { result } = await client.request>( + const { result } = await client.request>( query, variables, ); diff --git a/e2e/tests/api-driven/src/permissions/steps.ts b/e2e/tests/api-driven/src/permissions/steps.ts index d0dc8e175c..31d84c5880 100644 --- a/e2e/tests/api-driven/src/permissions/steps.ts +++ b/e2e/tests/api-driven/src/permissions/steps.ts @@ -3,6 +3,7 @@ import { strict as assert } from "node:assert"; import { getUser } from "../globalHelpers"; import { Action, + GQLQueryResult, Table, addUserToTeam, cleanup, @@ -28,7 +29,7 @@ export class CustomWorld extends World { activeUserEmail!: string; error?: Error = undefined; - result: unknown[] | Record<"returning", unknown[]> | null = null; + result: GQLQueryResult = null; } Before("@team-admin-permissions", async function () { diff --git a/e2e/tests/ui-driven/package.json b/e2e/tests/ui-driven/package.json index f029be3d67..105b72501f 100644 --- a/e2e/tests/ui-driven/package.json +++ b/e2e/tests/ui-driven/package.json @@ -8,7 +8,7 @@ "postinstall": "./install-dependencies.sh" }, "dependencies": { - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#c2d6f35", "axios": "^1.4.0", "dotenv": "^16.3.1", "eslint": "^8.44.0", diff --git a/e2e/tests/ui-driven/pnpm-lock.yaml b/e2e/tests/ui-driven/pnpm-lock.yaml index cedd2fda9c..c252e37c2e 100644 --- a/e2e/tests/ui-driven/pnpm-lock.yaml +++ b/e2e/tests/ui-driven/pnpm-lock.yaml @@ -6,8 +6,8 @@ settings: dependencies: '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 - version: github.com/theopensystemslab/planx-core/3a85966 + specifier: git+https://github.com/theopensystemslab/planx-core#c2d6f35 + version: github.com/theopensystemslab/planx-core/c2d6f35 axios: specifier: ^1.4.0 version: 1.4.0 @@ -87,13 +87,6 @@ packages: js-tokens: 4.0.0 dev: false - /@babel/runtime@7.22.15: - resolution: {integrity: sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==} - engines: {node: '>=6.9.0'} - dependencies: - regenerator-runtime: 0.14.0 - dev: false - /@babel/runtime@7.23.2: resolution: {integrity: sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg==} engines: {node: '>=6.9.0'} @@ -124,7 +117,7 @@ packages: resolution: {integrity: sha512-m4HEDZleaaCH+XgDDsPF15Ht6wTLsgDTeR3WYj9Q/k76JtWhrJjcP4+/XlG8LGT/Rol9qUfOIztXeA84ATpqPQ==} dependencies: '@babel/helper-module-imports': 7.22.5 - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/hash': 0.9.1 '@emotion/memoize': 0.8.1 '@emotion/serialize': 1.1.2 @@ -169,7 +162,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/cache': 11.11.0 '@emotion/serialize': 1.1.2 @@ -204,7 +197,7 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/babel-plugin': 11.11.0 '@emotion/is-prop-valid': 1.2.1 '@emotion/react': 11.11.1(react@18.2.0) @@ -575,10 +568,6 @@ packages: resolution: {integrity: sha512-+68kP9yzs4LMp7VNh8gdzMSPZFL44MLGqiHWvttYJe+6qnuVr4Ek9wSBQoveqY/r+LwjCcU29kNVkidwim+kYA==} dev: false - /@types/prop-types@15.7.5: - resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} - dev: false - /@types/prop-types@15.7.8: resolution: {integrity: sha512-kMpQpfZKSCBqltAJwskgePRaYRFukDkm1oItcAbC3gNELR20XIBcN9VRgg4+m8DKsTfkWeA4m4Imp4DDuWy7FQ==} dev: false @@ -592,7 +581,7 @@ packages: /@types/react@18.2.20: resolution: {integrity: sha512-WKNtmsLWJM/3D5mG4U84cysVY31ivmyw85dE84fOCk5Hx78wezB/XEjVPWl2JTZ5FkEeaTJf+VgUAUn3PE7Isw==} dependencies: - '@types/prop-types': 15.7.5 + '@types/prop-types': 15.7.8 '@types/scheduler': 0.16.3 csstype: 3.1.2 dev: false @@ -728,7 +717,7 @@ packages: resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} engines: {node: '>=10', npm: '>=6'} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 cosmiconfig: 7.1.0 resolve: 1.22.4 dev: false @@ -2502,8 +2491,8 @@ packages: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - github.com/theopensystemslab/planx-core/3a85966: - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} + github.com/theopensystemslab/planx-core/c2d6f35: + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/c2d6f35} name: '@opensystemslab/planx-core' version: 1.0.0 prepare: true diff --git a/e2e/tests/ui-driven/src/context.ts b/e2e/tests/ui-driven/src/context.ts index 788230a062..88972b80dd 100644 --- a/e2e/tests/ui-driven/src/context.ts +++ b/e2e/tests/ui-driven/src/context.ts @@ -15,7 +15,7 @@ export interface Context { team: { id?: number; name: string; - slug?: string; + slug: string; logo: string; primaryColor: string; homepage: string; @@ -50,13 +50,13 @@ export const contextDefaults: Context = { export async function setUpTestContext( initialContext: Context, ): Promise { - const core = getCoreDomainClient(); + const $admin = getCoreDomainClient(); const context: Context = { ...initialContext }; if (context.user) { - context.user.id = await core.createUser(context.user); + context.user.id = await $admin.user.create(context.user); } if (context.team) { - context.team.id = await core.createTeam({ + context.team.id = await $admin.team.create({ slug: context.team.slug, name: context.team.name, logo: context.team.logo, @@ -71,12 +71,12 @@ export async function setUpTestContext( context.team?.id && context.user?.id ) { - context.flow.id = await core.createFlow({ + context.flow.id = await $admin.flow.create({ slug: context.flow.slug, teamId: context.team.id, data: context.flow!.data!, }); - context.flow.publishedId = await core.publishFlow({ + context.flow.publishedId = await $admin.flow.publish({ flow: { id: context.flow.id, data: context.flow!.data!, diff --git a/editor.planx.uk/package.json b/editor.planx.uk/package.json index 8ea7b375b7..a6bc59d031 100644 --- a/editor.planx.uk/package.json +++ b/editor.planx.uk/package.json @@ -14,7 +14,7 @@ "@mui/styles": "^5.14.5", "@mui/utils": "^5.14.5", "@opensystemslab/map": "^0.7.5", - "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#3a85966", + "@opensystemslab/planx-core": "git+https://github.com/theopensystemslab/planx-core#c2d6f35", "@tiptap/core": "^2.0.3", "@tiptap/extension-bold": "^2.0.3", "@tiptap/extension-bubble-menu": "^2.1.6", diff --git a/editor.planx.uk/pnpm-lock.yaml b/editor.planx.uk/pnpm-lock.yaml index 7d75980a5b..df6573388b 100644 --- a/editor.planx.uk/pnpm-lock.yaml +++ b/editor.planx.uk/pnpm-lock.yaml @@ -46,8 +46,8 @@ dependencies: specifier: ^0.7.5 version: 0.7.5 '@opensystemslab/planx-core': - specifier: git+https://github.com/theopensystemslab/planx-core#3a85966 - version: github.com/theopensystemslab/planx-core/3a85966(@types/react@18.2.20) + specifier: git+https://github.com/theopensystemslab/planx-core#c2d6f35 + version: github.com/theopensystemslab/planx-core/c2d6f35(@types/react@18.2.20) '@tiptap/core': specifier: ^2.0.3 version: 2.0.3(@tiptap/pm@2.0.3) @@ -4002,7 +4002,7 @@ packages: '@emotion/core': ^10.0.28 react: '>=16.3.0' dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/core': 10.3.1(react@18.2.0) '@emotion/is-prop-valid': 0.8.8 '@emotion/serialize': 0.11.16 @@ -5403,8 +5403,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@mui/utils': 5.14.11(@types/react@18.2.20)(react@18.2.0) + '@babel/runtime': 7.23.2 + '@mui/utils': 5.14.13(@types/react@18.2.20)(react@18.2.0) '@types/react': 18.2.20 prop-types: 15.8.1 react: 18.2.0 @@ -5457,7 +5457,7 @@ packages: '@emotion/styled': optional: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@emotion/cache': 11.11.0 '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.20)(react@18.2.0) @@ -5611,8 +5611,8 @@ packages: '@types/react': optional: true dependencies: - '@babel/runtime': 7.22.15 - '@types/prop-types': 15.7.5 + '@babel/runtime': 7.23.2 + '@types/prop-types': 15.7.8 '@types/react': 18.2.20 prop-types: 15.8.1 react: 18.2.0 @@ -5934,13 +5934,13 @@ packages: /@remirror/core-constants@2.0.1: resolution: {integrity: sha512-ZR4aihtnnT9lMbhh5DEbsriJRlukRXmLZe7HmM+6ufJNNUDoazc75UX26xbgQlNUqgAqMcUdGFAnPc1JwgAdLQ==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dev: false /@remirror/core-helpers@2.0.3: resolution: {integrity: sha512-LqIPF4stGG69l9qu/FFicv9d9B+YaItzgDMC5A0CEvDQfKkGD3BfabLmfpnuWbsc06oKGdTduilgWcALLZoYLg==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@linaria/core': 4.2.9 '@remirror/core-constants': 2.0.1 '@remirror/types': 1.0.1 @@ -9240,7 +9240,7 @@ packages: /babel-plugin-macros@2.8.0: resolution: {integrity: sha512-SEP5kJpfGYqYKpBrj5XU3ahw5p5GOHJ0U5ssOSQ/WBVdwkD2Dzlce95exQTs3jOVWPPKLBN2rlEWkCK7dSmLvg==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 cosmiconfig: 6.0.0 resolve: 1.22.2 dev: true @@ -9249,7 +9249,7 @@ packages: resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} engines: {node: '>=10', npm: '>=6'} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 cosmiconfig: 7.1.0 resolve: 1.22.2 @@ -9759,7 +9759,7 @@ packages: engines: {node: '>=10.0.0'} requiresBuild: true dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@types/raf': 3.4.0 core-js: 3.31.1 raf: 3.4.1 @@ -10476,7 +10476,7 @@ packages: /css-vendor@2.0.8: resolution: {integrity: sha512-x9Aq0XTInxrkuFeHKbYC7zWY8ai7qJ04Kxd9MnvbC1uO5DagxoHQjm4JvG+vCdXOoFtCjbL2XSZfxmoYa9uQVQ==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 is-in-browser: 1.1.3 /css-what@3.4.2: @@ -18409,7 +18409,7 @@ packages: /rtl-css-js@1.16.1: resolution: {integrity: sha512-lRQgou1mu19e+Ya0LsTvKrVJ5TYUbqCVPAiImX3UfLTenarvPUl1QFdvu5Z3PYmHT9RCcwIfbjRQBntExyj3Zg==} dependencies: - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 dev: false /run-parallel@1.2.0: @@ -20645,7 +20645,7 @@ packages: '@apideck/better-ajv-errors': 0.3.6(ajv@8.12.0) '@babel/core': 7.22.9 '@babel/preset-env': 7.22.7(@babel/core@7.22.9) - '@babel/runtime': 7.22.15 + '@babel/runtime': 7.23.2 '@rollup/plugin-babel': 5.3.1(@babel/core@7.22.9)(rollup@2.79.1) '@rollup/plugin-node-resolve': 11.2.1(rollup@2.79.1) '@rollup/plugin-replace': 2.4.2(rollup@2.79.1) @@ -20999,11 +20999,12 @@ packages: use-sync-external-store: 1.2.0(react@18.2.0) dev: false - github.com/theopensystemslab/planx-core/3a85966(@types/react@18.2.20): - resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/3a85966} - id: github.com/theopensystemslab/planx-core/3a85966 + github.com/theopensystemslab/planx-core/c2d6f35(@types/react@18.2.20): + resolution: {tarball: https://codeload.github.com/theopensystemslab/planx-core/tar.gz/c2d6f35} + id: github.com/theopensystemslab/planx-core/c2d6f35 name: '@opensystemslab/planx-core' version: 1.0.0 + prepare: true requiresBuild: true dependencies: '@emotion/react': 11.11.1(@types/react@18.2.20)(react@18.2.0) From 9515b88f4af41e81529e07aa22cf467857b46f06 Mon Sep 17 00:00:00 2001 From: Mike <36415632+Mike-Heneghan@users.noreply.github.com> Date: Wed, 18 Oct 2023 10:08:56 +0100 Subject: [PATCH 13/13] feat: track user resetting flow (#2307) * feat: track user resetting flow - Update `analytics_log` record for node which was reset on reset confirmation - Change flow_direction to "reset" to store this user action - Amend update permission to allow flow_direction to be changed - Currently, the new "reset" type will only be applied to the flow_direction property --- .../src/@planx/components/Notice/Public.tsx | 10 ++++++- editor.planx.uk/src/components/Header.tsx | 3 +++ .../FlowEditor/lib/analyticsProvider.tsx | 26 ++++++++++++++++++- hasura.planx.uk/metadata/tables.yaml | 1 + 4 files changed, 38 insertions(+), 2 deletions(-) diff --git a/editor.planx.uk/src/@planx/components/Notice/Public.tsx b/editor.planx.uk/src/@planx/components/Notice/Public.tsx index a6ce0f753a..4fd28a55ee 100644 --- a/editor.planx.uk/src/@planx/components/Notice/Public.tsx +++ b/editor.planx.uk/src/@planx/components/Notice/Public.tsx @@ -9,6 +9,7 @@ import Card from "@planx/components/shared/Preview/Card"; import { contentFlowSpacing } from "@planx/components/shared/Preview/Card"; import QuestionHeader from "@planx/components/shared/Preview/QuestionHeader"; import { PublicProps } from "@planx/components/ui"; +import { useAnalyticsTracking } from "pages/FlowEditor/lib/analyticsProvider"; import React from "react"; import { getContrastTextColor } from "styleUtils"; import { FONT_WEIGHT_SEMI_BOLD } from "theme"; @@ -75,6 +76,13 @@ const NoticeComponent: React.FC = (props) => { ? () => props.handleSubmit?.() : undefined; + const { trackResetFlow } = useAnalyticsTracking(); + + const handleNoticeResetClick = () => { + trackResetFlow(); + props.resetPreview && props.resetPreview(); + }; + return ( <> @@ -105,7 +113,7 @@ const NoticeComponent: React.FC = (props) => { variant="contained" size="large" type="submit" - onClick={props.resetPreview} + onClick={handleNoticeResetClick} sx={contentFlowSpacing} > Back to start diff --git a/editor.planx.uk/src/components/Header.tsx b/editor.planx.uk/src/components/Header.tsx index d8ea18c2c9..5d79fbe161 100644 --- a/editor.planx.uk/src/components/Header.tsx +++ b/editor.planx.uk/src/components/Header.tsx @@ -315,6 +315,8 @@ const PublicToolbar: React.FC<{ const showCentredServiceTitle = useMediaQuery((theme: Theme) => theme.breakpoints.up("md"), ); + + const { trackResetFlow } = useAnalyticsTracking(); const handleRestart = async () => { if ( @@ -322,6 +324,7 @@ const PublicToolbar: React.FC<{ "Are you sure you want to restart? This will delete your previous answers", ) ) { + trackResetFlow(); if (path === ApplicationPath.SingleSession) { clearLocalFlow(id); window.location.reload(); diff --git a/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx b/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx index e7d88a68a8..1c309f663f 100644 --- a/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx +++ b/editor.planx.uk/src/pages/FlowEditor/lib/analyticsProvider.tsx @@ -7,7 +7,7 @@ import React, { createContext, useContext, useEffect, useState } from "react"; import { Store, useStore } from "./store"; export type AnalyticsType = "init" | "resume"; -type AnalyticsLogDirection = AnalyticsType | "forwards" | "backwards"; +type AnalyticsLogDirection = AnalyticsType | "forwards" | "backwards" | "reset"; export type HelpClickMetadata = Record; export type SelectedUrlsMetadata = Record<"selectedUrls", string[]>; @@ -18,11 +18,13 @@ const analyticsContext = createContext<{ createAnalytics: (type: AnalyticsType) => Promise; trackHelpClick: (metadata?: HelpClickMetadata) => Promise; trackNextStepsLinkClick: (metadata?: SelectedUrlsMetadata) => Promise; + trackResetFlow: () => Promise; node: Store.node | null; }>({ createAnalytics: () => Promise.resolve(), trackHelpClick: () => Promise.resolve(), trackNextStepsLinkClick: () => Promise.resolve(), + trackResetFlow: () => Promise.resolve(), node: null, }); const { Provider } = analyticsContext; @@ -104,6 +106,7 @@ export const AnalyticsProvider: React.FC<{ children: React.ReactNode }> = ({ createAnalytics, trackHelpClick, trackNextStepsLinkClick, + trackResetFlow, node, }} > @@ -199,6 +202,27 @@ export const AnalyticsProvider: React.FC<{ children: React.ReactNode }> = ({ } } + async function trackResetFlow() { + if (shouldTrackAnalytics && lastAnalyticsLogId) { + await publicClient.mutate({ + mutation: gql` + mutation UpdateHasResetFlow($id: bigint!, $flow_direction: String) { + update_analytics_logs_by_pk( + pk_columns: { id: $id } + _set: { flow_direction: $flow_direction } + ) { + id + } + } + `, + variables: { + id: lastAnalyticsLogId, + flow_direction: "reset", + }, + }); + } + } + async function createAnalytics(type: AnalyticsType) { if (shouldTrackAnalytics) { const response = await publicClient.mutate({ diff --git a/hasura.planx.uk/metadata/tables.yaml b/hasura.planx.uk/metadata/tables.yaml index 5b5f621381..0ee1f16c77 100644 --- a/hasura.planx.uk/metadata/tables.yaml +++ b/hasura.planx.uk/metadata/tables.yaml @@ -44,6 +44,7 @@ - role: public permission: columns: + - flow_direction - has_clicked_help - metadata filter: {}