|
1
|
import { useTranslation } from "react-i18next" |
|
2
|
import { StatusCell } from "../../common/status-cell" |
|
3
|
|
|
4
|
type AccountCellProps = { |
|
5
|
hasAccount: boolean |
|
6
|
} |
|
7
|
|
|
8
|
export const AccountCell = ({ hasAccount }: AccountCellProps) => { |
|
9
|
const { t } = useTranslation() |
|
10
|
|
|
11
|
const color = hasAccount ? "green" : ("orange" as const) |
|
12
|
const text = hasAccount |
|
13
|
? t("customers.fields.registered") |
|
14
|
: t("customers.fields.guest") |
|
15
|
|
|
16
|
return <StatusCell color={color}>{text}</StatusCell> |
|
17
|
} |
|
18
|
|
|
19
|
export const AccountHeader = () => { |
|
20
|
const { t } = useTranslation() |
|
21
|
|
|
22
|
return ( |
|
23
|
<div className="flex h-full w-full items-center"> |
|
24
|
<span className="truncate">{t("fields.account")}</span> |
|
25
|
</div> |
|
26
|
) |
|
27
|
} |