cal.pub0.org/packages/app-store/office365video/components/AccountDialog.tsx

38 lines
1.1 KiB
TypeScript
Raw Normal View History

import type { DialogProps } from "@calcom/ui";
2022-12-01 00:11:59 +00:00
import { Button } from "@calcom/ui";
import { Dialog, DialogClose, DialogContent, DialogFooter } from "@calcom/ui";
import useAddAppMutation from "../../_utils/useAddAppMutation";
export function AccountDialog(props: DialogProps) {
const mutation = useAddAppMutation("office365_video");
return (
2022-12-01 00:11:59 +00:00
<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>
2022-12-01 00:11:59 +00:00
<>
<DialogClose
type="button"
color="secondary"
tabIndex={-1}
onClick={() => {
props.onOpenChange?.(false);
}}>
Cancel
</DialogClose>
2022-12-01 00:11:59 +00:00
<Button type="button" onClick={() => mutation.mutate("")}>
Continue
</Button>
</>
</DialogFooter>
</DialogContent>
</Dialog>
);
}
export default AccountDialog;