diff --git a/api/src/Feature.Statistics/GetElectionsOverview/Endpoint.cs b/api/src/Feature.Statistics/GetElectionsOverview/Endpoint.cs index 8c05255d4..1aed3f2cf 100644 --- a/api/src/Feature.Statistics/GetElectionsOverview/Endpoint.cs +++ b/api/src/Feature.Statistics/GetElectionsOverview/Endpoint.cs @@ -126,7 +126,7 @@ AND FS."NumberOfQuestionsAnswered" > 0 WHERE "ElectionRoundId" = ANY (@electionRoundIds) AND "NumberOfQuestionsAnswered" > 0 - ) AS "NumberOfFormSubmissions"; + ) AS ""NumberOfQuestionsAnswered""; ----------------------------- -- number of questions answered diff --git a/web/package.json b/web/package.json index 93b39f1cb..2a0481967 100644 --- a/web/package.json +++ b/web/package.json @@ -59,6 +59,7 @@ "@tiptap/react": "^2.8.0", "@tiptap/starter-kit": "^2.8.0", "@types/lodash": "^4.17.7", + "@types/papaparse": "^5.3.15", "@uidotdev/usehooks": "^2.4.1", "axios": "^1.6.2", "chart.js": "^4.4.2", @@ -74,6 +75,7 @@ "i18next-browser-languagedetector": "^8.0.0", "lodash": "^4.17.21", "lucide-react": "^0.294.0", + "papaparse": "^5.4.1", "qs": "^6.12.0", "react": "^18.2.0", "react-beautiful-dnd": "^13.1.1", diff --git a/web/pnpm-lock.yaml b/web/pnpm-lock.yaml index a5ffe9139..6e50d8d38 100644 --- a/web/pnpm-lock.yaml +++ b/web/pnpm-lock.yaml @@ -134,6 +134,9 @@ importers: '@types/lodash': specifier: ^4.17.7 version: 4.17.7 + '@types/papaparse': + specifier: ^5.3.15 + version: 5.3.15 '@uidotdev/usehooks': specifier: ^2.4.1 version: 2.4.1(react-dom@18.2.0(react@18.2.0))(react@18.2.0) @@ -179,6 +182,9 @@ importers: lucide-react: specifier: ^0.294.0 version: 0.294.0(react@18.2.0) + papaparse: + specifier: ^5.4.1 + version: 5.4.1 qs: specifier: ^6.12.0 version: 6.12.0 @@ -2121,6 +2127,9 @@ packages: '@types/normalize-package-data@2.4.4': resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} + '@types/papaparse@5.3.15': + resolution: {integrity: sha512-JHe6vF6x/8Z85nCX4yFdDslN11d+1pr12E526X8WAfhadOeaOTx5AuIkvDKIBopfvlzpzkdMx4YyvSKCM9oqtw==} + '@types/parse-json@4.0.2': resolution: {integrity: sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==} @@ -3834,6 +3843,9 @@ packages: resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} engines: {node: '>=6'} + papaparse@5.4.1: + resolution: {integrity: sha512-HipMsgJkZu8br23pW15uvo6sib6wne/4woLZPlFf3rpDyMe9ywEXUsuD7+6K9PRkJlVT51j/sCOYDKGGS3ZJrw==} + parent-module@1.0.1: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} @@ -6848,6 +6860,10 @@ snapshots: '@types/normalize-package-data@2.4.4': {} + '@types/papaparse@5.3.15': + dependencies: + '@types/node': 20.5.1 + '@types/parse-json@4.0.2': {} '@types/prop-types@15.7.11': {} @@ -8846,6 +8862,8 @@ snapshots: p-try@2.2.0: {} + papaparse@5.4.1: {} + parent-module@1.0.1: dependencies: callsites: 3.1.0 diff --git a/web/src/components/layout/Layout.tsx b/web/src/components/layout/Layout.tsx index 3eb295268..6e6c7f9cc 100644 --- a/web/src/components/layout/Layout.tsx +++ b/web/src/components/layout/Layout.tsx @@ -4,7 +4,7 @@ import Breadcrumbs from './Breadcrumbs/Breadcrumbs'; import BackButton from './Breadcrumbs/BackButton'; interface LayoutProps { - title: string; + title?: string; subtitle?: string; enableBreadcrumbs?: boolean; breadcrumbs?: ReactNode; diff --git a/web/src/components/ui/dual-range-slider.tsx b/web/src/components/ui/dual-range-slider.tsx index c746aa262..9911bf412 100644 --- a/web/src/components/ui/dual-range-slider.tsx +++ b/web/src/components/ui/dual-range-slider.tsx @@ -1,5 +1,3 @@ -'use client'; - import * as React from 'react'; import * as SliderPrimitive from '@radix-ui/react-slider'; diff --git a/web/src/components/ui/file-uploader.tsx b/web/src/components/ui/file-uploader.tsx index 0f57943f1..759619e21 100644 --- a/web/src/components/ui/file-uploader.tsx +++ b/web/src/components/ui/file-uploader.tsx @@ -137,7 +137,7 @@ export function FileUploader(props: FileUploaderProps) { return (