From 8c0f2f801844bc89de760fd1d76f37b8aa49e838 Mon Sep 17 00:00:00 2001 From: Sosthene Date: Tue, 15 Jul 2025 20:43:15 +0200 Subject: [PATCH] Add create backup button in my account --- .../Components/Layouts/MyAccount/index.tsx | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/front/Components/Layouts/MyAccount/index.tsx b/src/front/Components/Layouts/MyAccount/index.tsx index 7bbc65bc..937ef3c7 100644 --- a/src/front/Components/Layouts/MyAccount/index.tsx +++ b/src/front/Components/Layouts/MyAccount/index.tsx @@ -1,5 +1,6 @@ import backgroundImage from "@Assets/images/background_refonte.svg"; import Users from "@Front/Api/LeCoffreApi/Notary/Users/Users"; +import Button, { EButtonVariant, EButtonSize, EButtonstyletype } from "@Front/Components/DesignSystem/Button"; import Form from "@Front/Components/DesignSystem/Form"; import TextField from "@Front/Components/DesignSystem/Form/TextField"; import Typography, { ETypo, ETypoColor } from "@Front/Components/DesignSystem/Typography"; @@ -9,6 +10,7 @@ import User from "le-coffre-resources/dist/Notary"; import React, { useEffect } from "react"; import classes from "./classes.module.scss"; +import MessageBus from "src/sdk/MessageBus"; export default function MyAccount() { const [user, setUser] = React.useState(null); @@ -33,6 +35,14 @@ export default function MyAccount() { }); }, []); + const handleCreateRestorationFile = () => { + MessageBus.getInstance().exportBackupFile().then((backupFile) => { + console.log(backupFile); + }).catch((error) => { + console.error(error); + }); + }; + return (
@@ -104,6 +114,16 @@ export default function MyAccount() { canCopy /> + +
);