import useShowStorybookCode from '@techytools/ui/hooks/useShowStorybookCode';
import CanvasContainer from '@techytools/ui/.storybook/components/CanvasContainer';
import Block from '@techytools/ui/components/Block';
import { withInline } from '@techytools/ui/components/Inline';
import CanvasStoryPadding from '@techytools/ui/.storybook/components/CanvasStoryPadding';
export default function (props) {
useShowStorybookCode();
const Heading = withInline({
as: 'h2',
ss: 'margin:0;',
});
const Code = withInline({
as: 'code',
});
return (
Text can be used as="h2", or{' '}
as="<code>", or as almost any other
HTML element. By default, it's a span.
But if you need to display inline code, use CodeInline{' '}
component, because that has more functionality. This{' '}
Inline component is mostly just used for custom style
props. See all available props below.
);
}
export const code = `import Inline from '@techytools/ui/components/Inline';
Text can be used as h2, or as <code>, or as any other HTML container element. By default, it's a span.
`;