Files
cd952dc93c chore: decouple ui dialog from AppRouter and Atoms (#20088)
* chore: decouple ui dialog from AppRouter and Atoms

* fix type e2e test

* fix: import dialog from @calcom/ui/components/dialog

* fix: remove log

* fix unit test

* fix

* fix and move data-override-list test to features package

---------

Co-authored-by: hbjORbj <[email protected]>
2025-03-27 09:24:42 +02:00

40 lines
1.3 KiB
TypeScript

import type { DialogProps as ControlledDialogProps } from "@calcom/features/components/controlled-dialog";
import { Dialog } from "@calcom/features/components/controlled-dialog";
import { Button } from "@calcom/ui/components/button";
import { DialogContent, DialogFooter, DialogClose } from "@calcom/ui/components/dialog";
export function AccountDialog(
props: ControlledDialogProps & {
handleSubmit: () => void;
}
) {
return (
<Dialog name="Account check" open={props.open} onOpenChange={props.onOpenChange}>
<DialogContent
type="creation"
title="Connecting with MS Teams requires a work/school Microsoft account."
description="If you continue with a personal account you will receive an error">
<DialogFooter showDivider className="mt-6">
<>
<DialogClose
type="button"
color="secondary"
tabIndex={-1}
onClick={() => {
props.onOpenChange?.(false);
}}>
Cancel
</DialogClose>
<Button type="button" onClick={props.handleSubmit}>
Continue
</Button>
</>
</DialogFooter>
</DialogContent>
</Dialog>
);
}
export default AccountDialog;