mirror of
https://github.com/langgenius/dify.git
synced 2026-04-23 16:37:44 +08:00
28 lines
682 B
TypeScript
28 lines
682 B
TypeScript
import { RiCloseLine } from '@remixicon/react'
|
|
import * as React from 'react'
|
|
import { useTranslation } from 'react-i18next'
|
|
|
|
type HeaderProps = {
|
|
onClose: () => void
|
|
}
|
|
|
|
const Header = ({
|
|
onClose,
|
|
}: HeaderProps) => {
|
|
const { t } = useTranslation()
|
|
|
|
return (
|
|
<div className="title-2xl-semi-bold relative flex items-center justify-between pb-3 pl-6 pr-14 pt-6 text-text-primary">
|
|
{t('app.importFromDSL')}
|
|
<div
|
|
className="absolute right-5 top-5 flex size-8 cursor-pointer items-center"
|
|
onClick={onClose}
|
|
>
|
|
<RiCloseLine className="size-[18px] text-text-tertiary" />
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|
|
|
|
export default React.memo(Header)
|