Merge pull request #4492 from urbit/mp/launch/1-7-tweak

launch: update for 1.7
This commit is contained in:
matildepark 2021-02-24 16:12:27 -05:00 committed by GitHub
commit 24dbe35af6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 23 additions and 26 deletions

View File

@ -21,7 +21,7 @@ import { Helmet } from 'react-helmet';
import useLocalState from "~/logic/state/local"; import useLocalState from "~/logic/state/local";
import { useWaitForProps } from '~/logic/lib/useWaitForProps'; import { useWaitForProps } from '~/logic/lib/useWaitForProps';
import { useQuery } from "~/logic/lib/useQuery"; import { useQuery } from "~/logic/lib/useQuery";
import { import {
hasTutorialGroup, hasTutorialGroup,
TUTORIAL_GROUP, TUTORIAL_GROUP,
TUTORIAL_HOST, TUTORIAL_HOST,
@ -46,17 +46,14 @@ export default function LaunchApp(props) {
const hashBox = ( const hashBox = (
<Box <Box
position={["relative", "absolute"]} position={["relative", "absolute"]}
fontFamily="mono"
left="0" left="0"
bottom="0" bottom="0"
color="washedGray" bg="#f2f2f2"
bg="white"
ml={3} ml={3}
mb={3} mb={3}
borderRadius={2} borderRadius={2}
fontSize={0} fontSize={0}
p={2} p={2}
boxShadow="0 0 0px 1px inset"
cursor="pointer" cursor="pointer"
onClick={() => { onClick={() => {
writeText(props.baseHash); writeText(props.baseHash);
@ -66,7 +63,7 @@ export default function LaunchApp(props) {
}, 2000); }, 2000);
}} }}
> >
<Text color="gray">{hashText || props.baseHash}</Text> <Text mono bold>{hashText || props.baseHash}</Text>
</Box> </Box>
); );
@ -87,7 +84,7 @@ export default function LaunchApp(props) {
const waiter = useWaitForProps(props); const waiter = useWaitForProps(props);
const { modal, showModal } = useModal({ const { modal, showModal } = useModal({
position: 'relative', position: 'relative',
maxWidth: '350px', maxWidth: '350px',
modal: (dismiss) => { modal: (dismiss) => {
const onDismiss = (e) => { const onDismiss = (e) => {
@ -120,7 +117,7 @@ export default function LaunchApp(props) {
</Box> </Box>
<Text lineHeight="tall" fontWeight="medium">Welcome</Text> <Text lineHeight="tall" fontWeight="medium">Welcome</Text>
<Text lineHeight="tall"> <Text lineHeight="tall">
You have been invited to use Landscape, an interface to chat You have been invited to use Landscape, an interface to chat
and interact with communities and interact with communities
<br /> <br />
Would you like a tour of Landscape? Would you like a tour of Landscape?
@ -183,21 +180,22 @@ export default function LaunchApp(props) {
/> />
<ModalButton <ModalButton
icon="Plus" icon="Plus"
bg="blue" bg="washedGray"
color="#fff" color="#000"
text="Join a Group" text="New Group"
style={{ gridColumnStart: 1 }} style={{ gridColumnStart: 1 }}
>
<JoinGroup {...props} />
</ModalButton>
<ModalButton
icon="CreateGroup"
bg="green"
color="#fff"
text="Create Group"
> >
<NewGroup {...props} /> <NewGroup {...props} />
</ModalButton> </ModalButton>
<ModalButton
icon="Boot"
bg="washedGray"
color="#000"
text="Join Group"
>
<JoinGroup {...props} />
</ModalButton>
<Groups unreads={props.unreads} groups={props.groups} associations={props.associations} /> <Groups unreads={props.unreads} groups={props.groups} associations={props.associations} />
</Box> </Box>
<Box alignSelf="flex-start" display={["block", "none"]}>{hashBox}</Box> <Box alignSelf="flex-start" display={["block", "none"]}>{hashBox}</Box>

View File

@ -85,12 +85,12 @@ function Group(props: GroupProps) {
<Col height="100%" justifyContent="space-between"> <Col height="100%" justifyContent="space-between">
<Text>{title}</Text> <Text>{title}</Text>
<Col> <Col>
{unreads > 0 &&
(<Text gray>{unreads} unread{unreads !== 1 && 's'} </Text>)
}
{updates > 0 && {updates > 0 &&
(<Text mt="1" color="blue">{updates} update{updates !== 1 && 's'} </Text>) (<Text mt="1" color="blue">{updates} update{updates !== 1 && 's'} </Text>)
} }
{unreads > 0 &&
(<Text color="lightGray">{unreads}</Text>)
}
</Col> </Col>
</Col> </Col>

View File

@ -12,17 +12,16 @@ const ModalButton = (props) => {
<Button <Button
onClick={showModal} onClick={showModal}
display='flex' display='flex'
alignItems='center'
cursor='pointer' cursor='pointer'
justifyContent="start"
bg={bg} bg={bg}
p={2} p={2}
border={0}
borderRadius={2} borderRadius={2}
boxShadow='0 0 0px 1px inset'
color='scales.black20'
{...rest} {...rest}
> >
<Icon icon={props.icon} mr={2} color={color}></Icon> <Icon icon={props.icon} mr={2} color={color}></Icon>
<Text color={color} whiteSpace='nowrap'> <Text color={color} fontWeight="medium" whiteSpace='nowrap'>
{props.text} {props.text}
</Text> </Text>
</Button> </Button>