1import React, { useCallback, useState } from 'react';
2import { Just, Nothing } from 'folktale/maybe';
3import * as need from 'lib/need';
4import { Grid } from 'indigo-react';
6import { usePointCursor } from 'store/pointCursor';
7// import { usePointCache } from 'store/pointCache';
9import View from 'components/View';
10import { DownloadButton } from 'components/Buttons';
11import PaperCollateralRenderer from 'PaperCollateralRenderer';
13import { downloadWallet } from 'lib/invite';
14import { ROUTE_NAMES } from 'lib/routeNames';
16import { useHistory } from 'store/history';
17import { useWallet } from 'store/wallet';
18import FooterButton from 'components/FooterButton';
20export default function Admin() {
21 const history = useHistory();
22 const { urbitWallet } = useWallet();
23 const { pointCursor } = usePointCursor();
24 const point = need.point(pointCursor);
26 const [paper, setPaper] = useState(Nothing());
28 const doDownload = () => {
29 downloadWallet(paper.value);
32 const paperRenderer = Just.hasInstance(paper) ? null : (
33 <PaperCollateralRenderer
34 wallet={{ [point]: urbitWallet.value }}
35 className={'extremely-hidden'}
37 setPaper(Just(paper));
46 disabled={Nothing.hasInstance(paper)}
48 {Nothing.hasInstance(paper)
49 ? 'Printing and folding...'
50 : 'Download paper wallet'}
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list