Merge branch 'Create-Dashboard' of https://github.com/nimbus-gui/nimbus-gui into Create-Dashboard

This commit is contained in:
Hristo Nedelkov 2023-09-14 12:18:05 +03:00
commit dd83e30718
4 changed files with 20 additions and 21 deletions

View File

@ -1,19 +1,16 @@
import { YStack } from 'tamagui'
import AddCard from './AddCard'
import DashboardCardWrapper from '../../../pages/Dashboard/DashboardCardWrapper'
const AddCardsContainer = () => {
return (
<YStack
style={{
borderRadius: '16px',
boxShadow: '0 0 8px rgba(0, 0, 0, 0.1)',
backgroundColor: '$background',
}}
>
<AddCard />
<AddCard />
</YStack>
<DashboardCardWrapper padding="0">
<YStack>
<AddCard />
<AddCard />
</YStack>
</DashboardCardWrapper>
)
}

View File

@ -19,3 +19,10 @@ export const Default: Story = {
children: 'Default',
},
}
export const WithoutPadding: Story = {
args: {
children: 'Default',
padding: '0',
},
}

View File

@ -1,21 +1,15 @@
import { Stack } from 'tamagui'
import { Shadow } from '@status-im/components'
type DashboardCardWrapperProps = {
children: React.ReactNode
padding?: string
}
const DashboardCardWrapper = ({ children }: DashboardCardWrapperProps) => {
const DashboardCardWrapper = ({ children, padding = '12px 16px' }: DashboardCardWrapperProps) => {
return (
<Stack
style={{
borderRadius: '16px',
boxShadow: '0 0 8px rgba(0, 0, 0, 0.1)',
padding: '12px 16px',
backgroundColor: '$background',
}}
>
<Shadow variant="$1" style={{ borderRadius: '16px', padding, backgroundColor: '$background' }}>
{children}
</Stack>
</Shadow>
)
}

View File

@ -1,4 +1,5 @@
import { YStack } from 'tamagui'
import SyncCardContent from './SyncCardContent'
const SyncStatusCard = () => {