objective categorical abstract machine language personal data server
1[@@@ocaml.warning "-26-27"]
2
3open React
4
5type actor = AccountSwitcher.actor
6
7let pages =
8 [ ("Account", "/account")
9 ; ("Security", "/account/security")
10 ; ("Identity", "/account/identity")
11 ; ("Permissions", "/account/permissions") ]
12
13let[@react.component] make ~current_user ~logged_in_users ~active_page () =
14 <Sidebar
15 pages
16 active_page
17 header=(<AccountSwitcher
18 current_user logged_in_users add_account_url="/account/login"
19 />)
20 footer=(<a
21 href=( "/account/logout?did="
22 ^ Js.Global.encodeURIComponent current_user.did )>
23 <Button
24 kind=`Secondary
25 className="mt-2 justify-start pl-0 active:shadow-none \
26 focus-visible:shadow-none">
27 (string "log out")
28 </Button>
29 </a>)
30 />