Skip to content

Commit 6c53b62

Browse files
committed
feat(ep): add StructureIdentity component to display structure ID
1 parent 9f0abe9 commit 6c53b62

2 files changed

Lines changed: 25 additions & 0 deletions

File tree

client/src/boards/european-projects/pages/horizon-europe/components/TabsContent.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import PositionnementContent from "./tabs/PositionnementContent";
66
import CollaborationsContent from "./tabs/CollaborationsContent";
77
import CheckEICAccelerator from "../../../components/check-eic-accelerator";
88
import EntitiesContent from "./tabs/EntitiesContent";
9+
import StructureIdentity from "./structure-identity";
910

1011
export default function TabsContent() {
1112
const [searchParams, setSearchParams] = useSearchParams();
@@ -27,6 +28,7 @@ export default function TabsContent() {
2728
return (
2829
<div>
2930
<CheckEICAccelerator />
31+
<StructureIdentity />
3032
<nav className="fr-nav" role="navigation" aria-label="Menu principal">
3133
<ul className="fr-nav__list">
3234
<li className="fr-nav__item">
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { useSearchParams } from "react-router-dom";
2+
import { Container, Row, Col } from "@dataesr/dsfr-plus";
3+
4+
export default function StructureIdentity() {
5+
const [searchParams] = useSearchParams();
6+
const currentLang = searchParams.get("language") || "en";
7+
const structureId = searchParams.get("structureid");
8+
9+
if (!structureId) {
10+
return null;
11+
}
12+
13+
return (
14+
<Container fluid>
15+
<Row>
16+
<Col>
17+
{currentLang === "fr" ? "id de la structure : " : "structure id: "}
18+
{structureId}
19+
</Col>
20+
</Row>
21+
</Container>
22+
);
23+
}

0 commit comments

Comments
 (0)