@mirohq/design-system-patterns 0.2.0-patterns-improvements-2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/main.js +2 -1
- package/dist/main.js.map +1 -1
- package/dist/module.js +2 -1
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
package/dist/main.js
CHANGED
@@ -20,7 +20,8 @@ const Container = designSystemStitches.styled(designSystemBox.Box, {
|
|
20
20
|
flexDirection: "column",
|
21
21
|
gap: "$50",
|
22
22
|
minWidth: "290px",
|
23
|
-
maxWidth: "480px"
|
23
|
+
maxWidth: "480px",
|
24
|
+
textAlign: "left"
|
24
25
|
});
|
25
26
|
const Illustration = designSystemStitches.styled("img", {
|
26
27
|
width: "112px",
|
package/dist/main.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"main.js","sources":["../src/empty-state/empty-state.tsx"],"sourcesContent":["import React from 'react'\nimport type { ReactNode, ElementRef } from 'react'\nimport { styled } from '@mirohq/design-system-stitches'\nimport { Box } from '@mirohq/design-system-box'\nimport { Button } from '@mirohq/design-system-button'\nimport type { ButtonProps } from '@mirohq/design-system-button'\nimport type { BoxProps } from '@mirohq/design-system-box'\nimport { Heading } from '@mirohq/design-system-typography'\n\n// Types\n// -----------------------------------------------------------------------------\nexport interface PatternEmptyStateProps extends Omit<BoxProps, 'children'> {\n heading: ReactNode\n description?: ReactNode\n illustration?: string\n actions?: {\n primary: ActionButton\n secondary?: ActionButton\n }\n}\n\ntype ActionButton = Omit<ButtonProps, 'variant' | 'children'> & {\n label: ReactNode\n}\n\n// Styled\n// -----------------------------------------------------------------------------\nconst Container = styled(Box, {\n background: '$background-neutrals',\n padding: '$500',\n display: 'flex',\n flexDirection: 'column',\n gap: '$50',\n minWidth: '290px',\n maxWidth: '480px',\n})\n\nconst Illustration = styled('img', {\n width: '112px',\n display: 'block',\n})\n\nconst Description = styled(Box, {\n color: '$text-neutrals-subtle',\n})\n\nconst Actions = styled(Box, {\n paddingY: '$200',\n display: 'flex',\n flexWrap: 'wrap',\n gap: '$100',\n})\n\n// Component\n// -----------------------------------------------------------------------------\nexport const PatternEmptyState = React.forwardRef<\n ElementRef<typeof Box>,\n PatternEmptyStateProps\n>(({ heading, description, illustration, actions, ...restProps }, ref) => (\n <Container ref={ref} {...restProps}>\n {illustration != null && (\n <Illustration src={illustration} aria-hidden alt='' />\n )}\n <Heading ref={ref} level={2} styledAs='h3'>\n {heading}\n </Heading>\n {description != null && (\n <Description css={{ color: '$text-neutrals-subtle' }}>\n {description}\n </Description>\n )}\n {actions != null && (\n <Actions>\n <Button {...actions.primary} variant='primary'>\n {actions.primary.label}\n </Button>\n\n {actions.secondary != null && (\n <Button {...actions.secondary} variant='ghost'>\n {actions.secondary.label}\n </Button>\n )}\n </Actions>\n )}\n </Container>\n))\n"],"names":["styled","Box","React","Heading","jsx","jsxs","Button"],"mappings":";;;;;;;;;;;;;;;AA2BA,MAAM,SAAA,GAAYA,4BAAOC,mBAAK,EAAA;AAAA,EAC5B,UAAY,EAAA,sBAAA;AAAA,EACZ,OAAS,EAAA,MAAA;AAAA,EACT,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAK,EAAA,KAAA;AAAA,EACL,QAAU,EAAA,OAAA;AAAA,EACV,QAAU,EAAA,OAAA;
|
1
|
+
{"version":3,"file":"main.js","sources":["../src/empty-state/empty-state.tsx"],"sourcesContent":["import React from 'react'\nimport type { ReactNode, ElementRef } from 'react'\nimport { styled } from '@mirohq/design-system-stitches'\nimport { Box } from '@mirohq/design-system-box'\nimport { Button } from '@mirohq/design-system-button'\nimport type { ButtonProps } from '@mirohq/design-system-button'\nimport type { BoxProps } from '@mirohq/design-system-box'\nimport { Heading } from '@mirohq/design-system-typography'\n\n// Types\n// -----------------------------------------------------------------------------\nexport interface PatternEmptyStateProps extends Omit<BoxProps, 'children'> {\n heading: ReactNode\n description?: ReactNode\n illustration?: string\n actions?: {\n primary: ActionButton\n secondary?: ActionButton\n }\n}\n\ntype ActionButton = Omit<ButtonProps, 'variant' | 'children'> & {\n label: ReactNode\n}\n\n// Styled\n// -----------------------------------------------------------------------------\nconst Container = styled(Box, {\n background: '$background-neutrals',\n padding: '$500',\n display: 'flex',\n flexDirection: 'column',\n gap: '$50',\n minWidth: '290px',\n maxWidth: '480px',\n textAlign: 'left',\n})\n\nconst Illustration = styled('img', {\n width: '112px',\n display: 'block',\n})\n\nconst Description = styled(Box, {\n color: '$text-neutrals-subtle',\n})\n\nconst Actions = styled(Box, {\n paddingY: '$200',\n display: 'flex',\n flexWrap: 'wrap',\n gap: '$100',\n})\n\n// Component\n// -----------------------------------------------------------------------------\nexport const PatternEmptyState = React.forwardRef<\n ElementRef<typeof Box>,\n PatternEmptyStateProps\n>(({ heading, description, illustration, actions, ...restProps }, ref) => (\n <Container ref={ref} {...restProps}>\n {illustration != null && (\n <Illustration src={illustration} aria-hidden alt='' />\n )}\n <Heading ref={ref} level={2} styledAs='h3'>\n {heading}\n </Heading>\n {description != null && (\n <Description css={{ color: '$text-neutrals-subtle' }}>\n {description}\n </Description>\n )}\n {actions != null && (\n <Actions>\n <Button {...actions.primary} variant='primary'>\n {actions.primary.label}\n </Button>\n\n {actions.secondary != null && (\n <Button {...actions.secondary} variant='ghost'>\n {actions.secondary.label}\n </Button>\n )}\n </Actions>\n )}\n </Container>\n))\n"],"names":["styled","Box","React","Heading","jsx","jsxs","Button"],"mappings":";;;;;;;;;;;;;;;AA2BA,MAAM,SAAA,GAAYA,4BAAOC,mBAAK,EAAA;AAAA,EAC5B,UAAY,EAAA,sBAAA;AAAA,EACZ,OAAS,EAAA,MAAA;AAAA,EACT,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAK,EAAA,KAAA;AAAA,EACL,QAAU,EAAA,OAAA;AAAA,EACV,QAAU,EAAA,OAAA;AAAA,EACV,SAAW,EAAA,MAAA;AACb,CAAC,CAAA,CAAA;AAED,MAAM,YAAA,GAAeD,4BAAO,KAAO,EAA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AAA,EAAA,GAAG,OAAQ,CAAA,SAAA,EAAW,OAAQ,EAAA,OAAA,EACpC,QAAQ,EAAA,OAAA,CAAA,SAAA,CAAU,KACrB,EAAA,CAAA;AAAA,GAEJ,EAAA,CAAA;AAAA,CAAA,EAEJ,CACD;;;;"}
|
package/dist/module.js
CHANGED
package/dist/module.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"module.js","sources":["../src/empty-state/empty-state.tsx"],"sourcesContent":["import React from 'react'\nimport type { ReactNode, ElementRef } from 'react'\nimport { styled } from '@mirohq/design-system-stitches'\nimport { Box } from '@mirohq/design-system-box'\nimport { Button } from '@mirohq/design-system-button'\nimport type { ButtonProps } from '@mirohq/design-system-button'\nimport type { BoxProps } from '@mirohq/design-system-box'\nimport { Heading } from '@mirohq/design-system-typography'\n\n// Types\n// -----------------------------------------------------------------------------\nexport interface PatternEmptyStateProps extends Omit<BoxProps, 'children'> {\n heading: ReactNode\n description?: ReactNode\n illustration?: string\n actions?: {\n primary: ActionButton\n secondary?: ActionButton\n }\n}\n\ntype ActionButton = Omit<ButtonProps, 'variant' | 'children'> & {\n label: ReactNode\n}\n\n// Styled\n// -----------------------------------------------------------------------------\nconst Container = styled(Box, {\n background: '$background-neutrals',\n padding: '$500',\n display: 'flex',\n flexDirection: 'column',\n gap: '$50',\n minWidth: '290px',\n maxWidth: '480px',\n})\n\nconst Illustration = styled('img', {\n width: '112px',\n display: 'block',\n})\n\nconst Description = styled(Box, {\n color: '$text-neutrals-subtle',\n})\n\nconst Actions = styled(Box, {\n paddingY: '$200',\n display: 'flex',\n flexWrap: 'wrap',\n gap: '$100',\n})\n\n// Component\n// -----------------------------------------------------------------------------\nexport const PatternEmptyState = React.forwardRef<\n ElementRef<typeof Box>,\n PatternEmptyStateProps\n>(({ heading, description, illustration, actions, ...restProps }, ref) => (\n <Container ref={ref} {...restProps}>\n {illustration != null && (\n <Illustration src={illustration} aria-hidden alt='' />\n )}\n <Heading ref={ref} level={2} styledAs='h3'>\n {heading}\n </Heading>\n {description != null && (\n <Description css={{ color: '$text-neutrals-subtle' }}>\n {description}\n </Description>\n )}\n {actions != null && (\n <Actions>\n <Button {...actions.primary} variant='primary'>\n {actions.primary.label}\n </Button>\n\n {actions.secondary != null && (\n <Button {...actions.secondary} variant='ghost'>\n {actions.secondary.label}\n </Button>\n )}\n </Actions>\n )}\n </Container>\n))\n"],"names":[],"mappings":";;;;;;;AA2BA,MAAM,SAAA,GAAY,OAAO,GAAK,EAAA;AAAA,EAC5B,UAAY,EAAA,sBAAA;AAAA,EACZ,OAAS,EAAA,MAAA;AAAA,EACT,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAK,EAAA,KAAA;AAAA,EACL,QAAU,EAAA,OAAA;AAAA,EACV,QAAU,EAAA,OAAA;
|
1
|
+
{"version":3,"file":"module.js","sources":["../src/empty-state/empty-state.tsx"],"sourcesContent":["import React from 'react'\nimport type { ReactNode, ElementRef } from 'react'\nimport { styled } from '@mirohq/design-system-stitches'\nimport { Box } from '@mirohq/design-system-box'\nimport { Button } from '@mirohq/design-system-button'\nimport type { ButtonProps } from '@mirohq/design-system-button'\nimport type { BoxProps } from '@mirohq/design-system-box'\nimport { Heading } from '@mirohq/design-system-typography'\n\n// Types\n// -----------------------------------------------------------------------------\nexport interface PatternEmptyStateProps extends Omit<BoxProps, 'children'> {\n heading: ReactNode\n description?: ReactNode\n illustration?: string\n actions?: {\n primary: ActionButton\n secondary?: ActionButton\n }\n}\n\ntype ActionButton = Omit<ButtonProps, 'variant' | 'children'> & {\n label: ReactNode\n}\n\n// Styled\n// -----------------------------------------------------------------------------\nconst Container = styled(Box, {\n background: '$background-neutrals',\n padding: '$500',\n display: 'flex',\n flexDirection: 'column',\n gap: '$50',\n minWidth: '290px',\n maxWidth: '480px',\n textAlign: 'left',\n})\n\nconst Illustration = styled('img', {\n width: '112px',\n display: 'block',\n})\n\nconst Description = styled(Box, {\n color: '$text-neutrals-subtle',\n})\n\nconst Actions = styled(Box, {\n paddingY: '$200',\n display: 'flex',\n flexWrap: 'wrap',\n gap: '$100',\n})\n\n// Component\n// -----------------------------------------------------------------------------\nexport const PatternEmptyState = React.forwardRef<\n ElementRef<typeof Box>,\n PatternEmptyStateProps\n>(({ heading, description, illustration, actions, ...restProps }, ref) => (\n <Container ref={ref} {...restProps}>\n {illustration != null && (\n <Illustration src={illustration} aria-hidden alt='' />\n )}\n <Heading ref={ref} level={2} styledAs='h3'>\n {heading}\n </Heading>\n {description != null && (\n <Description css={{ color: '$text-neutrals-subtle' }}>\n {description}\n </Description>\n )}\n {actions != null && (\n <Actions>\n <Button {...actions.primary} variant='primary'>\n {actions.primary.label}\n </Button>\n\n {actions.secondary != null && (\n <Button {...actions.secondary} variant='ghost'>\n {actions.secondary.label}\n </Button>\n )}\n </Actions>\n )}\n </Container>\n))\n"],"names":[],"mappings":";;;;;;;AA2BA,MAAM,SAAA,GAAY,OAAO,GAAK,EAAA;AAAA,EAC5B,UAAY,EAAA,sBAAA;AAAA,EACZ,OAAS,EAAA,MAAA;AAAA,EACT,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAK,EAAA,KAAA;AAAA,EACL,QAAU,EAAA,OAAA;AAAA,EACV,QAAU,EAAA,OAAA;AAAA,EACV,SAAW,EAAA,MAAA;AACb,CAAC,CAAA,CAAA;AAED,MAAM,YAAA,GAAe,OAAO,KAAO,EAAA;AAAA,EACjC,KAAO,EAAA,OAAA;AAAA,EACP,OAAS,EAAA,OAAA;AACX,CAAC,CAAA,CAAA;AAED,MAAM,WAAA,GAAc,OAAO,GAAK,EAAA;AAAA,EAC9B,KAAO,EAAA,uBAAA;AACT,CAAC,CAAA,CAAA;AAED,MAAM,OAAA,GAAU,OAAO,GAAK,EAAA;AAAA,EAC1B,QAAU,EAAA,MAAA;AAAA,EACV,OAAS,EAAA,MAAA;AAAA,EACT,QAAU,EAAA,MAAA;AAAA,EACV,GAA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
6
|
"source": "src/index.ts",
|
@@ -27,9 +27,9 @@
|
|
27
27
|
},
|
28
28
|
"dependencies": {
|
29
29
|
"@mirohq/design-system-box": "^2.1.60",
|
30
|
-
"@mirohq/design-system-button": "^4.2.4",
|
31
30
|
"@mirohq/design-system-stitches": "^2.6.29",
|
32
|
-
"@mirohq/design-system-typography": "^0.6.7"
|
31
|
+
"@mirohq/design-system-typography": "^0.6.7",
|
32
|
+
"@mirohq/design-system-button": "^4.2.4"
|
33
33
|
},
|
34
34
|
"devDependencies": {
|
35
35
|
"@mirohq/brand-assets": "^0.2.1"
|