Skip to content

Commit 826b407

Browse files
authored
Merge pull request #2357 from navikt/contact-step-page
Contact step page
2 parents 1921893 + 70e9480 commit 826b407

File tree

11 files changed

+217
-0
lines changed

11 files changed

+217
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
// WARNING: This file was automatically generated by "no.item.xp.codegen". You may lose your changes if you edit it.
2+
export type ContactStepPage = {
3+
/**
4+
* Sett side-tittel
5+
*/
6+
title?: string;
7+
8+
/**
9+
* Tittel for utlisting og sortering
10+
*/
11+
sortTitle?: string;
12+
13+
/**
14+
* Norsk tittel (hvis fremmedspråklig innhold)
15+
*/
16+
norwegianTitle?: string;
17+
18+
/**
19+
* Tekst over tittel
20+
*/
21+
textAboveTitle?: string;
22+
23+
/**
24+
* Velg piktogram
25+
*/
26+
illustration: string;
27+
28+
/**
29+
* Ingress
30+
*/
31+
html?: string;
32+
33+
/**
34+
* Må begynne med '/start/[målgruppe dersom ikke privatperson]'
35+
*/
36+
customPath: string;
37+
38+
/**
39+
* Overskrift
40+
*/
41+
linkPanelsHeading?: string;
42+
43+
/**
44+
* Undertittel
45+
*/
46+
linkPanelsSubHeading?: string;
47+
48+
49+
linkPanels: Array<{
50+
/**
51+
* Innhold det skal lenkes til
52+
*/
53+
target: string;
54+
55+
/**
56+
* Lenketekst (hvis tom vil tittel på innholdet vises)
57+
*/
58+
text?: string;
59+
60+
/**
61+
* Ingress
62+
*/
63+
ingress?: string;
64+
}>;
65+
66+
/**
67+
* Tilbakelenke
68+
*/
69+
backLink: {
70+
/**
71+
* Innhold det skal lenkes til
72+
*/
73+
target: string;
74+
75+
/**
76+
* Lenketekst (hvis tom vil tittel på innholdet vises)
77+
*/
78+
text?: string;
79+
};
80+
};

.xp-codegen/site/content-types/index.d.ts

