Skip to content

Commit

Permalink
bug fixes (#453)
Browse files Browse the repository at this point in the history
* linkfy informasjonselement

* fix mobileview, use full height

* fix margin

* fix margin chat
  • Loading branch information
marcjas authored May 16, 2023
1 parent 766966f commit 526ffc0
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@ const App = (props: Props) => {
return (
<div
className={cx('flex flex-col', {
'min-h-[calc(100vh-180px)] md:h-[calc(100vh-180px)]': erInternFlate,
'min-h-[calc(100vh-72px)] md:h-[calc(100vh-80px)]': !erInternFlate
'min-h-[calc(100vh-180px)] h-[calc(100vh-180px)]': erInternFlate,
'min-h-[calc(100vh-72px)] h-[calc(100vh-80px)]': !erInternFlate
})}
>
<Provider fnr={fnr} erVeileder={!!fnr}>
Expand Down
2 changes: 1 addition & 1 deletion src/view/aktivitet/DialogMedAktivitetHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export function DialogMedAktivitetHeader(props: Props) {
<div className="flex w-full flex-col md:flex-row">
<div className="flex flex-1 flex-row items-center gap-x-2 lg:max-w-lgContainer xl:max-w-none">
<TilbakeKnapp className="md:hidden" />
<div className="ml-4">
<div className="md:ml-4">
<Heading level="2" size="small" aria-label={`${typeTekst}: ${aktivitet?.tittel}`}>
{aktivitet?.tittel}
</Heading>
Expand Down
3 changes: 2 additions & 1 deletion src/view/aktivitet/InformasjonElement.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import React, { ReactNode } from 'react';

import EksternLenke from '../../felleskomponenter/EksternLenke';
import { StringOrNull } from '../../utils/Typer';
import { linkify } from '../melding/linkify';

interface TekstomradeProps {
merkelapptekst: string;
Expand All @@ -18,7 +19,7 @@ export default function InformasjonElement(props: TekstomradeProps) {

return (
<InformasjonElementRaw merkelapptekst={merkelapptekst}>
<span className="text-ellipsis overflow-hidden">{verdi}</span>
<span className="text-ellipsis overflow-hidden">{linkify(verdi)}</span>
</InformasjonElementRaw>
);
}
Expand Down
2 changes: 1 addition & 1 deletion src/view/dialogliste/DialogOversikt.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const DialogOversikt = () => {
<div
className={classNames(
{ hidden: !!dialog || isNyRoute } /* Hvis liten skjerm, bare vis dialog-liste på "Homepage" */,
'border-r border-border-divider w-full h-full md:max-w-80 md:flex md:flex-col xl:max-w-none xl:min-w-[320px] xl:w-[16.7vw]'
'flex flex-col border-r border-border-divider w-full h-full md:max-w-80 md:flex md:flex-col xl:max-w-none xl:min-w-[320px] xl:w-[16.7vw]'
)}
>
<DialogOversiktHeader erVeileder={erVeileder} />
Expand Down
4 changes: 3 additions & 1 deletion src/view/melding/Melding.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { PersonIcon } from '@navikt/aksel-icons';
import { BodyShort, Chat, Link } from '@navikt/ds-react';
import classNames from 'classnames';
import React from 'react';

import { ViktigMelding } from '../../felleskomponenter/etiketer/Etikett';
Expand Down Expand Up @@ -45,8 +46,9 @@ export function Melding(props: Props) {
position={erMeldingFraBruker ? 'right' : 'left'}
backgroundColor={backgroundColor}
avatarBgColor={avatarBgColor}
className={classNames('p-0', { 'md:pl-16': erMeldingFraBruker, 'md:pr-16': !erMeldingFraBruker })}
>
<Chat.Bubble>
<Chat.Bubble className="">
<div className="flex flex-col items-start">
<ViktigMelding visible={viktigMarkering} />
<span className="mt-2 whitespace-pre-wrap">{linkify(tekst)}</span>
Expand Down

0 comments on commit 526ffc0

Please sign in to comment.