mirror of
https://github.com/ilyakooo0/urbit.git
synced 2025-01-05 22:03:50 +03:00
parent
185f35f194
commit
1ec9141de1
@ -89,6 +89,7 @@ export function Invites(props: InvitesProps): ReactElement {
|
|||||||
invite={invite}
|
invite={invite}
|
||||||
app={app}
|
app={app}
|
||||||
uid={uid}
|
uid={uid}
|
||||||
|
join={join}
|
||||||
resource={resource}
|
resource={resource}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
@ -14,6 +14,7 @@ import GroupSearch from '~/views/components/GroupSearch';
|
|||||||
import { useTutorialModal } from '~/views/components/useTutorialModal';
|
import { useTutorialModal } from '~/views/components/useTutorialModal';
|
||||||
import useHarkState from '~/logic/state/hark';
|
import useHarkState from '~/logic/state/hark';
|
||||||
import useMetadataState from '~/logic/state/metadata';
|
import useMetadataState from '~/logic/state/metadata';
|
||||||
|
import useGroupState from '~/logic/state/group';
|
||||||
|
|
||||||
const baseUrl = '/~notifications';
|
const baseUrl = '/~notifications';
|
||||||
|
|
||||||
@ -41,6 +42,7 @@ export default function NotificationsScreen(props: any): ReactElement {
|
|||||||
|
|
||||||
const [filter, setFilter] = useState<NotificationFilter>({ groups: [] });
|
const [filter, setFilter] = useState<NotificationFilter>({ groups: [] });
|
||||||
const associations = useMetadataState(state => state.associations);
|
const associations = useMetadataState(state => state.associations);
|
||||||
|
const pendingJoin = useGroupState(s => s.pendingJoin);
|
||||||
const onSubmit = async ({ groups } : NotificationFilter) => {
|
const onSubmit = async ({ groups } : NotificationFilter) => {
|
||||||
setFilter({ groups });
|
setFilter({ groups });
|
||||||
};
|
};
|
||||||
@ -128,7 +130,11 @@ export default function NotificationsScreen(props: any): ReactElement {
|
|||||||
</Dropdown>
|
</Dropdown>
|
||||||
</Row>
|
</Row>
|
||||||
</Row>
|
</Row>
|
||||||
{!view && <Inbox {...props} filter={filter.groups} />}
|
{!view && <Inbox
|
||||||
|
pendingJoin={pendingJoin}
|
||||||
|
{...props}
|
||||||
|
filter={filter.groups}
|
||||||
|
/>}
|
||||||
</Col>
|
</Col>
|
||||||
</Body>
|
</Body>
|
||||||
</>
|
</>
|
||||||
|
@ -108,7 +108,7 @@ export function InviteItem(props: InviteItemProps) {
|
|||||||
}
|
}
|
||||||
}, [invite]);
|
}, [invite]);
|
||||||
|
|
||||||
if(status?.hidden) {
|
if(pendingJoin?.hidden) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +119,7 @@ export function InviteItem(props: InviteItemProps) {
|
|||||||
api={api}
|
api={api}
|
||||||
preview={preview}
|
preview={preview}
|
||||||
invite={invite}
|
invite={invite}
|
||||||
status={status}
|
status={pendingJoin.progress}
|
||||||
{...handlers}
|
{...handlers}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user