Skip to content

Commit aad462b

Browse files
committed
Some fix for Server components
1 parent 7af137b commit aad462b

File tree

3 files changed

+73
-1
lines changed

3 files changed

+73
-1
lines changed

src/Button.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ export namespace ButtonProps {
6666
};
6767
}
6868

69+
/** @see <https://react-dsfr-components.etalab.studio/?path=/docs/components-button> */
6970
export const Button = memo(
7071
forwardRef<HTMLButtonElement | HTMLAnchorElement, ButtonProps>((props, ref) => {
7172
const {

src/ButtonsGroup.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export namespace ButtonsGroupProps {
4747
};
4848
}
4949

50-
/** @see <https://react-dsfr-components.etalab.studio/?path=/docs/components-buttons-group> */
50+
/** @see <https://react-dsfr-components.etalab.studio/?path=/docs/components-buttonsgroup> */
5151
export const ButtonsGroup = memo(
5252
forwardRef<HTMLUListElement, ButtonsGroupProps>((props, ref) => {
5353
const {

test/integration/next-appdir/app/page.tsx

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,89 @@
11
import { ClientComponent } from "../shared/ClientComponent";
22
import { Alert } from "@codegouvfr/react-dsfr/Alert";
3+
import { Badge } from "@codegouvfr/react-dsfr/Badge";
4+
import { Card } from "@codegouvfr/react-dsfr/Card";
5+
import { Tabs } from "@codegouvfr/react-dsfr/Tabs";
6+
import { Summary } from "@codegouvfr/react-dsfr/Summary";
37

48
export default function Page() {
59

610
return (
711
<>
812
<h1>Hello World</h1>
13+
<Summary
14+
links={[
15+
{
16+
linkProps: {
17+
href: '#'
18+
},
19+
text: 'Titre de l’ancre'
20+
},
21+
{
22+
linkProps: {
23+
href: '#'
24+
},
25+
text: 'Titre de l’ancre'
26+
},
27+
{
28+
linkProps: {
29+
href: '#'
30+
},
31+
text: 'Titre de l’ancre'
32+
},
33+
{
34+
linkProps: {
35+
href: '#'
36+
},
37+
text: 'Titre de l’ancre'
38+
},
39+
{
40+
linkProps: {
41+
href: '#'
42+
},
43+
text: 'Titre de l’ancre'
44+
}
45+
]}
46+
/>
947
<ClientComponent />
1048
<Alert
1149
closable
1250
description="Everything went well"
1351
severity="success"
1452
title="Message successfully sent"
1553
/>
54+
<Badge
55+
label="Label badge"
56+
severity="success"
57+
/>
58+
<Card
59+
desc="Lorem ipsum dolor sit amet, consectetur adipiscing, incididunt, ut labore et dolore magna aliqua. Vitae sapien pellentesque habitant morbi tristique senectus et"
60+
enlargeLink
61+
imageAlt="texte alternatif de l’image"
62+
imageUrl="https://www.systeme-de-design.gouv.fr/img/placeholder.16x9.png"
63+
linkProps={{
64+
href: '#'
65+
}}
66+
title="Intitulé de la carte (sur lequel se trouve le lien)"
67+
/>
68+
<Tabs
69+
label="Name of the tabs system"
70+
tabs={[
71+
{
72+
content: <p>Content of tab1</p>,
73+
iconId: 'fr-icon-add-line',
74+
label: 'Tab 1'
75+
},
76+
{
77+
content: <p>Content of tab2</p>,
78+
iconId: 'fr-icon-ball-pen-fill',
79+
label: 'Tab 2'
80+
},
81+
{
82+
content: <p>Content of tab3</p>,
83+
label: 'Tab 3'
84+
}
85+
]}
86+
/>
1687
</>
1788
);
1889

0 commit comments

Comments
 (0)