Merge pull request #5678 from urbit/lf/landscape-floor

groups: assorted bug fixes
This commit is contained in:
Hunter Miller 2022-03-31 12:28:43 -05:00 committed by GitHub
commit 3496a8e8bf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 16 additions and 6 deletions

View File

@ -12,7 +12,7 @@ import React from "react";
import { useHistory } from "react-router-dom";
import { getNotificationCount } from "~/logic/lib/hark";
import { alphabeticalOrder } from "~/logic/lib/util";
import useGroupState from "~/logic/state/group";
import useGroupState, {useGroup} from "~/logic/state/group";
import useHarkState, { selHarkGraph } from "~/logic/state/hark";
import useInviteState from "~/logic/state/invite";
import useMetadataState, { usePreview } from "~/logic/state/metadata";
@ -128,6 +128,11 @@ function PendingGroup(props: PendingGroupProps) {
};
const joining = useGroupState((s) => s.pendingJoin[path]?.progress);
const group = useGroup(path);
if(joining?.progress === 'done' && !group) {
return null;
}
return (
<Tile gridColumnStart={first ? 1 : undefined}>

View File

@ -84,7 +84,8 @@ export function RemoteContentImageEmbed(
referrerPolicy="no-referrer"
flexShrink={0}
src={url}
height="100%"
height="192px"
maxWidth="192px"
width="100%"
objectFit="contain"
borderRadius={2}

View File

@ -204,7 +204,7 @@ export function ShipSearch<I extends string, V extends Value<I>>(
onChange={onChange}
onSelect={onAdd}
/>
<Row minHeight="34px" flexWrap="wrap">
<Row overflowX="auto" maxHeight="192px" minHeight="34px" flexWrap="wrap">
{pills.map((s, i) => (
<Row
fontFamily="mono"

View File

@ -213,7 +213,7 @@ export function GroupsPane(props: GroupsPaneProps) {
{...props}
baseUrl={baseUrl}
>
<Box width="100%">
<Box overflow="auto">
<Join desc={desc} />
</Box>
</Skeleton>

View File

@ -54,7 +54,9 @@ export function SidebarListHeader(props: {
const feedPath = groupPath ? getFeedPath(associations.groups[groupPath]) : undefined;
const unreadCount = useHarkState(
s => s.unreads?.graph?.[feedPath ?? '']?.['/']?.unreads as number ?? 0
s => feedPath
? (s.unreads?.[`/graph/${feedPath.slice(6)}` ?? '']?.count as number ?? 0)
: 0
);
return (

View File

@ -203,12 +203,13 @@
?> =(1 ~(wyt by nodes))
=/ ship-screen (~(get ju screened) src.bowl)
=. ship-screen (~(uni in ship-screen) (normalize-incoming nodes))
=/ should-notify=? !(~(has by screened) src.bowl)
=. screened (~(put by screened) src.bowl ship-screen)
:_ state
=/ =action:hook
[%pendings ~(key by screened)]
:- (fact:io dm-hook-action+!>(action) ~[/updates])
?: (~(has by screened) src.bowl) ~
?. should-notify ~
(notify-pending src.bowl)^~
::
++ dm-exists

View File

@ -542,6 +542,7 @@
%graph-validator-publish publish
%graph-validator-link link
%graph-validator-dm dm
%graph-validator-post post
==
::
++ chat