diff --git a/packages/canon/src/components/Inline/Docs.mdx b/packages/canon/src/components/Inline/Docs.mdx new file mode 100644 index 0000000000..fb4e664b42 --- /dev/null +++ b/packages/canon/src/components/Inline/Docs.mdx @@ -0,0 +1,118 @@ +import { Meta, Unstyled, Source } from '@storybook/blocks'; +import * as InlineStories from './Inline.stories'; +import { Title, Text } from '../../../docs/components'; +import { PropsTable, getBoxProps } from '../../../docs/components/PropsTable'; +import { spacingProperties } from '../../layout/sprinkles.css'; +import { inlineProperties } from './sprinkles.css'; + + + + + +Inline + + + The Inline component is used to create a horizontal layout of elements. By + default it uses flex and flexWrap to make sure that your content always flows + responsively. + + +Installation + + + + API reference + + + + + + The grid component also accepts all the spacing props from the Box component. + + + + +Examples + +Simple +A simple example of how to use the Inline component. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + +Responsive + + The Inline component also supports responsive values, making it easy to create + responsive designs. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + +Align + + The Inline component also supports responsive alignment, making it easy to + create responsive designs. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + +Align vertically + + The Inline component also supports responsive vertical alignment, making it + easy to create responsive designs. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + + diff --git a/packages/canon/src/components/Inline/sprinkles.css.ts b/packages/canon/src/components/Inline/sprinkles.css.ts index 1d7e95da00..ccd4126608 100644 --- a/packages/canon/src/components/Inline/sprinkles.css.ts +++ b/packages/canon/src/components/Inline/sprinkles.css.ts @@ -18,7 +18,7 @@ import { defineProperties, createSprinkles } from '@vanilla-extract/sprinkles'; import { breakpoints } from '../../layout/properties'; import { colorProperties, spacingProperties } from '../../layout/sprinkles.css'; -const inlineProperties = defineProperties({ +export const inlineProperties = defineProperties({ conditions: breakpoints, defaultCondition: 'xs', properties: { diff --git a/packages/canon/src/components/Stack/Docs.mdx b/packages/canon/src/components/Stack/Docs.mdx index 4f63d7114e..62fd06cc62 100644 --- a/packages/canon/src/components/Stack/Docs.mdx +++ b/packages/canon/src/components/Stack/Docs.mdx @@ -1,7 +1,8 @@ import { Meta, Unstyled, Source } from '@storybook/blocks'; import * as StackStories from './Stack.stories'; import { Title, Text } from '../../../docs/components'; -import { PropsTable } from '../../../docs/components/PropsTable'; +import { PropsTable, getBoxProps } from '../../../docs/components/PropsTable'; +import { spacingProperties } from '../../layout/sprinkles.css'; @@ -15,15 +16,12 @@ import { PropsTable } from '../../../docs/components/PropsTable'; columns. All values are responsive. - - Hello World - Hello World - Hello World -`} - language="tsx" - dark -/> +Installation + + + + API reference + -How to stack horizontally? + + The grid component also accepts all the spacing props from the Box component. + + + + +Common questions + +Can I stack horizontally? The Stack component only allows for stacking elements vertically. If you want to create a column layout, please use the Grid component. -Responsive -TBD + + Hello World + Hello World + Hello World + +`} + language="tsx" + dark +/> -Start and End -TBD +Examples + +Simple + + A simple example of how to use the Stack component with a medium gap. + + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + +Responsive + + The Stack component also supports responsive values, making it easy to create + responsive designs. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/> + +Align + + The Stack component also supports responsive alignment, making it easy to + create responsive designs. + + + Hello World + Hello World + Hello World +`} + language="tsx" + dark +/>