1import { Col, H3, LoadingSpinner, Row, Text } from '@tlon/indigo-react';
2import Modal from 'components/L2/Modal';
3import { Button } from 'indigo-react';
4import { InviteGeneratingStatus } from './useInvites';
6interface GeneratingModalProps {
7 status: InviteGeneratingStatus;
14export const GeneratingModal = ({
20}: GeneratingModalProps) => {
21 const successfulInvites = current > 1 ? current - 1 : 0;
24 show={status !== 'initial'}
26 hideClose={status !== 'finished'}>
28 {status === 'generating' && (
30 <Row alignItems="center" marginBottom={2}>
31 <LoadingSpinner dark />
33 Generating {current} of {total} Invites
37 Each invite will require four transactions to be signed, unless
38 your point is owned by a master ticket.
42 {status === 'finished' && (
45 <span className="ph1 number-emphasis">{total}</span> Invites
48 <Text marginBottom={4}>
49 Your invites have been sent to the roller for confirmation in the
50 next batch. Check the point's page to see its status.
54 <Button solid onClick={hide}>
59 {status === 'errored' && (
62 There was an error while generating your invites:
65 <Text color="red" mono marginBottom={3}>
69 {!!successfulInvites && (
71 At least {successfulInvites} invite
72 {successfulInvites > 1 ? 's' : ''} were successfully generated.
73 Go back to see them or try again.
78 <Button solid onClick={hide}>
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