mirror of
https://github.com/tuono-labs/tuono
synced 2026-07-29 13:52:46 -07:00
Create documentation website (#19)
* feat: scaffold documentation app * feat: init documentation website with mantine * feat: add theme button * feat: setup mdx link component * feat: setup basic documentation folder * feat: add routing folder * feat: scaffold homepage * feat: refined navbar and hero * feat: create pre mdx component * feat: create mdx blockquote component * feat: create code mdx component * fix: remove HTMLProps type * feat: create base hero page * ci: add lint/formatting/type checking to documentation * ci: add documentation pipeline * fix: static build documentation * fix: remove documentation test check * fix: install deps outside workspace * fix: filter prettier checks * fix: eslint plugins * fix: clone eslintrc * feat: update dark theme colors * doc: add installation page * feat: add deploy documenation CD pipeline * fix: update documentation bucket region * feat: update documentation head tags * fix: deploy website on main branch push
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
import type { AnchorHTMLAttributes } from 'react'
|
||||
import { Button } from '@mantine/core'
|
||||
import { Link } from 'tuono'
|
||||
import { IconExternalLink } from '@tabler/icons-react'
|
||||
|
||||
export default function MdxLink(
|
||||
props: AnchorHTMLAttributes<HTMLAnchorElement>,
|
||||
): JSX.Element {
|
||||
if (props.href?.startsWith('http')) {
|
||||
return (
|
||||
<Button
|
||||
component="a"
|
||||
{...props}
|
||||
target="_blank"
|
||||
rightSection={
|
||||
<IconExternalLink size="16px" style={{ marginLeft: -5 }} />
|
||||
}
|
||||
variant="transparent"
|
||||
style={{ height: '20px' }}
|
||||
mt={-2}
|
||||
p={0}
|
||||
/>
|
||||
)
|
||||
}
|
||||
return (
|
||||
<Button
|
||||
component={Link}
|
||||
{...props}
|
||||
target="_blank"
|
||||
rightSection={<IconExternalLink size="16px" style={{ marginLeft: -5 }} />}
|
||||
variant="transparent"
|
||||
style={{ height: '20px' }}
|
||||
mt={-2}
|
||||
p={0}
|
||||
/>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user