+ {social.providers
+ .map((p, index) => {
+ if (p.providerId === "agentconnect" || p.providerId === "proconnect") {
+ return
;
+ }
- if (p.providerId === "franceconnect") {
- return
;
- }
+ if (franceConnectProviderIds.includes(p.providerId)) {
+ if (index !== 0) {
+ throw new Error('Le bouton FranceConnect doit être le premier bouton de connexion');
+ }
+ return (
+ <>
+
+ FranceConnect est la solution proposée par l’État pour sécuriser et simplifier la connexion à
+ vos services en ligne.
+
+
+ >
+ );
+ }
- return (
-
- );
- })}
-
+ return (
+
+
+
+ );
+ })
+ .map((value, index) => {
+ if (index >= 1 && franceConnectProviderIds.includes(social.providers?.[0].providerId ?? '')) {
+ return (
+ <>
+
OU
+ {value}
+ >
+ );
+ }
+ return value;
+ })}
+
)}
>
@@ -103,7 +132,7 @@ export default function Login(props: PageProps