| 1234567891011121314151617181920212223 |
- import { RolesActionDialog } from './roles-action-dialog'
- import { RolesDeleteDialog } from './roles-delete-dialog'
- import { useRolesContext } from './roles-provider'
- export function RolesDialogs() {
- const { open, setOpen, currentRow, setCurrentRow } = useRolesContext()
- return (
- <>
- <RolesActionDialog />
- <RolesDeleteDialog
- open={open === 'delete'}
- onOpenChange={(state) => {
- if (!state) {
- setOpen(null)
- setCurrentRow(null)
- }
- }}
- currentRow={currentRow}
- />
- </>
- )
- }
|