UNPKG

@sanity/scheduled-publishing

Version:

> [!IMPORTANT] > As of [v3.39.0](https://www.sanity.io/changelog/e6013ee5-8214-4e03-9593-f7b19124b8a3) of Sanity Studio, this plugin has been deprecated and the Scheduled Publishing functionality has been moved into the core studio package. > Read more an

24 lines (19 loc) 597 B
import DialogScheduleEdit from '../components/dialogs/DialogScheduleEdit' import {Schedule} from '../types' import {useDialogVisible} from './useDialogVisibile' // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types function useDialogScheduleEdit(schedule: Schedule) { const {visible, show, hide} = useDialogVisible() const dialogProps = { onClose: hide, schedule, visible, } return { DialogScheduleEdit: visible ? DialogScheduleEdit : null, dialogProps, dialogScheduleEditShow: show, hide, } } export default useDialogScheduleEdit