-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
41 changed files
with
804 additions
and
164 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
examples/client/Locomotion/src/Components/BusinessAccountText/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import React from 'react'; | ||
import { BoldTitle, SubTitle, TitleWithSubTitle } from './styled'; | ||
|
||
interface BusinessAccountTextProps { | ||
title: string; | ||
subTitle: string; | ||
} | ||
const BusinessAccountText = ({ | ||
title, subTitle, | ||
} : BusinessAccountTextProps) => ( | ||
<TitleWithSubTitle> | ||
<BoldTitle numberOfLines={1}>{title}</BoldTitle> | ||
<SubTitle numberOfLines={1}>{subTitle}</SubTitle> | ||
</TitleWithSubTitle> | ||
); | ||
|
||
export default BusinessAccountText; |
22 changes: 22 additions & 0 deletions
22
examples/client/Locomotion/src/Components/BusinessAccountText/styled.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { Text, View } from 'react-native'; | ||
import styled from 'styled-components'; | ||
import { FONT_SIZES, FONT_WEIGHTS } from '../../context/theme'; | ||
|
||
export const TitleWithSubTitle = styled(View)` | ||
display: flex; | ||
flex-direction: column; | ||
flex: 1 0 0; | ||
`; | ||
export const BaseText = styled(Text)` | ||
color: #212229; | ||
${FONT_SIZES.LARGE}; | ||
font-family: Inter; | ||
font-style: normal; | ||
line-height: 20px; | ||
`; | ||
export const SubTitle = styled(BaseText)` | ||
font-weight: 500; | ||
`; | ||
export const BoldTitle = styled(BaseText)` | ||
font-weight: 700; | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
examples/client/Locomotion/src/Components/EmptyState/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react'; | ||
import { | ||
Container, Description, Title, TitleWithoutDescription, | ||
} from './styled'; | ||
|
||
interface EmptyStateProps { | ||
title: string; | ||
description?: string; | ||
} | ||
const EmptyState = ({ | ||
title, | ||
description, | ||
}: EmptyStateProps) => ( | ||
<Container> | ||
{description | ||
? <Title>{title}</Title> | ||
: <TitleWithoutDescription>{title}</TitleWithoutDescription> | ||
} | ||
|
||
{description ? <Description>{description}</Description> : null} | ||
</Container> | ||
); | ||
EmptyState.defaultProps = { | ||
description: '', | ||
}; | ||
export default EmptyState; |
40 changes: 40 additions & 0 deletions
40
examples/client/Locomotion/src/Components/EmptyState/styled.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import { Text, View } from 'react-native'; | ||
import styled from 'styled-components'; | ||
import { FONT_SIZES, FONT_WEIGHTS } from '../../context/theme'; | ||
|
||
export const Container = styled(View)` | ||
border-radius: 8px; | ||
border: 1px dashed rgba(125, 139, 172, 0.32); | ||
display: flex; | ||
padding: 16px; | ||
flex-direction: column; | ||
justify-content: center; | ||
align-items: center; | ||
margin: 4px; | ||
flex: 1 0 0; | ||
align-self: stretch; | ||
`; | ||
export const Title = styled(Text)` | ||
align-self: stretch; | ||
color: #212229; | ||
text-align: center; | ||
${FONT_WEIGHTS.REGULAR}; | ||
${FONT_SIZES.LARGE}; | ||
font-weight: 600; | ||
`; | ||
export const Description = styled(Text)` | ||
align-self: stretch; | ||
color: #666975; | ||
text-align: center; | ||
${FONT_WEIGHTS.REGULAR}; | ||
${FONT_SIZES.LARGE}; | ||
font-weight: 400; | ||
`; | ||
export const TitleWithoutDescription = styled(Text)` | ||
align-self: stretch; | ||
color: #666975; | ||
text-align: center; | ||
${FONT_WEIGHTS.REGULAR}; | ||
${FONT_SIZES.LARGE}; | ||
font-weight: 500; | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.