diff --git a/frontend/packages/erd-core/src/components/ERDRenderer/ERDContent/TableNode/TableNode.tsx b/frontend/packages/erd-core/src/components/ERDRenderer/ERDContent/TableNode/TableNode.tsx index 4482ec9a7..b3a0d5edc 100644 --- a/frontend/packages/erd-core/src/components/ERDRenderer/ERDContent/TableNode/TableNode.tsx +++ b/frontend/packages/erd-core/src/components/ERDRenderer/ERDContent/TableNode/TableNode.tsx @@ -1,5 +1,7 @@ import type { Table } from '@liam-hq/db-structure' import { + DiamondFillIcon, + DiamondIcon, DrawerClose, DrawerContent, DrawerPortal, @@ -39,6 +41,25 @@ export const TableNode: FC = ({ data: { table } }) => { /> )} + {!column.primary && ( + + {column.notNull ? ( + + ) : ( + + )} + + )} {column.name} diff --git a/frontend/packages/ui/src/icons/DiamondFillIcon.tsx b/frontend/packages/ui/src/icons/DiamondFillIcon.tsx new file mode 100644 index 000000000..d90a302f4 --- /dev/null +++ b/frontend/packages/ui/src/icons/DiamondFillIcon.tsx @@ -0,0 +1,25 @@ +import type { ComponentPropsWithoutRef, FC } from 'react' + +type Props = ComponentPropsWithoutRef<'svg'> + +export const DiamondFillIcon: FC = (props) => { + return ( + + + + ) +} diff --git a/frontend/packages/ui/src/icons/DiamondIcon.tsx b/frontend/packages/ui/src/icons/DiamondIcon.tsx new file mode 100644 index 000000000..e9cbc5466 --- /dev/null +++ b/frontend/packages/ui/src/icons/DiamondIcon.tsx @@ -0,0 +1,25 @@ +import type { ComponentPropsWithoutRef, FC } from 'react' + +type Props = ComponentPropsWithoutRef<'svg'> + +export const DiamondIcon: FC = (props) => { + return ( + + + + ) +} diff --git a/frontend/packages/ui/src/icons/index.ts b/frontend/packages/ui/src/icons/index.ts index b76e136aa..d9295fb67 100644 --- a/frontend/packages/ui/src/icons/index.ts +++ b/frontend/packages/ui/src/icons/index.ts @@ -2,4 +2,6 @@ export * from './InfoIcon' export * from './XIcon' export * from './FacebookIcon' export * from './LinkedInIcon' +export * from './DiamondIcon' +export * from './DiamondFillIcon' export { KeyRound } from 'lucide-react'