diff options
author | Sebastian <sebasjm@gmail.com> | 2021-11-01 16:10:49 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2021-11-01 16:10:55 -0300 |
commit | 88d142d2098ad87613222e9a0c6df478a78f6528 (patch) | |
tree | c5552e43a4641edb233fc858670d50c41d2c7c9b /packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx | |
parent | ea2acd1d3caa21f23127687214045a49d8fea0ad (diff) | |
download | wallet-core-88d142d2098ad87613222e9a0c6df478a78f6528.tar.xz |
more styling
added placeholders for inputs
import declaration for png
next button now has tooltip providing info about whats missing
a lot more of examples for UI testing
added qr dependency for totp rendering
added email and field input types
added all auth method setup screens
added modal when there is not auth provider
merge continent and country into location section
others improvements as well...
Diffstat (limited to 'packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx')
-rw-r--r-- | packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx b/packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx index 218f1d1fd..70ac8157d 100644 --- a/packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx +++ b/packages/anastasis-webui/src/pages/home/BackupFinishedScreen.tsx @@ -1,3 +1,4 @@ +import { format } from "date-fns"; import { h, VNode } from "preact"; import { useAnastasisContext } from "../../context/anastasis"; import { AnastasisClientFrame } from "./index"; @@ -11,23 +12,30 @@ export function BackupFinishedScreen(): VNode { return <div>invalid state</div> } const details = reducer.currentReducerState.success_details - return (<AnastasisClientFrame hideNext title="Backup finished"> - <p> - Your backup of secret "{reducer.currentReducerState.secret_name ?? "??"}" was + + return (<AnastasisClientFrame hideNav title="Backup finished"> + {reducer.currentReducerState.secret_name ? <p> + Your backup of secret <b>"{reducer.currentReducerState.secret_name}"</b> was successful. - </p> - <p>The backup is stored by the following providers:</p> + </p> : + <p> + Your secret was successfully backed up. + </p>} - {details && <ul> + {details && <div class="block"> + <p>The backup is stored by the following providers:</p> {Object.keys(details).map((x, i) => { const sd = details[x]; return ( - <li key={i}> - {x} (Policy version {sd.policy_version}) - </li> + <div key={i} class="box"> + {x} + <p> + version {sd.policy_version} + {sd.policy_expiration.t_ms !== 'never' ? ` expires at: ${format(sd.policy_expiration.t_ms, 'dd/MM/yyyy')}` : ' without expiration date'} + </p> + </div> ); })} - </ul>} - <button onClick={() => reducer.reset()}>Back to start</button> + </div>} </AnastasisClientFrame>); } |