diff --git a/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/classes.module.scss b/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/classes.module.scss
index 5c8539d8..76b11e55 100644
--- a/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/classes.module.scss
+++ b/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/classes.module.scss
@@ -3,14 +3,18 @@
.root {
display: flex;
flex-direction: column;
- width: 472px;
+ width: 566px;
margin: auto;
margin-top: 24px;
gap: var(--spacing-xl, 32px);
- @media (max-width: 504px) {
- width: unset;
- margin: 24px 16px;
+ @media (max-width: $screen-m) {
+ width: 474px;
+ }
+
+ @media (max-width: $screen-s) {
+ width: 100%;
+ padding: var(--spacing-md, 16px);
}
.form {
diff --git a/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/index.tsx b/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/index.tsx
index de94f5c0..c095612b 100644
--- a/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/index.tsx
+++ b/src/front/Components/Layouts/Folder/UpdateFolderCollaborators/index.tsx
@@ -1,22 +1,22 @@
+import backgroundImage from "@Assets/images/background_refonte.svg";
import Folders from "@Front/Api/LeCoffreApi/Notary/Folders/Folders";
import Users, { IGetUsersParams } from "@Front/Api/LeCoffreApi/Notary/Users/Users";
import Button, { EButtonstyletype, EButtonVariant } from "@Front/Components/DesignSystem/Button";
+import { IOption } from "@Front/Components/DesignSystem/Dropdown/DropdownMenu/DropdownOption";
import Form from "@Front/Components/DesignSystem/Form";
-import { IOption } from "@Front/Components/DesignSystem/Form/SelectField";
-import MultiSelect from "@Front/Components/DesignSystem/MultiSelect";
+import AutocompleteMultiSelectField from "@Front/Components/DesignSystem/Form/AutocompleteMultiSelectField";
import RadioBox from "@Front/Components/DesignSystem/RadioBox";
import Typography, { ETypo } from "@Front/Components/DesignSystem/Typography";
import BackArrow from "@Front/Components/Elements/BackArrow";
+import DefaultDoubleSidePage from "@Front/Components/LayoutTemplates/DefaultDoubleSidePage";
import Module from "@Front/Config/Module";
+import { ValidationError } from "class-validator";
import User from "le-coffre-resources/dist/Notary/User";
import Link from "next/link";
import { useRouter } from "next/router";
+import { useCallback, useEffect, useState } from "react";
import classes from "./classes.module.scss";
-import { ValidationError } from "class-validator";
-import backgroundImage from "@Assets/images/background_refonte.svg";
-import DefaultDoubleSidePage from "@Front/Components/LayoutTemplates/DefaultDoubleSidePage";
-import { useCallback, useEffect, useState } from "react";
enum ERadioBoxValue {
ALL = "all",
@@ -26,9 +26,8 @@ enum ERadioBoxValue {
export default function UpdateFolderCollaborators() {
const router = useRouter();
let { folderUid } = router.query;
-
const [availableCollaborators, setAvailableCollaborators] = useState([]);
- const [selectedCollaborators, setSelectedCollaborators] = useState([]);
+ const [selectedCollaborators, setSelectedCollaborators] = useState([]);
const [defaultCheckedAllOffice, setDefaultCheckedAllOffice] = useState(false);
const [selectedOption, setSelectedOption] = useState(ERadioBoxValue.SELECTION);
const [loading, setLoading] = useState(true);
@@ -40,9 +39,7 @@ export default function UpdateFolderCollaborators() {
try {
let collaboratorsUid: User[] = availableCollaborators;
if (selectedOption === ERadioBoxValue.SELECTION) {
- collaboratorsUid = selectedCollaborators.map((collaborator) =>
- User.hydrate({ uid: collaborator.value as string }),
- );
+ collaboratorsUid = selectedCollaborators.map((collaborator) => User.hydrate({ uid: collaborator.id as string }));
}
await Folders.getInstance().put(folderUid, { stakeholders: collaboratorsUid });
router.push(
@@ -61,8 +58,8 @@ export default function UpdateFolderCollaborators() {
setSelectedOption(ERadioBoxValue.ALL);
}, []);
- const onChangeSelectedCollaborators = useCallback((selectedCollaborators: readonly IOption[]) => {
- setSelectedCollaborators(selectedCollaborators);
+ const onChangeSelectedCollaborators = useCallback((selectedCollaborators: IOption[] | null) => {
+ selectedCollaborators && setSelectedCollaborators(selectedCollaborators);
}, []);
const onSelectedOptionSpecific = useCallback((event: React.ChangeEvent) => {
@@ -89,7 +86,7 @@ export default function UpdateFolderCollaborators() {
const preSelectedCollaborators: IOption[] = folder.stakeholders!.map((collaborator) => {
return {
label: collaborator.contact?.first_name + " " + collaborator.contact?.last_name,
- value: collaborator.uid,
+ id: collaborator.uid ?? "",
};
});
@@ -129,7 +126,7 @@ export default function UpdateFolderCollaborators() {
const selectOptions: IOption[] = availableCollaborators.map((collaborator) => {
return {
label: collaborator.contact?.first_name + " " + collaborator.contact?.last_name,
- value: collaborator.uid,
+ id: collaborator.uid ?? "",
};
});
@@ -148,25 +145,23 @@ export default function UpdateFolderCollaborators() {
name="office"
value={ERadioBoxValue.ALL}
defaultChecked={defaultCheckedAllOffice}
- onChange={onSelectedOptionAllOffice}>
- Tout l'office
-
+ onChange={onSelectedOptionAllOffice}
+ label="Tout l'office">
- Sélectionner des collaborateurs
-
+ onChange={onSelectedOptionSpecific}
+ label="Sélectionner des collaborateurs">
{selectedOption === ERadioBoxValue.SELECTION && (
- error.property === "stakeholders")}
/>
diff --git a/src/front/Components/Layouts/Folder/UpdateFolderMetadata/classes.module.scss b/src/front/Components/Layouts/Folder/UpdateFolderMetadata/classes.module.scss
index 57f936d6..8f7fa6b5 100644
--- a/src/front/Components/Layouts/Folder/UpdateFolderMetadata/classes.module.scss
+++ b/src/front/Components/Layouts/Folder/UpdateFolderMetadata/classes.module.scss
@@ -4,9 +4,19 @@
display: flex;
flex-direction: column;
gap: var(--spacing-xl, 32px);
- width: 472px;
+ width: 566px;
margin: auto;
margin: 24px auto;
+
+ @media (max-width: $screen-m) {
+ width: 474px;
+ }
+
+ @media (max-width: $screen-s) {
+ width: 100%;
+ padding: var(--spacing-md, 16px);
+ }
+
.form {
.content {
display: flex;
diff --git a/src/front/Components/Layouts/Folder/UpdateFolderMetadata/index.tsx b/src/front/Components/Layouts/Folder/UpdateFolderMetadata/index.tsx
index 76470291..38299062 100644
--- a/src/front/Components/Layouts/Folder/UpdateFolderMetadata/index.tsx
+++ b/src/front/Components/Layouts/Folder/UpdateFolderMetadata/index.tsx
@@ -1,7 +1,7 @@
import Folders from "@Front/Api/LeCoffreApi/Notary/Folders/Folders";
import Button, { EButtonstyletype, EButtonVariant } from "@Front/Components/DesignSystem/Button";
import Form from "@Front/Components/DesignSystem/Form";
-import Select, { IOption } from "@Front/Components/DesignSystem/Form/SelectField";
+import Select, { IOptionOld } from "@Front/Components/DesignSystem/Form/SelectFieldOld";
import TextField from "@Front/Components/DesignSystem/Form/TextField";
import Typography, { ETypo } from "@Front/Components/DesignSystem/Typography";
import BackArrow from "@Front/Components/Elements/BackArrow";
@@ -81,7 +81,7 @@ export default function UpdateFolderMetadata() {
const deedOption = {
label: selectedFolder?.deed?.deed_type?.name,
value: selectedFolder?.deed?.deed_type?.uid,
- } as IOption;
+ } as IOptionOld;
const openingDate = new Date(selectedFolder?.created_at ?? "");
if (!selectedFolder?.created_at) return <>>;
const defaultValue = openingDate.toISOString().split("T")[0];
diff --git a/src/front/Components/Layouts/Folder/index.tsx b/src/front/Components/Layouts/Folder/index.tsx
index d4d5da21..fdcda8f0 100644
--- a/src/front/Components/Layouts/Folder/index.tsx
+++ b/src/front/Components/Layouts/Folder/index.tsx
@@ -1,4 +1,3 @@
-import backgroundImage from "@Assets/images/background_refonte_reverse.svg";
import LogoIcon from "@Assets/logo_small_blue.svg";
import Users from "@Front/Api/LeCoffreApi/Notary/Users/Users";
import Button, { EButtonSize, EButtonstyletype, EButtonVariant } from "@Front/Components/DesignSystem/Button";
@@ -7,10 +6,10 @@ import DefaultNotaryDashboard from "@Front/Components/LayoutTemplates/DefaultNot
import Module from "@Front/Config/Module";
import JwtService from "@Front/Services/JwtService/JwtService";
import { DocumentIcon } from "@heroicons/react/24/outline";
-import User, { OfficeFolder } from "le-coffre-resources/dist/Notary";
+import User from "le-coffre-resources/dist/Notary";
import Image from "next/image";
import Link from "next/link";
-import { useCallback, useEffect, useState } from "react";
+import { useEffect, useState } from "react";
import classes from "./classes.module.scss";
import Folders from "@Front/Api/LeCoffreApi/Notary/Folders/Folders";
@@ -18,14 +17,10 @@ import EFolderStatus from "le-coffre-resources/dist/Customer/EFolderStatus";
import { useRouter } from "next/router";
export default function Folder() {
- const [_folder, setFolder] = useState
(null);
const [_isArchivedModalOpen, _setIsArchivedModalOpen] = useState(true);
const router = useRouter();
const [activeUser, setActiveUser] = useState();
- const onSelectedFolder = useCallback((folder: OfficeFolder): void => {
- setFolder(folder);
- }, []);
useEffect(() => {
const decodedJwt = JwtService.getInstance().decodeJwt();
@@ -60,11 +55,7 @@ export default function Folder() {
}, [router]);
return (
-
+
diff --git a/src/front/Components/Layouts/FolderArchived/UpdateFolderMetadata/index.tsx b/src/front/Components/Layouts/FolderArchived/UpdateFolderMetadata/index.tsx
index a8ac0db5..fc3708bb 100644
--- a/src/front/Components/Layouts/FolderArchived/UpdateFolderMetadata/index.tsx
+++ b/src/front/Components/Layouts/FolderArchived/UpdateFolderMetadata/index.tsx
@@ -1,6 +1,6 @@
import Button, { EButtonstyletype, EButtonVariant } from "@Front/Components/DesignSystem/Button";
import Form from "@Front/Components/DesignSystem/Form";
-import Select, { IOption } from "@Front/Components/DesignSystem/Form/SelectField";
+import Select, { IOptionOld } from "@Front/Components/DesignSystem/Form/SelectFieldOld";
import TextField from "@Front/Components/DesignSystem/Form/TextField";
import Typography, { ETypo } from "@Front/Components/DesignSystem/Typography";
import BackArrow from "@Front/Components/Elements/BackArrow";
@@ -18,7 +18,7 @@ type IProps = {
};
type IState = {
selectedFolder: OfficeFolder | null;
- selectedOption?: IOption;
+ selectedOption?: IOptionOld;
};
class UpdateFolderMetadataClass extends BasePage
{
constructor(props: IProps) {
@@ -39,7 +39,7 @@ class UpdateFolderMetadataClass extends BasePage {
.get()
.modules.pages.Folder.pages.FolderInformation.props.path.replace("[folderUid]", this.props.selectedFolderUid);
return (
-
+
@@ -74,7 +74,7 @@ class UpdateFolderMetadataClass extends BasePage
{
);
}
- private onSelectedOption(option: IOption) {
+ private onSelectedOption(option: IOptionOld) {
this.setState({
selectedOption: option,
});
diff --git a/src/front/Components/Layouts/FolderArchived/index.tsx b/src/front/Components/Layouts/FolderArchived/index.tsx
index 748e2001..2ee150f2 100644
--- a/src/front/Components/Layouts/FolderArchived/index.tsx
+++ b/src/front/Components/Layouts/FolderArchived/index.tsx
@@ -23,11 +23,7 @@ export default class FolderArchived extends BasePage {
// TODO: Message if the user has not created any folder yet
public override render(): JSX.Element {
return (
-
+
Informations du dossier
diff --git a/src/front/Components/Layouts/Legal/LegalInformations/classes.module.scss b/src/front/Components/Layouts/Legal/LegalInformations/classes.module.scss
new file mode 100644
index 00000000..351451a0
--- /dev/null
+++ b/src/front/Components/Layouts/Legal/LegalInformations/classes.module.scss
@@ -0,0 +1,11 @@
+.pdf-viewer {
+ width: 100%;
+ height: 100%;
+ min-height: 100%;
+ min-width: 100%;
+
+ .no-pdf-text {
+ padding: 16px;
+ text-align: center;
+ }
+}
diff --git a/src/front/Components/Layouts/Legal/LegalInformations/index.tsx b/src/front/Components/Layouts/Legal/LegalInformations/index.tsx
new file mode 100644
index 00000000..b7a6d200
--- /dev/null
+++ b/src/front/Components/Layouts/Legal/LegalInformations/index.tsx
@@ -0,0 +1,34 @@
+import { useRouter } from "next/router";
+import React from "react";
+import classes from "./classes.module.scss";
+import DefaultLegalDashboard, { ELegalOptions } from "@Front/Components/LayoutTemplates/DefaultLegalDashboard";
+import Typography, { ETypo, ETypoColor } from "@Front/Components/DesignSystem/Typography";
+import Link from "next/link";
+
+const pdfLinks: Record
= {
+ "mentions-legales": "https://s3.fr-par.scw.cloud/lecoffre.io-bucket/footer/mentions_legales.pdf",
+ "politique-de-confidentialite": "https://s3.fr-par.scw.cloud/lecoffre.io-bucket/footer/politique_confidentialite.pdf",
+ "politique-de-gestion-des-cookies": "https://s3.fr-par.scw.cloud/lecoffre.io-bucket/footer/politique_cookies.pdf",
+ cgs: "https://s3.fr-par.scw.cloud/lecoffre.io-bucket/footer/cgs.pdf",
+ cgu: "https://s3.fr-par.scw.cloud/lecoffre.io-bucket/footer/cgu.pdf",
+};
+
+export default function LegalInformations() {
+ const router = useRouter();
+ let { legalUid } = router.query;
+ const legalUidTyped = legalUid as ELegalOptions;
+ return (
+
+
+
+ );
+}
diff --git a/src/front/Components/Layouts/Legal/index.tsx b/src/front/Components/Layouts/Legal/index.tsx
new file mode 100644
index 00000000..f2b9961b
--- /dev/null
+++ b/src/front/Components/Layouts/Legal/index.tsx
@@ -0,0 +1,23 @@
+import DefaultLegalDashboard, { ELegalOptions } from "@Front/Components/LayoutTemplates/DefaultLegalDashboard";
+import { useRouter } from "next/router";
+import Module from "@Front/Config/Module";
+import { useEffect } from "react";
+
+type IProps = {};
+
+export default function Legal(props: IProps) {
+ const router = useRouter();
+ const { legalUid } = router.query;
+
+ useEffect(() => {
+ if (!legalUid && router.isReady) {
+ router.push(
+ Module.getInstance()
+ .get()
+ .modules.pages.Legal.pages.LegalInformations.props.path.replace("[legalUid]", ELegalOptions.LEGAL_MENTIONS),
+ );
+ }
+ }, [legalUid, router]);
+
+ return ;
+}
diff --git a/src/front/Components/Layouts/Login/StepEmail/classes.module.scss b/src/front/Components/Layouts/Login/StepEmail/classes.module.scss
index 2826c0af..aa8fe60f 100644
--- a/src/front/Components/Layouts/Login/StepEmail/classes.module.scss
+++ b/src/front/Components/Layouts/Login/StepEmail/classes.module.scss
@@ -1,11 +1,22 @@
+@import "@Themes/constants.scss";
+
.root {
- width: 472px;
+ width: 566px;
margin: auto;
margin-top: 80px;
display: flex;
flex-direction: column;
gap: var(--spacing-xl, 32px);
+ @media (max-width: $screen-m) {
+ width: 474px;
+ }
+
+ @media (max-width: $screen-s) {
+ width: 100%;
+ padding: var(--spacing-md, 16px);
+ }
+
.header {
display: flex;
flex-direction: column;
diff --git a/src/front/Components/Layouts/LoginCallback/index.tsx b/src/front/Components/Layouts/LoginCallback/index.tsx
index a488e4aa..8011f092 100644
--- a/src/front/Components/Layouts/LoginCallback/index.tsx
+++ b/src/front/Components/Layouts/LoginCallback/index.tsx
@@ -1,6 +1,6 @@
import LandingImage from "../Login/landing-connect.jpeg";
import Image from "next/image";
-import CoffreIcon from "@Assets/Icons/coffre.svg";
+import CoffreIcon from "@Assets/logo_small_blue.svg";
import { useRouter } from "next/router";
import React, { useEffect } from "react";
import classes from "./classes.module.scss";
diff --git a/src/front/Components/Layouts/LoginCallbackCustomer/index.tsx b/src/front/Components/Layouts/LoginCallbackCustomer/index.tsx
index f2420f9b..ce0539f1 100644
--- a/src/front/Components/Layouts/LoginCallbackCustomer/index.tsx
+++ b/src/front/Components/Layouts/LoginCallbackCustomer/index.tsx
@@ -1,6 +1,6 @@
import LandingImage from "../Login/landing-connect.jpeg";
import Image from "next/image";
-import CoffreIcon from "@Assets/Icons/coffre.svg";
+import CoffreIcon from "@Assets/logo_small_blue.svg";
import { useRouter } from "next/router";
import React, { useEffect } from "react";
import classes from "./classes.module.scss";
diff --git a/src/front/Components/Layouts/Offices/OfficeInformations/index.tsx b/src/front/Components/Layouts/Offices/OfficeInformations/index.tsx
index f6e8b91e..2a761172 100644
--- a/src/front/Components/Layouts/Offices/OfficeInformations/index.tsx
+++ b/src/front/Components/Layouts/Offices/OfficeInformations/index.tsx
@@ -117,7 +117,7 @@ export default function OfficeInformations(props: IProps) {
);
return (
-
+
Office {officeSelected?.crpcen + " - " + officeSelected?.name}
diff --git a/src/front/Components/Layouts/Offices/index.tsx b/src/front/Components/Layouts/Offices/index.tsx
index bded3736..5c060f27 100644
--- a/src/front/Components/Layouts/Offices/index.tsx
+++ b/src/front/Components/Layouts/Offices/index.tsx
@@ -9,7 +9,7 @@ type IState = {};
export default class Offices extends BasePage
{
public override render(): JSX.Element {
return (
-
+
Informations des offices
diff --git a/src/front/Components/Layouts/Subscription/Components/SubscribeCheckoutTicket/index.tsx b/src/front/Components/Layouts/Subscription/Components/SubscribeCheckoutTicket/index.tsx
index 0c45cad1..6b775bbc 100644
--- a/src/front/Components/Layouts/Subscription/Components/SubscribeCheckoutTicket/index.tsx
+++ b/src/front/Components/Layouts/Subscription/Components/SubscribeCheckoutTicket/index.tsx
@@ -83,17 +83,15 @@ export default function SubscribeCheckoutTicket(props: IProps) {
value={EPaymentFrequencyFront.yearly.toString()}
onChange={handleFrequencyChange}
defaultChecked={paymentFrequency === EPaymentFrequencyFront.yearly}
- disabled={props.disableInputs}>
- Annuel
-
+ disabled={props.disableInputs}
+ label="Annuel">
- Mensuel
-
+ disabled={props.disableInputs}
+ label="Mensuel">
diff --git a/src/front/Components/Layouts/Subscription/Components/SubscribeIllimityComponent/index.tsx b/src/front/Components/Layouts/Subscription/Components/SubscribeIllimityComponent/index.tsx
index 2cf69af2..868f262e 100644
--- a/src/front/Components/Layouts/Subscription/Components/SubscribeIllimityComponent/index.tsx
+++ b/src/front/Components/Layouts/Subscription/Components/SubscribeIllimityComponent/index.tsx
@@ -113,16 +113,14 @@ export default function SubscribeIllimityComponent({ hasNavTab = true }: IProps)
name="paymentFrequencyInSubscription"
value={EPaymentFrequency.yearly.toString()}
onChange={handleFrequencyChange}
- defaultChecked={paymentFrequency === EPaymentFrequency.yearly}>
- Annuel
-
+ defaultChecked={paymentFrequency === EPaymentFrequency.yearly}
+ label="Annuel">
- Mensuel
-
+ defaultChecked={paymentFrequency === EPaymentFrequency.monthly}
+ label="Mensuel">
diff --git a/src/front/Components/Layouts/Subscription/Components/SubscribeStandardComponent/index.tsx b/src/front/Components/Layouts/Subscription/Components/SubscribeStandardComponent/index.tsx
index 5730ac85..e448a954 100644
--- a/src/front/Components/Layouts/Subscription/Components/SubscribeStandardComponent/index.tsx
+++ b/src/front/Components/Layouts/Subscription/Components/SubscribeStandardComponent/index.tsx
@@ -104,16 +104,14 @@ export default function SubscribeStandardComponent({ hasNavTab = true }: IProps)
name="paymentFrequencyInSubscription"
value={EPaymentFrequency.yearly.toString()}
onChange={handleFrequencyChange}
- defaultChecked={paymentFrequency === EPaymentFrequency.yearly}>
- Annuel
-
+ defaultChecked={paymentFrequency === EPaymentFrequency.yearly}
+ label="Annuel">
- Mensuel
-
+ defaultChecked={paymentFrequency === EPaymentFrequency.monthly}
+ label="Mensuel">
diff --git a/src/front/Components/Layouts/Users/UserInformations/index.tsx b/src/front/Components/Layouts/Users/UserInformations/index.tsx
index 2ffc406f..2a723553 100644
--- a/src/front/Components/Layouts/Users/UserInformations/index.tsx
+++ b/src/front/Components/Layouts/Users/UserInformations/index.tsx
@@ -210,7 +210,7 @@ export default function UserInformations(props: IProps) {
}, [currentAppointment, getUser]);
return (
-
+
{!isLoading && (
diff --git a/src/front/Components/Layouts/Users/index.tsx b/src/front/Components/Layouts/Users/index.tsx
index 60f48873..b9da00ca 100644
--- a/src/front/Components/Layouts/Users/index.tsx
+++ b/src/front/Components/Layouts/Users/index.tsx
@@ -9,7 +9,7 @@ type IState = {};
export default class Users extends BasePage
{
public override render(): JSX.Element {
return (
-
+
Informations des utilisateurs
diff --git a/src/front/Config/Module/development.json b/src/front/Config/Module/development.json
index 20bc04c8..253742bf 100644
--- a/src/front/Config/Module/development.json
+++ b/src/front/Config/Module/development.json
@@ -390,6 +390,22 @@
}
}
}
+ },
+ "Legal": {
+ "enabled": true,
+ "props": {
+ "path": "/legal",
+ "labelKey": "legal"
+ },
+ "pages": {
+ "LegalInformations": {
+ "enabled": true,
+ "props": {
+ "path": "/legal/[legalUid]",
+ "labelKey": "legal_informations"
+ }
+ }
+ }
}
}
}
diff --git a/src/front/Config/Module/preprod.json b/src/front/Config/Module/preprod.json
index 20bc04c8..253742bf 100644
--- a/src/front/Config/Module/preprod.json
+++ b/src/front/Config/Module/preprod.json
@@ -390,6 +390,22 @@
}
}
}
+ },
+ "Legal": {
+ "enabled": true,
+ "props": {
+ "path": "/legal",
+ "labelKey": "legal"
+ },
+ "pages": {
+ "LegalInformations": {
+ "enabled": true,
+ "props": {
+ "path": "/legal/[legalUid]",
+ "labelKey": "legal_informations"
+ }
+ }
+ }
}
}
}
diff --git a/src/front/Config/Module/production.json b/src/front/Config/Module/production.json
index 20bc04c8..253742bf 100644
--- a/src/front/Config/Module/production.json
+++ b/src/front/Config/Module/production.json
@@ -390,6 +390,22 @@
}
}
}
+ },
+ "Legal": {
+ "enabled": true,
+ "props": {
+ "path": "/legal",
+ "labelKey": "legal"
+ },
+ "pages": {
+ "LegalInformations": {
+ "enabled": true,
+ "props": {
+ "path": "/legal/[legalUid]",
+ "labelKey": "legal_informations"
+ }
+ }
+ }
}
}
}
diff --git a/src/front/Config/Module/staging.json b/src/front/Config/Module/staging.json
index 20bc04c8..253742bf 100644
--- a/src/front/Config/Module/staging.json
+++ b/src/front/Config/Module/staging.json
@@ -390,6 +390,22 @@
}
}
}
+ },
+ "Legal": {
+ "enabled": true,
+ "props": {
+ "path": "/legal",
+ "labelKey": "legal"
+ },
+ "pages": {
+ "LegalInformations": {
+ "enabled": true,
+ "props": {
+ "path": "/legal/[legalUid]",
+ "labelKey": "legal_informations"
+ }
+ }
+ }
}
}
}
diff --git a/src/front/Hooks/useToggle.ts b/src/front/Hooks/useToggle.ts
index 884e67aa..14088d13 100644
--- a/src/front/Hooks/useToggle.ts
+++ b/src/front/Hooks/useToggle.ts
@@ -3,8 +3,11 @@ import { useCallback, useState } from "react";
export default function useToggle(defaultValue: boolean = false) {
const [active, setActive] = useState(defaultValue);
- const toggle = useCallback(() => {
- setActive((prev) => !prev);
+ const toggle = useCallback((callback?: (isOpen: boolean) => void) => {
+ setActive((prev) => {
+ callback?.(!prev);
+ return !prev;
+ });
}, []);
const activate = useCallback(() => {
diff --git a/src/front/index.scss b/src/front/index.scss
index 3b8e1f7e..5b066837 100644
--- a/src/front/index.scss
+++ b/src/front/index.scss
@@ -46,13 +46,6 @@ a,
a:visited {
color: initial;
text-decoration: none !important;
- opacity: 1;
- transition: opacity 0.15s ease-in-out;
- will-change: opacity;
-}
-
-a:hover {
- opacity: 0.9;
}
.react-select__input-container {
diff --git a/src/pages/legal/[legalUid]/index.tsx b/src/pages/legal/[legalUid]/index.tsx
new file mode 100644
index 00000000..58da8f23
--- /dev/null
+++ b/src/pages/legal/[legalUid]/index.tsx
@@ -0,0 +1,5 @@
+import LegalInformations from "@Front/Components/Layouts/Legal/LegalInformations";
+
+export default function Route() {
+ return ;
+}
diff --git a/src/pages/legal/index.tsx b/src/pages/legal/index.tsx
new file mode 100644
index 00000000..fb7e17c9
--- /dev/null
+++ b/src/pages/legal/index.tsx
@@ -0,0 +1,5 @@
+import Legal from "@Front/Components/Layouts/Legal";
+
+export default function Route() {
+ return ;
+}