+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export type Calculator = import("./calculator").Calculator;
88
export type Cms2xp_page = import("./cms2xp_page").Cms2xp_page;
99
export type Cms2xp_section = import("./cms2xp_section").Cms2xp_section;
1010
export type ContactInformation = import("./contact-information").ContactInformation;
11+
export type ContactStepPage = import("./contact-step-page").ContactStepPage;
1112
export type ContentDataLocaleFallback = import("./content-data-locale-fallback").ContentDataLocaleFallback;
1213
export type ContentList = import("./content-list").ContentList;
1314
export type ContentPageWithSidemenus = import("./content-page-with-sidemenus").ContentPageWithSidemenus;
@@ -66,6 +67,7 @@ declare global {
6667
"no.nav.navno:cms2xp_page": Cms2xp_page;
6768
"no.nav.navno:cms2xp_section": Cms2xp_section;
6869
"no.nav.navno:contact-information": ContactInformation;
70+
"no.nav.navno:contact-step-page": ContactStepPage;
6971
"no.nav.navno:content-data-locale-fallback": ContentDataLocaleFallback;
7072
"no.nav.navno:content-list": ContentList;
7173
"no.nav.navno:content-page-with-sidemenus": ContentPageWithSidemenus;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// WARNING: This file was automatically generated by "no.item.xp.codegen". You may lose your changes if you edit it.
2+
export type HtmlArea = {
3+
/**
4+
* Ingress
5+
*/
6+
html?: string;
7+
};

.xp-codegen/site/mixins/index.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ export type FormDetailsSelector = import("./form-details-selector").FormDetailsS
1919
export type FormIntermediateStepData = import("./form-intermediate-step-data").FormIntermediateStepData;
2020
export type FormIntermediateStepDataAction = import("./form-intermediate-step-data-action").FormIntermediateStepDataAction;
2121
export type HeaderWithAnchor = import("./header-with-anchor").HeaderWithAnchor;
22+
export type HtmlArea = import("./html-area").HtmlArea;
2223
export type IconSelector = import("./icon-selector").IconSelector;
2324
export type Illustration = import("./illustration").Illustration;
2425
export type Ingress = import("./ingress").Ingress;

src/main/resources/lib/contenttype-lists.ts

+1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export const dynamicPageContentTypes = [
3232
`${APP_DESCRIPTOR}:area-page`,
3333
`${APP_DESCRIPTOR}:press-landing-page`,
3434
`${APP_DESCRIPTOR}:forms-overview`,
35+
`${APP_DESCRIPTOR}:contact-step-page`,
3536
] as const satisfies ContentTypeList;
3637

3738
export const linkContentTypes = [
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#import "../fragments/contentCommonWithPageFragment.graphql"
2+
#import "../fragments/content-types/contactStepPageFragment.graphql"
3+
4+
query contactStepPageQuery($ref: ID!) {
5+
guillotine {
6+
get(key: $ref) {
7+
...contentCommonWithPage
8+
...contactStepPage
9+
}
10+
}
11+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#import "../mixins/animatedIconsTargetFragment.graphql"
2+
#import "../mixins/internalLinkTargetFragment.graphql"
3+
#import "../contentCommonFragment.graphql"
4+
#import "../richText/richTextFragment.graphql"
5+
6+
fragment contactStepPage on no_nav_navno_ContactStepPage {
7+
dataAsJson
8+
data {
9+
illustration {
10+
...animatedIconsTargetMixin
11+
}
12+
linkPanels {
13+
target {
14+
...internalLinkTargetMixin
15+
}
16+
text
17+
ingress
18+
}
19+
backLink {
20+
target {
21+
...internalLinkTargetMixin
22+
}
23+
text
24+
}
25+
html(processHtml: { type: server }) {
26+
...richText
27+
}
28+
}
29+
}

src/main/resources/lib/guillotine/queries/run-content-query.ts

+2
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import areaPageQuery from './content-queries/areaPageQuery.graphql';
3030
import contactInformationQuery from './content-queries/contactInformationQuery.graphql';
3131
import calculatorQuery from './content-queries/calculatorQuery.graphql';
3232
import contentPageWithSidemenusQuery from './content-queries/contentPageWithSidemenusQuery.graphql';
33+
import contactStepPageQuery from './content-queries/contactStepPageQuery.graphql';
3334
import dynamicPageQuery from './content-queries/dynamicPageQuery.graphql';
3435
import externalLinkQuery from './content-queries/externalLinkQuery.graphql';
3536
import frontPageQuery from './content-queries/frontPageQuery.graphql';
@@ -86,6 +87,7 @@ export const graphQlContentQueries: { [type in ContentDescriptor]?: string } = {
8687
'no.nav.navno:area-page': areaPageQuery,
8788
'no.nav.navno:calculator': calculatorQuery,
8889
'no.nav.navno:contact-information': contactInformationQuery,
90+
'no.nav.navno:contact-step-page': contactStepPageQuery,
8991
'no.nav.navno:content-page-with-sidemenus': contentPageWithSidemenusQuery,
9092
'no.nav.navno:product-details': productDetailsQuery,
9193
'no.nav.navno:form-details': formDetailsQuery,
Loading
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
<content-type>
2+
<display-name>Mellomsteg for kontaktside</display-name>
3+
<super-type>base:structured</super-type>
4+
<is-abstract>false</is-abstract>
5+
<is-final>true</is-final>
6+
<form>
7+
<field-set>
8+
<label>Tittel og ingress</label>
9+
<items>
10+
<mixin name="page-header" />
11+
<input type="TextLine" name="textAboveTitle">
12+
<label>Tekst over tittel</label>
13+
<occurrences minimum="0" maximum="1" />
14+
</input>
15+
<mixin name="illustration" />
16+
<mixin name="html-area" />
17+
</items>
18+
</field-set>
19+
<field-set>
20+
<label>Kort-url</label>
21+
<items>
22+
<input name="customPath" type="CustomSelector">
23+
<label>Må begynne med '/start/[målgruppe dersom ikke privatperson]'</label>
24+
<occurrences minimum="1" maximum="1" />
25+
<config>
26+
<service>customPathSelector</service>
27+
</config>
28+
</input>
29+
</items>
30+
</field-set>
31+
<field-set>
32+
<label>Lenker</label>
33+
<items>
34+
<input name="linkPanelsHeading" type="TextLine">
35+
<label>Overskrift</label>
36+
<occurrences minimum="0" maximum="1" />
37+
</input>
38+
<input name="linkPanelsSubHeading" type="TextLine">
39+
<label>Undertittel</label>
40+
<occurrences minimum="0" maximum="1" />
41+
</input>
42+
<item-set name="linkPanels">
43+
<occurrences minimum="1" maximum="0" />
44+
<items>
45+
<mixin name="link-internal" />
46+
<input type="TextArea" name="ingress">
47+
<label>Ingress</label>
48+
<occurrences minimum="0" maximum="1" />
49+
</input>
50+
</items>
51+
</item-set>
52+
</items>
53+
</field-set>
54+
<field-set>
55+
<label>Tilbakelenke</label>
56+
<items>
57+
<item-set name="backLink">
58+
<label>Tilbakelenke</label>
59+
<occurrences minimum="1" maximum="1" />
60+
<items>
61+
<mixin name="link-internal" />
62+
</items>
63+
</item-set>
64+
</items>
65+
</field-set>
66+
</form>
67+
</content-type>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<mixin>
2+
<display-name>Html Area</display-name>
3+
<form>
4+
<input name="html" type="HtmlArea">
5+
<label>Ingress</label>
6+
<occurrences minimum="0" maximum="1"/>
7+
<config>
8+
<service>htmlFragmentSelector</service>
9+
<include>Undo Redo Bold</include>
10+
<exclude>JustifyBlock JustifyLeft JustifyCenter JustifyRight Outdent Indent
11+
Anchor Table
12+
</exclude>
13+
<allowHeadings>normal h2 h3 h4</allowHeadings>
14+
</config>
15+
</input>
16+
</form>
17+
</mixin>

0 commit comments

Comments
 (0)