Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
AudunSorheim committed Nov 27, 2023
1 parent 67effb6 commit db0d7ec
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/components/history/HistoricEventsSummary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ const getHeaderText = (viewItem: AktivitetskravViewItem) => {
switch (viewItem.type) {
case "UNDER_BEHANDLING":
return "NAV vurderer aktivitetsplikten din";
case "IKKE_OPPFYLT":
return "Svarfristen din har gått ut";
case "FORHANDSVARSEL":
return "Forhåndsvarsel om stans av sykepenger";
case "MOTTATT_VURDERING":
Expand Down
3 changes: 3 additions & 0 deletions src/components/view/Vurdering.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { ForhandsvarselComponent } from "@/components/view/ForhandsvarselCompone
import { UnderBehandlingComponent } from "@/components/view/UnderBehandlingComponent";
import { MottattVurderingComponent } from "@/components/view/MottattVurderingComponent";
import { AktivitetskravViewItem } from "@/components/view/viewUtils";
import { IkkeOppfyltComponent } from "@/components/view/ikkeOppfylt/IkkeOppfyltComponent";

interface Props {
viewItem?: AktivitetskravViewItem | null;
Expand All @@ -19,6 +20,8 @@ export const Vurdering = ({ viewItem }: Props): ReactElement | null => {
return <MottattVurderingComponent vurdering={viewItem.vurdering} />;
case "UNDER_BEHANDLING":
return <UnderBehandlingComponent />;
case "IKKE_OPPFYLT":
return <IkkeOppfyltComponent />;
default:
return null;
}
Expand Down
22 changes: 22 additions & 0 deletions src/components/view/ikkeOppfylt/IkkeOppfyltComponent.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
"use client";
import React from "react";
import { ComponentHeader } from "@/components/accordion/ComponentHeader";
import { BodyLong } from "@navikt/ds-react";

export const IkkeOppfyltComponent = () => {
return (
<>
<ComponentHeader headerText={"Svarfristen din har gått ut"} />

<div className="flex flex-col gap-4">
<BodyLong>Hei!</BodyLong>

<BodyLong>
Svarfristen til forhåndsvarslet har gått ut. NAV vurderer fremdeles
aktivitetsplikten din. Du vil motta ny informasjon så snart NAV har
fullført vurderingen. 
</BodyLong>
</div>
</>
);
};
15 changes: 12 additions & 3 deletions src/components/view/viewUtils.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import { AktivitetskravVurdering } from "@/schema/aktivitetskravVurderingSchema";

export interface AktivitetskravViewItem {
type: "UNDER_BEHANDLING" | "FORHANDSVARSEL" | "MOTTATT_VURDERING";
type:
| "UNDER_BEHANDLING"
| "FORHANDSVARSEL"
| "MOTTATT_VURDERING"
| "IKKE_OPPFYLT";
vurdering: AktivitetskravVurdering;
}

Expand All @@ -23,8 +27,7 @@ export const mapVurderingToViewItem = (
}
case "AVVENT":
case "NY":
case "NY_VURDERING":
case "IKKE_OPPFYLT": {
case "NY_VURDERING": {
return {
type: "UNDER_BEHANDLING",
vurdering: vurdering,
Expand All @@ -37,5 +40,11 @@ export const mapVurderingToViewItem = (
type: "MOTTATT_VURDERING",
vurdering: vurdering,
};
case "IKKE_OPPFYLT": {
return {
type: "IKKE_OPPFYLT",
vurdering: vurdering,
};
}
}
};

0 comments on commit db0d7ec

Please sign in to comment.