forked from digdir/designsystemet
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'digdir:next' into next
- Loading branch information
Showing
176 changed files
with
9,844 additions
and
8,861 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
SkipLink: Add css variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
ValidationMessage: fix icon abandoning the component when scrolling |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
Accordion: Add css variable for chevron |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
Breadcrumbs: Add css variable for chevron |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
"@digdir/designsystemet-react": patch | ||
--- | ||
|
||
Input: Sufficient color contrast for readonly |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
Alert: fix icon abandoning the component when scrolling |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-react": patch | ||
--- | ||
|
||
Popover: Make sure arrow does not leave the popover |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-react": patch | ||
--- | ||
|
||
Modal: Fix `onClose` not being called |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
|
||
--- | ||
|
||
Tooltip: Add more variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
"@digdir/designsystemet-react": patch | ||
--- | ||
|
||
Field: Adds `<Field>` component wrapping and connecting internal form elements for better accessibility |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-react": patch | ||
--- | ||
|
||
Avatar: Fix `aria-hidden` being wrongly added to a fragment |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
Pagination: Add css variable for chevron |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
"@digdir/designsystemet-theme": minor | ||
"@digdir/designsystemet": minor | ||
"@digdir/designsystemet-css": minor | ||
--- | ||
|
||
Implemented a more flexible system of semantic border-radius tokens. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@digdir/designsystemet-css": patch | ||
--- | ||
|
||
Modal backdrop was invisible in some browser versions. See https://caniuse.com/mdn-css_selectors_backdrop_inherit_from_originating_element for affected versions. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
import { Button, Heading, Link, Paragraph } from '@digdir/designsystemet-react'; | ||
import cl from 'clsx/lite'; | ||
import Image from 'next/image'; | ||
import NextLink from 'next/link'; | ||
import { type ReactNode, forwardRef } from 'react'; | ||
import { Container } from '../'; | ||
|
||
import { Bronnoysund } from '../logos/Bronnoysund'; | ||
import { Digdir } from '../logos/Digdir'; | ||
import { Mattilsynet } from '../logos/Mattilsynet'; | ||
import { Udir } from '../logos/Udir'; | ||
import classes from './Footer.module.css'; | ||
|
||
type LinkListItemProps = { | ||
text: string; | ||
url: string; | ||
prefix?: ReactNode; | ||
}; | ||
|
||
const getCurrentYear = () => { | ||
const date = new Date(); | ||
return date.getFullYear(); | ||
}; | ||
|
||
const LinkList = (links: LinkListItemProps[]) => { | ||
return ( | ||
<ul className={classes.links}> | ||
{links.map((item, index) => ( | ||
<li key={index}> | ||
<Link href={item.url} color='neutral' className={classes.link}> | ||
{item.prefix} | ||
{item.text} | ||
</Link> | ||
</li> | ||
))} | ||
</ul> | ||
); | ||
}; | ||
|
||
type FooterProps = { | ||
centerLinks: LinkListItemProps[]; | ||
rightLinks: LinkListItemProps[]; | ||
} & React.HTMLAttributes<HTMLElement>; | ||
|
||
export const Footer = forwardRef<HTMLElement, FooterProps>(function Footer( | ||
{ centerLinks, rightLinks, className, ...rest }, | ||
ref, | ||
) { | ||
return ( | ||
<footer | ||
ref={ref} | ||
className={cl(classes.footer, className)} | ||
data-ds-color-mode='dark' | ||
{...rest} | ||
> | ||
<div className={classes.top}> | ||
<Container className={classes.container}> | ||
<div> | ||
<Heading size='xs' level={2} className={classes.title}> | ||
Lages på tvers av offentlige etater: | ||
</Heading> | ||
<div className={classes.logos}> | ||
<Digdir /> | ||
<Bronnoysund /> | ||
<Mattilsynet /> | ||
<Udir className={classes.udir} /> | ||
</div> | ||
<Button asChild variant='secondary' color='neutral' size='sm'> | ||
<NextLink | ||
href='mailto:[email protected]' | ||
className={classes.button} | ||
> | ||
Din etat? Ta kontakt! | ||
</NextLink> | ||
</Button> | ||
</div> | ||
<div> | ||
<Heading size='xs' level={2} className={classes.title}> | ||
Om nettstedet | ||
</Heading> | ||
{LinkList(centerLinks)} | ||
</div> | ||
<div> | ||
<Heading size='xs' level={2} className={classes.title}> | ||
Kom i kontakt med oss | ||
</Heading> | ||
{LinkList(rightLinks)} | ||
</div> | ||
</Container> | ||
</div> | ||
<div className={classes.bottom}> | ||
<Container> | ||
<Paragraph size='sm'>© {getCurrentYear()} Designsystemet</Paragraph> | ||
</Container> | ||
</div> | ||
</footer> | ||
); | ||
}); |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.