Skip to content
Draft
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
101 commits
Select commit Hold shift + click to select a range
fde17a3
Update consent-banner.mdx
frankdahle Jun 2, 2026
e00db75
titles and lists
mrosvik Jun 2, 2026
090292f
code
mrosvik Jun 2, 2026
2545d44
Made the language more active
mrosvik Jun 2, 2026
b019564
added images and clearified placement together with skiplink
mrosvik Jun 2, 2026
2f1a1f0
add examples
mrosvik Jun 3, 2026
ae90197
improve alt texts, fix typos, add contributors
mrosvik Jun 3, 2026
bec0e26
add do dont examples
mrosvik Jun 3, 2026
6e68292
removed repetitions
mrosvik Jun 3, 2026
f8cb646
Merge branch 'main' into Cookie-banner
mrosvik Jun 3, 2026
db59a8d
examples
mrosvik Jun 3, 2026
6d0c139
Merge branch 'Cookie-banner' of https://github.com/digdir/designsyste…
mrosvik Jun 3, 2026
287c5dc
new image as suggested by @magnusrand
mrosvik Jun 3, 2026
1f98399
remove duplicated button
mrosvik Jun 3, 2026
4c61e10
add disclamer
mrosvik Jun 3, 2026
c696231
add disclamer and a new story
mrosvik Jun 3, 2026
6a844f0
Refine wording
mrosvik Jun 3, 2026
8dd4e72
move technology-neutral consent guidance earlier
mrosvik Jun 3, 2026
0116574
Removed unused link
mrosvik Jun 3, 2026
749d982
fix some sentences
mrosvik Jun 3, 2026
f3e4cd0
Feedback from @dortedrange
mrosvik Jun 4, 2026
f646825
changed the title since it is not only about how the website is used.
mrosvik Jun 4, 2026
6f16b99
removed duplicate sentence
mrosvik Jun 4, 2026
eb99a5b
new image for video
mrosvik Jun 4, 2026
452d6db
simplified the sentence for updating consent
mrosvik Jun 4, 2026
c7f0077
remove title
mrosvik Jun 4, 2026
96315a0
merged two paragraphs
mrosvik Jun 4, 2026
00385a8
shortened the preparations chapter.
mrosvik Jun 4, 2026
7a3e542
the article has not yet been translated into English
mrosvik Jun 4, 2026
c5c20d1
fix sentence
mrosvik Jun 4, 2026
1d759c1
combine paragraphs
mrosvik Jun 4, 2026
4946822
as suggested by @Febakke
mrosvik Jun 4, 2026
9fa7ed8
add space
mrosvik Jun 4, 2026
fdaf4b5
specify bottom at page
mrosvik Jun 4, 2026
12b0317
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
05aaa52
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
eecb68f
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
a7e85e1
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
8ee21fe
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
34ca493
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
d1b6b0a
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
2e2648d
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
369c35f
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
14a7123
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
9169ce4
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
8663510
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
ea4d49e
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
1f92199
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
5f4532c
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
d21105b
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
72ac458
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
30c762c
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
e5928f7
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
f473a57
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
fd1335f
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
18920d6
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
86af19e
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
dabfb88
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
262ce1a
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
80f97e0
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
814cab4
Update apps/www/app/content/patterns/no/consent-banner.mdx
mrosvik Jun 5, 2026
28f8dcb
Merge branch 'main' into Cookie-banner
mrosvik Jun 5, 2026
249884c
docs: move consent storage sections to Forberedelser (#4956)
magnusrand Jun 5, 2026
4aefdb5
use consistent second-person voice throughout article
mrosvik Jun 9, 2026
2f2f997
use a more active voice
mrosvik Jun 9, 2026
5d801c9
change start
mrosvik Jun 9, 2026
f3193a3
new video img
mrosvik Jun 9, 2026
5bd66de
video with image
mrosvik Jun 9, 2026
d4cb51a
fix sentence after comment from @Barsnes
mrosvik Jun 9, 2026
3badb79
comments from Marte Seth
mrosvik Jun 9, 2026
e4410f2
add do example
mrosvik Jun 9, 2026
8c80061
add do examples
mrosvik Jun 10, 2026
0edb8f4
simplify code example
mrosvik Jun 10, 2026
e428cd7
add aria-labelledby
mrosvik Jun 10, 2026
792ef9c
remove comments
mrosvik Jun 10, 2026
0636673
Merge branch 'main' into Cookie-banner
mrosvik Jun 10, 2026
1d925a9
add Fieldset to example
mrosvik Jun 10, 2026
58eee56
Merge branch 'Cookie-banner' of https://github.com/digdir/designsyste…
mrosvik Jun 10, 2026
bc00249
remove space
mrosvik Jun 10, 2026
bd4ddd1
add value necessary
mrosvik Jun 10, 2026
3a31efc
add avatars
mrosvik Jun 10, 2026
8cb1f3b
fix from @Camulos
mrosvik Jun 10, 2026
42ccd0b
suggestion from @mimarz
mrosvik Jun 10, 2026
022bdeb
remove unused class
mrosvik Jun 10, 2026
38b897a
add code example with checkboxes
mrosvik Jun 12, 2026
a2a1934
Merge branch 'main' into Cookie-banner
mrosvik Jun 12, 2026
066d5b0
Merge branch 'main' into Cookie-banner
mrosvik Jun 17, 2026
da7b631
comment 1 from nkom
mrosvik Jun 24, 2026
06a96ba
comment 3 from nkom
mrosvik Jun 24, 2026
46add1b
comment 4 from nkom
mrosvik Jun 24, 2026
0536e66
comment 5 from nkom
mrosvik Jun 24, 2026
5a03835
comment 6 from nkom
mrosvik Jun 24, 2026
e64713f
comment from datatilsynet
mrosvik Jun 24, 2026
70d8fa2
add info about personal data (comment from datatilsynet)
mrosvik Jun 24, 2026
d6e6c24
sharing consent across services
mrosvik Jun 24, 2026
4dd4a91
one question, one purpose
mrosvik Jun 24, 2026
a029493
add img text
mrosvik Jun 24, 2026
00a2a14
clarify consent guidance based on purpose and legal requirements
mrosvik Jun 24, 2026
c20b564
accept all requires a reject all button
mrosvik Jun 24, 2026
e8d208c
simplify sentence
mrosvik Jun 24, 2026
83e1fe4
video example
mrosvik Jun 26, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions apps/www/app/content/patterns/no/consent-banner.dodont.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import { Button, Paragraph } from '@digdir/designsystemet-react';

export const DontNegations = () => {
return (
<Paragraph>
Ønsker du at vi ikke skal lagre informasjon om deg og dine bruksmønstre?
</Paragraph>
);
};

export const DoNegations = () => {
return (
<Paragraph>Får vi samle informasjon om hvordan nettsiden brukes?</Paragraph>
);
};

export const DontButtons1 = () => {
return (
<>
<Button variant='primary'>Nei, jeg vil ikke ha en bedre tjeneste</Button>
<Button variant='primary'>Ja, jeg vil hjelpe til</Button>
<Button variant='primary'>Godta anbefalte</Button>
<Button variant='primary'>Bare nødvendige</Button>
<Button variant='primary'>OK</Button>
<Button variant='primary'>Jeg forstår</Button>
</>
);
};

export const DontButtons2 = () => {
return <Button variant='primary'>Godta bare nødvendige</Button>;
};
253 changes: 233 additions & 20 deletions apps/www/app/content/patterns/no/consent-banner.mdx

Large diffs are not rendered by default.

106 changes: 106 additions & 0 deletions apps/www/app/content/patterns/no/consent-banner.stories.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
import {
Button,
Heading,
Link,
Paragraph,
SkipLink,
} from '@digdir/designsystemet-react';

export const ConsentBanner = () => {
return (
<>
<section
aria-labelledby='samtykkebanner__tittel'
style={{
background: '#0062ba',
color: 'white',
padding: 'var(--ds-size-8) var(--ds-size-8)',
}}
>
<Heading
id='samtykkebanner__tittel'
data-size='md'
style={{ marginBottom: 'var(--ds-size-4)' }}
>
Får vi samle informasjon om hvordan nettsiden brukes?
</Heading>
<Paragraph
style={{
color: 'inherit',
fontSize: '1.25rem',
maxWidth: '68rem',
}}
>
Hvis du svarer ja, lagrer og analyserer vi informasjon som hjelper oss
å forbedre nettsiden. Du kan når som helst endre valget ditt nederst
på siden.{' '}
<Link href='#mer-om-hva-vi-lagrer' style={{ color: 'inherit' }}>
Mer om hva vi lagrer og hvorfor.
</Link>
</Paragraph>
<form
method='post'
action='/api/consent'
style={{
display: 'flex',
gap: 'var(--ds-size-4)',
marginTop: 'var(--ds-size-5)',
}}
>
<Button
className='consent-banner-button'
data-color='neutral'
data-size='md'
name='action'
type='submit'
value='all'
>
Ja
</Button>
<Button
className='consent-banner-button'
data-color='neutral'
data-size='md'
name='action'
type='submit'
value='required'
>
Nei
</Button>
</form>
<Paragraph
style={{
color: 'inherit',
fontSize: '1.125rem',
marginTop: 'var(--ds-size-8)',
}}
>
<Link href='#nodvendig-informasjon' style={{ color: 'inherit' }}>
Vi lagrer også nødvendig informasjon
</Link>{' '}
som ikke kan velges bort. Dette gjør at nettsiden fungerer og er
trygg.
</Paragraph>
</section>
<style>
{`
.consent-banner-button {
background-color: rgb(255 255 255 / 100%);
color: rgb(0 0 0 / 100%);
}

.consent-banner-button:hover {
background-color: rgb(255 255 255 / 70%);
}

.consent-banner-skip-link:focus {
width: 100%;
}
`}
</style>
<SkipLink className='consent-banner-skip-link' href='#main'>
Hopp til hovedinnhold
</SkipLink>
</>
);
};
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading