diff --git a/.github/workflows/app.altinn3-tilgang-service-prod.yml b/.github/workflows/app.altinn3-tilgang-service-prod.yml new file mode 100644 index 00000000000..6751193d9f0 --- /dev/null +++ b/.github/workflows/app.altinn3-tilgang-service-prod.yml @@ -0,0 +1,24 @@ +name: altinn3-tilgang-service-prod + +on: + push: + paths: + - "plugins/**" + - "libs/reactive-core/**" + - "libs/reactive-security/**" + - "apps/altinn3-tilgang-service/**" + - ".github/workflows/app.altinn3-tilgang-service.yml" + +jobs: + workflow: + uses: ./.github/workflows/common.workflow.backend.yml + with: + working-directory: "apps/altinn3-tilgang-service" + deploy-tag: "#deploy-altinn3-tilgang-service-prod" + nais-manifest: "config.prod.yml" + cluster: "prod-gcp" + permissions: + contents: read + id-token: write + secrets: inherit + diff --git a/.github/workflows/app.organisasjon-tilgang-service.yml b/.github/workflows/app.altinn3-tilgang-service.yml similarity index 50% rename from .github/workflows/app.organisasjon-tilgang-service.yml rename to .github/workflows/app.altinn3-tilgang-service.yml index 229fcbb1fcd..33ed8e0eaaa 100644 --- a/.github/workflows/app.organisasjon-tilgang-service.yml +++ b/.github/workflows/app.altinn3-tilgang-service.yml @@ -1,4 +1,4 @@ -name: organisasjon-tilgang-service +name: altinn3-tilgang-service on: push: @@ -6,16 +6,18 @@ on: - "plugins/**" - "libs/reactive-core/**" - "libs/reactive-security/**" - - "apps/organisasjon-tilgang-service/**" - - ".github/workflows/app.organisasjon-tilgang-service.yml" + - "apps/altinn3-tilgang-service/**" + - ".github/workflows/app.altinn3-tilgang-service.yml" jobs: workflow: uses: ./.github/workflows/common.workflow.backend.yml with: - working-directory: "apps/organisasjon-tilgang-service" - deploy-tag: "#deploy-organisasjon-tilgang-service" + working-directory: "apps/altinn3-tilgang-service" + deploy-tag: "#deploy-altinn3-tilgang-service" + nais-manifest: "config.dev.yml" permissions: contents: read id-token: write secrets: inherit + diff --git a/.github/workflows/app.person-organisasjon-tilgang-service.yml b/.github/workflows/app.person-organisasjon-tilgang-service.yml deleted file mode 100644 index 6136dd68925..00000000000 --- a/.github/workflows/app.person-organisasjon-tilgang-service.yml +++ /dev/null @@ -1,23 +0,0 @@ -name: person-organisasjon-tilgang-service - -on: - push: - paths: - - "plugins/**" - - "libs/integration-test/**" - - "libs/reactive-core/**" - - "libs/reactive-security/**" - - "libs/security-core/**" - - "apps/person-organisasjon-tilgang-service/**" - - ".github/workflows/app.person-organisasjon-tilgang-service.yml" - -jobs: - workflow: - uses: ./.github/workflows/common.workflow.backend.yml - with: - working-directory: "apps/person-organisasjon-tilgang-service" - deploy-tag: "#deploy-person-organisasjon-tilgang-service" - permissions: - contents: read - id-token: write - secrets: inherit diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 16c25d9ff37..9351999c60b 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -3,7 +3,6 @@ on: push: paths: - 'apps/bruker-service/**' - - 'apps/person-organisasjon-tilgang-service/**' workflow_dispatch: jobs: @@ -14,11 +13,4 @@ jobs: working-directory: 'apps/bruker-service/' healthcheck: 'http://localhost:8002/internal/isAlive' secrets: - NAV_TOKEN: ${{ secrets.NAV_TOKEN }} - person-organisasjon-tilgang-service: - if: github.event.pull_request.draft == false - uses: ./.github/workflows/common.integration-test.yml - with: - working-directory: 'apps/person-organisasjon-tilgang-service/' - healthcheck: 'http://localhost:8001/internal/isAlive' - secrets: inherit \ No newline at end of file + NAV_TOKEN: ${{ secrets.NAV_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/maskinporten.yml b/.github/workflows/maskinporten.yml deleted file mode 100644 index 9d1b7007cc8..00000000000 --- a/.github/workflows/maskinporten.yml +++ /dev/null @@ -1,22 +0,0 @@ -name: Deploy maskinporten - -on: - push: - branches: - - master - paths: - - '.nais/maskinporten.yml' - -jobs: - deploy-maskinporten: - name: Deploy maskinporten - runs-on: ubuntu-latest - permissions: - contents: read - id-token: write - steps: - - uses: actions/checkout@v4 - - uses: nais/deploy/actions/deploy@v2 - env: - CLUSTER: prod-gcp - RESOURCE: ".nais/maskinporten.yml" diff --git a/.github/workflows/proxy.altinn3-tilgang-proxy.yml b/.github/workflows/proxy.altinn3-tilgang-proxy.yml new file mode 100644 index 00000000000..eb617126e20 --- /dev/null +++ b/.github/workflows/proxy.altinn3-tilgang-proxy.yml @@ -0,0 +1,23 @@ +name: altinn3-tilgang-proxy + +on: + push: + paths: + - "plugins/**" + - "libs/reactive-core/**" + - "libs/reactive-proxy/**" + - "libs/security-core/**" + - "libs/servlet-insecure-security/**" + - "proxies/altinn3-tilgang-proxy/**" + - ".github/workflows/proxy.altinn3-tilgang-proxy.yml" + +jobs: + workflow: + uses: ./.github/workflows/common.workflow.backend.yml + with: + working-directory: "proxies/altinn3-tilgang-proxy" + deploy-tag: "#deploy-proxy-altinn3-tilgang" + permissions: + contents: read + id-token: write + secrets: inherit diff --git a/.nais/maskinporten.yml b/.nais/maskinporten.yml deleted file mode 100644 index ae6508f5809..00000000000 --- a/.nais/maskinporten.yml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: nais.io/v1 -kind: MaskinportenClient -metadata: - name: dolly - namespace: dolly - labels: - team: dolly -spec: - scopes: - consumes: - - name: altinn:serviceowner - secretName: maskinporten-dolly-prod # deployes til prod. secret kopieres manuelt til dev. diff --git a/apps/adresse-service/src/main/resources/application-local.yaml b/apps/adresse-service/src/main/resources/application-local.yaml deleted file mode 100644 index 4b75550d16b..00000000000 --- a/apps/adresse-service/src/main/resources/application-local.yaml +++ /dev/null @@ -1,10 +0,0 @@ -TOKEN_X_CLIENT_ID: dev-gcp:dolly:testnav-adresse-service - -spring: - config: - import: "sm://" - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} \ No newline at end of file diff --git a/apps/adresse-service/src/main/resources/application-local.yml b/apps/adresse-service/src/main/resources/application-local.yml new file mode 100644 index 00000000000..d2582a766ea --- /dev/null +++ b/apps/adresse-service/src/main/resources/application-local.yml @@ -0,0 +1,7 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} +TOKEN_X_CLIENT_ID: dev-gcp:dolly:testnav-adresse-service + +spring: + config: + import: "sm://" diff --git a/apps/adresse-service/src/main/resources/application.yaml b/apps/adresse-service/src/main/resources/application.yml similarity index 91% rename from apps/adresse-service/src/main/resources/application.yaml rename to apps/adresse-service/src/main/resources/application.yml index 5b96088b72e..5b3bf750fca 100644 --- a/apps/adresse-service/src/main/resources/application.yaml +++ b/apps/adresse-service/src/main/resources/application.yml @@ -34,12 +34,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/altinn3-tilgang-service/99-dolly-convert-to-pk8.sh b/apps/altinn3-tilgang-service/99-dolly-convert-to-pk8.sh new file mode 100644 index 00000000000..49cfce0b64e --- /dev/null +++ b/apps/altinn3-tilgang-service/99-dolly-convert-to-pk8.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env sh + +# +# Converts NAIS provided key.pem to PKCS#8 PEM format, which can be used by R2dbc. +# +openssl pkey -in /var/run/secrets/nais.io/sqlcertificate/key.pem -out /tmp/pk8.pem \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/Dockerfile b/apps/altinn3-tilgang-service/Dockerfile similarity index 65% rename from apps/organisasjon-tilgang-service/Dockerfile rename to apps/altinn3-tilgang-service/Dockerfile index 5adc5c61063..6114d5f0438 100644 --- a/apps/organisasjon-tilgang-service/Dockerfile +++ b/apps/altinn3-tilgang-service/Dockerfile @@ -1,8 +1,9 @@ FROM ghcr.io/navikt/baseimages/temurin:21 LABEL maintainer="Team Dolly" -ADD build/libs/app.jar /app/app.jar - ENV JAVA_OPTS="--add-opens java.base/java.lang=ALL-UNNAMED" +COPY 99-dolly-convert-to-pk8.sh /init-scripts/ +COPY /build/libs/app.jar /app/ + EXPOSE 8080 \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/README.md b/apps/altinn3-tilgang-service/README.md new file mode 100644 index 00000000000..baad90dca7e --- /dev/null +++ b/apps/altinn3-tilgang-service/README.md @@ -0,0 +1,13 @@ +## altinn3-tilgang-service + +Service som godkjenner tilganger for en spesifisert organisasjoner mot Dolly ved bruk av bankid. + +## Swagger + +Swagger finnes under [/swagger-ui.html](https://testnav-altinn3-tilgang-service.intern.dev.nav.no/swagger-ui.html) +-endepunktet til applikasjonen. + +## Lokal kjøring +* [Generelt.](../../docs/local_general.md) +* [Secret Manager.](../../docs/local_secretmanager.md) +* [Database i GCP.](../../docs/gcp_db.md) diff --git a/apps/organisasjon-tilgang-service/build.gradle b/apps/altinn3-tilgang-service/build.gradle similarity index 68% rename from apps/organisasjon-tilgang-service/build.gradle rename to apps/altinn3-tilgang-service/build.gradle index 7ec15dac6dc..cf1162f4ca0 100644 --- a/apps/organisasjon-tilgang-service/build.gradle +++ b/apps/altinn3-tilgang-service/build.gradle @@ -4,29 +4,32 @@ plugins { sonarqube { properties { - property "sonar.projectKey", "testnav-organisasjon-tilgang-service" - property "sonar.projectName", "testnav-organisasjon-tilgang-service" + property "sonar.projectKey", "testnav-altinn3-tilgang-service" + property "sonar.projectName", "testnav-altinn3-tilgang-service" } } dependencies { + implementation "no.nav.testnav.libs:data-transfer-objects" implementation "no.nav.testnav.libs:reactive-core" implementation "no.nav.testnav.libs:reactive-security" + implementation "org.springframework.boot:spring-boot-starter-data-r2dbc" implementation "org.springframework.boot:spring-boot-starter-oauth2-resource-server" + implementation "org.springframework.boot:spring-boot-starter-security" - implementation "org.springframework.boot:spring-boot-starter-data-r2dbc" - runtimeOnly "org.postgresql:postgresql" - implementation "io.r2dbc:r2dbc-h2" - implementation "org.postgresql:r2dbc-postgresql" implementation "org.flywaydb:flyway-core" implementation "org.flywaydb:flyway-database-postgresql" + runtimeOnly "org.postgresql:postgresql" + runtimeOnly "org.postgresql:r2dbc-postgresql" + implementation "ma.glasnost.orika:orika-core:$versions.orika" implementation "org.springdoc:springdoc-openapi-starter-webflux-ui:$versions.springdoc" implementation "io.swagger.core.v3:swagger-annotations-jakarta:$versions.swagger" - testImplementation "org.springframework.cloud:spring-cloud-contract-wiremock" + implementation "io.r2dbc:r2dbc-h2" + testRuntimeOnly "com.h2database:h2" } diff --git a/apps/organisasjon-tilgang-service/config.yml b/apps/altinn3-tilgang-service/config.dev.yml similarity index 66% rename from apps/organisasjon-tilgang-service/config.yml rename to apps/altinn3-tilgang-service/config.dev.yml index 497d5fdc323..6b66adf5c44 100644 --- a/apps/organisasjon-tilgang-service/config.yml +++ b/apps/altinn3-tilgang-service/config.dev.yml @@ -1,7 +1,7 @@ apiVersion: "nais.io/v1alpha1" kind: "Application" metadata: - name: testnav-organisasjon-tilgang-service + name: testnav-altinn3-tilgang-service namespace: dolly labels: team: dolly @@ -10,7 +10,6 @@ spec: enabled: true image: "{{image}}" port: 8080 - webproxy: true azure: application: enabled: true @@ -18,19 +17,26 @@ spec: claims: groups: - id: 9c7efec1-1599-4216-a67e-6fd53a6a951c + maskinporten: + enabled: true + scopes: + consumes: + - name: altinn:resourceregistry/accesslist.read + - name: altinn:resourceregistry/accesslist.write + - name: altinn:accessmanagement/authorizedparties.resourceowner accessPolicy: inbound: rules: - - application: dolly-frontend - application: dolly-frontend-dev - application: dolly-frontend-dev-unstable - - application: dolly-idporten - application: team-dolly-lokal-app - application: testnav-oversikt-frontend + - application: testnav-bruker-service-dev + - application: testnorge-profil-api-dev outbound: external: - - host: altinn.no - - host: maskinporten.no + - host: platform.tt02.altinn.no + - host: data.brreg.no liveness: path: /internal/isAlive initialDelay: 10 @@ -51,10 +57,6 @@ spec: prometheus: enabled: true path: /internal/metrics - envFrom: - - secret: altinn-prod - - secret: google-sql-testnav-organisasjon-tilgang-service - - secret: maskinporten-dolly-prod replicas: min: 1 max: 1 @@ -64,16 +66,16 @@ spec: memory: 1024Mi limits: memory: 2048Mi - ingresses: - - "https://testnav-organisasjon-tilgang-service.intern.dev.nav.no" env: - name: SPRING_PROFILES_ACTIVE - value: prod + value: dev + ingresses: + - "https://testnav-altinn3-tilgang-service.intern.dev.nav.no" gcp: sqlInstances: - - type: POSTGRES_15 + - type: POSTGRES_16 tier: db-custom-1-3840 - name: testnav-organisasjon-tilganger + name: testnav-altinn3-tilgang databases: - - name: testnav-organisasjon-tilganger + - name: testnav-altinn3-tilgang autoBackupHour: 2 \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/config.prod.yml b/apps/altinn3-tilgang-service/config.prod.yml new file mode 100644 index 00000000000..ed0e4aff1d6 --- /dev/null +++ b/apps/altinn3-tilgang-service/config.prod.yml @@ -0,0 +1,85 @@ +apiVersion: "nais.io/v1alpha1" +kind: "Application" +metadata: + name: testnav-altinn3-tilgang-service-prod + namespace: dolly + labels: + team: dolly +spec: + tokenx: + enabled: true + image: "{{image}}" + port: 8080 + azure: + application: + enabled: true + tenant: nav.no + claims: + groups: + - id: 9c7efec1-1599-4216-a67e-6fd53a6a951c + maskinporten: + enabled: true + scopes: + consumes: + - name: altinn:resourceregistry/accesslist.read + - name: altinn:resourceregistry/accesslist.write + - name: altinn:accessmanagement/authorizedparties.resourceowner + accessPolicy: + inbound: + rules: + - application: dolly-frontend + cluster: dev-gcp + - application: dolly-idporten + cluster: dev-gcp + - application: team-dolly-lokal-app + cluster: dev-gcp + - application: testnav-oversikt-frontend + cluster: dev-gcp + - application: testnav-altinn3-tilgang-proxy + cluster: dev-gcp + outbound: + external: + - host: platform.altinn.no + - host: data.brreg.no + liveness: + path: /internal/isAlive + initialDelay: 10 + periodSeconds: 5 + failureThreshold: 500 + observability: + logging: + destinations: + - id: elastic + autoInstrumentation: + enabled: true + runtime: java + readiness: + path: /internal/isReady + initialDelay: 10 + periodSeconds: 5 + failureThreshold: 500 + prometheus: + enabled: true + path: /internal/metrics + replicas: + min: 1 + max: 1 + resources: + requests: + cpu: 200m + memory: 1024Mi + limits: + memory: 2048Mi + env: + - name: SPRING_PROFILES_ACTIVE + value: prod + ingresses: + - "https://testnav-altinn3-tilgang-service.nav.no" + gcp: + sqlInstances: + - type: POSTGRES_16 + tier: db-custom-1-3840 + name: testnav-altinn3-tilgang + databases: + - name: testnav-altinn3-tilgang + autoBackupHour: 2 \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/docker-compose.yml b/apps/altinn3-tilgang-service/docker-compose.yml new file mode 100644 index 00000000000..b0eb57bd211 --- /dev/null +++ b/apps/altinn3-tilgang-service/docker-compose.yml @@ -0,0 +1,18 @@ +services: + + cloud_sql_proxy: + image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.14.2 + network_mode: host + command: + - "dolly-dev-ff83:europe-north1:testnav-altinn3-tilgang-local" + - "--credentials-file=/application_default_credentials.json" + - "--run-connection-test" + volumes: + - type: bind + # Set a variable $DOLLY_APPLICATION_CREDENTIALS. We don't use + # GOOGLE_APPLICATION_CREDENTIALS, as this causes an extra step during login. + # + # - $HOME/.config/gcloud/application_default_credentials.json for Linux/macOS. + # - $APPDATA/gcloud/application_default_credentials.json for Windows. + source: $DOLLY_APPLICATION_CREDENTIALS + target: /application_default_credentials.json \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/gradle/wrapper/gradle-wrapper.jar b/apps/altinn3-tilgang-service/gradle/wrapper/gradle-wrapper.jar similarity index 100% rename from apps/organisasjon-tilgang-service/gradle/wrapper/gradle-wrapper.jar rename to apps/altinn3-tilgang-service/gradle/wrapper/gradle-wrapper.jar diff --git a/apps/organisasjon-tilgang-service/gradle/wrapper/gradle-wrapper.properties b/apps/altinn3-tilgang-service/gradle/wrapper/gradle-wrapper.properties similarity index 100% rename from apps/organisasjon-tilgang-service/gradle/wrapper/gradle-wrapper.properties rename to apps/altinn3-tilgang-service/gradle/wrapper/gradle-wrapper.properties diff --git a/apps/organisasjon-tilgang-service/gradlew b/apps/altinn3-tilgang-service/gradlew similarity index 100% rename from apps/organisasjon-tilgang-service/gradlew rename to apps/altinn3-tilgang-service/gradlew diff --git a/apps/organisasjon-tilgang-service/gradlew.bat b/apps/altinn3-tilgang-service/gradlew.bat similarity index 100% rename from apps/organisasjon-tilgang-service/gradlew.bat rename to apps/altinn3-tilgang-service/gradlew.bat diff --git a/apps/organisasjon-tilgang-service/gradlewUpdate.sh b/apps/altinn3-tilgang-service/gradlewUpdate.sh similarity index 100% rename from apps/organisasjon-tilgang-service/gradlewUpdate.sh rename to apps/altinn3-tilgang-service/gradlewUpdate.sh diff --git a/apps/organisasjon-tilgang-service/settings.gradle b/apps/altinn3-tilgang-service/settings.gradle similarity index 77% rename from apps/organisasjon-tilgang-service/settings.gradle rename to apps/altinn3-tilgang-service/settings.gradle index 29ccda116b3..d7e1b8e69d7 100644 --- a/apps/organisasjon-tilgang-service/settings.gradle +++ b/apps/altinn3-tilgang-service/settings.gradle @@ -2,10 +2,11 @@ plugins { id "com.gradle.develocity" version "3.17.4" } -rootProject.name = 'organisasjon-tilgang-service' +rootProject.name = 'altinn3-tilgang-service' includeBuild "../../plugins/java" +includeBuild '../../libs/data-transfer-objects' includeBuild '../../libs/reactive-core' includeBuild '../../libs/reactive-security' diff --git a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/PersonOrganisasjonTilgangServiceApplicationStarter.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/Altinn3TilgangServiceApplicationStarter.java similarity index 60% rename from apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/PersonOrganisasjonTilgangServiceApplicationStarter.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/Altinn3TilgangServiceApplicationStarter.java index 9b61b5fd26c..1f674d70b88 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/PersonOrganisasjonTilgangServiceApplicationStarter.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/Altinn3TilgangServiceApplicationStarter.java @@ -1,22 +1,25 @@ -package no.nav.testnav.apps.persontilgangservice; +package no.nav.testnav.altinn3tilgangservice; import no.nav.testnav.libs.reactivecore.config.CoreConfig; import no.nav.testnav.libs.reactivesecurity.config.SecureOAuth2ServerToServerConfiguration; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.context.annotation.Import; +import org.springframework.data.r2dbc.config.EnableR2dbcAuditing; +import org.springframework.data.r2dbc.repository.config.EnableR2dbcRepositories; import org.springframework.web.reactive.config.EnableWebFlux; - @Import({ CoreConfig.class, SecureOAuth2ServerToServerConfiguration.class }) @EnableWebFlux +@EnableR2dbcAuditing +@EnableR2dbcRepositories @SpringBootApplication -public class PersonOrganisasjonTilgangServiceApplicationStarter { +public class Altinn3TilgangServiceApplicationStarter { public static void main(String[] args) { - SpringApplication.run(PersonOrganisasjonTilgangServiceApplicationStarter.class, args); + SpringApplication.run(Altinn3TilgangServiceApplicationStarter.class, args); } } diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/AltinnConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/AltinnConfig.java similarity index 54% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/AltinnConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/AltinnConfig.java index 47ed78ed69c..bcc747c7eba 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/AltinnConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/AltinnConfig.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.config; +package no.nav.testnav.altinn3tilgangservice.config; import lombok.Getter; import lombok.NoArgsConstructor; @@ -13,12 +13,9 @@ public class AltinnConfig { @Value("${altinn.api.url}") private String url; - @Value("${altinn.api.key}") - private String apiKey; + @Value("${altinn.resource.owner}") + private String owner; - @Value("${altinn.service.code}") - private String code; - - @Value("${altinn.service.edition}") - private String edition; + @Value("${altinn.resource.identifier}") + private String identifier; } diff --git a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/config/JacksonConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JacksonConfig.java similarity index 94% rename from apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/config/JacksonConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JacksonConfig.java index cbc95a05771..fd684bcddc7 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/config/JacksonConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JacksonConfig.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.persontilgangservice.config; +package no.nav.testnav.altinn3tilgangservice.config; import com.fasterxml.jackson.databind.ObjectMapper; import lombok.RequiredArgsConstructor; diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JsonMapperConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JsonMapperConfig.java new file mode 100644 index 00000000000..890a543f0c6 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/JsonMapperConfig.java @@ -0,0 +1,110 @@ +package no.nav.testnav.altinn3tilgangservice.config; + +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.DeserializationFeature; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.MapperFeature; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.fasterxml.jackson.databind.SerializationFeature; +import com.fasterxml.jackson.databind.json.JsonMapper; +import com.fasterxml.jackson.databind.module.SimpleModule; +import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule; +import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateSerializer; +import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer; +import com.fasterxml.jackson.datatype.jsr310.ser.YearMonthSerializer; +import com.fasterxml.jackson.datatype.jsr310.ser.ZonedDateTimeSerializer; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; + +import java.io.IOException; +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.YearMonth; +import java.time.ZonedDateTime; +import java.time.format.DateTimeFormatter; + +import static org.apache.commons.lang3.StringUtils.isBlank; + +@Configuration +public class JsonMapperConfig { + + private static final String YEAR_MONTH = "yyyy-MM"; + + @Bean + public ObjectMapper objectMapper() { + + var simpleModule = new SimpleModule() + .addDeserializer(LocalDateTime.class, new DollyLocalDateTimeDeserializer()) + .addSerializer(LocalDateTime.class, new LocalDateTimeSerializer(DateTimeFormatter.ISO_DATE_TIME)) + .addDeserializer(LocalDate.class, new DollyLocalDateDeserializer()) + .addSerializer(LocalDate.class, new LocalDateSerializer(DateTimeFormatter.ISO_DATE)) + .addDeserializer(YearMonth.class, new DollyYearMonthDeserializer()) + .addSerializer(YearMonth.class, new YearMonthSerializer(DateTimeFormatter.ofPattern(YEAR_MONTH))) + .addDeserializer(ZonedDateTime.class, new DollyZonedDateTimeDeserializer()) + .addSerializer(ZonedDateTime.class, new ZonedDateTimeSerializer(DateTimeFormatter.ISO_DATE_TIME)); + return JsonMapper + .builder() + .configure(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS, false) + .configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false) + .configure(DeserializationFeature.ACCEPT_EMPTY_STRING_AS_NULL_OBJECT, true) + .configure(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY, true) + .enable(MapperFeature.ACCEPT_CASE_INSENSITIVE_ENUMS) + .disable(SerializationFeature.FAIL_ON_EMPTY_BEANS) + .build() + .registerModule(new JavaTimeModule()) + .registerModule(simpleModule); + + } + + private static class DollyYearMonthDeserializer extends JsonDeserializer { + + @Override + public YearMonth deserialize(JsonParser jsonParser, DeserializationContext deserializationContext) throws IOException { + JsonNode node = jsonParser.getCodec().readTree(jsonParser); + if (isBlank(node.asText())) { + return null; + } + return YearMonth.parse(node.asText(), DateTimeFormatter.ofPattern(YEAR_MONTH)); + } + } + + private static class DollyZonedDateTimeDeserializer extends JsonDeserializer { + + @Override + public ZonedDateTime deserialize(JsonParser jsonParser, DeserializationContext deserializationContext) throws IOException { + JsonNode node = jsonParser.getCodec().readTree(jsonParser); + if (isBlank(node.asText())) { + return null; + } + return ZonedDateTime.parse(node.asText(), DateTimeFormatter.ISO_DATE_TIME); + } + } + + private static class DollyLocalDateDeserializer extends JsonDeserializer { + + @Override + public LocalDate deserialize(JsonParser jsonParser, DeserializationContext deserializationContext) throws IOException { + JsonNode node = jsonParser.getCodec().readTree(jsonParser); + if (isBlank(node.asText())) { + return null; + } + var dateTime = node.asText().length() > 10 ? node.asText().substring(0, 10) : node.asText(); + return LocalDate.parse(dateTime); + } + } + + private static class DollyLocalDateTimeDeserializer extends JsonDeserializer { + + @Override + public LocalDateTime deserialize(JsonParser jsonParser, DeserializationContext deserializationContext) throws IOException { + JsonNode node = jsonParser.getCodec().readTree(jsonParser); + if (isBlank(node.asText())) { + return null; + } + var dateTime = node.asText().length() > 19 ? node.asText().substring(0, 19) : node.asText(); + return dateTime.length() > 10 ? LocalDateTime.parse(dateTime) : LocalDate.parse(dateTime).atStartOfDay(); + } + } +} diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/MaskinportenConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/MaskinportenConfig.java similarity index 65% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/MaskinportenConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/MaskinportenConfig.java index 3ac7906824b..119cc389e30 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/MaskinportenConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/MaskinportenConfig.java @@ -1,24 +1,25 @@ -package no.nav.testnav.apps.organisasjontilgangservice.config; +package no.nav.testnav.altinn3tilgangservice.config; import lombok.Getter; import lombok.NoArgsConstructor; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; + @Getter @Configuration @NoArgsConstructor public class MaskinportenConfig { @Value("${MASKINPORTEN_CLIENT_ID}") - private String clientId; + private String maskinportenClientId; @Value("${MASKINPORTEN_CLIENT_JWK}") - private String jwkPrivate; + private String maskinportenClientJwk; @Value("${MASKINPORTEN_SCOPES}") - private String scope; + private String maskinportenScopes; @Value("${MASKINPORTEN_WELL_KNOWN_URL}") - private String wellKnownUrl; -} + private String maskinportenWellKnownUrl; +} \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/OpenApiConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/OpenApiConfig.java similarity index 71% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/OpenApiConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/OpenApiConfig.java index 9fbc6385f89..5cd5983a7f9 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/OpenApiConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/OpenApiConfig.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.config; +package no.nav.testnav.altinn3tilgangservice.config; import io.swagger.v3.oas.models.Components; import io.swagger.v3.oas.models.OpenAPI; @@ -13,10 +13,14 @@ import java.util.Arrays; import no.nav.testnav.libs.reactivecore.config.ApplicationProperties; +import org.springframework.web.server.ServerWebExchange; +import org.springframework.web.server.WebFilter; +import org.springframework.web.server.WebFilterChain; +import reactor.core.publisher.Mono; @Configuration -public class OpenApiConfig { +public class OpenApiConfig implements WebFilter { @Bean public OpenAPI openApi(ApplicationProperties applicationProperties) { @@ -46,4 +50,17 @@ public OpenAPI openApi(ApplicationProperties applicationProperties) { ) ); } + + @Override + public Mono filter(ServerWebExchange exchange, WebFilterChain chain) { + if (exchange.getRequest().getURI().getPath().equals("/swagger")) { + return chain + .filter(exchange.mutate() + .request(exchange.getRequest() + .mutate().path("/swagger-ui.html").build()) + .build()); + } + + return chain.filter(exchange); + } } \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/SecurityConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/SecurityConfig.java similarity index 96% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/SecurityConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/SecurityConfig.java index 79595cbdc7f..1472adbd5c6 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/config/SecurityConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/config/SecurityConfig.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.config; +package no.nav.testnav.altinn3tilgangservice.config; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/AltinnConsumer.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/AltinnConsumer.java new file mode 100644 index 00000000000..4a6f5de6b53 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/AltinnConsumer.java @@ -0,0 +1,179 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn; + +import com.fasterxml.jackson.core.type.TypeReference; +import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.ObjectMapper; +import lombok.SneakyThrows; +import lombok.extern.slf4j.Slf4j; +import ma.glasnost.orika.MapperFacade; +import no.nav.testnav.altinn3tilgangservice.config.AltinnConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.command.CreateAccessListeMemberCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.command.DeleteAccessListMemberCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.command.GetAccessListMembersCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.command.GetAuthorizedPartiesCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.command.GetExchangeTokenCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAccessListResponseDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAuthorizedPartiesRequestDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AuthorizedPartyDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.BrregResponseDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonCreateDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonDeleteDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.brreg.BrregConsumer; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.MaskinportenConsumer; +import no.nav.testnav.altinn3tilgangservice.domain.Organisasjon; +import org.springframework.http.codec.json.Jackson2JsonDecoder; +import org.springframework.http.codec.json.Jackson2JsonEncoder; +import org.springframework.stereotype.Component; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +import java.util.Arrays; +import java.util.List; +import java.util.Map; + +import static no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonCreateDTO.ORGANISASJON_ID; +import static org.apache.commons.lang3.StringUtils.isBlank; + +@Slf4j +@Component +public class AltinnConsumer { + + private final WebClient webClient; + private final AltinnConfig altinnConfig; + private final MapperFacade mapperFacade; + private final ObjectMapper objectMapper; + private final MaskinportenConsumer maskinportenConsumer; + private final BrregConsumer brregConsumer; + + public AltinnConsumer( + AltinnConfig altinnConfig, + MaskinportenConsumer maskinportenConsumer, + ObjectMapper objectMapper, + MapperFacade mapperFacade, + WebClient.Builder webClientBuilder, BrregConsumer brregConsumer) { + + this.altinnConfig = altinnConfig; + this.maskinportenConsumer = maskinportenConsumer; + this.webClient = webClientBuilder + .baseUrl(altinnConfig.getUrl()) + .codecs(clientDefaultCodecsConfigurer -> { + clientDefaultCodecsConfigurer + .defaultCodecs() + .jackson2JsonEncoder(new Jackson2JsonEncoder(objectMapper)); + clientDefaultCodecsConfigurer + .defaultCodecs() + .jackson2JsonDecoder(new Jackson2JsonDecoder(objectMapper)); + }) + .build(); + this.brregConsumer = brregConsumer; + this.mapperFacade = mapperFacade; + this.objectMapper = objectMapper; + } + + public Mono exchangeToken(String token) { + + return new GetExchangeTokenCommand(webClient, token).call(); + } + + public Flux delete(String organisasjonsnummer) { + + return Flux.from(getAccessListMembers() + .flatMapMany(value -> Flux.fromIterable(value.getData())) + .map(AltinnAccessListResponseDTO.AccessListMembershipDTO::getIdentifiers) + .collectList() + .map(data -> getIdentifier(data, organisasjonsnummer)) + .map(identifier -> + !identifier.getData().isEmpty() ? + maskinportenConsumer.getAccessToken() + .flatMap(this::exchangeToken) + .flatMap(exchangeToken -> new DeleteAccessListMemberCommand( + webClient, + exchangeToken, + identifier, + altinnConfig).call()) + .flatMapMany(this::convertToOrganisasjon) : + Flux.just(Organisasjon.builder() + .organisasjonsnummer(organisasjonsnummer) + .feilmelding("404 Not found: Organisasjon %s ble ikke funnet".formatted(organisasjonsnummer)) + .build()))) + .flatMap(Flux::from); + } + + public Mono create(String organisasjonsnummer) { + + return Mono.from(maskinportenConsumer.getAccessToken() + .flatMap(this::exchangeToken) + .flatMap(exchangeToken -> new CreateAccessListeMemberCommand( + webClient, + exchangeToken, + new OrganisasjonCreateDTO(organisasjonsnummer), + altinnConfig).call()) + .flatMapMany(response -> + isBlank(response.getFeilmelding()) ? + Flux.fromIterable(response.getData()) + .map(this::getOrgnummer) + .filter(organisasjonsnummer::equals) + .flatMap(brregConsumer::getEnhet) : + Mono.just(BrregResponseDTO.builder() + .organisasjonsnummer(organisasjonsnummer) + .feilmelding(response.getFeilmelding()) + .status(response.getStatus()) + .build())) + .map(response -> mapperFacade.map(response, Organisasjon.class))); + } + + public Flux getOrganisasjoner() { + + return getAccessListMembers() + .flatMapMany(this::convertToOrganisasjon); + } + + public Flux getAuthorizedParties(String ident) { + + return maskinportenConsumer.getAccessToken() + .flatMap(this::exchangeToken) + .flatMap(exchangeToken -> new GetAuthorizedPartiesCommand(webClient, + new AltinnAuthorizedPartiesRequestDTO(ident), + exchangeToken).call()) + .map(Arrays::asList) + .flatMapIterable(list -> list); + } + + private Mono getAccessListMembers() { + + return maskinportenConsumer.getAccessToken() + .flatMap(this::exchangeToken) + .flatMap(exchangeToken -> new GetAccessListMembersCommand( + webClient, + exchangeToken, + altinnConfig).call()); + } + + private Flux convertToOrganisasjon(AltinnAccessListResponseDTO altInnResponse) { + + return Flux.fromIterable(altInnResponse.getData()) + .map(this::getOrgnummer) + .flatMap(brregConsumer::getEnhet) + .map(response -> mapperFacade.map(response, Organisasjon.class)); + } + + private OrganisasjonDeleteDTO getIdentifier(List data, String organisasjonsnummer) { + + return data.stream() + .filter(identifier -> organisasjonsnummer.equals(identifier.get(ORGANISASJON_ID).asText())) + .map(identifier -> objectMapper.convertValue(identifier, + new TypeReference>() { + })) + .map(OrganisasjonDeleteDTO::new) + .findFirst().orElse(new OrganisasjonDeleteDTO()); + } + + @SneakyThrows + private String getOrgnummer(AltinnAccessListResponseDTO.AccessListMembershipDTO data) { + + return data.getIdentifiers() + .get(ORGANISASJON_ID) + .asText(); + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/CreateAccessListeMemberCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/CreateAccessListeMemberCommand.java new file mode 100644 index 00000000000..d665fd9723d --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/CreateAccessListeMemberCommand.java @@ -0,0 +1,52 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.config.AltinnConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAccessListResponseDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonCreateDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; +import java.util.stream.Collectors; + +@Slf4j +@RequiredArgsConstructor +public class CreateAccessListeMemberCommand implements Callable> { + + private static final String ALTINN_URL = "/resourceregistry/api/v1/access-lists/{owner}/{identifier}/members"; + + private final WebClient webClient; + private final String token; + private final OrganisasjonCreateDTO organisasjon; + private final AltinnConfig altinnConfig; + + + @Override + public Mono call() { + + return webClient + .post() + .uri(builder -> builder.path(ALTINN_URL) + .build(altinnConfig.getOwner(), altinnConfig.getIdentifier())) + .bodyValue(organisasjon) + .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .retrieve() + .bodyToMono(AltinnAccessListResponseDTO.class) + .doOnError(WebClientFilter::logErrorMessage) + .doOnSuccess(value -> log.info("Altinn organisasjontilgang opprettet for {}", + organisasjon.getData().stream() + .map(data -> data.split(":")) + .map(data -> data[data.length-1]) + .collect(Collectors.joining()))) + .onErrorResume(throwable -> Mono.just(AltinnAccessListResponseDTO.builder() + .status(WebClientFilter.getStatus(throwable)) + .feilmelding(WebClientFilter.getMessage(throwable)) + .build())); + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/DeleteAccessListMemberCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/DeleteAccessListMemberCommand.java new file mode 100644 index 00000000000..e685b681507 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/DeleteAccessListMemberCommand.java @@ -0,0 +1,53 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.config.AltinnConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAccessListResponseDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonDeleteDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.HttpMethod; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; +import java.util.stream.Collectors; + +import static no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.OrganisasjonCreateDTO.ORGANISASJON_ID; + +@Slf4j +@RequiredArgsConstructor +public class DeleteAccessListMemberCommand implements Callable> { + + private static final String ALTINN_URL = "/resourceregistry/api/v1/access-lists/{owner}/{identifier}/members"; + + private final WebClient webClient; + private final String token; + private final OrganisasjonDeleteDTO identifiers; + private final AltinnConfig altinnConfig; + + + @Override + public Mono call() { + + return webClient + .method(HttpMethod.DELETE) + .uri(builder -> builder.path(ALTINN_URL) + .build(altinnConfig.getOwner(), altinnConfig.getIdentifier()) + ) + .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .bodyValue(identifiers) + .retrieve() + .bodyToMono(AltinnAccessListResponseDTO.class) + .doOnSuccess(value -> log.info("Altinn organisasjontilgang slettet for {}", + identifiers.getData().stream() + .filter(data -> data.contains(ORGANISASJON_ID)) + .map(data -> data.split(":")) + .map(data -> data[data.length - 1]) + .collect(Collectors.joining()))) + .doOnError(WebClientFilter::logErrorMessage); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAccessListMembersCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAccessListMembersCommand.java new file mode 100644 index 00000000000..19f63d2f8db --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAccessListMembersCommand.java @@ -0,0 +1,39 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.config.AltinnConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAccessListResponseDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; + +@Slf4j +@RequiredArgsConstructor +public class GetAccessListMembersCommand implements Callable> { + + private static final String ALTINN_URL = "/resourceregistry/api/v1/access-lists/{owner}/{identifier}/members"; + + private final WebClient webClient; + private final String token; + private final AltinnConfig altinnConfig; + + @Override + public Mono call() { + + return webClient + .get() + .uri(builder -> builder.path(ALTINN_URL) + .build(altinnConfig.getOwner(), altinnConfig.getIdentifier())) + .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .retrieve() + .bodyToMono(AltinnAccessListResponseDTO.class) + .doOnError(WebClientFilter::logErrorMessage) + .doOnSuccess(value -> log.info("Altinn-tilgang hentet")); + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAuthorizedPartiesCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAuthorizedPartiesCommand.java new file mode 100644 index 00000000000..d58693bacb2 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetAuthorizedPartiesCommand.java @@ -0,0 +1,40 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AltinnAuthorizedPartiesRequestDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AuthorizedPartyDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; + +@Slf4j +@RequiredArgsConstructor +public class GetAuthorizedPartiesCommand implements Callable> { + + private static final String ALTINN_URL = "/accessmanagement/api/v1/resourceowner/authorizedparties"; + + private final WebClient webClient; + private final AltinnAuthorizedPartiesRequestDTO request; + private final String token; + + @Override + public Mono call() { + + log.info("Spørring på bruker {}", request); + return webClient + .post() + .uri(builder -> builder.path(ALTINN_URL) + .build()) + .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .bodyValue(request) + .retrieve() + .bodyToMono(AuthorizedPartyDTO[].class) + .doOnError(WebClientFilter::logErrorMessage); + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetExchangeTokenCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetExchangeTokenCommand.java new file mode 100644 index 00000000000..b6037f76e01 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/command/GetExchangeTokenCommand.java @@ -0,0 +1,37 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; + +@Slf4j +@RequiredArgsConstructor +public class GetExchangeTokenCommand implements Callable> { + + private static final String ALTINN_URL = "/authentication/api/v1/exchange/maskinporten"; + + private final WebClient webClient; + private final String token; + + @Override + public Mono call() { + + return webClient + .get() + .uri(builder -> builder.path(ALTINN_URL) + .build() + ) + .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .retrieve() + .bodyToMono(String.class) + .doOnError(WebClientFilter::logErrorMessage) + .doOnSuccess(response -> log.info("Exchange token hentet fra Altinn")); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAccessListResponseDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAccessListResponseDTO.java new file mode 100644 index 00000000000..6521fa55049 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAccessListResponseDTO.java @@ -0,0 +1,44 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import com.fasterxml.jackson.databind.JsonNode; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.springframework.http.HttpStatus; + +import java.time.LocalDateTime; +import java.util.ArrayList; +import java.util.List; + +import static java.util.Objects.isNull; + +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +public class AltinnAccessListResponseDTO { + + private List data; + private String feilmelding; + private HttpStatus status; + + public List getData() { + + if (isNull(data)) { + data = new ArrayList<>(); + } + return data; + } + + @Data + @Builder + @NoArgsConstructor + @AllArgsConstructor + public static class AccessListMembershipDTO { + + private String id; + private LocalDateTime since; + private JsonNode identifiers; + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAuthorizedPartiesRequestDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAuthorizedPartiesRequestDTO.java new file mode 100644 index 00000000000..7e2eecded37 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AltinnAuthorizedPartiesRequestDTO.java @@ -0,0 +1,18 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import lombok.Data; + +@Data +public class AltinnAuthorizedPartiesRequestDTO { + + private static final String IDENT_IDENTIFIKATOR = "urn:altinn:person:identifier-no"; + + private String type; + private String value; + + public AltinnAuthorizedPartiesRequestDTO(String ident) { + + this.type = IDENT_IDENTIFIKATOR; + this.value = ident; + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AuthorizedPartyDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AuthorizedPartyDTO.java new file mode 100644 index 00000000000..0fe03486d57 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/AuthorizedPartyDTO.java @@ -0,0 +1,42 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.ArrayList; +import java.util.List; + +import static java.util.Objects.isNull; + +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +public class AuthorizedPartyDTO { + + private String name; + private String organizationNumber; + private String unitType; + private Boolean isDeleted; + private List authorizedResources; + private List subunits; + + public List getAuthorizedResources() { + + if (isNull(authorizedResources)) { + authorizedResources = new ArrayList<>(); + } + return authorizedResources; + } + + public List getSubunits() { + + if (isNull(subunits)) { + subunits = new ArrayList<>(); + } + return subunits; + } +} + diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/BrregResponseDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/BrregResponseDTO.java new file mode 100644 index 00000000000..fd94b4134a2 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/BrregResponseDTO.java @@ -0,0 +1,65 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.springframework.http.HttpStatus; + +import java.util.List; + +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +public class BrregResponseDTO { + + private Embedded _embedded; + private Link _links; + + private String organisasjonsnummer; + private String feilmelding; + private HttpStatus status; + + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Embedded { + + private List enheter; + } + + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Enhet { + + private String organisasjonsnummer; + private String navn; + private Organisasjonsform organisasjonsform; + } + + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Organisasjonsform { + + private String kode; + } + + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Link { + + private Self self; + } + + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Self { + + private String href; + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonCreateDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonCreateDTO.java new file mode 100644 index 00000000000..af1d881e965 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonCreateDTO.java @@ -0,0 +1,18 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import lombok.Data; + +import java.util.List; + +@Data +public class OrganisasjonCreateDTO { + + public static final String ORGANISASJON_ID = "urn:altinn:organization:identifier-no"; + + private List data; + + public OrganisasjonCreateDTO(String orgnummer) { + + this.data = List.of("%s:%s".formatted(ORGANISASJON_ID, orgnummer)); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonDeleteDTO.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonDeleteDTO.java new file mode 100644 index 00000000000..16d570268f2 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/altinn/dto/OrganisasjonDeleteDTO.java @@ -0,0 +1,32 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto; + +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import static java.util.Objects.isNull; + +@Data +@NoArgsConstructor +public class OrganisasjonDeleteDTO { + + private List data; + + public List getData() { + + if (isNull(data)) { + data = new ArrayList<>(); + } + return data; + } + + public OrganisasjonDeleteDTO(Map organisasjon) { + + data = organisasjon.entrySet().stream() + .map(entry -> "%s:%s".formatted(entry.getKey(), entry.getValue())) + .toList(); + } +} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/BrregConsumer.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/BrregConsumer.java new file mode 100644 index 00000000000..bb536729142 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/BrregConsumer.java @@ -0,0 +1,26 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.brreg; + +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.BrregResponseDTO; +import no.nav.testnav.altinn3tilgangservice.consumer.brreg.command.GetBrregEnheterCommand; +import org.springframework.stereotype.Service; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +@Service +public class BrregConsumer { + + private static final String BRREG_URL = "https://data.brreg.no"; + + private final WebClient webClient; + + public BrregConsumer(WebClient.Builder webClientBuilder) { + this.webClient = webClientBuilder + .baseUrl(BRREG_URL) + .build(); + } + + public Mono getEnhet(String orgnummer) { + + return new GetBrregEnheterCommand(webClient, orgnummer).call(); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/command/GetBrregEnheterCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/command/GetBrregEnheterCommand.java new file mode 100644 index 00000000000..7fca24c0dc0 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/brreg/command/GetBrregEnheterCommand.java @@ -0,0 +1,37 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.brreg.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.BrregResponseDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.util.concurrent.Callable; + +@Slf4j +@RequiredArgsConstructor +public class GetBrregEnheterCommand implements Callable> { + + private static final String BRREG_ENHETER_URL = "/enhetsregisteret/api/enheter"; + + private final WebClient webClient; + private final String organisasjonsnummer; + + @Override + public Mono call() { + + return webClient + .get() + .uri(builder -> builder.path(BRREG_ENHETER_URL) + .queryParam("organisasjonsnummer", organisasjonsnummer) + .build() + ) + .header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE) + .retrieve() + .bodyToMono(BrregResponseDTO.class) + .doOnError(WebClientFilter::logErrorMessage); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/MaskinportenConsumer.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/MaskinportenConsumer.java new file mode 100644 index 00000000000..4ee44a8b126 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/MaskinportenConsumer.java @@ -0,0 +1,74 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.maskinporten; + +import com.nimbusds.jose.JOSEObjectType; +import com.nimbusds.jose.JWSAlgorithm; +import com.nimbusds.jose.JWSHeader; +import com.nimbusds.jose.crypto.RSASSASigner; +import com.nimbusds.jose.jwk.RSAKey; +import com.nimbusds.jwt.JWTClaimsSet; +import com.nimbusds.jwt.SignedJWT; +import lombok.SneakyThrows; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.config.MaskinportenConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.command.GetAccessTokenCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.command.GetWellKnownCommand; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto.AccessToken; +import org.springframework.stereotype.Component; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.time.Instant; +import java.util.Date; +import java.util.UUID; + +@Slf4j +@Component +public class MaskinportenConsumer { + + private final WebClient webClient; + private final MaskinportenConfig maskinportenConfig; + + public MaskinportenConsumer(MaskinportenConfig maskinportenConfig, WebClient.Builder webClientBuilder) { + + this.webClient = webClientBuilder.build(); + this.maskinportenConfig = maskinportenConfig; + } + + public Mono getAccessToken() { + + return new GetWellKnownCommand(webClient, maskinportenConfig).call() + .flatMap(wellKnown -> new GetAccessTokenCommand(webClient, wellKnown, + createJwtClaims(wellKnown.issuer())).call()) + .map(AccessToken::accessToken); + } + + @SneakyThrows + private String createJwtClaims(String audience) { + + var now = Instant.now(); + var rsaKey = RSAKey.parse(maskinportenConfig.getMaskinportenClientJwk()); + return createSignedJWT(rsaKey, + new JWTClaimsSet.Builder() + .audience(audience) + .claim("scope", maskinportenConfig.getMaskinportenScopes()) + .issuer(maskinportenConfig.getMaskinportenClientId()) + .issueTime(Date.from(now)) + .expirationTime(Date.from(now.plusSeconds(120))) + .jwtID(UUID.randomUUID().toString()) + .build()) + .serialize(); + } + + @SneakyThrows + private SignedJWT createSignedJWT(RSAKey rsaJwk, JWTClaimsSet claimsSet) { + + var header = new JWSHeader.Builder(JWSAlgorithm.RS256) + .keyID(rsaJwk.getKeyID()) + .type(JOSEObjectType.JWT); + var signedJWT = new SignedJWT(header.build(), claimsSet); + var signer = new RSASSASigner(rsaJwk.toPrivateKey()); + signedJWT.sign(signer); + + return signedJWT; + } +} diff --git a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/command/GetAccessTokenCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetAccessTokenCommand.java similarity index 56% rename from apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/command/GetAccessTokenCommand.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetAccessTokenCommand.java index f1da03d101d..ea87d47f598 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/command/GetAccessTokenCommand.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetAccessTokenCommand.java @@ -1,14 +1,15 @@ -package no.nav.testnav.apps.persontilgangservice.client.maskinporten.v1.command; +package no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.command; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import no.nav.testnav.apps.persontilgangservice.client.maskinporten.v1.dto.AccessToken; -import no.nav.testnav.apps.persontilgangservice.client.maskinporten.v1.dto.WellKnown; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto.AccessToken; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto.WellKnown; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; import org.springframework.web.reactive.function.BodyInserters; import org.springframework.web.reactive.function.client.WebClient; -import org.springframework.web.reactive.function.client.WebClientResponseException; import reactor.core.publisher.Mono; +import java.time.Duration; import java.util.concurrent.Callable; @Slf4j @@ -20,21 +21,17 @@ public class GetAccessTokenCommand implements Callable> { @Override public Mono call() { + return webClient.post() .uri(wellKnown.tokenEndpoint()) .body(BodyInserters - .fromFormData("grant_type", wellKnown.grantTypesSupported().get(0)) + .fromFormData("grant_type", wellKnown.grantTypesSupported().getFirst()) .with("assertion", assertion) ) .retrieve() .bodyToMono(AccessToken.class) .doOnSuccess(value -> log.info("AccessToken hentet fra maskinporten.")) - .doOnError( - WebClientResponseException.class::isInstance, - throwable -> log.error( - "Feil ved henting av AccessToken for maskinporten. \n{}", - ((WebClientResponseException) throwable).getResponseBodyAsString() - ) - ); + .doOnError(WebClientFilter::logErrorMessage) + .cache(Duration.ofSeconds(10L)); } } diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetWellKnownCommand.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetWellKnownCommand.java new file mode 100644 index 00000000000..610d47944ad --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/command/GetWellKnownCommand.java @@ -0,0 +1,32 @@ +package no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.command; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.config.MaskinportenConfig; +import no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto.WellKnown; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +import java.time.Duration; +import java.util.concurrent.Callable; + +@Slf4j +@RequiredArgsConstructor +public class GetWellKnownCommand implements Callable> { + + private final WebClient webClient; + private final MaskinportenConfig maskinportenConfig; + + @Override + public Mono call() { + + return webClient.get() + .uri(maskinportenConfig.getMaskinportenWellKnownUrl()) + .retrieve() + .bodyToMono(WellKnown.class) + .doOnSuccess(value -> log.info("WellKnown hentet for maskinporten.")) + .doOnError(WebClientFilter::logErrorMessage) + .cache(Duration.ofDays(1L)); + } +} diff --git a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/AccessToken.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/AccessToken.java similarity index 81% rename from apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/AccessToken.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/AccessToken.java index 90ede59fe24..c6e5df1c632 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/AccessToken.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/AccessToken.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.persontilgangservice.client.maskinporten.v1.dto; +package no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/WellKnown.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/WellKnown.java similarity index 85% rename from apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/WellKnown.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/WellKnown.java index da750ff225d..da3eb6903ce 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/persontilgangservice/client/maskinporten/v1/dto/WellKnown.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/consumer/maskinporten/dto/WellKnown.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.persontilgangservice.client.maskinporten.v1.dto; +package no.nav.testnav.altinn3tilgangservice.consumer.maskinporten.dto; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/entity/OrganisasjonTilgang.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/entity/OrganisasjonTilgang.java similarity index 78% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/entity/OrganisasjonTilgang.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/entity/OrganisasjonTilgang.java index 154d47ef35d..0fe0b183a2a 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/entity/OrganisasjonTilgang.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/entity/OrganisasjonTilgang.java @@ -1,10 +1,11 @@ -package no.nav.testnav.apps.organisasjontilgangservice.database.entity; +package no.nav.testnav.altinn3tilgangservice.database.entity; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Data; import lombok.NoArgsConstructor; import org.springframework.data.annotation.Id; +import org.springframework.data.annotation.Transient; import org.springframework.data.relational.core.mapping.Column; import org.springframework.data.relational.core.mapping.Table; @@ -24,4 +25,7 @@ public class OrganisasjonTilgang { @Column("miljoe") private String miljoe; + + @Transient + private String feilmelding; } \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/repository/OrganisasjonTilgangRepository.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/repository/OrganisasjonTilgangRepository.java similarity index 65% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/repository/OrganisasjonTilgangRepository.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/repository/OrganisasjonTilgangRepository.java index 67f0b1997d0..8b7b3096e23 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/database/repository/OrganisasjonTilgangRepository.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/database/repository/OrganisasjonTilgangRepository.java @@ -1,6 +1,6 @@ -package no.nav.testnav.apps.organisasjontilgangservice.database.repository; +package no.nav.testnav.altinn3tilgangservice.database.repository; -import no.nav.testnav.apps.organisasjontilgangservice.database.entity.OrganisasjonTilgang; +import no.nav.testnav.altinn3tilgangservice.database.entity.OrganisasjonTilgang; import org.springframework.data.repository.reactive.ReactiveCrudRepository; import reactor.core.publisher.Mono; @@ -12,5 +12,5 @@ public interface OrganisasjonTilgangRepository extends ReactiveCrudRepository save(OrganisasjonTilgang organisasjonTilgang); - Mono deleteByOrganisasjonNummer(String orgnummer); + Mono deleteByOrganisasjonNummer(String orgnummer); } \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/consumer/altinn/v1/dto/DeleteStatus.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/Organisasjon.java similarity index 50% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/consumer/altinn/v1/dto/DeleteStatus.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/Organisasjon.java index 388453047e4..69eab5dff90 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/consumer/altinn/v1/dto/DeleteStatus.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/Organisasjon.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.consumer.altinn.v1.dto; +package no.nav.testnav.altinn3tilgangservice.domain; import lombok.AllArgsConstructor; import lombok.Builder; @@ -10,7 +10,13 @@ @Builder @NoArgsConstructor @AllArgsConstructor -public class DeleteStatus { +public class Organisasjon { + private String navn; + private String organisasjonsnummer; + private String organisasjonsform; + private String url; + + private String feilmelding; private HttpStatus status; } diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/domain/OrganisasjonResponse.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/OrganisasjonResponse.java similarity index 71% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/domain/OrganisasjonResponse.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/OrganisasjonResponse.java index 7b2d1be2ec9..20f3b590a87 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/domain/OrganisasjonResponse.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/OrganisasjonResponse.java @@ -1,12 +1,10 @@ -package no.nav.testnav.apps.organisasjontilgangservice.domain; +package no.nav.testnav.altinn3tilgangservice.domain; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Data; import lombok.NoArgsConstructor; -import java.time.LocalDateTime; - @Data @Builder @NoArgsConstructor @@ -16,6 +14,8 @@ public class OrganisasjonResponse { private String navn; private String organisasjonsnummer; private String organisasjonsform; - private LocalDateTime gyldigTil; private String miljoe; + private String url; + + private String feilmelding; } diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/PersonRequest.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/PersonRequest.java new file mode 100644 index 00000000000..40f9ef759f0 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/domain/PersonRequest.java @@ -0,0 +1,13 @@ +package no.nav.testnav.altinn3tilgangservice.domain; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; + +@Data +@NoArgsConstructor +@AllArgsConstructor +public class PersonRequest { + + private String ident; +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/BrrregResponseMappingStrategy.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/BrrregResponseMappingStrategy.java new file mode 100644 index 00000000000..bbbc3432445 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/BrrregResponseMappingStrategy.java @@ -0,0 +1,49 @@ +package no.nav.testnav.altinn3tilgangservice.mapper; + +import ma.glasnost.orika.CustomMapper; +import ma.glasnost.orika.MapperFactory; +import ma.glasnost.orika.MappingContext; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.BrregResponseDTO; +import no.nav.testnav.altinn3tilgangservice.domain.Organisasjon; +import org.springframework.stereotype.Component; + +import static java.util.Objects.nonNull; +import static org.apache.commons.lang3.StringUtils.isBlank; + +@Component +public class BrrregResponseMappingStrategy implements MappingStrategy { + + @Override + public void register(MapperFactory factory) { + factory.classMap(BrregResponseDTO.class, Organisasjon.class) + .customize(new CustomMapper<>() { + @Override + public void mapAtoB(BrregResponseDTO kilde, Organisasjon destinasjon, MappingContext context) { + + if (isBlank(kilde.getFeilmelding())) { + var link = kilde.get_links().getSelf().getHref(); + if (nonNull(kilde.get_embedded())) { + mapperFacade.map(kilde.get_embedded().getEnheter().getFirst(), destinasjon, context); + } else { + destinasjon.setNavn("Ukjent organisasjon hos BRREG"); + destinasjon.setOrganisasjonsform("???"); + destinasjon.setOrganisasjonsnummer(link.substring(link.indexOf('=') + 1)); + } + destinasjon.setUrl(link); + } + } + }) + .byDefault() + .register(); + + factory.classMap(BrregResponseDTO.Enhet.class, Organisasjon.class) + .customize(new CustomMapper<>() { + @Override + public void mapAtoB(BrregResponseDTO.Enhet kilde, Organisasjon destianasjon, MappingContext context) { + + destianasjon.setOrganisasjonsform(kilde.getOrganisasjonsform().getKode()); + } + }).byDefault() + .register(); + } +} diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MapperFacadeConfig.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MapperFacadeConfig.java similarity index 94% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MapperFacadeConfig.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MapperFacadeConfig.java index 37af6d8419f..c0fe7cf844b 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MapperFacadeConfig.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MapperFacadeConfig.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.mapper; +package no.nav.testnav.altinn3tilgangservice.mapper; import ma.glasnost.orika.CustomConverter; import ma.glasnost.orika.MapperFacade; diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MappingStrategy.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MappingStrategy.java similarity index 87% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MappingStrategy.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MappingStrategy.java index f099f95bdc8..a8e49e743d4 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/MappingStrategy.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/MappingStrategy.java @@ -1,4 +1,4 @@ -package no.nav.testnav.apps.organisasjontilgangservice.mapper; +package no.nav.testnav.altinn3tilgangservice.mapper; import ma.glasnost.orika.MapperFactory; diff --git a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/OrganisajonTilgangMappingStrategy.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/OrganisajonTilgangMappingStrategy.java similarity index 74% rename from apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/OrganisajonTilgangMappingStrategy.java rename to apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/OrganisajonTilgangMappingStrategy.java index 1429916dc6d..da0153af926 100644 --- a/apps/organisasjon-tilgang-service/src/main/java/no/nav/testnav/apps/organisasjontilgangservice/mapper/OrganisajonTilgangMappingStrategy.java +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/mapper/OrganisajonTilgangMappingStrategy.java @@ -1,11 +1,11 @@ -package no.nav.testnav.apps.organisasjontilgangservice.mapper; +package no.nav.testnav.altinn3tilgangservice.mapper; import ma.glasnost.orika.CustomMapper; import ma.glasnost.orika.MapperFactory; import ma.glasnost.orika.MappingContext; -import no.nav.testnav.apps.organisasjontilgangservice.database.entity.OrganisasjonTilgang; -import no.nav.testnav.apps.organisasjontilgangservice.domain.Organisasjon; -import no.nav.testnav.apps.organisasjontilgangservice.domain.OrganisasjonResponse; +import no.nav.testnav.altinn3tilgangservice.database.entity.OrganisasjonTilgang; +import no.nav.testnav.altinn3tilgangservice.domain.Organisasjon; +import no.nav.testnav.altinn3tilgangservice.domain.OrganisasjonResponse; import org.springframework.stereotype.Component; import static java.util.Objects.nonNull; @@ -22,7 +22,7 @@ public void register(MapperFactory factory) { @Override public void mapAtoB(Organisasjon organisasjon, OrganisasjonResponse response, MappingContext context) { - var organisasjonTilgang = (OrganisasjonTilgang) context.getProperty("organisasjonTilgang"); + var organisasjonTilgang = (OrganisasjonTilgang) context.getProperty("tilgang"); response.setMiljoe(nonNull(organisasjonTilgang) && isNotBlank(organisasjonTilgang.getMiljoe()) ? organisasjonTilgang.getMiljoe() : "q1"); } diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnBrukerTilgangController.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnBrukerTilgangController.java new file mode 100644 index 00000000000..55893774beb --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnBrukerTilgangController.java @@ -0,0 +1,33 @@ +package no.nav.testnav.altinn3tilgangservice.provider; + +import lombok.RequiredArgsConstructor; +import no.nav.testnav.altinn3tilgangservice.domain.PersonRequest; +import no.nav.testnav.altinn3tilgangservice.service.AltinnBrukerTilgangService; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; +import no.nav.testnav.libs.dto.altinn3.v1.PersonDTO; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +@RestController +@RequestMapping("/api/v1/brukertilgang") +@RequiredArgsConstructor +public class AltinnBrukerTilgangController { + + private final AltinnBrukerTilgangService brukerTilgangService; + + @PostMapping + public Flux getPersonOrganisasjonTilgang(@RequestBody PersonRequest request) { + + return brukerTilgangService.getPersonOrganisasjonTilgang(request.getIdent()); + } + + @PostMapping("/detaljert") + public Mono getPersonOrganisasjonDetaljertTilgang(@RequestBody PersonRequest request) { + + return brukerTilgangService.getPersonOrganisasjonDetaljertTilgang(request.getIdent()); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnOrganisasjonTilgangController.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnOrganisasjonTilgangController.java new file mode 100644 index 00000000000..5c83bf67abd --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/AltinnOrganisasjonTilgangController.java @@ -0,0 +1,51 @@ +package no.nav.testnav.altinn3tilgangservice.provider; + +import io.swagger.v3.oas.annotations.Operation; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.domain.OrganisasjonResponse; +import no.nav.testnav.altinn3tilgangservice.service.AltinnOrganisasjonTilgangService; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +import java.util.Comparator; + +@Slf4j +@RestController +@RequestMapping("/api/v1/organisasjoner") +@RequiredArgsConstructor +public class AltinnOrganisasjonTilgangController { + + private final AltinnOrganisasjonTilgangService altinnTilgangService; + + @GetMapping + @Operation(description = "Henter alle organisasjoner med Altinn-tilgang") + public Flux getAll() { + + return altinnTilgangService.getAll() + .sort(Comparator.comparing(OrganisasjonResponse::getNavn)); + } + + @PostMapping("/{organisasjonsnummer}") + @Operation(description = "Oppretter Altinn-tilgang for organisasjon") + public Mono create(@PathVariable String organisasjonsnummer, + @RequestParam String miljoe) { + + return altinnTilgangService + .create(organisasjonsnummer, miljoe); + } + + @DeleteMapping("/{organisasjonsnummer}") + @Operation(description = "Sletter Altinn-tilgang for organisasjon") + public Flux delete(@PathVariable String organisasjonsnummer) { + + return altinnTilgangService.delete(organisasjonsnummer); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/OrganisasjonMiljoeController.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/OrganisasjonMiljoeController.java new file mode 100644 index 00000000000..cc91176d3b5 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/provider/OrganisasjonMiljoeController.java @@ -0,0 +1,38 @@ +package no.nav.testnav.altinn3tilgangservice.provider; + +import io.swagger.v3.oas.annotations.Operation; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.database.entity.OrganisasjonTilgang; +import no.nav.testnav.altinn3tilgangservice.service.MiljoerOversiktService; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; +import reactor.core.publisher.Mono; + +@Slf4j +@RestController +@RequestMapping("/api/v1/miljoer") +@RequiredArgsConstructor +public class OrganisasjonMiljoeController { + + private final MiljoerOversiktService miljoerOversiktService; + + @GetMapping("/organisasjon/{organisasjonsnummer}") + @Operation(description = "Henter miljøer for organisasjon") + public Mono getOrganisasjon(@PathVariable("organisasjonsnummer") String orgnummer) { + + return miljoerOversiktService.getMiljoe(orgnummer); + } + + @PutMapping("/organisasjon/{organisasjonsnummer}") + @Operation(description = "Endrer miljøer for organisasjon") + public Mono updateOrganisasjon(@PathVariable("organisasjonsnummer") String orgnummer, + @RequestParam String miljoe) { + + return miljoerOversiktService.updateMiljoe(orgnummer, miljoe); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnBrukerTilgangService.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnBrukerTilgangService.java new file mode 100644 index 00000000000..ba468bb4273 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnBrukerTilgangService.java @@ -0,0 +1,108 @@ +package no.nav.testnav.altinn3tilgangservice.service; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.AltinnConsumer; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.dto.AuthorizedPartyDTO; +import no.nav.testnav.altinn3tilgangservice.domain.Organisasjon; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; +import no.nav.testnav.libs.dto.altinn3.v1.PersonDTO; +import org.springframework.stereotype.Service; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; +import reactor.util.function.Tuple2; + +import java.util.List; + +@Slf4j +@Service +@RequiredArgsConstructor +public class AltinnBrukerTilgangService { + + private static final String DOLLY_RESOURCE = "nav_dolly_tilgang-samarbeidspartnere"; + private final AltinnConsumer altinnConsumer; + + public Flux getPersonOrganisasjonTilgang(String ident) { + + return Flux.zip( + altinnConsumer.getAuthorizedParties(ident).collectList(), + altinnConsumer.getOrganisasjoner().collectList()) + .flatMap(this::getOrganisasjon); + } + + private Flux getOrganisasjon(Tuple2, List> organisasjoner) { + + return Flux.fromIterable(organisasjoner.getT1()) + .doOnNext(org -> log.info("Organisasjon {}", org)) + .filter(party -> party.getAuthorizedResources().contains(DOLLY_RESOURCE)) + .filter(party -> organisasjoner.getT2().stream() + .anyMatch(organisasjon -> organisasjon.getOrganisasjonsnummer().equals(party.getOrganizationNumber()))) + .map(part -> OrganisasjonDTO.builder() + .navn(part.getName()) + .organisasjonsnummer(part.getOrganizationNumber()) + .organisasjonsform(part.getUnitType()) + .build()); + } + + public Mono getPersonOrganisasjonDetaljertTilgang(String ident) { + + return Mono.zip( + altinnConsumer.getAuthorizedParties(ident).collectList(), + altinnConsumer.getOrganisasjoner().collectList()) + .flatMapMany(this::getTilpassetOrganisasjon) + .collectList() + .map(organisasjoner -> PersonDTO.builder() + .ident(ident) + .organisasjoner(organisasjoner) + .build()); + } + + private Flux getTilpassetOrganisasjon(Tuple2, List> organisasjoner) { + + return Flux.fromIterable(organisasjoner.getT1()) + .map(party -> PersonDTO.OrganisasjonDTO.builder() + .navn(party.getName()) + .organisasjonsnummer(party.getOrganizationNumber()) + .organisasjonsform(party.getUnitType()) + .hasAltinnDollyTilgang(hasAltinnDollyTilgang(party)) + .hasDollyOrganisasjonTilgang(hasDollyOrganisasjonTilgang(organisasjoner.getT2(), party)) + .melding(getMelding(party.getName(), party.getOrganizationNumber(), + hasAltinnDollyTilgang(party), hasDollyOrganisasjonTilgang(organisasjoner.getT2(), party))) + .build()); + } + + private static boolean hasAltinnDollyTilgang(AuthorizedPartyDTO authorizedParty) { + + return authorizedParty.getAuthorizedResources().contains(DOLLY_RESOURCE); + } + + private static boolean hasDollyOrganisasjonTilgang(List organisasjoner, AuthorizedPartyDTO party) { + + return organisasjoner.stream() + .anyMatch(organisasjon -> organisasjon.getOrganisasjonsnummer().equals(party.getOrganizationNumber())); + } + + private static String getMelding(String orgnavn, String orgnummer, boolean hasAltinnDollyTilgang, boolean hasDollyOrganisasjonTilgang) { + + return new StringBuilder() + .append(!hasAltinnDollyTilgang ? + "Du mangler tilgang i Altinn på følgende tjenste: " + + "\"Tilgang til NAVs Dolly for samarbeidspartnere\" " + + "for organisasjon %s (med orgnummer %s)%n".formatted(orgnavn, orgnummer) : "") + .append(!hasAltinnDollyTilgang && !hasDollyOrganisasjonTilgang ? + " og %n" : "") + .append(!hasDollyOrganisasjonTilgang ? + "Organisasjon %s (med orgnummer %s) " .formatted(orgnavn, orgnummer) + + "mangler tilgang på Dolly syntetiske testdata selvbetjening%n" : "") + .append(!hasAltinnDollyTilgang || !hasDollyOrganisasjonTilgang ? + "Hvis du har til hensikt å bruke Dolly til å generere testdata, gjør følgende:%n" : "") + .append(!hasAltinnDollyTilgang ? + "- Ta kontakt med Altinn-ansvarlig i %s (med orgnummer %s) ".formatted(orgnavn, orgnummer) + + "og spør om vedkommene kan gi deg tilgang til tjenesten: " + + "\"Tilgang til NAVs Dolly for samarbeidspartnere\"%n" : "") + .append(!hasDollyOrganisasjonTilgang ? + "- Ta kontakt med NAV ved Anders Marstrander epost: anders.marstrander@nav.no, og spør om " + + "organisasjon med orgnr %s kan gis tilgang til Dolly syntetiske testdata selvbetjening%n".formatted(orgnummer) : "") + .toString(); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnOrganisasjonTilgangService.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnOrganisasjonTilgangService.java new file mode 100644 index 00000000000..45b9067b46b --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/AltinnOrganisasjonTilgangService.java @@ -0,0 +1,91 @@ +package no.nav.testnav.altinn3tilgangservice.service; + +import lombok.RequiredArgsConstructor; +import ma.glasnost.orika.MapperFacade; +import ma.glasnost.orika.MappingContext; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.AltinnConsumer; +import no.nav.testnav.altinn3tilgangservice.database.entity.OrganisasjonTilgang; +import no.nav.testnav.altinn3tilgangservice.database.repository.OrganisasjonTilgangRepository; +import no.nav.testnav.altinn3tilgangservice.domain.Organisasjon; +import no.nav.testnav.altinn3tilgangservice.domain.OrganisasjonResponse; +import org.springframework.stereotype.Service; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +import static org.apache.commons.lang3.BooleanUtils.isTrue; +import static org.apache.commons.lang3.StringUtils.isBlank; + +@Service +@RequiredArgsConstructor +public class AltinnOrganisasjonTilgangService { + + private static final String ORGANISASJON_TILGANG = "tilgang"; + private final AltinnConsumer altinnConsumer; + private final OrganisasjonTilgangRepository organisasjonTilgangRepository; + private final MapperFacade mapperFacade; + + public Flux getAll() { + + return altinnConsumer.getOrganisasjoner() + .flatMap(this::convertResponse); + } + + public Mono create(String orgnummer, String miljoe) { + + return altinnConsumer.create(orgnummer) + .flatMap(altinnOrg -> { + if (isBlank(altinnOrg.getFeilmelding())) { + return saveOrganisasjon(orgnummer, miljoe) + .map(tilgang -> { + var context = new MappingContext.Factory().getContext(); + context.setProperty(ORGANISASJON_TILGANG, tilgang); + return mapperFacade.map(altinnOrg, OrganisasjonResponse.class, context); + }); + } else { + var context = new MappingContext.Factory().getContext(); + context.setProperty(ORGANISASJON_TILGANG, OrganisasjonTilgang.builder() + .organisasjonNummer(orgnummer) + .miljoe(miljoe) + .build()); + return Mono.just(mapperFacade.map(altinnOrg, OrganisasjonResponse.class, context)); + } + }); + } + + public Flux delete(String organisasjonsnummer) { + + return organisasjonTilgangRepository.deleteByOrganisasjonNummer(organisasjonsnummer) + .flatMapMany(result -> altinnConsumer.delete(organisasjonsnummer)) + .flatMap(this::convertResponse); + } + + private Mono convertResponse(Organisasjon organisasjon) { + + return organisasjonTilgangRepository + .existsByOrganisasjonNummer(organisasjon.getOrganisasjonsnummer()) + .flatMap(exists -> isTrue(exists) ? + organisasjonTilgangRepository + .findByOrganisasjonNummer(organisasjon.getOrganisasjonsnummer()) : + Mono.just(new OrganisasjonTilgang())) + .map(organisasjonTilgang -> { + var context = new MappingContext.Factory().getContext(); + context.setProperty(ORGANISASJON_TILGANG, organisasjonTilgang); + return mapperFacade.map(organisasjon, OrganisasjonResponse.class, context); + }); + } + + private Mono saveOrganisasjon(String orgnummer, String miljoe) { + + return organisasjonTilgangRepository.existsByOrganisasjonNummer(orgnummer) + .flatMap(exists -> isTrue(exists) ? + organisasjonTilgangRepository.findByOrganisasjonNummer(orgnummer) + .flatMap(organisasjon -> { + organisasjon.setMiljoe(miljoe); + return organisasjonTilgangRepository.save(organisasjon); + }) : + organisasjonTilgangRepository.save(OrganisasjonTilgang.builder() + .organisasjonNummer(orgnummer) + .miljoe(miljoe) + .build())); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/MiljoerOversiktService.java b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/MiljoerOversiktService.java new file mode 100644 index 00000000000..3774737e83f --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/java/no/nav/testnav/altinn3tilgangservice/service/MiljoerOversiktService.java @@ -0,0 +1,61 @@ +package no.nav.testnav.altinn3tilgangservice.service; + +import lombok.RequiredArgsConstructor; +import no.nav.testnav.altinn3tilgangservice.consumer.altinn.AltinnConsumer; +import no.nav.testnav.altinn3tilgangservice.database.entity.OrganisasjonTilgang; +import no.nav.testnav.altinn3tilgangservice.database.repository.OrganisasjonTilgangRepository; +import org.springframework.http.HttpStatus; +import org.springframework.stereotype.Service; +import org.springframework.web.server.ResponseStatusException; +import reactor.core.publisher.Mono; + +import static org.apache.commons.lang3.BooleanUtils.isTrue; + +@Service +@RequiredArgsConstructor +public class MiljoerOversiktService { + + private final AltinnConsumer altinnConsumer; + private final OrganisasjonTilgangRepository organisasjonTilgangRepository; + + public Mono getMiljoe(String orgnummer) { + + return altinnConsumer.getOrganisasjoner() + .collectList() + .flatMap(bedrifter -> { + + if (bedrifter.stream().anyMatch(bedrift -> + orgnummer.equals(bedrift.getOrganisasjonsnummer()))) { + + return organisasjonTilgangRepository.existsByOrganisasjonNummer(orgnummer) + .flatMap(exists -> isTrue(exists) ? + organisasjonTilgangRepository.findByOrganisasjonNummer(orgnummer) : + Mono.just(OrganisasjonTilgang.builder() + .organisasjonNummer(orgnummer) + .miljoe("q1") + .build())); + } else { + return throwError(orgnummer); + } + }); + } + + public Mono updateMiljoe(String orgnummer, String miljoe) { + + return organisasjonTilgangRepository.existsByOrganisasjonNummer(orgnummer) + .flatMap(exists -> isTrue(exists) ? + organisasjonTilgangRepository.findByOrganisasjonNummer(orgnummer) + .flatMap(organisasjon -> { + organisasjon.setMiljoe(miljoe); + return organisasjonTilgangRepository.save(organisasjon); + }) : + + throwError(orgnummer)); + } + + private static Mono throwError(String orgnummer) { + + throw new ResponseStatusException(HttpStatus.NOT_FOUND, + "Organisasjonsnummer %s ble ikke funnet".formatted(orgnummer)); + } +} diff --git a/apps/altinn3-tilgang-service/src/main/resources/application-dev.yml b/apps/altinn3-tilgang-service/src/main/resources/application-dev.yml new file mode 100644 index 00000000000..0335878de67 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/resources/application-dev.yml @@ -0,0 +1,17 @@ +ALTINN_URL: https://platform.tt02.altinn.no + +spring: + flyway: + locations: classpath:db/migration + url: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_JDBC_URL} + user: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_USERNAME} + password: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PASSWORD} + r2dbc: + url: r2dbc:postgresql://${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_HOST}:${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PORT}/${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_DATABASE} + username: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_USERNAME} + password: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PASSWORD} + properties: + sslCert: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLCERT} + sslKey: /tmp/pk8.pem # See Dockerfile and 99-dolly-convert-to-pk8.sh. + sslMode: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLMODE} + sslRootCert: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLROOTCERT} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/resources/application-local.yml b/apps/altinn3-tilgang-service/src/main/resources/application-local.yml new file mode 100644 index 00000000000..b53b18bab13 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/resources/application-local.yml @@ -0,0 +1,29 @@ +ALTINN_URL: https://platform.tt02.altinn.no +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} +MASKINPORTEN_CLIENT_ID: ef2960de-7fa6-4396-80a5-2eca00e4af28 +MASKINPORTEN_CLIENT_JWK: dummy +MASKINPORTEN_SCOPES: altinn:resourceregistry/accesslist.read altinn:resourceregistry/accesslist.write altinn:accessmanagement/authorizedparties.resourceowner +MASKINPORTEN_WELL_KNOWN_URL: https://test.maskinporten.no/.well-known/oauth-authorization-server +TOKEN_X_ISSUER: dummy + +spring: + cache: + type: none + cloud: + gcp: + secretmanager: + project-id: dolly-dev-ff83 + config: + import: "sm://" + flyway: + enabled: true + locations: classpath:db/migration + baseline-on-migrate: true + url: jdbc:postgresql://localhost:5432/testnav-altinn3-tilgang-local + user: testnav-altinn3-tilgang-local + password: ${sm://testnav-altinn3-tilgang-local} + r2dbc: + url: r2dbc:postgresql://localhost:5432/testnav-altinn3-tilgang-local + username: testnav-altinn3-tilgang-local + password: ${sm://testnav-altinn3-tilgang-local} \ No newline at end of file diff --git a/apps/altinn3-tilgang-service/src/main/resources/application-prod.yml b/apps/altinn3-tilgang-service/src/main/resources/application-prod.yml new file mode 100644 index 00000000000..00fc0d3389d --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/resources/application-prod.yml @@ -0,0 +1,17 @@ +ALTINN_URL: https://platform.altinn.no + +spring: + flyway: + locations: classpath:db/migration + url: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_JDBC_URL} + user: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_USERNAME} + password: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PASSWORD} + r2dbc: + url: r2dbc:postgresql://${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_HOST}:${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PORT}/${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_DATABASE} + username: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_USERNAME} + password: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_PASSWORD} + properties: + sslCert: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLCERT} + sslKey: /tmp/pk8.pem # See Dockerfile and 99-dolly-convert-to-pk8.sh. + sslMode: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLMODE} + sslRootCert: ${NAIS_DATABASE_TESTNAV_ALTINN3_TILGANG_TESTNAV_ALTINN3_TILGANG_SSLROOTCERT} \ No newline at end of file diff --git a/apps/person-organisasjon-tilgang-service/src/main/resources/application.yml b/apps/altinn3-tilgang-service/src/main/resources/application.yml similarity index 69% rename from apps/person-organisasjon-tilgang-service/src/main/resources/application.yml rename to apps/altinn3-tilgang-service/src/main/resources/application.yml index 1da5b3b1184..654d076c3a4 100644 --- a/apps/person-organisasjon-tilgang-service/src/main/resources/application.yml +++ b/apps/altinn3-tilgang-service/src/main/resources/application.yml @@ -3,15 +3,15 @@ AAD_ISSUER_URI: https://login.microsoftonline.com/62366534-1ec3-4962-8869-9b5535 spring: application: version: application.version.todo - name: testnav-person-organisasjon-tilgang-service - description: Tjeneste for å hente tilganger for personer + name: testnav-altinn3-tilgang-service + description: Tjeneste for å hente og sette tilganger for orgnisasjoner security: oauth2: resourceserver: aad: issuer-uri: ${AAD_ISSUER_URI}/v2.0 jwk-set-uri: ${AAD_ISSUER_URI}/discovery/v2.0/keys - accepted-audience: ${AZURE_APP_CLIENT_ID}, api:// ${AZURE_APP_CLIENT_ID} + accepted-audience: ${AZURE_APP_CLIENT_ID}, api://${AZURE_APP_CLIENT_ID} tokenx: issuer-uri: ${TOKEN_X_ISSUER} jwk-set-uri: ${TOKEN_X_JWKS_URI} @@ -28,22 +28,22 @@ springdoc: altinn: api: url: ${ALTINN_URL} - key: ${ALTINN_API_KEY} - service: - code: 5748 - edition: 1 + resource: + owner: nav + identifier: godkjente-dolly-tilganger management: endpoints: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: @@ -53,4 +53,5 @@ server: encoding: charset: UTF-8 error: - include-message: always \ No newline at end of file + include-message: always + include-stacktrace: never \ No newline at end of file diff --git a/apps/organisasjon-tilgang-service/src/main/resources/db/migration/V1.0.0__CreateTables.sql b/apps/altinn3-tilgang-service/src/main/resources/db/migration/V1.0.0__CreateTables.sql similarity index 100% rename from apps/organisasjon-tilgang-service/src/main/resources/db/migration/V1.0.0__CreateTables.sql rename to apps/altinn3-tilgang-service/src/main/resources/db/migration/V1.0.0__CreateTables.sql diff --git a/apps/altinn3-tilgang-service/src/main/resources/logback-spring.xml b/apps/altinn3-tilgang-service/src/main/resources/logback-spring.xml new file mode 100644 index 00000000000..43e833f00b6 --- /dev/null +++ b/apps/altinn3-tilgang-service/src/main/resources/logback-spring.xml @@ -0,0 +1,32 @@ + + + + + + -1 + true + - + + + + + + + + + + + + %d{HH:mm:ss.SSS} | %5p | %logger{25} | %m%n + + utf8 + + + + + + + + + + \ No newline at end of file diff --git a/apps/person-organisasjon-tilgang-service/src/test/java/no/nav/testnav/apps/persontilgangservice/ApplicationContextTest.java b/apps/altinn3-tilgang-service/src/test/java/no/nav/testnav/altinn3tilgangservice/ApplicationContextTest.java similarity index 72% rename from apps/person-organisasjon-tilgang-service/src/test/java/no/nav/testnav/apps/persontilgangservice/ApplicationContextTest.java rename to apps/altinn3-tilgang-service/src/test/java/no/nav/testnav/altinn3tilgangservice/ApplicationContextTest.java index 384f37ebae5..3fed84b2557 100644 --- a/apps/person-organisasjon-tilgang-service/src/test/java/no/nav/testnav/apps/persontilgangservice/ApplicationContextTest.java +++ b/apps/altinn3-tilgang-service/src/test/java/no/nav/testnav/altinn3tilgangservice/ApplicationContextTest.java @@ -1,5 +1,6 @@ -package no.nav.testnav.apps.persontilgangservice; +package no.nav.testnav.altinn3tilgangservice; +import com.google.cloud.secretmanager.v1.SecretManagerServiceClient; import org.junit.jupiter.api.Test; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.mock.mockito.MockBean; @@ -13,6 +14,9 @@ class ApplicationContextTest { @MockBean public ReactiveJwtDecoder jwtDecoder; + @MockBean + public SecretManagerServiceClient secretManagerClient; + @Test @SuppressWarnings("java:S2699") void load_app_context() { diff --git a/apps/organisasjon-tilgang-service/src/test/resources/application-test.yml b/apps/altinn3-tilgang-service/src/test/resources/application-test.yml similarity index 67% rename from apps/organisasjon-tilgang-service/src/test/resources/application-test.yml rename to apps/altinn3-tilgang-service/src/test/resources/application-test.yml index 0468cb34222..dfbee67495e 100644 --- a/apps/organisasjon-tilgang-service/src/test/resources/application-test.yml +++ b/apps/altinn3-tilgang-service/src/test/resources/application-test.yml @@ -4,10 +4,4 @@ MASKINPORTEN_CLIENT_ID: dummy MASKINPORTEN_CLIENT_JWK: dummy MASKINPORTEN_SCOPES: dummy MASKINPORTEN_WELL_KNOWN_URL: http://localhost:8080 -TOKEN_X_ISSUER: dummy - -spring: - cloud: - gcp: - secretmanager: - enabled: false \ No newline at end of file +TOKEN_X_ISSUER: dummy \ No newline at end of file diff --git a/apps/amelding-service/src/main/resources/application-dev.yml b/apps/amelding-service/src/main/resources/application-local.yml similarity index 50% rename from apps/amelding-service/src/main/resources/application-dev.yml rename to apps/amelding-service/src/main/resources/application-local.yml index e222fbad757..fd9e94057e6 100644 --- a/apps/amelding-service/src/main/resources/application-dev.yml +++ b/apps/amelding-service/src/main/resources/application-local.yml @@ -1,11 +1,9 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + spring: config: import: "sm://" - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} consumers: oppsummeringsdokument-service: diff --git a/apps/amelding-service/src/main/resources/application.yml b/apps/amelding-service/src/main/resources/application.yml index e90182fd21e..404bec3cc25 100644 --- a/apps/amelding-service/src/main/resources/application.yml +++ b/apps/amelding-service/src/main/resources/application.yml @@ -30,12 +30,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/amelding-service/src/main/resources/logback-spring.xml b/apps/amelding-service/src/main/resources/logback-spring.xml index f874dcc44c1..ae836bf1b11 100644 --- a/apps/amelding-service/src/main/resources/logback-spring.xml +++ b/apps/amelding-service/src/main/resources/logback-spring.xml @@ -22,7 +22,7 @@ - + diff --git a/apps/app-tilgang-analyse-service/src/main/resources/application-local.yml b/apps/app-tilgang-analyse-service/src/main/resources/application-local.yml index 6e81acdc788..fa988806f6d 100644 --- a/apps/app-tilgang-analyse-service/src/main/resources/application-local.yml +++ b/apps/app-tilgang-analyse-service/src/main/resources/application-local.yml @@ -1,3 +1,6 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + spring: config: import: "sm://" @@ -5,9 +8,3 @@ spring: url: jdbc:h2:mem:testdb username: sa password: - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} - diff --git a/apps/app-tilgang-analyse-service/src/main/resources/application-localdb.yml b/apps/app-tilgang-analyse-service/src/main/resources/application-localdb.yml index baf2a030a5e..191fc5b367f 100644 --- a/apps/app-tilgang-analyse-service/src/main/resources/application-localdb.yml +++ b/apps/app-tilgang-analyse-service/src/main/resources/application-localdb.yml @@ -1,3 +1,6 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + spring: config: import: "sm://" @@ -9,8 +12,3 @@ spring: url: r2dbc:postgresql://localhost:3306/testnav-app-tilgang-analyse-service-db username: testnav-app-tilgang-analyse-service password: ${DB_PASSWORD} - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} \ No newline at end of file diff --git a/apps/app-tilgang-analyse-service/src/main/resources/application.yml b/apps/app-tilgang-analyse-service/src/main/resources/application.yml index ebf58a884c3..829bfd78a09 100644 --- a/apps/app-tilgang-analyse-service/src/main/resources/application.yml +++ b/apps/app-tilgang-analyse-service/src/main/resources/application.yml @@ -32,12 +32,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/arbeidsforhold-service/src/main/resources/application-dev.yml b/apps/arbeidsforhold-service/src/main/resources/application-dev.yml deleted file mode 100644 index bea43da510a..00000000000 --- a/apps/arbeidsforhold-service/src/main/resources/application-dev.yml +++ /dev/null @@ -1,8 +0,0 @@ -spring: - config: - import: "sm://" - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} \ No newline at end of file diff --git a/proxies/aareg-synt-services-proxy/src/main/resources/application-dev.yml b/apps/arbeidsforhold-service/src/main/resources/application-local.yml similarity index 64% rename from proxies/aareg-synt-services-proxy/src/main/resources/application-dev.yml rename to apps/arbeidsforhold-service/src/main/resources/application-local.yml index 0f24d85a8e2..e36d70419c6 100644 --- a/proxies/aareg-synt-services-proxy/src/main/resources/application-dev.yml +++ b/apps/arbeidsforhold-service/src/main/resources/application-local.yml @@ -1,10 +1,7 @@ -TOKEN_X_ISSUER: dummy +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} spring: - cloud: - gcp: - secretmanager: - enabled: true config: import: "sm://" security: diff --git a/apps/arbeidsforhold-service/src/main/resources/application.yml b/apps/arbeidsforhold-service/src/main/resources/application.yml index 9e816896986..f15c64ba7ef 100644 --- a/apps/arbeidsforhold-service/src/main/resources/application.yml +++ b/apps/arbeidsforhold-service/src/main/resources/application.yml @@ -33,12 +33,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/arbeidsforhold-service/src/main/resources/logback-spring.xml b/apps/arbeidsforhold-service/src/main/resources/logback-spring.xml index 6e928942d90..c6f5a93ab27 100644 --- a/apps/arbeidsforhold-service/src/main/resources/logback-spring.xml +++ b/apps/arbeidsforhold-service/src/main/resources/logback-spring.xml @@ -22,7 +22,7 @@ - + diff --git a/apps/batch-bestilling-service/src/main/resources/application-dev.yml b/apps/batch-bestilling-service/src/main/resources/application-dev.yml deleted file mode 100644 index c3bbec56cd7..00000000000 --- a/apps/batch-bestilling-service/src/main/resources/application-dev.yml +++ /dev/null @@ -1,12 +0,0 @@ -spring: - config: - import: "sm://" - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} - -consumers: - dolly-backend: - url: https://dolly-backend.intern.dev.nav.no \ No newline at end of file diff --git a/apps/batch-bestilling-service/src/main/resources/application-local.yml b/apps/batch-bestilling-service/src/main/resources/application-local.yml new file mode 100644 index 00000000000..ee40c021aad --- /dev/null +++ b/apps/batch-bestilling-service/src/main/resources/application-local.yml @@ -0,0 +1,10 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + +spring: + config: + import: "sm://" + +consumers: + dolly-backend: + url: https://dolly-backend.intern.dev.nav.no \ No newline at end of file diff --git a/apps/batch-bestilling-service/src/main/resources/application.yml b/apps/batch-bestilling-service/src/main/resources/application.yml index 5e056d09e77..0a85377386b 100644 --- a/apps/batch-bestilling-service/src/main/resources/application.yml +++ b/apps/batch-bestilling-service/src/main/resources/application.yml @@ -28,12 +28,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/batch-bestilling-service/src/main/resources/logback-spring.xml b/apps/batch-bestilling-service/src/main/resources/logback-spring.xml index 7309420d4fd..7573f10edb7 100644 --- a/apps/batch-bestilling-service/src/main/resources/logback-spring.xml +++ b/apps/batch-bestilling-service/src/main/resources/logback-spring.xml @@ -22,7 +22,7 @@ - + diff --git a/apps/brreg-stub/docker-compose.sql b/apps/brreg-stub/docker-compose.sql new file mode 100644 index 00000000000..a1386159aed --- /dev/null +++ b/apps/brreg-stub/docker-compose.sql @@ -0,0 +1,2 @@ +SELECT 'CREATE DATABASE "testnav-brregstub"' +WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'testnav-brregstub')\gexec \ No newline at end of file diff --git a/apps/brreg-stub/docker-compose.yml b/apps/brreg-stub/docker-compose.yml new file mode 100644 index 00000000000..f129389717a --- /dev/null +++ b/apps/brreg-stub/docker-compose.yml @@ -0,0 +1,11 @@ +services: + + postgresql: + image: postgres + network_mode: host + shm_size: 128mb + environment: + POSTGRES_PASSWORD: "" + POSTGRES_HOST_AUTH_METHOD: trust + volumes: + - ./docker-compose.sql:/docker-entrypoint-initdb.d/init.sql \ No newline at end of file diff --git a/apps/brreg-stub/src/main/resources/application-local.yaml b/apps/brreg-stub/src/main/resources/application-local.yml similarity index 100% rename from apps/brreg-stub/src/main/resources/application-local.yaml rename to apps/brreg-stub/src/main/resources/application-local.yml diff --git a/apps/brreg-stub/src/main/resources/application-prod.yaml b/apps/brreg-stub/src/main/resources/application-prod.yml similarity index 100% rename from apps/brreg-stub/src/main/resources/application-prod.yaml rename to apps/brreg-stub/src/main/resources/application-prod.yml diff --git a/apps/brreg-stub/src/main/resources/application.yaml b/apps/brreg-stub/src/main/resources/application.yml similarity index 80% rename from apps/brreg-stub/src/main/resources/application.yaml rename to apps/brreg-stub/src/main/resources/application.yml index de4ff173f11..0667df0b3ea 100644 --- a/apps/brreg-stub/src/main/resources/application.yaml +++ b/apps/brreg-stub/src/main/resources/application.yml @@ -12,12 +12,13 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/bruker-service/config.test.yml b/apps/bruker-service/config.test.yml index 713f06a5a78..48e92b075b5 100644 --- a/apps/bruker-service/config.test.yml +++ b/apps/bruker-service/config.test.yml @@ -22,12 +22,11 @@ spec: rules: - application: dolly-frontend-dev - application: dolly-frontend-dev-unstable - - application: dolly-idporten - application: team-dolly-lokal-app - application: testnav-oversikt-frontend outbound: rules: - - application: testnav-person-organisasjon-tilgang-service-dev + - application: testnav-altinn3-tilgang-service liveness: path: /internal/isAlive initialDelay: 4 diff --git a/apps/bruker-service/config.yml b/apps/bruker-service/config.yml index 58cdf65a2d3..4274825e08f 100644 --- a/apps/bruker-service/config.yml +++ b/apps/bruker-service/config.yml @@ -21,14 +21,11 @@ spec: inbound: rules: - application: dolly-frontend - cluster: dev-gcp - application: dolly-idporten - cluster: dev-gcp - application: testnav-oversikt-frontend - cluster: dev-gcp outbound: rules: - - application: testnav-person-organisasjon-tilgang-service + - application: testnav-altinn3-tilgang-proxy liveness: path: /internal/isAlive initialDelay: 4 diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/Consumers.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/Consumers.java index 51662bd8e36..e3473bbb710 100644 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/Consumers.java +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/Consumers.java @@ -9,14 +9,6 @@ import static lombok.AccessLevel.PACKAGE; -/** - * Samler alle placeholders for ulike {@code consumers.*}-konfigurasjon her, dvs. subklasser av {@code ServerProperties}. - *

- * Husk at Spring Boot bruker relaxed binding - * mellom configuration properties og field names. - * - * @see ServerProperties - */ @Configuration @ConfigurationProperties(prefix = "consumers") @NoArgsConstructor(access = PACKAGE) @@ -24,6 +16,6 @@ @Setter(PACKAGE) public class Consumers { - private ServerProperties testnavPersonOrganisasjonTilgangService; + private ServerProperties testnavAltinn3TilgangService; } diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/OpenApiConfig.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/OpenApiConfig.java index cd656377c3d..66a6a6a178f 100644 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/OpenApiConfig.java +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/config/OpenApiConfig.java @@ -13,10 +13,14 @@ import java.util.Arrays; import no.nav.testnav.libs.reactivecore.config.ApplicationProperties; +import org.springframework.web.server.ServerWebExchange; +import org.springframework.web.server.WebFilter; +import org.springframework.web.server.WebFilterChain; +import reactor.core.publisher.Mono; @Configuration -public class OpenApiConfig { +public class OpenApiConfig implements WebFilter { @Bean public OpenAPI openApi(ApplicationProperties applicationProperties) { @@ -46,4 +50,17 @@ public OpenAPI openApi(ApplicationProperties applicationProperties) { ) ); } + + @Override + public Mono filter(ServerWebExchange exchange, WebFilterChain chain) { + if (exchange.getRequest().getURI().getPath().equals("/swagger")) { + return chain + .filter(exchange.mutate() + .request(exchange.getRequest() + .mutate().path("/swagger-ui.html").build()) + .build()); + } + + return chain.filter(exchange); + } } \ No newline at end of file diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/AltinnTilgangServiceConsumer.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/AltinnTilgangServiceConsumer.java new file mode 100644 index 00000000000..986de3c3939 --- /dev/null +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/AltinnTilgangServiceConsumer.java @@ -0,0 +1,44 @@ +package no.nav.testnav.apps.brukerservice.consumer; + +import no.nav.testnav.apps.brukerservice.config.Consumers; +import no.nav.testnav.apps.brukerservice.consumer.command.GetBrukertilgangCommand; +import no.nav.testnav.apps.brukerservice.domain.Organisasjon; +import no.nav.testnav.libs.reactivesecurity.action.GetAuthenticatedUserId; +import no.nav.testnav.libs.reactivesecurity.exchange.TokenExchange; +import no.nav.testnav.libs.securitycore.domain.ServerProperties; +import org.springframework.stereotype.Component; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Mono; + +@Component +public class AltinnTilgangServiceConsumer { + + private final WebClient webClient; + private final ServerProperties serverProperties; + private final TokenExchange tokenExchange; + private final GetAuthenticatedUserId getAuthenticatedUserId; + + public AltinnTilgangServiceConsumer( + Consumers consumers, + TokenExchange tokenExchange, + WebClient.Builder webClientBuilder, + GetAuthenticatedUserId getAuthenticatedUserId) { + + serverProperties = consumers.getTestnavAltinn3TilgangService(); + this.tokenExchange = tokenExchange; + this.webClient = webClientBuilder + .baseUrl(serverProperties.getUrl()) + .build(); + this.getAuthenticatedUserId = getAuthenticatedUserId; + } + + public Mono getOrganisasjon(String orgnummer) { + + return Mono.from(getAuthenticatedUserId.call() + .flatMapMany(userId -> tokenExchange.exchange(serverProperties) + .flatMapMany(accessToken -> + new GetBrukertilgangCommand(webClient, userId, accessToken.getTokenValue()).call())) + .filter(org -> org.getOrganisasjonsnummer().equals(orgnummer)) + .map(Organisasjon::new)); + } +} diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/PersonOrganisasjonTilgangConsumer.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/PersonOrganisasjonTilgangConsumer.java deleted file mode 100644 index 0a947be0817..00000000000 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/PersonOrganisasjonTilgangConsumer.java +++ /dev/null @@ -1,51 +0,0 @@ -package no.nav.testnav.apps.brukerservice.consumer; - -import com.fasterxml.jackson.databind.ObjectMapper; -import no.nav.testnav.apps.brukerservice.config.Consumers; -import no.nav.testnav.apps.brukerservice.consumer.command.GetOrganisasjonCommand; -import no.nav.testnav.apps.brukerservice.domain.Organisasjon; -import no.nav.testnav.libs.reactivesecurity.exchange.TokenExchange; -import no.nav.testnav.libs.securitycore.domain.ServerProperties; -import org.springframework.http.MediaType; -import org.springframework.http.codec.json.Jackson2JsonDecoder; -import org.springframework.http.codec.json.Jackson2JsonEncoder; -import org.springframework.stereotype.Component; -import org.springframework.web.reactive.function.client.ExchangeStrategies; -import org.springframework.web.reactive.function.client.WebClient; -import reactor.core.publisher.Mono; - -@Component -public class PersonOrganisasjonTilgangConsumer { - private final WebClient webClient; - private final ServerProperties serverProperties; - private final TokenExchange tokenExchange; - - public PersonOrganisasjonTilgangConsumer( - Consumers consumers, - TokenExchange tokenExchange, - ObjectMapper objectMapper, - WebClient.Builder webClientBuilder) { - serverProperties = consumers.getTestnavPersonOrganisasjonTilgangService(); - this.tokenExchange = tokenExchange; - ExchangeStrategies jacksonStrategy = ExchangeStrategies - .builder() - .codecs( - config -> { - config.defaultCodecs() - .jackson2JsonEncoder(new Jackson2JsonEncoder(objectMapper, MediaType.APPLICATION_JSON)); - config.defaultCodecs() - .jackson2JsonDecoder(new Jackson2JsonDecoder(objectMapper, MediaType.APPLICATION_JSON)); - }) - .build(); - this.webClient = webClientBuilder - .exchangeStrategies(jacksonStrategy) - .baseUrl(serverProperties.getUrl()) - .build(); - } - - public Mono getOrganisasjon(String orgnummer) { - return tokenExchange.exchange(serverProperties) - .flatMap(accessToken -> new GetOrganisasjonCommand(webClient, orgnummer, accessToken.getTokenValue()).call()) - .map(Organisasjon::new); - } -} diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetOrganisasjonCommand.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetBrukertilgangCommand.java similarity index 53% rename from apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetOrganisasjonCommand.java rename to apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetBrukertilgangCommand.java index 2a766f152c8..f3e949dd4e4 100644 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetOrganisasjonCommand.java +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/command/GetBrukertilgangCommand.java @@ -1,31 +1,35 @@ package no.nav.testnav.apps.brukerservice.consumer.command; import lombok.RequiredArgsConstructor; -import no.nav.testnav.apps.brukerservice.consumer.dto.OrganisasjonDTO; +import no.nav.testnav.apps.brukerservice.consumer.dto.AltinnBrukerRequest; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; import org.springframework.http.HttpHeaders; import org.springframework.web.reactive.function.client.WebClient; import org.springframework.web.reactive.function.client.WebClientResponseException; +import reactor.core.publisher.Flux; import reactor.core.publisher.Mono; import java.util.concurrent.Callable; @RequiredArgsConstructor -public class GetOrganisasjonCommand implements Callable> { +public class GetBrukertilgangCommand implements Callable> { private final WebClient webClient; - private final String organisasjonsnummer; + private final String ident; private final String token; @Override - public Mono call() { - return webClient.get() - .uri(builder -> builder.path("/api/v1/person/organisasjoner/{organisasjonsnummer}").build(organisasjonsnummer)) + public Flux call() { + return webClient.post() + .uri(builder -> builder.path("/api/v1/brukertilgang").build()) .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .bodyValue(new AltinnBrukerRequest(ident)) .retrieve() - .bodyToMono(OrganisasjonDTO.class) + .bodyToFlux(OrganisasjonDTO.class) + .doOnError(WebClientFilter::logErrorMessage) .onErrorResume( throwable -> throwable instanceof WebClientResponseException.NotFound, throwable -> Mono.empty() ); } -} - +} \ No newline at end of file diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/AltinnBrukerRequest.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/AltinnBrukerRequest.java new file mode 100644 index 00000000000..f70ff4216c1 --- /dev/null +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/AltinnBrukerRequest.java @@ -0,0 +1,11 @@ +package no.nav.testnav.apps.brukerservice.consumer.dto; + +import lombok.AllArgsConstructor; +import lombok.Data; + +@Data +@AllArgsConstructor +public class AltinnBrukerRequest { + + private String ident; +} diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/OrganisasjonDTO.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/OrganisasjonDTO.java deleted file mode 100644 index 425b1c3bf5c..00000000000 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/consumer/dto/OrganisasjonDTO.java +++ /dev/null @@ -1,4 +0,0 @@ -package no.nav.testnav.apps.brukerservice.consumer.dto; - -public record OrganisasjonDTO(String navn, String organisasjonsnummer, String organisasjonsfrom) { -} diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/domain/Organisasjon.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/domain/Organisasjon.java index 77904f9ed88..c292fbc5a20 100644 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/domain/Organisasjon.java +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/domain/Organisasjon.java @@ -1,27 +1,23 @@ package no.nav.testnav.apps.brukerservice.domain; -import no.nav.testnav.apps.brukerservice.consumer.dto.OrganisasjonDTO; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; -public class Organisasjon { - private final String navn; - private final String organisasjonsnummer; - private final String organisasjonsform; - - public Organisasjon(OrganisasjonDTO dto) { - this.navn = dto.navn(); - this.organisasjonsnummer = dto.organisasjonsnummer(); - this.organisasjonsform = dto.organisasjonsfrom(); - } +@Data +@NoArgsConstructor +@AllArgsConstructor - public String getNavn() { - return navn; - } +public class Organisasjon { - public String getOrganisasjonsnummer() { - return organisasjonsnummer; - } + private String navn; + private String organisasjonsnummer; + private String organisasjonsform; - public String getOrganisasjonsform() { - return organisasjonsform; + public Organisasjon(OrganisasjonDTO dto) { + this.navn = dto.getNavn(); + this.organisasjonsnummer = dto.getOrganisasjonsnummer(); + this.organisasjonsform = dto.getOrganisasjonsform(); } } diff --git a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/service/ValidateService.java b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/service/ValidateService.java index 1ada4106bb8..4f39d4eb895 100644 --- a/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/service/ValidateService.java +++ b/apps/bruker-service/src/main/java/no/nav/testnav/apps/brukerservice/service/ValidateService.java @@ -1,7 +1,7 @@ package no.nav.testnav.apps.brukerservice.service; import lombok.RequiredArgsConstructor; -import no.nav.testnav.apps.brukerservice.consumer.PersonOrganisasjonTilgangConsumer; +import no.nav.testnav.apps.brukerservice.consumer.AltinnTilgangServiceConsumer; import no.nav.testnav.apps.brukerservice.exception.UserHasNoAccessToOrgnisasjonException; import org.springframework.stereotype.Service; import reactor.core.publisher.Mono; @@ -9,10 +9,11 @@ @Service @RequiredArgsConstructor public class ValidateService { - private final PersonOrganisasjonTilgangConsumer client; + + private final AltinnTilgangServiceConsumer altinnTilgangServiceConsumer; public Mono validateOrganiasjonsnummerAccess(String organisasjonsnummer) { - return client + return altinnTilgangServiceConsumer .getOrganisasjon(organisasjonsnummer) .doOnNext(organisasjon -> { if (!organisasjon.getOrganisasjonsnummer().equals(organisasjonsnummer)) { diff --git a/apps/bruker-service/src/main/resources/application-dev.yml b/apps/bruker-service/src/main/resources/application-dev.yml index 9236e224169..35c9fa83539 100644 --- a/apps/bruker-service/src/main/resources/application-dev.yml +++ b/apps/bruker-service/src/main/resources/application-dev.yml @@ -1,6 +1,13 @@ spring: application: name: testnav-bruker-service-dev + security: + oauth2: + resourceserver: + tokenx: + issuer-uri: ${TOKEN_X_ISSUER} + jwk-set-uri: ${TOKEN_X_JWKS_URI} + accepted-audience: ${TOKEN_X_CLIENT_ID} r2dbc: url: r2dbc:postgresql://${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_DEV_TESTNAV_BRUKER_SERVICE_DEV_DB_HOST}:${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_DEV_TESTNAV_BRUKER_SERVICE_DEV_DB_PORT}/${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_DEV_TESTNAV_BRUKER_SERVICE_DEV_DB_DATABASE} username: ${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_DEV_TESTNAV_BRUKER_SERVICE_DEV_DB_USERNAME} @@ -12,6 +19,6 @@ spring: consumers: - testnav-person-organisasjon-tilgang-service: - url: http://testnav-person-organisasjon-tilgang-service-dev.dolly.svc.cluster.local - name: testnav-person-organisasjon-tilgang-service-dev \ No newline at end of file + testnav-altinn3-tilgang-service: + url: http://testnav-altinn3-tilgang-service.dolly.svc.cluster.local + name: testnav-altinn3-tilgang-service \ No newline at end of file diff --git a/apps/bruker-service/src/main/resources/application-local.yml b/apps/bruker-service/src/main/resources/application-local.yml index e5668233f25..9c14722dfc9 100644 --- a/apps/bruker-service/src/main/resources/application-local.yml +++ b/apps/bruker-service/src/main/resources/application-local.yml @@ -1,17 +1,22 @@ + +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} CRYPTOGRAPHY_SECRET: DUMMY SUPER SECRET CRYPTOGRAPHY KEY THAT IS NOT SECURE JWT_SECRET: DUMMY SUPER SECRET JWT KEY THAT IS NOT SECURE TOKEN_X_CLIENT_ID: dev-gcp:dolly:testnav-bruker-service-dev -TOKENDINGS_URL: ${TOKEN_X_ISSUER} + spring: application: name: testnav-bruker-service-dev + config: + import: "sm://" flyway: url: jdbc:h2:mem:testdb username: sa password: consumers: - testnav-person-organisasjon-tilgang-service: - url: https://testnav-person-organisasjon-tilgang-service-dev.intern.dev.nav.no - name: testnav-person-organisasjon-tilgang-service-dev \ No newline at end of file + testnav-altinn3-tilgang-service: + url: https://testnav-altinn3-tilgang-service.intern.dev.nav.no + name: testnav-altinn3-tilgang-service diff --git a/apps/bruker-service/src/main/resources/application-prod.yml b/apps/bruker-service/src/main/resources/application-prod.yml index 455275bd171..e6f872195b9 100644 --- a/apps/bruker-service/src/main/resources/application-prod.yml +++ b/apps/bruker-service/src/main/resources/application-prod.yml @@ -1,4 +1,11 @@ spring: + security: + oauth2: + resourceserver: + tokenx: + issuer-uri: ${TOKEN_X_ISSUER} + jwk-set-uri: ${TOKEN_X_JWKS_URI} + accepted-audience: ${TOKEN_X_CLIENT_ID} r2dbc: url: r2dbc:postgresql://${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_TESTNAV_BRUKER_SERVICE_DB_HOST}:${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_TESTNAV_BRUKER_SERVICE_DB_PORT}/${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_TESTNAV_BRUKER_SERVICE_DB_DATABASE} username: ${NAIS_DATABASE_TESTNAV_BRUKER_SERVICE_TESTNAV_BRUKER_SERVICE_DB_USERNAME} diff --git a/apps/bruker-service/src/main/resources/application-virtual.yml b/apps/bruker-service/src/main/resources/application-virtual.yml index b45d934be91..0de519e330b 100644 --- a/apps/bruker-service/src/main/resources/application-virtual.yml +++ b/apps/bruker-service/src/main/resources/application-virtual.yml @@ -23,11 +23,11 @@ spring: password: compose-postgres consumers: - testnav-person-organisasjon-tilgang-service: - url: http://testnav-person-organisasjon-tilgang-service:8080 + testnav-altinn3-tilgang-service: + url: http://testnav-altinn3-tilgang-service:8080 cluster: dev-gcp namespace: dolly - name: testnav-person-organisasjon-tilgang-service + name: testnav-altinn3-tilgang-service TOKEN_X_WELL_KNOWN_URL: http://tokendings:8080/.well-known/oauth-authorization-server TOKEN_X_CLIENT_ID: dev-gcp:dolly:testnav-bruker-service diff --git a/apps/bruker-service/src/main/resources/application.yml b/apps/bruker-service/src/main/resources/application.yml index 9f515a648c1..c08c085bc98 100644 --- a/apps/bruker-service/src/main/resources/application.yml +++ b/apps/bruker-service/src/main/resources/application.yml @@ -1,3 +1,5 @@ +AAD_ISSUER_URI: https://login.microsoftonline.com/62366534-1ec3-4962-8869-9b5535279d0b + spring: application: version: application.version.todo @@ -6,10 +8,10 @@ spring: security: oauth2: resourceserver: - tokenx: - issuer-uri: ${TOKEN_X_ISSUER} - jwk-set-uri: ${TOKEN_X_JWKS_URI} - accepted-audience: ${TOKEN_X_CLIENT_ID} + aad: + issuer-uri: ${AAD_ISSUER_URI}/v2.0 + jwk-set-uri: ${AAD_ISSUER_URI}/discovery/v2.0/keys + accepted-audience: ${AZURE_APP_CLIENT_ID}, api://${AZURE_APP_CLIENT_ID} jackson: serialization: write_dates_as_timestamps: @@ -20,23 +22,24 @@ springdoc: url: /v3/api-docs consumers: - testnav-person-organisasjon-tilgang-service: - url: http://testnav-person-organisasjon-tilgang-service.dolly.svc.cluster.local + testnav-altinn3-tilgang-service: + url: http://testnav-altinn3-tilgang-proxy.dolly.svc.cluster.local cluster: dev-gcp namespace: dolly - name: testnav-person-organisasjon-tilgang-service + name: testnav-altinn3-tilgang-proxy management: endpoints: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: - prometheus.enabled: true - heapdump.enabled: true + prometheus: + enabled: true prometheus: metrics: export: diff --git a/apps/bruker-service/src/test/resources/application-test.yml b/apps/bruker-service/src/test/resources/application-test.yml index 5ac5d4b6204..9f9350113ba 100644 --- a/apps/bruker-service/src/test/resources/application-test.yml +++ b/apps/bruker-service/src/test/resources/application-test.yml @@ -20,5 +20,5 @@ spring: jwk-set-uri: ${wiremockBaseUrl}/jwks consumers: - testnav-person-organisasjon-tilgang-service: + testnav-altinn3-tilgang-service: url: ${wiremockBaseUrl} \ No newline at end of file diff --git a/apps/budpro-service/config.yml b/apps/budpro-service/config.yml index 78ea66f500d..130fbd3286b 100644 --- a/apps/budpro-service/config.yml +++ b/apps/budpro-service/config.yml @@ -5,6 +5,8 @@ metadata: namespace: "dolly" labels: "team": "dolly" + annotations: + texas.nais.io/enabled: "true" spec: accessPolicy: inbound: diff --git a/apps/budpro-service/src/main/resources/application-local.yml b/apps/budpro-service/src/main/resources/application-local.yml index 10148a7de46..675d84c40f0 100644 --- a/apps/budpro-service/src/main/resources/application-local.yml +++ b/apps/budpro-service/src/main/resources/application-local.yml @@ -1,11 +1,9 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + spring: config: import: "sm://" - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} management: endpoints: @@ -15,4 +13,4 @@ management: consumers: generer-navn-service: - url: "https://generer-navn-service.intern.dev.nav.no" \ No newline at end of file + url: "https://generer-navn-service.intern.dev.nav.no" diff --git a/apps/budpro-service/src/main/resources/logback-spring.xml b/apps/budpro-service/src/main/resources/logback-spring.xml index 8d108ba7157..51d34a83c96 100644 --- a/apps/budpro-service/src/main/resources/logback-spring.xml +++ b/apps/budpro-service/src/main/resources/logback-spring.xml @@ -1,6 +1,6 @@ - + diff --git a/apps/dolly-backend/config.test.yml b/apps/dolly-backend/config.test.yml index ed956306f6d..53e3dc0feff 100644 --- a/apps/dolly-backend/config.test.yml +++ b/apps/dolly-backend/config.test.yml @@ -7,6 +7,7 @@ metadata: team: dolly annotations: nginx.ingress.kubernetes.io/proxy-body-size: "512m" + nginx.ingress.kubernetes.io/proxy-buffer-size: "8m" nginx.ingress.kubernetes.io/proxy-send-timeout: "600" nginx.ingress.kubernetes.io/proxy-read-timeout: "600" diff --git a/apps/dolly-backend/config.yml b/apps/dolly-backend/config.yml index 441586da91f..0f656c7ab3c 100644 --- a/apps/dolly-backend/config.yml +++ b/apps/dolly-backend/config.yml @@ -9,6 +9,7 @@ metadata: nginx.ingress.kubernetes.io/proxy-read-timeout: "3600" nginx.ingress.kubernetes.io/proxy-send-timeout: "3600" nginx.ingress.kubernetes.io/proxy-body-size: "512m" + nginx.ingress.kubernetes.io/proxy-buffer-size: "8m" spec: tokenx: diff --git a/apps/dolly-backend/docker-compose.yml b/apps/dolly-backend/docker-compose.yml new file mode 100644 index 00000000000..dc1ab075853 --- /dev/null +++ b/apps/dolly-backend/docker-compose.yml @@ -0,0 +1,28 @@ +services: + + cloud_sql_proxy: + image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.14.2 + network_mode: host + command: + - "dolly-dev-ff83:europe-north1:testnav-dolly-backend-local" + - "--credentials-file=/application_default_credentials.json" + - "--run-connection-test" + volumes: + - type: bind + # Set a variable $DOLLY_APPLICATION_CREDENTIALS. We don't use + # GOOGLE_APPLICATION_CREDENTIALS, as this causes an extra step during login. + # + # - $HOME/.config/gcloud/application_default_credentials.json for Linux/macOS. + # - $APPDATA/gcloud/application_default_credentials.json for Windows. + source: $DOLLY_APPLICATION_CREDENTIALS + target: /application_default_credentials.json + + opensearch: + image: opensearchproject/opensearch:latest + ports: + - "9200:9200" + - "9600:9600" + environment: + discovery.type: single-node + plugins.security.disabled: "true" + OPENSEARCH_INITIAL_ADMIN_PASSWORD: YLAgOm}rz#o6#Aq \ No newline at end of file diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/fullmakt/FullmaktClient.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/fullmakt/FullmaktClient.java index 5b48dade5c8..87c8bd8d144 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/fullmakt/FullmaktClient.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/fullmakt/FullmaktClient.java @@ -28,8 +28,6 @@ @RequiredArgsConstructor public class FullmaktClient implements ClientRegister { - private static final String FULLMAKT_REPRESENTASJON = "FULLMAKT_REPR#"; - private final ErrorStatusDecoder errorStatusDecoder; private final TransactionHelperService transactionHelperService; private final FullmaktConsumer fullmaktConsumer; diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkClient.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkClient.java index 4fc1be64032..e959390d660 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkClient.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkClient.java @@ -58,7 +58,6 @@ public Flux gjenopprett(RsDollyUtvidetBestilling bestilling, Dolly histarkConsumer.postHistark(request) .mapNotNull(status -> getStatus(dollyPerson.getIdent(), bestilling.getId(), status)) : - Mono.just("OK") ) .map(status -> futurePersist(progress, status)); diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkConsumer.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkConsumer.java index 4620666f522..0965c7236d5 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkConsumer.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/HistarkConsumer.java @@ -10,12 +10,14 @@ import no.nav.testnav.libs.securitycore.domain.ServerProperties; import no.nav.testnav.libs.standalone.servletsecurity.exchange.TokenExchange; import org.springframework.stereotype.Service; +import org.springframework.web.reactive.function.client.ExchangeFilterFunction; import org.springframework.web.reactive.function.client.WebClient; import reactor.core.publisher.Flux; import java.util.UUID; import static java.lang.String.format; +import static java.util.Objects.nonNull; import static no.nav.dolly.domain.CommonKeysAndUtils.CONSUMER; import static no.nav.dolly.util.JacksonExchangeStrategyUtil.getJacksonStrategy; @@ -36,11 +38,12 @@ public HistarkConsumer( this.tokenService = tokenService; this.webClient = webClientBuilder .baseUrl(serverProperties.getUrl()) + .filters(exchangeFilterFunctions -> exchangeFilterFunctions.add(logRequest())) .exchangeStrategies(getJacksonStrategy(objectMapper)) .build(); } - @Timed(name = "providers", tags = { "operation", "dokarkiv-opprett" }) + @Timed(name = "providers", tags = { "operation", "histark-opprett" }) public Flux postHistark(HistarkRequest histarkRequest) { var callId = getNavCallId(); @@ -51,6 +54,28 @@ public Flux postHistark(HistarkRequest histarkRequest) { token.getTokenValue()).call()); } + private ExchangeFilterFunction logRequest() { + + return (clientRequest, next) -> { + var buffer = new StringBuilder(250) + .append("Request: ") + .append(clientRequest.method()) + .append(' ') + .append(clientRequest.url()) + .append(System.lineSeparator()); + + clientRequest.headers() + .forEach((name, values) -> values + .forEach(value -> buffer.append('\t') + .append(name) + .append('=') + .append(nonNull(value) && value.contains("Bearer ") ? "Bearer token" : value) + .append(System.lineSeparator()))); + log.trace(buffer.substring(0, buffer.length() - 1)); + return next.exchange(clientRequest); + }; + } + private static String getNavCallId() { return format("%s %s", CONSUMER, UUID.randomUUID()); } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/command/HistarkPostCommand.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/command/HistarkPostCommand.java index ad20fb87941..bdde77ece66 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/command/HistarkPostCommand.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/command/HistarkPostCommand.java @@ -5,10 +5,7 @@ import no.nav.dolly.bestilling.histark.domain.HistarkRequest; import no.nav.dolly.bestilling.histark.domain.HistarkResponse; import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; -import org.springframework.http.HttpHeaders; import org.springframework.http.MediaType; -import org.springframework.http.client.MultipartBodyBuilder; -import org.springframework.web.reactive.function.BodyInserters; import org.springframework.web.reactive.function.client.WebClient; import reactor.core.publisher.Flux; import reactor.core.publisher.Mono; @@ -16,9 +13,11 @@ import java.nio.charset.StandardCharsets; import java.time.Duration; +import java.util.Arrays; import java.util.concurrent.Callable; import static org.springframework.http.HttpHeaders.AUTHORIZATION; +import static org.springframework.web.reactive.function.BodyInserters.fromFormData; @Slf4j @RequiredArgsConstructor @@ -32,29 +31,33 @@ public class HistarkPostCommand implements Callable> { @Override public Flux call() { - return Flux.fromIterable(histarkRequest.getHistarkDokumenter()).flatMap(histarkDokument -> { - var bodyBuilder = new MultipartBodyBuilder(); - bodyBuilder.part("file", histarkDokument.getFile().getBytes(StandardCharsets.UTF_8)); - bodyBuilder.part("metadata", histarkDokument.getMetadata().toString()); - return webClient.post() - .uri(builder -> - builder.path("/api/saksmapper/import").build()) - .header(AUTHORIZATION, "Bearer " + token) - .contentType(MediaType.MULTIPART_FORM_DATA) - .header(HttpHeaders.CONTENT_TYPE, MediaType.MULTIPART_FORM_DATA_VALUE) - .body(BodyInserters.fromMultipartData(bodyBuilder.build())) - .retrieve() - .bodyToMono(String.class) - .doOnSuccess(response -> log.info("Response mottatt fra Histark service: {}", response)) - .map(response -> HistarkResponse.builder() - .histarkId(response.replaceAll("[^\\d-]|-(?=\\D)", "")) - .build()) - .retryWhen(Retry.backoff(3, Duration.ofSeconds(5)) - .filter(WebClientFilter::is5xxException)) - .doOnError(WebClientFilter::logErrorMessage) - .onErrorResume(error -> Mono.just(HistarkResponse.builder() - .feilmelding(WebClientFilter.getMessage(error)) - .build())); - }); + return Flux.fromIterable(histarkRequest.getHistarkDokumenter()) + .flatMap(histarkDokument -> { + log.info("Sender metadata: {}", histarkDokument.getMetadata().toString()); + return webClient.post() + .uri(builder -> + builder.path("/api/saksmapper/import") + .queryParam("metadata", histarkDokument.getMetadata().toString()) + .build()) + .header(AUTHORIZATION, "Bearer " + token) + .contentType(MediaType.MULTIPART_FORM_DATA) + .body(fromFormData("metadata", histarkDokument.getMetadata().toString()) + .with("file", Arrays.toString(histarkDokument.getFile().getBytes(StandardCharsets.UTF_8)))) + .exchangeToMono(clientResponse -> { + log.info("Status fra histark: {}", clientResponse.statusCode()); + log.info("Responseheaders fra histark: {}", clientResponse.headers().asHttpHeaders()); + if (clientResponse.statusCode().isError()) { + return Mono.just(HistarkResponse.builder() + .feilmelding("Feil ved opprettelse av saksmappe, status: " + clientResponse.statusCode()) + .build()); + } + return clientResponse.bodyToMono(HistarkResponse.class); + }) + .doOnNext(response -> log.info("Responsebody fra histark: {}", response)) + .retryWhen(Retry.backoff(3, Duration.ofSeconds(5)) + .filter(WebClientFilter::is5xxException)) + .doOnError(WebClientFilter::logErrorMessage) + .onErrorResume(throwable -> Mono.empty()); + }); } -} \ No newline at end of file +} diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkRequest.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkRequest.java index f3c17399b18..bbdb16cdb30 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkRequest.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkRequest.java @@ -41,6 +41,10 @@ public static class HistarkDokument { @Schema(description = "Metadata tilhørende filen som sendes") private HistarkMetadata metadata; + @Override + public String toString() { + return "HistarkDokument{file='%s...', metadata=%s}".formatted(file.substring(file.length() - 21, file.length() - 1), metadata); + } @Data @Builder diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkResponse.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkResponse.java index c69f5f6f22f..76a3324e4c5 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkResponse.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/histark/domain/HistarkResponse.java @@ -12,5 +12,6 @@ public class HistarkResponse { private String histarkId; + private String saksmappeId; private String feilmelding; } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/instdata/mapper/InstdataMappingStrategy.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/instdata/mapper/InstdataMappingStrategy.java index 6cda125ebf8..29ca884349b 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/instdata/mapper/InstdataMappingStrategy.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/instdata/mapper/InstdataMappingStrategy.java @@ -10,7 +10,6 @@ import no.nav.dolly.mapper.MappingStrategy; import org.springframework.stereotype.Component; -import static java.util.Objects.nonNull; import static no.nav.dolly.domain.resultset.inst.TssEksternId.ADAMSTUEN_SYKEHJEM; import static no.nav.dolly.domain.resultset.inst.TssEksternId.HELGELANDSSYKEHUSET_HF; import static no.nav.dolly.domain.resultset.inst.TssEksternId.INDRE_OSTFOLD_FENGSEL; @@ -29,12 +28,6 @@ public void mapAtoB(RsInstdata rsInstdata, Instdata instdata, MappingContext con instdata.setNorskident((String) context.getProperty("ident")); instdata.setRegistrertAv("Dolly"); - if (nonNull(rsInstdata.getForventetSluttdato())) { - instdata.setSluttdato(rsInstdata.getForventetSluttdato().toLocalDate()); - } - if (nonNull(rsInstdata.getFaktiskSluttdato())) { - instdata.setSluttdato(rsInstdata.getFaktiskSluttdato().toLocalDate()); - } instdata.setOppholdstype(nullcheckSetDefaultValue(rsInstdata.getKategori(), decideKategori(instdata.getInstitusjonstype())).name()); instdata.setTssEksternId(nullcheckSetDefaultValue(instdata.getTssEksternId(), diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/sykemelding/domain/DetaljertSykemeldingRequest.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/sykemelding/domain/DetaljertSykemeldingRequest.java index 78b13c87bb4..7e1d630ebfa 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/sykemelding/domain/DetaljertSykemeldingRequest.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/sykemelding/domain/DetaljertSykemeldingRequest.java @@ -20,9 +20,9 @@ public class DetaljertSykemeldingRequest { private Arbeidsgiver arbeidsgiver; + private DollyDiagnose hovedDiagnose; private List biDiagnoser; private Detaljer detaljer; - private DollyDiagnose hovedDiagnose; private Helsepersonell helsepersonell; private Boolean manglendeTilretteleggingPaaArbeidsplassen; private Organisasjon mottaker; @@ -31,6 +31,7 @@ public class DetaljertSykemeldingRequest { private Organisasjon sender; private LocalDate startDato; private Boolean umiddelbarBistand; + private KontaktMedPasient kontaktMedPasient; public List getBiDiagnoser() { if (isNull(biDiagnoser)) { @@ -57,7 +58,6 @@ public enum AktivitetType { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Arbeidsgiver { - private String navn; private Double stillingsprosent; private String yrkesbetegnelse; @@ -69,7 +69,6 @@ public static class Arbeidsgiver { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class DollyDiagnose { - private String diagnose; private String diagnosekode; private String system; @@ -81,7 +80,6 @@ public static class DollyDiagnose { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Detaljer { - private Boolean arbeidsforEtterEndtPeriode; private String beskrivHensynArbeidsplassen; private String tiltakArbeidsplass; @@ -94,7 +92,6 @@ public static class Detaljer { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Helsepersonell { - private String etternavn; private String fornavn; private String hprId; @@ -109,7 +106,6 @@ public static class Helsepersonell { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Organisasjon { - private Adresse adresse; private String navn; private String orgNr; @@ -121,7 +117,6 @@ public static class Organisasjon { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Pasient { - private Adresse adresse; private String etternavn; private LocalDate foedselsdato; @@ -138,7 +133,6 @@ public static class Pasient { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Periode { - private DollyAktivitet aktivitet; private LocalDate fom; private LocalDate tom; @@ -155,7 +149,6 @@ public static class DollyAktivitet { private Integer behandlingsdager; private Integer grad; private Boolean reisetilskudd; - } @Data @@ -164,10 +157,19 @@ public static class DollyAktivitet { @AllArgsConstructor @JsonInclude(value = JsonInclude.Include.NON_EMPTY) public static class Adresse { - private String by; private String gate; private String land; private String postnummer; } -} + + @Data + @Builder + @NoArgsConstructor + @AllArgsConstructor + @JsonInclude(value = JsonInclude.Include.NON_EMPTY) + public static class KontaktMedPasient { + private LocalDate kontaktDato; + private String begrunnelseIkkeKontakt; + } +} \ No newline at end of file diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/inst/Instdata.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/inst/Instdata.java index 448e3f7e262..6fb96fb61d3 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/inst/Instdata.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/inst/Instdata.java @@ -23,6 +23,7 @@ public class Instdata { private LocalDate startdato; private LocalDate sluttdato; + private LocalDate forventetSluttdato; private String registrertAv; } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/sykemelding/RsSykemelding.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/sykemelding/RsSykemelding.java index 430979e7f77..8407f3c604c 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/sykemelding/RsSykemelding.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/sykemelding/RsSykemelding.java @@ -30,6 +30,18 @@ public class RsSykemelding { private RsSyntSykemelding syntSykemelding; private RsDetaljertSykemelding detaljertSykemelding; + @JsonIgnore + public boolean hasDetaljertSykemelding() { + + return nonNull(detaljertSykemelding); + } + + @JsonIgnore + public boolean hasSyntSykemelding() { + + return nonNull(syntSykemelding); + } + @Getter @Setter @Builder @@ -53,9 +65,9 @@ public static class RsSyntSykemelding { public static class RsDetaljertSykemelding { private Arbeidsgiver arbeidsgiver; + private DollyDiagnose hovedDiagnose; private List biDiagnoser; private Detaljer detaljer; - private DollyDiagnose hovedDiagnose; private Helsepersonell helsepersonell; private Boolean manglendeTilretteleggingPaaArbeidsplassen; private Organisasjon mottaker; @@ -65,6 +77,7 @@ public static class RsDetaljertSykemelding { @Field(type = FieldType.Date, format = DateFormat.basic_date, pattern = "uuuu-MM-dd") private LocalDate startDato; private Boolean umiddelbarBistand; + private KontaktMedPasient kontaktMedPasient; public List getBiDiagnoser() { if (isNull(biDiagnoser)) { @@ -216,17 +229,16 @@ public static class Adresse { private String land; private String postnummer; } - } - - @JsonIgnore - public boolean hasDetaljertSykemelding() { - - return nonNull(detaljertSykemelding); - } - - @JsonIgnore - public boolean hasSyntSykemelding() { - return nonNull(syntSykemelding); + @Getter + @Setter + @Builder + @NoArgsConstructor + @AllArgsConstructor + @JsonInclude(JsonInclude.Include.NON_EMPTY) + public static class KontaktMedPasient { + private LocalDate kontaktDato; + private String begrunnelseIkkeKontakt; + } } } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/provider/api/advice/HttpExceptionAdvice.java b/apps/dolly-backend/src/main/java/no/nav/dolly/provider/api/advice/HttpExceptionAdvice.java index 6c1d8427a97..cb7d3c6c17c 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/provider/api/advice/HttpExceptionAdvice.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/provider/api/advice/HttpExceptionAdvice.java @@ -6,6 +6,7 @@ import lombok.Data; import lombok.NoArgsConstructor; import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; import no.nav.dolly.exceptions.ConstraintViolationException; import no.nav.dolly.exceptions.DollyFunctionalException; import no.nav.dolly.exceptions.KodeverkException; @@ -22,6 +23,7 @@ import java.time.LocalDateTime; @ControllerAdvice +@Slf4j @RequiredArgsConstructor public class HttpExceptionAdvice { @@ -29,6 +31,7 @@ public class HttpExceptionAdvice { private final UrlPathHelper urlPathHelper; private ExceptionInformation informationForException(RuntimeException exception, HttpStatus status) { + log.error("HttpException: ", exception); return ExceptionInformation.builder() .error(status.getReasonPhrase()) .status(status.value()) diff --git a/apps/dolly-backend/src/main/resources/application-dev.yaml b/apps/dolly-backend/src/main/resources/application-dev.yml similarity index 100% rename from apps/dolly-backend/src/main/resources/application-dev.yaml rename to apps/dolly-backend/src/main/resources/application-dev.yml diff --git a/apps/dolly-backend/src/main/resources/application-local.yaml b/apps/dolly-backend/src/main/resources/application-local.yml similarity index 93% rename from apps/dolly-backend/src/main/resources/application-local.yaml rename to apps/dolly-backend/src/main/resources/application-local.yml index 27d8ee5323b..e2aa7e2a7e7 100644 --- a/apps/dolly-backend/src/main/resources/application-local.yaml +++ b/apps/dolly-backend/src/main/resources/application-local.yml @@ -1,3 +1,6 @@ +AZURE_APP_CLIENT_ID: ${sm://azure-app-client-id} +AZURE_APP_CLIENT_SECRET: ${sm://azure-app-client-secret} + dolly: client: general: @@ -12,11 +15,6 @@ spring: url: jdbc:postgresql://localhost:5432/testnav-dolly-backend-local username: testnav-dolly-backend-local password: ${sm://testnav-dolly-backend-local} - security: - oauth2: - resourceserver: - aad: - accepted-audience: ${sm://azure-app-client-id}, api://${sm://azure-app-client-id} management: endpoints: diff --git a/apps/dolly-backend/src/main/resources/application-prod.yaml b/apps/dolly-backend/src/main/resources/application-prod.yml similarity index 100% rename from apps/dolly-backend/src/main/resources/application-prod.yaml rename to apps/dolly-backend/src/main/resources/application-prod.yml diff --git a/apps/dolly-backend/src/main/resources/application.yaml b/apps/dolly-backend/src/main/resources/application.yml similarity index 98% rename from apps/dolly-backend/src/main/resources/application.yaml rename to apps/dolly-backend/src/main/resources/application.yml index 6caad4f8bde..7187259ca47 100644 --- a/apps/dolly-backend/src/main/resources/application.yaml +++ b/apps/dolly-backend/src/main/resources/application.yml @@ -64,15 +64,14 @@ management: enabled-by-default: true web: base-path: /internal - exposure.include: prometheus,heapdump,health + exposure: + include: prometheus,health path-mapping: prometheus: metrics endpoint: health: show-components: always show-details: always - heapdump: - enabled: true prometheus: enabled: true prometheus: diff --git a/apps/dolly-backend/src/main/resources/logback-spring.xml b/apps/dolly-backend/src/main/resources/logback-spring.xml index 09dbae4c025..a49aedadd95 100644 --- a/apps/dolly-backend/src/main/resources/logback-spring.xml +++ b/apps/dolly-backend/src/main/resources/logback-spring.xml @@ -41,6 +41,7 @@ + diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/aareg/AaregConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/aareg/AaregConsumerTest.java index 2a3a2c43845..217d0de176d 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/aareg/AaregConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/aareg/AaregConsumerTest.java @@ -39,7 +39,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class AaregConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/arenaforvalter/ArenaForvalterConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/arenaforvalter/ArenaForvalterConsumerTest.java index d8e29a9d42d..99f38233dbf 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/arenaforvalter/ArenaForvalterConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/arenaforvalter/ArenaForvalterConsumerTest.java @@ -35,7 +35,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class ArenaForvalterConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/instdata/InstdataConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/instdata/InstdataConsumerTest.java index 8a5bdf1c5ea..21b887d970e 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/instdata/InstdataConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/instdata/InstdataConsumerTest.java @@ -37,7 +37,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class InstdataConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/kontoregisterservice/KontoregisterConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/kontoregisterservice/KontoregisterConsumerTest.java index 2e26426511d..40a6ede774a 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/kontoregisterservice/KontoregisterConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/kontoregisterservice/KontoregisterConsumerTest.java @@ -42,7 +42,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class KontoregisterConsumerTest { private static final String IDENT = "12345678901"; diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/krrstub/KrrstubConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/krrstub/KrrstubConsumerTest.java index d5afa94ac60..76437c53abc 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/krrstub/KrrstubConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/krrstub/KrrstubConsumerTest.java @@ -44,7 +44,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class KrrstubConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/pensjonforvalter/PensjonforvalterConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/pensjonforvalter/PensjonforvalterConsumerTest.java index 6aa4613ac43..58d401d7fae 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/pensjonforvalter/PensjonforvalterConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/pensjonforvalter/PensjonforvalterConsumerTest.java @@ -38,7 +38,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class PensjonforvalterConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/sigrunstub/SigrunStubConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/sigrunstub/SigrunStubConsumerTest.java index a2d09fd56ad..90d4946730c 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/sigrunstub/SigrunStubConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/sigrunstub/SigrunStubConsumerTest.java @@ -41,7 +41,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class SigrunStubConsumerTest { diff --git a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/tpsmessagingservice/TpsMessagingConsumerTest.java b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/tpsmessagingservice/TpsMessagingConsumerTest.java index 8c3f2a441a9..4f29d5b8985 100644 --- a/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/tpsmessagingservice/TpsMessagingConsumerTest.java +++ b/apps/dolly-backend/src/test/java/no/nav/dolly/bestilling/tpsmessagingservice/TpsMessagingConsumerTest.java @@ -41,7 +41,7 @@ @ActiveProfiles("test") @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@TestPropertySource(locations = "classpath:application.yaml") +@TestPropertySource(locations = "classpath:application.yml") @AutoConfigureWireMock(port = 0) class TpsMessagingConsumerTest { diff --git a/apps/dolly-backend/src/test/resources/application-test.yaml b/apps/dolly-backend/src/test/resources/application-test.yml similarity index 100% rename from apps/dolly-backend/src/test/resources/application-test.yaml rename to apps/dolly-backend/src/test/resources/application-test.yml diff --git a/apps/dolly-frontend/config.idporten.yml b/apps/dolly-frontend/config.idporten.yml index 4d9bce7df8e..64f2ba53138 100644 --- a/apps/dolly-frontend/config.idporten.yml +++ b/apps/dolly-frontend/config.idporten.yml @@ -17,7 +17,7 @@ spec: tenant: nav.no replicas: min: 1 - max: 2 + max: 1 port: 8080 ingresses: - "https://dolly-idporten.ekstern.dev.nav.no" @@ -42,11 +42,8 @@ spec: - application: testnav-organisasjon-faste-data-service - application: testnav-organisasjon-forvalter - application: testnav-organisasjon-service - - application: testnav-organisasjon-tilgang-service - application: testnav-pdl-forvalter - application: testnav-person-faste-data-service - - application: testnav-person-organisasjon-tilgang-service - - application: testnav-person-organisasjon-tilgang-service-dev - application: testnav-person-search-service - application: testnav-person-service - application: testnav-skattekort-service @@ -57,6 +54,7 @@ spec: - application: testnorge-profil-api - application: testnorge-tilbakemelding-api - application: testnav-yrkesskade-proxy + - application: testnav-altinn3-tilgang-proxy external: - host: testnav-pensjon-testdata-facade-proxy.dev-fss-pub.nais.io - host: testnav-sigrunstub-proxy.dev-fss-pub.nais.io diff --git a/apps/dolly-frontend/config.test.yml b/apps/dolly-frontend/config.test.yml index 45bf1b3dbd2..9494c59a1f0 100644 --- a/apps/dolly-frontend/config.test.yml +++ b/apps/dolly-frontend/config.test.yml @@ -46,13 +46,11 @@ spec: - application: testnav-organisasjon-faste-data-service - application: testnav-organisasjon-forvalter - application: testnav-organisasjon-service - - application: testnav-organisasjon-tilgang-service - application: testnav-pdl-forvalter-dev - application: testnav-person-faste-data-service - - application: testnav-person-organisasjon-tilgang-service-dev - application: testnav-person-search-service - application: testnav-person-service - - application: testnav-sykemelding-api + - application: testnav-sykemelding-api-dev - application: testnav-tenor-search-service - application: testnav-tps-messaging-service - application: testnav-varslinger-service @@ -63,6 +61,7 @@ spec: - application: testnav-levende-arbeidsforhold-scheduler - application: testnav-skattekort-service - application: testnav-yrkesskade-proxy + - application: testnav-altinn3-tilgang-service external: - host: testnav-pensjon-testdata-facade-proxy.dev-fss-pub.nais.io - host: testnav-sigrunstub-proxy.dev-fss-pub.nais.io diff --git a/apps/dolly-frontend/config.unstable.yml b/apps/dolly-frontend/config.unstable.yml index 62416c37c82..19b2a8aa5cc 100644 --- a/apps/dolly-frontend/config.unstable.yml +++ b/apps/dolly-frontend/config.unstable.yml @@ -44,9 +44,7 @@ spec: - application: testnav-organisasjon-faste-data-service - application: testnav-organisasjon-forvalter - application: testnav-organisasjon-service - - application: testnav-organisasjon-tilgang-service - application: testnav-pdl-forvalter-dev - - application: testnav-person-organisasjon-tilgang-service-dev - application: testnav-person-search-service - application: testnav-person-service - application: testnav-tenor-search-service @@ -56,6 +54,7 @@ spec: - application: testnorge-tilbakemelding-api - application: testnav-skattekort-service - application: testnav-yrkesskade-proxy + - application: testnav-altinn3-tilgang-service external: - host: testnav-pensjon-testdata-facade-proxy.dev-fss-pub.nais.io - host: testnav-sigrunstub-proxy.dev-fss-pub.nais.io diff --git a/apps/dolly-frontend/config.yml b/apps/dolly-frontend/config.yml index 851b7e85ed9..2faeb17bc3a 100644 --- a/apps/dolly-frontend/config.yml +++ b/apps/dolly-frontend/config.yml @@ -51,10 +51,8 @@ spec: - application: testnav-organisasjon-faste-data-service - application: testnav-organisasjon-forvalter - application: testnav-organisasjon-service - - application: testnav-organisasjon-tilgang-service - application: testnav-pdl-forvalter - application: testnav-person-faste-data-service - - application: testnav-person-organisasjon-tilgang-service - application: testnav-person-search-service - application: testnav-person-service - application: testnav-skattekort-service @@ -67,7 +65,7 @@ spec: - application: testnav-levende-arbeidsforhold-ansettelse - application: testnav-levende-arbeidsforhold-scheduler - application: testnav-yrkesskade-proxy - + - application: testnav-altinn3-tilgang-proxy external: - host: testnav-pensjon-testdata-facade-proxy.dev-fss-pub.nais.io - host: testnav-sigrunstub-proxy.dev-fss-pub.nais.io diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/DollyFrontendApplicationStarter.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/DollyFrontendApplicationStarter.java index 265f37443c5..8124c6e087f 100644 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/DollyFrontendApplicationStarter.java +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/DollyFrontendApplicationStarter.java @@ -53,7 +53,6 @@ public class DollyFrontendApplicationStarter { @Bean public RouteLocator customRouteLocator(RouteLocatorBuilder builder) { - return builder .routes() .route(createRoute(consumers.getTestnavKontoregisterPersonProxy())) @@ -62,9 +61,9 @@ public RouteLocator customRouteLocator(RouteLocatorBuilder builder) { .route(createRoute(consumers.getOppsummeringsdokumentService(), "oppsummeringsdokument-service")) .route(createRoute(consumers.getTestnavOrganisasjonForvalter())) .route(createRoute(consumers.getTestnavVarslingerService(), "testnav-varslinger-service")) - .route(createRoute(consumers.getTestnavOrganisasjonTilgangService(), "testnav-organisasjon-tilgang-service")) .route(createRoute(consumers.getTestnavTpsMessagingService(), "testnav-tps-messaging-service")) .route(createRoute(consumers.getTestnorgeProfilApi(), "testnorge-profil-api")) + .route(createRoute(consumers.getTestnavSykemeldingApi(), "testnav-sykemelding-api")) .route(createRoute(consumers.getTestnavBrukerService(), "testnav-bruker-service")) .route(createRoute(consumers.getTestnavMiljoerService())) .route(createRoute(consumers.getDollyBackend(), "dolly-backend")) @@ -85,7 +84,6 @@ public RouteLocator customRouteLocator(RouteLocatorBuilder builder) { .route(createRoute(consumers.getTestnavSigrunstubProxy())) .route(createRoute(consumers.getTestnavPdlForvalter(), "testnav-pdl-forvalter")) .route(createRoute(consumers.getTestnavPersonSearchService())) - .route(createRoute(consumers.getTestnavPersonOrganisasjonTilgangService(), "testnav-person-organisasjon-tilgang-service")) .route(createRoute(consumers.getTestnavSkjermingsregisterProxy())) .route(createRoute(consumers.getTestnavDokarkivProxy())) .route(createRoute(consumers.getTestnavArbeidsplassenCVProxy())) @@ -98,6 +96,7 @@ public RouteLocator customRouteLocator(RouteLocatorBuilder builder) { .route(createRoute(consumers.getTestnavLevendeArbeidsforholdAnsettelse(), "testnav-levende-arbeidsforhold-ansettelse")) .route(createRoute(consumers.getTestnavLevendeArbeidsforholdScheduler(), "testnav-levende-arbeidsforhold-scheduler")) .route(createRoute(consumers.getTestnavYrkesskadeProxy())) + .route(createRoute(consumers.getTestnavAltinn3TilgangService(), "testnav-altinn3-tilgang-service")) .build(); } @@ -146,4 +145,4 @@ private Function> createRoute(String segment, St .filters(filter, removeCookiesFilter, addUserJwtHeaderFilter()) ).uri(host); } -} +} \ No newline at end of file diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/config/Consumers.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/config/Consumers.java index 0217856ea1d..86a118efec9 100644 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/config/Consumers.java +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/config/Consumers.java @@ -49,10 +49,8 @@ public class Consumers { private ServerProperties testnavOrganisasjonFasteDataService; private ServerProperties testnavOrganisasjonForvalter; private ServerProperties testnavOrganisasjonService; - private ServerProperties testnavOrganisasjonTilgangService; private ServerProperties testnavPdlForvalter; private ServerProperties testnavPensjonTestdataFacadeProxy; - private ServerProperties testnavPersonOrganisasjonTilgangService; private ServerProperties testnavPersonSearchService; private ServerProperties testnavPersonService; private ServerProperties testnavSigrunstubProxy; @@ -63,9 +61,11 @@ public class Consumers { private ServerProperties testnorgeProfilApi; private ServerProperties testnorgeTilbakemeldingApi; private ServerProperties testnavTenorSearchService; + private ServerProperties testnavSykemeldingApi; private ServerProperties testnavSkattekortService; private ServerProperties testnavLevendeArbeidsforholdAnsettelse; private ServerProperties testnavLevendeArbeidsforholdScheduler; private ServerProperties testnavYrkesskadeProxy; + private ServerProperties testnavAltinn3TilgangService; } diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/Altinn3PersonOrganisasjonTilgangConsumer.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/Altinn3PersonOrganisasjonTilgangConsumer.java new file mode 100644 index 00000000000..50a38ef30f7 --- /dev/null +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/Altinn3PersonOrganisasjonTilgangConsumer.java @@ -0,0 +1,66 @@ +package no.nav.dolly.web.consumers; + +import lombok.extern.slf4j.Slf4j; +import no.nav.dolly.web.config.Consumers; +import no.nav.dolly.web.consumers.command.PostPersonOrganisasjonTilgangCommand; +import no.nav.dolly.web.service.AccessService; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; +import no.nav.testnav.libs.reactivesecurity.action.GetAuthenticatedUserId; +import no.nav.testnav.libs.securitycore.domain.ServerProperties; +import org.springframework.stereotype.Component; +import org.springframework.web.reactive.function.client.WebClient; +import org.springframework.web.reactive.function.client.WebClientResponseException; +import org.springframework.web.server.ServerWebExchange; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +@Slf4j +@Component +public class Altinn3PersonOrganisasjonTilgangConsumer { + + private final WebClient webClient; + private final ServerProperties serverProperties; + private final AccessService accessService; + private final GetAuthenticatedUserId getAuthenticatedUserId; + + public Altinn3PersonOrganisasjonTilgangConsumer( + Consumers consumers, + AccessService accessService, + WebClient.Builder webClientBuilder, + GetAuthenticatedUserId getAuthenticatedUserId) { + + this.accessService = accessService; + serverProperties = consumers.getTestnavAltinn3TilgangService(); + + this.webClient = webClientBuilder + .baseUrl(serverProperties.getUrl()) + .build(); + this.getAuthenticatedUserId = getAuthenticatedUserId; + } + + public Mono hasAccess(String organisasjonsnummer, ServerWebExchange exchange) { + + return getAuthenticatedUserId + .call() + .flatMap(userId -> accessService.getAccessToken(serverProperties, exchange) + .flatMapMany(accessToken -> new PostPersonOrganisasjonTilgangCommand(webClient, userId, accessToken).call()) + .filter(organisasjonDTO -> organisasjonDTO.getOrganisasjonsnummer().equals(organisasjonsnummer)) + .onErrorResume( + WebClientResponseException.class::isInstance, + throwable -> { + log.warn("Person har ikke tilgang til organisasjon {}.", organisasjonsnummer); + return Mono.empty(); + }) + .reduce(Boolean.FALSE, (acc, value) -> Boolean.TRUE)); + } + + public Flux getOrganisasjoner(ServerWebExchange exchange) { + + return getAuthenticatedUserId + .call() + .flatMapMany(userId -> + accessService.getAccessToken(serverProperties, exchange) + .flatMapMany(accessToken -> new PostPersonOrganisasjonTilgangCommand(webClient, userId, accessToken).call())); + } +} + diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/PersonOrganisasjonTilgangConsumer.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/PersonOrganisasjonTilgangConsumer.java deleted file mode 100644 index cec7481322b..00000000000 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/PersonOrganisasjonTilgangConsumer.java +++ /dev/null @@ -1,62 +0,0 @@ -package no.nav.dolly.web.consumers; - -import com.fasterxml.jackson.databind.ObjectMapper; -import lombok.extern.slf4j.Slf4j; -import no.nav.dolly.web.config.Consumers; -import no.nav.dolly.web.consumers.command.GetPersonOrganisasjonTilgangCommand; -import no.nav.dolly.web.service.AccessService; -import no.nav.testnav.libs.securitycore.domain.ServerProperties; -import org.springframework.http.MediaType; -import org.springframework.http.codec.json.Jackson2JsonDecoder; -import org.springframework.http.codec.json.Jackson2JsonEncoder; -import org.springframework.stereotype.Component; -import org.springframework.web.reactive.function.client.ExchangeStrategies; -import org.springframework.web.reactive.function.client.WebClient; -import org.springframework.web.reactive.function.client.WebClientResponseException; -import org.springframework.web.server.ServerWebExchange; -import reactor.core.publisher.Mono; - -@Slf4j -@Component -public class PersonOrganisasjonTilgangConsumer { - private final WebClient webClient; - private final ServerProperties serverProperties; - - private final AccessService accessService; - - public PersonOrganisasjonTilgangConsumer( - Consumers consumers, - AccessService accessService, - ObjectMapper objectMapper, - WebClient.Builder webClientBuilder) { - - this.accessService = accessService; - serverProperties = consumers.getTestnavPersonOrganisasjonTilgangService(); - ExchangeStrategies jacksonStrategy = ExchangeStrategies.builder() - .codecs(config -> { - config.defaultCodecs() - .jackson2JsonEncoder(new Jackson2JsonEncoder(objectMapper, MediaType.APPLICATION_JSON)); - config.defaultCodecs() - .jackson2JsonDecoder(new Jackson2JsonDecoder(objectMapper, MediaType.APPLICATION_JSON)); - }).build(); - - this.webClient = webClientBuilder - .exchangeStrategies(jacksonStrategy) - .baseUrl(serverProperties.getUrl()) - .build(); - } - - public Mono hasAccess(String organisasjonsnummer, ServerWebExchange exchange) { - return accessService.getAccessToken(serverProperties, exchange) - .flatMap(accessToken -> new GetPersonOrganisasjonTilgangCommand(webClient, accessToken, organisasjonsnummer).call()) - .onErrorResume( - WebClientResponseException.class::isInstance, - throwable -> { - log.warn("Person har ikke tilgang til organisasjon {}.", organisasjonsnummer); - return Mono.empty(); - }) - .flatMap(value -> Mono.just(true)) - .switchIfEmpty(Mono.just(false)); - } -} - diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/GetPersonOrganisasjonTilgangCommand.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/PostPersonOrganisasjonTilgangCommand.java similarity index 59% rename from apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/GetPersonOrganisasjonTilgangCommand.java rename to apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/PostPersonOrganisasjonTilgangCommand.java index 3bdfb86c837..7b7e5ece269 100644 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/GetPersonOrganisasjonTilgangCommand.java +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/command/PostPersonOrganisasjonTilgangCommand.java @@ -2,11 +2,12 @@ import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import no.nav.dolly.web.consumers.dto.OrganisasjonDTO; +import no.nav.dolly.web.consumers.dto.AltinnBrukerRequest; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; import org.springframework.http.HttpHeaders; import org.springframework.web.reactive.function.client.WebClient; -import reactor.core.publisher.Mono; +import reactor.core.publisher.Flux; import reactor.util.retry.Retry; import java.time.Duration; @@ -14,21 +15,24 @@ @Slf4j @RequiredArgsConstructor -public class GetPersonOrganisasjonTilgangCommand implements Callable> { +public class PostPersonOrganisasjonTilgangCommand implements Callable> { + private final WebClient webClient; + private final String ident; private final String token; - private final String organisasjonsnummer; @Override - public Mono call() { + public Flux call() { + return webClient - .get() - .uri(builder -> builder.path("/api/v1/person/organisasjoner/{organisasjonsnummer}").build(organisasjonsnummer)) + .post() + .uri(builder -> builder.path("/api/v1/brukertilgang").build()) .header(HttpHeaders.AUTHORIZATION, "Bearer " + token) + .bodyValue(new AltinnBrukerRequest(ident)) .retrieve() - .bodyToMono(OrganisasjonDTO.class) - .doOnError(error -> log.error("Feilet å hente organisasjon, status: {}, feilmelding: ", - WebClientFilter.getMessage(error), + .bodyToFlux(OrganisasjonDTO.class) + .doOnError(error -> log.error("Feilet å hente organisasjon, status: {}, feilmelding: {}", + WebClientFilter.getStatus(error), WebClientFilter.getMessage(error), error)) .retryWhen(Retry.backoff(3, Duration.ofSeconds(5)) diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/AltinnBrukerRequest.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/AltinnBrukerRequest.java new file mode 100644 index 00000000000..91dbb8b2a03 --- /dev/null +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/AltinnBrukerRequest.java @@ -0,0 +1,11 @@ +package no.nav.dolly.web.consumers.dto; + +import lombok.AllArgsConstructor; +import lombok.Data; + +@Data +@AllArgsConstructor +public class AltinnBrukerRequest { + + private String ident; +} diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/OrganisasjonDTO.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/OrganisasjonDTO.java deleted file mode 100644 index fdd85cd2839..00000000000 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/consumers/dto/OrganisasjonDTO.java +++ /dev/null @@ -1,12 +0,0 @@ -package no.nav.dolly.web.consumers.dto; - -import java.time.LocalDateTime; - -public record OrganisasjonDTO( - String navn, - String orgnisasjonsnummer, - String orgnisasjonsfrom, - LocalDateTime gyldigTil -) { -} - diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/BrukerTilgangController.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/BrukerTilgangController.java new file mode 100644 index 00000000000..829b41b4fab --- /dev/null +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/BrukerTilgangController.java @@ -0,0 +1,29 @@ +package no.nav.dolly.web.provider.web; + +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import no.nav.dolly.web.consumers.Altinn3PersonOrganisasjonTilgangConsumer; +import no.nav.testnav.libs.dto.altinn3.v1.OrganisasjonDTO; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.server.ServerWebExchange; +import reactor.core.publisher.Mono; + +import java.util.List; + +@Slf4j +@RestController +@RequestMapping("/altinn") +@RequiredArgsConstructor +public class BrukerTilgangController { + + private final Altinn3PersonOrganisasjonTilgangConsumer altinn3PersonOrganisasjonTilgangConsumer; + + @GetMapping("/organisasjoner") + public Mono> getOrganisasjoner(ServerWebExchange exchange) { + + return altinn3PersonOrganisasjonTilgangConsumer.getOrganisasjoner(exchange) + .collectList(); + } +} diff --git a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/SessionController.java b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/SessionController.java index 0652790796c..f6222576b25 100644 --- a/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/SessionController.java +++ b/apps/dolly-frontend/src/main/java/no/nav/dolly/web/provider/web/SessionController.java @@ -2,7 +2,7 @@ import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import no.nav.dolly.web.consumers.PersonOrganisasjonTilgangConsumer; +import no.nav.dolly.web.consumers.Altinn3PersonOrganisasjonTilgangConsumer; import no.nav.dolly.web.service.BrukerService; import no.nav.testnav.libs.securitycore.config.UserSessionConstant; import org.springframework.http.HttpStatus; @@ -24,7 +24,7 @@ public class SessionController { private final BrukerService brukerService; - private final PersonOrganisasjonTilgangConsumer personOrganisasjonTilgangConsumer; + private final Altinn3PersonOrganisasjonTilgangConsumer altinn3PersonOrganisasjonTilgangConsumer; /** * Ping endepunkt for aa holde sessionen aapen. @@ -44,7 +44,8 @@ public Mono> delete(ServerWebExchange exchange) { @PutMapping("/user") public Mono> addUserToSession(@RequestParam String organisasjonsnummer, ServerWebExchange exchange) { - return personOrganisasjonTilgangConsumer + + return altinn3PersonOrganisasjonTilgangConsumer .hasAccess(organisasjonsnummer, exchange) .doOnError(e -> log.error("Feil ved sjekk av tilgang til org {}", organisasjonsnummer, e)) .flatMap(hasAccess -> { diff --git a/apps/dolly-frontend/src/main/js/package-lock.json b/apps/dolly-frontend/src/main/js/package-lock.json index 80940c5d35d..1456b6e885c 100644 --- a/apps/dolly-frontend/src/main/js/package-lock.json +++ b/apps/dolly-frontend/src/main/js/package-lock.json @@ -1,12 +1,12 @@ { "name": "dolly", - "version": "3.0.47", + "version": "3.0.50", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "dolly", - "version": "3.0.47", + "version": "3.0.50", "license": "ISC", "dependencies": { "@grafana/faro-react": "^1.11.0", @@ -21,12 +21,11 @@ "dayjs": "^1.11.13", "history": "^5.3.0", "immer": "^10.1.1", - "lodash": "^4.17.21", + "lodash-es": "^4.17.21", "rc-progress": "^4.0.0", "rc-tooltip": "^6.2.1", "react": "^18.3.1", "react-confetti-explosion": "^2.1.2", - "react-datepicker": "^7.5.0", "react-dom": "^18.3.1", "react-highlight-words": "^0.20.0", "react-hook-form": "^7.53.1", @@ -55,13 +54,11 @@ "@navikt/ds-icons": "^3.4.3", "@navikt/ds-react": "^7.4.0", "@playwright/test": "^1.48.2", - "@redux-devtools/extension": "^3.3.0", "@reduxjs/toolkit": "^2.3.0", "@testing-library/react": "^16.0.1", - "@types/lodash": "^4.17.13", + "@types/lodash-es": "^4.17.12", "@types/node": "^22.8.4", "@types/react": "^18.3.12", - "@types/react-datepicker": "^6.2.0", "@types/react-dom": "^18.3.1", "@types/react-highlight-words": "^0.20.0", "@types/react-redux": "^7.1.34", @@ -71,8 +68,8 @@ "@types/redux-actions": "^2.6.5", "@typescript-eslint/eslint-plugin": "^8.12.2", "@typescript-eslint/parser": "^8.12.2", - "@vitejs/plugin-react": "^4.3.3", - "@vitest/ui": "^2.1.4", + "@vitejs/plugin-react": "^4.3.4", + "@vitest/ui": "^2.1.6", "babel-plugin-styled-components": "^2.1.4", "dot-prop": "^9.0.0", "eslint": "^9.13.0", @@ -90,12 +87,11 @@ "react-router-dom": "^6.27.0", "sass": "^1.80.5", "swr": "^2.2.5", - "ts-node": "^10.9.2", "typescript": "^5.6.3", - "vite": "^5.4.10", + "vite": "^6.0.1", "vite-plugin-environment": "^1.1.3", - "vite-tsconfig-paths": "^5.0.1", - "vitest": "^2.1.4" + "vite-tsconfig-paths": "^5.1.3", + "vitest": "^2.1.6" } }, "node_modules/@ampproject/remapping": { @@ -127,9 +123,9 @@ } }, "node_modules/@babel/compat-data": { - "version": "7.26.2", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.26.2.tgz", - "integrity": "sha512-Z0WgzSEa+aUcdiJuCIqgujCshpMWgUpgOxXotrYPSA53hA3qopNaqcJpyr0hVb1FeWdnqFA35/fUtXgBK8srQg==", + "version": "7.26.3", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.26.3.tgz", + "integrity": "sha512-nHIxvKPniQXpmQLb0vhY3VaFb3S0YrTAwpOWJZh1wn3oJPjJk9Asva204PsBdmAE8vpzfHudT8DB0scYvy9q0g==", "dev": true, "license": "MIT", "engines": { @@ -178,13 +174,13 @@ } }, "node_modules/@babel/generator": { - "version": "7.26.2", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.26.2.tgz", - "integrity": "sha512-zevQbhbau95nkoxSq3f/DC/SC+EEOUZd3DYqfSkMhY2/wfSeaHV1Ew4vk8e+x8lja31IbyuUa2uQ3JONqKbysw==", + "version": "7.26.3", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.26.3.tgz", + "integrity": "sha512-6FF/urZvD0sTeO7k6/B15pMLC4CHUv1426lzr3N01aHJTl046uCAh9LXW/fzeXXjPNCJ6iABW5XaWOsIZB93aQ==", "license": "MIT", "dependencies": { - "@babel/parser": "^7.26.2", - "@babel/types": "^7.26.0", + "@babel/parser": "^7.26.3", + "@babel/types": "^7.26.3", "@jridgewell/gen-mapping": "^0.3.5", "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^3.0.2" @@ -317,12 +313,12 @@ } }, "node_modules/@babel/parser": { - "version": "7.26.2", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.26.2.tgz", - "integrity": "sha512-DWMCZH9WA4Maitz2q21SRKHo9QXZxkDsbNZoVD62gusNtNBBqDg9i7uOhASfTfIGNzW+O+r7+jAlM8dwphcJKQ==", + "version": "7.26.3", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.26.3.tgz", + "integrity": "sha512-WJ/CvmY8Mea8iDXo6a7RK2wbmJITT5fN3BEkRuFlxVyNx8jOKIIhmC4fSkTcPcf8JyavbBwIe6OpiCOBXt/IcA==", "license": "MIT", "dependencies": { - "@babel/types": "^7.26.0" + "@babel/types": "^7.26.3" }, "bin": { "parser": "bin/babel-parser.js" @@ -406,16 +402,16 @@ } }, "node_modules/@babel/traverse": { - "version": "7.25.9", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.25.9.tgz", - "integrity": "sha512-ZCuvfwOwlz/bawvAuvcj8rrithP2/N55Tzz342AkTvq4qaWbGfmCk/tKhNaV2cthijKrPAA8SRJV5WWe7IBMJw==", + "version": "7.26.4", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.26.4.tgz", + "integrity": "sha512-fH+b7Y4p3yqvApJALCPJcwb0/XaOSgtK4pzV6WVjPR5GLFQBRI7pfoX2V2iM48NXvX07NUxxm1Vw98YjqTcU5w==", "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.25.9", - "@babel/generator": "^7.25.9", - "@babel/parser": "^7.25.9", + "@babel/code-frame": "^7.26.2", + "@babel/generator": "^7.26.3", + "@babel/parser": "^7.26.3", "@babel/template": "^7.25.9", - "@babel/types": "^7.25.9", + "@babel/types": "^7.26.3", "debug": "^4.3.1", "globals": "^11.1.0" }, @@ -424,9 +420,9 @@ } }, "node_modules/@babel/types": { - "version": "7.26.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.26.0.tgz", - "integrity": "sha512-Z/yiTPj+lDVnF7lWeKCIJzaIkI0vYO87dMpZ4bg4TDrFe4XXLFWL1TbXU27gBP3QccxV9mZICCrnjnYlJjXHOA==", + "version": "7.26.3", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.26.3.tgz", + "integrity": "sha512-vN5p+1kl59GVKMvTHt55NzzmYVxprfJD+ql7U9NFIfKCBkYE55LYtS+WtPlaYOyzydrKI8Nezd+aZextrd+FMA==", "license": "MIT", "dependencies": { "@babel/helper-string-parser": "^7.25.9", @@ -483,30 +479,6 @@ "node": ">=6" } }, - "node_modules/@cspotcode/source-map-support": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", - "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@jridgewell/trace-mapping": "0.3.9" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", - "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@jridgewell/resolve-uri": "^3.0.3", - "@jridgewell/sourcemap-codec": "^1.4.10" - } - }, "node_modules/@emotion/babel-plugin": { "version": "11.13.5", "resolved": "https://registry.npmjs.org/@emotion/babel-plugin/-/babel-plugin-11.13.5.tgz", @@ -548,9 +520,9 @@ } }, "node_modules/@emotion/cache": { - "version": "11.13.5", - "resolved": "https://registry.npmjs.org/@emotion/cache/-/cache-11.13.5.tgz", - "integrity": "sha512-Z3xbtJ+UcK76eWkagZ1onvn/wAVb1GOMuR15s30Fm2wrMgC7jzpnO2JZXr4eujTTqoQFUrZIw/rT0c6Zzjca1g==", + "version": "11.14.0", + "resolved": "https://registry.npmjs.org/@emotion/cache/-/cache-11.14.0.tgz", + "integrity": "sha512-L/B1lc/TViYk4DcpGxtAVbx0ZyiKM5ktoIyafGkH6zg/tj+mA+NE//aPYKG0k8kCHSHVJrpLpcAlOBEXQ3SavA==", "license": "MIT", "dependencies": { "@emotion/memoize": "^0.9.0", @@ -588,16 +560,16 @@ "license": "MIT" }, "node_modules/@emotion/react": { - "version": "11.13.5", - "resolved": "https://registry.npmjs.org/@emotion/react/-/react-11.13.5.tgz", - "integrity": "sha512-6zeCUxUH+EPF1s+YF/2hPVODeV/7V07YU5x+2tfuRL8MdW6rv5vb2+CBEGTGwBdux0OIERcOS+RzxeK80k2DsQ==", + "version": "11.14.0", + "resolved": "https://registry.npmjs.org/@emotion/react/-/react-11.14.0.tgz", + "integrity": "sha512-O000MLDBDdk/EohJPFUqvnp4qnHeYkVP5B0xEG0D/L7cOKP9kefu2DXn8dj74cQfsEzUqh+sr1RzFqiL1o+PpA==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.18.3", "@emotion/babel-plugin": "^11.13.5", - "@emotion/cache": "^11.13.5", + "@emotion/cache": "^11.14.0", "@emotion/serialize": "^1.3.3", - "@emotion/use-insertion-effect-with-fallbacks": "^1.1.0", + "@emotion/use-insertion-effect-with-fallbacks": "^1.2.0", "@emotion/utils": "^1.4.2", "@emotion/weak-memoize": "^0.4.0", "hoist-non-react-statics": "^3.3.1" @@ -643,9 +615,9 @@ "license": "MIT" }, "node_modules/@emotion/use-insertion-effect-with-fallbacks": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@emotion/use-insertion-effect-with-fallbacks/-/use-insertion-effect-with-fallbacks-1.1.0.tgz", - "integrity": "sha512-+wBOcIV5snwGgI2ya3u99D7/FJquOIniQT1IKyDsBmEgwvpxMNeS65Oib7OnE2d2aY+3BU4OiH+0Wchf8yk3Hw==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@emotion/use-insertion-effect-with-fallbacks/-/use-insertion-effect-with-fallbacks-1.2.0.tgz", + "integrity": "sha512-yJMtVdH59sxi/aVJBpk9FQq+OR8ll5GT8oWd57UpeaKEVGab41JWaCFA7FRLoMLloOZF/c/wsPoe+bfGmRKgDg==", "license": "MIT", "peerDependencies": { "react": ">=16.8.0" @@ -664,9 +636,9 @@ "license": "MIT" }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.24.0.tgz", + "integrity": "sha512-WtKdFM7ls47zkKHFVzMz8opM7LkcsIp9amDUBIAWirg70RM71WRSjdILPsY5Uv1D42ZpUfaPILDlfactHgsRkw==", "cpu": [ "ppc64" ], @@ -677,13 +649,13 @@ "aix" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.24.0.tgz", + "integrity": "sha512-arAtTPo76fJ/ICkXWetLCc9EwEHKaeya4vMrReVlEIUCAUncH7M4bhMQ+M9Vf+FFOZJdTNMXNBrWwW+OXWpSew==", "cpu": [ "arm" ], @@ -694,13 +666,13 @@ "android" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.24.0.tgz", + "integrity": "sha512-Vsm497xFM7tTIPYK9bNTYJyF/lsP590Qc1WxJdlB6ljCbdZKU9SY8i7+Iin4kyhV/KV5J2rOKsBQbB77Ab7L/w==", "cpu": [ "arm64" ], @@ -711,13 +683,13 @@ "android" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.24.0.tgz", + "integrity": "sha512-t8GrvnFkiIY7pa7mMgJd7p8p8qqYIz1NYiAoKc75Zyv73L3DZW++oYMSHPRarcotTKuSs6m3hTOa5CKHaS02TQ==", "cpu": [ "x64" ], @@ -728,13 +700,13 @@ "android" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.24.0.tgz", + "integrity": "sha512-CKyDpRbK1hXwv79soeTJNHb5EiG6ct3efd/FTPdzOWdbZZfGhpbcqIpiD0+vwmpu0wTIL97ZRPZu8vUt46nBSw==", "cpu": [ "arm64" ], @@ -745,13 +717,13 @@ "darwin" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "node_modules/@esbuild/darwin-x64": { - "version": "0.21.5", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", - "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.24.0.tgz", + "integrity": "sha512-rgtz6flkVkh58od4PwTRqxbKH9cOjaXCMZgWD905JOzjFKW+7EiUObfd/Kav+A6Gyud6WZk9w+xu6QLytdi2OA==", "cpu": [ "x64" ], @@ -762,13 +734,13 @@ "darwin" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.24.0.tgz", + "integrity": "sha512-6Mtdq5nHggwfDNLAHkPlyLBpE5L6hwsuXZX8XNmHno9JuL2+bg2BX5tRkwjyfn6sKbxZTq68suOjgWqCicvPXA==", "cpu": [ "arm64" ], @@ -779,13 +751,13 @@ "freebsd" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.24.0.tgz", + "integrity": "sha512-D3H+xh3/zphoX8ck4S2RxKR6gHlHDXXzOf6f/9dbFt/NRBDIE33+cVa49Kil4WUjxMGW0ZIYBYtaGCa2+OsQwQ==", "cpu": [ "x64" ], @@ -796,13 +768,13 @@ "freebsd" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.24.0.tgz", + "integrity": "sha512-gJKIi2IjRo5G6Glxb8d3DzYXlxdEj2NlkixPsqePSZMhLudqPhtZ4BUrpIuTjJYXxvF9njql+vRjB2oaC9XpBw==", "cpu": [ "arm" ], @@ -813,13 +785,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.24.0.tgz", + "integrity": "sha512-TDijPXTOeE3eaMkRYpcy3LarIg13dS9wWHRdwYRnzlwlA370rNdZqbcp0WTyyV/k2zSxfko52+C7jU5F9Tfj1g==", "cpu": [ "arm64" ], @@ -830,13 +802,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.24.0.tgz", + "integrity": "sha512-K40ip1LAcA0byL05TbCQ4yJ4swvnbzHscRmUilrmP9Am7//0UjPreh4lpYzvThT2Quw66MhjG//20mrufm40mA==", "cpu": [ "ia32" ], @@ -847,13 +819,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.24.0.tgz", + "integrity": "sha512-0mswrYP/9ai+CU0BzBfPMZ8RVm3RGAN/lmOMgW4aFUSOQBjA31UP8Mr6DDhWSuMwj7jaWOT0p0WoZ6jeHhrD7g==", "cpu": [ "loong64" ], @@ -864,13 +836,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.24.0.tgz", + "integrity": "sha512-hIKvXm0/3w/5+RDtCJeXqMZGkI2s4oMUGj3/jM0QzhgIASWrGO5/RlzAzm5nNh/awHE0A19h/CvHQe6FaBNrRA==", "cpu": [ "mips64el" ], @@ -881,13 +853,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.24.0.tgz", + "integrity": "sha512-HcZh5BNq0aC52UoocJxaKORfFODWXZxtBaaZNuN3PUX3MoDsChsZqopzi5UupRhPHSEHotoiptqikjN/B77mYQ==", "cpu": [ "ppc64" ], @@ -898,13 +870,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.24.0.tgz", + "integrity": "sha512-bEh7dMn/h3QxeR2KTy1DUszQjUrIHPZKyO6aN1X4BCnhfYhuQqedHaa5MxSQA/06j3GpiIlFGSsy1c7Gf9padw==", "cpu": [ "riscv64" ], @@ -915,13 +887,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.24.0.tgz", + "integrity": "sha512-ZcQ6+qRkw1UcZGPyrCiHHkmBaj9SiCD8Oqd556HldP+QlpUIe2Wgn3ehQGVoPOvZvtHm8HPx+bH20c9pvbkX3g==", "cpu": [ "s390x" ], @@ -932,13 +904,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.24.0.tgz", + "integrity": "sha512-vbutsFqQ+foy3wSSbmjBXXIJ6PL3scghJoM8zCL142cGaZKAdCZHyf+Bpu/MmX9zT9Q0zFBVKb36Ma5Fzfa8xA==", "cpu": [ "x64" ], @@ -949,13 +921,13 @@ "linux" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.24.0.tgz", + "integrity": "sha512-hjQ0R/ulkO8fCYFsG0FZoH+pWgTTDreqpqY7UnQntnaKv95uP5iW3+dChxnx7C3trQQU40S+OgWhUVwCjVFLvg==", "cpu": [ "x64" ], @@ -966,13 +938,30 @@ "netbsd" ], "engines": { - "node": ">=12" + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.24.0.tgz", + "integrity": "sha512-MD9uzzkPQbYehwcN583yx3Tu5M8EIoTD+tUgKF982WYL9Pf5rKy9ltgD0eUgs8pvKnmizxjXZyLt0z6DC3rRXg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.24.0.tgz", + "integrity": "sha512-4ir0aY1NGUhIC1hdoCzr1+5b43mw99uNwVzhIq1OY3QcEwPDO3B7WNXBzaKY5Nsf1+N11i1eOfFcq+D/gOS15Q==", "cpu": [ "x64" ], @@ -983,13 +972,13 @@ "openbsd" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.24.0.tgz", + "integrity": "sha512-jVzdzsbM5xrotH+W5f1s+JtUy1UWgjU0Cf4wMvffTB8m6wP5/kx0KiaLHlbJO+dMgtxKV8RQ/JvtlFcdZ1zCPA==", "cpu": [ "x64" ], @@ -1000,13 +989,13 @@ "sunos" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.24.0.tgz", + "integrity": "sha512-iKc8GAslzRpBytO2/aN3d2yb2z8XTVfNV0PjGlCxKo5SgWmNXx82I/Q3aG1tFfS+A2igVCY97TJ8tnYwpUWLCA==", "cpu": [ "arm64" ], @@ -1017,13 +1006,13 @@ "win32" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.24.0.tgz", + "integrity": "sha512-vQW36KZolfIudCcTnaTpmLQ24Ha1RjygBo39/aLkM2kmjkWmZGEJ5Gn9l5/7tzXA42QGIoWbICfg6KLLkIw6yw==", "cpu": [ "ia32" ], @@ -1034,13 +1023,13 @@ "win32" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "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==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.24.0.tgz", + "integrity": "sha512-7IAFPrjSQIJrGsK6flwg7NFmwBoSTyF3rl7If0hNUFQU4ilTsEPL6GuMuU9BfIWVVGuRnuIidkSMC+c0Otu8IA==", "cpu": [ "x64" ], @@ -1051,7 +1040,7 @@ "win32" ], "engines": { - "node": ">=12" + "node": ">=18" } }, "node_modules/@eslint-community/eslint-utils": { @@ -1084,13 +1073,13 @@ } }, "node_modules/@eslint/config-array": { - "version": "0.19.0", - "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.19.0.tgz", - "integrity": "sha512-zdHg2FPIFNKPdcHWtiNT+jEFCHYVplAXRDlQDyqy0zGx/q2parwh7brGJSiTxRk/TSMkbM//zt/f5CHgyTyaSQ==", + "version": "0.19.1", + "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.19.1.tgz", + "integrity": "sha512-fo6Mtm5mWyKjA/Chy1BYTdn5mGJoDNjC7C64ug20ADsRDGrA85bN3uK3MaKbeRkRuuIEAR5N33Jr1pbm411/PA==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@eslint/object-schema": "^2.1.4", + "@eslint/object-schema": "^2.1.5", "debug": "^4.3.1", "minimatch": "^3.1.2" }, @@ -1123,11 +1112,14 @@ } }, "node_modules/@eslint/core": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.9.0.tgz", - "integrity": "sha512-7ATR9F0e4W85D/0w7cU0SNj7qkAexMG+bAHEZOjo9akvGuhHE2m7umzWzfnpa0XAg5Kxc1BWmtPMV67jJ+9VUg==", + "version": "0.9.1", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.9.1.tgz", + "integrity": "sha512-GuUdqkyyzQI5RMIWkHhvTWLCyLo1jNK3vzkSyaExH5kHPDHcuL2VOpHjmMY+y3+NC69qAKToBqldTBgYeLSr9Q==", "dev": true, "license": "Apache-2.0", + "dependencies": { + "@types/json-schema": "^7.0.15" + }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } @@ -1194,9 +1186,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.15.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.15.0.tgz", - "integrity": "sha512-tMTqrY+EzbXmKJR5ToI8lxu7jaN5EdmrBFJpQk5JmSlyLsx6o4t27r883K5xsLuCYCpfKBCGswMSWXsM+jB7lg==", + "version": "9.17.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.17.0.tgz", + "integrity": "sha512-Sxc4hqcs1kTu0iID3kcZDW3JHq2a77HO9P8CP6YEA/FpH3Ll8UXE2r/86Rz9YJLKme39S9vU5OWNjC6Xl0Cr3w==", "dev": true, "license": "MIT", "engines": { @@ -1204,9 +1196,9 @@ } }, "node_modules/@eslint/object-schema": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.4.tgz", - "integrity": "sha512-BsWiH1yFGjXXS2yvrf5LyuoSIIbPrGUWob917o+BTKuZ7qJdxX8aJLRxs1fS9n6r7vESrq1OUqb68dANcFXuQQ==", + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.5.tgz", + "integrity": "sha512-o0bhxnL89h5Bae5T318nFoFzGy+YE5i/gGkoPAgkmTVdRKTiv3p8JHevPiPaMwoloKfEiiaHlawCqaZMqRm+XQ==", "dev": true, "license": "Apache-2.0", "engines": { @@ -1214,9 +1206,9 @@ } }, "node_modules/@eslint/plugin-kit": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.2.3.tgz", - "integrity": "sha512-2b/g5hRmpbb1o4GnTZax9N9m0FXzz9OV42ZzI4rDDMDuHUqigAiQCEWChBWCY4ztAGVRjoWT19v0yMmc5/L5kA==", + "version": "0.2.4", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.2.4.tgz", + "integrity": "sha512-zSkKow6H5Kdm0ZUQUB2kV5JIXqoG0+uH5YADhaEHswm664N9Db8dXSi0nMJpacpMf+MyyglF1vnZohpEg5yUtg==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -1235,12 +1227,6 @@ "@floating-ui/utils": "^0.2.8" } }, - "node_modules/@floating-ui/core/node_modules/@floating-ui/utils": { - "version": "0.2.8", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz", - "integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig==", - "license": "MIT" - }, "node_modules/@floating-ui/dom": { "version": "1.6.12", "resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.6.12.tgz", @@ -1251,21 +1237,14 @@ "@floating-ui/utils": "^0.2.8" } }, - "node_modules/@floating-ui/dom/node_modules/@floating-ui/utils": { - "version": "0.2.8", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz", - "integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig==", - "license": "MIT" - }, "node_modules/@floating-ui/react": { - "version": "0.25.4", - "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.25.4.tgz", - "integrity": "sha512-lWRQ/UiTvSIBxohn0/2HFHEmnmOVRjl7j6XcRJuLH0ls6f/9AyHMWVzkAJFuwx0n9gaEeCmg9VccCSCJzbEJig==", - "dev": true, + "version": "0.24.1", + "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.24.1.tgz", + "integrity": "sha512-qjCKUZDEz/4bnJmu4gn66TqsoX912/re8JGEi3pXazsphmyh327l0UpTgpBAT3WkNbnzAH7Adt3wKlLMNtfupw==", "license": "MIT", "dependencies": { - "@floating-ui/react-dom": "^2.0.2", - "@floating-ui/utils": "^0.1.1", + "@floating-ui/react-dom": "^2.0.0", + "aria-hidden": "^1.1.3", "tabbable": "^6.0.1" }, "peerDependencies": { @@ -1287,10 +1266,9 @@ } }, "node_modules/@floating-ui/utils": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.6.tgz", - "integrity": "sha512-OfX7E2oUDYxtBvsuS4e/jSn4Q9Qb6DzgeYtsAdkPZ47znpoNsMgZw0+tVijiv3uGNR6dgNlty6r9rzIzHjtd/A==", - "dev": true, + "version": "0.2.8", + "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz", + "integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig==", "license": "MIT" }, "node_modules/@grafana/faro-core": { @@ -1446,13 +1424,13 @@ } }, "node_modules/@inquirer/confirm": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/@inquirer/confirm/-/confirm-5.0.2.tgz", - "integrity": "sha512-KJLUHOaKnNCYzwVbryj3TNBxyZIrr56fR5N45v6K9IPrbT6B7DcudBMfylkV1A8PUdJE15mybkEQyp2/ZUpxUA==", + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@inquirer/confirm/-/confirm-5.1.0.tgz", + "integrity": "sha512-osaBbIMEqVFjTX5exoqPXs6PilWQdjaLhGtMDXMXg/yxkHXNq43GlxGyTA35lK2HpzUgDN+Cjh/2AmqCN0QJpw==", "dev": true, "license": "MIT", "dependencies": { - "@inquirer/core": "^10.1.0", + "@inquirer/core": "^10.1.1", "@inquirer/type": "^3.0.1" }, "engines": { @@ -1463,9 +1441,9 @@ } }, "node_modules/@inquirer/core": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/@inquirer/core/-/core-10.1.0.tgz", - "integrity": "sha512-I+ETk2AL+yAVbvuKx5AJpQmoaWhpiTFOg/UJb7ZkMAK4blmtG8ATh5ct+T/8xNld0CZG/2UhtkdMwpgvld92XQ==", + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/@inquirer/core/-/core-10.1.1.tgz", + "integrity": "sha512-rmZVXy9iZvO3ZStEe/ayuuwIJ23LSF13aPMlLMTQARX6lGUBDHGV8UB5i9MRrfy0+mZwt5/9bdy8llszSD3NQA==", "dev": true, "license": "MIT", "dependencies": { @@ -1507,9 +1485,9 @@ } }, "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", - "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", + "version": "0.3.8", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.8.tgz", + "integrity": "sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA==", "license": "MIT", "dependencies": { "@jridgewell/set-array": "^1.2.1", @@ -1634,9 +1612,9 @@ } }, "node_modules/@mswjs/interceptors": { - "version": "0.37.1", - "resolved": "https://registry.npmjs.org/@mswjs/interceptors/-/interceptors-0.37.1.tgz", - "integrity": "sha512-SvE+tSpcX884RJrPCskXxoS965Ky/pYABDEhWW6oeSRhpUDLrS5nTvT5n1LLSDVDYvty4imVmXsy+3/ROVuknA==", + "version": "0.37.3", + "resolved": "https://registry.npmjs.org/@mswjs/interceptors/-/interceptors-0.37.3.tgz", + "integrity": "sha512-USvgCL/uOGFtVa6SVyRrC8kIAedzRohxIXN5LISlg5C5vLZCn7dgMFVSNhSF9cuBEFrm/O2spDWEZeMnw4ZXYg==", "dev": true, "license": "MIT", "dependencies": { @@ -1652,16 +1630,16 @@ } }, "node_modules/@navikt/aksel-icons": { - "version": "7.5.3", - "resolved": "https://npm.pkg.github.com/download/@navikt/aksel-icons/7.5.3/8b07f7fd834d42300df49884d2c672f0b607ce90", - "integrity": "sha512-N4uaddfmZMp4Xm6h/WprY+8O7io9KwDX167h+o2/97ySN0zbcPxDyskWKjwplOlZg/SjoVuY45M/xqlkUa6byg==", + "version": "7.8.0", + "resolved": "https://npm.pkg.github.com/download/@navikt/aksel-icons/7.8.0/14f477c1a7b0ffff50549a31b46a372280e33393", + "integrity": "sha512-QyzmaZLARky/6/8M6FIHi5U5KsZt5ya+foJmeaB44IFCKIuNlSsE6LIe5KS7+Jozb7SX6OCMh5e4pohZXOrdOA==", "dev": true, "license": "MIT" }, "node_modules/@navikt/ds-css": { - "version": "7.5.3", - "resolved": "https://npm.pkg.github.com/download/@navikt/ds-css/7.5.3/e8fd9ed4df8d2306188ffbab0c18a79fa6bd5ce8", - "integrity": "sha512-S1Eg1/4D8FZmEhZq6S0iCy6PvOm+a36SJ5H+d+yMatdEZmGezwy/wzAMr97uWXhmtFpCS6HOG/Ns8VNFX0hm4g==", + "version": "7.8.0", + "resolved": "https://npm.pkg.github.com/download/@navikt/ds-css/7.8.0/83ea0bd43951a10294c1a14dd6ead3d7dc678ea5", + "integrity": "sha512-8CVEZSyoNkqrnT5n2ifl4Xt5sQoujSW90CvRRypIDP4RU3lHc3bYWjghW1LixFdC1uVjorfv93CoT9M5NeYY/Q==", "dev": true, "license": "MIT" }, @@ -1683,16 +1661,16 @@ } }, "node_modules/@navikt/ds-react": { - "version": "7.5.3", - "resolved": "https://npm.pkg.github.com/download/@navikt/ds-react/7.5.3/2b1cf3562099ed426afd36a826a96e4a299160a7", - "integrity": "sha512-dVV4ED2nulCSpONs41Lc3RuGEuE+eg8VMNPVTuedwhwEp8HeFE4wl0ACqOgbFGlQ+xDsF11O3cqioPZBqxgAUg==", + "version": "7.8.0", + "resolved": "https://npm.pkg.github.com/download/@navikt/ds-react/7.8.0/fb24f0fd5066d6cf9504ac9cb7c7a7aee5f6e5aa", + "integrity": "sha512-1u9zTAOSZur9hpuJGXEpsH5tOQtD7EO6TFvVkO4ogEVXk5v7BmaBUw8YVsCQRCh+uAulNQDt2YZ/LiSbdBAo3A==", "dev": true, "license": "MIT", "dependencies": { "@floating-ui/react": "0.25.4", "@floating-ui/react-dom": "^2.0.9", - "@navikt/aksel-icons": "^7.5.3", - "@navikt/ds-tokens": "^7.5.3", + "@navikt/aksel-icons": "^7.8.0", + "@navikt/ds-tokens": "^7.8.0", "clsx": "^2.1.0", "date-fns": "^3.0.0", "react-day-picker": "8.10.1" @@ -1719,21 +1697,6 @@ "react": "^17.0.0 || ^18.0.0" } }, - "node_modules/@navikt/ds-react-internal/node_modules/@floating-ui/react": { - "version": "0.24.1", - "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.24.1.tgz", - "integrity": "sha512-qjCKUZDEz/4bnJmu4gn66TqsoX912/re8JGEi3pXazsphmyh327l0UpTgpBAT3WkNbnzAH7Adt3wKlLMNtfupw==", - "license": "MIT", - "dependencies": { - "@floating-ui/react-dom": "^2.0.0", - "aria-hidden": "^1.1.3", - "tabbable": "^6.0.1" - }, - "peerDependencies": { - "react": ">=16.8.0", - "react-dom": ">=16.8.0" - } - }, "node_modules/@navikt/ds-react-internal/node_modules/@navikt/aksel-icons": { "version": "3.4.2", "resolved": "https://npm.pkg.github.com/download/@navikt/aksel-icons/3.4.2/fa858e1a5fb0557d61b62ad7cdf0d75e26fc89d7", @@ -1815,6 +1778,29 @@ "react-dom": "^0.14.0 || ^15.0.0 || ^16 || ^17 || ^18" } }, + "node_modules/@navikt/ds-react/node_modules/@floating-ui/react": { + "version": "0.25.4", + "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.25.4.tgz", + "integrity": "sha512-lWRQ/UiTvSIBxohn0/2HFHEmnmOVRjl7j6XcRJuLH0ls6f/9AyHMWVzkAJFuwx0n9gaEeCmg9VccCSCJzbEJig==", + "dev": true, + "license": "MIT", + "dependencies": { + "@floating-ui/react-dom": "^2.0.2", + "@floating-ui/utils": "^0.1.1", + "tabbable": "^6.0.1" + }, + "peerDependencies": { + "react": ">=16.8.0", + "react-dom": ">=16.8.0" + } + }, + "node_modules/@navikt/ds-react/node_modules/@floating-ui/utils": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.6.tgz", + "integrity": "sha512-OfX7E2oUDYxtBvsuS4e/jSn4Q9Qb6DzgeYtsAdkPZ47znpoNsMgZw0+tVijiv3uGNR6dgNlty6r9rzIzHjtd/A==", + "dev": true, + "license": "MIT" + }, "node_modules/@navikt/ds-react/node_modules/date-fns": { "version": "3.6.0", "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.6.0.tgz", @@ -1842,9 +1828,9 @@ } }, "node_modules/@navikt/ds-tokens": { - "version": "7.5.3", - "resolved": "https://npm.pkg.github.com/download/@navikt/ds-tokens/7.5.3/ffe7aaadb5c9d0993842cdb6c1c6acd862a31014", - "integrity": "sha512-iuwpmXM/cBCc9W4898nLnRV7qOuPN3f7pl3tkeirEyjBS8elIV/WEqKhQjaCkT+aVC7lEHzZ5nkC5MDQcjWicg==", + "version": "7.8.0", + "resolved": "https://npm.pkg.github.com/download/@navikt/ds-tokens/7.8.0/a80bf0c47ac30716094ad0ad18d5fc0ffbb00fcb", + "integrity": "sha512-QgZS7hOODkC+T2jsbmh2KIjjMDGoZlBB/KYNJcIz22oXTiXHHmiV1kLUxdVa3lebGxXOGxL+o6sbyWAFvMblMA==", "dev": true, "license": "MIT" }, @@ -1959,12 +1945,12 @@ } }, "node_modules/@opentelemetry/core": { - "version": "1.28.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/core/-/core-1.28.0.tgz", - "integrity": "sha512-ZLwRMV+fNDpVmF2WYUdBHlq0eOWtEaUJSusrzjGnBt7iSRvfjFE3RXYUZJrqou/wIDWV0DwQ5KIfYe9WXg9Xqw==", + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/core/-/core-1.30.0.tgz", + "integrity": "sha512-Q/3u/K73KUjTCnFUP97ZY+pBjQ1kPEgjOfXj/bJl8zW7GbXdkw6cwuyZk6ZTXkVgCBsYRYUzx4fvYK1jxdb9MA==", "license": "Apache-2.0", "dependencies": { - "@opentelemetry/semantic-conventions": "1.27.0" + "@opentelemetry/semantic-conventions": "1.28.0" }, "engines": { "node": ">=14" @@ -1973,15 +1959,6 @@ "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, - "node_modules/@opentelemetry/core/node_modules/@opentelemetry/semantic-conventions": { - "version": "1.27.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz", - "integrity": "sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg==", - "license": "Apache-2.0", - "engines": { - "node": ">=14" - } - }, "node_modules/@opentelemetry/exporter-trace-otlp-http": { "version": "0.53.0", "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-http/-/exporter-trace-otlp-http-0.53.0.tgz", @@ -2281,13 +2258,13 @@ } }, "node_modules/@opentelemetry/resources": { - "version": "1.28.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/resources/-/resources-1.28.0.tgz", - "integrity": "sha512-cIyXSVJjGeTICENN40YSvLDAq4Y2502hGK3iN7tfdynQLKWb3XWZQEkPc+eSx47kiy11YeFAlYkEfXwR1w8kfw==", + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/resources/-/resources-1.30.0.tgz", + "integrity": "sha512-5mGMjL0Uld/99t7/pcd7CuVtJbkARckLVuiOX84nO8RtLtIz0/J6EOHM2TGvPZ6F4K+XjUq13gMx14w80SVCQg==", "license": "Apache-2.0", "dependencies": { - "@opentelemetry/core": "1.28.0", - "@opentelemetry/semantic-conventions": "1.27.0" + "@opentelemetry/core": "1.30.0", + "@opentelemetry/semantic-conventions": "1.28.0" }, "engines": { "node": ">=14" @@ -2296,15 +2273,6 @@ "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, - "node_modules/@opentelemetry/resources/node_modules/@opentelemetry/semantic-conventions": { - "version": "1.27.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz", - "integrity": "sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg==", - "license": "Apache-2.0", - "engines": { - "node": ">=14" - } - }, "node_modules/@opentelemetry/sdk-logs": { "version": "0.53.0", "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-logs/-/sdk-logs-0.53.0.tgz", @@ -2476,14 +2444,14 @@ } }, "node_modules/@opentelemetry/sdk-trace-web": { - "version": "1.28.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-web/-/sdk-trace-web-1.28.0.tgz", - "integrity": "sha512-/QOIrJc/A/caKbA9voLua4isf///cjQKB6gomEzX2fL18TBqZhIkm9k2DpjlbtrQoYCJDZ9x7Phrec22aQGpQw==", + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-web/-/sdk-trace-web-1.30.0.tgz", + "integrity": "sha512-tSsPbaOQqmkfSkRkMnv1T8au2hwlv3v5ZUGmRwc7zIL1hokhZKg5qhqTsvrWvRENlZ7+J9+cXZFKIMNKHodyhQ==", "license": "Apache-2.0", "dependencies": { - "@opentelemetry/core": "1.28.0", - "@opentelemetry/sdk-trace-base": "1.28.0", - "@opentelemetry/semantic-conventions": "1.27.0" + "@opentelemetry/core": "1.30.0", + "@opentelemetry/sdk-trace-base": "1.30.0", + "@opentelemetry/semantic-conventions": "1.28.0" }, "engines": { "node": ">=14" @@ -2493,14 +2461,14 @@ } }, "node_modules/@opentelemetry/sdk-trace-web/node_modules/@opentelemetry/sdk-trace-base": { - "version": "1.28.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.28.0.tgz", - "integrity": "sha512-ceUVWuCpIao7Y5xE02Xs3nQi0tOGmMea17ecBdwtCvdo9ekmO+ijc9RFDgfifMl7XCBf41zne/1POM3LqSTZDA==", + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.30.0.tgz", + "integrity": "sha512-RKQDaDIkV7PwizmHw+rE/FgfB2a6MBx+AEVVlAHXRG1YYxLiBpPX2KhmoB99R5vA4b72iJrjle68NDWnbrE9Dg==", "license": "Apache-2.0", "dependencies": { - "@opentelemetry/core": "1.28.0", - "@opentelemetry/resources": "1.28.0", - "@opentelemetry/semantic-conventions": "1.27.0" + "@opentelemetry/core": "1.30.0", + "@opentelemetry/resources": "1.30.0", + "@opentelemetry/semantic-conventions": "1.28.0" }, "engines": { "node": ">=14" @@ -2509,15 +2477,6 @@ "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, - "node_modules/@opentelemetry/sdk-trace-web/node_modules/@opentelemetry/semantic-conventions": { - "version": "1.27.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz", - "integrity": "sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg==", - "license": "Apache-2.0", - "engines": { - "node": ">=14" - } - }, "node_modules/@opentelemetry/semantic-conventions": { "version": "1.28.0", "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.28.0.tgz", @@ -2852,13 +2811,13 @@ } }, "node_modules/@playwright/test": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.49.0.tgz", - "integrity": "sha512-DMulbwQURa8rNIQrf94+jPJQ4FmOVdpE5ZppRNvWVjvhC+6sOeo28r8MgIpQRYouXRtt/FCCXU7zn20jnHR4Qw==", + "version": "1.49.1", + "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.49.1.tgz", + "integrity": "sha512-Ky+BVzPz8pL6PQxHqNRW1k3mIyv933LML7HktS8uik0bUXNCdPhoS/kLihiO1tMf/egaJb4IutXd7UywvXEW+g==", "dev": true, "license": "Apache-2.0", "dependencies": { - "playwright": "1.49.0" + "playwright": "1.49.1" }, "bin": { "playwright": "cli.js" @@ -3200,9 +3159,9 @@ } }, "node_modules/@rc-component/trigger": { - "version": "2.2.5", - "resolved": "https://registry.npmjs.org/@rc-component/trigger/-/trigger-2.2.5.tgz", - "integrity": "sha512-F1EJ4KjFpGAHAjuKvOyZB/6IZDkVx0bHl0M4fQM5wXcmm7lgTgVSSnR3bXwdmS6jOJGHOqfDxIJW3WUvwMIXhQ==", + "version": "2.2.6", + "resolved": "https://registry.npmjs.org/@rc-component/trigger/-/trigger-2.2.6.tgz", + "integrity": "sha512-/9zuTnWwhQ3S3WT1T8BubuFTT46kvnXgaERR9f4BTKyn61/wpf/BvbImzYBubzJibU707FxwbKszLlHjcLiv1Q==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.23.2", @@ -3210,7 +3169,7 @@ "classnames": "^2.3.2", "rc-motion": "^2.0.0", "rc-resize-observer": "^1.3.1", - "rc-util": "^5.38.0" + "rc-util": "^5.44.0" }, "engines": { "node": ">=8.x" @@ -3220,24 +3179,10 @@ "react-dom": ">=16.9.0" } }, - "node_modules/@redux-devtools/extension": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/@redux-devtools/extension/-/extension-3.3.0.tgz", - "integrity": "sha512-X34S/rC8S/M1BIrkYD1mJ5f8vlH0BDqxXrs96cvxSBo4FhMdbhU+GUGsmNYov1xjSyLMHgo8NYrUG8bNX7525g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/runtime": "^7.23.2", - "immutable": "^4.3.4" - }, - "peerDependencies": { - "redux": "^3.1.0 || ^4.0.0 || ^5.0.0" - } - }, "node_modules/@reduxjs/toolkit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@reduxjs/toolkit/-/toolkit-2.3.0.tgz", - "integrity": "sha512-WC7Yd6cNGfHx8zf+iu+Q1UPTfEcXhQ+ATi7CV1hlrSAaQBdlPzg7Ww/wJHNQem7qG9rxmWoFCDCPubSvFObGzA==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/@reduxjs/toolkit/-/toolkit-2.5.0.tgz", + "integrity": "sha512-awNe2oTodsZ6LmRqmkFhtb/KH03hUhxOamEQy411m3Njj3BbFvoBovxo4Q1cBWnV1ErprVj9MlF0UPXkng0eyg==", "dev": true, "license": "MIT", "dependencies": { @@ -3247,7 +3192,7 @@ "reselect": "^5.1.0" }, "peerDependencies": { - "react": "^16.9.0 || ^17.0.0 || ^18", + "react": "^16.9.0 || ^17.0.0 || ^18 || ^19", "react-redux": "^7.2.1 || ^8.1.3 || ^9.0.0" }, "peerDependenciesMeta": { @@ -3269,9 +3214,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.27.4.tgz", - "integrity": "sha512-2Y3JT6f5MrQkICUyRVCw4oa0sutfAsgaSsb0Lmmy1Wi2y7X5vT9Euqw4gOsCyy0YfKURBg35nhUKZS4mDcfULw==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.28.1.tgz", + "integrity": "sha512-2aZp8AES04KI2dy3Ss6/MDjXbwBzj+i0GqKtWXgw2/Ma6E4jJvujryO6gJAghIRVz7Vwr9Gtl/8na3nDUKpraQ==", "cpu": [ "arm" ], @@ -3283,9 +3228,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.27.4.tgz", - "integrity": "sha512-wzKRQXISyi9UdCVRqEd0H4cMpzvHYt1f/C3CoIjES6cG++RHKhrBj2+29nPF0IB5kpy9MS71vs07fvrNGAl/iA==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.28.1.tgz", + "integrity": "sha512-EbkK285O+1YMrg57xVA+Dp0tDBRB93/BZKph9XhMjezf6F4TpYjaUSuPt5J0fZXlSag0LmZAsTmdGGqPp4pQFA==", "cpu": [ "arm64" ], @@ -3297,9 +3242,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.27.4.tgz", - "integrity": "sha512-PlNiRQapift4LNS8DPUHuDX/IdXiLjf8mc5vdEmUR0fF/pyy2qWwzdLjB+iZquGr8LuN4LnUoSEvKRwjSVYz3Q==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.28.1.tgz", + "integrity": "sha512-prduvrMKU6NzMq6nxzQw445zXgaDBbMQvmKSJaxpaZ5R1QDM8w+eGxo6Y/jhT/cLoCvnZI42oEqf9KQNYz1fqQ==", "cpu": [ "arm64" ], @@ -3311,9 +3256,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.27.4.tgz", - "integrity": "sha512-o9bH2dbdgBDJaXWJCDTNDYa171ACUdzpxSZt+u/AAeQ20Nk5x+IhA+zsGmrQtpkLiumRJEYef68gcpn2ooXhSQ==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.28.1.tgz", + "integrity": "sha512-WsvbOunsUk0wccO/TV4o7IKgloJ942hVFK1CLatwv6TJspcCZb9umQkPdvB7FihmdxgaKR5JyxDjWpCOp4uZlQ==", "cpu": [ "x64" ], @@ -3325,9 +3270,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.27.4.tgz", - "integrity": "sha512-NBI2/i2hT9Q+HySSHTBh52da7isru4aAAo6qC3I7QFVsuhxi2gM8t/EI9EVcILiHLj1vfi+VGGPaLOUENn7pmw==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.28.1.tgz", + "integrity": "sha512-HTDPdY1caUcU4qK23FeeGxCdJF64cKkqajU0iBnTVxS8F7H/7BewvYoG+va1KPSL63kQ1PGNyiwKOfReavzvNA==", "cpu": [ "arm64" ], @@ -3339,9 +3284,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.27.4.tgz", - "integrity": "sha512-wYcC5ycW2zvqtDYrE7deary2P2UFmSh85PUpAx+dwTCO9uw3sgzD6Gv9n5X4vLaQKsrfTSZZ7Z7uynQozPVvWA==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.28.1.tgz", + "integrity": "sha512-m/uYasxkUevcFTeRSM9TeLyPe2QDuqtjkeoTpP9SW0XxUWfcYrGDMkO/m2tTw+4NMAF9P2fU3Mw4ahNvo7QmsQ==", "cpu": [ "x64" ], @@ -3353,9 +3298,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.27.4.tgz", - "integrity": "sha512-9OwUnK/xKw6DyRlgx8UizeqRFOfi9mf5TYCw1uolDaJSbUmBxP85DE6T4ouCMoN6pXw8ZoTeZCSEfSaYo+/s1w==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.28.1.tgz", + "integrity": "sha512-QAg11ZIt6mcmzpNE6JZBpKfJaKkqTm1A9+y9O+frdZJEuhQxiugM05gnCWiANHj4RmbgeVJpTdmKRmH/a+0QbA==", "cpu": [ "arm" ], @@ -3367,9 +3312,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.27.4.tgz", - "integrity": "sha512-Vgdo4fpuphS9V24WOV+KwkCVJ72u7idTgQaBoLRD0UxBAWTF9GWurJO9YD9yh00BzbkhpeXtm6na+MvJU7Z73A==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.28.1.tgz", + "integrity": "sha512-dRP9PEBfolq1dmMcFqbEPSd9VlRuVWEGSmbxVEfiq2cs2jlZAl0YNxFzAQS2OrQmsLBLAATDMb3Z6MFv5vOcXg==", "cpu": [ "arm" ], @@ -3381,9 +3326,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.27.4.tgz", - "integrity": "sha512-pleyNgyd1kkBkw2kOqlBx+0atfIIkkExOTiifoODo6qKDSpnc6WzUY5RhHdmTdIJXBdSnh6JknnYTtmQyobrVg==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.28.1.tgz", + "integrity": "sha512-uGr8khxO+CKT4XU8ZUH1TTEUtlktK6Kgtv0+6bIFSeiSlnGJHG1tSFSjm41uQ9sAO/5ULx9mWOz70jYLyv1QkA==", "cpu": [ "arm64" ], @@ -3395,9 +3340,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.27.4.tgz", - "integrity": "sha512-caluiUXvUuVyCHr5DxL8ohaaFFzPGmgmMvwmqAITMpV/Q+tPoaHZ/PWa3t8B2WyoRcIIuu1hkaW5KkeTDNSnMA==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.28.1.tgz", + "integrity": "sha512-QF54q8MYGAqMLrX2t7tNpi01nvq5RI59UBNx+3+37zoKX5KViPo/gk2QLhsuqok05sSCRluj0D00LzCwBikb0A==", "cpu": [ "arm64" ], @@ -3408,10 +3353,24 @@ "linux" ] }, + "node_modules/@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.28.1.tgz", + "integrity": "sha512-vPul4uodvWvLhRco2w0GcyZcdyBfpfDRgNKU+p35AWEbJ/HPs1tOUrkSueVbBS0RQHAf/A+nNtDpvw95PeVKOA==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.27.4.tgz", - "integrity": "sha512-FScrpHrO60hARyHh7s1zHE97u0KlT/RECzCKAdmI+LEoC1eDh/RDji9JgFqyO+wPDb86Oa/sXkily1+oi4FzJQ==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.28.1.tgz", + "integrity": "sha512-pTnTdBuC2+pt1Rmm2SV7JWRqzhYpEILML4PKODqLz+C7Ou2apEV52h19CR7es+u04KlqplggmN9sqZlekg3R1A==", "cpu": [ "ppc64" ], @@ -3423,9 +3382,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.27.4.tgz", - "integrity": "sha512-qyyprhyGb7+RBfMPeww9FlHwKkCXdKHeGgSqmIXw9VSUtvyFZ6WZRtnxgbuz76FK7LyoN8t/eINRbPUcvXB5fw==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.28.1.tgz", + "integrity": "sha512-vWXy1Nfg7TPBSuAncfInmAI/WZDd5vOklyLJDdIRKABcZWojNDY0NJwruY2AcnCLnRJKSaBgf/GiJfauu8cQZA==", "cpu": [ "riscv64" ], @@ -3437,9 +3396,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.27.4.tgz", - "integrity": "sha512-PFz+y2kb6tbh7m3A7nA9++eInGcDVZUACulf/KzDtovvdTizHpZaJty7Gp0lFwSQcrnebHOqxF1MaKZd7psVRg==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.28.1.tgz", + "integrity": "sha512-/yqC2Y53oZjb0yz8PVuGOQQNOTwxcizudunl/tFs1aLvObTclTwZ0JhXF2XcPT/zuaymemCDSuuUPXJJyqeDOg==", "cpu": [ "s390x" ], @@ -3451,9 +3410,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.27.4.tgz", - "integrity": "sha512-Ni8mMtfo+o/G7DVtweXXV/Ol2TFf63KYjTtoZ5f078AUgJTmaIJnj4JFU7TK/9SVWTaSJGxPi5zMDgK4w+Ez7Q==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.28.1.tgz", + "integrity": "sha512-fzgeABz7rrAlKYB0y2kSEiURrI0691CSL0+KXwKwhxvj92VULEDQLpBYLHpF49MSiPG4sq5CK3qHMnb9tlCjBw==", "cpu": [ "x64" ], @@ -3465,9 +3424,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.27.4.tgz", - "integrity": "sha512-5AeeAF1PB9TUzD+3cROzFTnAJAcVUGLuR8ng0E0WXGkYhp6RD6L+6szYVX+64Rs0r72019KHZS1ka1q+zU/wUw==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.28.1.tgz", + "integrity": "sha512-xQTDVzSGiMlSshpJCtudbWyRfLaNiVPXt1WgdWTwWz9n0U12cI2ZVtWe/Jgwyv/6wjL7b66uu61Vg0POWVfz4g==", "cpu": [ "x64" ], @@ -3479,9 +3438,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.27.4.tgz", - "integrity": "sha512-yOpVsA4K5qVwu2CaS3hHxluWIK5HQTjNV4tWjQXluMiiiu4pJj4BN98CvxohNCpcjMeTXk/ZMJBRbgRg8HBB6A==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.28.1.tgz", + "integrity": "sha512-wSXmDRVupJstFP7elGMgv+2HqXelQhuNf+IS4V+nUpNVi/GUiBgDmfwD0UGN3pcAnWsgKG3I52wMOBnk1VHr/A==", "cpu": [ "arm64" ], @@ -3493,9 +3452,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.27.4.tgz", - "integrity": "sha512-KtwEJOaHAVJlxV92rNYiG9JQwQAdhBlrjNRp7P9L8Cb4Rer3in+0A+IPhJC9y68WAi9H0sX4AiG2NTsVlmqJeQ==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.28.1.tgz", + "integrity": "sha512-ZkyTJ/9vkgrE/Rk9vhMXhf8l9D+eAhbAVbsGsXKy2ohmJaWg0LPQLnIxRdRp/bKyr8tXuPlXhIoGlEB5XpJnGA==", "cpu": [ "ia32" ], @@ -3507,9 +3466,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.27.4.tgz", - "integrity": "sha512-3j4jx1TppORdTAoBJRd+/wJRGCPC0ETWkXOecJ6PPZLj6SptXkrXcNqdj0oclbKML6FkQltdz7bBA3rUSirZug==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.28.1.tgz", + "integrity": "sha512-ZvK2jBafvttJjoIdKm/Q/Bh7IJ1Ose9IBOwpOXcOvW3ikGTQGmKDgxTC6oCAzW6PynbkKP8+um1du81XJHZ0JA==", "cpu": [ "x64" ], @@ -3542,9 +3501,9 @@ } }, "node_modules/@testing-library/react": { - "version": "16.0.1", - "resolved": "https://registry.npmjs.org/@testing-library/react/-/react-16.0.1.tgz", - "integrity": "sha512-dSmwJVtJXmku+iocRhWOUFbrERC76TX2Mnf0ATODz8brzAZrMBbzLwQixlBSanZxR6LddK3eiwpSFZgDET1URg==", + "version": "16.1.0", + "resolved": "https://registry.npmjs.org/@testing-library/react/-/react-16.1.0.tgz", + "integrity": "sha512-Q2ToPvg0KsVL0ohND9A3zLJWcOXXcO8IDu3fj11KhNt0UlCWyFyvnCIBkd12tidB2lkiVRG8VFqdhcqhqnAQtg==", "dev": true, "license": "MIT", "dependencies": { @@ -3555,10 +3514,10 @@ }, "peerDependencies": { "@testing-library/dom": "^10.0.0", - "@types/react": "^18.0.0", - "@types/react-dom": "^18.0.0", - "react": "^18.0.0", - "react-dom": "^18.0.0" + "@types/react": "^18.0.0 || ^19.0.0", + "@types/react-dom": "^18.0.0 || ^19.0.0", + "react": "^18.0.0 || ^19.0.0", + "react-dom": "^18.0.0 || ^19.0.0" }, "peerDependenciesMeta": { "@types/react": { @@ -3569,34 +3528,6 @@ } } }, - "node_modules/@tsconfig/node10": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.11.tgz", - "integrity": "sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@tsconfig/node12": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", - "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", - "dev": true, - "license": "MIT" - }, - "node_modules/@tsconfig/node14": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", - "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", - "dev": true, - "license": "MIT" - }, - "node_modules/@tsconfig/node16": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", - "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", - "dev": true, - "license": "MIT" - }, "node_modules/@types/aria-query": { "version": "5.0.4", "resolved": "https://registry.npmjs.org/@types/aria-query/-/aria-query-5.0.4.tgz", @@ -3681,9 +3612,9 @@ "license": "MIT" }, "node_modules/@types/hoist-non-react-statics": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/@types/hoist-non-react-statics/-/hoist-non-react-statics-3.3.5.tgz", - "integrity": "sha512-SbcrWzkKBw2cdwRTwQAswfpB9g9LJWfjtUeW/jvNwbhC8cpmmNYVePa+ncbUe0rGTQ7G3Ff6mYUN2VMfLVr+Sg==", + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/@types/hoist-non-react-statics/-/hoist-non-react-statics-3.3.6.tgz", + "integrity": "sha512-lPByRJUer/iN/xa4qpyL0qmL11DqNW81iU/IG1S3uvRUq4oKagz8VCxZjiWkumgt66YT3vOdDgZ0o32sGKtCEw==", "dev": true, "license": "MIT", "dependencies": { @@ -3711,13 +3642,23 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/lodash-es": { + "version": "4.17.12", + "resolved": "https://registry.npmjs.org/@types/lodash-es/-/lodash-es-4.17.12.tgz", + "integrity": "sha512-0NgftHUcV4v34VhXm8QBSftKVXtbkBG3ViCjs6+eJ5a6y6Mi/jiFGPc1sC7QK+9BFhWrURE3EOggmWaSxL9OzQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/lodash": "*" + } + }, "node_modules/@types/node": { - "version": "22.9.3", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.9.3.tgz", - "integrity": "sha512-F3u1fs/fce3FFk+DAxbxc78DF8x0cY09RRL8GnXLmkJ1jvx3TtPdWoTT5/NiYfI5ASqXBmfqJi9dZ3gxMx4lzw==", + "version": "22.10.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.2.tgz", + "integrity": "sha512-Xxr6BBRCAOQixvonOye19wnzyDiUtTeqldOOmj3CkeblonbccA12PFwlufvRdrpjXxqnmUaeiU5EOA+7s5diUQ==", "license": "MIT", "dependencies": { - "undici-types": "~6.19.8" + "undici-types": "~6.20.0" } }, "node_modules/@types/parse-json": { @@ -3727,75 +3668,29 @@ "license": "MIT" }, "node_modules/@types/prop-types": { - "version": "15.7.13", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.13.tgz", - "integrity": "sha512-hCZTSvwbzWGvhqxp/RqVqwU999pBf2vp7hzIjiYOsl8wqOmUxkQ6ddw1cV3l8811+kdUFus/q4d1Y3E3SyEifA==", + "version": "15.7.14", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.14.tgz", + "integrity": "sha512-gNMvNH49DJ7OJYv+KAKn0Xp45p8PLl6zo2YnvDIbTd4J6MER2BmWN49TG7n9LvkyihINxeKW8+3bfS2yDC9dzQ==", "license": "MIT" }, "node_modules/@types/react": { - "version": "18.3.12", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.12.tgz", - "integrity": "sha512-D2wOSq/d6Agt28q7rSI3jhU7G6aiuzljDGZ2hTZHIkrTLUI+AF3WMeKkEZ9nN2fkBAlcktT6vcZjDFiIhMYEQw==", + "version": "18.3.17", + "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.17.tgz", + "integrity": "sha512-opAQ5no6LqJNo9TqnxBKsgnkIYHozW9KSTlFVoSUJYh1Fl/sswkEoqIugRSm7tbh6pABtYjGAjW+GOS23j8qbw==", "license": "MIT", "dependencies": { "@types/prop-types": "*", "csstype": "^3.0.2" } }, - "node_modules/@types/react-datepicker": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/@types/react-datepicker/-/react-datepicker-6.2.0.tgz", - "integrity": "sha512-+JtO4Fm97WLkJTH8j8/v3Ldh7JCNRwjMYjRaKh4KHH0M3jJoXtwiD3JBCsdlg3tsFIw9eQSqyAPeVDN2H2oM9Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@floating-ui/react": "^0.26.2", - "@types/react": "*", - "date-fns": "^3.3.1" - } - }, - "node_modules/@types/react-datepicker/node_modules/@floating-ui/react": { - "version": "0.26.28", - "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.26.28.tgz", - "integrity": "sha512-yORQuuAtVpiRjpMhdc0wJj06b9JFjrYF4qp96j++v2NBpbi6SEGF7donUJ3TMieerQ6qVkAv1tgr7L4r5roTqw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@floating-ui/react-dom": "^2.1.2", - "@floating-ui/utils": "^0.2.8", - "tabbable": "^6.0.0" - }, - "peerDependencies": { - "react": ">=16.8.0", - "react-dom": ">=16.8.0" - } - }, - "node_modules/@types/react-datepicker/node_modules/@floating-ui/utils": { - "version": "0.2.8", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz", - "integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/react-datepicker/node_modules/date-fns": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.6.0.tgz", - "integrity": "sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww==", - "dev": true, - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/kossnocorp" - } - }, "node_modules/@types/react-dom": { - "version": "18.3.1", - "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-18.3.1.tgz", - "integrity": "sha512-qW1Mfv8taImTthu4KoXgDfLuk4bydU6Q/TkADnDWWHwi4NX4BR+LWfTp2sVmTqRrsHvyDDTelgelxJ+SsejKKQ==", + "version": "18.3.5", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-18.3.5.tgz", + "integrity": "sha512-P4t6saawp+b/dFrUr2cvkVsfvPguwsxtH6dNIYRllMsefqFzkZk5UIjzyDOv5g1dXIPdG4Sp1yCR4Z6RCUsG/Q==", "dev": true, "license": "MIT", - "dependencies": { - "@types/react": "*" + "peerDependencies": { + "@types/react": "^18.0.0" } }, "node_modules/@types/react-highlight-words": { @@ -3865,11 +3760,11 @@ } }, "node_modules/@types/react-transition-group": { - "version": "4.4.11", - "resolved": "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.11.tgz", - "integrity": "sha512-RM05tAniPZ5DZPzzNFP+DmrcOdD0efDUxMy3145oljWSl3x9ZV5vhme98gTxFrj2lhXvmGNnUiuDyJgY9IKkNA==", + "version": "4.4.12", + "resolved": "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.12.tgz", + "integrity": "sha512-8TV6R3h2j7a91c+1DXdJi3Syo69zzIZbz7Lg5tORM5LEJG7X/E6a1V3drRyBRZq7/utz7A+c4OgYLiLcYGHG6w==", "license": "MIT", - "dependencies": { + "peerDependencies": { "@types/react": "*" } }, @@ -3923,24 +3818,24 @@ "license": "MIT" }, "node_modules/@types/use-sync-external-store": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/@types/use-sync-external-store/-/use-sync-external-store-0.0.3.tgz", - "integrity": "sha512-EwmlvuaxPNej9+T4v5AuBPJa2x2UOJVdjCtDHgcDqitUeOtjnJKJ+apYjVcAoBEMjKW1VVFGZLUb5+qqa09XFA==", + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/@types/use-sync-external-store/-/use-sync-external-store-0.0.6.tgz", + "integrity": "sha512-zFDAD+tlpf2r4asuHEj0XH6pY6i0g5NeAHPn+15wk3BV6JA69eERFXC1gyGThDkVa1zCyKr5jox1+2LbV/AMLg==", "dev": true, "license": "MIT" }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.15.0.tgz", - "integrity": "sha512-+zkm9AR1Ds9uLWN3fkoeXgFppaQ+uEVtfOV62dDmsy9QCNqlRHWNEck4yarvRNrvRcHQLGfqBNui3cimoz8XAg==", + "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, "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.15.0", - "@typescript-eslint/type-utils": "8.15.0", - "@typescript-eslint/utils": "8.15.0", - "@typescript-eslint/visitor-keys": "8.15.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", @@ -3955,25 +3850,21 @@ }, "peerDependencies": { "@typescript-eslint/parser": "^8.0.0 || ^8.0.0-alpha.0", - "eslint": "^8.57.0 || ^9.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" } }, "node_modules/@typescript-eslint/parser": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.15.0.tgz", - "integrity": "sha512-7n59qFpghG4uazrF9qtGKBZXn7Oz4sOMm8dwNWDQY96Xlm2oX67eipqcblDj+oY1lLCbf1oltMZFpUso66Kl1A==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.18.1.tgz", + "integrity": "sha512-rBnTWHCdbYM2lh7hjyXqxk70wvon3p2FyaniZuey5TrcGBpfhVp0OxOa6gxr9Q9YhZFKyfbEnxc24ZnVbbUkCA==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "8.15.0", - "@typescript-eslint/types": "8.15.0", - "@typescript-eslint/typescript-estree": "8.15.0", - "@typescript-eslint/visitor-keys": "8.15.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": { @@ -3984,23 +3875,19 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.15.0.tgz", - "integrity": "sha512-QRGy8ADi4J7ii95xz4UoiymmmMd/zuy9azCaamnZ3FM8T5fZcex8UfJcjkiEZjJSztKfEBe3dZ5T/5RHAmw2mA==", + "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, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.15.0", - "@typescript-eslint/visitor-keys": "8.15.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" @@ -4011,14 +3898,14 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.15.0.tgz", - "integrity": "sha512-UU6uwXDoI3JGSXmcdnP5d8Fffa2KayOhUUqr/AiBnG1Gl7+7ut/oyagVeSkh7bxQ0zSXV9ptRh/4N15nkCqnpw==", + "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, "license": "MIT", "dependencies": { - "@typescript-eslint/typescript-estree": "8.15.0", - "@typescript-eslint/utils": "8.15.0", + "@typescript-eslint/typescript-estree": "8.18.1", + "@typescript-eslint/utils": "8.18.1", "debug": "^4.3.4", "ts-api-utils": "^1.3.0" }, @@ -4030,18 +3917,14 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" } }, "node_modules/@typescript-eslint/types": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.15.0.tgz", - "integrity": "sha512-n3Gt8Y/KyJNe0S3yDCD2RVKrHBC4gTUcLTebVBXacPy091E6tNspFLKRXlk3hwT4G55nfr1n2AdFqi/XMxzmPQ==", + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.18.1.tgz", + "integrity": "sha512-7uoAUsCj66qdNQNpH2G8MyTFlgerum8ubf21s3TSM3XmKXuIn+H2Sifh/ES2nPOPiYSRJWAk0fDkW0APBWcpfw==", "dev": true, "license": "MIT", "engines": { @@ -4053,14 +3936,14 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.15.0.tgz", - "integrity": "sha512-1eMp2JgNec/niZsR7ioFBlsh/Fk0oJbhaqO0jRyQBMgkz7RrFfkqF9lYYmBoGBaSiLnu8TAPQTwoTUiSTUW9dg==", + "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, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.15.0", - "@typescript-eslint/visitor-keys": "8.15.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", @@ -4075,23 +3958,21 @@ "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "peerDependencies": { + "typescript": ">=4.8.4 <5.8.0" } }, "node_modules/@typescript-eslint/utils": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.15.0.tgz", - "integrity": "sha512-k82RI9yGhr0QM3Dnq+egEpz9qB6Un+WLYhmoNcvl8ltMEededhh7otBVVIDDsEEttauwdY/hQoSsOv13lxrFzQ==", + "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, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.4.0", - "@typescript-eslint/scope-manager": "8.15.0", - "@typescript-eslint/types": "8.15.0", - "@typescript-eslint/typescript-estree": "8.15.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" @@ -4101,22 +3982,18 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.15.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.15.0.tgz", - "integrity": "sha512-h8vYOulWec9LhpwfAdZf2bjr8xIp0KNKnpgqSz0qqYYKAW/QZKw3ktRndbiAtUz4acH4QLQavwZBYCc0wulA/Q==", + "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, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.15.0", + "@typescript-eslint/types": "8.18.1", "eslint-visitor-keys": "^4.2.0" }, "engines": { @@ -4141,15 +4018,15 @@ } }, "node_modules/@vitejs/plugin-react": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-4.3.3.tgz", - "integrity": "sha512-NooDe9GpHGqNns1i8XDERg0Vsg5SSYRhRxxyTGogUdkdNt47jal+fbuYi+Yfq6pzRCKXyoPcWisfxE6RIM3GKA==", + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-4.3.4.tgz", + "integrity": "sha512-SCCPBJtYLdE8PX/7ZQAs1QAZ8Jqwih+0VBLum1EGqmCCQal+MIUqLCzj3ZUy8ufbC0cAM4LRlSTm7IQJwWT4ug==", "dev": true, "license": "MIT", "dependencies": { - "@babel/core": "^7.25.2", - "@babel/plugin-transform-react-jsx-self": "^7.24.7", - "@babel/plugin-transform-react-jsx-source": "^7.24.7", + "@babel/core": "^7.26.0", + "@babel/plugin-transform-react-jsx-self": "^7.25.9", + "@babel/plugin-transform-react-jsx-source": "^7.25.9", "@types/babel__core": "^7.20.5", "react-refresh": "^0.14.2" }, @@ -4157,18 +4034,18 @@ "node": "^14.18.0 || >=16.0.0" }, "peerDependencies": { - "vite": "^4.2.0 || ^5.0.0" + "vite": "^4.2.0 || ^5.0.0 || ^6.0.0" } }, "node_modules/@vitest/expect": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-2.1.5.tgz", - "integrity": "sha512-nZSBTW1XIdpZvEJyoP/Sy8fUg0b8od7ZpGDkTUcfJ7wz/VoZAFzFfLyxVxGFhUjJzhYqSbIpfMtl/+k/dpWa3Q==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-2.1.8.tgz", + "integrity": "sha512-8ytZ/fFHq2g4PJVAtDX57mayemKgDR6X3Oa2Foro+EygiOJHUXhCqBAAKQYYajZpFoIfvBCF1j6R6IYRSIUFuw==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/spy": "2.1.5", - "@vitest/utils": "2.1.5", + "@vitest/spy": "2.1.8", + "@vitest/utils": "2.1.8", "chai": "^5.1.2", "tinyrainbow": "^1.2.0" }, @@ -4176,37 +4053,10 @@ "url": "https://opencollective.com/vitest" } }, - "node_modules/@vitest/mocker": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-2.1.5.tgz", - "integrity": "sha512-XYW6l3UuBmitWqSUXTNXcVBUCRytDogBsWuNXQijc00dtnU/9OqpXWp4OJroVrad/gLIomAq9aW8yWDBtMthhQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/spy": "2.1.5", - "estree-walker": "^3.0.3", - "magic-string": "^0.30.12" - }, - "funding": { - "url": "https://opencollective.com/vitest" - }, - "peerDependencies": { - "msw": "^2.4.9", - "vite": "^5.0.0" - }, - "peerDependenciesMeta": { - "msw": { - "optional": true - }, - "vite": { - "optional": true - } - } - }, "node_modules/@vitest/pretty-format": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-2.1.5.tgz", - "integrity": "sha512-4ZOwtk2bqG5Y6xRGHcveZVr+6txkH7M2e+nPFd6guSoN638v/1XQ0K06eOpi0ptVU/2tW/pIU4IoPotY/GZ9fw==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-2.1.8.tgz", + "integrity": "sha512-9HiSZ9zpqNLKlbIDRWOnAWqgcA7xu+8YxXSekhr0Ykab7PAYFkhkwoqVArPOtJhPmYeE2YHgKZlj3CP36z2AJQ==", "dev": true, "license": "MIT", "dependencies": { @@ -4217,13 +4067,13 @@ } }, "node_modules/@vitest/runner": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-2.1.5.tgz", - "integrity": "sha512-pKHKy3uaUdh7X6p1pxOkgkVAFW7r2I818vHDthYLvUyjRfkKOU6P45PztOch4DZarWQne+VOaIMwA/erSSpB9g==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-2.1.8.tgz", + "integrity": "sha512-17ub8vQstRnRlIU5k50bG+QOMLHRhYPAna5tw8tYbj+jzjcspnwnwtPtiOlkuKC4+ixDPTuLZiqiWWQ2PSXHVg==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/utils": "2.1.5", + "@vitest/utils": "2.1.8", "pathe": "^1.1.2" }, "funding": { @@ -4231,13 +4081,13 @@ } }, "node_modules/@vitest/snapshot": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-2.1.5.tgz", - "integrity": "sha512-zmYw47mhfdfnYbuhkQvkkzYroXUumrwWDGlMjpdUr4jBd3HZiV2w7CQHj+z7AAS4VOtWxI4Zt4bWt4/sKcoIjg==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-2.1.8.tgz", + "integrity": "sha512-20T7xRFbmnkfcmgVEz+z3AU/3b0cEzZOt/zmnvZEctg64/QZbSDJEVm9fLnnlSi74KibmRsO9/Qabi+t0vCRPg==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "2.1.5", + "@vitest/pretty-format": "2.1.8", "magic-string": "^0.30.12", "pathe": "^1.1.2" }, @@ -4246,9 +4096,9 @@ } }, "node_modules/@vitest/spy": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-2.1.5.tgz", - "integrity": "sha512-aWZF3P0r3w6DiYTVskOYuhBc7EMc3jvn1TkBg8ttylFFRqNN2XGD7V5a4aQdk6QiUzZQ4klNBSpCLJgWNdIiNw==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-2.1.8.tgz", + "integrity": "sha512-5swjf2q95gXeYPevtW0BLk6H8+bPlMb4Vw/9Em4hFxDcaOxS+e0LOX4yqNxoHzMR2akEB2xfpnWUzkZokmgWDg==", "dev": true, "license": "MIT", "dependencies": { @@ -4259,13 +4109,13 @@ } }, "node_modules/@vitest/ui": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/ui/-/ui-2.1.5.tgz", - "integrity": "sha512-ERgKkDMTfngrZip6VG5h8L9B5D0AH/4+bga4yR1UzGH7c2cxv3LWogw2Dvuwr9cP3/iKDHYys7kIFLDKpxORTg==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/ui/-/ui-2.1.8.tgz", + "integrity": "sha512-5zPJ1fs0ixSVSs5+5V2XJjXLmNzjugHRyV11RqxYVR+oMcogZ9qTuSfKW+OcTV0JeFNznI83BNylzH6SSNJ1+w==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/utils": "2.1.5", + "@vitest/utils": "2.1.8", "fflate": "^0.8.2", "flatted": "^3.3.1", "pathe": "^1.1.2", @@ -4277,17 +4127,17 @@ "url": "https://opencollective.com/vitest" }, "peerDependencies": { - "vitest": "2.1.5" + "vitest": "2.1.8" } }, "node_modules/@vitest/utils": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-2.1.5.tgz", - "integrity": "sha512-yfj6Yrp0Vesw2cwJbP+cl04OC+IHFsuQsrsJBL9pyGeQXE56v1UAOQco+SR55Vf1nQzfV0QJg1Qum7AaWUwwYg==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-2.1.8.tgz", + "integrity": "sha512-dwSoui6djdwbfFmIgbIjX2ZhIoG7Ex/+xpxyiEgIGzjliY8xGkcpITKTlp6B4MgtGkF2ilvm97cPM96XZaAgcA==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "2.1.5", + "@vitest/pretty-format": "2.1.8", "loupe": "^3.1.2", "tinyrainbow": "^1.2.0" }, @@ -4340,28 +4190,12 @@ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/acorn-walk": { - "version": "8.3.4", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.4.tgz", - "integrity": "sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==", - "dev": true, - "license": "MIT", - "dependencies": { - "acorn": "^8.11.0" - }, - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/agent-base": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.1.tgz", - "integrity": "sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==", + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.3.tgz", + "integrity": "sha512-jRR5wdylq8CkOe6hei19GGZnxM6rBGwFl3Bg0YItGDimvjGtAvdZk4Pu6Cl4u4Igsws4a1fd1Vq3ezrhn4KmFw==", "dev": true, "license": "MIT", - "dependencies": { - "debug": "^4.3.4" - }, "engines": { "node": ">= 14" } @@ -4462,13 +4296,6 @@ "node": ">=10" } }, - "node_modules/arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true, - "license": "MIT" - }, "node_modules/argparse": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", @@ -4559,16 +4386,16 @@ } }, "node_modules/array.prototype.flat": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.2.tgz", - "integrity": "sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==", + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.3.tgz", + "integrity": "sha512-rwG/ja1neyLqCuGZ5YYrznA62D4mZXg0i1cIskIUKSiqF3Cje9/wXAls9B9s1Wa2fomMsIv8czB8jZcPmxCXFg==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0" + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-shim-unscopables": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -4578,16 +4405,16 @@ } }, "node_modules/array.prototype.flatmap": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.2.tgz", - "integrity": "sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==", + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.3.tgz", + "integrity": "sha512-Y7Wt51eKJSyi80hFrJCePGGNo5ktJCslFuboqJsbf57CCPcm5zztluPlc4/aD8sWsKvlwatezpV4U1efk8kpjg==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0" + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-shim-unscopables": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -4614,20 +4441,19 @@ } }, "node_modules/arraybuffer.prototype.slice": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.3.tgz", - "integrity": "sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.4.tgz", + "integrity": "sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ==", "dev": true, "license": "MIT", "dependencies": { "array-buffer-byte-length": "^1.0.1", - "call-bind": "^1.0.5", + "call-bind": "^1.0.8", "define-properties": "^1.2.1", - "es-abstract": "^1.22.3", - "es-errors": "^1.2.1", - "get-intrinsic": "^1.2.3", - "is-array-buffer": "^3.0.4", - "is-shared-array-buffer": "^1.0.2" + "es-abstract": "^1.23.5", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6", + "is-array-buffer": "^3.0.4" }, "engines": { "node": ">= 0.4" @@ -4679,9 +4505,9 @@ } }, "node_modules/axios": { - "version": "1.7.7", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.7.tgz", - "integrity": "sha512-S4kL7XrjgBmvdGut0sN3yJxqYzrDOnivkBiN0OFs6hLiUam3UPvswUo0kqGyhqUZGEOytHyumEdXsAkgCOUf3Q==", + "version": "1.7.9", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.9.tgz", + "integrity": "sha512-LhLcE7Hbiryz8oMDdDptSrWowmB4Bl6RCt6sIJKpRB4XtVf0iEgewX3au/pJqm+Py1kCASkb/FFKjxQaLtxJvw==", "license": "MIT", "dependencies": { "follow-redirects": "^1.15.6", @@ -4705,12 +4531,12 @@ } }, "node_modules/babel-plugin-macros/node_modules/resolve": { - "version": "1.22.8", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", - "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", + "version": "1.22.9", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.9.tgz", + "integrity": "sha512-QxrmX1DzraFIi9PxdG5VkRfRwIgjwyud+z/iBwfRRrVmHc+P9Q7u2lSSpQ6bjr2gy5lrqIiU9vb6iAeGf2400A==", "license": "MIT", "dependencies": { - "is-core-module": "^2.13.0", + "is-core-module": "^2.16.0", "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" }, @@ -4769,9 +4595,9 @@ } }, "node_modules/browserslist": { - "version": "4.24.2", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.24.2.tgz", - "integrity": "sha512-ZIc+Q62revdMcqC6aChtW4jz3My3klmCO1fEmINZY/8J3EpBg5/A/D0AKmBveUh6pgoeycoMkVMko84tuYS+Gg==", + "version": "4.24.3", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.24.3.tgz", + "integrity": "sha512-1CPmv8iobE2fyRMV97dAcMVegvvWKxmq94hkLiAkUGwKVTyDLw33K+ZxiFrREKmmps4rIw6grcCFCnTMSZ/YiA==", "dev": true, "funding": [ { @@ -4789,9 +4615,9 @@ ], "license": "MIT", "dependencies": { - "caniuse-lite": "^1.0.30001669", - "electron-to-chromium": "^1.5.41", - "node-releases": "^2.0.18", + "caniuse-lite": "^1.0.30001688", + "electron-to-chromium": "^1.5.73", + "node-releases": "^2.0.19", "update-browserslist-db": "^1.1.1" }, "bin": { @@ -4812,17 +4638,47 @@ } }, "node_modules/call-bind": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", - "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", + "integrity": "sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==", "dev": true, "license": "MIT", "dependencies": { + "call-bind-apply-helpers": "^1.0.0", "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.1" + "set-function-length": "^1.2.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/call-bind-apply-helpers": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.1.tgz", + "integrity": "sha512-BhYE+WDaywFg2TBWYNXAE+8B1ATnThNBqXHP5nQu0jWJdVvY2hvkpyB3qOmtmDePiS5/BDQ8wASEWGMWRG148g==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.3.tgz", + "integrity": "sha512-YTd+6wGlNlPxSuri7Y6X8tY2dmm12UMH66RpKMhiX6rsk5wXXnYgbUcOt8kiS31/AjfoTOvCsE+w8nZQLQnzHA==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "get-intrinsic": "^1.2.6" }, "engines": { "node": ">= 0.4" @@ -4850,9 +4706,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001684", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001684.tgz", - "integrity": "sha512-G1LRwLIQjBQoyq0ZJGqGIJUXzJ8irpbjHLpVRXDvBEScFJ9b17sgK6vlx0GAJFE21okD7zXl08rRRUfq6HdoEQ==", + "version": "1.0.30001690", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001690.tgz", + "integrity": "sha512-5ExiE3qQN6oF8Clf8ifIDcMRCRE/dMGcETG/XGMD8/XiXm6HXQgQTh1yZYLXXpSOsEUlJm1Xr7kGULZTuGtP/w==", "dev": true, "funding": [ { @@ -4962,9 +4818,9 @@ } }, "node_modules/chokidar": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.1.tgz", - "integrity": "sha512-n8enUVCED/KVRQlab1hr3MVpcVMvxtZjmEa956u+4YijlmQED223XMSYj2tLuKvr4jcCTzNNMpQDUer72MMmzA==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz", + "integrity": "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==", "dev": true, "license": "MIT", "dependencies": { @@ -5182,6 +5038,15 @@ "node": ">=10" } }, + "node_modules/cosmiconfig/node_modules/yaml": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", + "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "license": "ISC", + "engines": { + "node": ">= 6" + } + }, "node_modules/country-data-list": { "version": "1.3.4", "resolved": "https://registry.npmjs.org/country-data-list/-/country-data-list-1.3.4.tgz", @@ -5191,13 +5056,6 @@ "currency-symbol-map": "~5" } }, - "node_modules/create-require": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", - "dev": true, - "license": "MIT" - }, "node_modules/cross-spawn": { "version": "7.0.6", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", @@ -5352,13 +5210,13 @@ } }, "node_modules/data-view-byte-offset": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.0.tgz", - "integrity": "sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.1.tgz", + "integrity": "sha512-BS8PfmtDGnrgYdOonGZQdLZslWIeCGFP9tpan0hi1Co2Zr2NKADsvGYA8XxuG/4UWgJ6Cjtv+YJnB6MM69QGlQ==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.6", + "call-bound": "^1.0.2", "es-errors": "^1.3.0", "is-data-view": "^1.0.1" }, @@ -5386,9 +5244,9 @@ "license": "MIT" }, "node_modules/debug": { - "version": "4.3.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.7.tgz", - "integrity": "sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==", + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", + "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", "license": "MIT", "dependencies": { "ms": "^2.1.3" @@ -5514,16 +5372,6 @@ "node": ">=8" } }, - "node_modules/diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } - }, "node_modules/doctrine": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", @@ -5571,10 +5419,25 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", + "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/electron-to-chromium": { - "version": "1.5.64", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.64.tgz", - "integrity": "sha512-IXEuxU+5ClW2IGEYFC2T7szbyVgehupCWQe5GNh+H065CD6U6IFN0s4KeAMFGNmQolRU4IV7zGBWSYMmZ8uuqQ==", + "version": "1.5.74", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.74.tgz", + "integrity": "sha512-ck3//9RC+6oss/1Bh9tiAVFy5vfSKbRHAFh7Z3/eTRkEqJeWgymloShB17Vg3Z4nmDNp35vAd1BZ6CMW4Wt6Iw==", "dev": true, "license": "ISC" }, @@ -5631,58 +5494,60 @@ } }, "node_modules/es-abstract": { - "version": "1.23.5", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.5.tgz", - "integrity": "sha512-vlmniQ0WNPwXqA0BnmwV3Ng7HxiGlh6r5U6JcTMNx8OilcAGqVJBHJcPjqOMaczU9fRuRK5Px2BdVyPRnKMMVQ==", + "version": "1.23.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.6.tgz", + "integrity": "sha512-Ifco6n3yj2tMZDWNLyloZrytt9lqqlwvS83P3HtaETR0NUOYnIULGGHpktqYGObGy+8wc1okO25p8TjemhImvA==", "dev": true, "license": "MIT", "dependencies": { "array-buffer-byte-length": "^1.0.1", - "arraybuffer.prototype.slice": "^1.0.3", + "arraybuffer.prototype.slice": "^1.0.4", "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", "data-view-buffer": "^1.0.1", "data-view-byte-length": "^1.0.1", "data-view-byte-offset": "^1.0.0", - "es-define-property": "^1.0.0", + "es-define-property": "^1.0.1", "es-errors": "^1.3.0", "es-object-atoms": "^1.0.0", "es-set-tostringtag": "^2.0.3", - "es-to-primitive": "^1.2.1", - "function.prototype.name": "^1.1.6", - "get-intrinsic": "^1.2.4", + "es-to-primitive": "^1.3.0", + "function.prototype.name": "^1.1.7", + "get-intrinsic": "^1.2.6", "get-symbol-description": "^1.0.2", "globalthis": "^1.0.4", - "gopd": "^1.0.1", + "gopd": "^1.2.0", "has-property-descriptors": "^1.0.2", - "has-proto": "^1.0.3", - "has-symbols": "^1.0.3", + "has-proto": "^1.2.0", + "has-symbols": "^1.1.0", "hasown": "^2.0.2", - "internal-slot": "^1.0.7", + "internal-slot": "^1.1.0", "is-array-buffer": "^3.0.4", "is-callable": "^1.2.7", - "is-data-view": "^1.0.1", + "is-data-view": "^1.0.2", "is-negative-zero": "^2.0.3", - "is-regex": "^1.1.4", + "is-regex": "^1.2.1", "is-shared-array-buffer": "^1.0.3", - "is-string": "^1.0.7", + "is-string": "^1.1.1", "is-typed-array": "^1.1.13", - "is-weakref": "^1.0.2", + "is-weakref": "^1.1.0", + "math-intrinsics": "^1.0.0", "object-inspect": "^1.13.3", "object-keys": "^1.1.1", "object.assign": "^4.1.5", "regexp.prototype.flags": "^1.5.3", - "safe-array-concat": "^1.1.2", - "safe-regex-test": "^1.0.3", - "string.prototype.trim": "^1.2.9", - "string.prototype.trimend": "^1.0.8", + "safe-array-concat": "^1.1.3", + "safe-regex-test": "^1.1.0", + "string.prototype.trim": "^1.2.10", + "string.prototype.trimend": "^1.0.9", "string.prototype.trimstart": "^1.0.8", "typed-array-buffer": "^1.0.2", "typed-array-byte-length": "^1.0.1", - "typed-array-byte-offset": "^1.0.2", - "typed-array-length": "^1.0.6", + "typed-array-byte-offset": "^1.0.3", + "typed-array-length": "^1.0.7", "unbox-primitive": "^1.0.2", - "which-typed-array": "^1.1.15" + "which-typed-array": "^1.1.16" }, "engines": { "node": ">= 0.4" @@ -5692,14 +5557,11 @@ } }, "node_modules/es-define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", - "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", + "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", "dev": true, "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.2.4" - }, "engines": { "node": ">= 0.4" } @@ -5787,15 +5649,15 @@ } }, "node_modules/es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.3.0.tgz", + "integrity": "sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==", "dev": true, "license": "MIT", "dependencies": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" + "is-callable": "^1.2.7", + "is-date-object": "^1.0.5", + "is-symbol": "^1.0.4" }, "engines": { "node": ">= 0.4" @@ -5805,9 +5667,9 @@ } }, "node_modules/esbuild": { - "version": "0.21.5", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", - "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "version": "0.24.0", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.24.0.tgz", + "integrity": "sha512-FuLPevChGDshgSicjisSooU0cemp/sGXR841D5LHMB7mTVOmsEHcAxaH3irL53+8YDIeVNQEySh4DaYU/iuPqQ==", "dev": true, "hasInstallScript": true, "license": "MIT", @@ -5815,32 +5677,33 @@ "esbuild": "bin/esbuild" }, "engines": { - "node": ">=12" + "node": ">=18" }, "optionalDependencies": { - "@esbuild/aix-ppc64": "0.21.5", - "@esbuild/android-arm": "0.21.5", - "@esbuild/android-arm64": "0.21.5", - "@esbuild/android-x64": "0.21.5", - "@esbuild/darwin-arm64": "0.21.5", - "@esbuild/darwin-x64": "0.21.5", - "@esbuild/freebsd-arm64": "0.21.5", - "@esbuild/freebsd-x64": "0.21.5", - "@esbuild/linux-arm": "0.21.5", - "@esbuild/linux-arm64": "0.21.5", - "@esbuild/linux-ia32": "0.21.5", - "@esbuild/linux-loong64": "0.21.5", - "@esbuild/linux-mips64el": "0.21.5", - "@esbuild/linux-ppc64": "0.21.5", - "@esbuild/linux-riscv64": "0.21.5", - "@esbuild/linux-s390x": "0.21.5", - "@esbuild/linux-x64": "0.21.5", - "@esbuild/netbsd-x64": "0.21.5", - "@esbuild/openbsd-x64": "0.21.5", - "@esbuild/sunos-x64": "0.21.5", - "@esbuild/win32-arm64": "0.21.5", - "@esbuild/win32-ia32": "0.21.5", - "@esbuild/win32-x64": "0.21.5" + "@esbuild/aix-ppc64": "0.24.0", + "@esbuild/android-arm": "0.24.0", + "@esbuild/android-arm64": "0.24.0", + "@esbuild/android-x64": "0.24.0", + "@esbuild/darwin-arm64": "0.24.0", + "@esbuild/darwin-x64": "0.24.0", + "@esbuild/freebsd-arm64": "0.24.0", + "@esbuild/freebsd-x64": "0.24.0", + "@esbuild/linux-arm": "0.24.0", + "@esbuild/linux-arm64": "0.24.0", + "@esbuild/linux-ia32": "0.24.0", + "@esbuild/linux-loong64": "0.24.0", + "@esbuild/linux-mips64el": "0.24.0", + "@esbuild/linux-ppc64": "0.24.0", + "@esbuild/linux-riscv64": "0.24.0", + "@esbuild/linux-s390x": "0.24.0", + "@esbuild/linux-x64": "0.24.0", + "@esbuild/netbsd-x64": "0.24.0", + "@esbuild/openbsd-arm64": "0.24.0", + "@esbuild/openbsd-x64": "0.24.0", + "@esbuild/sunos-x64": "0.24.0", + "@esbuild/win32-arm64": "0.24.0", + "@esbuild/win32-ia32": "0.24.0", + "@esbuild/win32-x64": "0.24.0" } }, "node_modules/escalade": { @@ -5866,9 +5729,9 @@ } }, "node_modules/eslint": { - "version": "9.15.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.15.0.tgz", - "integrity": "sha512-7CrWySmIibCgT1Os28lUU6upBshZ+GxybLOrmRzi08kS8MBuO8QA7pXEgYgY5W8vK3e74xv0lpjo9DbaGU9Rkw==", + "version": "9.17.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.17.0.tgz", + "integrity": "sha512-evtlNcpJg+cZLcnVKwsai8fExnqjGPicK7gnUtlNuzu+Fv9bI0aLpND5T44VLQtoMEnI57LoXO9XAkIXwohKrA==", "dev": true, "license": "MIT", "dependencies": { @@ -5877,7 +5740,7 @@ "@eslint/config-array": "^0.19.0", "@eslint/core": "^0.9.0", "@eslint/eslintrc": "^3.2.0", - "@eslint/js": "9.15.0", + "@eslint/js": "9.17.0", "@eslint/plugin-kit": "^0.2.3", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", @@ -5886,7 +5749,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", @@ -6287,9 +6150,9 @@ } }, "node_modules/file-selector": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/file-selector/-/file-selector-2.1.1.tgz", - "integrity": "sha512-pJVY80PuSiHbnYEZ0gZYQf15x0z/lkeIF1yn95yRC/Usb43343ewXtMClQ9GLPvPm4/SscX4zvQz9QhCAyLqlg==", + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/file-selector/-/file-selector-2.1.2.tgz", + "integrity": "sha512-QgXo+mXTe8ljeqUFaX3QVHc5osSItJ/Km+xpocx0aSqWGMSCf6qYs/VnzZgS864Pjn5iceMRFigeAV7AfTlaig==", "dev": true, "license": "MIT", "dependencies": { @@ -6477,16 +6340,17 @@ } }, "node_modules/function.prototype.name": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", - "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.7.tgz", + "integrity": "sha512-2g4x+HqTJKM9zcJqBSpjoRmdcPFtJM60J3xJisTQSXBWka5XqyBN/2tNUgma1mztTXyDuUsEtYe5qcs7xYzYQA==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "functions-have-names": "^1.2.3" + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "functions-have-names": "^1.2.3", + "hasown": "^2.0.2", + "is-callable": "^1.2.7" }, "engines": { "node": ">= 0.4" @@ -6557,17 +6421,22 @@ } }, "node_modules/get-intrinsic": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", - "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.6.tgz", + "integrity": "sha512-qxsEs+9A+u85HhllWJJFicJfPDhRmjzoYdl64aMWW9yRIJmSyxdn8IEkuIM530/7T+lv0TIHd8L6Q/ra0tEoeA==", "dev": true, "license": "MIT", "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "dunder-proto": "^1.0.0", + "es-define-property": "^1.0.1", "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", "function-bind": "^1.1.2", - "has-proto": "^1.0.1", - "has-symbols": "^1.0.3", - "hasown": "^2.0.0" + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.0.0" }, "engines": { "node": ">= 0.4" @@ -6577,15 +6446,15 @@ } }, "node_modules/get-symbol-description": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.2.tgz", - "integrity": "sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.1.0.tgz", + "integrity": "sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.5", + "call-bound": "^1.0.3", "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4" + "get-intrinsic": "^1.2.6" }, "engines": { "node": ">= 0.4" @@ -6690,13 +6559,13 @@ "license": "MIT" }, "node_modules/gopd": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", - "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", + "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", "dev": true, "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.1.3" + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -6718,9 +6587,9 @@ "license": "MIT" }, "node_modules/graphql": { - "version": "16.9.0", - "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.9.0.tgz", - "integrity": "sha512-GGTKBX4SD7Wdb8mqeDLni2oaRGYQWjWHGKPQ24ZMnUtKfcsVoiv4uX8+LJr1K6U5VW2Lu1BwJnj7uiori0YtRw==", + "version": "16.10.0", + "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.10.0.tgz", + "integrity": "sha512-AjqGKbDGUFRKIRCP9tCKiIGHyriz2oHEbPIbEtcSLSs4YjReZOIPQQWek4+6hjw62H9QShXHyaGivGiYVLeYFQ==", "dev": true, "license": "MIT", "engines": { @@ -6728,11 +6597,14 @@ } }, "node_modules/has-bigints": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", - "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.1.0.tgz", + "integrity": "sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==", "dev": true, "license": "MIT", + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -6761,11 +6633,14 @@ } }, "node_modules/has-proto": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", - "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.2.0.tgz", + "integrity": "sha512-KIL7eQPfHQRC8+XluaIw7BHUwwqL19bQn4hzNgdr+1wXoU0KKj6rufu47lhY7KbJR2C6T6+PfyN0Ea7wkSS+qQ==", "dev": true, "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.0" + }, "engines": { "node": ">= 0.4" }, @@ -6774,9 +6649,9 @@ } }, "node_modules/has-symbols": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", - "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", + "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", "dev": true, "license": "MIT", "engines": { @@ -6923,13 +6798,13 @@ } }, "node_modules/https-proxy-agent": { - "version": "7.0.5", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.5.tgz", - "integrity": "sha512-1e4Wqeblerz+tMKPIq2EMGiiWW1dIjZOksyHWSUm1rmuvw/how9hBHZ38lAGj5ID4Ik6EdkOw7NmWPy6LAwalw==", + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", "dev": true, "license": "MIT", "dependencies": { - "agent-base": "^7.0.2", + "agent-base": "^7.1.2", "debug": "4" }, "engines": { @@ -6990,9 +6865,9 @@ } }, "node_modules/immutable": { - "version": "4.3.7", - "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.3.7.tgz", - "integrity": "sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==", + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/immutable/-/immutable-5.0.3.tgz", + "integrity": "sha512-P8IdPQHq3lA1xVeBRi5VPqUm5HDgKnx0Ru51wZz5mjxHr5n3RWhjIpOFU7ybkUxfB+5IToy+OLaHYDBIWsv+uw==", "dev": true, "license": "MIT" }, @@ -7013,9 +6888,9 @@ } }, "node_modules/import-in-the-middle": { - "version": "1.11.2", - "resolved": "https://registry.npmjs.org/import-in-the-middle/-/import-in-the-middle-1.11.2.tgz", - "integrity": "sha512-gK6Rr6EykBcc6cVWRSBR5TWf8nn6hZMYSRYqCcHa0l0d1fPK7JSYo6+Mlmck76jIX9aL/IZ71c06U2VpFwl1zA==", + "version": "1.12.0", + "resolved": "https://registry.npmjs.org/import-in-the-middle/-/import-in-the-middle-1.12.0.tgz", + "integrity": "sha512-yAgSE7GmtRcu4ZUSFX/4v69UGXwugFFSdIQJ14LHPOPPQrWv8Y7O9PHsw8Ovk7bKCLe4sjXMbZFqGFcLHpZ89w==", "license": "Apache-2.0", "dependencies": { "acorn": "^8.8.2", @@ -7065,15 +6940,15 @@ } }, "node_modules/internal-slot": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.7.tgz", - "integrity": "sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.1.0.tgz", + "integrity": "sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==", "dev": true, "license": "MIT", "dependencies": { "es-errors": "^1.3.0", - "hasown": "^2.0.0", - "side-channel": "^1.0.4" + "hasown": "^2.0.2", + "side-channel": "^1.1.0" }, "engines": { "node": ">= 0.4" @@ -7104,14 +6979,15 @@ } }, "node_modules/is-array-buffer": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.4.tgz", - "integrity": "sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.5.tgz", + "integrity": "sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.1" + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "get-intrinsic": "^1.2.6" }, "engines": { "node": ">= 0.4" @@ -7143,27 +7019,30 @@ } }, "node_modules/is-bigint": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", - "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.1.0.tgz", + "integrity": "sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==", "dev": true, "license": "MIT", "dependencies": { - "has-bigints": "^1.0.1" + "has-bigints": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-boolean-object": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", - "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.2.1.tgz", + "integrity": "sha512-l9qO6eFlUETHtuihLcYOaLKByJ1f+N4kthcU9YjHy3N+B3hWv0y/2Nd0mu/7lTFnRQHTrSdXF50HQ3bl5fEnng==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" + "call-bound": "^1.0.2", + "has-tostringtag": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -7186,9 +7065,9 @@ } }, "node_modules/is-core-module": { - "version": "2.15.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.15.1.tgz", - "integrity": "sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==", + "version": "2.16.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.0.tgz", + "integrity": "sha512-urTSINYfAYgcbLb0yDQ6egFm6h3Mo1DcF9EkyXSRjjzdHbsulg01qhwWuXdOoUBuTkbQ80KDboXa0vFJ+BDH+g==", "license": "MIT", "dependencies": { "hasown": "^2.0.2" @@ -7201,12 +7080,14 @@ } }, "node_modules/is-data-view": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.1.tgz", - "integrity": "sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.2.tgz", + "integrity": "sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==", "dev": true, "license": "MIT", "dependencies": { + "call-bound": "^1.0.2", + "get-intrinsic": "^1.2.6", "is-typed-array": "^1.1.13" }, "engines": { @@ -7217,13 +7098,14 @@ } }, "node_modules/is-date-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", - "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.1.0.tgz", + "integrity": "sha512-PwwhEakHVKTdRNVOw+/Gyh0+MzlCl4R6qKvkhuvLtPMggI1WAHt9sOwZxQLSGpUaDnrdyDsomoRgNnCfKNSXXg==", "dev": true, "license": "MIT", "dependencies": { - "has-tostringtag": "^1.0.0" + "call-bound": "^1.0.2", + "has-tostringtag": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -7253,13 +7135,13 @@ } }, "node_modules/is-finalizationregistry": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.1.0.tgz", - "integrity": "sha512-qfMdqbAQEwBw78ZyReKnlA8ezmPdb9BemzIIip/JkjaZUhitfXDkkr+3QTboW0JrSXT1QWyYShpvnNHGZ4c4yA==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.1.1.tgz", + "integrity": "sha512-1pC6N8qWJbWoPtEjgcL2xyhQOP491EQjeUo3qTKcmV8YSDDJrOepfG8pcC7h/QgnQHYSv0mJ3Z/ZWxmatVrysg==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7" + "call-bound": "^1.0.3" }, "engines": { "node": ">= 0.4" @@ -7367,13 +7249,14 @@ } }, "node_modules/is-number-object": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", - "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.1.1.tgz", + "integrity": "sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==", "dev": true, "license": "MIT", "dependencies": { - "has-tostringtag": "^1.0.0" + "call-bound": "^1.0.3", + "has-tostringtag": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -7390,14 +7273,16 @@ "license": "MIT" }, "node_modules/is-regex": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.2.1.tgz", + "integrity": "sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" + "call-bound": "^1.0.2", + "gopd": "^1.2.0", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.2" }, "engines": { "node": ">= 0.4" @@ -7420,13 +7305,13 @@ } }, "node_modules/is-shared-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.3.tgz", - "integrity": "sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.4.tgz", + "integrity": "sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7" + "call-bound": "^1.0.3" }, "engines": { "node": ">= 0.4" @@ -7436,13 +7321,14 @@ } }, "node_modules/is-string": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.1.1.tgz", + "integrity": "sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==", "dev": true, "license": "MIT", "dependencies": { - "has-tostringtag": "^1.0.0" + "call-bound": "^1.0.3", + "has-tostringtag": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -7452,13 +7338,15 @@ } }, "node_modules/is-symbol": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.1.1.tgz", + "integrity": "sha512-9gGx6GTtCQM73BgmHQXfDmLtfjjTUDSyoxTCbp5WtoixAhfgsDirWIcVQ/IHpvI5Vgd5i/J5F7B9cN/WlVbC/w==", "dev": true, "license": "MIT", "dependencies": { - "has-symbols": "^1.0.2" + "call-bound": "^1.0.2", + "has-symbols": "^1.1.0", + "safe-regex-test": "^1.1.0" }, "engines": { "node": ">= 0.4" @@ -7468,13 +7356,13 @@ } }, "node_modules/is-typed-array": { - "version": "1.1.13", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.13.tgz", - "integrity": "sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==", + "version": "1.1.15", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.15.tgz", + "integrity": "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==", "dev": true, "license": "MIT", "dependencies": { - "which-typed-array": "^1.1.14" + "which-typed-array": "^1.1.16" }, "engines": { "node": ">= 0.4" @@ -7497,27 +7385,30 @@ } }, "node_modules/is-weakref": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", - "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.1.0.tgz", + "integrity": "sha512-SXM8Nwyys6nT5WP6pltOwKytLV7FqQ4UiibxVmW+EIosHcmCqkkjViTb5SNssDlkCiEYRP1/pdWUKVvZBmsR2Q==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2" + "call-bound": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-weakset": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.3.tgz", - "integrity": "sha512-LvIm3/KWzS9oRFHugab7d+M/GcBXuXX5xZkzPmN+NxihdQlZUQ4dWuSV1xR/sq6upL1TJEDrfBgRepHFdBtSNQ==", + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.4.tgz", + "integrity": "sha512-mfcwb6IzQyOKTs84CQMrOwW4gQcaTOAWJ0zzJCl2WSPDrWk/OzDaImWFH3djXhb24g4eudZfLRozAvPGw4d9hQ==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", - "get-intrinsic": "^1.2.4" + "call-bound": "^1.0.3", + "get-intrinsic": "^1.2.6" }, "engines": { "node": ">= 0.4" @@ -7559,17 +7450,18 @@ } }, "node_modules/iterator.prototype": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/iterator.prototype/-/iterator.prototype-1.1.3.tgz", - "integrity": "sha512-FW5iMbeQ6rBGm/oKgzq2aW4KvAGpxPzYES8N4g4xNXUKpL1mclMvOe+76AcLDTvD+Ze+sOpVhgdAQEKF4L9iGQ==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/iterator.prototype/-/iterator.prototype-1.1.4.tgz", + "integrity": "sha512-x4WH0BWmrMmg4oHHl+duwubhrvczGlyuGAZu3nvrf0UXOfPu8IhZObFEr7DE/iv01YgVZrsOiRcqw2srkKEDIA==", "dev": true, "license": "MIT", "dependencies": { - "define-properties": "^1.2.1", - "get-intrinsic": "^1.2.1", - "has-symbols": "^1.0.3", - "reflect.getprototypeof": "^1.0.4", - "set-function-name": "^2.0.1" + "define-data-property": "^1.1.4", + "es-object-atoms": "^1.0.0", + "get-intrinsic": "^1.2.6", + "has-symbols": "^1.1.0", + "reflect.getprototypeof": "^1.0.8", + "set-function-name": "^2.0.2" }, "engines": { "node": ">= 0.4" @@ -7642,9 +7534,9 @@ } }, "node_modules/jsesc": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.0.2.tgz", - "integrity": "sha512-xKqzzWXDttJuOcawBt4KnKHHIf5oQ/Cxax+0PWFG+DFDgHNAdi+TXECADI+RYiFUMmx8792xsMbbgXj4CwnP4g==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", "license": "MIT", "bin": { "jsesc": "bin/jsesc" @@ -7892,9 +7784,9 @@ } }, "node_modules/less": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/less/-/less-4.2.0.tgz", - "integrity": "sha512-P3b3HJDBtSzsXUl0im2L7gTO5Ubg8mEN6G8qoTS77iXxXX4Hvu4Qj540PZDvQ8V6DmX6iXo98k7Md0Cm1PrLaA==", + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/less/-/less-4.2.1.tgz", + "integrity": "sha512-CasaJidTIhWmjcqv0Uj5vccMI7pJgfD9lMkKtlnTHAdJdYK/7l8pM9tumLyJ0zhbD4KJLo/YvTj+xznQd5NBhg==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -7960,6 +7852,12 @@ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "license": "MIT" }, + "node_modules/lodash-es": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.21.tgz", + "integrity": "sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==", + "license": "MIT" + }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -8028,9 +7926,9 @@ } }, "node_modules/magic-string": { - "version": "0.30.13", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.13.tgz", - "integrity": "sha512-8rYBO+MsWkgjDSOvLomYnzhdwEG51olQ4zL5KXnNJWV5MNmrb4rTZdrtkhxjnD/QyZUqR/Z/XDsUs/4ej2nx0g==", + "version": "0.30.17", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.17.tgz", + "integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==", "dev": true, "license": "MIT", "dependencies": { @@ -8073,13 +7971,6 @@ "semver": "bin/semver" } }, - "node_modules/make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true, - "license": "ISC" - }, "node_modules/make-event-props": { "version": "1.6.2", "resolved": "https://registry.npmjs.org/make-event-props/-/make-event-props-1.6.2.tgz", @@ -8090,6 +7981,16 @@ "url": "https://github.com/wojtekmaj/make-event-props?sponsor=1" } }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", + "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, "node_modules/mdn-data": { "version": "2.0.14", "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", @@ -8294,9 +8195,9 @@ "license": "MIT" }, "node_modules/msw": { - "version": "2.6.6", - "resolved": "https://registry.npmjs.org/msw/-/msw-2.6.6.tgz", - "integrity": "sha512-npfIIVRHKQX3Lw4aLWX4wBh+lQwpqdZNyJYB5K/+ktK8NhtkdsTxGK7WDrgknozcVyRI7TOqY6yBS9j2FTR+YQ==", + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/msw/-/msw-2.7.0.tgz", + "integrity": "sha512-BIodwZ19RWfCbYTxWTUfTXc+sg4OwjCAgxU1ZsgmggX/7S3LdUifsbUPJs61j0rWb19CZRGY5if77duhc0uXzw==", "dev": true, "hasInstallScript": true, "license": "MIT", @@ -8310,12 +8211,12 @@ "@open-draft/until": "^2.1.0", "@types/cookie": "^0.6.0", "@types/statuses": "^2.0.4", - "chalk": "^4.1.2", "graphql": "^16.8.1", "headers-polyfill": "^4.0.2", "is-node-process": "^1.2.0", "outvariant": "^1.4.3", "path-to-regexp": "^6.3.0", + "picocolors": "^1.1.1", "strict-event-emitter": "^0.5.1", "type-fest": "^4.26.1", "yargs": "^17.7.2" @@ -8383,9 +8284,9 @@ "license": "MIT" }, "node_modules/nanoid": { - "version": "3.3.7", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", - "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "version": "3.3.8", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.8.tgz", + "integrity": "sha512-WNLf5Sd8oZxOm+TzppcYk8gVOgP+l58xNy58D0nbUnOxOWRWvlcCV4kUF7ltmI6PsrLl/BgKEyS4mqsGChFN0w==", "funding": [ { "type": "github", @@ -8480,9 +8381,9 @@ } }, "node_modules/node-releases": { - "version": "2.0.18", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.18.tgz", - "integrity": "sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g==", + "version": "2.0.19", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.19.tgz", + "integrity": "sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw==", "dev": true, "license": "MIT" }, @@ -8519,9 +8420,9 @@ } }, "node_modules/nwsapi": { - "version": "2.2.13", - "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.13.tgz", - "integrity": "sha512-cTGB9ptp9dY9A5VbMSe7fQBcl/tt22Vcqdq8+eN93rblOuE0aCFu4aZ2vMwct/2t+lFnosm8RkQW1I0Omb1UtQ==", + "version": "2.2.16", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.16.tgz", + "integrity": "sha512-F1I/bimDpj3ncaNDhfyMWuFqmQDBwDB0Fogc2qpL3BWvkQteFD/8BzWuIRl83rq0DXfm8SGt/HFhLXZyljTXcQ==", "dev": true, "license": "MIT" }, @@ -8558,15 +8459,17 @@ } }, "node_modules/object.assign": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.5.tgz", - "integrity": "sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==", + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.7.tgz", + "integrity": "sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.5", + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", "define-properties": "^1.2.1", - "has-symbols": "^1.0.3", + "es-object-atoms": "^1.0.0", + "has-symbols": "^1.1.0", "object-keys": "^1.1.1" }, "engines": { @@ -8611,13 +8514,14 @@ } }, "node_modules/object.values": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.2.0.tgz", - "integrity": "sha512-yBYjY9QX2hnRmZHAjG/f13MzmBzxzYgQhFrke06TTyKY5zSTEqkOeukBzIdVA3j3ulu8Qa3MbVFShV7T2RmGtQ==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.2.1.tgz", + "integrity": "sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", "define-properties": "^1.2.1", "es-object-atoms": "^1.0.0" }, @@ -8893,13 +8797,13 @@ } }, "node_modules/playwright": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.49.0.tgz", - "integrity": "sha512-eKpmys0UFDnfNb3vfsf8Vx2LEOtflgRebl0Im2eQQnYMA4Aqd+Zw8bEOB+7ZKvN76901mRnqdsiOGKxzVTbi7A==", + "version": "1.49.1", + "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.49.1.tgz", + "integrity": "sha512-VYL8zLoNTBxVOrJBbDuRgDWa3i+mfQgDTrL8Ah9QXZ7ax4Dsj0MSq5bYgytRnDVVe+njoKnfsYkH3HzqVj5UZA==", "dev": true, "license": "Apache-2.0", "dependencies": { - "playwright-core": "1.49.0" + "playwright-core": "1.49.1" }, "bin": { "playwright": "cli.js" @@ -8912,9 +8816,9 @@ } }, "node_modules/playwright-core": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.49.0.tgz", - "integrity": "sha512-R+3KKTQF3npy5GTiKH/T+kdhoJfJojjHESR1YEWhYuEKRVfVaxH3+4+GvXE5xyCngCxhxnykk0Vlah9v8fs3jA==", + "version": "1.49.1", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.49.1.tgz", + "integrity": "sha512-BzmpVcs4kE2CH15rWfzpjzVGhWERJfmnXmniSyKeRZUs9Ws65m+RGIi7mjJK/euCegfn3i7jvqWeWyHe9y3Vgg==", "dev": true, "license": "Apache-2.0", "bin": { @@ -8979,9 +8883,9 @@ } }, "node_modules/prettier": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.3.3.tgz", - "integrity": "sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==", + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.4.2.tgz", + "integrity": "sha512-e9MewbtFo+Fevyuxn/4rrcDAaq0IYxPGLvObpQjiZBMAzB9IGmzlnG9RZy3FFas+eBMu2vA0CszMeduow5dIuQ==", "dev": true, "license": "MIT", "bin": { @@ -9110,13 +9014,16 @@ "optional": true }, "node_modules/psl": { - "version": "1.13.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.13.0.tgz", - "integrity": "sha512-BFwmFXiJoFqlUpZ5Qssolv15DMyc84gTBds1BjsV1BfXEo1UyyD7GsmN67n7J77uRhoSNW1AXtXKPLcBFQn9Aw==", + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/psl/-/psl-1.15.0.tgz", + "integrity": "sha512-JZd3gMVBAVQkSs6HdNZo9Sdo0LNcQeMNP3CozBJb3JYC/QUYZTnKxP+f8oWRX4rHP5EurWxqAHTSwUCjlNKa1w==", "dev": true, "license": "MIT", "dependencies": { "punycode": "^2.3.1" + }, + "funding": { + "url": "https://github.com/sponsors/lupomontero" } }, "node_modules/punycode": { @@ -9158,14 +9065,14 @@ "license": "MIT" }, "node_modules/rc-motion": { - "version": "2.9.3", - "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.9.3.tgz", - "integrity": "sha512-rkW47ABVkic7WEB0EKJqzySpvDqwl60/tdkY7hWP7dYnh5pm0SzJpo54oW3TDUGXV5wfxXFmMkxrzRRbotQ0+w==", + "version": "2.9.4", + "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.9.4.tgz", + "integrity": "sha512-TAPUUufDqhPO669qJobI0d9U0XZ/VPNQyZTivUxxzU1EyuPe3PtHSx7Kb902KuzQgu7sS18z8GguaxZEALV/ww==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.11.1", "classnames": "^2.2.1", - "rc-util": "^5.43.0" + "rc-util": "^5.44.0" }, "peerDependencies": { "react": ">=16.9.0", @@ -9188,14 +9095,14 @@ } }, "node_modules/rc-resize-observer": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.4.0.tgz", - "integrity": "sha512-PnMVyRid9JLxFavTjeDXEXo65HCRqbmLBw9xX9gfC4BZiSzbLXKzW3jPz+J0P71pLbD5tBMTT+mkstV5gD0c9Q==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.4.3.tgz", + "integrity": "sha512-YZLjUbyIWox8E9i9C3Tm7ia+W7euPItNWSPX5sCcQTYbnwDb5uNpnLHQCG1f22oZWUhLw4Mv2tFmeWe68CDQRQ==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.20.7", "classnames": "^2.2.1", - "rc-util": "^5.38.0", + "rc-util": "^5.44.1", "resize-observer-polyfill": "^1.5.1" }, "peerDependencies": { @@ -9204,9 +9111,9 @@ } }, "node_modules/rc-tooltip": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/rc-tooltip/-/rc-tooltip-6.2.1.tgz", - "integrity": "sha512-rws0duD/3sHHsD905Nex7FvoUGy2UBQRhTkKxeEvr2FB+r21HsOxcDJI0TzyO8NHhnAA8ILr8pfbSBg5Jj5KBg==", + "version": "6.3.2", + "resolved": "https://registry.npmjs.org/rc-tooltip/-/rc-tooltip-6.3.2.tgz", + "integrity": "sha512-oA4HZIiZJbUQ5ojigM0y4XtWxaH/aQlJSzknjICRWNpqyemy1sL3X3iEQV2eSPBWEq+bqU3+aSs81z+28j9luA==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.11.2", @@ -9219,9 +9126,9 @@ } }, "node_modules/rc-util": { - "version": "5.43.0", - "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.43.0.tgz", - "integrity": "sha512-AzC7KKOXFqAdIBqdGWepL9Xn7cm3vnAmjlHqUnoQaTMZYhM4VlXGLkkHHxj/BZ7Td0+SOPKB4RGPboBVKT9htw==", + "version": "5.44.2", + "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.44.2.tgz", + "integrity": "sha512-uGSk3hpPBLa3/0QAcKhCjgl4SFnhQCJDLvvpoLdbR6KgDuXrujG+dQaUeUvBJr2ZWak1O/9n+cYbJiWmmk95EQ==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.18.3", @@ -9264,53 +9171,6 @@ "react-dom": "^18.x" } }, - "node_modules/react-datepicker": { - "version": "7.5.0", - "resolved": "https://registry.npmjs.org/react-datepicker/-/react-datepicker-7.5.0.tgz", - "integrity": "sha512-6MzeamV8cWSOcduwePHfGqY40acuGlS1cG//ePHT6bVbLxWyqngaStenfH03n1wbzOibFggF66kWaBTb1SbTtQ==", - "license": "MIT", - "dependencies": { - "@floating-ui/react": "^0.26.23", - "clsx": "^2.1.1", - "date-fns": "^3.6.0", - "prop-types": "^15.8.1" - }, - "peerDependencies": { - "react": "^16.9.0 || ^17 || ^18", - "react-dom": "^16.9.0 || ^17 || ^18" - } - }, - "node_modules/react-datepicker/node_modules/@floating-ui/react": { - "version": "0.26.28", - "resolved": "https://registry.npmjs.org/@floating-ui/react/-/react-0.26.28.tgz", - "integrity": "sha512-yORQuuAtVpiRjpMhdc0wJj06b9JFjrYF4qp96j++v2NBpbi6SEGF7donUJ3TMieerQ6qVkAv1tgr7L4r5roTqw==", - "license": "MIT", - "dependencies": { - "@floating-ui/react-dom": "^2.1.2", - "@floating-ui/utils": "^0.2.8", - "tabbable": "^6.0.0" - }, - "peerDependencies": { - "react": ">=16.8.0", - "react-dom": ">=16.8.0" - } - }, - "node_modules/react-datepicker/node_modules/@floating-ui/utils": { - "version": "0.2.8", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz", - "integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig==", - "license": "MIT" - }, - "node_modules/react-datepicker/node_modules/date-fns": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.6.0.tgz", - "integrity": "sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/kossnocorp" - } - }, "node_modules/react-display-name": { "version": "0.2.5", "resolved": "https://registry.npmjs.org/react-display-name/-/react-display-name-0.2.5.tgz", @@ -9372,9 +9232,9 @@ } }, "node_modules/react-hook-form": { - "version": "7.53.2", - "resolved": "https://registry.npmjs.org/react-hook-form/-/react-hook-form-7.53.2.tgz", - "integrity": "sha512-YVel6fW5sOeedd1524pltpHX+jgU2u3DSDtXEaBORNdqiNrsX/nUI/iGXONegttg0mJVnfrIkiV0cmTU6Oo2xw==", + "version": "7.54.1", + "resolved": "https://registry.npmjs.org/react-hook-form/-/react-hook-form-7.54.1.tgz", + "integrity": "sha512-PUNzFwQeQ5oHiiTUO7GO/EJXGEtuun2Y1A59rLnZBBj+vNEOWt/3ERTiG1/zt7dVeJEM+4vDX/7XQ/qanuvPMg==", "license": "MIT", "engines": { "node": ">=18.0.0" @@ -9434,9 +9294,9 @@ "license": "MIT" }, "node_modules/react-modal": { - "version": "3.16.1", - "resolved": "https://registry.npmjs.org/react-modal/-/react-modal-3.16.1.tgz", - "integrity": "sha512-VStHgI3BVcGo7OXczvnJN7yT2TWHJPDXZWyI/a0ssFNhGZWsPmB8cF0z33ewDXq4VfYMO1vXgiv/g8Nj9NDyWg==", + "version": "3.16.3", + "resolved": "https://registry.npmjs.org/react-modal/-/react-modal-3.16.3.tgz", + "integrity": "sha512-yCYRJB5YkeQDQlTt17WGAgFJ7jr2QYcWa1SHqZ3PluDmnKJ/7+tVU+E6uKyZ0nODaeEj+xCpK4LcSnKXLMC0Nw==", "license": "MIT", "dependencies": { "exenv": "^1.2.0", @@ -9444,12 +9304,9 @@ "react-lifecycles-compat": "^3.0.0", "warning": "^4.0.3" }, - "engines": { - "node": ">=8" - }, "peerDependencies": { - "react": "^0.14.0 || ^15.0.0 || ^16 || ^17 || ^18", - "react-dom": "^0.14.0 || ^15.0.0 || ^16 || ^17 || ^18" + "react": "^0.14.0 || ^15.0.0 || ^16 || ^17 || ^18 || ^19", + "react-dom": "^0.14.0 || ^15.0.0 || ^16 || ^17 || ^18 || ^19" } }, "node_modules/react-paginate": { @@ -9495,18 +9352,18 @@ } }, "node_modules/react-redux": { - "version": "9.1.2", - "resolved": "https://registry.npmjs.org/react-redux/-/react-redux-9.1.2.tgz", - "integrity": "sha512-0OA4dhM1W48l3uzmv6B7TXPCGmokUU4p1M44DGN2/D9a1FjVPukVjER1PcPX97jIg6aUeLq1XJo1IpfbgULn0w==", + "version": "9.2.0", + "resolved": "https://registry.npmjs.org/react-redux/-/react-redux-9.2.0.tgz", + "integrity": "sha512-ROY9fvHhwOD9ySfrF0wmvu//bKCQ6AeZZq1nJNtbDC+kk5DuSuNX/n6YWYF/SYy7bSba4D4FSz8DJeKY/S/r+g==", "dev": true, "license": "MIT", "dependencies": { - "@types/use-sync-external-store": "^0.0.3", - "use-sync-external-store": "^1.0.0" + "@types/use-sync-external-store": "^0.0.6", + "use-sync-external-store": "^1.4.0" }, "peerDependencies": { - "@types/react": "^18.2.25", - "react": "^18.0", + "@types/react": "^18.2.25 || ^19", + "react": "^18.0 || ^19", "redux": "^5.0.0" }, "peerDependenciesMeta": { @@ -9561,9 +9418,9 @@ } }, "node_modules/react-select": { - "version": "5.8.3", - "resolved": "https://registry.npmjs.org/react-select/-/react-select-5.8.3.tgz", - "integrity": "sha512-lVswnIq8/iTj1db7XCG74M/3fbGB6ZaluCzvwPGT5ZOjCdL/k0CLWhEK0vCBLuU5bHTEf6Gj8jtSvi+3v+tO1w==", + "version": "5.9.0", + "resolved": "https://registry.npmjs.org/react-select/-/react-select-5.9.0.tgz", + "integrity": "sha512-nwRKGanVHGjdccsnzhFte/PULziueZxGD8LL2WojON78Mvnq7LdAMEtu2frrwld1fr3geixg3iiMBIc/LLAZpw==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.12.0", @@ -9574,11 +9431,11 @@ "memoize-one": "^6.0.0", "prop-types": "^15.6.0", "react-transition-group": "^4.3.0", - "use-isomorphic-layout-effect": "^1.1.2" + "use-isomorphic-layout-effect": "^1.2.0" }, "peerDependencies": { - "react": "^16.8.0 || ^17.0.0 || ^18.0.0", - "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0" + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", + "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "node_modules/react-select/node_modules/memoize-one": { @@ -9643,9 +9500,9 @@ } }, "node_modules/react-use": { - "version": "17.5.1", - "resolved": "https://registry.npmjs.org/react-use/-/react-use-17.5.1.tgz", - "integrity": "sha512-LG/uPEVRflLWMwi3j/sZqR00nF6JGqTTDblkXK2nzXsIvij06hXl1V/MZIlwj1OKIQUtlh1l9jK8gLsRyCQxMg==", + "version": "17.6.0", + "resolved": "https://registry.npmjs.org/react-use/-/react-use-17.6.0.tgz", + "integrity": "sha512-OmedEScUMKFfzn1Ir8dBxiLLSOzhKe/dPZwVxcujweSj45aNM7BEGPb9BEVIgVEqEXx6f3/TsXzwIktNgUR02g==", "license": "Unlicense", "dependencies": { "@types/js-cookie": "^2.2.6", @@ -9669,9 +9526,9 @@ } }, "node_modules/react-window": { - "version": "1.8.10", - "resolved": "https://registry.npmjs.org/react-window/-/react-window-1.8.10.tgz", - "integrity": "sha512-Y0Cx+dnU6NLa5/EvoHukUD0BklJ8qITCtVEPY1C/nL8wwoZ0b5aEw8Ff1dOVHw7fCzMt55XfJDd8S8W8LCaUCg==", + "version": "1.8.11", + "resolved": "https://registry.npmjs.org/react-window/-/react-window-1.8.11.tgz", + "integrity": "sha512-+SRbUVT2scadgFSWx+R1P754xHPEqvcfSfVX10QYg6POOz+WNgkN48pS+BtZNIMGiL1HYrSEiCkwsMS15QogEQ==", "license": "MIT", "dependencies": { "@babel/runtime": "^7.0.0", @@ -9681,8 +9538,8 @@ "node": ">8.0.0" }, "peerDependencies": { - "react": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0", - "react-dom": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0" + "react": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", + "react-dom": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "node_modules/readable-stream": { @@ -9766,19 +9623,20 @@ } }, "node_modules/reflect.getprototypeof": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.7.tgz", - "integrity": "sha512-bMvFGIUKlc/eSfXNX+aZ+EL95/EgZzuwA0OBPTbZZDEJw/0AkentjMuM1oiRfwHrshqk4RzdgiTg5CcDalXN5g==", + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.9.tgz", + "integrity": "sha512-r0Ay04Snci87djAsI4U+WNRcSw5S4pOH7qFjd/veA5gC7TbqESR3tcj28ia95L/fYUDw11JKP7uqUKUAfVvV5Q==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", "define-properties": "^1.2.1", - "es-abstract": "^1.23.5", + "dunder-proto": "^1.0.1", + "es-abstract": "^1.23.6", "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "which-builtin-type": "^1.1.4" + "get-intrinsic": "^1.2.6", + "gopd": "^1.2.0", + "which-builtin-type": "^1.2.1" }, "engines": { "node": ">= 0.4" @@ -9861,12 +9719,12 @@ } }, "node_modules/require-in-the-middle/node_modules/resolve": { - "version": "1.22.8", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", - "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", + "version": "1.22.9", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.9.tgz", + "integrity": "sha512-QxrmX1DzraFIi9PxdG5VkRfRwIgjwyud+z/iBwfRRrVmHc+P9Q7u2lSSpQ6bjr2gy5lrqIiU9vb6iAeGf2400A==", "license": "MIT", "dependencies": { - "is-core-module": "^2.13.0", + "is-core-module": "^2.16.0", "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" }, @@ -9953,9 +9811,9 @@ } }, "node_modules/rollup": { - "version": "4.27.4", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.27.4.tgz", - "integrity": "sha512-RLKxqHEMjh/RGLsDxAEsaLO3mWgyoU6x9w6n1ikAzet4B3gI2/3yP6PWY2p9QzRTh6MfEIXB3MwsOY0Iv3vNrw==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.28.1.tgz", + "integrity": "sha512-61fXYl/qNVinKmGSTHAZ6Yy8I3YIJC/r2m9feHo6SwVAVcLT5MPwOUFe7EuURA/4m0NR8lXG4BBXuo/IZEsjMg==", "dev": true, "license": "MIT", "dependencies": { @@ -9969,24 +9827,25 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.27.4", - "@rollup/rollup-android-arm64": "4.27.4", - "@rollup/rollup-darwin-arm64": "4.27.4", - "@rollup/rollup-darwin-x64": "4.27.4", - "@rollup/rollup-freebsd-arm64": "4.27.4", - "@rollup/rollup-freebsd-x64": "4.27.4", - "@rollup/rollup-linux-arm-gnueabihf": "4.27.4", - "@rollup/rollup-linux-arm-musleabihf": "4.27.4", - "@rollup/rollup-linux-arm64-gnu": "4.27.4", - "@rollup/rollup-linux-arm64-musl": "4.27.4", - "@rollup/rollup-linux-powerpc64le-gnu": "4.27.4", - "@rollup/rollup-linux-riscv64-gnu": "4.27.4", - "@rollup/rollup-linux-s390x-gnu": "4.27.4", - "@rollup/rollup-linux-x64-gnu": "4.27.4", - "@rollup/rollup-linux-x64-musl": "4.27.4", - "@rollup/rollup-win32-arm64-msvc": "4.27.4", - "@rollup/rollup-win32-ia32-msvc": "4.27.4", - "@rollup/rollup-win32-x64-msvc": "4.27.4", + "@rollup/rollup-android-arm-eabi": "4.28.1", + "@rollup/rollup-android-arm64": "4.28.1", + "@rollup/rollup-darwin-arm64": "4.28.1", + "@rollup/rollup-darwin-x64": "4.28.1", + "@rollup/rollup-freebsd-arm64": "4.28.1", + "@rollup/rollup-freebsd-x64": "4.28.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.28.1", + "@rollup/rollup-linux-arm-musleabihf": "4.28.1", + "@rollup/rollup-linux-arm64-gnu": "4.28.1", + "@rollup/rollup-linux-arm64-musl": "4.28.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.28.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.28.1", + "@rollup/rollup-linux-riscv64-gnu": "4.28.1", + "@rollup/rollup-linux-s390x-gnu": "4.28.1", + "@rollup/rollup-linux-x64-gnu": "4.28.1", + "@rollup/rollup-linux-x64-musl": "4.28.1", + "@rollup/rollup-win32-arm64-msvc": "4.28.1", + "@rollup/rollup-win32-ia32-msvc": "4.28.1", + "@rollup/rollup-win32-x64-msvc": "4.28.1", "fsevents": "~2.3.2" } }, @@ -10031,15 +9890,16 @@ } }, "node_modules/safe-array-concat": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.2.tgz", - "integrity": "sha512-vj6RsCsWBCf19jIeHEfkRMw8DPiBb+DMXklQ/1SGDHOMlHdPUkZXFQ2YdplS23zESTijAcurb1aSgJA3AgMu1Q==", + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.3.tgz", + "integrity": "sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", - "get-intrinsic": "^1.2.4", - "has-symbols": "^1.0.3", + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", + "get-intrinsic": "^1.2.6", + "has-symbols": "^1.1.0", "isarray": "^2.0.5" }, "engines": { @@ -10072,15 +9932,15 @@ "optional": true }, "node_modules/safe-regex-test": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.3.tgz", - "integrity": "sha512-CdASjNJPvRa7roO6Ra/gLYBTzYzzPyyBXxIMdGW3USQLyjWEls2RgW5UBTXaQVp+OrpeCK3bLem8smtmheoRuw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.1.0.tgz", + "integrity": "sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.6", + "call-bound": "^1.0.2", "es-errors": "^1.3.0", - "is-regex": "^1.1.4" + "is-regex": "^1.2.1" }, "engines": { "node": ">= 0.4" @@ -10097,9 +9957,9 @@ "license": "MIT" }, "node_modules/sass": { - "version": "1.81.0", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.81.0.tgz", - "integrity": "sha512-Q4fOxRfhmv3sqCLoGfvrC9pRV8btc0UtqL9mN6Yrv6Qi9ScL55CVH1vlPP863ISLEEMNLLuu9P+enCeGHlnzhA==", + "version": "1.83.0", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.83.0.tgz", + "integrity": "sha512-qsSxlayzoOjdvXMVLkzF84DJFc2HZEL/rFyGIKbbilYtAvlCxyuzUeff9LawTn4btVnLKg75Z8MMr1lxU1lfGw==", "dev": true, "license": "MIT", "dependencies": { @@ -10117,13 +9977,6 @@ "@parcel/watcher": "^2.4.1" } }, - "node_modules/sass/node_modules/immutable": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/immutable/-/immutable-5.0.3.tgz", - "integrity": "sha512-P8IdPQHq3lA1xVeBRi5VPqUm5HDgKnx0Ru51wZz5mjxHr5n3RWhjIpOFU7ybkUxfB+5IToy+OLaHYDBIWsv+uw==", - "dev": true, - "license": "MIT" - }, "node_modules/sax": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.1.tgz", @@ -10271,16 +10124,73 @@ "license": "BSD-2-Clause" }, "node_modules/side-channel": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", - "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.0.tgz", + "integrity": "sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "object-inspect": "^1.13.1" + "object-inspect": "^1.13.3", + "side-channel-list": "^1.0.0", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.0.tgz", + "integrity": "sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" }, "engines": { "node": ">= 0.4" @@ -10528,17 +10438,20 @@ } }, "node_modules/string.prototype.trim": { - "version": "1.2.9", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.9.tgz", - "integrity": "sha512-klHuCNxiMZ8MlsOihJhJEBJAiMVqU3Z2nEXWfWnIqjN0gEFS9J9+IxKozWWtQGcgoa1WUZzLjKPTr4ZHNFTFxw==", + "version": "1.2.10", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.10.tgz", + "integrity": "sha512-Rs66F0P/1kedk5lyYyH9uBzuiI/kNRmwJAR9quK6VOtIpZ2G+hMZd+HQbbv25MgCA6gEffoMZYxlTod4WcdrKA==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", + "define-data-property": "^1.1.4", "define-properties": "^1.2.1", - "es-abstract": "^1.23.0", - "es-object-atoms": "^1.0.0" - }, + "es-abstract": "^1.23.5", + "es-object-atoms": "^1.0.0", + "has-property-descriptors": "^1.0.2" + }, "engines": { "node": ">= 0.4" }, @@ -10547,16 +10460,20 @@ } }, "node_modules/string.prototype.trimend": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.8.tgz", - "integrity": "sha512-p73uL5VCHCO2BZZ6krwwQE3kCzM7NKmis8S//xEC6fQonchbum4eP6kR4DLEjQFO3Wnj3Fuo8NM0kOSjVdHjZQ==", + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.9.tgz", + "integrity": "sha512-G7Ok5C6E/j4SGfyLCloXTrngQIQU3PWtXGst3yM7Bea9FRURf1S42ZHlZZtsNque2FN2PoUhfZXYLNWwEr4dLQ==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", "define-properties": "^1.2.1", "es-object-atoms": "^1.0.0" }, + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -10893,22 +10810,22 @@ } }, "node_modules/tldts": { - "version": "6.1.64", - "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.64.tgz", - "integrity": "sha512-ph4AE5BXWIOsSy9stpoeo7bYe/Cy7VfpciIH4RhVZUPItCJmhqWCN0EVzxd8BOHiyNb42vuJc6NWTjJkg91Tuw==", + "version": "6.1.68", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.68.tgz", + "integrity": "sha512-JKF17jROiYkjJPT73hUTEiTp2OBCf+kAlB+1novk8i6Q6dWjHsgEjw9VLiipV4KTJavazXhY1QUXyQFSem2T7w==", "dev": true, "license": "MIT", "dependencies": { - "tldts-core": "^6.1.64" + "tldts-core": "^6.1.68" }, "bin": { "tldts": "bin/cli.js" } }, "node_modules/tldts-core": { - "version": "6.1.64", - "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.64.tgz", - "integrity": "sha512-uqnl8vGV16KsyflHOzqrYjjArjfXaU6rMPXYy2/ZWoRKCkXtghgB4VwTDXUG+t0OTGeSewNAG31/x1gCTfLt+Q==", + "version": "6.1.68", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.68.tgz", + "integrity": "sha512-85TdlS/DLW/gVdf2oyyzqp3ocS30WxjaL4la85EArl9cHUR/nizifKAJPziWewSZjDZS71U517/i6ciUeqtB5Q==", "dev": true, "license": "MIT" }, @@ -10974,9 +10891,9 @@ } }, "node_modules/ts-api-utils": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.4.1.tgz", - "integrity": "sha512-5RU2/lxTA3YUZxju61HO2U6EoZLvBLtmV2mbTvqyu4a/7s7RmJPT+1YekhMVsQhznRWk/czIwDUg+V8Q9ZuG4w==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.4.3.tgz", + "integrity": "sha512-i3eMG77UTMD0hZhgRS562pv83RC6ukSAC2GMNWc+9dieh/+jDM5u5YG+NHX6VNDRHQcHwmsTHctP9LhbC3WxVw==", "dev": true, "license": "MIT", "engines": { @@ -10992,50 +10909,6 @@ "integrity": "sha512-Z86EW+fFFh/IFB1fqQ3/+7Zpf9t2ebOAxNI/V6Wo7r5gqiqtxmgTlQ1qbqQcjLKYeSHPTsEmvlJUDg/EuL0uHQ==", "license": "Unlicense" }, - "node_modules/ts-node": { - "version": "10.9.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz", - "integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@cspotcode/source-map-support": "^0.8.0", - "@tsconfig/node10": "^1.0.7", - "@tsconfig/node12": "^1.0.7", - "@tsconfig/node14": "^1.0.0", - "@tsconfig/node16": "^1.0.2", - "acorn": "^8.4.1", - "acorn-walk": "^8.1.1", - "arg": "^4.1.0", - "create-require": "^1.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "v8-compile-cache-lib": "^3.0.1", - "yn": "3.1.1" - }, - "bin": { - "ts-node": "dist/bin.js", - "ts-node-cwd": "dist/bin-cwd.js", - "ts-node-esm": "dist/bin-esm.js", - "ts-node-script": "dist/bin-script.js", - "ts-node-transpile-only": "dist/bin-transpile.js", - "ts-script": "dist/bin-script-deprecated.js" - }, - "peerDependencies": { - "@swc/core": ">=1.2.50", - "@swc/wasm": ">=1.2.50", - "@types/node": "*", - "typescript": ">=2.7" - }, - "peerDependenciesMeta": { - "@swc/core": { - "optional": true - }, - "@swc/wasm": { - "optional": true - } - } - }, "node_modules/tsconfck": { "version": "3.1.4", "resolved": "https://registry.npmjs.org/tsconfck/-/tsconfck-3.1.4.tgz", @@ -11077,9 +10950,9 @@ } }, "node_modules/type-fest": { - "version": "4.28.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.28.0.tgz", - "integrity": "sha512-jXMwges/FVbFRe5lTMJZVEZCrO9kI9c8k0PA/z7nF3bo0JSCCLysvokFjNPIUK/itEMas10MQM+AiHoHt/T/XA==", + "version": "4.30.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.30.2.tgz", + "integrity": "sha512-UJShLPYi1aWqCdq9HycOL/gwsuqda1OISdBO3t8RlXQC4QvtuIz4b5FCfe2dQIWEpmlRExKmcTBfP1r9bhY7ig==", "dev": true, "license": "(MIT OR CC0-1.0)", "engines": { @@ -11090,32 +10963,32 @@ } }, "node_modules/typed-array-buffer": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.2.tgz", - "integrity": "sha512-gEymJYKZtKXzzBzM4jqa9w6Q1Jjm7x2d+sh19AdsD4wqnMPDYyvwpsIc2Q/835kHuo3BEQ7CjelGhfTsoBb2MQ==", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", + "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bound": "^1.0.3", "es-errors": "^1.3.0", - "is-typed-array": "^1.1.13" + "is-typed-array": "^1.1.14" }, "engines": { "node": ">= 0.4" } }, "node_modules/typed-array-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.1.tgz", - "integrity": "sha512-3iMJ9q0ao7WE9tWcaYKIptkNBuOIcZCCT0d4MRvuuH88fEoEH62IuQe0OtraD3ebQEoTRk8XCBoknUNc1Y67pw==", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.3.tgz", + "integrity": "sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-proto": "^1.0.3", - "is-typed-array": "^1.1.13" + "gopd": "^1.2.0", + "has-proto": "^1.2.0", + "is-typed-array": "^1.1.14" }, "engines": { "node": ">= 0.4" @@ -11125,19 +10998,19 @@ } }, "node_modules/typed-array-byte-offset": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.3.tgz", - "integrity": "sha512-GsvTyUHTriq6o/bHcTd0vM7OQ9JEdlvluu9YISaA7+KzDzPaIzEeDFNkTfhdE3MYcNhNi0vq/LlegYgIs5yPAw==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.4.tgz", + "integrity": "sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==", "dev": true, "license": "MIT", "dependencies": { "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-proto": "^1.0.3", - "is-typed-array": "^1.1.13", - "reflect.getprototypeof": "^1.0.6" + "gopd": "^1.2.0", + "has-proto": "^1.2.0", + "is-typed-array": "^1.1.15", + "reflect.getprototypeof": "^1.0.9" }, "engines": { "node": ">= 0.4" @@ -11208,25 +11081,28 @@ } }, "node_modules/unbox-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", - "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.1.0.tgz", + "integrity": "sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", + "call-bound": "^1.0.3", "has-bigints": "^1.0.2", - "has-symbols": "^1.0.3", - "which-boxed-primitive": "^1.0.2" + "has-symbols": "^1.1.0", + "which-boxed-primitive": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/undici-types": { - "version": "6.19.8", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", - "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==", + "version": "6.20.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", + "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", "license": "MIT" }, "node_modules/universalify": { @@ -11292,12 +11168,12 @@ } }, "node_modules/use-isomorphic-layout-effect": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/use-isomorphic-layout-effect/-/use-isomorphic-layout-effect-1.1.2.tgz", - "integrity": "sha512-49L8yCO3iGT/ZF9QttjwLF/ZD9Iwto5LnH5LmEdk/6cFmXddqi2ulF0edxTwjj+7mqvpVVGQWvbXZdn32wRSHA==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-isomorphic-layout-effect/-/use-isomorphic-layout-effect-1.2.0.tgz", + "integrity": "sha512-q6ayo8DWoPZT0VdG4u3D3uxcgONP3Mevx2i2b0434cwWBoL+aelL1DzkXI6w3PhTZzUeR2kaVlZn70iCiseP6w==", "license": "MIT", "peerDependencies": { - "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" }, "peerDependenciesMeta": { "@types/react": { @@ -11316,13 +11192,13 @@ } }, "node_modules/use-sync-external-store": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.2.tgz", - "integrity": "sha512-PElTlVMwpblvbNqQ82d2n6RjStvdSoNe9FG28kNfz3WiXilJm4DdNkEzRhCZuIDwY8U08WVihhGR5iRqAwfDiw==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.4.0.tgz", + "integrity": "sha512-9WXSPC5fMv61vaupRkCKCxsPxBocVnwakBEkMIHHpkTTg6icbJtg6jzgtLDm4bl3cSHAca52rYWih0k4K3PfHw==", "dev": true, "license": "MIT", "peerDependencies": { - "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "node_modules/util-deprecate": { @@ -11346,29 +11222,22 @@ "uuid": "dist/esm/bin/uuid" } }, - "node_modules/v8-compile-cache-lib": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", - "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", - "dev": true, - "license": "MIT" - }, "node_modules/vite": { - "version": "5.4.11", - "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.11.tgz", - "integrity": "sha512-c7jFQRklXua0mTzneGW9QVyxFjUgwcihC4bXEtujIo2ouWCe1Ajt/amn2PCxYnhYfd5k09JX3SB7OYWFKYqj8Q==", + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.0.3.tgz", + "integrity": "sha512-Cmuo5P0ENTN6HxLSo6IHsjCLn/81Vgrp81oaiFFMRa8gGDj5xEjIcEpf2ZymZtZR8oU0P2JX5WuUp/rlXcHkAw==", "dev": true, "license": "MIT", "dependencies": { - "esbuild": "^0.21.3", - "postcss": "^8.4.43", - "rollup": "^4.20.0" + "esbuild": "^0.24.0", + "postcss": "^8.4.49", + "rollup": "^4.23.0" }, "bin": { "vite": "bin/vite.js" }, "engines": { - "node": "^18.0.0 || >=20.0.0" + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" }, "funding": { "url": "https://github.com/vitejs/vite?sponsor=1" @@ -11377,19 +11246,25 @@ "fsevents": "~2.3.3" }, "peerDependencies": { - "@types/node": "^18.0.0 || >=20.0.0", + "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", + "jiti": ">=1.21.0", "less": "*", "lightningcss": "^1.21.0", "sass": "*", "sass-embedded": "*", "stylus": "*", "sugarss": "*", - "terser": "^5.4.0" + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" }, "peerDependenciesMeta": { "@types/node": { "optional": true }, + "jiti": { + "optional": true + }, "less": { "optional": true }, @@ -11410,13 +11285,19 @@ }, "terser": { "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true } } }, "node_modules/vite-node": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-2.1.5.tgz", - "integrity": "sha512-rd0QIgx74q4S1Rd56XIiL2cYEdyWn13cunYBIuqh9mpmQr7gGS0IxXoP8R6OaZtNQQLyXSWbd4rXKYUbhFpK5w==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-2.1.8.tgz", + "integrity": "sha512-uPAwSr57kYjAUux+8E2j0q0Fxpn8M9VoyfGiRI8Kfktz9NcYMCenwY5RnZxnF1WTu3TGiYipirIzacLL3VVGFg==", "dev": true, "license": "MIT", "dependencies": { @@ -11436,167 +11317,1262 @@ "url": "https://opencollective.com/vitest" } }, - "node_modules/vite-plugin-environment": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/vite-plugin-environment/-/vite-plugin-environment-1.1.3.tgz", - "integrity": "sha512-9LBhB0lx+2lXVBEWxFZC+WO7PKEyE/ykJ7EPWCq95NEcCpblxamTbs5Dm3DLBGzwODpJMEnzQywJU8fw6XGGGA==", + "node_modules/vite-node/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" + ], "dev": true, "license": "MIT", - "peerDependencies": { - "vite": ">= 2.7" + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" } }, - "node_modules/vite-tsconfig-paths": { - "version": "5.1.3", - "resolved": "https://registry.npmjs.org/vite-tsconfig-paths/-/vite-tsconfig-paths-5.1.3.tgz", - "integrity": "sha512-0bz+PDlLpGfP2CigeSKL9NFTF1KtXkeHGZSSaGQSuPZH77GhoiQaA8IjYgOaynSuwlDTolSUEU0ErVvju3NURg==", + "node_modules/vite-node/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" + ], "dev": true, "license": "MIT", - "dependencies": { - "debug": "^4.1.1", - "globrex": "^0.1.2", - "tsconfck": "^3.0.3" - }, - "peerDependencies": { - "vite": "*" - }, - "peerDependenciesMeta": { - "vite": { - "optional": true - } + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" } }, - "node_modules/vite/node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "node_modules/vite-node/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" + ], "dev": true, - "hasInstallScript": true, "license": "MIT", "optional": true, "os": [ - "darwin" + "android" ], "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + "node": ">=12" } }, - "node_modules/vite/node_modules/postcss": { - "version": "8.4.49", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.49.tgz", - "integrity": "sha512-OCVPnIObs4N29kxTjzLfUryOkvZEq+pf8jTF0lg8E7uETuWHA+v7j3c/xJmiqpX450191LlmZfUKkXxkTry7nA==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/postcss" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } + "node_modules/vite-node/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" ], + "dev": true, "license": "MIT", - "dependencies": { - "nanoid": "^3.3.7", - "picocolors": "^1.1.1", - "source-map-js": "^1.2.1" - }, + "optional": true, + "os": [ + "android" + ], "engines": { - "node": "^10 || ^12 || >=14" + "node": ">=12" } }, - "node_modules/vitest": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/vitest/-/vitest-2.1.5.tgz", - "integrity": "sha512-P4ljsdpuzRTPI/kbND2sDZ4VmieerR2c9szEZpjc+98Z9ebvnXmM5+0tHEKqYZumXqlvnmfWsjeFOjXVriDG7A==", + "node_modules/vite-node/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" + ], "dev": true, "license": "MIT", - "dependencies": { - "@vitest/expect": "2.1.5", - "@vitest/mocker": "2.1.5", - "@vitest/pretty-format": "^2.1.5", - "@vitest/runner": "2.1.5", - "@vitest/snapshot": "2.1.5", - "@vitest/spy": "2.1.5", - "@vitest/utils": "2.1.5", - "chai": "^5.1.2", - "debug": "^4.3.7", - "expect-type": "^1.1.0", - "magic-string": "^0.30.12", - "pathe": "^1.1.2", - "std-env": "^3.8.0", - "tinybench": "^2.9.0", - "tinyexec": "^0.3.1", - "tinypool": "^1.0.1", - "tinyrainbow": "^1.2.0", - "vite": "^5.0.0", - "vite-node": "2.1.5", - "why-is-node-running": "^2.3.0" - }, - "bin": { - "vitest": "vitest.mjs" - }, + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": "^18.0.0 || >=20.0.0" - }, - "funding": { - "url": "https://opencollective.com/vitest" - }, - "peerDependencies": { - "@edge-runtime/vm": "*", - "@types/node": "^18.0.0 || >=20.0.0", - "@vitest/browser": "2.1.5", - "@vitest/ui": "2.1.5", - "happy-dom": "*", - "jsdom": "*" - }, - "peerDependenciesMeta": { - "@edge-runtime/vm": { - "optional": true - }, - "@types/node": { - "optional": true - }, - "@vitest/browser": { - "optional": true - }, - "@vitest/ui": { - "optional": true - }, - "happy-dom": { - "optional": true - }, - "jsdom": { - "optional": true - } + "node": ">=12" } }, - "node_modules/w3c-xmlserializer": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", - "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "node_modules/vite-node/node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], "dev": true, "license": "MIT", - "dependencies": { - "xml-name-validator": "^5.0.0" - }, + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">=18" + "node": ">=12" } }, - "node_modules/warning": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/warning/-/warning-4.0.3.tgz", - "integrity": "sha512-rpJyN222KWIvHJ/F53XSZv0Zl/accqHR8et1kpaMTD/fLCRxtV8iX8czMzY7sVZupTI3zcUTg8eycS2kNF9l6w==", - "license": "MIT", - "dependencies": { - "loose-envify": "^1.0.0" - } + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vite-node/node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, + "node_modules/vite-node/node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/vite-node/node_modules/postcss": { + "version": "8.4.49", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.49.tgz", + "integrity": "sha512-OCVPnIObs4N29kxTjzLfUryOkvZEq+pf8jTF0lg8E7uETuWHA+v7j3c/xJmiqpX450191LlmZfUKkXxkTry7nA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/vite-node/node_modules/vite": { + "version": "5.4.11", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.11.tgz", + "integrity": "sha512-c7jFQRklXua0mTzneGW9QVyxFjUgwcihC4bXEtujIo2ouWCe1Ajt/amn2PCxYnhYfd5k09JX3SB7OYWFKYqj8Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "^0.21.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/vite-plugin-environment": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/vite-plugin-environment/-/vite-plugin-environment-1.1.3.tgz", + "integrity": "sha512-9LBhB0lx+2lXVBEWxFZC+WO7PKEyE/ykJ7EPWCq95NEcCpblxamTbs5Dm3DLBGzwODpJMEnzQywJU8fw6XGGGA==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "vite": ">= 2.7" + } + }, + "node_modules/vite-tsconfig-paths": { + "version": "5.1.4", + "resolved": "https://registry.npmjs.org/vite-tsconfig-paths/-/vite-tsconfig-paths-5.1.4.tgz", + "integrity": "sha512-cYj0LRuLV2c2sMqhqhGpaO3LretdtMn/BVX4cPLanIZuwwrkVl+lK84E/miEXkCHWXuq65rhNN4rXsBcOB3S4w==", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^4.1.1", + "globrex": "^0.1.2", + "tsconfck": "^3.0.3" + }, + "peerDependencies": { + "vite": "*" + }, + "peerDependenciesMeta": { + "vite": { + "optional": true + } + } + }, + "node_modules/vite/node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/vite/node_modules/postcss": { + "version": "8.4.49", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.49.tgz", + "integrity": "sha512-OCVPnIObs4N29kxTjzLfUryOkvZEq+pf8jTF0lg8E7uETuWHA+v7j3c/xJmiqpX450191LlmZfUKkXxkTry7nA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/vitest": { + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-2.1.8.tgz", + "integrity": "sha512-1vBKTZskHw/aosXqQUlVWWlGUxSJR8YtiyZDJAFeW2kPAeX6S3Sool0mjspO+kXLuxVWlEDDowBAeqeAQefqLQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/expect": "2.1.8", + "@vitest/mocker": "2.1.8", + "@vitest/pretty-format": "^2.1.8", + "@vitest/runner": "2.1.8", + "@vitest/snapshot": "2.1.8", + "@vitest/spy": "2.1.8", + "@vitest/utils": "2.1.8", + "chai": "^5.1.2", + "debug": "^4.3.7", + "expect-type": "^1.1.0", + "magic-string": "^0.30.12", + "pathe": "^1.1.2", + "std-env": "^3.8.0", + "tinybench": "^2.9.0", + "tinyexec": "^0.3.1", + "tinypool": "^1.0.1", + "tinyrainbow": "^1.2.0", + "vite": "^5.0.0", + "vite-node": "2.1.8", + "why-is-node-running": "^2.3.0" + }, + "bin": { + "vitest": "vitest.mjs" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "@edge-runtime/vm": "*", + "@types/node": "^18.0.0 || >=20.0.0", + "@vitest/browser": "2.1.8", + "@vitest/ui": "2.1.8", + "happy-dom": "*", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "@edge-runtime/vm": { + "optional": true + }, + "@types/node": { + "optional": true + }, + "@vitest/browser": { + "optional": true + }, + "@vitest/ui": { + "optional": true + }, + "happy-dom": { + "optional": true + }, + "jsdom": { + "optional": true + } + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/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" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/vitest/node_modules/@vitest/mocker": { + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-2.1.8.tgz", + "integrity": "sha512-7guJ/47I6uqfttp33mgo6ga5Gr1VnL58rcqYKyShoRK9ebu8T5Rs6HN3s1NABiBeVTdWNrwUMcHH54uXZBN4zA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/spy": "2.1.8", + "estree-walker": "^3.0.3", + "magic-string": "^0.30.12" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "msw": "^2.4.9", + "vite": "^5.0.0" + }, + "peerDependenciesMeta": { + "msw": { + "optional": true + }, + "vite": { + "optional": true + } + } + }, + "node_modules/vitest/node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, + "node_modules/vitest/node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/vitest/node_modules/postcss": { + "version": "8.4.49", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.49.tgz", + "integrity": "sha512-OCVPnIObs4N29kxTjzLfUryOkvZEq+pf8jTF0lg8E7uETuWHA+v7j3c/xJmiqpX450191LlmZfUKkXxkTry7nA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/vitest/node_modules/vite": { + "version": "5.4.11", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.11.tgz", + "integrity": "sha512-c7jFQRklXua0mTzneGW9QVyxFjUgwcihC4bXEtujIo2ouWCe1Ajt/amn2PCxYnhYfd5k09JX3SB7OYWFKYqj8Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "^0.21.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "license": "MIT", + "dependencies": { + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/warning": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/warning/-/warning-4.0.3.tgz", + "integrity": "sha512-rpJyN222KWIvHJ/F53XSZv0Zl/accqHR8et1kpaMTD/fLCRxtV8iX8czMzY7sVZupTI3zcUTg8eycS2kNF9l6w==", + "license": "MIT", + "dependencies": { + "loose-envify": "^1.0.0" + } }, "node_modules/web-vitals": { "version": "4.2.4", @@ -11645,9 +12621,9 @@ } }, "node_modules/whatwg-url": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.0.0.tgz", - "integrity": "sha512-1lfMEm2IEr7RIV+f4lUNPOqfFL+pO+Xw3fJSqmjX9AbXcXcYOkCe1P6+9VBZB6n94af16NfZf+sSk0JCBZC9aw==", + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.1.0.tgz", + "integrity": "sha512-jlf/foYIKywAt3x/XWKZ/3rz8OSJPiWktjmk891alJUEjiVxKX9LEO92qH3hv4aJ0mN3MWPvGMCy8jQi95xK4w==", "dev": true, "license": "MIT", "dependencies": { @@ -11675,42 +12651,45 @@ } }, "node_modules/which-boxed-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", - "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.1.1.tgz", + "integrity": "sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==", "dev": true, "license": "MIT", "dependencies": { - "is-bigint": "^1.0.1", - "is-boolean-object": "^1.1.0", - "is-number-object": "^1.0.4", - "is-string": "^1.0.5", - "is-symbol": "^1.0.3" + "is-bigint": "^1.1.0", + "is-boolean-object": "^1.2.1", + "is-number-object": "^1.1.1", + "is-string": "^1.1.1", + "is-symbol": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/which-builtin-type": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/which-builtin-type/-/which-builtin-type-1.2.0.tgz", - "integrity": "sha512-I+qLGQ/vucCby4tf5HsLmGueEla4ZhwTBSqaooS+Y0BuxN4Cp+okmGuV+8mXZ84KDI9BA+oklo+RzKg0ONdSUA==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/which-builtin-type/-/which-builtin-type-1.2.1.tgz", + "integrity": "sha512-6iBczoX+kDQ7a3+YJBnh3T+KZRxM/iYNPXicqk66/Qfm1b93iu+yOImkg0zHbj5LNOcNv1TEADiZ0xa34B4q6Q==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bound": "^1.0.2", "function.prototype.name": "^1.1.6", "has-tostringtag": "^1.0.2", "is-async-function": "^2.0.0", - "is-date-object": "^1.0.5", + "is-date-object": "^1.1.0", "is-finalizationregistry": "^1.1.0", "is-generator-function": "^1.0.10", - "is-regex": "^1.1.4", + "is-regex": "^1.2.1", "is-weakref": "^1.0.2", "isarray": "^2.0.5", - "which-boxed-primitive": "^1.0.2", + "which-boxed-primitive": "^1.1.0", "which-collection": "^1.0.2", - "which-typed-array": "^1.1.15" + "which-typed-array": "^1.1.16" }, "engines": { "node": ">= 0.4" @@ -11739,16 +12718,17 @@ } }, "node_modules/which-typed-array": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.15.tgz", - "integrity": "sha512-oV0jmFtUky6CXfkqehVvBP/LSWJ2sy4vWMioiENyJLePrBO/yKyV9OyJySfAKosh+RYkIl5zJCNZ8/4JncrpdA==", + "version": "1.1.18", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.18.tgz", + "integrity": "sha512-qEcY+KJYlWyLH9vNbsr6/5j59AXk5ni5aakf8ldzBvGde6Iz4sxZGkJyWSAueTG7QhOvNRYb1lDdFmL5Td0QKA==", "dev": true, "license": "MIT", "dependencies": { "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", "for-each": "^0.3.3", - "gopd": "^1.0.1", + "gopd": "^1.2.0", "has-tostringtag": "^1.0.2" }, "engines": { @@ -11885,12 +12865,18 @@ "license": "ISC" }, "node_modules/yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.6.1.tgz", + "integrity": "sha512-7r0XPzioN/Q9kXBro/XPnA6kznR73DHq+GXh5ON7ZozRO6aMjbmiBuKste2wslTFkC5d1dw0GooOCepZXJ2SAg==", + "dev": true, "license": "ISC", + "optional": true, + "peer": true, + "bin": { + "yaml": "bin.mjs" + }, "engines": { - "node": ">= 6" + "node": ">= 14" } }, "node_modules/yargs": { @@ -11922,16 +12908,6 @@ "node": ">=12" } }, - "node_modules/yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/yocto-queue": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", @@ -11959,9 +12935,9 @@ } }, "node_modules/yup": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/yup/-/yup-1.4.0.tgz", - "integrity": "sha512-wPbgkJRCqIf+OHyiTBQoJiP5PFuAXaWiJK6AmYkzQAh5/c2K9hzSApBZG5wV9KoKSePF7sAxmNSvh/13YHkFDg==", + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yup/-/yup-1.6.1.tgz", + "integrity": "sha512-JED8pB50qbA4FOkDol0bYF/p60qSEDQqBD0/qeIrUCG1KbPBIQ776fCUNb9ldbPcSTxA69g/47XTo4TqWiuXOA==", "license": "MIT", "dependencies": { "property-expr": "^2.0.5", diff --git a/apps/dolly-frontend/src/main/js/package.json b/apps/dolly-frontend/src/main/js/package.json index 846ac1e1cc0..e0a5b944fdc 100644 --- a/apps/dolly-frontend/src/main/js/package.json +++ b/apps/dolly-frontend/src/main/js/package.json @@ -1,6 +1,7 @@ { "name": "dolly", - "version": "3.0.47", + "version": "3.0.50", + "sideEffects": false, "type": "module", "description": "", "main": "index.js", @@ -12,7 +13,7 @@ "prettier": "prettier --write '**/*.{ts,tsx,js,css,html}'", "test:start": "vite --port 5678", "test:playwright-dev": "playwright test --ui", - "test:playwright-run": "playwright test", + "test:playwright-run": "vite build && playwright test", "test:playwright-debug": "playwright test --debug", "test:vitest-debug": "vitest --ui", "test:vitest-run": "vitest", @@ -33,12 +34,11 @@ "dayjs": "^1.11.13", "history": "^5.3.0", "immer": "^10.1.1", - "lodash": "^4.17.21", + "lodash-es": "^4.17.21", "rc-progress": "^4.0.0", "rc-tooltip": "^6.2.1", "react": "^18.3.1", "react-confetti-explosion": "^2.1.2", - "react-datepicker": "^7.5.0", "react-dom": "^18.3.1", "react-highlight-words": "^0.20.0", "react-hook-form": "^7.53.1", @@ -67,13 +67,11 @@ "@navikt/ds-icons": "^3.4.3", "@navikt/ds-react": "^7.4.0", "@playwright/test": "^1.48.2", - "@redux-devtools/extension": "^3.3.0", "@reduxjs/toolkit": "^2.3.0", "@testing-library/react": "^16.0.1", - "@types/lodash": "^4.17.13", + "@types/lodash-es": "^4.17.12", "@types/node": "^22.8.4", "@types/react": "^18.3.12", - "@types/react-datepicker": "^6.2.0", "@types/react-dom": "^18.3.1", "@types/react-highlight-words": "^0.20.0", "@types/react-redux": "^7.1.34", @@ -83,8 +81,8 @@ "@types/redux-actions": "^2.6.5", "@typescript-eslint/eslint-plugin": "^8.12.2", "@typescript-eslint/parser": "^8.12.2", - "@vitejs/plugin-react": "^4.3.3", - "@vitest/ui": "^2.1.4", + "@vitejs/plugin-react": "^4.3.4", + "@vitest/ui": "^2.1.6", "babel-plugin-styled-components": "^2.1.4", "dot-prop": "^9.0.0", "eslint": "^9.13.0", @@ -102,17 +100,17 @@ "react-router-dom": "^6.27.0", "sass": "^1.80.5", "swr": "^2.2.5", - "ts-node": "^10.9.2", "typescript": "^5.6.3", - "vite": "^5.4.10", + "vite": "^6.0.1", "vite-plugin-environment": "^1.1.3", - "vite-tsconfig-paths": "^5.0.1", - "vitest": "^2.1.4" + "vite-tsconfig-paths": "^5.1.3", + "vitest": "^2.1.6" }, "prettier": { "singleQuote": true, "semi": false, "useTabs": true, "printWidth": 100 - } + }, + "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e" } diff --git a/apps/dolly-frontend/src/main/js/playwright/mocks/BasicMocks.tsx b/apps/dolly-frontend/src/main/js/playwright/mocks/BasicMocks.tsx index 7518f066e45..ce86904ffba 100644 --- a/apps/dolly-frontend/src/main/js/playwright/mocks/BasicMocks.tsx +++ b/apps/dolly-frontend/src/main/js/playwright/mocks/BasicMocks.tsx @@ -23,8 +23,7 @@ export const personOrgTilgangMock = [ { navn: 'testytest', organisasjonsnummer: '12345678', - organisasjonsfrom: 'BEDR', - gyldigTil: '2100-10-10T10:10:10.100Z', + organisasjonsform: 'BEDR', }, ] diff --git a/apps/dolly-frontend/src/main/js/playwright/tests/Bankid.spec.ts b/apps/dolly-frontend/src/main/js/playwright/tests/Bankid.spec.ts index 10d86341dca..f832c6a7883 100644 --- a/apps/dolly-frontend/src/main/js/playwright/tests/Bankid.spec.ts +++ b/apps/dolly-frontend/src/main/js/playwright/tests/Bankid.spec.ts @@ -11,7 +11,7 @@ test.describe('Bankid testing', () => { headers: { 'content-type': 'application/json' }, }) }) - await page.route(new RegExp(/testnav-person-organisasjon-tilgang-service/), async (route) => { + await page.route(new RegExp(/altinn\/organisasjoner/), async (route) => { await route.fulfill({ status: 200, body: JSON.stringify(personOrgTilgangMock), diff --git a/apps/dolly-frontend/src/main/js/proxy-routes.json b/apps/dolly-frontend/src/main/js/proxy-routes.json index 843d1003414..ea55ec091c7 100644 --- a/apps/dolly-frontend/src/main/js/proxy-routes.json +++ b/apps/dolly-frontend/src/main/js/proxy-routes.json @@ -1,257 +1,165 @@ { "/api": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/oauth2/authorization/aad": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/oauth2/authorization/idporten": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/login/oauth2/code/aad": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/login/oauth2/code/idporten": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/logout": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/oauth2/logout": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/oauth2/callback": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/session/ping": { - "target": "http://localhost:8020", - "secure": false + "changeOrigin": false }, "/session/user": { + "changeOrigin": false + }, + "/altinn/organisasjoner": { "target": "http://localhost:8020", "secure": false }, "/testnav-organisasjon-faste-data-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/oppsummeringsdokument-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-tps-messaging-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-adresse-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-joark-dokument-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-histark-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-udistub-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-inntektstub-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-norg2-proxy/norg2": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-brregstub-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-arena-forvalteren-proxy": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-krrstub-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-fullmakt-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-inst-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-sigrunstub-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-aareg-proxy/": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-medl-proxy/rest": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-pensjon-testdata-facade-proxy/": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/dolly-backend/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/person-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnorge-profil-api/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, - "/testnav-organisasjon-tilgang-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "/testnav-altinn3-tilgang-service/api": { + "changeOrigin": true }, "/testnav-varslinger-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-organisasjon-forvalter/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-organisasjon-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-miljoer-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/udi-stub/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-person-search-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false - }, - "/testnav-person-organisasjon-tilgang-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-pdl-forvalter/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-bruker-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-kontoregister-person-proxy/api/system": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-skjermingsregister-proxy/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-dokarkiv-proxy": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-arbeidsplassencv-proxy": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-helsepersonell-service": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true + }, + "/testnav-sykemelding-api/api": { + "changeOrigin": true }, "/generer-navn-service": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-kodeverk-service": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-tenor-search-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-skattekort-service/api": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-levende-arbeidsforhold-ansettelse": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-levende-arbeidsforhold-scheduler": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true }, "/testnav-yrkesskade-proxy": { - "target": "http://localhost:8020", - "changeOrigin": true, - "secure": false + "changeOrigin": true } } \ No newline at end of file diff --git a/apps/dolly-frontend/src/main/js/src/allRoutes.tsx b/apps/dolly-frontend/src/main/js/src/allRoutes.tsx index 4b8045d2d5f..cf0d1c4c076 100644 --- a/apps/dolly-frontend/src/main/js/src/allRoutes.tsx +++ b/apps/dolly-frontend/src/main/js/src/allRoutes.tsx @@ -1,22 +1,27 @@ -import React, { lazy } from 'react' +import React from 'react' import { Navigate } from 'react-router-dom' -import GruppeConnector from '@/pages/gruppe/GruppeConnector' -import { OrganisasjonTenorSoekPage } from '@/pages/organisasjoner/OrganisasjonTenorSoek/OrganisasjonTenorSoekPage' -import NyansettelserPage from '@/pages/nyansettelser/NyansettelserPage' +import GruppeConnector from './pages/gruppe/GruppeConnector' +import { lazyWithPreload } from './utils/lazyWithPreload' -const GruppeOversikt = lazy(() => import('@/pages/gruppeOversikt/GruppeOversiktConnector')) -const Organisasjon = lazy(() => import('@/pages/organisasjoner/Organisasjoner')) -const BestillingsveilederConnector = lazy( +const OrganisasjonTenorSoekPage = lazyWithPreload( + () => import('@/pages/organisasjoner/OrganisasjonTenorSoek/OrganisasjonTenorSoekPage'), +) +const NyansettelserPage = lazyWithPreload(() => import('@/pages/nyansettelser/NyansettelserPage')) +const GruppeOversikt = lazyWithPreload( + () => import('@/pages/gruppeOversikt/GruppeOversiktConnector'), +) +const Organisasjon = lazyWithPreload(() => import('@/pages/organisasjoner/Organisasjoner')) +const BestillingsveilederConnector = lazyWithPreload( () => import('@/components/bestillingsveileder/BestillingsveilederConnector'), ) -const MinSide = lazy(() => import('@/pages/minSide/MinSide')) -const UI = lazy(() => import('@/pages/ui/index')) -const TestnorgePage = lazy(() => import('@/pages/testnorgePage/index')) -const Endringsmelding = lazy(() => import('@/pages/endringsmelding/Endringsmelding')) -const DollySoekPage = lazy(() => import('@/pages/dollySoek/DollySoekPage')) -const TenorSoekPage = lazy(() => import('@/pages/tenorSoek/TenorSoekPage')) -const OrgtilgangPage = lazy(() => import('@/pages/adminPages/Orgtilgang/OrgtilgangPage')) -const LevendeArbeidsforholdPage = lazy( +const MinSide = lazyWithPreload(() => import('@/pages/minSide/MinSide')) +const UI = lazyWithPreload(() => import('@/pages/ui/index')) +const TestnorgePage = lazyWithPreload(() => import('@/pages/testnorgePage/index')) +const Endringsmelding = lazyWithPreload(() => import('@/pages/endringsmelding/Endringsmelding')) +const DollySoekPage = lazyWithPreload(() => import('@/pages/dollySoek/DollySoekPage')) +const TenorSoekPage = lazyWithPreload(() => import('@/pages/tenorSoek/TenorSoekPage')) +const OrgtilgangPage = lazyWithPreload(() => import('@/pages/adminPages/Orgtilgang/OrgtilgangPage')) +const LevendeArbeidsforholdPage = lazyWithPreload( () => import('@/pages/adminPages/Levendearbeidsforhold/AppstyringPage'), ) @@ -24,67 +29,49 @@ const GruppeBreadcrumb = (props) => Gruppe #{props.match?.params?.gruppeId const allRoutes = [ { path: '/', breadcrumb: 'Hjem', element: () => }, - { - path: '/gruppe', - breadcrumb: 'Personer', - element: () => , - }, - { path: '/gruppe/:gruppeId', breadcrumb: GruppeBreadcrumb, element: () => }, + { path: '/gruppe', breadcrumb: 'Personer', element: GruppeOversikt }, + { path: '/gruppe/:gruppeId', breadcrumb: GruppeBreadcrumb, element: GruppeConnector }, { path: '/gruppe/:gruppeId/bestilling/:personId', breadcrumb: 'Legg til/endre', - element: () => , + element: BestillingsveilederConnector, }, { path: '/gruppe/:gruppeId/bestilling', breadcrumb: 'Opprett personer', - element: () => , - }, - { - path: '/organisasjoner', - breadcrumb: 'Organisasjoner', - element: () => , + element: BestillingsveilederConnector, }, + { path: '/organisasjoner', breadcrumb: 'Organisasjoner', element: Organisasjon }, { path: '/tenor/organisasjoner', breadcrumb: 'Søk i Tenor organisasjoner', - element: () => , + element: OrganisasjonTenorSoekPage, }, { path: '/organisasjoner/bestilling', breadcrumb: 'Opprett organisasjon', - element: () => , - }, - { path: '/minside', breadcrumb: 'Min side', element: () => }, - { path: '/ui', breadcrumb: 'UI demo', element: () => }, - { path: '/dollysoek', breadcrumb: 'Søk i Dolly', element: () => }, - { path: '/testnorge', breadcrumb: 'Søk i Test-Norge', element: () => }, - { path: '/tenor/personer', breadcrumb: 'Søk i Tenor personer', element: () => }, - { - path: '/importer', - breadcrumb: 'Importer', - element: () => , - }, - { - path: '/endringsmelding', - breadcrumb: 'Endringsmelding', - element: () => , - }, - { - path: '/admin/orgtilgang', - breadcrumb: 'Organisasjon-tilgang', - element: () => , + element: BestillingsveilederConnector, }, + { path: '/minside', breadcrumb: 'Min side', element: MinSide }, + { path: '/ui', breadcrumb: 'UI demo', element: UI }, + { path: '/dollysoek', breadcrumb: 'Søk i Dolly', element: DollySoekPage }, + { path: '/testnorge', breadcrumb: 'Søk i Test-Norge', element: TestnorgePage }, + { path: '/tenor/personer', breadcrumb: 'Søk i Tenor personer', element: TenorSoekPage }, + { path: '/importer', breadcrumb: 'Importer', element: BestillingsveilederConnector }, + { path: '/endringsmelding', breadcrumb: 'Endringsmelding', element: Endringsmelding }, + { path: '/admin/orgtilgang', breadcrumb: 'Organisasjon-tilgang', element: OrgtilgangPage }, { path: '/admin/levendearbeidsforhold', breadcrumb: 'Levende-arbeidsforhold', - element: () => , - }, - { - path: '/nyansettelser', - breadcrumb: 'Nyansettelser', - element: () => , + element: LevendeArbeidsforholdPage, }, + { path: '/nyansettelser', breadcrumb: 'Nyansettelser', element: NyansettelserPage }, ] +export const preloadComponentOnRoute = (path: string) => { + const matchingRoute: any = allRoutes.find((route) => route.path === path) + + matchingRoute?.element?.preload?.() +} + export default allRoutes diff --git a/apps/dolly-frontend/src/main/js/src/api/index.ts b/apps/dolly-frontend/src/main/js/src/api/index.ts index 980f62ff229..5337e221afa 100644 --- a/apps/dolly-frontend/src/main/js/src/api/index.ts +++ b/apps/dolly-frontend/src/main/js/src/api/index.ts @@ -90,8 +90,11 @@ export const multiFetcherDokarkiv = (miljoUrlListe) => ), ) -export const cvFetcher = (url, headers) => - axios +export const cvFetcher = (url, headers) => { + if (!url) { + return Promise.resolve(null) + } + return axios .get(url, { headers: headers }) .then((res) => { return res.data @@ -111,6 +114,12 @@ export const cvFetcher = (url, headers) => } throw new Error(`Henting av data fra ${url} feilet.`) }) +} + +export const sykemeldingFetcher = (url, body) => + axios.post(url, body).then((res) => { + return res.data + }) export const fetcher = (url, headers) => axios diff --git a/apps/dolly-frontend/src/main/js/src/app/App.tsx b/apps/dolly-frontend/src/main/js/src/app/App.tsx index 987b05128d0..9ed3c97eb7b 100644 --- a/apps/dolly-frontend/src/main/js/src/app/App.tsx +++ b/apps/dolly-frontend/src/main/js/src/app/App.tsx @@ -31,7 +31,6 @@ export const App = () => { const { loading, error: userError, currentBruker } = useCurrentBruker() - // Lazyloader miljøer, brukerens maler og profilData så det ligger cachet ved oppstart useDollyEnvironments() useBrukerProfil() useDollyMalerBrukerOgMalnavn(currentBruker?.brukerId) diff --git a/apps/dolly-frontend/src/main/js/src/components/bestilling/detaljer/BestillingDetaljer.tsx b/apps/dolly-frontend/src/main/js/src/components/bestilling/detaljer/BestillingDetaljer.tsx index 9dd7b731543..672847ab8b7 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestilling/detaljer/BestillingDetaljer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestilling/detaljer/BestillingDetaljer.tsx @@ -5,7 +5,7 @@ import GjenopprettConnector from '@/components/bestilling/gjenopprett/Gjenoppret import './BestillingDetaljer.less' import { MalModal, malTyper } from '@/pages/minSide/maler/MalModal' -import _ from 'lodash' +import * as _ from 'lodash-es' import { SlettButton } from '@/components/ui/button/SlettButton/SlettButton' import React from 'react' import { DollyApi } from '@/service/Api' diff --git a/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/kriterier/BestillingKriterieMapper.tsx b/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/kriterier/BestillingKriterieMapper.tsx index 99670b44fbf..0e4384b262d 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/kriterier/BestillingKriterieMapper.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/kriterier/BestillingKriterieMapper.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { allCapsToCapitalized, arrayToString, @@ -21,8 +21,6 @@ import { } from '@/config/kodeverk' import { isEmpty } from '@/components/fagsystem/pdlf/form/partials/utils' import { SelectOptionsManager as Options } from '@/service/SelectOptions' -import _get from 'lodash/get' -import _has from 'lodash/has' import { MedlKodeverk } from '@/components/fagsystem/medl/MedlConstants' import { useNavEnheter } from '@/utils/hooks/useNorg2' import { kodeverkKeyToLabel } from '@/components/fagsystem/sigrunstubPensjonsgivende/utils' @@ -1278,7 +1276,7 @@ const mapInntektStub = (bestillingData, data) => { } const mapArbeidsplassenCV = (bestillingData, data) => { - const CVKriterier = _get(bestillingData, 'arbeidsplassenCV') + const CVKriterier = _.get(bestillingData, 'arbeidsplassenCV') if (CVKriterier) { const arbeidsplassenCV = { @@ -1443,7 +1441,7 @@ const mapArbeidsplassenCV = (bestillingData, data) => { ]) } - if (_has(CVKriterier, 'harHjemmel')) { + if (_.has(CVKriterier, 'harHjemmel')) { arbeidsplassenCV.itemRows.push([ { numberHeader: 'Hjemmel' }, { @@ -1535,6 +1533,17 @@ const mapSykemelding = (bestillingData, data) => { 'Hensyn på arbeidsplass', _.get(sykemeldingKriterier.detaljertSykemelding, 'detaljer.beskrivHensynArbeidsplassen'), ), + obj( + 'Begrunnelse ikke kontakt', + _.get( + sykemeldingKriterier.detaljertSykemelding, + 'kontaktMedPasient.begrunnelseIkkeKontakt', + ), + ), + obj( + 'Kontaktdato', + formatDate(sykemeldingKriterier.detaljertSykemelding?.kontaktMedPasient?.kontaktDato), + ), obj( 'Arbeidsfør etter endt periode', sykemeldingKriterier.detaljertSykemelding.detaljer && @@ -1722,6 +1731,7 @@ const mapInst = (bestillingData, data) => { institusjonstype: i.institusjonstype, varighet: i.varighet, startdato: i.startdato, + forventetSluttdato: i.forventetSluttdato, sluttdato: i.sluttdato, }) }) @@ -1739,6 +1749,7 @@ const mapInst = (bestillingData, data) => { obj('Institusjonstype', showLabel('institusjonstype', inst.institusjonstype)), obj('Varighet', inst.varighet && showLabel('varighet', inst.varighet)), obj('Startdato', formatDate(inst.startdato)), + obj('Forventet sluttdato', formatDate(inst.forventetSluttdato)), obj('Sluttdato', formatDate(inst.sluttdato)), ]) }) diff --git a/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/miljoeStatus/MiljoeStatus.tsx b/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/miljoeStatus/MiljoeStatus.tsx index cac1394f56e..76710c6246c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/miljoeStatus/MiljoeStatus.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestilling/sammendrag/miljoeStatus/MiljoeStatus.tsx @@ -2,7 +2,7 @@ import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import FagsystemStatus from './fagsystemStatus/FagsystemStatus' import ApiFeilmelding from '@/components/ui/apiFeilmelding/ApiFeilmelding' import antallIdenterOpprettet from '@/components/bestilling/utils/antallIdenterOpprettet' -import _ from 'lodash' +import * as _ from 'lodash-es' import React from 'react' export type Miljostatus = { diff --git a/apps/dolly-frontend/src/main/js/src/components/bestilling/statusListe/StatusListe.tsx b/apps/dolly-frontend/src/main/js/src/components/bestilling/statusListe/StatusListe.tsx index 49bb5eca391..c4c502daf52 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestilling/statusListe/StatusListe.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestilling/statusListe/StatusListe.tsx @@ -4,7 +4,7 @@ import Loading from '@/components/ui/loading/Loading' import BestillingResultat from './BestillingResultat/BestillingResultat' import { BestillingProgresjon } from '@/components/bestilling/statusListe/BestillingProgresjon/BestillingProgresjon' import { Bestillingsstatus } from '@/utils/hooks/useOrganisasjoner' -import _has from 'lodash/has' +import * as _ from 'lodash-es' type StatusProps = { gruppeId: string @@ -54,7 +54,7 @@ const StatusListe = ({ bestillingListe, cancelBestilling, isCanceling }: StatusP @@ -65,7 +65,7 @@ const StatusListe = ({ bestillingListe, cancelBestilling, isCanceling }: StatusP key={ferdig.id} bestilling={ferdig} lukkBestilling={lukkBestilling} - erOrganisasjon={_has(ferdig, 'organisasjonNummer')} + erOrganisasjon={_.has(ferdig, 'organisasjonNummer')} /> )) diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/SwrMutateContext.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/SwrMutateContext.tsx new file mode 100644 index 00000000000..3f83f3370b5 --- /dev/null +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/SwrMutateContext.tsx @@ -0,0 +1,3 @@ +import React from 'react' + +export const SwrMutateContext: any = React.createContext(undefined) diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/VisAttributt.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/VisAttributt.tsx index 8b931749563..4e7bac5a5e7 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/VisAttributt.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/VisAttributt.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { useFormContext } from 'react-hook-form' export const Vis = ({ attributt, children }) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/options/malOptions.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/options/malOptions.tsx index d64c243ff97..ebd28209b41 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/options/malOptions.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/options/malOptions.tsx @@ -1,5 +1,5 @@ import { initialValues } from './utils' -import _ from 'lodash' +import * as _ from 'lodash-es' import { filterMiljoe } from '@/components/miljoVelger/MiljoeInfo' import { BostedData, diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/EksisterendeIdent/EksisterendeIdent.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/EksisterendeIdent/EksisterendeIdent.tsx index b05470e3a41..ecc2c99b777 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/EksisterendeIdent/EksisterendeIdent.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/EksisterendeIdent/EksisterendeIdent.tsx @@ -1,6 +1,6 @@ import React, { BaseSyntheticEvent, useState } from 'react' import { useAsyncFn } from 'react-use' -import _ from 'lodash' +import * as _ from 'lodash-es' import NavButton from '@/components/ui/button/NavButton/NavButton' import { PdlforvalterApi } from '@/service/Api' import Loading from '@/components/ui/loading/Loading' diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/NyIdent/NyIdent.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/NyIdent/NyIdent.tsx index af2042161b4..794f40dc717 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/NyIdent/NyIdent.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/NyIdent/NyIdent.tsx @@ -11,7 +11,7 @@ import { Alert } from '@navikt/ds-react' import ModalActionKnapper from '@/components/ui/modal/ModalActionKnapper' import styled from 'styled-components' -import _ from 'lodash' +import * as _ from 'lodash-es' import { tpsfAttributter } from '@/components/bestillingsveileder/utils' import { Mal, useDollyMaler } from '@/utils/hooks/useMaler' import { TestComponentSelectors } from '#/mocks/Selectors' diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/StartModal.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/StartModal.tsx index 00fccb654b3..1a70862946c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/StartModal.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/startModal/StartModal.tsx @@ -3,9 +3,7 @@ import { DollyModal } from '@/components/ui/modal/DollyModal' import { NyBestillingProps, NyIdent } from './NyIdent/NyIdent' import { EksisterendeIdent } from './EksisterendeIdent/EksisterendeIdent' import styled from 'styled-components' - import './startModal.less' - import { ToggleGroup } from '@navikt/ds-react' import { TestComponentSelectors } from '#/mocks/Selectors' @@ -14,7 +12,7 @@ const StyledToggleGroup = styled(ToggleGroup)` margin-bottom: 20px; ` -export const BestillingsveilederModal = ({ onAvbryt, onSubmit, brukernavn }: NyBestillingProps) => { +const BestillingsveilederModal = ({ onAvbryt, onSubmit, brukernavn }: NyBestillingProps) => { const [type, setType] = useState('ny') return ( @@ -44,3 +42,5 @@ export const BestillingsveilederModal = ({ onAvbryt, onSubmit, brukernavn }: NyB ) } + +export default BestillingsveilederModal diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stateModifier.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stateModifier.tsx index 05fb3d88bbe..434ed1a1d3f 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stateModifier.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stateModifier.tsx @@ -1,77 +1,73 @@ -import _, { isArray } from 'lodash' -import { UseFormReturn } from 'react-hook-form/dist/types' import { useContext } from 'react' +import { UseFormReturn } from 'react-hook-form' import { BestillingsveilederContext } from './BestillingsveilederContext' +import * as _ from 'lodash-es' -export const useStateModifierFns = (formMethods: UseFormReturn) => { +export const useStateModifierFns = (formMethods: UseFormReturn, setFormMutate: any) => { + const { setValue, watch, resetField, getValues, reset, formState } = formMethods const opts = useContext(BestillingsveilederContext) - const set = (path, value) => { - formMethods.setValue(path, value) - } - const has = (path) => { - return formMethods.watch(path) !== undefined - } - const values = (path) => { - return formMethods.watch(path) - } - const del = (path) => { - if (isArray(path)) { - path.forEach((p) => { - formMethods.resetField(p) - }) + + const set = (path: string, value: any) => setValue(path, value) + const has = (path: string) => watch(path) !== undefined + const values = (path: string) => watch(path) + const delMutate = () => setFormMutate?.(() => undefined) + + const del = (path: string | string[]) => { + if (Array.isArray(path)) { + path.forEach((p) => resetField(p)) } else { - formMethods.resetField(path) + resetField(path) } - let newObj = _.omit(formMethods.getValues(), path) + let newObj = _.omit(getValues(), path) // Ingen tomme objekter guard let rootPath = Array.isArray(path) ? path[0].split('.')[0] : path.split('.')[0] if (path.includes('pdldata.person') || path[0].includes('pdldata.person')) rootPath = 'pdldata.person' if (_.isEmpty(_.get(newObj, rootPath))) newObj = _.omit(newObj, rootPath) - - formMethods.reset(newObj) + reset(newObj) } - const setMulti = (...arrays) => { - arrays.forEach((curr) => { - const [path, val] = curr - formMethods.setValue(path, val) - }) + + const setMulti = (...arrays: [string, any][]) => { + arrays.forEach(([path, val]) => setValue(path, val)) } - const allCheckedLabels = (attrs) => + const allCheckedLabels = (attrs: Record) => Object.values(attrs) .filter((a) => a.checked) .map((b) => b.label) - const batchUpdate = (attrs, ignoreKeys = [], key = 'add') => { + const batchUpdate = ( + attrs: Record, + ignoreKeys: string[] = [], + key: 'add' | 'remove', + ) => { + delMutate() Object.entries(attrs) - .filter(([name, value]) => { - return !ignoreKeys?.includes(name) - }) - .forEach(([_name, value]: [name: string, value: any]) => { - value[key]() // Call add or remove method - }) + .filter(([name]) => !ignoreKeys.includes(name)) + .forEach(([, value]) => value[key]()) } return ( - fn: (arg0: { - set: (path: any, value: any) => any - setMulti: (...arrays: any[]) => void + fn: (args: { + set: (path: string, value: any) => void + setMulti: (...arrays: [string, any][]) => void opts: any - del: (path: any) => void - has: (path: any) => boolean - values: (path: any) => any - methods: any - }) => {}, + del: (path: string | string[]) => void + delMutate: () => void + has: (path: string) => boolean + values: (path: string) => any + methods: UseFormReturn + }) => Record, ) => { - const attrs = fn({ set, setMulti, opts, del, has, values, methods: formMethods }) || {} + const attrs = + fn({ set, setMulti, opts, del, delMutate, has, values, methods: formMethods }) || {} const checked = allCheckedLabels(attrs) return { attrs, checked, - batchAdd: (ignoreKeys: never[] | undefined) => batchUpdate(attrs, ignoreKeys, 'add'), - batchRemove: (ignoreKeys: never[] | undefined) => batchUpdate(attrs, ignoreKeys, 'remove'), + batchAdd: (ignoreKeys?: string[]) => batchUpdate(attrs, ignoreKeys, 'add'), + batchRemove: (ignoreKeys?: string[]) => batchUpdate(attrs, ignoreKeys, 'remove'), } } } diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/Navigation/Navigation.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/Navigation/Navigation.tsx index c06c79146d1..94b7909fafe 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/Navigation/Navigation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/Navigation/Navigation.tsx @@ -13,7 +13,7 @@ import { ShowErrorContextType, } from '@/components/bestillingsveileder/ShowErrorContext' -export const Navigation = ({ step, onPrevious, isLastStep, handleSubmit }) => { +export const Navigation = ({ step, onPrevious, isLastStep, mutateLoading, handleSubmit }: any) => { const showPrevious = step > 0 const errorContext: ShowErrorContextType = useContext(ShowErrorContext) const opts: any = useContext(BestillingsveilederContext) @@ -62,8 +62,10 @@ export const Navigation = ({ step, onPrevious, isLastStep, handleSubmit }) => { Videre diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/StegVelger.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/StegVelger.tsx index 9adb83942f8..130c603ed04 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/StegVelger.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/StegVelger.tsx @@ -1,12 +1,7 @@ -import React, { useContext, useState } from 'react' +import React, { Suspense, useContext, useState } from 'react' import { Navigation } from './Navigation/Navigation' import { useStateModifierFns } from '../stateModifier' import { BestillingsveilederHeader } from '../BestillingsveilederHeader' - -import { Steg1 } from './steg/steg1/Steg1' -import { Steg2 } from './steg/steg2/Steg2' -import { Steg3 } from './steg/steg3/Steg3' -import DisplayFormState from '@/utils/DisplayFormState' import { REGEX_BACKEND_BESTILLINGER, REGEX_BACKEND_GRUPPER, @@ -16,15 +11,29 @@ import { import { Stepper } from '@navikt/ds-react' import { FormProvider, useForm } from 'react-hook-form' import { yupResolver } from '@hookform/resolvers/yup' -import DisplayFormErrors from '@/utils/DisplayFormErrors' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' import { ShowErrorContext, ShowErrorContextType, } from '@/components/bestillingsveileder/ShowErrorContext' -import { DollyValidation } from './steg/steg2/DollyValidation' +import { SwrMutateContext } from '@/components/bestillingsveileder/SwrMutateContext' +import Loading from '@/components/ui/loading/Loading' +import { DollyValidation } from '@/components/bestillingsveileder/stegVelger/steg/steg2/DollyValidation' +import { lazyWithPreload } from '@/utils/lazyWithPreload' + +const Steg1 = lazyWithPreload(() => import('./steg/steg1/Steg1')) +const Steg2 = lazyWithPreload(() => import('./steg/steg2/Steg2')) +const Steg3 = lazyWithPreload(() => import('./steg/steg3/Steg3')) + +Steg1.label = 'Velg egenskaper' +Steg2.label = 'Velg verdier' +Steg3.label = 'Oppsummering' + +const DisplayFormState = lazyWithPreload(() => import('@/utils/DisplayFormState')) +const DisplayFormErrors = lazyWithPreload(() => import('@/utils/DisplayFormErrors')) const STEPS = [Steg1, Steg2, Steg3] +const manualMutateFields = ['manual.sykemelding.detaljertSykemelding'] export const devEnabled = window.location.hostname.includes('localhost') || @@ -32,9 +41,13 @@ export const devEnabled = export const StegVelger = ({ initialValues, onSubmit }) => { const context: any = useContext(BestillingsveilederContext) - const [loading, setLoading] = useState(false) const errorContext: ShowErrorContextType = useContext(ShowErrorContext) + + const [formMutate, setFormMutate] = useState(() => null as any) + const [mutateLoading, setMutateLoading] = useState(false) + const [loading, setLoading] = useState(false) const [step, setStep] = useState(0) + const CurrentStepComponent: any = STEPS[step] const stepMaxIndex = STEPS.length - 1 const formMethods = useForm({ @@ -43,14 +56,15 @@ export const StegVelger = ({ initialValues, onSubmit }) => { resolver: yupResolver(DollyValidation), context: context, }) - const stateModifier = useStateModifierFns(formMethods) + const stateModifier = useStateModifierFns(formMethods, setFormMutate) - const mutate = useMatchMutate() + const matchMutate = useMatchMutate() - const validationPaths = Object.keys(DollyValidation?.fields) + const validationPaths = Object.keys(DollyValidation.fields) const isLastStep = () => step === STEPS.length - 1 - const handleNext = () => { + + const validateForm = () => { formMethods.trigger(validationPaths).then(() => { const errorFelter = Object.keys(formMethods.formState.errors) const kunEnvironmentError = errorFelter.length === 1 && errorFelter[0] === 'environments' @@ -65,6 +79,23 @@ export const StegVelger = ({ initialValues, onSubmit }) => { }) } + const handleNext = () => { + if (step === 1 && formMutate) { + formMethods.clearErrors(manualMutateFields) + errorContext?.setShowError(true) + setMutateLoading(true) + formMutate?.().then((response) => { + setMutateLoading(false) + if (response.status === 'INVALID') { + return + } + validateForm() + }) + } else { + validateForm() + } + } + const handleBack = () => { errorContext?.setShowError(false) if (step !== 0) setStep(step - 1) @@ -82,44 +113,49 @@ export const StegVelger = ({ initialValues, onSubmit }) => { formMethods.handleSubmit(onSubmit(values)) formMethods.reset() - mutate(REGEX_BACKEND_GRUPPER) - mutate(REGEX_BACKEND_ORGANISASJONER) - mutate(REGEX_BACKEND_BESTILLINGER) + matchMutate(REGEX_BACKEND_GRUPPER) + matchMutate(REGEX_BACKEND_ORGANISASJONER) + matchMutate(REGEX_BACKEND_BESTILLINGER) } const labels = STEPS.map((v) => ({ label: v.label })) return ( - - - {labels.map((label, index) => ( - index < stepMaxIndex && setStep(index)} - > - {label.label} - - ))} - - - - {devEnabled && ( - <> - - - - )} - {!loading && ( - { - return _handleSubmit(formMethods.getValues()) - }} - /> - )} - + + + + {labels.map((label, index) => ( + index < stepMaxIndex && setStep(index)} + > + {label.label} + + ))} + + + }> + + + {devEnabled && ( + }> + + + + )} + {!loading && ( + { + return _handleSubmit(formMethods.getValues()) + }} + /> + )} + + ) } diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/Steg1.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/Steg1.tsx index 09cd4f4dd8a..7badcc8871b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/Steg1.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/Steg1.tsx @@ -3,7 +3,7 @@ import { BestillingsveilederContext } from '@/components/bestillingsveileder/Bes import { Steg1Person } from './Steg1Person' import { Steg1Organisasjon } from './Steg1Organisasjon' -export const Steg1 = ({ stateModifier }) => { +const Steg1 = ({ stateModifier }) => { const opts: any = useContext(BestillingsveilederContext) return opts.is.nyOrganisasjon || @@ -15,4 +15,4 @@ export const Steg1 = ({ stateModifier }) => { ) } -Steg1.label = 'Velg egenskaper' +export default Steg1 diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Arbeidsplassen.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Arbeidsplassen.tsx index 89aef3229c2..85508380e44 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Arbeidsplassen.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Arbeidsplassen.tsx @@ -18,8 +18,7 @@ import { initialSpraakVerdier, initialUtdanningVerdier, } from '@/components/fagsystem/arbeidsplassen/form/initialValues' -import _has from 'lodash/has' -import { isBoolean } from 'lodash' +import * as _ from 'lodash-es' export const ArbeidsplassenPanel = ({ stateModifier, formValues }) => { const sm = stateModifier(ArbeidsplassenPanel.initialValues) @@ -59,7 +58,7 @@ ArbeidsplassenPanel.initialValues = ({ setMulti, opts, del, has, values }) => { const hjemmel = () => { if (has('arbeidsplassenCV.harHjemmel')) { return values('arbeidsplassenCV.harHjemmel') - } else if (isBoolean(personFoerLeggTilHarHjemmel)) { + } else if (_.isBoolean(personFoerLeggTilHarHjemmel)) { return personFoerLeggTilHarHjemmel } return true @@ -70,8 +69,8 @@ ArbeidsplassenPanel.initialValues = ({ setMulti, opts, del, has, values }) => { if ( selected?.arbeidsplassenCV && Object.keys(selected?.arbeidsplassenCV)?.length === 2 && - _has(selected, fjernPath) && - _has(selected, 'arbeidsplassenCV.harHjemmel') + _.has(selected, fjernPath) && + _.has(selected, 'arbeidsplassenCV.harHjemmel') ) { return [fjernPath, 'arbeidsplassenCV.harHjemmel'] } diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Dokarkiv.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Dokarkiv.tsx index 76dfe056b2a..68e6143b2e1 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Dokarkiv.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Dokarkiv.tsx @@ -1,12 +1,10 @@ import Panel from '@/components/ui/panel/Panel' import { Attributt, AttributtKategori } from '../Attributt' import { harValgtAttributt } from '@/components/ui/form/formUtils' -import { dokarkivAttributt } from '@/components/fagsystem/dokarkiv/form/DokarkivForm' import { initialDigitalInnsending, initialDokarkiv, } from '@/components/fagsystem/arbeidsplassen/form/initialValues' -import { histarkAttributt } from '@/components/fagsystem/histark/form/HistarkForm' import { initialHistark } from '@/components/fagsystem/histark/form/initialValues' export const DokarkivPanel = ({ stateModifier, formValues }: any) => { @@ -19,7 +17,7 @@ export const DokarkivPanel = ({ stateModifier, formValues }: any) => { checkAttributeArray={() => sm.batchAdd(['digitalInnsending', 'histark'])} uncheckAttributeArray={sm.batchRemove} iconType="dokarkiv" - startOpen={harValgtAttributt(formValues, [dokarkivAttributt, histarkAttributt])} + startOpen={harValgtAttributt(formValues, ['dokarkiv', 'histark'])} > ({ { institusjonstype: runningE2ETest() ? 'AS' : '', startdato: runningE2ETest() ? new Date() : '', + forventetSluttdato: '', sluttdato: '', }, ]) diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Personinformasjon.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Personinformasjon.tsx index 27cd4af4c8b..d772a16ac3c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Personinformasjon.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Personinformasjon.tsx @@ -1,5 +1,5 @@ import React, { useContext } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import Panel from '@/components/ui/panel/Panel' import { Attributt, AttributtKategori } from '../Attributt' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Sykdom.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Sykdom.tsx index 7ce326579ab..36392f4fb1c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Sykdom.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg1/paneler/Sykdom.tsx @@ -41,7 +41,7 @@ export const SykdomPanel = ({ stateModifier, formValues }: any) => { SykdomPanel.heading = 'Sykdom og skade' -SykdomPanel.initialValues = ({ set, del, has }: any) => ({ +SykdomPanel.initialValues = ({ set, del, delMutate, has }: any) => ({ sykemelding: { label: 'Har sykemelding', checked: has('sykemelding'), @@ -56,6 +56,7 @@ SykdomPanel.initialValues = ({ set, del, has }: any) => ({ }, remove() { del('sykemelding') + delMutate?.() }, }, yrkesskader: { diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/DollyValidation.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/DollyValidation.tsx index b16c33845fb..c0366f0f4dd 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/DollyValidation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/DollyValidation.tsx @@ -9,13 +9,11 @@ import { ArenaForm } from '@/components/fagsystem/arena/form/Form' import { InstForm } from '@/components/fagsystem/inst/form/Form' import { UdistubForm } from '@/components/fagsystem/udistub/form/Form' import { PensjonForm } from '@/components/fagsystem/pensjon/form/Form' -import { DokarkivForm } from '@/components/fagsystem/dokarkiv/form/DokarkivForm' import { MedlForm } from '@/components/fagsystem/medl/form/MedlForm' import { SykdomForm } from '@/components/fagsystem/sykdom/form/Form' import { OrganisasjonForm } from '@/components/fagsystem/organisasjoner/form/Form' import { SkjermingForm } from '@/components/fagsystem/skjermingsregister/form/SkjermingForm' import { ArbeidsplassenForm } from '@/components/fagsystem/arbeidsplassen/form/Form' -import { HistarkForm } from '@/components/fagsystem/histark/form/HistarkForm' import { SigrunstubPensjonsgivendeForm } from '@/components/fagsystem/sigrunstubPensjonsgivende/form/Form' import { KrrstubForm } from '@/components/fagsystem/krrstub/form/KrrForm' import { MiljoVelger } from '@/components/miljoVelger/MiljoVelger' @@ -24,6 +22,8 @@ import { VelgGruppe } from '@/components/bestillingsveileder/stegVelger/steg/ste import { SkattekortForm } from '@/components/fagsystem/skattekort/form/Form' import { FullmaktForm } from '@/components/fagsystem/fullmakt/form/FullmaktForm' import { YrkesskaderForm } from '@/components/fagsystem/yrkesskader/form/Form' +import { dokarkivValidation } from '@/components/fagsystem/dokarkiv/form/DokarkivValidation' +import { histarkValidation } from '@/components/fagsystem/histark/form/HistarkValidation' export const DollyValidation = Yup.object({ ...PdlfForm.validation, @@ -44,8 +44,8 @@ export const DollyValidation = Yup.object({ ...UdistubForm.validation, ...SkjermingForm.validation, ...FullmaktForm.validation, - ...DokarkivForm.validation, - ...HistarkForm.validation, + ...dokarkivValidation, + ...histarkValidation, ...OrganisasjonForm.validation, ...MiljoVelger.validation, ...PensjonForm.validation, diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/Steg2.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/Steg2.tsx index f0a7475a5b4..8e674756dbb 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/Steg2.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg2/Steg2.tsx @@ -1,4 +1,4 @@ -import React, { useContext, useEffect } from 'react' +import React, { lazy, Suspense, useContext, useEffect } from 'react' import { harAvhukedeAttributter } from '@/components/bestillingsveileder/utils' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' import { SigrunstubForm } from '@/components/fagsystem/sigrunstub/form/Form' @@ -6,12 +6,10 @@ import { InntektstubForm } from '@/components/fagsystem/inntektstub/form/Form' import { InntektsmeldingForm } from '@/components/fagsystem/inntektsmelding/form/Form' import { AaregForm } from '@/components/fagsystem/aareg/form/Form' import { BrregstubForm } from '@/components/fagsystem/brregstub/form/Form' -import { PdlfForm } from '@/components/fagsystem/pdlf/form/Form' import { ArenaForm } from '@/components/fagsystem/arena/form/Form' import { InstForm } from '@/components/fagsystem/inst/form/Form' import { UdistubForm } from '@/components/fagsystem/udistub/form/Form' import { PensjonForm } from '@/components/fagsystem/pensjon/form/Form' -import { DokarkivForm } from '@/components/fagsystem/dokarkiv/form/DokarkivForm' import { MedlForm } from '@/components/fagsystem/medl/form/MedlForm' import { SykdomForm } from '@/components/fagsystem/sykdom/form/Form' import { OrganisasjonForm } from '@/components/fagsystem/organisasjoner/form/Form' @@ -19,7 +17,6 @@ import { TjenestepensjonForm } from '@/components/fagsystem/tjenestepensjon/form import { Alert } from '@navikt/ds-react' import { AlderspensjonForm } from '@/components/fagsystem/alderspensjon/form/Form' import { ArbeidsplassenForm } from '@/components/fagsystem/arbeidsplassen/form/Form' -import { HistarkForm } from '@/components/fagsystem/histark/form/HistarkForm' import { UforetrygdForm } from '@/components/fagsystem/uforetrygd/form/Form' import { SigrunstubPensjonsgivendeForm } from '@/components/fagsystem/sigrunstubPensjonsgivende/form/Form' import { KrrstubForm } from '@/components/fagsystem/krrstub/form/KrrForm' @@ -29,6 +26,11 @@ import { PensjonsavtaleForm } from '@/components/fagsystem/pensjonsavtale/form/F import { FullmaktForm } from '@/components/fagsystem/fullmakt/form/FullmaktForm' import { AfpOffentligForm } from '@/components/fagsystem/afpOffentlig/form/Form' import { YrkesskaderForm } from '@/components/fagsystem/yrkesskader/form/Form' +import Loading from '@/components/ui/loading/Loading' +import { PdlfForm } from '@/components/fagsystem/pdlf/form/Form' + +const HistarkForm = lazy(() => import('@/components/fagsystem/histark/form/HistarkForm')) +const DokarkivForm = lazy(() => import('@/components/fagsystem/dokarkiv/form/DokarkivForm')) const gruppeNavn = (gruppe) => {gruppe.navn} @@ -47,7 +49,7 @@ const getEmptyMessage = (leggTil, importTestnorge, gruppe = null) => { return 'Du har ikke valgt noen egenskaper. Dolly oppretter personer med tilfeldige verdier.' } -export const Steg2 = () => { +const Steg2 = () => { const opts: any = useContext(BestillingsveilederContext) const formMethods = useFormContext() @@ -90,11 +92,13 @@ export const Steg2 = () => { - - + }> + + + ) } -Steg2.label = 'Velg verdier' +export default Steg2 diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg3/Steg3.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg3/Steg3.tsx index a10e434b39c..7d11fd49dfa 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg3/Steg3.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/stegVelger/steg/steg3/Steg3.tsx @@ -16,7 +16,7 @@ const Bestillingskriterier = React.lazy( () => import('@/components/bestilling/sammendrag/kriterier/Bestillingskriterier'), ) -export const Steg3 = ({ loadingBestilling }: { loadingBestilling: boolean }) => { +const Steg3 = ({ loadingBestilling }: { loadingBestilling: boolean }) => { const opts = useContext(BestillingsveilederContext) const formMethods = useFormContext() const { currentBruker } = useCurrentBruker() @@ -142,4 +142,4 @@ export const Steg3 = ({ loadingBestilling }: { loadingBestilling: boolean }) => ) } -Steg3.label = 'Oppsummering' +export default Steg3 diff --git a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/utils.tsx b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/utils.tsx index 9ff64d4609f..3c9a201329e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/utils.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/bestillingsveileder/utils.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' export const tpsfAttributter = [ 'harMellomnavn', diff --git a/apps/dolly-frontend/src/main/js/src/components/codeView/CodeView.tsx b/apps/dolly-frontend/src/main/js/src/components/codeView/CodeView.tsx deleted file mode 100644 index b17440fa6cd..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/codeView/CodeView.tsx +++ /dev/null @@ -1,19 +0,0 @@ -import SyntaxHighlighter from 'react-syntax-highlighter' -import styled from 'styled-components' - -const StyledSyntaxHighlighter = styled(SyntaxHighlighter)` - font-size: 0.9em; - width: 100%; -` - -type Props = { - code: string - language: string - wrapLongLines?: boolean -} - -export default ({ code, language, wrapLongLines = false }: Props) => ( - - {code} - -) diff --git a/apps/dolly-frontend/src/main/js/src/components/codeView/PrettyCode.tsx b/apps/dolly-frontend/src/main/js/src/components/codeView/PrettyCode.tsx new file mode 100644 index 00000000000..b6789ad847e --- /dev/null +++ b/apps/dolly-frontend/src/main/js/src/components/codeView/PrettyCode.tsx @@ -0,0 +1,27 @@ +import styled from 'styled-components' +import { Light as SyntaxHighlighter } from 'react-syntax-highlighter' +import xml from 'react-syntax-highlighter/dist/esm/languages/hljs/xml' +import json from 'react-syntax-highlighter/dist/esm/languages/hljs/json' +import { defaultStyle } from 'react-syntax-highlighter/dist/esm/styles/hljs' + +SyntaxHighlighter.registerLanguage('xml', xml) +SyntaxHighlighter.registerLanguage('json', json) + +const StyledSyntaxHighlighter = styled(SyntaxHighlighter)` + font-size: 0.9em; + width: 100%; +` + +type Props = { + codeString: string + wrapLongLines?: boolean + language?: string +} + +const PrettyCode = ({ codeString, wrapLongLines = false, language }: Props) => ( + + {codeString} + +) + +export default PrettyCode diff --git a/apps/dolly-frontend/src/main/js/src/components/codeView/index.tsx b/apps/dolly-frontend/src/main/js/src/components/codeView/index.tsx deleted file mode 100644 index 488b2645a00..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/codeView/index.tsx +++ /dev/null @@ -1 +0,0 @@ -export { default as CodeView } from './CodeView' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/partials/arbeidsforholdForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/partials/arbeidsforholdForm.tsx index d4380163c2b..205acbdd308 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/partials/arbeidsforholdForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/partials/arbeidsforholdForm.tsx @@ -17,7 +17,7 @@ import { } from '../initialValues' import { isDate } from 'date-fns' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' -import _ from 'lodash' +import * as _ from 'lodash-es' import { fixTimezone } from '@/components/ui/form/formUtils' import { useFormContext } from 'react-hook-form' import { hentAaregEksisterendeData } from '@/components/fagsystem/aareg/form/utils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/utils.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/utils.tsx index 9ba92337264..5a66f96bf0e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/utils.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/utils.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import subYears from 'date-fns/subYears' export const hentAaregEksisterendeData = (personFoerLeggTil: any) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/validation.tsx index 75b3b34253a..9f6ad0779ff 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/form/validation.tsx @@ -1,5 +1,5 @@ import * as Yup from 'yup' -import _, { toNumber } from 'lodash' +import * as _ from 'lodash-es' import { getMonth, getYear, isWithinInterval } from 'date-fns' import { ifPresent, messages, requiredDate, requiredString } from '@/utils/YupValidations' import { testDatoFom, testDatoTom } from '@/components/fagsystem/utils' @@ -92,7 +92,7 @@ const arbeidsavtale = Yup.object({ '$avtaltArbeidstimerPerUke', Yup.string() .test('isBetween', 'Må være mellom 1 og 75', (val, context) => { - const value = toNumber(val) + const value = _.toNumber(val) return !val || isNaN(value) || (value >= 1 && value <= 75) }) .nullable(), diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/visning/partials/Arbeidsavtaler.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/visning/partials/Arbeidsavtaler.tsx index 56ece303673..4571b5c70bb 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/visning/partials/Arbeidsavtaler.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/aareg/visning/partials/Arbeidsavtaler.tsx @@ -2,7 +2,7 @@ import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatStringDates } from '@/utils/DataFormatter' import { ArbeidKodeverk } from '@/config/kodeverk' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' -import _ from 'lodash' +import * as _ from 'lodash-es' import React from 'react' import { Fartoy } from '@/components/fagsystem/aareg/visning/partials/Fartoy' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/alderspensjon/form/Form.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/alderspensjon/form/Form.tsx index 51dd5055471..87644aa6792 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/alderspensjon/form/Form.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/alderspensjon/form/Form.tsx @@ -6,8 +6,7 @@ import React, { useContext, useEffect, useState } from 'react' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { Alert, ToggleGroup } from '@navikt/ds-react' import styled from 'styled-components' -import _has from 'lodash/has' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { add, getYear, isAfter, isDate, parseISO } from 'date-fns' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' import { validation } from '@/components/fagsystem/alderspensjon/form/validation' @@ -55,8 +54,8 @@ export const AlderspensjonForm = () => { function sjekkAlderFelt() { const harAlder = - _has(formMethods.getValues(), 'pdldata.opprettNyPerson.alder') && - _has(formMethods.getValues(), 'pdldata.opprettNyPerson.foedtFoer') + _.has(formMethods.getValues(), 'pdldata.opprettNyPerson.alder') && + _.has(formMethods.getValues(), 'pdldata.opprettNyPerson.foedtFoer') const alderNyPerson = formMethods.watch('pdldata.opprettNyPerson.alder') const foedtFoer = formMethods.watch('pdldata.opprettNyPerson.foedtFoer') && @@ -74,14 +73,14 @@ export const AlderspensjonForm = () => { const { harAlder, alderNyPerson, foedtFoer, harGyldigAlder } = sjekkAlderFelt() const alderLeggTilPerson = getAlder( - _get(opts, 'personFoerLeggTil.pdl.hentPerson.foedselsdato[0].foedselsdato') || - _get(opts, 'personFoerLeggTil.pdl.hentPerson.foedsel[0].foedselsdato'), + _.get(opts, 'personFoerLeggTil.pdl.hentPerson.foedselsdato[0].foedselsdato') || + _.get(opts, 'personFoerLeggTil.pdl.hentPerson.foedsel[0].foedselsdato'), ) const alderImportertPerson = opts?.importPersoner?.map((person) => getAlder( - _get(person, 'data.hentPerson.foedselsdato[0].foedselsdato') || - _get(person, 'data.hentPerson.foedsel[0].foedselsdato'), + _.get(person, 'data.hentPerson.foedselsdato[0].foedselsdato') || + _.get(person, 'data.hentPerson.foedsel[0].foedselsdato'), ), ) @@ -107,7 +106,7 @@ export const AlderspensjonForm = () => { ugyldigFoedselsaar = true } } - const foedsel = _get(formMethods.getValues(), 'pdldata.person.foedsel') + const foedsel = _.get(formMethods.getValues(), 'pdldata.person.foedsel') if (foedsel) { const foedselsaar = foedsel[foedsel.length - 1]?.foedselsaar || @@ -122,20 +121,20 @@ export const AlderspensjonForm = () => { } const harNorskBankkonto = - _has(formMethods.getValues(), 'bankkonto.norskBankkonto') || - _has(opts, 'personFoerLeggTil.kontoregister.aktivKonto') + _.has(formMethods.getValues(), 'bankkonto.norskBankkonto') || + _.has(opts, 'personFoerLeggTil.kontoregister.aktivKonto') const harPopp = - _has(formMethods.getValues(), 'pensjonforvalter.inntekt') || + _.has(formMethods.getValues(), 'pensjonforvalter.inntekt') || opts?.tidligereBestillinger?.some((bestilling) => bestilling.data?.pensjonforvalter?.inntekt) const gyldigSivilstand = ['GIFT', 'SAMBOER', 'REGISTRERT_PARTNER'] const harPartner = - _get(formMethods.getValues(), 'pdldata.person.sivilstand')?.some((siv) => + _.get(formMethods.getValues(), 'pdldata.person.sivilstand')?.some((siv) => gyldigSivilstand.includes(siv?.type), ) || - _get(opts, 'personFoerLeggTil.pdl.hentPerson.sivilstand')?.some((siv) => + _.get(opts, 'personFoerLeggTil.pdl.hentPerson.sivilstand')?.some((siv) => gyldigSivilstand.includes(siv?.type), ) @@ -153,12 +152,13 @@ export const AlderspensjonForm = () => { utland: 'UTLAND', } const valgtAdresseType = () => { - const adresseUtenTilDato = _get(formMethods.getValues(), 'pdldata.person.bostedsadresse')?.find( - (adresse) => adresse.gyldigFraOgMed && !adresse.gyldigTilOgMed, - ) + const adresseUtenTilDato = _.get( + formMethods.getValues(), + 'pdldata.person.bostedsadresse', + )?.find((adresse) => adresse.gyldigFraOgMed && !adresse.gyldigTilOgMed) const gjeldendeAdresse = adresseUtenTilDato || - _get(formMethods.getValues(), 'pdldata.person.bostedsadresse')?.reduce((prev, curr) => { + _.get(formMethods.getValues(), 'pdldata.person.bostedsadresse')?.reduce((prev, curr) => { if ( !prev.gyldigTilOgMed || !curr.gyldigTilOgMed || @@ -178,7 +178,7 @@ export const AlderspensjonForm = () => { const harNorskAdresse = () => { if (opts?.personFoerLeggTil) { return ( - _get(opts?.personFoerLeggTil, 'pdl.hentGeografiskTilknytning.gtType') !== 'UTLAND' || + _.get(opts?.personFoerLeggTil, 'pdl.hentGeografiskTilknytning.gtType') !== 'UTLAND' || valgtAdresseType() === adressetyper.norge ) } diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AndreGodkjenningerForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AndreGodkjenningerForm.tsx index 53b1f244dd9..c15d18d7077 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AndreGodkjenningerForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AndreGodkjenningerForm.tsx @@ -10,7 +10,7 @@ import * as React from 'react' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { EraseFillButtons } from '@/components/fagsystem/arbeidsplassen/form/partials/EraseFillButtons' -import _get from 'lodash/get' +import * as _ from 'lodash-es' export const AndreGodkjenningerForm = ({ formMethods }) => { const andreGodkjenningerListePath = 'arbeidsplassenCV.andreGodkjenninger' @@ -38,7 +38,7 @@ export const AndreGodkjenningerForm = ({ formMethods }) => { name={`${annenGodkjenningPath}.issuer`} label="Utsteder" size="large" - key={`issuer_${_get(formMethods.getValues(), `${annenGodkjenningPath}.issuer`)}`} + key={`issuer_${_.get(formMethods.getValues(), `${annenGodkjenningPath}.issuer`)}`} /> diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AnnenErfaringForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AnnenErfaringForm.tsx index 0af1562372f..8d7216a4f1c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AnnenErfaringForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/AnnenErfaringForm.tsx @@ -5,7 +5,7 @@ import { } from '@/components/fagsystem/arbeidsplassen/form/initialValues' import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { Fritekstfelt } from '@/components/fagsystem/arbeidsplassen/form/styles' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import * as React from 'react' @@ -31,12 +31,12 @@ export const AnnenErfaringForm = ({ formMethods }) => { name={`${annenErfaringPath}.role`} label="Rolle" size="xlarge" - key={`role_${_get(formMethods.getValues(), `${annenErfaringPath}.role`)}`} + key={`role_${_.get(formMethods.getValues(), `${annenErfaringPath}.role`)}`} /> formMethods.setValue( `${annenErfaringPath}.description`, @@ -44,7 +44,7 @@ export const AnnenErfaringForm = ({ formMethods }) => { ) } size="small" - key={`description_${_get( + key={`description_${_.get( formMethods.getValues(), `${annenErfaringPath}.description`, )}`} @@ -54,14 +54,14 @@ export const AnnenErfaringForm = ({ formMethods }) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/ArbeidserfaringForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/ArbeidserfaringForm.tsx index f5d3271ee8f..853ed55ba84 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/ArbeidserfaringForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/ArbeidserfaringForm.tsx @@ -8,7 +8,7 @@ import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import * as React from 'react' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import { FormSelect } from '@/components/ui/form/inputs/select/Select' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { Fritekstfelt } from '@/components/fagsystem/arbeidsplassen/form/styles' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { Vis } from '@/components/bestillingsveileder/VisAttributt' @@ -46,7 +46,7 @@ export const ArbeidserfaringForm = ({ formMethods }) => { name={`${arbeidsforholdPath}.alternativeJobTitle`} label="Alternativ tittel" size="large" - key={`alternativeJobTitle_${_get( + key={`alternativeJobTitle_${_.get( formMethods.getValues(), `${arbeidsforholdPath}.alternativeJobTitle`, )}`} @@ -55,18 +55,18 @@ export const ArbeidserfaringForm = ({ formMethods }) => { name={`${arbeidsforholdPath}.employer`} label="Bedrift" size="large" - key={`employer_${_get(formMethods.getValues(), `${arbeidsforholdPath}.employer`)}`} + key={`employer_${_.get(formMethods.getValues(), `${arbeidsforholdPath}.employer`)}`} /> formMethods.setValue( `${arbeidsforholdPath}.description`, @@ -74,7 +74,7 @@ export const ArbeidserfaringForm = ({ formMethods }) => { ) } size="small" - key={`description_${_get( + key={`description_${_.get( formMethods.getValues(), `${arbeidsforholdPath}.description`, )}`} @@ -84,14 +84,14 @@ export const ArbeidserfaringForm = ({ formMethods }) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/KursForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/KursForm.tsx index 86915917f3a..eb975f0854c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/KursForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/KursForm.tsx @@ -8,7 +8,7 @@ import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import * as React from 'react' import { SelectOptionsManager as Options } from '@/service/SelectOptions' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { showLabel } from '@/utils/DataFormatter' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { EraseFillButtons } from '@/components/fagsystem/arbeidsplassen/form/partials/EraseFillButtons' @@ -20,7 +20,7 @@ export const KursForm = ({ formMethods }) => { {(kursPath, idx) => { - const durationUnit = _get(formMethods.getValues(), `${kursPath}.durationUnit`) + const durationUnit = _.get(formMethods.getValues(), `${kursPath}.durationUnit`) return ( <>
@@ -28,13 +28,13 @@ export const KursForm = ({ formMethods }) => { name={`${kursPath}.title`} label="Kursnavn" size="xlarge" - key={`title_${_get(formMethods.getValues(), `${kursPath}.title`)}`} + key={`title_${_.get(formMethods.getValues(), `${kursPath}.title`)}`} /> { }`} size="small" type="number" - key={`duration_${_get(formMethods.getValues(), `${kursPath}.duration`)}`} + key={`duration_${_.get(formMethods.getValues(), `${kursPath}.duration`)}`} />
{ const offentligeGodkjenningerListePath = 'arbeidsplassenCV.offentligeGodkjenninger' @@ -38,7 +38,7 @@ export const OffentligeGodkjenningerForm = ({ formMethods }) => { name={`${offentligGodkjenningPath}.issuer`} label="Utsteder" size="large" - key={`issuer_${_get( + key={`issuer_${_.get( formMethods.getValues(), `${offentligGodkjenningPath}.issuer`, )}`} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/SammendragForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/SammendragForm.tsx index f55a3a54fb8..c0990931861 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/SammendragForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arbeidsplassen/form/partials/SammendragForm.tsx @@ -1,4 +1,4 @@ -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { Fritekstfelt } from '@/components/fagsystem/arbeidsplassen/form/styles' import * as React from 'react' import { Vis } from '@/components/bestillingsveileder/VisAttributt' @@ -14,11 +14,11 @@ export const SammendragForm = ({ formMethods }) => { formMethods.setValue(sammendragPath, sammendrag?.target?.value)} size="small" - key={`sammendrag_${_get(formMethods.getValues(), sammendragPath)}`} - error={_get(formMethods.getValues(), sammendragPath) === '' ? 'Feltet er påkrevd' : null} + key={`sammendrag_${_.get(formMethods.getValues(), sammendragPath)}`} + error={_.get(formMethods.getValues(), sammendragPath) === '' ? 'Feltet er påkrevd' : null} resize /> { formMethods.setValue(`${utdanningPath}.description`, beskrivelse?.target?.value) } @@ -67,14 +67,14 @@ export const UtdanningForm = ({ formMethods }) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/Form.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/Form.tsx index 99ce1f66e91..047c883f662 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/Form.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/Form.tsx @@ -1,5 +1,5 @@ import React, { useContext } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { ifPresent } from '@/utils/YupValidations' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import Panel from '@/components/ui/panel/Panel' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/partials/MedServicebehov.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/partials/MedServicebehov.tsx index 9b8c8f2ab6a..5d793a7fc00 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/partials/MedServicebehov.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/partials/MedServicebehov.tsx @@ -3,7 +3,7 @@ import { Kategori } from '@/components/ui/form/kategori/Kategori' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' -import _ from 'lodash' +import * as _ from 'lodash-es' import { Alert } from '@navikt/ds-react' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/validation.tsx index 4167111820d..ccac6140484 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/arena/form/validation.tsx @@ -1,7 +1,7 @@ import * as Yup from 'yup' import { messages, requiredString } from '@/utils/YupValidations' import { isAfter, isBefore, isEqual } from 'date-fns' -import _ from 'lodash' +import * as _ from 'lodash-es' const ikkeOverlappendeVedtak = ['aap', 'dagpenger'] diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/UtenlandskBankkonto.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/UtenlandskBankkonto.tsx index d4b7c9fd2f3..391d7772725 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/UtenlandskBankkonto.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/UtenlandskBankkonto.tsx @@ -4,7 +4,7 @@ import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { ArbeidKodeverk, GtKodeverk } from '@/config/kodeverk' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' -import _ from 'lodash' +import * as _ from 'lodash-es' import { landkodeIsoMapping } from '@/service/services/kontoregister/landkoder' const path = 'bankkonto.utenlandskBankkonto' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/validation.tsx index d90e71ef488..8751a1f7ee1 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/bankkonto/form/validation.tsx @@ -1,6 +1,6 @@ import * as Yup from 'yup' import { ifPresent, messages, requiredString } from '@/utils/YupValidations' -import _ from 'lodash' +import * as _ from 'lodash-es' import { landkodeIsoMapping, landkoder } from '@/service/services/kontoregister/landkoder' const validInputOrCheckboxTest = (val, checkboxPath, feilmelding, inputValidation) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/brregstub/form/partials/organisasjonTextSelect.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/brregstub/form/partials/organisasjonTextSelect.tsx index 042e4421650..a4e0c29b981 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/brregstub/form/partials/organisasjonTextSelect.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/brregstub/form/partials/organisasjonTextSelect.tsx @@ -3,7 +3,7 @@ import { OrganisasjonMedMiljoeSelect } from '@/components/organisasjonSelect/Org import { useBoolean } from 'react-use' import { OrgserviceApi } from '@/service/Api' import { OrgInfoAdresse } from '@/service/services/organisasjonservice/types' -import _ from 'lodash' +import * as _ from 'lodash-es' import { useFormContext } from 'react-hook-form' interface OrgnanisasjonTextSelectProps { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivForm.tsx index 0baa4e4ce1a..4a8bedfdff5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivForm.tsx @@ -1,33 +1,19 @@ import React, { BaseSyntheticEvent, useEffect, useState } from 'react' -import * as Yup from 'yup' -import { ifPresent, requiredString } from '@/utils/YupValidations' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { Kategori } from '@/components/ui/form/kategori/Kategori' import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { DollyTextInput, FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import Panel from '@/components/ui/panel/Panel' import { erForsteEllerTest, panelError } from '@/components/ui/form/formUtils' -import _ from 'lodash' +import * as _ from 'lodash-es' import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import { SelectOptionsManager as Options } from '@/service/SelectOptions' -import { UseFormReturn } from 'react-hook-form/dist/types' import { useFormContext } from 'react-hook-form' import { Option } from '@/service/SelectOptionsOppslag' import { useKodeverk } from '@/utils/hooks/useKodeverk' - -const Digitalinnsending = React.lazy( - () => import('@/components/fagsystem/dokarkiv/form/partials/Digitalinnsending'), -) - -const FileUploader = React.lazy(() => import('@/utils/FileUploader/FileUploader')) - -const DokumentInfoListe = React.lazy( - () => import('@/components/fagsystem/dokarkiv/modal/DokumentInfoListe'), -) - -interface DokarkivFormProps { - formMethods: UseFormReturn -} +import Digitalinnsending from './partials/Digitalinnsending' +import FileUploader from '@/utils/FileUploader/FileUploader' +import DokumentInfoListe from '@/components/fagsystem/dokarkiv/modal/DokumentInfoListe' type Skjema = { data: string @@ -53,9 +39,9 @@ enum Kodeverk { BEHANDLINGSTEMA = 'Behandlingstema', } -export const dokarkivAttributt = 'dokarkiv' +const dokarkivAttributt = 'dokarkiv' -export const DokarkivForm = () => { +const DokarkivForm = () => { const formMethods = useFormContext() if (!formMethods.watch(dokarkivAttributt)) { return null @@ -195,7 +181,11 @@ export const DokarkivForm = () => { {files.length > 0 && ( - + )} @@ -204,76 +194,4 @@ export const DokarkivForm = () => { ) } -DokarkivForm.validation = { - dokarkiv: ifPresent( - '$dokarkiv', - Yup.object({ - tittel: requiredString, - tema: requiredString, - journalfoerendeEnhet: Yup.string() - .optional() - .nullable() - .matches(/^\d*$/, 'Journalfoerende enhet må enten være blank eller et tall med 4 sifre') - .test( - 'len', - 'Journalfoerende enhet må enten være blank eller et tall med 4 sifre', - (val) => !val || (val && val.length === 4), - ), - sak: Yup.object({ - sakstype: requiredString, - fagsaksystem: Yup.string().when('sakstype', { - is: 'FAGSAK', - then: () => requiredString, - otherwise: () => Yup.mixed().notRequired(), - }), - fagsakId: Yup.string().when('sakstype', { - is: 'FAGSAK', - then: () => requiredString, - otherwise: () => Yup.mixed().notRequired(), - }), - }), - avsenderMottaker: Yup.object({ - idType: Yup.string().optional().nullable(), - id: Yup.string() - .when('idType', { - is: 'ORGNR', - then: () => - Yup.string() - .matches(/^\d*$/, 'Orgnummer må være et tall med 9 sifre') - .test( - 'len', - 'Orgnummer må være et tall med 9 sifre', - (val) => val && val.length === 9, - ), - }) - .when('idType', { - is: 'FNR', - then: () => - Yup.string() - .matches(/^\d*$/, 'Ident må være et tall med 11 sifre') - .test( - 'len', - 'Ident må være et tall med 11 sifre', - (val) => val && val.length === 11, - ), - }), - navn: Yup.string().optional(), - }), - dokumenter: Yup.array().of( - Yup.object({ - tittel: requiredString, - brevkode: Yup.string().test( - 'is-valid-brevkode', - 'Feltet er påkrevd', - (_val, testContext) => { - const fullForm = - testContext.from && testContext.from[testContext.from.length - 1]?.value - const brevkode = _.get(fullForm, 'dokarkiv.dokumenter[0].brevkode') - return brevkode !== '' - }, - ), - }), - ), - }), - ), -} +export default DokarkivForm diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivValidation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivValidation.tsx new file mode 100644 index 00000000000..cdebc38e629 --- /dev/null +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/form/DokarkivValidation.tsx @@ -0,0 +1,77 @@ +import * as Yup from 'yup' +import { ifPresent, requiredString } from '@/utils/YupValidations' +import * as _ from 'lodash-es' + +export const dokarkivValidation = { + dokarkiv: ifPresent( + '$dokarkiv', + Yup.object({ + tittel: requiredString, + tema: requiredString, + journalfoerendeEnhet: Yup.string() + .optional() + .nullable() + .matches(/^\d*$/, 'Journalfoerende enhet må enten være blank eller et tall med 4 sifre') + .test( + 'len', + 'Journalfoerende enhet må enten være blank eller et tall med 4 sifre', + (val) => !val || (val && val.length === 4), + ), + sak: Yup.object({ + sakstype: requiredString, + fagsaksystem: Yup.string().when('sakstype', { + is: 'FAGSAK', + then: () => requiredString, + otherwise: () => Yup.mixed().notRequired(), + }), + fagsakId: Yup.string().when('sakstype', { + is: 'FAGSAK', + then: () => requiredString, + otherwise: () => Yup.mixed().notRequired(), + }), + }), + avsenderMottaker: Yup.object({ + idType: Yup.string().optional().nullable(), + id: Yup.string() + .when('idType', { + is: 'ORGNR', + then: () => + Yup.string() + .matches(/^\d*$/, 'Orgnummer må være et tall med 9 sifre') + .test( + 'len', + 'Orgnummer må være et tall med 9 sifre', + (val) => val && val.length === 9, + ), + }) + .when('idType', { + is: 'FNR', + then: () => + Yup.string() + .matches(/^\d*$/, 'Ident må være et tall med 11 sifre') + .test( + 'len', + 'Ident må være et tall med 11 sifre', + (val) => val && val.length === 11, + ), + }), + navn: Yup.string().optional(), + }), + dokumenter: Yup.array().of( + Yup.object({ + tittel: requiredString, + brevkode: Yup.string().test( + 'is-valid-brevkode', + 'Feltet er påkrevd', + (_val, testContext) => { + const fullForm = + testContext.from && testContext.from[testContext.from.length - 1]?.value + const brevkode = _.get(fullForm, 'dokarkiv.dokumenter[0].brevkode') + return brevkode !== '' + }, + ), + }), + ), + }), + ), +} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/modal/DokumentInfoListe.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/modal/DokumentInfoListe.tsx index f6964e482db..b272a78e48e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/modal/DokumentInfoListe.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/modal/DokumentInfoListe.tsx @@ -1,4 +1,4 @@ -import React from 'react' +import React, { useEffect } from 'react' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { Vedlegg } from '@/components/fagsystem/dokarkiv/form/DokarkivForm' @@ -8,12 +8,14 @@ import 'react-pdf/dist/esm/Page/AnnotationLayer.css' import 'react-pdf/dist/esm/Page/TextLayer.css' import styled from 'styled-components' import Button from '@/components/ui/button/Button' +import { useFormContext } from 'react-hook-form' pdfjs.GlobalWorkerOptions.workerSrc = `//unpkg.com/pdfjs-dist@${pdfjs.version}/build/pdf.worker.min.mjs` type Data = { filer: Vedlegg[] handleChange: Function + path: string isMultiple?: boolean } @@ -28,11 +30,20 @@ const PdfDocument = styled(Document)` max-height: 90px; margin-right: 10px; ` -export default ({ filer, handleChange, isMultiple = true }: Data) => { +export default ({ filer, handleChange, path, isMultiple = true }: Data) => { + const formMethods = useFormContext() if (!filer || filer.length < 1) { return null } + useEffect(() => { + filer.forEach((fil: Vedlegg, index: number) => { + if (formMethods.watch(`${path}.${index}.tittel`) === '') { + formMethods.setValue(`${path}.${index}.tittel`, fil.name) + } + }) + }, [filer]) + const handleDeleteByIndex = (deleteIndex: number) => handleChange(filer.filter((fil, index) => index !== deleteIndex)) @@ -44,14 +55,11 @@ export default ({ filer, handleChange, isMultiple = true }: Data) => { {(fil: Vedlegg, index: number) => (
- + handleDeleteByIndex(index)} /> @@ -60,15 +68,12 @@ export default ({ filer, handleChange, isMultiple = true }: Data) => { ) : (
- + handleDeleteByIndex(0)} /> diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/visning/DokarkivVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/visning/DokarkivVisning.tsx index abc681ce6b2..41d63a28216 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/visning/DokarkivVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/dokarkiv/visning/DokarkivVisning.tsx @@ -17,55 +17,60 @@ const H4 = styled.h4` width: 100%; ` -export default ({ journalpost, miljoe }: Props) => ( -
- - - - - - - - - +export default ({ journalpost, miljoe }: Props) => { + if (!journalpost) { + return null + } + return ( +
+ + + + + + + + + - {journalpost.avsenderMottaker ? ( - <> -

Avsender

- - - - - ) : null} + {journalpost.avsenderMottaker ? ( + <> +

Avsender

+ + + + + ) : null} - - {(dokument: Dokument, idx: number) => { - return ( -
- - - -
- ) - }} -
-
-) + + {(dokument: Dokument, idx: number) => { + return ( +
+ + + +
+ ) + }} +
+
+ ) +} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/FullmaktForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/FullmaktForm.tsx index 100181f7c56..2893a41eeb4 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/FullmaktForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/FullmaktForm.tsx @@ -16,13 +16,13 @@ import { useFullmaktOmraader } from '@/utils/hooks/useFullmakt' import { Omraade } from '@/components/fagsystem/fullmakt/FullmaktType' import { Option } from '@/service/SelectOptionsOppslag' import Loading from '@/components/ui/loading/Loading' -import { ErrorMessage } from '@hookform/error-message' import { validation } from '@/components/fagsystem/fullmakt/form/validation' import { isEmpty } from '@/components/fagsystem/pdlf/form/partials/utils' +import { DisplayFormError } from '@/components/ui/toast/DisplayFormError' interface FullmaktProps { formMethods: UseFormReturn - path?: string + path: string opts?: any eksisterendeNyPerson?: any } @@ -179,15 +179,7 @@ export const Fullmakt = ({ toggleExpansion={!isTestnorgeIdent} eksisterendeNyPerson={eksisterendeNyPerson} /> - {formMethods.formState.errors && ( - ( -

{message}

- )} - /> - )} +
) } diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/validation.tsx index 89e12a22faa..cc988c29e45 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/form/validation.tsx @@ -1,7 +1,7 @@ import * as Yup from 'yup' import { ifPresent, requiredDate, requiredString } from '@/utils/YupValidations' import { testDatoTom } from '@/components/fagsystem/utils' -import _ from 'lodash' +import * as _ from 'lodash-es' import { isBefore, subDays } from 'date-fns' export const validation = { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/visning/FullmaktVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/visning/FullmaktVisning.tsx index 176369c4c03..3ffdb339a92 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/visning/FullmaktVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/fullmakt/visning/FullmaktVisning.tsx @@ -42,3 +42,5 @@ export const FullmaktVisning = ({ ident }: FullmaktProps) => { ) } + +export default FullmaktVisning diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkForm.tsx index 494b0c8c891..663b85fe4e6 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkForm.tsx @@ -1,6 +1,4 @@ import React, { useEffect, useState } from 'react' -import * as Yup from 'yup' -import { ifPresent, messages, requiredDate, requiredString } from '@/utils/YupValidations' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { Kategori } from '@/components/ui/form/kategori/Kategori' import { FormSelect } from '@/components/ui/form/inputs/select/Select' @@ -9,28 +7,26 @@ import { erForsteEllerTest, panelError } from '@/components/ui/form/formUtils' import { Vedlegg } from '@/components/fagsystem/dokarkiv/form/DokarkivForm' import { FormDollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { useNavEnheter } from '@/utils/hooks/useNorg2' -import _ from 'lodash' +import * as _ from 'lodash-es' import { Option } from '@/service/SelectOptionsOppslag' import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { useFormContext } from 'react-hook-form' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import { getYearRangeOptions } from '@/utils/DataFormatter' import { initialHistark } from '@/components/fagsystem/histark/form/initialValues' - -const DokumentInfoListe = React.lazy( - () => import('@/components/fagsystem/dokarkiv/modal/DokumentInfoListe'), -) -const FileUploader = React.lazy(() => import('@/utils/FileUploader/FileUploader')) +import { DisplayFormError } from '@/components/ui/toast/DisplayFormError' +import FileUploader from '@/utils/FileUploader/FileUploader' +import DokumentInfoListe from '@/components/fagsystem/dokarkiv/modal/DokumentInfoListe' enum Kodeverk { TEMA = 'Tema', } -export const histarkAttributt = 'histark' +const histarkAttributt = 'histark' -export const HistarkForm = () => { +const HistarkForm = () => { const formMethods = useFormContext() - if (!_.has(formMethods.getValues(), histarkAttributt)) { + if (!formMethods.getValues(histarkAttributt)) { return null } @@ -55,7 +51,7 @@ export const HistarkForm = () => { filer.forEach((fil: Vedlegg, index: number) => { formMethods.setValue(`histark.dokumenter.${index}.tittel`, fil.dokNavn || fil.name) formMethods.setValue(`histark.dokumenter.${index}.antallSider`, 1) - formMethods.setValue(`histark.dokumenter.${index}.fysiskDokument`, fil.content.base64) + formMethods.setValue(`histark.dokumenter.${index}.fysiskDokument`, fil.content?.base64) }) formMethods.trigger('histark.dokumenter') formMethods.trigger('histark.vedlegg') @@ -141,12 +137,14 @@ export const HistarkForm = () => { {files.length > 0 && ( )} +
)} @@ -157,33 +155,4 @@ export const HistarkForm = () => { ) } -HistarkForm.validation = { - histark: ifPresent( - '$histark', - Yup.object({ - dokumenter: Yup.array().of( - Yup.object({ - tittel: requiredString, - temakoder: Yup.array().required().min(1, 'Velg minst en temakode'), - enhetsnavn: Yup.string().required('Velg en NAV-enhet'), - enhetsnummer: requiredString, - skanner: requiredString, - skannested: requiredString, - skanningsTidspunkt: requiredDate.nullable(), - startYear: Yup.number() - .required(messages.required) - .test('start-before-slutt', 'Startår må være før sluttår', (value, context) => { - const sluttAar = context.parent.endYear - return value && sluttAar && value < sluttAar - }), - endYear: Yup.number() - .required(messages.required) - .test('slutt-after-start', 'Sluttår må være etter startår', (value, context) => { - const startAar = context.parent.startYear - return value && startAar && value > startAar - }), - }), - ), - }), - ), -} +export default HistarkForm diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkValidation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkValidation.tsx new file mode 100644 index 00000000000..eec85885c01 --- /dev/null +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/HistarkValidation.tsx @@ -0,0 +1,33 @@ +import * as Yup from 'yup' +import { ifPresent, messages, requiredDate, requiredString } from '@/utils/YupValidations' + +export const histarkValidation = { + histark: ifPresent( + '$histark', + Yup.object({ + dokumenter: Yup.array().of( + Yup.object({ + tittel: requiredString, + temakoder: Yup.array().required().min(1, 'Velg minst en temakode'), + enhetsnavn: Yup.string().required('Velg en NAV-enhet'), + enhetsnummer: requiredString, + skanner: requiredString, + skannested: requiredString, + skanningsTidspunkt: requiredDate.nullable(), + startYear: Yup.number() + .required(messages.required) + .test('start-before-slutt', 'Startår må være før sluttår', (value, context) => { + const sluttAar = context.parent.endYear + return value && sluttAar && value < sluttAar + }), + endYear: Yup.number() + .required(messages.required) + .test('slutt-after-start', 'Sluttår må være etter startår', (value, context) => { + const startAar = context.parent.startYear + return value && startAar && value > startAar + }), + }), + ), + }), + ), +} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/initialValues.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/initialValues.tsx index c13ffa8795c..cd05bf106d1 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/initialValues.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/form/initialValues.tsx @@ -4,13 +4,13 @@ export const initialHistark = { tittel: '', antallSider: -1, skanner: '', - skannested: '', + skannested: 'FREDRIKSTAD', skanningsTidspunkt: new Date(), temakoder: [], enhetsnavn: '', enhetsnummer: '', - startYear: 2000, - endYear: 2010, + startAar: new Date(), + sluttAar: new Date(), fysiskDokument: '', }, ], diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/HistarkVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/HistarkVisning.tsx index afb87bb71d8..aee2496ca3f 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/HistarkVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/HistarkVisning.tsx @@ -19,22 +19,27 @@ type HistarkDokument = { } } -export default ({ dokument }: HistarkDokument) => ( -
- - - - - - - - - -
-) +export default ({ dokument }: HistarkDokument) => { + if (!dokument) { + return null + } + return ( +
+ + + + + + + + + +
+ ) +} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/index.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/index.tsx deleted file mode 100644 index 015480e3e6a..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/histark/visning/index.tsx +++ /dev/null @@ -1 +0,0 @@ -export { default as HistarkVisning } from './Visning' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/index.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/index.tsx deleted file mode 100644 index 6d88115b7bb..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/index.tsx +++ /dev/null @@ -1,37 +0,0 @@ -import { KrrVisning } from '@/components/fagsystem/krrstub/visning/KrrVisning' -import { PdlfVisning } from '@/components/fagsystem/pdlf/visning/PdlfVisning' -import { ArenaVisning } from '@/components/fagsystem/arena/visning/ArenaVisning' -import { AaregVisning } from '@/components/fagsystem/aareg/visning/Visning' -import { UdiVisning } from '@/components/fagsystem/udistub/visning/UdiVisning' -import { SigrunstubVisning } from '@/components/fagsystem/sigrunstub/visning/Visning' -import { InntektstubVisning } from '@/components/fagsystem/inntektstub/visning/Visning' -import { InntektsmeldingVisning } from '@/components/fagsystem/inntektsmelding/visning/Visning' -import { InstVisning } from '@/components/fagsystem/inst/visning/InstVisning' -import { PensjonVisning } from '@/components/fagsystem/pensjon/visning/PensjonVisning' -import { TpVisning } from '@/components/fagsystem/tjenestepensjon/visning/TpVisning' -import { BrregVisning } from '@/components/fagsystem/brregstub/visning/BrregVisning' -import { TpsfVisning } from '@/components/fagsystem/tpsf/visning/Visning' -import { DokarkivVisning } from '@/components/fagsystem/dokarkiv/visning' -import { HistarkVisning } from '@/components/fagsystem/histark/visning' -import { SykemeldingVisning } from '@/components/fagsystem/sykdom/visning/Visning' -import { FullmaktVisning } from './fullmakt/visning/FullmaktVisning' - -export { - TpsfVisning, - KrrVisning, - PdlfVisning, - FullmaktVisning, - ArenaVisning, - AaregVisning, - UdiVisning, - SigrunstubVisning, - InntektsmeldingVisning, - InntektstubVisning, - InstVisning, - BrregVisning, - PensjonVisning, - TpVisning, - DokarkivVisning, - HistarkVisning, - SykemeldingVisning, -} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/form/Form.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/form/Form.tsx index 06730fdfd6c..327e4f17936 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/form/Form.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/form/Form.tsx @@ -1,6 +1,6 @@ import React, { useContext, useState } from 'react' import * as Yup from 'yup' -import _ from 'lodash' +import * as _ from 'lodash-es' import Panel from '@/components/ui/panel/Panel' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { erForsteEllerTest, panelError } from '@/components/ui/form/formUtils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/Visning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/Visning.tsx index 48a48a48889..4f09ea68bcf 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/Visning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/Visning.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { Bestilling, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/personVisningContent.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/personVisningContent.tsx index 51e8551eef4..07ad6bc83d1 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/personVisningContent.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/personVisningContent.tsx @@ -1,11 +1,12 @@ import { TitleValue } from '@/components/ui/titleValue/TitleValue' import Button from '@/components/ui/button/Button' -import { CodeView } from '@/components/codeView' import useBoolean from '@/utils/hooks/useBoolean' import { Journalpost } from '@/components/fagsystem/inntektsmelding/InntektsmeldingTypes' import styled from 'styled-components' import { useDokument } from '@/utils/hooks/useJoarkDokument' import { Alert } from '@navikt/ds-react' +import { lazy, Suspense } from 'react' +import Loading from '@/components/ui/loading/Loading' interface PersonVisningContentProps { id: Journalpost @@ -33,6 +34,7 @@ const StyledJournalpost = styled.div` } } ` +const PrettyCode = lazy(() => import('@/components/codeView/PrettyCode')) export const PersonVisningContent = ({ miljoe, dokumentInfo }: PersonVisningContentProps) => { const [viserSkjemainnhold, vis, skjul] = useBoolean(false) @@ -59,7 +61,9 @@ export const PersonVisningContent = ({ miljoe, dokumentInfo }: PersonVisningCont {viserSkjemainnhold && (dokument ? ( - + }> + + ) : ( Kunne ikke hente skjemainnhold diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/refusjonVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/refusjonVisning.tsx index 18f104b6f9d..694d54e6375 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/refusjonVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/refusjonVisning.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatDate } from '@/utils/DataFormatter' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/sykepengerVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/sykepengerVisning.tsx index 0c8cf4c49ef..593c8cc0cb3 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/sykepengerVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektsmelding/visning/partials/sykepengerVisning.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { codeToNorskLabel, formatDate } from '@/utils/DataFormatter' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektstub/form/partials/versjon.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektstub/form/partials/versjon.tsx index ca11ee6eee9..53259914d5e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektstub/form/partials/versjon.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inntektstub/form/partials/versjon.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' // @ts-ignore import { Inntektsinformasjon } from './inntektinformasjonTypes' import { UseFormReturn } from 'react-hook-form/dist/types' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/Form.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/Form.tsx index f5c031ba7a7..14f890c9eb0 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/Form.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/Form.tsx @@ -15,6 +15,7 @@ import { useFormContext } from 'react-hook-form' export const initialValues = { institusjonstype: '', startdato: '', + forventetSluttdato: '', sluttdato: '', } export const instAttributt = 'instdata' @@ -56,6 +57,12 @@ export const InstForm = () => { excludeDates={excludeDates} maxDate={maxDate} /> + { const startDate = new Date(startdato) diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/validation.tsx index d30c7d07210..1327f253670 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/form/validation.tsx @@ -54,6 +54,7 @@ export const validation = { Yup.object({ institusjonstype: requiredString, startdato: datoOverlapperIkkeAndreOppholdTest(requiredDate, true), + forventetSluttdato: Yup.string().nullable(), sluttdato: datoOverlapperIkkeAndreOppholdTest(Yup.string().nullable(), false), }), ), diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/visning/InstVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/visning/InstVisning.tsx index 9942e9eb22f..bf3c71e3fde 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/visning/InstVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/inst/visning/InstVisning.tsx @@ -75,6 +75,10 @@ export const InstVisning = ({ data, loading, bestillingIdListe, tilgjengeligMilj value={showLabel('institusjonstype', opphold.institusjonstype)} /> + )} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/krrstub/form/KrrValidation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/krrstub/form/KrrValidation.tsx index 914f00229da..f9aa3b0fab5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/krrstub/form/KrrValidation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/krrstub/form/KrrValidation.tsx @@ -1,6 +1,6 @@ import * as Yup from 'yup' import { ifPresent, requiredBoolean, requiredString } from '@/utils/YupValidations' -import _ from 'lodash' +import * as _ from 'lodash-es' const testMobil = (val) => { return val.test('gyldig-mobil', 'Ugyldig telefonnummer', (mobil, testContext) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/medl/visning/Visning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/medl/visning/Visning.tsx index 69fff695f7b..0861fb76e64 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/medl/visning/Visning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/medl/visning/Visning.tsx @@ -1,7 +1,7 @@ import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import MedlVisning from './MedlVisning' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' -import _ from 'lodash' +import * as _ from 'lodash-es' import { Medlemskapsperiode } from '@/components/fagsystem/medl/MedlTypes' import styled from 'styled-components' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/organisasjoner/form/partials/Detaljer.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/organisasjoner/form/partials/Detaljer.tsx index 0a33077a88c..1ce4f853b34 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/organisasjoner/form/partials/Detaljer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/organisasjoner/form/partials/Detaljer.tsx @@ -1,5 +1,5 @@ import React, { useEffect, useState } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { organisasjonPaths } from '../paths' import { Kategori } from '@/components/ui/form/kategori/Kategori' import { FormSelect } from '@/components/ui/form/inputs/select/Select' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/PdlVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/PdlVisning.tsx index 57e446e4ade..7948cbdc1fb 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/PdlVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/PdlVisning.tsx @@ -23,8 +23,8 @@ import { PdlDeltBosted } from '@/components/fagsystem/pdl/visning/partials/adres import { Doedsfall } from '@/components/fagsystem/pdlf/visning/partials/Doedsfall' import { PdlVergemaal } from '@/components/fagsystem/pdl/visning/partials/vergemaal/PdlVergemaal' import { getBankkontoData } from '@/components/fagsystem/pdlf/visning/PdlfVisning' -import { FullmaktVisning } from '@/components/fagsystem' import React from 'react' +import FullmaktVisning from '@/components/fagsystem/fullmakt/visning/FullmaktVisning' type PdlVisningProps = { pdlData: PdlData diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlKontaktadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlKontaktadresse.tsx index e39d9dbff90..fe46edc4e9e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlKontaktadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlKontaktadresse.tsx @@ -5,7 +5,7 @@ import { } from '@/components/fagsystem/pdlf/visning/partials/Kontaktadresse' import { KontaktadresseData } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' import { ArrayHistorikk } from '@/components/ui/historikk/ArrayHistorikk' -import _ from 'lodash' +import * as _ from 'lodash-es' type PdlKontaktadresseProps = { data: Array diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlOppholdsadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlOppholdsadresse.tsx index 0b31e4335e4..8946cecbc63 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlOppholdsadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/adresser/PdlOppholdsadresse.tsx @@ -5,7 +5,7 @@ import { } from '@/components/fagsystem/pdlf/visning/partials/Oppholdsadresse' import { OppholdsadresseData } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' import { ArrayHistorikk } from '@/components/ui/historikk/ArrayHistorikk' -import _ from 'lodash' +import * as _ from 'lodash-es' type PdlOppholdsadresseProps = { data: Array diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/relasjoner/PdlForeldreansvar.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/relasjoner/PdlForeldreansvar.tsx index 8ebf394a467..4b6fc3d4836 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/relasjoner/PdlForeldreansvar.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdl/visning/partials/relasjoner/PdlForeldreansvar.tsx @@ -1,6 +1,6 @@ import { TitleValue } from '@/components/ui/titleValue/TitleValue' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' -import _ from 'lodash' +import * as _ from 'lodash-es' import { formatDate } from '@/utils/DataFormatter' import { AdresseKodeverk } from '@/config/kodeverk' import { Foreldreansvar } from '@/components/fagsystem/pdlf/PdlTypes' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressebeskyttelse/Adressebeskyttelse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressebeskyttelse/Adressebeskyttelse.tsx index b7f122bf844..03070ba8e98 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressebeskyttelse/Adressebeskyttelse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressebeskyttelse/Adressebeskyttelse.tsx @@ -6,7 +6,7 @@ import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { AvansertForm } from '@/components/fagsystem/pdlf/form/partials/avansert/AvansertForm' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' -import _ from 'lodash' +import * as _ from 'lodash-es' import { UseFormReturn } from 'react-hook-form/dist/types' interface AdressebeskyttelseValues { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressetyper/MatrikkeladresseTilfeldig.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressetyper/MatrikkeladresseTilfeldig.tsx index ba429f3221e..7534b11099c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressetyper/MatrikkeladresseTilfeldig.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/adressetyper/MatrikkeladresseTilfeldig.tsx @@ -1,6 +1,6 @@ import { MatrikkelAdresseVelger } from '@/components/adresseVelger' import { DollyTextInput } from '@/components/ui/form/inputs/textInput/TextInput' -import _ from 'lodash' +import * as _ from 'lodash-es' import styled from 'styled-components' import { MatrikkelAdresse } from '@/components/adresseVelger/MatrikkelAdresseVelger' import { UseFormReturn } from 'react-hook-form/dist/types' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/bostedsadresse/Bostedsadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/bostedsadresse/Bostedsadresse.tsx index a2d2e1c0f6c..d6b0967dca7 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/bostedsadresse/Bostedsadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/bostedsadresse/Bostedsadresse.tsx @@ -12,7 +12,7 @@ import { import { FormDollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' -import _ from 'lodash' +import * as _ from 'lodash-es' import { MatrikkeladresseVelger, UkjentBosted, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/kontaktadresse/Kontaktadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/kontaktadresse/Kontaktadresse.tsx index 2ebcf9a29f4..0f8a97acb29 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/kontaktadresse/Kontaktadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/kontaktadresse/Kontaktadresse.tsx @@ -1,5 +1,5 @@ import React, { useContext, useEffect } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialKontaktadresse, initialPostboksadresse, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/oppholdsadresse/Oppholdsadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/oppholdsadresse/Oppholdsadresse.tsx index 4f9c57de406..95e658eff45 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/oppholdsadresse/Oppholdsadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/adresser/oppholdsadresse/Oppholdsadresse.tsx @@ -1,5 +1,5 @@ import React, { useContext, useEffect } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialOppholdsadresse, initialMatrikkeladresse, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/alder/Alder.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/alder/Alder.tsx index 9ef01975d7d..b887a007442 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/alder/Alder.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/alder/Alder.tsx @@ -1,8 +1,7 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import React, { useContext } from 'react' -import _get from 'lodash/get' import { BestillingsveilederContext } from '@/components/bestillingsveileder/BestillingsveilederContext' export const Alder = ({ formMethods }) => { @@ -16,7 +15,7 @@ export const Alder = ({ formMethods }) => { } const harFoedsel = () => { - const foedselListe = _get(formValues, 'pdldata.person.foedsel') + const foedselListe = _.get(formValues, 'pdldata.person.foedsel') return foedselListe?.some((foedsel) => foedsel?.foedselsaar || foedsel?.foedselsdato) } diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/DeltBosted.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/DeltBosted.tsx index ca9750a6220..f59cd4bb6ac 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/DeltBosted.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/DeltBosted.tsx @@ -1,5 +1,5 @@ import React, { useEffect, useState } from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/ForelderBarnRelasjon.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/ForelderBarnRelasjon.tsx index 65f9589deef..9c9829d1d28 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/ForelderBarnRelasjon.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/forelderBarnRelasjon/ForelderBarnRelasjon.tsx @@ -8,7 +8,7 @@ import { initialPdlBiPerson, initialPdlPerson, } from '@/components/fagsystem/pdlf/form/initialValues' -import _ from 'lodash' +import * as _ from 'lodash-es' import { AvansertForm } from '@/components/fagsystem/pdlf/form/partials/avansert/AvansertForm' import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import { FormSelect } from '@/components/ui/form/inputs/select/Select' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/foreldreansvar/Foreldreansvar.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/foreldreansvar/Foreldreansvar.tsx index 0040bdc942c..08b9aab2699 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/foreldreansvar/Foreldreansvar.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/familierelasjoner/foreldreansvar/Foreldreansvar.tsx @@ -10,7 +10,7 @@ import { FormDollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldA import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' -import _ from 'lodash' +import * as _ from 'lodash-es' import { ForeldreBarnRelasjon, TypeAnsvarlig } from '@/components/fagsystem/pdlf/PdlTypes' import { PdlEksisterendePerson } from '@/components/fagsystem/pdlf/form/partials/pdlPerson/PdlEksisterendePerson' import { PdlNyPerson } from '@/components/fagsystem/pdlf/form/partials/pdlPerson/PdlNyPerson' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/identifikasjon/falskIdentitet/FalskIdentitet.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/identifikasjon/falskIdentitet/FalskIdentitet.tsx index bd4595bbf2e..0b2d4da7022 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/identifikasjon/falskIdentitet/FalskIdentitet.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/identifikasjon/falskIdentitet/FalskIdentitet.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { AdresseKodeverk } from '@/config/kodeverk' import { SelectOptionsManager as Options } from '@/service/SelectOptions' import { DollySelect, FormSelect } from '@/components/ui/form/inputs/select/Select' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/kontaktinformasjonForDoedsbo/Kontakt.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/kontaktinformasjonForDoedsbo/Kontakt.tsx index 650fc41de6a..bddbfa4097d 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/kontaktinformasjonForDoedsbo/Kontakt.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/kontaktinformasjonForDoedsbo/Kontakt.tsx @@ -3,7 +3,7 @@ import { Kategori } from '@/components/ui/form/kategori/Kategori' import { DollySelect, FormSelect } from '@/components/ui/form/inputs/select/Select' import { FormDatepicker } from '@/components/ui/form/inputs/datepicker/Datepicker' import { getPlaceholder, setNavn } from '../utils' -import _ from 'lodash' +import * as _ from 'lodash-es' import { initialNyPerson, initialOrganisasjon, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/navn/Navn.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/navn/Navn.tsx index 432a29d8b88..0ab84d08b5e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/navn/Navn.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/partials/navn/Navn.tsx @@ -4,7 +4,7 @@ import { AvansertForm } from '@/components/fagsystem/pdlf/form/partials/avansert import { FormCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import { Option } from '@/service/SelectOptionsOppslag' import { FormSelect } from '@/components/ui/form/inputs/select/Select' -import _, { isEmpty } from 'lodash' +import * as _ from 'lodash-es' import { useContext, useEffect, useState } from 'react' import { ArrowCirclepathIcon } from '@navikt/aksel-icons' import { Button } from '@navikt/ds-react' @@ -152,7 +152,7 @@ export const NavnForm = ({ formMethods, path, identtype, identMaster }: NavnType name={`${path}.hasMellomnavn`} id={`${path}.hasMellomnavn`} label="Har tilfeldig mellomnavn" - isDisabled={!isEmpty(selectedMellomnavn)} + isDisabled={!_.isEmpty(selectedMellomnavn)} checkboxMargin /> @@ -163,7 +163,7 @@ export const NavnForm = ({ formMethods, path, identtype, identMaster }: NavnType } export const Navn = ({ formMethods }: NavnTypes) => { - const opts = useContext(BestillingsveilederContext) + const opts: any = useContext(BestillingsveilederContext) return (
{ const fornavn = _.get(values, `${selectedValuePath}.fornavn`) diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/familierelasjoner.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/familierelasjoner.tsx index 77cf677ab5c..d16866e09e1 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/familierelasjoner.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/familierelasjoner.tsx @@ -1,8 +1,11 @@ import * as Yup from 'yup' import { ifPresent, requiredDate, requiredString } from '@/utils/YupValidations' -import { matrikkeladresse, vegadresse } from '@/components/fagsystem/pdlf/form/validation/partials' import { testDatoFom, testDatoTom } from '@/components/fagsystem/utils' -import _ from 'lodash' +import * as _ from 'lodash-es' +import { + matrikkeladresse, + vegadresse, +} from '@/components/fagsystem/pdlf/form/validation/partials/adresser' const testForeldreansvar = (val: Yup.StringSchema) => { return val.test('er-gyldig-foreldreansvar', (selected, testContext) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/index.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/index.tsx deleted file mode 100644 index 4ae6a1ec78f..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/index.tsx +++ /dev/null @@ -1,48 +0,0 @@ -import { - bostedsadresse, - matrikkeladresse, - vegadresse, - oppholdsadresse, - kontaktadresse, - adressebeskyttelse, -} from './adresser' -import { - doedfoedtBarn, - forelderBarnRelasjon, - foreldreansvar, - sivilstand, - nyPerson, -} from './familierelasjoner' -import { innflytting } from './innvandring' -import { kontaktDoedsbo } from './kontaktinformasjonForDoedsbo' -import { sikkerhetstiltak } from './sikkerhetstiltak' -import { telefonnummer } from './telefonnummer' -import { utenlandskId, falskIdentitet } from './identifikasjon' -import { utflytting } from './utflytting' -import { statsborgerskap } from './statborgerskap' -import { vergemaal } from './vergemaal' -import { tilrettelagtKommunikasjon } from './tilrettelagtKommunikasjon' - -export { - bostedsadresse, - matrikkeladresse, - vegadresse, - oppholdsadresse, - kontaktadresse, - adressebeskyttelse, - doedfoedtBarn, - forelderBarnRelasjon, - foreldreansvar, - sivilstand, - nyPerson, - innflytting, - kontaktDoedsbo, - sikkerhetstiltak, - telefonnummer, - utenlandskId, - falskIdentitet, - utflytting, - statsborgerskap, - vergemaal, - tilrettelagtKommunikasjon, -} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/innvandring.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/innvandring.tsx index 43fdefd9921..1f1082cb6f8 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/innvandring.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/innvandring.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import * as Yup from 'yup' import { requiredDate, requiredString } from '@/utils/YupValidations' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo.tsx index 1a7dedc523f..eee610339ff 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo.tsx @@ -1,7 +1,7 @@ import * as Yup from 'yup' import { requiredDate, requiredString } from '@/utils/YupValidations' -import { nyPerson } from '@/components/fagsystem/pdlf/form/validation/partials' -import _ from 'lodash' +import * as _ from 'lodash-es' +import { nyPerson } from './familierelasjoner' export const kontaktDoedsbo = Yup.object().shape({ skifteform: requiredString, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/sikkerhetstiltak.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/sikkerhetstiltak.tsx index abe9fff54b4..aadd695399f 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/sikkerhetstiltak.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/sikkerhetstiltak.tsx @@ -1,7 +1,7 @@ import * as Yup from 'yup' import { requiredDate, requiredString } from '@/utils/YupValidations' import { differenceInWeeks, isAfter } from 'date-fns' -import _ from 'lodash' +import * as _ from 'lodash-es' export const sikkerhetstiltak = Yup.array().of( Yup.object({ diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/telefonnummer.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/telefonnummer.tsx index a6036a4c8ed..ac4ccf7b295 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/telefonnummer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/partials/telefonnummer.tsx @@ -1,6 +1,6 @@ import * as Yup from 'yup' import { requiredString } from '@/utils/YupValidations' -import _ from 'lodash' +import * as _ from 'lodash-es' const testTelefonnummer = () => Yup.string() diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/validation.tsx index ad5627d5085..8aba76b166d 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/form/validation/validation.tsx @@ -1,29 +1,33 @@ import * as Yup from 'yup' import { ifPresent, requiredDate, requiredString } from '@/utils/YupValidations' +import { bankkontoValidation } from '@/components/fagsystem/bankkonto/form' +import { tpsMessagingValidation } from '@/components/fagsystem/tpsmessaging/form/validation' +import { testDatoFom, testDatoTom } from '@/components/fagsystem/utils' +import { isSameDay } from 'date-fns' import { adressebeskyttelse, bostedsadresse, - doedfoedtBarn, + kontaktadresse, + oppholdsadresse, +} from '@/components/fagsystem/pdlf/form/validation/partials/adresser' +import { sikkerhetstiltak } from '@/components/fagsystem/pdlf/form/validation/partials/sikkerhetstiltak' +import { tilrettelagtKommunikasjon } from '@/components/fagsystem/pdlf/form/validation/partials/tilrettelagtKommunikasjon' +import { falskIdentitet, + utenlandskId, +} from '@/components/fagsystem/pdlf/form/validation/partials/identifikasjon' +import { telefonnummer } from '@/components/fagsystem/pdlf/form/validation/partials/telefonnummer' +import { + doedfoedtBarn, forelderBarnRelasjon, foreldreansvar, - innflytting, - kontaktadresse, - kontaktDoedsbo, - oppholdsadresse, - sikkerhetstiltak, sivilstand, - statsborgerskap, - telefonnummer, - tilrettelagtKommunikasjon, - utenlandskId, - utflytting, - vergemaal, -} from '@/components/fagsystem/pdlf/form/validation/partials' -import { bankkontoValidation } from '@/components/fagsystem/bankkonto/form' -import { tpsMessagingValidation } from '@/components/fagsystem/tpsmessaging/form/validation' -import { testDatoFom, testDatoTom } from '@/components/fagsystem/utils' -import { isSameDay } from 'date-fns' +} from '@/components/fagsystem/pdlf/form/validation/partials/familierelasjoner' +import { utflytting } from '@/components/fagsystem/pdlf/form/validation/partials/utflytting' +import { kontaktDoedsbo } from '@/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo' +import { vergemaal } from '@/components/fagsystem/pdlf/form/validation/partials/vergemaal' +import { statsborgerskap } from '@/components/fagsystem/pdlf/form/validation/partials/statborgerskap' +import { innflytting } from '@/components/fagsystem/pdlf/form/validation/partials/innvandring' const testGyldigFom = (val) => { return val.test('is-unique', (selected: string, testContext: any) => { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisning.tsx index 71d21367c8f..f76d59a8980 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisning.tsx @@ -22,7 +22,7 @@ import { Persondetaljer } from '@/components/fagsystem/pdlf/visning/partials/Per import { PdlSikkerhetstiltak } from '@/components/fagsystem/pdl/visning/partials/PdlSikkerhetstiltak' import { TpsMBankkonto } from '@/components/fagsystem/pdl/visning/partials/tpsMessaging/TpsMBankkonto' import { ForeldreansvarVisning } from '@/components/fagsystem/pdlf/visning/partials/Foreldreansvar' -import { FullmaktVisning } from '@/components/fagsystem' +import FullmaktVisning from '@/components/fagsystem/fullmakt/visning/FullmaktVisning' export const getBankkontoData = (data) => { if (data?.kontoregister) { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisningConnector.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisningConnector.tsx index 3f8a86e55d6..f30eef9d62e 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisningConnector.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/PdlfVisningConnector.tsx @@ -1,5 +1,5 @@ import { connect, RootStateOrAny } from 'react-redux' -import { PdlfVisning } from '@/components/fagsystem' +import { PdlfVisning } from './PdlfVisning' const mapStateToProps = (state: RootStateOrAny) => { return { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Adressebeskyttelse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Adressebeskyttelse.tsx index 52334a97f29..d24225fa3ee 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Adressebeskyttelse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Adressebeskyttelse.tsx @@ -1,5 +1,5 @@ import React from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Boadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Boadresse.tsx index dd5ef205155..0d73f67d2ac 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Boadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Boadresse.tsx @@ -1,5 +1,5 @@ import React from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DeltBosted.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DeltBosted.tsx index 68c51dea480..17e35ccb798 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DeltBosted.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DeltBosted.tsx @@ -6,7 +6,7 @@ import { Matrikkeladresse } from '@/components/fagsystem/pdlf/visning/partials/M import { UkjentBosted } from '@/components/fagsystem/pdlf/visning/partials/UkjentBosted' import { DeltBostedValues, PersonData } from '@/components/fagsystem/pdlf/PdlTypes' import { initialDeltBosted } from '@/components/fagsystem/pdlf/form/initialValues' -import _ from 'lodash' +import * as _ from 'lodash-es' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DoedfoedtBarn.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DoedfoedtBarn.tsx index 407a76dcac4..078628fd3cc 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DoedfoedtBarn.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/DoedfoedtBarn.tsx @@ -4,7 +4,7 @@ import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatDate } from '@/utils/DataFormatter' import { DoedfoedtBarnData, PersonData } from '@/components/fagsystem/pdlf/PdlTypes' -import _ from 'lodash' +import * as _ from 'lodash-es' import { initialDoedfoedtBarn } from '@/components/fagsystem/pdlf/form/initialValues' import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Doedsfall.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Doedsfall.tsx index 2afdde4d903..337e9f7ae13 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Doedsfall.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Doedsfall.tsx @@ -4,7 +4,7 @@ import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { formatDate } from '@/utils/DataFormatter' -import _ from 'lodash' +import * as _ from 'lodash-es' import { DoedsfallData, Person } from '@/components/fagsystem/pdlf/PdlTypes' import { getInitialDoedsfall } from '@/components/fagsystem/pdlf/form/initialValues' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foedsel.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foedsel.tsx index 23010408dd6..135fb55cee6 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foedsel.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foedsel.tsx @@ -5,7 +5,7 @@ import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { formatDate } from '@/utils/DataFormatter' import KodeverkConnector from '@/components/kodeverk/KodeverkConnector' -import _ from 'lodash' +import * as _ from 'lodash-es' import { Kodeverk, KodeverkValues, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/ForelderBarnRelasjon.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/ForelderBarnRelasjon.tsx index 171d5dc0f33..9907d68e291 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/ForelderBarnRelasjon.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/ForelderBarnRelasjon.tsx @@ -6,7 +6,7 @@ import { showLabel } from '@/utils/DataFormatter' import { RelatertPerson } from '@/components/fagsystem/pdlf/visning/partials/RelatertPerson' import { ForeldreBarnRelasjon, Relasjon } from '@/components/fagsystem/pdlf/PdlTypes' import { RelatertPersonUtenId } from '@/components/fagsystem/pdlf/visning/partials/RelatertPersonUtenId' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialBarn, getInitialForelder, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foreldreansvar.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foreldreansvar.tsx index afac3357144..3b620a4699b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foreldreansvar.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Foreldreansvar.tsx @@ -3,7 +3,7 @@ import { getInitialForeldreansvar } from '@/components/fagsystem/pdlf/form/initi import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import * as React from 'react' import { TitleValue } from '@/components/ui/titleValue/TitleValue' -import _ from 'lodash' +import * as _ from 'lodash-es' import { formatDate } from '@/utils/DataFormatter' import { AdresseKodeverk } from '@/config/kodeverk' import { getEksisterendeNyPerson } from '@/components/fagsystem/utils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Innvandring.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Innvandring.tsx index 7c90165aff1..fe65d6082ec 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Innvandring.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Innvandring.tsx @@ -9,7 +9,7 @@ import { UtvandringValues, } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' import { initialInnvandring } from '@/components/fagsystem/pdlf/form/initialValues' -import _ from 'lodash' +import * as _ from 'lodash-es' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' import { PersonData } from '@/components/fagsystem/pdlf/PdlTypes' import { getSisteDato } from '@/components/bestillingsveileder/utils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Kontaktadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Kontaktadresse.tsx index 5052b471f24..046fca1d7ca 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Kontaktadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Kontaktadresse.tsx @@ -11,7 +11,7 @@ import { KodeverkValues, KontaktadresseData, } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' -import _ from 'lodash' +import * as _ from 'lodash-es' import { AdresseKodeverk } from '@/config/kodeverk' import { getInitialKontaktadresse } from '@/components/fagsystem/pdlf/form/initialValues' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/KontaktinformasjonForDoedsbo.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/KontaktinformasjonForDoedsbo.tsx index 0caa210884f..9df804f35b2 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/KontaktinformasjonForDoedsbo.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/KontaktinformasjonForDoedsbo.tsx @@ -5,7 +5,7 @@ import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { Personnavn } from '@/components/fagsystem/pdlf/visning/partials/Personnavn' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { RelatertPerson } from '@/components/fagsystem/pdlf/visning/partials/RelatertPerson' -import _ from 'lodash' +import * as _ from 'lodash-es' import { initialKontaktinfoForDoedebo } from '@/components/fagsystem/pdlf/form/initialValues' import { getEksisterendeNyPerson } from '@/components/fagsystem/utils' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Oppholdsadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Oppholdsadresse.tsx index d150e52ae79..d7569bef3cd 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Oppholdsadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Oppholdsadresse.tsx @@ -5,7 +5,7 @@ import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray import { Vegadresse } from '@/components/fagsystem/pdlf/visning/partials/Vegadresse' import { Matrikkeladresse } from '@/components/fagsystem/pdlf/visning/partials/Matrikkeladresse' import { UtenlandskAdresse } from '@/components/fagsystem/pdlf/visning/partials/UtenlandskAdresse' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialOppholdsadresse } from '@/components/fagsystem/pdlf/form/initialValues' import { OppholdsadresseData } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Persondetaljer.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Persondetaljer.tsx index 0485962c0ed..3e031d5f3dc 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Persondetaljer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Persondetaljer.tsx @@ -3,7 +3,7 @@ import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { formatDate, showLabel } from '@/utils/DataFormatter' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialKjoenn, getInitialNavn, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Personstatus.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Personstatus.tsx index e8272db4a6a..d17f289aa4f 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Personstatus.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Personstatus.tsx @@ -2,7 +2,7 @@ import React from 'react' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatDate, showLabel } from '@/utils/DataFormatter' -import _ from 'lodash' +import * as _ from 'lodash-es' import { initialPersonstatus } from '@/components/fagsystem/pdlf/form/initialValues' import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Sivilstand.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Sivilstand.tsx index 73c6b11c0a7..623bd91675b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Sivilstand.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Sivilstand.tsx @@ -10,7 +10,7 @@ import { getInitialSivilstand, initialPdlPerson, } from '@/components/fagsystem/pdlf/form/initialValues' -import _ from 'lodash' +import * as _ from 'lodash-es' import React from 'react' import { getEksisterendeNyPerson } from '@/components/fagsystem/utils' import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Statsborgerskap.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Statsborgerskap.tsx index 98ea475bf63..7d889c9c283 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Statsborgerskap.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Statsborgerskap.tsx @@ -1,7 +1,7 @@ import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import React from 'react' -import _ from 'lodash' +import * as _ from 'lodash-es' import { getInitialStatsborgerskap } from '@/components/fagsystem/pdlf/form/initialValues' import { PersonData, StatsborgerskapData } from '@/components/fagsystem/pdlf/PdlTypes' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Telefonnummer.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Telefonnummer.tsx index 7c5abe59a55..60923cb2708 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Telefonnummer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Telefonnummer.tsx @@ -3,7 +3,7 @@ import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { TelefonData } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' -import _ from 'lodash' +import * as _ from 'lodash-es' import VisningRedigerbarSamletConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarSamletConnector' type DataListe = { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/UtenlandsId.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/UtenlandsId.tsx index 56bee220406..6dd6948851b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/UtenlandsId.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/UtenlandsId.tsx @@ -6,7 +6,7 @@ import { oversettBoolean } from '@/utils/DataFormatter' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' import React from 'react' import { getInitialUtenlandskIdentifikasjonsnummer } from '@/components/fagsystem/pdlf/form/initialValues' -import _ from 'lodash' +import * as _ from 'lodash-es' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Utvandring.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Utvandring.tsx index b6c4710e456..c419984a9b8 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Utvandring.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Utvandring.tsx @@ -8,7 +8,7 @@ import { InnvandringValues, UtvandringValues, } from '@/pages/gruppe/PersonVisning/PersonMiljoeinfo/PdlDataTyper' -import _ from 'lodash' +import * as _ from 'lodash-es' import { PersonData } from '@/components/fagsystem/pdlf/PdlTypes' import { initialUtvandring } from '@/components/fagsystem/pdlf/form/initialValues' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Vergemaal.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Vergemaal.tsx index b7da27f8235..0aa9c82222a 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Vergemaal.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/partials/Vergemaal.tsx @@ -6,7 +6,7 @@ import { formatDate } from '@/utils/DataFormatter' import { RelatertPerson } from '@/components/fagsystem/pdlf/visning/partials/RelatertPerson' import { PersonData, Relasjon, VergemaalValues } from '@/components/fagsystem/pdlf/PdlTypes' import { VergemaalKodeverk } from '@/config/kodeverk' -import _ from 'lodash' +import * as _ from 'lodash-es' import { initialPdlPerson, initialVergemaal } from '@/components/fagsystem/pdlf/form/initialValues' import VisningRedigerbarConnector from '@/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarConnector' import { getEksisterendeNyPerson } from '@/components/fagsystem/utils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbar.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbar.tsx index a12c8150e24..2035c20ccd5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbar.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbar.tsx @@ -1,9 +1,9 @@ -import React, { useCallback, useRef, useState } from 'react' +import React, { lazy, Suspense, useCallback, useRef, useState } from 'react' import { FoedselForm } from '@/components/fagsystem/pdlf/form/partials/foedsel/Foedsel' import NavButton from '@/components/ui/button/NavButton/NavButton' import styled from 'styled-components' import Button from '@/components/ui/button/Button' -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyApi, PdlforvalterApi } from '@/service/Api' import Icon from '@/components/ui/icon/Icon' import { DollyModal } from '@/components/ui/modal/DollyModal' @@ -40,10 +40,9 @@ import { yupResolver } from '@hookform/resolvers/yup' import './VisningRedigerbarForm.less' import { FoedestedForm } from '@/components/fagsystem/pdlf/form/partials/foedsel/Foedested' import { FoedselsdatoForm } from '@/components/fagsystem/pdlf/form/partials/foedsel/Foedselsdato' -import DisplayFormState from '@/utils/DisplayFormState' -import DisplayFormErrors from '@/utils/DisplayFormErrors' import { devEnabled } from '@/components/bestillingsveileder/stegVelger/StegVelger' import { PersonstatusForm } from '@/components/fagsystem/pdlf/form/partials/personstatus/Personstatus' +import Loading from '@/components/ui/loading/Loading' type VisningTypes = { getPdlForvalter: Function @@ -131,6 +130,9 @@ export const VisningRedigerbar = ({ relatertPersonInfo = null, master = null, }: VisningTypes) => { + const DisplayFormState = lazy(() => import('@/utils/DisplayFormState')) + const DisplayFormErrors = lazy(() => import('@/utils/DisplayFormErrors')) + const [visningModus, setVisningModus] = useState(Modus.Les) const [errorMessagePdlf, setErrorMessagePdlf] = useState(null) const [errorMessagePdl, setErrorMessagePdl] = useState(null) @@ -401,8 +403,10 @@ export const VisningRedigerbar = ({ <> {devEnabled && ( <> - - + }> + + + )} diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarForm.less b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarForm.less index 5e7e0fb9303..b7349111d77 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarForm.less +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarForm.less @@ -1,13 +1,5 @@ .visning-redigerbar-form { - &&& .react-datepicker__navigation { - position: fixed; - } - - && .react-datepicker__year-wrapper { - display: flow; - } - && .navds-form-field--small .navds-date__field-button { top: 18px; right: 33px; diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarPersondetaljer.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarPersondetaljer.tsx index bc8aa13cf32..cd2a78c1be3 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarPersondetaljer.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarPersondetaljer.tsx @@ -3,7 +3,7 @@ import * as Yup from 'yup' import NavButton from '@/components/ui/button/NavButton/NavButton' import styled from 'styled-components' import Button from '@/components/ui/button/Button' -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyApi, PdlforvalterApi, SkjermingApi } from '@/service/Api' import Icon from '@/components/ui/icon/Icon' import { DollyModal } from '@/components/ui/modal/DollyModal' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarSamlet.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarSamlet.tsx index d0b6bf951a0..4a046cb474f 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarSamlet.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarSamlet.tsx @@ -4,14 +4,13 @@ import Loading from '@/components/ui/loading/Loading' import NavButton from '@/components/ui/button/NavButton/NavButton' import styled from 'styled-components' import Button from '@/components/ui/button/Button' -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyApi, PdlforvalterApi } from '@/service/Api' import Icon from '@/components/ui/icon/Icon' import { DollyModal } from '@/components/ui/modal/DollyModal' import useBoolean from '@/utils/hooks/useBoolean' import { ifPresent } from '@/utils/YupValidations' import { DollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldArray' -import { telefonnummer } from '@/components/fagsystem/pdlf/form/validation/partials' import { TelefonnummerFormRedigering } from '@/components/fagsystem/pdlf/form/partials/telefonnummer/Telefonnummer' import { TelefonnummerLes } from '@/components/fagsystem/pdlf/visning/partials/Telefonnummer' import { @@ -21,6 +20,7 @@ import { import { OpplysningSlettet } from '@/components/fagsystem/pdlf/visning/visningRedigerbar/OpplysningSlettet' import { Form, FormProvider, useForm } from 'react-hook-form' import { yupResolver } from '@hookform/resolvers/yup' +import { telefonnummer } from '../../form/validation/partials/telefonnummer' type VisningTypes = { getPdlForvalter: Function diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarValidation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarValidation.tsx index 42353f80f5f..33b39771bb3 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarValidation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pdlf/visning/visningRedigerbar/VisningRedigerbarValidation.tsx @@ -2,24 +2,24 @@ import * as Yup from 'yup' import { ifPresent } from '@/utils/YupValidations' import { doedsfall, navn } from '@/components/fagsystem/pdlf/form/validation/validation' import { - adressebeskyttelse, - bostedsadresse, + deltBosted, doedfoedtBarn, forelderBarnRelasjon, - innflytting, - kontaktadresse, - kontaktDoedsbo, - oppholdsadresse, - sivilstand, - statsborgerskap, - utenlandskId, - utflytting, - vergemaal, -} from '@/components/fagsystem/pdlf/form/validation/partials' -import { - deltBosted, foreldreansvarForBarn, + sivilstand, } from '@/components/fagsystem/pdlf/form/validation/partials/familierelasjoner' +import { statsborgerskap } from '@/components/fagsystem/pdlf/form/validation/partials/statborgerskap' +import { innflytting } from '@/components/fagsystem/pdlf/form/validation/partials/innvandring' +import { utflytting } from '@/components/fagsystem/pdlf/form/validation/partials/utflytting' +import { vergemaal } from '@/components/fagsystem/pdlf/form/validation/partials/vergemaal' +import { + adressebeskyttelse, + bostedsadresse, + kontaktadresse, + oppholdsadresse, +} from '@/components/fagsystem/pdlf/form/validation/partials/adresser' +import { kontaktDoedsbo } from '@/components/fagsystem/pdlf/form/validation/partials/kontaktinformasjonForDoedsbo' +import { utenlandskId } from '@/components/fagsystem/pdlf/form/validation/partials/identifikasjon' export const visningRedigerbarValidation = Yup.object().shape( { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/GenerertInntektForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/GenerertInntektForm.tsx index e036e62a877..b17edbfbc5c 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/GenerertInntektForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/GenerertInntektForm.tsx @@ -9,8 +9,8 @@ import { FormDollyFieldArray } from '@/components/ui/form/fieldArray/DollyFieldA import { pensjonGenererPath } from '@/components/fagsystem/pensjon/form/Form' import styled from 'styled-components' import NavButton from '@/components/ui/button/NavButton/NavButton' -import { ErrorMessage } from '@hookform/error-message' import { usePensjonFacadeGenerer } from '@/utils/hooks/usePensjon' +import { DisplayFormError } from '@/components/ui/toast/DisplayFormError' const getTittel = (data) => { const inntektsaar = data?.map((inntekt) => inntekt.ar) @@ -118,15 +118,7 @@ export const GenerertInntektForm = ({ gyldigFraOgMedAar, formMethods }) => {
- {formMethods.formState.errors && ( - ( -

{message}

- )} - /> - )} + {formInntekter?.length > 0 && ( diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/validation.tsx index 271c2000ec8..09250a9197a 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/pensjon/form/validation.tsx @@ -1,5 +1,5 @@ import * as Yup from 'yup' -import _ from 'lodash' +import * as _ from 'lodash-es' import { ifPresent, requiredNumber, requiredString } from '@/utils/YupValidations' import { TjenestepensjonForm } from '@/components/fagsystem/tjenestepensjon/form/Form' import { AlderspensjonForm } from '@/components/fagsystem/alderspensjon/form/Form' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/Form.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/Form.tsx index 7cb6080f139..d3737415d10 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/Form.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/Form.tsx @@ -16,7 +16,7 @@ import { import { getInitialInntekt } from '@/components/fagsystem/sigrunstubPensjonsgivende/utils' import { validation } from '@/components/fagsystem/sigrunstubPensjonsgivende/form/validation' import { useFormContext } from 'react-hook-form' -import _ from 'lodash' +import * as _ from 'lodash-es' export const getInitialSigrunstubPensjonsgivende = (kodeverk = null, skatteordning = null) => { return { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/PensjonsgivendeInntektForm.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/PensjonsgivendeInntektForm.tsx index fc86b544780..844e8b33ea5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/PensjonsgivendeInntektForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sigrunstubPensjonsgivende/form/PensjonsgivendeInntektForm.tsx @@ -8,7 +8,7 @@ import { getInitialInntekt, kodeverkKeyToLabel, } from '@/components/fagsystem/sigrunstubPensjonsgivende/utils' -import _ from 'lodash' +import * as _ from 'lodash-es' const getSkatteordningOptions = (skatteordning) => { return skatteordning?.map((item) => ({ value: item, label: _.capitalize(item) })) diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/skatteetaten/visning/SkatteetatenVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/skatteetaten/visning/SkatteetatenVisning.tsx index 824f1a79860..6cdeb3ddc8b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/skatteetaten/visning/SkatteetatenVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/skatteetaten/visning/SkatteetatenVisning.tsx @@ -1,7 +1,7 @@ import React from 'react' import Loading from '@/components/ui/loading/Loading' import Icon from '@/components/ui/icon/Icon' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { BrregErFrVisning } from '@/components/fagsystem/skatteetaten/visning/BrregErFrVisning' import { InntektVisning } from '@/components/fagsystem/skatteetaten/visning/InntektVisning' import { TjenestepensjonsavtaleVisning } from '@/components/fagsystem/skatteetaten/visning/TjenestepensjonsavtaleVisning' @@ -29,7 +29,7 @@ export const SkatteetatenVisning = ({ data, loading }: SkatteetatenVisningProps) const tjenestepensjonavtaleListe = tenorRelasjoner.tjenestepensjonavtale const harTjenestepensjonavtale = tjenestepensjonavtaleListe?.length > 0 - const harDagligLederRolle = _get(tenorRelasjoner, 'brreg-er-fr')?.length > 0 + const harDagligLederRolle = _.get(tenorRelasjoner, 'brreg-er-fr')?.length > 0 const skattemeldingListe = tenorRelasjoner.skattemelding const harSkattemelding = skattemeldingListe?.length > 0 diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/skattekort/visning/Visning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/skattekort/visning/Visning.tsx index 102d0525cb5..c5ed5d7cfe3 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/skattekort/visning/Visning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/skattekort/visning/Visning.tsx @@ -1,5 +1,5 @@ import Loading from '@/components/ui/loading/Loading' -import React from 'react' +import React, { lazy, Suspense } from 'react' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { Alert } from '@navikt/ds-react' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' @@ -10,13 +10,14 @@ import { useSkattekortKodeverk } from '@/utils/hooks/useSkattekort' import { ForskuddstrekkVisning } from '@/components/fagsystem/skattekort/visning/ForskuddstrekkVisning' import Button from '@/components/ui/button/Button' import useBoolean from '@/utils/hooks/useBoolean' -import { CodeView } from '@/components/codeView' type SkattekortVisning = { liste?: Array loading?: boolean } +const PrettyCode = lazy(() => import('@/components/codeView/PrettyCode')) + export const showKodeverkLabel = (kodeverkstype: string, value: string) => { const { kodeverk, loading, error } = useSkattekortKodeverk(kodeverkstype) if (loading || error) { @@ -106,7 +107,9 @@ export const SkattekortVisning = ({ liste, loading }: SkattekortVisning) => { {viserXml && (skattekort?.skattekortXml ? ( - + }> + + ) : ( Kunne ikke vise skattekort-xml diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/SykemeldingTypes.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/SykemeldingTypes.tsx index 31d22143ac3..a05759a545a 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/SykemeldingTypes.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/SykemeldingTypes.tsx @@ -32,6 +32,7 @@ export type SykemeldingDetaljert = { helsepersonell: Helsepersonell arbeidsgiver: Arbeidsgiver detaljer: Detaljer + kontaktMedPasient?: KontaktMedPasient perioder: Array } idx: number @@ -44,6 +45,11 @@ export type Diagnose = { system?: string } +export type KontaktMedPasient = { + begrunnelseIkkeKontakt: string + kontaktDato?: string +} + export type Helsepersonell = { fornavn: string mellomnavn?: string diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/form/partials/DetaljertSykemelding.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/form/partials/DetaljertSykemelding.tsx index d35debdd1a4..5377f25f09d 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/form/partials/DetaljertSykemelding.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/form/partials/DetaljertSykemelding.tsx @@ -15,8 +15,12 @@ import { } from '@/components/fagsystem/sykdom/SykemeldingTypes' import { useKodeverk } from '@/utils/hooks/useKodeverk' import { getRandomValue } from '@/components/fagsystem/utils' -import { useEffect } from 'react' +import { useContext, useEffect } from 'react' import { useHelsepersonellOptions } from '@/utils/hooks/useSelectOptions' +import { useSykemeldingValidering } from '@/utils/hooks/useSykemelding' +import { DollyErrorMessage } from '@/utils/DollyErrorMessage' +import { useWatch } from 'react-hook-form' +import { SwrMutateContext } from '@/components/bestillingsveileder/SwrMutateContext' type DiagnoseSelect = { diagnoseNavn: string @@ -42,10 +46,35 @@ const initialValuesPeriode = { const KODESYSTEM = '2.16.578.1.12.4.1.1.7170' export const DetaljertSykemelding = ({ formMethods }: SykemeldingForm) => { + const setContextMutate: any = useContext(SwrMutateContext) + const handleDiagnoseChange = (v: DiagnoseSelect, path: string) => { formMethods.setValue(`${path}.diagnose`, v.diagnoseNavn) formMethods.setValue(`${path}.system`, KODESYSTEM) } + const detaljertSykemelding = useWatch({ + name: 'sykemelding.detaljertSykemelding', + control: formMethods.control, + }) + + const { data, mutate, errorMessage } = useSykemeldingValidering(detaljertSykemelding) + + useEffect(() => { + if (errorMessage && errorMessage.length > 0) { + formMethods.setError('manual.sykemelding.detaljertSykemelding', { + type: 'manual', + message: errorMessage, + }) + } else formMethods.clearErrors('manual.sykemelding.detaljertSykemelding') + }, [errorMessage, data]) + + useEffect(() => { + setContextMutate(() => mutate) + formMethods.setError('manual.sykemelding.detaljertSykemelding', { + type: 'manual', + message: 'Trykk "Videre" for å validere sykemeldingen', + }) + }, [mutate]) const handleLegeChange = (v: Helsepersonell) => { formMethods.setValue('sykemelding.detaljertSykemelding.helsepersonell', { @@ -95,6 +124,7 @@ export const DetaljertSykemelding = ({ formMethods }: SykemeldingForm) => { return (
+
{ /> )} + +
+ + +
+
{ + const setFormMutate: any = useContext(SwrMutateContext) + const formMethods = useFormContext() + + useEffect(() => { + setFormMutate?.(undefined) + formMethods.clearErrors('manual.sykemelding.detaljertSykemelding') + }, []) return (
diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/Visning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/Visning.tsx index 660ab7fe61f..e5f3e48d002 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/Visning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/Visning.tsx @@ -1,131 +1,123 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' -import {SyntSykemelding} from './partials/SyntSykemelding' -import {DetaljertSykemelding} from './partials/DetaljertSykemelding' -import { - Sykemelding, - SykemeldingDetaljert, - SykemeldingSynt -} from '../SykemeldingTypes' -import {erGyldig} from '@/components/transaksjonid/GyldigeBestillinger' -import {Alert} from '@navikt/ds-react' +import { SyntSykemelding } from './partials/SyntSykemelding' +import { DetaljertSykemelding } from './partials/DetaljertSykemelding' +import { Sykemelding, SykemeldingDetaljert, SykemeldingSynt } from '../SykemeldingTypes' +import { erGyldig } from '@/components/transaksjonid/GyldigeBestillinger' +import { Alert } from '@navikt/ds-react' import React from 'react' -import {MiljoTabs} from '@/components/ui/miljoTabs/MiljoTabs' -import {useBestilteMiljoer} from '@/utils/hooks/useBestilling' +import { MiljoTabs } from '@/components/ui/miljoTabs/MiljoTabs' +import { useBestilteMiljoer } from '@/utils/hooks/useBestilling' import Loading from '@/components/ui/loading/Loading' export const sjekkManglerSykemeldingData = (sykemeldingData) => { - return ( - !sykemeldingData || - sykemeldingData?.length < 1 || - sykemeldingData?.every((miljoData) => !miljoData.data) - ) + return ( + !sykemeldingData || + sykemeldingData?.length < 1 || + sykemeldingData?.every((miljoData) => !miljoData.data) + ) } export const sjekkManglerSykemeldingBestilling = (sykemeldingBestilling) => { - return !sykemeldingBestilling || sykemeldingBestilling?.length < 1 + return !sykemeldingBestilling || sykemeldingBestilling?.length < 1 } -const VisningAvBestilling = ({bestillinger}) => { - if (!bestillinger) { - return null - } - - return bestillinger?.map((bestilling: SykemeldingSynt | SykemeldingDetaljert, idx: number) => { - if (!bestilling.erGjenopprettet) { - const syntSykemelding = _.get(bestilling, 'data.sykemelding.syntSykemelding') - const detaljertSykemelding = _.get(bestilling, 'data.sykemelding.detaljertSykemelding') - - return syntSykemelding ? ( - - ) : detaljertSykemelding ? ( - - ) : null - } - }) +const VisningAvBestilling = ({ bestillinger }) => { + if (!bestillinger) { + return null + } + + return bestillinger?.map((bestilling: SykemeldingSynt | SykemeldingDetaljert, idx: number) => { + if (!bestilling.erGjenopprettet) { + const syntSykemelding = _.get(bestilling, 'data.sykemelding.syntSykemelding') + const detaljertSykemelding = _.get(bestilling, 'data.sykemelding.detaljertSykemelding') + + return syntSykemelding ? ( + + ) : detaljertSykemelding ? ( + + ) : null + } + }) } -const VisningAvTransaksjonsId = ({data}) => { - if (!data) { - return null - } - - const syntSykemelding = _.get(data, 'syntSykemeldingRequest') - const detaljertSykemelding = _.get(data, 'detaljertSykemeldingRequest') - const sykemeldingId = _.get(data, 'sykemeldingId') - - if (syntSykemelding) { - syntSykemelding['sykemeldingId'] = sykemeldingId - return - } - if (detaljertSykemelding) { - detaljertSykemelding['sykemeldingId'] = sykemeldingId - return < DetaljertSykemelding sykemelding={detaljertSykemelding}/> - } +const VisningAvTransaksjonsId = ({ data }) => { + if (!data) { + return null + } + + const syntSykemelding = _.get(data, 'syntSykemeldingRequest') + const detaljertSykemelding = _.get(data, 'detaljertSykemeldingRequest') + const sykemeldingId = _.get(data, 'sykemeldingId') + + if (syntSykemelding) { + syntSykemelding['sykemeldingId'] = sykemeldingId + return + } + if (detaljertSykemelding) { + detaljertSykemelding['sykemeldingId'] = sykemeldingId + return + } } export const SykemeldingVisning = ({ - data, - loading, - bestillingIdListe, - tilgjengeligMiljoe, - bestillinger, - }: Sykemelding) => { - const {bestilteMiljoer} = useBestilteMiljoer(bestillingIdListe, 'SYKEMELDING') - - if (loading) { - return - } - - if (!data && !bestillinger) { - return null - } - - const manglerFagsystemData = - sjekkManglerSykemeldingData(data) && sjekkManglerSykemeldingBestilling(bestillinger) - - const miljoerMedData = data?.map((miljoData) => miljoData.data && miljoData.miljo) - const errorMiljoer = bestilteMiljoer?.filter((miljo) => !miljoerMedData?.includes(miljo)) - - const forsteMiljo = data?.find((miljoData) => miljoData?.data)?.miljo - - const filteredData = - tilgjengeligMiljoe && data?.filter((item) => tilgjengeligMiljoe.includes(item.miljo)) - - return ( -
- - {manglerFagsystemData ? ( - - Fant ikke sykemelding-data på person - - ) : sjekkManglerSykemeldingData(data) ? ( - - ) : ( - - - - )} -
- ) + data, + loading, + bestillingIdListe, + tilgjengeligMiljoe, + bestillinger, +}: Sykemelding) => { + const { bestilteMiljoer } = useBestilteMiljoer(bestillingIdListe, 'SYKEMELDING') + + if (loading) { + return + } + + if (!data && !bestillinger) { + return null + } + + const manglerFagsystemData = + sjekkManglerSykemeldingData(data) && sjekkManglerSykemeldingBestilling(bestillinger) + + const miljoerMedData = data?.map((miljoData) => miljoData.data && miljoData.miljo) + const errorMiljoer = bestilteMiljoer?.filter((miljo) => !miljoerMedData?.includes(miljo)) + + const forsteMiljo = data?.find((miljoData) => miljoData?.data)?.miljo + + const filteredData = + tilgjengeligMiljoe && data?.filter((item) => tilgjengeligMiljoe.includes(item.miljo)) + + return ( +
+ + {manglerFagsystemData ? ( + + Fant ikke sykemelding-data på person + + ) : sjekkManglerSykemeldingData(data) ? ( + + ) : ( + + + + )} +
+ ) } SykemeldingVisning.filterValues = (bestillinger: Array, ident: string) => { - if (!bestillinger) { - return null - } - - return bestillinger.filter( - (bestilling: any) => - bestilling.data?.sykemelding && erGyldig(bestilling.id, 'SYKEMELDING', ident), - ) + if (!bestillinger) { + return null + } + + return bestillinger.filter( + (bestilling: any) => + bestilling.data?.sykemelding && erGyldig(bestilling.id, 'SYKEMELDING', ident), + ) } diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/partials/DetaljertSykemelding.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/partials/DetaljertSykemelding.tsx index 4fe1c7172eb..e421013949d 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/partials/DetaljertSykemelding.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/sykdom/visning/partials/DetaljertSykemelding.tsx @@ -1,119 +1,114 @@ import * as React from 'react' -import {formatStringDates, oversettBoolean} from '@/utils/DataFormatter' -import {TitleValue} from '@/components/ui/titleValue/TitleValue' -import {Bidiagnoser} from './Bidiagnoser' -import {Perioder} from './Perioder' -import {ArbeidKodeverk} from '@/config/kodeverk' -import { - SykemeldingDetaljert -} from '@/components/fagsystem/sykdom/SykemeldingTypes' +import { formatStringDates, oversettBoolean } from '@/utils/DataFormatter' +import { TitleValue } from '@/components/ui/titleValue/TitleValue' +import { Bidiagnoser } from './Bidiagnoser' +import { Perioder } from './Perioder' +import { ArbeidKodeverk } from '@/config/kodeverk' +import { SykemeldingDetaljert } from '@/components/fagsystem/sykdom/SykemeldingTypes' import styled from 'styled-components' export const SykemeldingKategori = styled.div` - width: 100%; + width: 100%; - h4 { - margin-top: 5px; - margin-bottom: 15px; - } + h4 { + margin-top: 5px; + margin-bottom: 15px; + } ` -export const DetaljertSykemelding = ({ - sykemelding, - idx - }: SykemeldingDetaljert) => { - console.log('sykemelding', sykemelding) - return ( -
- -
- - - -
- <> - -

Diagnose

-
-
- - -
- - - <> - -

Helsepersonell

-
-
- - - - -
- - <> - -

Arbeidsgiver

-
-
- - - -
- - - <> - -

Detaljer

-
-
- - - - - -
- -
-
- ) -} +export const DetaljertSykemelding = ({ sykemelding, idx }: SykemeldingDetaljert) => ( +
+ +
+ + + +
+ <> + +

Diagnose

+
+
+ + +
+ + + {sykemelding.kontaktMedPasient && ( + <> + +

Tilbakedatering

+
+
+ + +
+ + )} + <> + +

Helsepersonell

+
+
+ + + + +
+ + <> + +

Arbeidsgiver

+
+
+ + + +
+ + + <> + +

Detaljer

+
+
+ + + + + +
+ +
+
+) diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/Visning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/Visning.tsx index 129e48d241d..8b66d99c1c4 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/Visning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/Visning.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { MidlertidigAdresse, Postadresse, diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Adressevalg.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Adressevalg.tsx index a3144fe72f5..136c6a43953 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Adressevalg.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Adressevalg.tsx @@ -1,7 +1,7 @@ import { Historikk } from '@/components/ui/historikk/Historikk' import { Adressevisning } from '@/components/fagsystem/tpsf/visning/partials/Boadresse' import { PostadresseVisning } from '@/components/fagsystem/tpsf/visning/partials/Postadresse' -import _ from 'lodash' +import * as _ from 'lodash-es' export const Adressevalg = ({ data }: any) => { return ( diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/MidlertidigAdresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/MidlertidigAdresse.tsx index 243863772a1..2d7795b8b7a 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/MidlertidigAdresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/MidlertidigAdresse.tsx @@ -4,7 +4,7 @@ import { TitleValue } from '@/components/ui/titleValue/TitleValue' import KodeverkConnector from '@/components/kodeverk/KodeverkConnector' import { Historikk } from '@/components/ui/historikk/Historikk' import { ErrorBoundary } from '@/components/ui/appError/ErrorBoundary' -import _ from 'lodash' +import * as _ from 'lodash-es' type AlleMidlertidigeAdresser = { midlertidigAdresse: Array diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Personinfo.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Personinfo.tsx index 8e1c0cfa49b..64cd18d3fe5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Personinfo.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Personinfo.tsx @@ -3,7 +3,7 @@ import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatAlder, formatDate, formatKjonn, gtTypeLabel } from '@/utils/DataFormatter' import { GtKodeverk, PersoninformasjonKodeverk } from '@/config/kodeverk' -import _ from 'lodash' +import * as _ from 'lodash-es' function hentSkjermingData(skjermingPath) { if (!skjermingPath) { diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Postadresse.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Postadresse.tsx index c70283141ef..42efa7d4300 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Postadresse.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/tpsf/visning/partials/Postadresse.tsx @@ -2,7 +2,7 @@ import { AdresseKodeverk } from '@/config/kodeverk' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { Historikk } from '@/components/ui/historikk/Historikk' -import _ from 'lodash' +import * as _ from 'lodash-es' export const PostadresseVisning = ({ postadresse }) => { const { postLinje1, postLinje2, postLinje3, postLand } = postadresse diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/form/validation.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/form/validation.tsx index 689165b6bcd..47aabeb8da5 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/form/validation.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/form/validation.tsx @@ -1,5 +1,5 @@ import * as Yup from 'yup' -import _ from 'lodash' +import * as _ from 'lodash-es' import { ifPresent, requiredBoolean, requiredString } from '@/utils/YupValidations' import { testDatoFom, testDatoTom } from '@/components/fagsystem/utils' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/UdiVisning.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/UdiVisning.tsx index fab4549f125..2ff674e39d8 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/UdiVisning.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/UdiVisning.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import SubOverskrift from '@/components/ui/subOverskrift/SubOverskrift' import Loading from '@/components/ui/loading/Loading' import { Oppholdsstatus } from './partials/Oppholdsstatus' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/partials/Oppholdsstatus.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/partials/Oppholdsstatus.tsx index bcd4afe21f8..d6462397fff 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/partials/Oppholdsstatus.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/udistub/visning/partials/Oppholdsstatus.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { TitleValue } from '@/components/ui/titleValue/TitleValue' import { formatStringDates, showLabel } from '@/utils/DataFormatter' import { AvslagEllerBortfall, AvslagEllerBortfallVisning } from './AvslagEllerBortfallVisning' diff --git a/apps/dolly-frontend/src/main/js/src/components/fagsystem/utils.tsx b/apps/dolly-frontend/src/main/js/src/components/fagsystem/utils.tsx index 466901b1772..841d1c7945a 100644 --- a/apps/dolly-frontend/src/main/js/src/components/fagsystem/utils.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/fagsystem/utils.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { isAfter, isBefore, isEqual } from 'date-fns' import { Relasjon } from '@/components/fagsystem/pdlf/PdlTypes' diff --git a/apps/dolly-frontend/src/main/js/src/components/infostripe/InfoStripe.tsx b/apps/dolly-frontend/src/main/js/src/components/infostripe/InfoStripe.tsx index 0cd7d7a1735..a9167a3fde2 100644 --- a/apps/dolly-frontend/src/main/js/src/components/infostripe/InfoStripe.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/infostripe/InfoStripe.tsx @@ -7,7 +7,7 @@ import Button from '@/components/ui/button/Button' import Icon from '@/components/ui/icon/Icon' import './InfoStripe.less' -import _ from 'lodash' +import * as _ from 'lodash-es' const getInfoStripeUrl = `/dolly-backend/api/v1/infostripe` const HIDDEN_ALERTS = 'HIDDEN_ALERTS' diff --git a/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/Inntekt.tsx b/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/Inntekt.tsx index 8e252384b93..6305ef97800 100644 --- a/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/Inntekt.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/Inntekt.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { AdresseKodeverk } from '@/config/kodeverk' import { FormSelect } from '@/components/ui/form/inputs/select/Select' import { FormTextInput } from '@/components/ui/form/inputs/textInput/TextInput' diff --git a/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/index.tsx b/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/index.tsx index e53826e7653..101f155b647 100644 --- a/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/inntektStub/validerInntekt/index.tsx @@ -1,7 +1,7 @@ import React, { useEffect, useState } from 'react' import Inntekt from '@/components/inntektStub/validerInntekt/Inntekt' import InntektstubService from '@/service/services/inntektstub/InntektstubService' -import _ from 'lodash' +import * as _ from 'lodash-es' import { Form, useFormContext, useWatch } from 'react-hook-form' import { isObjectEmptyDeep } from '@/components/ui/form/formUtils' diff --git a/apps/dolly-frontend/src/main/js/src/components/redigerGruppe/RedigerGruppe.tsx b/apps/dolly-frontend/src/main/js/src/components/redigerGruppe/RedigerGruppe.tsx index 1b072fd6533..c42680f8752 100644 --- a/apps/dolly-frontend/src/main/js/src/components/redigerGruppe/RedigerGruppe.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/redigerGruppe/RedigerGruppe.tsx @@ -9,7 +9,7 @@ import { useNavigate } from 'react-router-dom' import { REGEX_BACKEND_GRUPPER, useMatchMutate } from '@/utils/hooks/useMutate' import { TestComponentSelectors } from '#/mocks/Selectors' import { useGruppeById } from '@/utils/hooks/useGruppe' -import _get from 'lodash/get' +import * as _ from 'lodash-es' import { Form, FormProvider, useForm } from 'react-hook-form' import { yupResolver } from '@hookform/resolvers/yup' @@ -45,8 +45,8 @@ const RedigerGruppe = ({ const { gruppe } = useGruppeById(gruppeId) const erRedigering = gruppe?.id !== undefined const initialValues = { - navn: _get(gruppe, 'navn', ''), - hensikt: _get(gruppe, 'hensikt', ''), + navn: _.get(gruppe, 'navn', ''), + hensikt: _.get(gruppe, 'hensikt', ''), } const mutate = useMatchMutate() const formMethods = useForm({ diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/background/Background.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/background/Background.tsx index dec5bce3e5a..69e579a6b90 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/background/Background.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/background/Background.tsx @@ -21,7 +21,7 @@ import '@/snow.scss' import '@/rain.scss' import '@/flowers.scss' import { NEDBOER_TYPE, useWeatherFyrstikkAlleen } from '@/utils/hooks/useWeather' -import _ from 'lodash' +import * as _ from 'lodash-es' const month = new Date().getMonth() const day = new Date().getDate() diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/button/RelatertPersonImportButton/RelatertPersonImportButton.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/button/RelatertPersonImportButton/RelatertPersonImportButton.tsx index a260807bcb6..0d404d55c23 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/button/RelatertPersonImportButton/RelatertPersonImportButton.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/button/RelatertPersonImportButton/RelatertPersonImportButton.tsx @@ -9,7 +9,7 @@ import { DollyApi } from '@/service/Api' import './RelatertPersonImportButton.less' import { DollyCheckbox } from '@/components/ui/form/inputs/checbox/Checkbox' import { allCapsToCapitalized } from '@/utils/DataFormatter' -import _ from 'lodash' +import * as _ from 'lodash-es' import { REGEX_BACKEND_GRUPPER, useMatchMutate } from '@/utils/hooks/useMutate' import { FormProvider, useFieldArray, useForm } from 'react-hook-form' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/dollyTable/table/Table.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/dollyTable/table/Table.tsx index c22f479fe25..8ee83a542df 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/dollyTable/table/Table.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/dollyTable/table/Table.tsx @@ -1,7 +1,7 @@ import cn from 'classnames' import Row from './TableRow' import Column from './TableColumn' -import _ from 'lodash' +import * as _ from 'lodash-es' import { LaastGruppeIconItem } from '@/components/ui/icon/IconItem' import './Table.less' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/formUtils.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/formUtils.tsx index 4648751b76f..0be8bce498b 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/formUtils.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/formUtils.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import { runningE2ETest } from '@/service/services/Request' import { isDate } from 'date-fns' import { useFormContext } from 'react-hook-form' @@ -13,7 +13,7 @@ export const panelError = (attributtPath) => { // Strings er akseptert, men konverter til Array if (!Array.isArray(attributtPath)) attributtPath = [attributtPath] - return attributtPath.some((attr) => _.has(errors, attr)) + return attributtPath.some((attr) => _.has(errors, attr) || _.has(errors, `manual.${attr}`)) } export const SyntEvent = (name, value) => ({ target: { name, value } }) diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.less b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.less deleted file mode 100644 index a0530bcd5cd..00000000000 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.less +++ /dev/null @@ -1,5 +0,0 @@ -@import (reference) '@/styles/variables.less'; - -.react-datepicker-wrapper { - width: 100%; -} diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.tsx index be2062d8add..0a075c14630 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/datepicker/Datepicker.tsx @@ -1,10 +1,6 @@ -import { registerLocale } from 'react-datepicker' import { addYears, subYears } from 'date-fns' -import locale_nb from 'date-fns/locale/nb' import { Vis } from '@/components/bestillingsveileder/VisAttributt' import { SyntEvent } from '@/components/ui/form/formUtils' -import 'react-datepicker/dist/react-datepicker.css' -import './Datepicker.less' import { useFormContext } from 'react-hook-form' import { DatePicker, useDatepicker } from '@navikt/ds-react' import React, { BaseSyntheticEvent, useCallback, useEffect, useState } from 'react' @@ -14,8 +10,6 @@ import { Label } from '@/components/ui/form/inputs/label/Label' import { formatDate } from '@/utils/DataFormatter' import { convertInputToDate } from '@/components/ui/form/DateFormatUtils' -registerLocale('nb', locale_nb) - export const DollyDatepicker = (props: any) => { const { excludeDates, diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/label/Label.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/label/Label.tsx index a8c614c877f..637125e5865 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/label/Label.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/label/Label.tsx @@ -1,5 +1,5 @@ import cn from 'classnames' -import _ from 'lodash' +import * as _ from 'lodash-es' import styled from 'styled-components' import './Label.less' import { Hjelpetekst } from '@/components/hjelpetekst/Hjelpetekst' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/monthpicker/Monthpicker.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/monthpicker/Monthpicker.tsx index a0f244a194c..a039e09eaff 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/monthpicker/Monthpicker.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/monthpicker/Monthpicker.tsx @@ -3,7 +3,7 @@ import { InputWrapper } from '@/components/ui/form/inputWrapper/InputWrapper' import { MonthPicker, useMonthpicker } from '@navikt/ds-react' import { addYears, isDate, subYears } from 'date-fns' import { useFormContext } from 'react-hook-form' -import _ from 'lodash' +import * as _ from 'lodash-es' import { useEffect } from 'react' interface MonthpickerProps { diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/select/Select.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/select/Select.tsx index c15f0a5cd95..a28c6220437 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/select/Select.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/select/Select.tsx @@ -7,7 +7,7 @@ import { SyntEvent } from '@/components/ui/form/formUtils' import './Select.less' import MenuList from '@/components/ui/form/inputs/select/MenuList' import Option from '@/components/ui/form/inputs/select/Option' -import _ from 'lodash' +import * as _ from 'lodash-es' import { useKodeverk } from '@/utils/hooks/useKodeverk' import { useController, useFormContext } from 'react-hook-form' import { useContext } from 'react' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/textInput/TextInput.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/textInput/TextInput.tsx index 75289255037..6490cd4e0fd 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/textInput/TextInput.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/form/inputs/textInput/TextInput.tsx @@ -10,7 +10,7 @@ import { ShowErrorContext, ShowErrorContextType, } from '@/components/bestillingsveileder/ShowErrorContext' -import _ from 'lodash' +import * as _ from 'lodash-es' import FormFieldInput from '@/components/ui/form/inputs/textInput/FormFieldInput' import { Button } from '@navikt/ds-react' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/historikk/Historikk.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/historikk/Historikk.tsx index 20ef1f64f6e..eaa14fb0c36 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/historikk/Historikk.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/historikk/Historikk.tsx @@ -1,4 +1,4 @@ -import _ from 'lodash' +import * as _ from 'lodash-es' import './historikk.less' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/titleValue/TitleValue.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/titleValue/TitleValue.tsx index b03486dabb4..bfd25080578 100644 --- a/apps/dolly-frontend/src/main/js/src/components/ui/titleValue/TitleValue.tsx +++ b/apps/dolly-frontend/src/main/js/src/components/ui/titleValue/TitleValue.tsx @@ -1,5 +1,5 @@ import cn from 'classnames' -import _ from 'lodash' +import * as _ from 'lodash-es' import KodeverkConnector from '@/components/kodeverk/KodeverkConnector' import Loading from '@/components/ui/loading/Loading' diff --git a/apps/dolly-frontend/src/main/js/src/components/ui/toast/DisplayFormError.tsx b/apps/dolly-frontend/src/main/js/src/components/ui/toast/DisplayFormError.tsx new file mode 100644 index 00000000000..f125208cd0f --- /dev/null +++ b/apps/dolly-frontend/src/main/js/src/components/ui/toast/DisplayFormError.tsx @@ -0,0 +1,32 @@ +import 'react-toastify/dist/ReactToastify.css' +import { ErrorMessage } from '@hookform/error-message' +import * as React from 'react' +import { useContext } from 'react' +import { useFormContext } from 'react-hook-form' +import { + ShowErrorContext, + ShowErrorContextType, +} from '@/components/bestillingsveileder/ShowErrorContext' + +type Props = { + path: string + errorMessage?: string +} + +export const DisplayFormError = ({ path, errorMessage }: Props) => { + const formMethods = useFormContext() + const errorContext: ShowErrorContextType = useContext(ShowErrorContext) + + return ( + errorContext.showError && + formMethods.formState.errors && ( + ( +

{errorMessage || message}

+ )} + /> + ) + ) +} diff --git a/apps/dolly-frontend/src/main/js/src/ducks/bestilling/index.tsx b/apps/dolly-frontend/src/main/js/src/ducks/bestilling/index.tsx index 1c12d2937c0..a1f690c4970 100644 --- a/apps/dolly-frontend/src/main/js/src/ducks/bestilling/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/ducks/bestilling/index.tsx @@ -1,10 +1,9 @@ import { createActions } from 'redux-actions' import { DollyApi } from '@/service/Api' -import _ from 'lodash' -import _set from 'lodash/fp/set' import { handleActions } from '@/ducks/utils/immerHandleActions' import { getLeggTilIdent, rootPaths } from '@/components/bestillingsveileder/utils' import { v4 as uuid } from 'uuid' +import * as _ from 'lodash-es' import { Logger } from '@/logger/Logger' export const actions = createActions( @@ -57,17 +56,13 @@ export const sendBestilling = (values, opts, gruppeId, navigate) => async (dispa } else if (opts.is.leggTilPaaGruppe) { bestillingAction = actions.postBestillingLeggTilPaaGruppe(gruppeId, values) } else if (opts.is.opprettFraIdenter) { - values = _set('opprettFraIdenter', opts.opprettFraIdenter, values) + values = Object.assign({}, values, { opprettFraIdenter: opts.opprettFraIdenter }) bestillingAction = actions.postBestillingFraEksisterendeIdenter(gruppeId, values) } else if (opts.is.importTestnorge) { - values = _set( - 'identer', - opts.importPersoner.map((person) => person.ident), - values, - ) - if (!values.environments) { - values = _set('environments', [], values) - } + values = Object.assign({}, values, { + identer: opts.importPersoner.map((person) => person.ident), + environments: values.environments || [], + }) bestillingAction = actions.postTestnorgeBestilling(values.gruppeId, values) } else if (values.organisasjon) { trackBestilling(values) diff --git a/apps/dolly-frontend/src/main/js/src/ducks/bestillingStatus/index.tsx b/apps/dolly-frontend/src/main/js/src/ducks/bestillingStatus/index.tsx index c639daa2546..43fecef6679 100644 --- a/apps/dolly-frontend/src/main/js/src/ducks/bestillingStatus/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/ducks/bestillingStatus/index.tsx @@ -1,5 +1,5 @@ import { createActions } from 'redux-actions' -import _ from 'lodash' +import * as _ from 'lodash-es' import { DollyApi } from '@/service/Api' export const { diff --git a/apps/dolly-frontend/src/main/js/src/ducks/errors/index.tsx b/apps/dolly-frontend/src/main/js/src/ducks/errors/index.tsx index 7709b9750f2..69e0ca868b4 100644 --- a/apps/dolly-frontend/src/main/js/src/ducks/errors/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/ducks/errors/index.tsx @@ -1,6 +1,6 @@ import { createAction } from 'redux-actions' import { createSelector } from 'reselect' -import _ from 'lodash' +import * as _ from 'lodash-es' export const clearAllErrors = createAction('ERRORS/CLEAR_ALL_ERRORS') export const addGlobalError = createAction('ERRORS/ADD_GLOBAL_ERROR') diff --git a/apps/dolly-frontend/src/main/js/src/ducks/fagsystem/index.tsx b/apps/dolly-frontend/src/main/js/src/ducks/fagsystem/index.tsx index 62c205f6273..2411b201ba6 100644 --- a/apps/dolly-frontend/src/main/js/src/ducks/fagsystem/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/ducks/fagsystem/index.tsx @@ -14,7 +14,7 @@ import { onSuccess } from '@/ducks/utils/requestActions' import { successMiljoSelector } from '@/ducks/bestillingStatus' import { handleActions } from '@/ducks/utils/immerHandleActions' import { formatAlder, formatKjonn } from '@/utils/DataFormatter' -import _ from 'lodash' +import * as _ from 'lodash-es' export const actions = createActions( { diff --git a/apps/dolly-frontend/src/main/js/src/ducks/finnPerson/index.tsx b/apps/dolly-frontend/src/main/js/src/ducks/finnPerson/index.tsx index 2eaf7f7ae4a..789c5c5f03d 100644 --- a/apps/dolly-frontend/src/main/js/src/ducks/finnPerson/index.tsx +++ b/apps/dolly-frontend/src/main/js/src/ducks/finnPerson/index.tsx @@ -4,7 +4,7 @@ import { onFailure, onSuccess } from '@/ducks/utils/requestActions' import { handleActions } from '@/ducks/utils/immerHandleActions' import { LOCATION_CHANGE } from 'redux-first-history' import { VisningType } from '@/pages/gruppe/Gruppe' -import { isEmpty } from 'lodash' +import * as _ from 'lodash-es' import { ERROR_NAVIGATE_IDENT } from '../errors/ErrorMessages' export const { @@ -56,7 +56,7 @@ export default handleActions( state.feilmelding = action.payload.data?.message }, [onSuccess(navigerTilPerson)](state, action) { - state.feilmelding = isEmpty(action.payload?.data) + state.feilmelding = _.isEmpty(action.payload?.data) ? ERROR_NAVIGATE_IDENT : action.payload?.data?.message state.hovedperson = action.payload.data.identHovedperson diff --git a/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgOversikt.tsx b/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgOversikt.tsx index acbb57d55f5..09586b69d52 100644 --- a/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgOversikt.tsx +++ b/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgOversikt.tsx @@ -34,7 +34,6 @@ export const OrgOversikt = ({ organisasjonTilgang, loading, error, mutate }: Ove Navn Form Miljø - Gyldig til Endre org. @@ -46,7 +45,6 @@ export const OrgOversikt = ({ organisasjonTilgang, loading, error, mutate }: Ove {navn} {organisasjonsform} {miljoe} - {formatDate(gyldigTil)} diff --git a/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgtilgangForm.tsx b/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgtilgangForm.tsx index bb56706201b..85d2358504b 100644 --- a/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgtilgangForm.tsx +++ b/apps/dolly-frontend/src/main/js/src/pages/adminPages/Orgtilgang/OrgtilgangForm.tsx @@ -86,7 +86,6 @@ export const OrgtilgangForm = ({ mutate }: any) => { isMulti={true} size="medium" /> -