diff --git a/.nvmrc b/.nvmrc index 11ebcd0e4..03b982a27 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -23.2.0 +23.4.0 diff --git a/Dockerfile b/Dockerfile index 7f2a6c486..4383538a2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ ######################################################################################################################## ######################################################################################################################## -FROM node:23.2.0 AS updated-local +FROM node:23.4.0 AS updated-local ENV TZ=Europe/Amsterdam ENV CI=true diff --git a/package-lock.json b/package-lock.json index 20fc68070..722699edf 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,7 +17,6 @@ "@microsoft/applicationinsights-react-js": "^17.3.4", "@microsoft/applicationinsights-web": "^3.3.4", "@react-spring/web": "^9.7.5", - "@rollup/rollup-linux-x64-gnu": "4.28.1", "@testing-library/dom": "^10.4.0", "@testing-library/jest-dom": "^6.6.3", "@testing-library/react": "^16.1.0", @@ -37,7 +36,7 @@ "@types/memoizee": "^0.4.11", "@types/memory-cache": "^0.2.6", "@types/morgan": "^1.9.9", - "@types/node": "^22.10.1", + "@types/node": "^22.10.2", "@types/node-jose": "^1.1.13", "@types/pg": "^8.11.10", "@types/proj4": "^2.5.5", @@ -59,7 +58,7 @@ "cookie-parser": "^1.4.7", "cookie-session": "^2.1.0", "cors": "^2.8.5", - "cron": "^3.3.0", + "cron": "^3.3.1", "cross-env": "^7.0.3", "date-fns": "^4.1.0", "decimal.js": "^10.4.3", @@ -69,7 +68,7 @@ "express-basic-auth": "^1.2.1", "express-http-proxy": "^2.1.1", "express-openid-connect": "^2.17.1", - "flat-cache": "^6.1.3", + "flat-cache": "^6.1.4", "form-data": "^4.0.1", "fuse.js": "^7.0.0", "html-to-ast": "^0.0.6", @@ -108,7 +107,7 @@ "react-test-renderer": "^18.3.1", "recoil": "^0.7.7", "sanitize-html": "^2.13.1", - "sass": "^1.82.0", + "sass": "^1.83.0", "slugme": "^1.1.1", "supercluster": "^7.1.5", "thenby": "^1.3.4", @@ -124,15 +123,15 @@ "xlsx": "file:vendor/xlsx-0.20.2.tgz" }, "devDependencies": { - "@eslint/js": "^9.16.0", + "@eslint/js": "^9.17.0", "@mocks-server/main": "^4.1.0", - "eslint": "^9.16.0", + "eslint": "^9.17.0", "eslint-plugin-import": "^2.31.0", "eslint-plugin-react": "^7.37.2", "eslint-plugin-unused-imports": "^4.1.0", "formidable": "^3.5.2", "globals": "^15.13.0", - "typescript-eslint": "^8.18.0" + "typescript-eslint": "^8.18.1" }, "engines": { "node": ">=22.4", @@ -856,6 +855,81 @@ "kuler": "^2.0.0" } }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, "node_modules/@esbuild/darwin-x64": { "version": "0.21.5", "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", @@ -871,6 +945,246 @@ "node": ">=12" } }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -1030,10 +1344,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.16.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.16.0.tgz", - "integrity": "sha512-tw2HxzQkrbeuvyj1tG2Yqq+0H9wGoI2IMk4EOsQeX+vmd75FtJAzf+gTA69WF+baUKRYQ3x2kbLE08js5OsTVg==", - "license": "MIT", + "version": "9.17.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.17.0.tgz", + "integrity": "sha512-Sxc4hqcs1kTu0iID3kcZDW3JHq2a77HO9P8CP6YEA/FpH3Ll8UXE2r/86Rz9YJLKme39S9vU5OWNjC6Xl0Cr3w==", "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } @@ -1280,7 +1593,6 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.0.1.tgz", "integrity": "sha512-kKXeynfORDGPUEEl2PvTExM2zs+IldC6ZD8jPcfvI351MDNtfMlw9V9s4XZXuJNDK2qR5gbEKxRyoYx3quHUVQ==", - "license": "MIT", "dependencies": { "buffer": "^6.0.3" } @@ -4427,10 +4739,9 @@ } }, "node_modules/@types/node": { - "version": "22.10.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.1.tgz", - "integrity": "sha512-qKgsUwfHZV2WCWLAnVP1JqnpE6Im6h3Y0+fYgMTasNQ7V++CBX5OT1as0g0f+OyubbFqhf6XVNIsmN4IIhEgGQ==", - "license": "MIT", + "version": "22.10.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.2.tgz", + "integrity": "sha512-Xxr6BBRCAOQixvonOye19wnzyDiUtTeqldOOmj3CkeblonbccA12PFwlufvRdrpjXxqnmUaeiU5EOA+7s5diUQ==", "dependencies": { "undici-types": "~6.20.0" } @@ -4590,16 +4901,16 @@ "integrity": "sha512-RwEfbxqXKEay2b5p8QQVllfnMbVPUZChiKKZ2M6+OSRRmvr4HTCCUZTWhr/QlmrMnNE0ViNBBbP1+5plF9OGRw==" }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.18.0.tgz", - "integrity": "sha512-NR2yS7qUqCL7AIxdJUQf2MKKNDVNaig/dEB0GBLU7D+ZdHgK1NoH/3wsgO3OnPVipn51tG3MAwaODEGil70WEw==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.18.1.tgz", + "integrity": "sha512-Ncvsq5CT3Gvh+uJG0Lwlho6suwDfUXH0HztslDf5I+F2wAFAZMRwYLEorumpKLzmO2suAXZ/td1tBg4NZIi9CQ==", "dev": true, "dependencies": { "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.18.0", - "@typescript-eslint/type-utils": "8.18.0", - "@typescript-eslint/utils": "8.18.0", - "@typescript-eslint/visitor-keys": "8.18.0", + "@typescript-eslint/scope-manager": "8.18.1", + "@typescript-eslint/type-utils": "8.18.1", + "@typescript-eslint/utils": "8.18.1", + "@typescript-eslint/visitor-keys": "8.18.1", "graphemer": "^1.4.0", "ignore": "^5.3.1", "natural-compare": "^1.4.0", @@ -4619,15 +4930,15 @@ } }, "node_modules/@typescript-eslint/parser": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.18.0.tgz", - "integrity": "sha512-hgUZ3kTEpVzKaK3uNibExUYm6SKKOmTU2BOxBSvOYwtJEPdVQ70kZJpPjstlnhCHcuc2WGfSbpKlb/69ttyN5Q==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.18.1.tgz", + "integrity": "sha512-rBnTWHCdbYM2lh7hjyXqxk70wvon3p2FyaniZuey5TrcGBpfhVp0OxOa6gxr9Q9YhZFKyfbEnxc24ZnVbbUkCA==", "dev": true, "dependencies": { - "@typescript-eslint/scope-manager": "8.18.0", - "@typescript-eslint/types": "8.18.0", - "@typescript-eslint/typescript-estree": "8.18.0", - "@typescript-eslint/visitor-keys": "8.18.0", + "@typescript-eslint/scope-manager": "8.18.1", + "@typescript-eslint/types": "8.18.1", + "@typescript-eslint/typescript-estree": "8.18.1", + "@typescript-eslint/visitor-keys": "8.18.1", "debug": "^4.3.4" }, "engines": { @@ -4643,13 +4954,13 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.18.0.tgz", - "integrity": "sha512-PNGcHop0jkK2WVYGotk/hxj+UFLhXtGPiGtiaWgVBVP1jhMoMCHlTyJA+hEj4rszoSdLTK3fN4oOatrL0Cp+Xw==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.18.1.tgz", + "integrity": "sha512-HxfHo2b090M5s2+/9Z3gkBhI6xBH8OJCFjH9MhQ+nnoZqxU3wNxkLT+VWXWSFWc3UF3Z+CfPAyqdCTdoXtDPCQ==", "dev": true, "dependencies": { - "@typescript-eslint/types": "8.18.0", - "@typescript-eslint/visitor-keys": "8.18.0" + "@typescript-eslint/types": "8.18.1", + "@typescript-eslint/visitor-keys": "8.18.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4660,13 +4971,13 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.18.0.tgz", - "integrity": "sha512-er224jRepVAVLnMF2Q7MZJCq5CsdH2oqjP4dT7K6ij09Kyd+R21r7UVJrF0buMVdZS5QRhDzpvzAxHxabQadow==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.18.1.tgz", + "integrity": "sha512-jAhTdK/Qx2NJPNOTxXpMwlOiSymtR2j283TtPqXkKBdH8OAMmhiUfP0kJjc/qSE51Xrq02Gj9NY7MwK+UxVwHQ==", "dev": true, "dependencies": { - "@typescript-eslint/typescript-estree": "8.18.0", - "@typescript-eslint/utils": "8.18.0", + "@typescript-eslint/typescript-estree": "8.18.1", + "@typescript-eslint/utils": "8.18.1", "debug": "^4.3.4", "ts-api-utils": "^1.3.0" }, @@ -4683,9 +4994,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.18.0.tgz", - "integrity": "sha512-FNYxgyTCAnFwTrzpBGq+zrnoTO4x0c1CKYY5MuUTzpScqmY5fmsh2o3+57lqdI3NZucBDCzDgdEbIaNfAjAHQA==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.18.1.tgz", + "integrity": "sha512-7uoAUsCj66qdNQNpH2G8MyTFlgerum8ubf21s3TSM3XmKXuIn+H2Sifh/ES2nPOPiYSRJWAk0fDkW0APBWcpfw==", "dev": true, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4696,13 +5007,13 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.18.0.tgz", - "integrity": "sha512-rqQgFRu6yPkauz+ms3nQpohwejS8bvgbPyIDq13cgEDbkXt4LH4OkDMT0/fN1RUtzG8e8AKJyDBoocuQh8qNeg==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.18.1.tgz", + "integrity": "sha512-z8U21WI5txzl2XYOW7i9hJhxoKKNG1kcU4RzyNvKrdZDmbjkmLBo8bgeiOJmA06kizLI76/CCBAAGlTlEeUfyg==", "dev": true, "dependencies": { - "@typescript-eslint/types": "8.18.0", - "@typescript-eslint/visitor-keys": "8.18.0", + "@typescript-eslint/types": "8.18.1", + "@typescript-eslint/visitor-keys": "8.18.1", "debug": "^4.3.4", "fast-glob": "^3.3.2", "is-glob": "^4.0.3", @@ -4758,15 +5069,15 @@ } }, "node_modules/@typescript-eslint/utils": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.18.0.tgz", - "integrity": "sha512-p6GLdY383i7h5b0Qrfbix3Vc3+J2k6QWw6UMUeY5JGfm3C5LbZ4QIZzJNoNOfgyRe0uuYKjvVOsO/jD4SJO+xg==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.18.1.tgz", + "integrity": "sha512-8vikiIj2ebrC4WRdcAdDcmnu9Q/MXXwg+STf40BVfT8exDqBCUPdypvzcUPxEqRGKg9ALagZ0UWcYCtn+4W2iQ==", "dev": true, "dependencies": { "@eslint-community/eslint-utils": "^4.4.0", - "@typescript-eslint/scope-manager": "8.18.0", - "@typescript-eslint/types": "8.18.0", - "@typescript-eslint/typescript-estree": "8.18.0" + "@typescript-eslint/scope-manager": "8.18.1", + "@typescript-eslint/types": "8.18.1", + "@typescript-eslint/typescript-estree": "8.18.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4781,12 +5092,12 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.18.0.tgz", - "integrity": "sha512-pCh/qEA8Lb1wVIqNvBke8UaRjJ6wrAWkJO5yyIbs8Yx6TNGYyfNjOo61tLv+WwLvoLPp4BQ8B7AHKijl8NGUfw==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.18.1.tgz", + "integrity": "sha512-Vj0WLm5/ZsD013YeUKn+K0y8p1M0jPpxOkKdbD1wB0ns53a5piVY02zjf072TblEweAbcYiFiPoSMF3kp+VhhQ==", "dev": true, "dependencies": { - "@typescript-eslint/types": "8.18.0", + "@typescript-eslint/types": "8.18.1", "eslint-visitor-keys": "^4.2.0" }, "engines": { @@ -5828,12 +6139,11 @@ } }, "node_modules/cacheable": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.8.5.tgz", - "integrity": "sha512-sRdiC3/Va8SAqZcnvcfxQAP3p3uipWl9MZpnNmAzHteyMVDRb5QllQO/JRcHGeDzYzPTfOBPH/27hoTpcREF1A==", - "license": "MIT", + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.8.6.tgz", + "integrity": "sha512-RNBnqNhWBtgYNe4mF4395e6260Q9loh6zT2CDFia9LSJor5+vOsvkxhd7GAtg3U4m8i38adn1Q3jiCU1N33/gg==", "dependencies": { - "hookified": "^1.5.0", + "hookified": "^1.5.1", "keyv": "^5.2.1" } }, @@ -5863,12 +6173,11 @@ } }, "node_modules/cacheable/node_modules/keyv": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.2.1.tgz", - "integrity": "sha512-tpIgCaY02VCW2Pz0zAn4guyct+IeH6Mb5wZdOvpe4oqXeQOJO0C3Wo8fTnf7P3ZD83Vr9kghbkNmzG3lTOhy/A==", - "license": "MIT", + "version": "5.2.2", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.2.2.tgz", + "integrity": "sha512-CRPP4Sq5ofbUE8s4FOirFmDgHeKZFRrH/8+WOUNvLJiMIplRMfnMjxmbaDb+zVd7ex0gGAWqMhZHfcL2u6PrNQ==", "dependencies": { - "@keyv/serialize": "*" + "@keyv/serialize": "^1.0.1" } }, "node_modules/call-bind": { @@ -6595,10 +6904,9 @@ "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" }, "node_modules/cron": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/cron/-/cron-3.3.0.tgz", - "integrity": "sha512-uwRMLudSn2vPPjg392dKOm3KoJRw/eOOFtcHbrmRJxCd/NDF3187JVnajTvHPIlam0UwhKUZWwVPd1V5vBlmsw==", - "license": "MIT", + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/cron/-/cron-3.3.1.tgz", + "integrity": "sha512-KpvuzJEbeTMTfLsXhUuDfsFYr8s5roUlLKb4fa68GszWrA4783C7q6m9yj4vyc6neyD/V9e0YiADSX2c+yRDXg==", "dependencies": { "@types/luxon": "~3.4.0", "luxon": "~3.5.0" @@ -7449,6 +7757,21 @@ "@esbuild/win32-x64": "0.21.5" } }, + "node_modules/esbuild/node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, "node_modules/escalade": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", @@ -7503,17 +7826,16 @@ } }, "node_modules/eslint": { - "version": "9.16.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.16.0.tgz", - "integrity": "sha512-whp8mSQI4C8VXd+fLgSM0lh3UlmcFtVwUQjyKCFfsp+2ItAIYhlq/hqGahGqHE6cv9unM41VlqKk2VtKYR2TaA==", - "license": "MIT", + "version": "9.17.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.17.0.tgz", + "integrity": "sha512-evtlNcpJg+cZLcnVKwsai8fExnqjGPicK7gnUtlNuzu+Fv9bI0aLpND5T44VLQtoMEnI57LoXO9XAkIXwohKrA==", "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.19.0", "@eslint/core": "^0.9.0", "@eslint/eslintrc": "^3.2.0", - "@eslint/js": "9.16.0", + "@eslint/js": "9.17.0", "@eslint/plugin-kit": "^0.2.3", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", @@ -7522,7 +7844,7 @@ "@types/json-schema": "^7.0.15", "ajv": "^6.12.4", "chalk": "^4.0.0", - "cross-spawn": "^7.0.5", + "cross-spawn": "^7.0.6", "debug": "^4.3.2", "escape-string-regexp": "^4.0.0", "eslint-scope": "^8.2.0", @@ -8735,12 +9057,11 @@ } }, "node_modules/flat-cache": { - "version": "6.1.3", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.3.tgz", - "integrity": "sha512-GWiWmC+qCbt/9EO80JgLj21gD61dw6iE4lw1t4NU1/DAWjmX+Hnv9C1pLtU32P6wnbdqXmUhkEVvx6y08IOACQ==", - "license": "MIT", + "version": "6.1.4", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.4.tgz", + "integrity": "sha512-Km+tVF9BLnxaYqX2R9OKLkwSPvGjDXXlciDC8oBr/nSM4xMCNO8X9s0w5i6lNoE8E/6BEzSJBUF5Bar+TXmKJQ==", "dependencies": { - "cacheable": "^1.8.5", + "cacheable": "^1.8.6", "flatted": "^3.3.2", "hookified": "^1.5.1" } @@ -9283,8 +9604,7 @@ "node_modules/hookified": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.5.1.tgz", - "integrity": "sha512-sZQQ5QgNVQUXffNd66qefqOMXA88CXIV0gW8I4bMAJYeu1ZCJsyy7sdchaoHzRyS4o0cXw3krNDXkljZr7uexw==", - "license": "MIT" + "integrity": "sha512-sZQQ5QgNVQUXffNd66qefqOMXA88CXIV0gW8I4bMAJYeu1ZCJsyy7sdchaoHzRyS4o0cXw3krNDXkljZr7uexw==" }, "node_modules/html-encoding-sniffer": { "version": "4.0.0", @@ -15946,10 +16266,9 @@ } }, "node_modules/sass": { - "version": "1.82.0", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.82.0.tgz", - "integrity": "sha512-j4GMCTa8elGyN9A7x7bEglx0VgSpNUG4W4wNedQ33wSMdnkqQCT8HTwOaVSV4e6yQovcu/3Oc4coJP/l0xhL2Q==", - "license": "MIT", + "version": "1.83.0", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.83.0.tgz", + "integrity": "sha512-qsSxlayzoOjdvXMVLkzF84DJFc2HZEL/rFyGIKbbilYtAvlCxyuzUeff9LawTn4btVnLKg75Z8MMr1lxU1lfGw==", "dependencies": { "chokidar": "^4.0.0", "immutable": "^5.0.2", @@ -16988,14 +17307,14 @@ } }, "node_modules/typescript-eslint": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.18.0.tgz", - "integrity": "sha512-Xq2rRjn6tzVpAyHr3+nmSg1/9k9aIHnJ2iZeOH7cfGOWqTkXTm3kwpQglEuLGdNrYvPF+2gtAs+/KF5rjVo+WQ==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.18.1.tgz", + "integrity": "sha512-Mlaw6yxuaDEPQvb/2Qwu3/TfgeBHy9iTJ3mTwe7OvpPmF6KPQjVOfGyEJpPv6Ez2C34OODChhXrzYw/9phI0MQ==", "dev": true, "dependencies": { - "@typescript-eslint/eslint-plugin": "8.18.0", - "@typescript-eslint/parser": "8.18.0", - "@typescript-eslint/utils": "8.18.0" + "@typescript-eslint/eslint-plugin": "8.18.1", + "@typescript-eslint/parser": "8.18.1", + "@typescript-eslint/utils": "8.18.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" diff --git a/package.json b/package.json index 1c13a9628..bb32249c2 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ "@types/memoizee": "^0.4.11", "@types/memory-cache": "^0.2.6", "@types/morgan": "^1.9.9", - "@types/node": "^22.10.1", + "@types/node": "^22.10.2", "@types/node-jose": "^1.1.13", "@types/pg": "^8.11.10", "@types/proj4": "^2.5.5", @@ -87,7 +87,7 @@ "cookie-parser": "^1.4.7", "cookie-session": "^2.1.0", "cors": "^2.8.5", - "cron": "^3.3.0", + "cron": "^3.3.1", "cross-env": "^7.0.3", "date-fns": "^4.1.0", "decimal.js": "^10.4.3", @@ -97,7 +97,7 @@ "express-basic-auth": "^1.2.1", "express-http-proxy": "^2.1.1", "express-openid-connect": "^2.17.1", - "flat-cache": "^6.1.3", + "flat-cache": "^6.1.4", "form-data": "^4.0.1", "fuse.js": "^7.0.0", "html-to-ast": "^0.0.6", @@ -136,7 +136,7 @@ "react-test-renderer": "^18.3.1", "recoil": "^0.7.7", "sanitize-html": "^2.13.1", - "sass": "^1.82.0", + "sass": "^1.83.0", "slugme": "^1.1.1", "supercluster": "^7.1.5", "thenby": "^1.3.4", @@ -155,14 +155,14 @@ "@rollup/rollup-linux-x64-gnu": "4.28.1" }, "devDependencies": { - "@eslint/js": "^9.16.0", + "@eslint/js": "^9.17.0", "@mocks-server/main": "^4.1.0", - "eslint": "^9.16.0", + "eslint": "^9.17.0", "eslint-plugin-import": "^2.31.0", "eslint-plugin-react": "^7.37.2", "eslint-plugin-unused-imports": "^4.1.0", "formidable": "^3.5.2", "globals": "^15.13.0", - "typescript-eslint": "^8.18.0" + "typescript-eslint": "^8.18.1" } } diff --git a/src/client/config/routes.ts b/src/client/config/routes.ts index 86e46c18c..75f049ee8 100644 --- a/src/client/config/routes.ts +++ b/src/client/config/routes.ts @@ -6,15 +6,15 @@ import { Match } from '../../universal/types'; export const AppRoutesRedirect = [ { from: '/burgerzaken/document/:id', - to: AppRoutes['BURGERZAKEN/ID-KAART'], + to: AppRoutes['BURGERZAKEN/IDENTITEITSBEWIJS'], }, { from: '/stadspas', - to: AppRoutes['HLI'], + to: AppRoutes.HLI, }, { from: '/stadspas/saldo/:pasnummer', - to: AppRoutes['HLI'], + to: AppRoutes.HLI, }, { from: '/inkomen-en-stadspas/bijstandsuitkering/:id', @@ -90,7 +90,8 @@ export const CustomTrackingUrls: CustomTrackingUrlMap = { }, [AppRoutes['INKOMEN/TONK']]: () => `/inkomen/tonk`, - [AppRoutes['BURGERZAKEN/ID-KAART']]: () => '/burgerzaken/id-kaart', + [AppRoutes['BURGERZAKEN/IDENTITEITSBEWIJS']]: () => + '/burgerzaken/identiteitsbewijs', [AppRoutes['ZORG/VOORZIENING']]: () => '/zorg-en-ondersteuning/voorziening', diff --git a/src/client/config/thema.ts b/src/client/config/thema.ts index 1f41b2dbb..b611ebb19 100644 --- a/src/client/config/thema.ts +++ b/src/client/config/thema.ts @@ -7,6 +7,10 @@ import { AppState, BagThema, LinkProps } from '../../universal/types/App.types'; import { DecosCaseType } from '../../universal/types/vergunningen'; import { getThemaTitleWithAppState } from '../pages/HLI/helpers'; import { PARKEER_CASE_TYPES } from '../pages/Parkeren/useParkerenData.hook'; +import { + getThemaTitleBurgerzakenWithAppState, + getThemaUrlBurgerzakenWithAppState, +} from '../pages/Burgerzaken/helpers'; export const BagThemas: Record = Object.fromEntries( Object.entries(Themas).map(([key, key2]) => { @@ -23,7 +27,7 @@ export const ThemaTitles: { [thema in Thema]: string } = { BEZWAREN: 'Bezwaren', BODEM: 'Bodem', BRP: 'Mijn gegevens', - BURGERZAKEN: 'Burgerzaken', + BURGERZAKEN: 'Paspoort en ID-kaart', BUURT: 'Mijn buurt', ERFPACHT: 'Erfpacht', ERFPACHTv2: 'Erfpacht V2', @@ -237,9 +241,11 @@ export const myThemasMenuItems: ThemaMenuItem[] = [ isAlwaysVisible: true, }, { - title: ThemaTitles.BURGERZAKEN, + title: (appState: AppState) => { + return getThemaTitleBurgerzakenWithAppState(appState); + }, id: Themas.BURGERZAKEN, - to: AppRoutes.BURGERZAKEN, + to: (appState) => getThemaUrlBurgerzakenWithAppState(appState), profileTypes: ['private'], }, { diff --git a/src/client/pages/Burgerzaken/__snapshots__/Burgerzaken.test.tsx.snap b/src/client/pages/Burgerzaken/__snapshots__/Burgerzaken.test.tsx.snap index 7a90cbe86..8baa3d2dd 100644 --- a/src/client/pages/Burgerzaken/__snapshots__/Burgerzaken.test.tsx.snap +++ b/src/client/pages/Burgerzaken/__snapshots__/Burgerzaken.test.tsx.snap @@ -13,7 +13,7 @@ exports[` > Renders without crashing 1`] = ` class="_Icon_3b337d" > > Renders without crashing 1`] = `

