refactor(web): reuse the same edit-custom-collection-modal component, and fix the pop up error (#28003)
This commit is contained in:
@@ -24,6 +24,7 @@ import Toast from '@/app/components/base/toast'
|
||||
|
||||
type Props = {
|
||||
positionLeft?: boolean
|
||||
dialogClassName?: string
|
||||
payload: any
|
||||
onHide: () => void
|
||||
onAdd?: (payload: CustomCollectionBackend) => void
|
||||
@@ -33,6 +34,7 @@ type Props = {
|
||||
// Add and Edit
|
||||
const EditCustomCollectionModal: FC<Props> = ({
|
||||
positionLeft,
|
||||
dialogClassName = '',
|
||||
payload,
|
||||
onHide,
|
||||
onAdd,
|
||||
@@ -186,6 +188,7 @@ const EditCustomCollectionModal: FC<Props> = ({
|
||||
positionCenter={isAdd && !positionLeft}
|
||||
onHide={onHide}
|
||||
title={t(`tools.createTool.${isAdd ? 'title' : 'editTitle'}`)!}
|
||||
dialogClassName={dialogClassName}
|
||||
panelClassName='mt-2 !w-[640px]'
|
||||
maxWidthClassName='!max-w-[640px]'
|
||||
height='calc(100vh - 16px)'
|
||||
|
||||
Reference in New Issue
Block a user