'use client' import { memo } from 'react' import { PortalToFollowElem, PortalToFollowElemContent, PortalToFollowElemTrigger, } from '@/app/components/base/portal-to-follow-elem' import SettingContent from '@/app/components/base/features/new-feature-panel/file-upload/setting-content' import type { OnFeaturesChange } from '@/app/components/base/features/types' type FileUploadSettingsProps = { open: boolean onOpen: (state: any) => void onChange?: OnFeaturesChange disabled?: boolean children?: React.ReactNode imageUpload?: boolean } const FileUploadSettings = ({ open, onOpen, onChange, disabled, children, imageUpload, }: FileUploadSettingsProps) => { return ( !disabled && onOpen((open: boolean) => !open)}> {children}
onOpen(false)} onChange={(v) => { onChange?.(v) onOpen(false) }} />
) } export default memo(FileUploadSettings)