- Burgerzaken + Paspoort en ID-kaart

@@ -116,7 +116,7 @@ exports[` > Renders without crashing 1`] = `

- Paspoort en ID-kaart + Mijn reisdocumenten

true, listPageRoute: generatePath(AppRoutes['BURGERZAKEN/LIST'], { kind: listPageParamKind.identiteitsbewijzen, }), diff --git a/src/client/pages/Burgerzaken/helpers.test.ts b/src/client/pages/Burgerzaken/helpers.test.ts new file mode 100644 index 000000000..3d752ce14 --- /dev/null +++ b/src/client/pages/Burgerzaken/helpers.test.ts @@ -0,0 +1,138 @@ +import { generatePath } from 'react-router-dom'; +import { describe, it, expect } from 'vitest'; + +import { + getThemaTitleBurgerzaken, + getThemaTitleBurgerzakenWithAppState, + getThemaUrlBurgerzakenWithAppState, +} from './helpers'; +import { AppRoutes } from '../../../universal/config/routes'; +import { AppState } from '../../../universal/types/App.types'; +import { ThemaTitles } from '../../config/thema'; + +describe('helpers', () => { + describe('getThemaTitleBurgerzaken', () => { + it('should return BURGERZAKEN when both hasIDKaart and hasPaspoort are true', () => { + const result = getThemaTitleBurgerzaken(true, true); + expect(result).toBe(ThemaTitles.BURGERZAKEN); + }); + + it('should return ID-kaart when only hasIDKaart is true', () => { + const result = getThemaTitleBurgerzaken(true, false); + expect(result).toBe('ID-kaart'); + }); + + it('should return Paspoort when only hasPaspoort is true', () => { + const result = getThemaTitleBurgerzaken(false, true); + expect(result).toBe('Paspoort'); + }); + + it('should return Paspoort when both hasIDKaart and hasPaspoort are false', () => { + const result = getThemaTitleBurgerzaken(false, false); + expect(result).toBe(ThemaTitles.BURGERZAKEN); + }); + }); + + describe('getThemaTitleBurgerzakenWithAppState', () => { + it('should return BURGERZAKEN when appState has both ID-kaart and Paspoort', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [ + { documentType: 'europese identiteitskaart', id: '1' }, + { documentType: 'paspoort', id: '2' }, + ], + }, + }, + } as unknown as AppState; + const result = getThemaTitleBurgerzakenWithAppState(appState); + expect(result).toBe(ThemaTitles.BURGERZAKEN); + }); + + it('should return ID-kaart when appState has only ID-kaart', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [ + { documentType: 'europese identiteitskaart', id: '1' }, + ], + }, + }, + } as unknown as AppState; + const result = getThemaTitleBurgerzakenWithAppState(appState); + expect(result).toBe('ID-kaart'); + }); + + it('should return Paspoort when appState has only Paspoort', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [{ documentType: 'paspoort', id: '1' }], + }, + }, + } as unknown as AppState; + const result = getThemaTitleBurgerzakenWithAppState(appState); + expect(result).toBe('Paspoort'); + }); + + it('should return Paspoort when appState has neither ID-kaart nor Paspoort', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [], + }, + }, + } as unknown as AppState; + const result = getThemaTitleBurgerzakenWithAppState(appState); + expect(result).toBe(ThemaTitles.BURGERZAKEN); + }); + }); + + describe('getThemaUrlBurgerzakenWithAppState', () => { + it('should return the URL for a single identiteitsbewijs', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [ + { documentType: 'europese identiteitskaart', id: '1' }, + ], + }, + }, + } as unknown as AppState; + const result = getThemaUrlBurgerzakenWithAppState(appState); + expect(result).toBe( + generatePath(AppRoutes['BURGERZAKEN/IDENTITEITSBEWIJS'], { + documentType: 'europese identiteitskaart', + id: '1', + }) + ); + }); + + it('should return the BURGERZAKEN route when there are multiple identiteitsbewijzen', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [ + { documentType: 'europese identiteitskaart', id: '1' }, + { documentType: 'paspoort', id: '2' }, + ], + }, + }, + } as unknown as AppState; + const result = getThemaUrlBurgerzakenWithAppState(appState); + expect(result).toBe(AppRoutes.BURGERZAKEN); + }); + + it('should return the BURGERZAKEN route when there are no identiteitsbewijzen', () => { + const appState = { + BRP: { + content: { + identiteitsbewijzen: [], + }, + }, + } as unknown as AppState; + const result = getThemaUrlBurgerzakenWithAppState(appState); + expect(result).toBe(AppRoutes.BURGERZAKEN); + }); + }); +}); diff --git a/src/client/pages/Burgerzaken/helpers.ts b/src/client/pages/Burgerzaken/helpers.ts new file mode 100644 index 000000000..27ebc0817 --- /dev/null +++ b/src/client/pages/Burgerzaken/helpers.ts @@ -0,0 +1,43 @@ +import { generatePath } from 'react-router-dom'; + +import { AppRoutes } from '../../../universal/config/routes'; +import { AppState } from '../../../universal/types/App.types'; +import { ThemaTitles } from '../../config/thema'; + +export function getThemaTitleBurgerzaken( + hasIDKaart: boolean, + hasPaspoort: boolean +) { + switch (true) { + default: + case hasIDKaart && hasPaspoort: + return ThemaTitles.BURGERZAKEN; + case hasIDKaart: + return 'ID-kaart'; + case hasPaspoort: + return 'Paspoort'; + } +} + +export function getThemaTitleBurgerzakenWithAppState(appState: AppState) { + const hasIDKaart = !!appState.BRP?.content?.identiteitsbewijzen?.some( + (x) => x.documentType == 'europese identiteitskaart' + ); + const hasPaspoort = !!appState.BRP?.content?.identiteitsbewijzen?.some( + (x) => x.documentType == 'paspoort' + ); + + return getThemaTitleBurgerzaken(hasIDKaart, hasPaspoort); +} + +export function getThemaUrlBurgerzakenWithAppState(appState: AppState) { + const identiteitsbewijzen = appState.BRP?.content?.identiteitsbewijzen ?? []; + const identiteitsbewijs = identiteitsbewijzen[0]; + + return identiteitsbewijzen.length === 1 && identiteitsbewijs + ? generatePath(AppRoutes['BURGERZAKEN/IDENTITEITSBEWIJS'], { + documentType: identiteitsbewijs.documentType, + id: identiteitsbewijs.id, + }) + : AppRoutes.BURGERZAKEN; +} diff --git a/src/server/services/__snapshots__/brp.test.ts.snap b/src/server/services/__snapshots__/brp.test.ts.snap index 143429b2b..454a891a2 100644 --- a/src/server/services/__snapshots__/brp.test.ts.snap +++ b/src/server/services/__snapshots__/brp.test.ts.snap @@ -53,7 +53,7 @@ exports[`BRP data api + transformation > should transform the source data 1`] = "id": "een-hash-van-documentnummer-1", "link": { "title": "paspoort", - "to": "/burgerzaken/paspoort/een-hash-van-documentnummer-1", + "to": "/paspoort-en-id-kaart/paspoort/een-hash-van-documentnummer-1", }, "steps": [], "title": "paspoort", @@ -68,7 +68,7 @@ exports[`BRP data api + transformation > should transform the source data 1`] = "id": "een-hash-van-documentnummer-2", "link": { "title": "europese identiteitskaart", - "to": "/burgerzaken/europese-identiteitskaart/een-hash-van-documentnummer-2", + "to": "/paspoort-en-id-kaart/europese-identiteitskaart/een-hash-van-documentnummer-2", }, "steps": [], "title": "ID-kaart", diff --git a/src/server/services/brp.ts b/src/server/services/brp.ts index fcb482c61..537835c34 100644 --- a/src/server/services/brp.ts +++ b/src/server/services/brp.ts @@ -34,17 +34,12 @@ const ID_BEWIJS_PEAK_DATE_END = new Date('2024-10-01'); const BrpDocumentTitles: Record = { paspoort: 'paspoort', 'europese identiteitskaart': 'ID-kaart', - 'nederlandse identiteitskaart': 'ID-kaart', - rijbewijs: 'rijbewijs', }; const BrpDocumentCallToAction: Record = { paspoort: 'https://www.amsterdam.nl/burgerzaken/paspoort-id-kaart-aanvragen/', 'europese identiteitskaart': 'https://www.amsterdam.nl/burgerzaken/paspoort-id-kaart-aanvragen/', - 'nederlandse identiteitskaart': - 'https://www.amsterdam.nl/burgerzaken/paspoort-id-kaart-aanvragen/', - rijbewijs: 'https://www.amsterdam.nl/burgerzaken/rijbewijs/', }; export function transformBRPNotifications(data: BRPData, compareDate: Date) { @@ -116,7 +111,7 @@ export function transformBRPNotifications(data: BRPData, compareDate: Date) { thema: Themas.BURGERZAKEN, datePublished: compareDate.toISOString(), isAlert: true, - id: `${document.documentType}-datum-afloop-binnekort`, + id: `${document.documentType}-datum-afloop-binnenkort`, title: `Voorkom vertraging en verleng uw ${docTitle} op tijd`, description: `Vanaf maart tot de zomervakantie wordt het erg druk op het Stadsloket. Uw huidige ${docTitle} verloopt op ${defaultDateFormat( document.datumAfloop diff --git a/src/universal/config/routes.ts b/src/universal/config/routes.ts index e0765d667..572826789 100644 --- a/src/universal/config/routes.ts +++ b/src/universal/config/routes.ts @@ -1,9 +1,9 @@ export const AppRoutes = { ROOT: '/', HOME: '/', - BURGERZAKEN: '/burgerzaken', - 'BURGERZAKEN/LIST': '/burgerzaken/lijst/:kind/:page?', - 'BURGERZAKEN/IDENTITEITSBEWIJS': '/burgerzaken/:documentType/:id', + BURGERZAKEN: '/paspoort-en-id-kaart', + 'BURGERZAKEN/LIST': '/paspoort-en-id-kaart/lijst/:kind/:page?', + 'BURGERZAKEN/IDENTITEITSBEWIJS': '/paspoort-en-id-kaart/:documentType/:id', ZORG: '/zorg-en-ondersteuning', 'ZORG/VOORZIENING': '/zorg-en-ondersteuning/voorziening/:id', diff --git a/src/universal/types/brp.ts b/src/universal/types/brp.ts index 8b9c6a609..168071c5b 100644 --- a/src/universal/types/brp.ts +++ b/src/universal/types/brp.ts @@ -3,7 +3,7 @@ import { LinkProps, ZaakDetail } from './App.types'; export interface IdentiteitsbewijsFromSource { id: string; documentNummer: string; - documentType: 'europese identiteitskaart' | 'paspoort' | string; + documentType: 'europese identiteitskaart' | 'paspoort'; datumUitgifte: string; datumAfloop: string; }