Skip to content

Scheduling infrastructure for absolutely everyone.

Daily video calls (#542)

Lolaadee3fd21137
diff --git a/.env.example b/.env.example
index a7731d6b4c9..2a9bfb6b433 100644
--- a/.env.example
+++ b/.env.example
@@ -31,6 +31,9 @@ MS_GRAPH_CLIENT_SECRET=
ZOOM_CLIENT_ID=
ZOOM_CLIENT_SECRET=
+#Used for the Daily integration
+DAILY_API_KEY=
+
# E-mail settings
# Cal uses nodemailer (@see https://nodemailer.com/about/) to provide email sending. As such we are trying to
diff --git a/.vscode/launch.json b/.vscode/launch.json
new file mode 100644
index 00000000000..7a9dfa044d0
--- /dev/null
+++ b/.vscode/launch.json
@@ -0,0 +1,15 @@
+{
+ // Use IntelliSense to learn about possible attributes.
+ // Hover to view descriptions of existing attributes.
+ // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
+ "version": "0.2.0",
+ "configurations": [
+ {
+ "type": "pwa-chrome",
+ "request": "launch",
+ "name": "Launch Chrome against localhost",
+ "url": "http://localhost:8080",
+ "webRoot": "${workspaceFolder}"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/README.md b/README.md
index 3a7ba4783f3..86e200dd30f 100644
--- a/README.md
+++ b/README.md
@@ -283,6 +283,13 @@ Contributions are what make the open source community such an amazing place to b
12. Click "Done".
13. You're good to go. Now you can easily add your Zoom integration in the Cal.com settings.
+## Obtaining Daily API Credentials
+
+ 1. Open [Daily](https://www.daily.co/) and sign into your account.
+ 2. From within your dashboard, go to the [developers](https://dashboard.daily.co/developers) tab.
+ 3. Copy your API key.
+ 4. Now paste the API key to your .env file into the `DAILY_API_KEY` field in your .env file.
+
<!-- LICENSE -->
## License
diff --git a/components/booking/pages/BookingPage.tsx b/components/booking/pages/BookingPage.tsx
index 05ad3b96bb4..7d2cd156bde 100644
--- a/components/booking/pages/BookingPage.tsx
+++ b/components/booking/pages/BookingPage.tsx
@@ -71,6 +71,7 @@ const BookingPage = (props: BookingPageProps) => {
[LocationType.Phone]: "Phone call",
[LocationType.GoogleMeet]: "Google Meet",
[LocationType.Zoom]: "Zoom Video",
+ [LocationType.Daily]: "Daily.co Video",
};
const _bookingHandler = (event) => {
diff --git a/lib/CalEventParser.ts b/lib/CalEventParser.ts
index 54e9eb8386a..752dd158044 100644
--- a/lib/CalEventParser.ts
+++ b/lib/CalEventParser.ts
@@ -80,13 +80,17 @@ export default class CalEventParser {
/**
* Conditionally returns the event's location. When VideoCallData is set,
* it returns the meeting url. Otherwise, the regular location is returned.
- *
+ * For Daily video calls returns the direct link
* @protected
*/
protected getLocation(): string | undefined {
+ const isDaily = this.calEvent.location === "integrations:daily";
if (this.optionalVideoCallData) {
return this.optionalVideoCallData.url;
}
+ if (isDaily) {
+ return process.env.BASE_URL + "/call/" + this.getUid();
+ }
return this.calEvent.location;
}
diff --git a/lib/dailyVideoClient.ts b/lib/dailyVideoClient.ts
new file mode 100644
index 00000000000..4e37130c62d
--- /dev/null
+++ b/lib/dailyVideoClient.ts
@@ -0,0 +1,239 @@
+import { Credential } from "@prisma/client";
+import short from "short-uuid";
+import { v5 as uuidv5 } from "uuid";
+
+import CalEventParser from "@lib/CalEventParser";
+import { AdditionInformation, EntryPoint } from "@lib/emails/EventMail";
+import { getIntegrationName } from "@lib/emails/helpers";
+import { EventResult } from "@lib/events/EventManager";
+import logger from "@lib/logger";
+
+import { CalendarEvent } from "./calendarClient";
+import EventAttendeeRescheduledMail from "./emails/EventAttendeeRescheduledMail";
+import EventOrganizerRescheduledMail from "./emails/EventOrganizerRescheduledMail";
+import VideoEventAttendeeMail from "./emails/VideoEventAttendeeMail";
+import VideoEventOrganizerMail from "./emails/VideoEventOrganizerMail";
+
+const log = logger.getChildLogger({ prefix: ["[lib] dailyVideoClient"] });
+
+const translator = short();
+
+export interface DailyVideoCallData {
+ type: string;
+ id: string;
+ password: string;
+ url: string;
+}
+
+function handleErrorsJson(response) {
+ if (!response.ok) {
+ response.json().then(console.log);
+ throw Error(response.statusText);
+ }
+ return response.json();
+}
+
+const dailyCredential = process.env.DAILY_API_KEY;
+
+interface DailyVideoApiAdapter {
+ dailyCreateMeeting(event: CalendarEvent): Promise<any>;
+
+ dailyUpdateMeeting(uid: string, event: CalendarEvent);
+
+ dailyDeleteMeeting(uid: string): Promise<unknown>;
+
+ getAvailability(dateFrom, dateTo): Promise<any>;
+}
+
+const DailyVideo = (credential): DailyVideoApiAdapter => {
+ const translateEvent = (event: CalendarEvent) => {
+ // Documentation at: https://docs.daily.co/reference#list-rooms
+ // added a 1 hour buffer for room expiration and room entry
+ const exp = Math.round(new Date(event.endTime).getTime() / 1000) + 60 * 60;
+ const nbf = Math.round(new Date(event.startTime).getTime() / 1000) - 60 * 60;
+ return {
+ privacy: "private",
+ properties: {
+ enable_new_call_ui: true,
+ enable_prejoin_ui: true,
+ enable_knocking: true,
+ enable_screenshare: true,
+ enable_chat: true,
+ exp: exp,
+ nbf: nbf,
+ },
+ };
+ };
+
+ return {
+ getAvailability: () => {
+ return credential;
+ },
+ dailyCreateMeeting: (event: CalendarEvent) =>
+ fetch("https://api.daily.co/v1/rooms", {
+ method: "POST",
+ headers: {
+ Authorization: "Bearer " + dailyCredential,
+ "Content-Type": "application/json",
+ },
+ body: JSON.stringify(translateEvent(event)),
+ }).then(handleErrorsJson),
+ dailyDeleteMeeting: (uid: string) =>
+ fetch("https://api.daily.co/v1/rooms/" + uid, {
+ method: "DELETE",
+ headers: {
+ Authorization: "Bearer " + dailyCredential,
+ },
+ }).then(handleErrorsJson),
+ dailyUpdateMeeting: (uid: string, event: CalendarEvent) =>
+ fetch("https://api.daily.co/v1/rooms/" + uid, {
+ method: "POST",
+ headers: {
+ Authorization: "Bearer " + dailyCredential,
+ "Content-Type": "application/json",
+ },
+ body: JSON.stringify(translateEvent(event)),
+ }).then(handleErrorsJson),
+ };
+};
+
+// factory
+const videoIntegrations = (withCredentials): DailyVideoApiAdapter[] =>
+ withCredentials
+ .map((cred) => {
+ return DailyVideo(cred);
+ })
+ .filter(Boolean);
+
+const getBusyVideoTimes: (withCredentials) => Promise<unknown[]> = (withCredentials) =>
+ Promise.all(videoIntegrations(withCredentials).map((c) => c.getAvailability())).then((results) =>
+ results.reduce((acc, availability) => acc.concat(availability), [])
+ );
+
+const dailyCreateMeeting = async (
+ credential: Credential,
+ calEvent: CalendarEvent,
+ maybeUid: string = null
+): Promise<EventResult> => {
+ const parser: CalEventParser = new CalEventParser(calEvent, maybeUid);
+ const uid: string = parser.getUid();
+
+ if (!credential) {
+ throw new Error(
+ "Credentials must be set! Video platforms are optional, so this method shouldn't even be called when no video credentials are set."
+ );
+ }
+
+ let success = true;
+
+ const creationResult = await videoIntegrations([credential])[0]
+ .dailyCreateMeeting(calEvent)
+ .catch((e) => {
+ log.error("createMeeting failed", e, calEvent);
+ success = false;
+ });
+
+ const currentRoute = process.env.BASE_URL;
+
+ const videoCallData: DailyVideoCallData = {
+ type: "Daily.co Video",
+ id: creationResult.name,
+ password: creationResult.password,
+ url: currentRoute + "/call/" + uid,
+ };
+
+ const entryPoint: EntryPoint = {
+ entryPointType: getIntegrationName(videoCallData),
+ uri: videoCallData.url,
+ label: "Enter Meeting",
+ pin: "",
+ };
+
+ const additionInformation: AdditionInformation = {
+ entryPoints: [entryPoint],
+ };
+
+ const organizerMail = new VideoEventOrganizerMail(calEvent, uid, videoCallData, additionInformation);
+ const attendeeMail = new VideoEventAttendeeMail(calEvent, uid, videoCallData, additionInformation);
+
+ try {
+ await organizerMail.sendEmail();
+ } catch (e) {
+ console.error("organizerMail.sendEmail failed", e);
+ }
+
+ if (!creationResult || !creationResult.disableConfirmationEmail) {
+ try {
+ await attendeeMail.sendEmail();
+ } catch (e) {
+ console.error("attendeeMail.sendEmail failed", e);
+ }
+ }
+
+ return {
+ type: "daily",
+ success,
+ uid,
+ createdEvent: creationResult,
+ originalEvent: calEvent,
+ };
+};
+
+const dailyUpdateMeeting = async (
+ credential: Credential,
+ uidToUpdate: string,
+ calEvent: CalendarEvent
+): Promise<EventResult> => {
+ const newUid: string = translator.fromUUID(uuidv5(JSON.stringify(calEvent), uuidv5.URL));
+
+ if (!credential) {
+ throw new Error(
+ "Credentials must be set! Video platforms are optional, so this method shouldn't even be called when no video credentials are set."
+ );
+ }
+
+ let success = true;
+
+ const updateResult = credential
+ ? await videoIntegrations([credential])[0]
+ .dailyUpdateMeeting(uidToUpdate, calEvent)
+ .catch((e) => {
+ log.error("updateMeeting failed", e, calEvent);
+ success = false;
+ })
+ : null;
+
+ const organizerMail = new EventOrganizerRescheduledMail(calEvent, newUid);
+ const attendeeMail = new EventAttendeeRescheduledMail(calEvent, newUid);
+ try {
+ await organizerMail.sendEmail();
+ } catch (e) {
+ console.error("organizerMail.sendEmail failed", e);
+ }
+
+ if (!updateResult || !updateResult.disableConfirmationEmail) {
+ try {
+ await attendeeMail.sendEmail();
+ } catch (e) {
+ console.error("attendeeMail.sendEmail failed", e);
+ }
+ }
+
+ return {
+ type: credential.type,
+ success,
+ uid: newUid,
+ updatedEvent: updateResult,
+ originalEvent: calEvent,
+ };
+};
+
+const dailyDeleteMeeting = (credential: Credential, uid: string): Promise<unknown> => {
+ if (credential) {
+ return videoIntegrations([credential])[0].dailyDeleteMeeting(uid);
+ }
+
+ return Promise.resolve({});
+};
+
+export { getBusyVideoTimes, dailyCreateMeeting, dailyUpdateMeeting, dailyDeleteMeeting };
diff --git a/lib/emails/VideoEventAttendeeMail.ts b/lib/emails/VideoEventAttendeeMail.ts
index 372918a0aaf..26ea18d0890 100644
--- a/lib/emails/VideoEventAttendeeMail.ts
+++ b/lib/emails/VideoEventAttendeeMail.ts
@@ -25,11 +25,21 @@ export default class VideoEventAttendeeMail extends EventAttendeeMail {
* @protected
*/
protected getAdditionalBody(): string {
- return `
+ const meetingPassword = this.videoCallData.password;
+ const meetingId = getFormattedMeetingId(this.videoCallData);
+
+ if (meetingId && meetingPassword) {
+ return `
<strong>Video call provider:</strong> ${getIntegrationName(this.videoCallData)}<br />
<strong>Meeting ID:</strong> ${getFormattedMeetingId(this.videoCallData)}<br />
<strong>Meeting Password:</strong> ${this.videoCallData.password}<br />
<strong>Meeting URL:</strong> <a href="${this.videoCallData.url}">${this.videoCallData.url}</a><br />
`;
+ }
+
+ return `
+ <strong>Video call provider:</strong> ${getIntegrationName(this.videoCallData)}<br />
+ <strong>Meeting URL:</strong> <a href="${this.videoCallData.url}">${this.videoCallData.url}</a><br />
+ `;
}
}
diff --git a/lib/emails/VideoEventOrganizerMail.ts b/lib/emails/VideoEventOrganizerMail.ts
index 3c6528c2b4f..9a63a645d93 100644
--- a/lib/emails/VideoEventOrganizerMail.ts
+++ b/lib/emails/VideoEventOrganizerMail.ts
@@ -26,11 +26,19 @@ export default class VideoEventOrganizerMail extends EventOrganizerMail {
* @protected
*/
protected getAdditionalBody(): string {
+ const meetingPassword = this.videoCallData.password;
+ const meetingId = getFormattedMeetingId(this.videoCallData);
// This odd indentation is necessary because otherwise the leading tabs will be applied into the event description.
- return `
+ if (meetingPassword && meetingId) {
+ return `
<strong>Video call provider:</strong> ${getIntegrationName(this.videoCallData)}<br />
<strong>Meeting ID:</strong> ${getFormattedMeetingId(this.videoCallData)}<br />
<strong>Meeting Password:</strong> ${this.videoCallData.password}<br />
+<strong>Meeting URL:</strong> <a href="${this.videoCallData.url}">${this.videoCallData.url}</a><br />
+ `;
+ }
+ return `
+<strong>Video call provider:</strong> ${getIntegrationName(this.videoCallData)}<br />
<strong>Meeting URL:</strong> <a href="${this.videoCallData.url}">${this.videoCallData.url}</a><br />
`;
}
diff --git a/lib/events/EventManager.ts b/lib/events/EventManager.ts
index 436c1ba79a7..1c444fe67b3 100644
--- a/lib/events/EventManager.ts
+++ b/lib/events/EventManager.ts
@@ -4,6 +4,7 @@ import merge from "lodash.merge";
import { v5 as uuidv5 } from "uuid";
import { CalendarEvent, createEvent, updateEvent } from "@lib/calendarClient";
+import { dailyCreateMeeting, dailyUpdateMeeting } from "@lib/dailyVideoClient";
import EventAttendeeMail from "@lib/emails/EventAttendeeMail";
import EventAttendeeRescheduledMail from "@lib/emails/EventAttendeeRescheduledMail";
import { LocationType } from "@lib/location";
@@ -43,6 +44,9 @@ interface GetLocationRequestFromIntegrationRequest {
location: string;
}
+//const to idenfity a daily event location
+const dailyLocation = "integrations:daily";
+
export default class EventManager {
calendarCredentials: Array<Credential>;
videoCredentials: Array<Credential>;
@@ -55,6 +59,19 @@ export default class EventManager {
constructor(credentials: Array<Credential>) {
this.calendarCredentials = credentials.filter((cred) => cred.type.endsWith("_calendar"));
this.videoCredentials = credentials.filter((cred) => cred.type.endsWith("_video"));
+
+ //for Daily.co video, temporarily pushes a credential for the daily-video-client
+
+ const hasDailyIntegration = process.env.DAILY_API_KEY;
+ const dailyCredential: Credential = {
+ id: +new Date().getTime(),
+ type: "daily_video",
+ key: { apikey: process.env.DAILY_API_KEY },
+ userId: +new Date().getTime(),
+ };
+ if (hasDailyIntegration) {
+ this.videoCredentials.push(dailyCredential);
+ }
}
/**
@@ -91,13 +108,25 @@ export default class EventManager {
);
const referencesToCreate: Array<PartialReference> = results.map((result: EventResult) => {
- return {
- type: result.type,
- uid: result.createdEvent.id.toString(),
- meetingId: result.videoCallData?.id.toString(),
- meetingPassword: result.videoCallData?.password,
- meetingUrl: result.videoCallData?.url,
- };
+ const isDailyResult = result.type === "daily";
+ if (isDailyResult) {
+ return {
+ type: result.type,
+ uid: result.createdEvent.name.toString(),
+ meetingId: result.videoCallData?.id.toString(),
+ meetingPassword: result.videoCallData?.password,
+ meetingUrl: result.videoCallData?.url,
+ };
+ }
+ if (!isDailyResult) {
+ return {
+ type: result.type,
+ uid: result.createdEvent.id.toString(),
+ meetingId: result.videoCallData?.id.toString(),
+ meetingPassword: result.videoCallData?.password,
+ meetingUrl: result.videoCallData?.url,
+ };
+ }
});
return {
@@ -136,7 +165,8 @@ export default class EventManager {
},
});
- const isDedicated = EventManager.isDedicatedIntegration(event.location);
+ const isDedicated =
+ EventManager.isDedicatedIntegration(event.location) || event.location === dailyLocation;
let results: Array<EventResult> = [];
let optionalVideoCallData: VideoCallData | undefined = undefined;
@@ -198,6 +228,7 @@ export default class EventManager {
* @param optionalVideoCallData
* @private
*/
+
private createAllCalendarEvents(
event: CalendarEvent,
noMail: boolean,
@@ -215,8 +246,10 @@ export default class EventManager {
* @param event
* @private
*/
+
private getVideoCredential(event: CalendarEvent): Credential | undefined {
const integrationName = event.location.replace("integrations:", "");
+
return this.videoCredentials.find((credential: Credential) => credential.type.includes(integrationName));
}
@@ -232,8 +265,12 @@ export default class EventManager {
private createVideoEvent(event: CalendarEvent, maybeUid?: string): Promise<EventResult> {
const credential = this.getVideoCredential(event);
- if (credential) {
+ const isDaily = event.location === dailyLocation;
+
+ if (credential && !isDaily) {
return createMeeting(credential, event, maybeUid);
+ } else if (isDaily) {
+ return dailyCreateMeeting(credential, event, maybeUid);
} else {
return Promise.reject("No suitable credentials given for the requested integration name.");
}
@@ -271,8 +308,9 @@ export default class EventManager {
*/
private updateVideoEvent(event: CalendarEvent, booking: PartialBooking) {
const credential = this.getVideoCredential(event);
+ const isDaily = event.location === dailyLocation;
- if (credential) {
+ if (credential && !isDaily) {
const bookingRef = booking.references.filter((ref) => ref.type === credential.type)[0];
return updateMeeting(credential, bookingRef.uid, event).then((returnVal: EventResult) => {
@@ -283,6 +321,10 @@ export default class EventManager {
return returnVal;
});
} else {
+ if (isDaily) {
+ const bookingRefUid = booking.references.filter((ref) => ref.type === "daily")[0].uid;
+ return dailyUpdateMeeting(credential, bookingRefUid, event);
+ }
return Promise.reject("No suitable credentials given for the requested integration name.");
}
}
@@ -300,7 +342,8 @@ export default class EventManager {
*/
private static isDedicatedIntegration(location: string): boolean {
// Hard-coded for now, because Zoom and Google Meet are both integrations, but one is dedicated, the other one isn't.
- return location === "integrations:zoom";
+
+ return location === "integrations:zoom" || location === dailyLocation;
}
/**
@@ -313,7 +356,11 @@ export default class EventManager {
private static getLocationRequestFromIntegration(locationObj: GetLocationRequestFromIntegrationRequest) {
const location = locationObj.location;
- if (location === LocationType.GoogleMeet.valueOf() || location === LocationType.Zoom.valueOf()) {
+ if (
+ location === LocationType.GoogleMeet.valueOf() ||
+ location === LocationType.Zoom.valueOf() ||
+ location === LocationType.Daily.valueOf()
+ ) {
const requestId = uuidv5(location, uuidv5.URL);
return {
diff --git a/lib/integrations.ts b/lib/integrations.ts
index a088affd1ed..9b317555d50 100644
--- a/lib/integrations.ts
+++ b/lib/integrations.ts
@@ -12,8 +12,8 @@ export function getIntegrationName(name: string) {
return "Stripe";
case "apple_calendar":
return "Apple Calendar";
- default:
- return "Unknown";
+ case "daily_video":
+ return "Daily";
}
}
diff --git a/lib/location.ts b/lib/location.ts
index 3bd8f71fcf8..40ed53ce995 100644
--- a/lib/location.ts
+++ b/lib/location.ts
@@ -3,4 +3,5 @@ export enum LocationType {
Phone = "phone",
GoogleMeet = "integrations:google:meet",
Zoom = "integrations:zoom",
+ Daily = "integrations:daily",
}
diff --git a/package.json b/package.json
index b54e9d485b0..f003246f858 100644
--- a/package.json
+++ b/package.json
@@ -28,6 +28,7 @@
},
"dependencies": {
"@headlessui/react": "^1.4.1",
+ "@daily-co/daily-js": "^0.16.0",
"@heroicons/react": "^1.0.4",
"@hookform/resolvers": "^2.8.1",
"@jitsu/sdk-js": "^2.2.4",
@@ -84,6 +85,7 @@
"react-select": "^4.3.1",
"react-timezone-select": "^1.0.7",
"react-use-intercom": "1.4.0",
+ "react-router-dom": "^5.2.0",
"short-uuid": "^4.2.0",
"stripe": "^8.168.0",
"superjson": "1.7.5",
diff --git a/pages/api/book/event.ts b/pages/api/book/event.ts
index 89e03040ce1..a95d2ba7535 100644
--- a/pages/api/book/event.ts
+++ b/pages/api/book/event.ts
@@ -22,6 +22,13 @@ import { getBusyVideoTimes } from "@lib/videoClient";
import sendPayload from "@lib/webhooks/sendPayload";
import getSubscriberUrls from "@lib/webhooks/subscriberUrls";
+export interface DailyReturnType {
+ name: string;
+ url: string;
+ id: string;
+ created_at: string;
+}
+
dayjs.extend(dayjsBusinessDays);
dayjs.extend(utc);
dayjs.extend(isBetween);
@@ -249,7 +256,7 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
const attendeesList = [...invitee, ...guests, ...teamMembers];
- const seed = `${users[0].username}:${dayjs(reqBody.start).utc().format()}`;
+ const seed = `${users[0].username}:${dayjs(req.body.start).utc().format()}:${new Date().getTime()}`;
const uid = translator.fromUUID(uuidv5(seed, uuidv5.URL));
const evt: CalendarEvent = {
@@ -353,8 +360,9 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
selectedCalendars
);
- const videoBusyTimes = await getBusyVideoTimes(credentials);
+ const videoBusyTimes = (await getBusyVideoTimes(credentials)).filter((time) => time);
calendarBusyTimes.push(...videoBusyTimes);
+ console.log("calendarBusyTimes==>>>", calendarBusyTimes);
const bufferedBusyTimes: BufferedBusyTimes = calendarBusyTimes.map((a) => ({
start: dayjs(a.start).subtract(currentUser.bufferTime, "minute").toString(),
@@ -445,6 +453,46 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
}
}
+ //for Daily.co video calls will grab the meeting token for the call
+ const isDaily = evt.location === "integrations:daily";
+
+ let dailyEvent: DailyReturnType;
+
+ if (!rescheduleUid) {
+ dailyEvent = results.filter((ref) => ref.type === "daily")[0]?.createdEvent as DailyReturnType;
+ } else {
+ dailyEvent = results.filter((ref) => ref.type === "daily_video")[0]?.updatedEvent as DailyReturnType;
+ }
+
+ let meetingToken;
+ if (isDaily) {
+ const response = await fetch("https://api.daily.co/v1/meeting-tokens", {
+ method: "POST",
+ body: JSON.stringify({ properties: { room_name: dailyEvent.name, is_owner: true } }),
+ headers: {
+ Authorization: "Bearer " + process.env.DAILY_API_KEY,
+ "Content-Type": "application/json",
+ },
+ });
+ meetingToken = await response.json();
+ }
+
+ //for Daily.co video calls will update the dailyEventReference table
+
+ if (isDaily) {
+ await prisma.dailyEventReference.create({
+ data: {
+ dailyurl: dailyEvent.url,
+ dailytoken: meetingToken.token,
+ booking: {
+ connect: {
+ uid: booking.uid,
+ },
+ },
+ },
+ });
+ }
+
if (eventType.requiresConfirmation && !rescheduleUid) {
await new EventOrganizerRequestMail(evt, uid).sendEmail();
}
diff --git a/pages/api/cancel.ts b/pages/api/cancel.ts
index 91a544e3c3d..4cb2020cda7 100644
--- a/pages/api/cancel.ts
+++ b/pages/api/cancel.ts
@@ -11,6 +11,8 @@ import { deleteMeeting } from "@lib/videoClient";
import sendPayload from "@lib/webhooks/sendPayload";
import getSubscriberUrls from "@lib/webhooks/subscriberUrls";
+import { dailyDeleteMeeting } from "../../lib/dailyVideoClient";
+
export default async function handler(req, res) {
// just bail if it not a DELETE
if (req.method !== "DELETE" && req.method !== "POST") {
@@ -37,6 +39,7 @@ export default async function handler(req, res) {
},
},
attendees: true,
+ location: true,
references: {
select: {
uid: true,
@@ -118,6 +121,13 @@ export default async function handler(req, res) {
return await deleteMeeting(credential, bookingRefUid);
}
}
+ //deleting a Daily meeting
+
+ const isDaily = bookingToDelete.location === "integrations:daily";
+ const bookingUID = bookingToDelete.references.filter((ref) => ref.type === "daily")[0]?.uid;
+ if (isDaily) {
+ return await dailyDeleteMeeting(credential, bookingUID);
+ }
});
if (bookingToDelete && bookingToDelete.paid) {
diff --git a/pages/call/[uid].tsx b/pages/call/[uid].tsx
new file mode 100644
index 00000000000..b073311c5d0
--- /dev/null
+++ b/pages/call/[uid].tsx
@@ -0,0 +1,90 @@
+import DailyIframe from "@daily-co/daily-js";
+import { getSession } from "next-auth/client";
+import { useRouter } from "next/router";
+import { useEffect } from "react";
+
+import prisma from "../../lib/prisma";
+
+export default function JoinCall(props, session) {
+ const router = useRouter();
+
+ //if no booking redirectis to the 404 page
+ const emptyBooking = props.booking === null;
+ useEffect(() => {
+ if (emptyBooking) {
+ router.push("/call/no-meeting-found");
+ }
+ });
+
+ useEffect(() => {
+ if (!emptyBooking && session.userid !== props.booking.user.id) {
+ const callFrame = DailyIframe.createFrame({
+ showLeaveButton: true,
+ iframeStyle: {
+ position: "fixed",
+ width: "100%",
+ height: "100%",
+ },
+ });
+ callFrame.join({
+ url: props.booking.dailyRef.dailyurl,
+ showLeaveButton: true,
+ });
+ }
+ if (!emptyBooking && session.userid === props.booking.user.id) {
+ const callFrame = DailyIframe.createFrame({
+ showLeaveButton: true,
+ iframeStyle: {
+ position: "fixed",
+ width: "100%",
+ height: "100%",
+ },
+ });
+ callFrame.join({
+ url: props.booking.dailyRef.dailyurl,
+ showLeaveButton: true,
+ token: props.booking.dailyRef.dailytoken,
+ });
+ }
+ }, []);
+
+ return JoinCall;
+}
+
+export async function getServerSideProps(context) {
+ const booking = await prisma.booking.findFirst({
+ where: {
+ uid: context.query.uid,
+ },
+ select: {
+ id: true,
+ user: {
+ select: {
+ credentials: true,
+ },
+ },
+ attendees: true,
+ dailyRef: {
+ select: {
+ dailyurl: true,
+ dailytoken: true,
+ },
+ },
+ references: {
+ select: {
+ uid: true,
+ type: true,
+ },
+ },
+ },
+ });
+
+ const session = await getSession();
+
+ return {
+ props: {
+ booking: booking,
+ session: session,
+ },
+ };
+}
diff --git a/pages/call/no-meeting-found.tsx b/pages/call/no-meeting-found.tsx
new file mode 100644
index 00000000000..4a1269037f7
--- /dev/null
+++ b/pages/call/no-meeting-found.tsx
@@ -0,0 +1,52 @@
+import { XIcon } from "@heroicons/react/outline";
+import { ArrowRightIcon } from "@heroicons/react/solid";
+
+import { HeadSeo } from "@components/seo/head-seo";
+import Button from "@components/ui/Button";
+
+export default function NoMeetingFound() {
+ return (
+ <div>
+ <HeadSeo title={`No meeting Found`} description={`No Meeting Found`} />
+ <main className="max-w-3xl mx-auto my-24">
+ <div className="fixed inset-0 z-50 overflow-y-auto">
+ <div className="flex items-end justify-center min-h-screen px-4 pt-4 pb-20 text-center sm:block sm:p-0">
+ <div className="fixed inset-0 my-4 transition-opacity sm:my-0" aria-hidden="true">
+ <span className="hidden sm:inline-block sm:align-middle sm:h-screen" aria-hidden="true">
+ &#8203;
+ </span>
+ <div
+ className="inline-block px-4 pt-5 pb-4 overflow-hidden text-left align-bottom transition-all transform bg-white rounded-lg shadow-xl sm:my-8 sm:align-middle sm:max-w-sm sm:w-full sm:p-6"
+ role="dialog"
+ aria-modal="true"
+ aria-labelledby="modal-headline">
+ <div>
+ <div className="flex items-center justify-center w-12 h-12 mx-auto bg-red-100 rounded-full">
+ <XIcon className="w-6 h-6 text-red-600" />
+ </div>
+ <div className="mt-3 text-center sm:mt-5">
+ <h3 className="text-lg font-medium leading-6 text-gray-900" id="modal-headline">
+ No Meeting Found
+ </h3>
+ </div>
+ <div className="mt-2">
+ <p className="text-sm text-center text-gray-500">
+ This meeting does not exist. Contact the meeting owner for an updated link.
+ </p>
+ </div>
+ </div>
+ <div className="mt-5 text-center sm:mt-6">
+ <div className="mt-5">
+ <Button data-testid="return-home" href="/event-types" EndIcon={ArrowRightIcon}>
+ Go back home
+ </Button>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </main>
+ </div>
+ );
+}
diff --git a/pages/event-types/[type].tsx b/pages/event-types/[type].tsx
index 218c17785e5..450c2e26902 100644
--- a/pages/event-types/[type].tsx
+++ b/pages/event-types/[type].tsx
@@ -270,6 +270,8 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
return <p className="text-sm">Cal will provide a Google Meet location.</p>;
case LocationType.Zoom:
return <p className="text-sm">Cal will provide a Zoom meeting URL.</p>;
+ case LocationType.Daily:
+ return <p className="text-sm">Cal will provide a video meeting URL.</p>;
}
return null;
};
@@ -327,14 +329,14 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
name="title"
id="title"
required
- className="pl-0 w-full text-xl font-bold focus:text-black text-gray-500 hover:text-gray-700 bg-transparent border-none cursor-pointer focus:ring-0 focus:outline-none"
+ className="w-full pl-0 text-xl font-bold text-gray-500 bg-transparent border-none cursor-pointer focus:text-black hover:text-gray-700 focus:ring-0 focus:outline-none"
placeholder="Quick Chat"
defaultValue={eventType.title}
/>
{editIcon && (
<PencilAltIcon
style={{ top: 14, left: `${eventType.title.length * 10 + 8}` }}
- className="group-hover:text-gray-700 text-gray-500 absolute left-0 w-4 h-4 inline"
+ className="absolute left-0 inline w-4 h-4 text-gray-500 group-hover:text-gray-700"
/>
)}
</div>
@@ -456,6 +458,51 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
<span className="ml-2 text-sm">Google Meet</span>
</div>
)}
+ {location.type === LocationType.Daily && (
+ <div className="flex flex-grow">
+ <svg
+ id="svg"
+ version="1.1"
+ xmlns="http://www.w3.org/2000/svg"
+ width="1.25em"
+ height="1.25em"
+ viewBox="0, 0, 400,400">
+ <g id="svgg">
+ <path
+ id="path0"
+ d="M100.400 142.062 C 99.630 142.280,98.394 143.076,97.654 143.830 C 96.914 144.583,95.997 145.200,95.616 145.200 C 94.776 145.200,93.802 146.248,93.389 147.598 C 93.221 148.147,92.560 149.054,91.919 149.613 C 90.024 151.267,90.020 151.390,90.010 199.645 C 89.999 248.545,90.014 248.945,91.940 250.744 C 92.571 251.334,93.229 252.262,93.401 252.808 C 93.751 253.916,95.054 255.200,95.829 255.200 C 96.107 255.200,96.710 255.808,97.169 256.550 C 98.373 258.498,94.832 258.400,164.273 258.400 C 231.741 258.400,231.099 258.418,231.949 256.552 C 232.208 255.983,233.149 255.250,234.197 254.801 C 235.357 254.304,236.005 253.774,236.014 253.314 C 236.021 252.921,236.375 251.880,236.800 251.000 C 237.225 250.120,237.579 249.119,237.586 248.776 C 237.594 248.434,237.864 247.804,238.187 247.376 C 238.696 246.704,238.776 240.392,238.787 200.426 C 238.801 149.852,238.967 154.051,236.799 149.949 C 236.610 149.591,236.332 148.647,236.183 147.850 C 235.956 146.640,235.591 146.227,233.964 145.342 C 232.893 144.759,231.907 143.938,231.774 143.518 C 231.641 143.098,231.052 142.539,230.466 142.277 C 229.079 141.657,102.567 141.447,100.400 142.062 "
+ stroke="none"
+ fill="#f9f9f9"
+ fillRule="evenodd"></path>
+ <path
+ id="path1"
+ d="M304.600 153.562 C 304.160 153.717,302.589 154.419,301.109 155.122 C 299.629 155.825,298.171 156.400,297.869 156.400 C 297.567 156.400,296.528 156.977,295.560 157.682 C 294.592 158.387,292.872 159.272,291.739 159.649 C 290.605 160.025,288.743 160.976,287.602 161.761 C 286.460 162.547,284.778 163.386,283.863 163.628 C 282.948 163.869,281.300 164.672,280.200 165.413 C 279.100 166.154,277.660 166.885,277.000 167.037 C 275.491 167.385,272.800 168.718,272.800 169.117 C 272.800 169.485,270.749 170.506,268.629 171.194 C 266.207 171.979,263.730 174.650,263.412 176.820 C 262.921 180.167,263.353 224.092,263.889 225.295 C 264.635 226.970,266.755 228.668,269.300 229.629 C 270.565 230.107,271.600 230.622,271.600 230.775 C 271.600 231.219,274.452 232.687,276.241 233.162 C 277.144 233.403,278.381 234.061,278.991 234.626 C 279.600 235.191,281.382 236.125,282.950 236.701 C 284.517 237.278,286.430 238.236,287.200 238.831 C 287.970 239.426,289.320 240.126,290.200 240.387 C 292.160 240.967,294.400 242.079,294.400 242.472 C 294.400 242.837,297.518 244.231,299.125 244.584 C 299.790 244.730,300.737 245.198,301.228 245.625 C 301.720 246.051,302.620 246.400,303.228 246.400 C 303.837 246.400,304.605 246.504,304.936 246.631 C 305.267 246.758,305.902 246.498,306.348 246.052 C 306.793 245.607,307.721 244.951,308.410 244.595 C 310.905 243.305,310.800 245.287,310.800 199.575 C 310.800 155.897,310.789 155.600,309.169 155.600 C 309.026 155.600,308.231 155.060,307.400 154.400 C 306.569 153.740,305.780 153.218,305.645 153.240 C 305.510 153.262,305.040 153.407,304.600 153.562 "
+ stroke="none"
+ fill="#1be7b8"
+ fillRule="evenodd"></path>
+ <path
+ id="path2"
+ d="M104.148 137.776 C 103.459 138.076,102.774 138.519,102.624 138.760 C 102.475 139.002,101.832 139.200,101.196 139.200 C 98.679 139.200,95.594 140.337,94.191 141.782 C 93.434 142.562,92.630 143.200,92.406 143.200 C 92.181 143.200,91.703 143.875,91.344 144.700 C 90.984 145.525,90.140 146.560,89.467 147.000 C 87.556 148.251,87.579 147.532,87.693 201.219 L 87.800 252.069 88.800 252.944 C 89.350 253.425,90.311 254.498,90.935 255.328 C 91.559 256.159,92.682 257.235,93.430 257.719 C 94.178 258.204,94.792 258.829,94.795 259.110 C 94.801 259.708,96.289 260.360,98.770 260.851 C 99.743 261.044,100.887 261.516,101.311 261.901 C 102.535 263.008,223.251 262.983,224.942 261.875 C 225.616 261.433,227.174 261.056,228.925 260.910 C 232.411 260.620,234.281 259.898,234.866 258.616 C 235.107 258.087,235.812 257.444,236.432 257.187 C 237.635 256.688,238.800 255.226,238.800 254.214 C 238.800 253.876,239.039 253.600,239.330 253.600 C 239.622 253.600,240.297 253.135,240.830 252.568 L 241.800 251.536 241.800 200.335 L 241.800 149.134 240.400 147.884 C 239.630 147.197,238.690 145.944,238.312 145.101 C 237.852 144.075,237.232 143.430,236.441 143.154 C 235.696 142.895,235.110 142.318,234.859 141.598 C 234.411 140.311,233.008 139.763,229.068 139.333 C 227.786 139.194,226.522 138.865,226.260 138.603 C 224.854 137.196,225.002 137.200,164.726 137.216 C 115.566 137.229,105.185 137.325,104.148 137.776 M230.299 140.581 C 231.013 140.751,232.363 141.600,233.299 142.466 C 234.235 143.333,235.488 144.338,236.085 144.699 C 236.684 145.061,237.282 145.862,237.419 146.487 C 237.556 147.110,238.076 148.110,238.574 148.710 C 240.721 151.291,240.592 148.280,240.713 198.600 C 240.829 246.814,240.750 249.650,239.248 251.152 C 238.800 251.600,238.071 252.676,237.629 253.543 C 237.187 254.410,236.187 255.514,235.407 255.995 C 234.628 256.477,233.798 257.231,233.563 257.670 C 232.125 260.355,229.256 260.458,160.200 260.300 C 96.040 260.154,98.009 260.223,96.185 258.055 C 95.663 257.435,94.598 256.495,93.818 255.964 C 93.037 255.434,92.310 254.730,92.202 254.400 C 92.094 254.070,91.396 253.117,90.652 252.283 C 88.728 250.126,88.809 252.440,88.804 199.526 C 88.800 148.835,88.746 150.246,90.767 148.075 C 91.445 147.347,92.000 146.583,92.000 146.379 C 92.000 145.965,94.367 143.600,94.781 143.600 C 94.926 143.600,95.721 142.979,96.550 142.220 C 97.645 141.217,98.567 140.772,99.928 140.589 C 100.958 140.450,101.980 140.273,102.200 140.195 C 103.020 139.904,229.052 140.284,230.299 140.581 M302.261 151.784 C 301.415 152.085,300.477 152.683,300.177 153.111 C 299.589 153.951,298.498 154.440,295.467 155.223 C 294.179 155.556,293.257 156.096,292.706 156.841 C 292.120 157.635,291.307 158.082,289.909 158.382 C 287.523 158.894,286.569 159.361,285.000 160.786 C 284.254 161.463,282.944 162.058,281.536 162.358 C 279.852 162.717,278.929 163.194,277.936 164.216 C 277.201 164.973,276.327 165.593,275.994 165.596 C 274.726 165.605,271.323 167.114,270.329 168.107 C 269.759 168.678,268.506 169.354,267.546 169.609 C 263.906 170.578,262.647 172.127,261.546 176.994 C 260.707 180.702,260.406 219.312,261.200 221.401 C 261.420 221.979,261.860 223.699,262.178 225.222 C 262.801 228.210,263.915 229.763,265.769 230.228 C 266.340 230.371,266.906 230.649,267.027 230.844 C 267.148 231.040,267.598 231.200,268.028 231.200 C 268.457 231.200,269.121 231.575,269.504 232.034 C 270.324 233.017,272.827 234.231,274.800 234.604 C 275.626 234.760,276.610 235.349,277.200 236.040 C 277.950 236.919,278.976 237.422,281.300 238.052 C 283.242 238.578,284.400 239.096,284.400 239.438 C 284.400 240.158,287.095 241.510,289.201 241.847 C 290.693 242.085,292.400 243.256,292.400 244.041 C 292.400 244.329,297.174 246.000,297.997 246.000 C 298.233 246.000,299.057 246.630,299.827 247.400 C 301.156 248.729,301.366 248.800,303.981 248.800 L 306.736 248.800 309.338 246.578 C 312.714 243.696,312.469 247.711,312.322 197.737 L 312.200 156.074 310.962 154.537 C 308.533 151.521,305.601 150.593,302.261 151.784 M307.400 154.400 C 308.231 155.060,309.026 155.600,309.169 155.600 C 310.789 155.600,310.800 155.897,310.800 199.575 C 310.800 245.287,310.905 243.305,308.410 244.595 C 307.721 244.951,306.793 245.607,306.348 246.052 C 305.902 246.498,305.267 246.758,304.936 246.631 C 304.605 246.504,303.837 246.400,303.228 246.400 C 302.620 246.400,301.720 246.051,301.228 245.625 C 300.737 245.198,299.790 244.730,299.125 244.584 C 297.518 244.231,294.400 242.837,294.400 242.472 C 294.400 242.079,292.160 240.967,290.200 240.387 C 289.320 240.126,287.970 239.426,287.200 238.831 C 286.430 238.236,284.517 237.278,282.950 236.701 C 281.382 236.125,279.600 235.191,278.991 234.626 C 278.381 234.061,277.144 233.403,276.241 233.162 C 274.452 232.687,271.600 231.219,271.600 230.775 C 271.600 230.622,270.565 230.107,269.300 229.629 C 266.755 228.668,264.635 226.970,263.889 225.295 C 263.353 224.092,262.921 180.167,263.412 176.820 C 263.730 174.650,266.207 171.979,268.629 171.194 C 270.749 170.506,272.800 169.485,272.800 169.117 C 272.800 168.718,275.491 167.385,277.000 167.037 C 277.660 166.885,279.100 166.154,280.200 165.413 C 281.300 164.672,282.948 163.869,283.863 163.628 C 284.778 163.386,286.460 162.547,287.602 161.761 C 288.743 160.976,290.605 160.025,291.739 159.649 C 292.872 159.272,294.592 158.387,295.560 157.682 C 296.528 156.977,297.567 156.400,297.869 156.400 C 298.171 156.400,299.629 155.825,301.109 155.122 C 303.608 153.934,305.049 153.337,305.645 153.240 C 305.780 153.218,306.569 153.740,307.400 154.400 "
+ stroke="none"
+ fill="#4c545c"
+ fillRule="evenodd"></path>
+ <path
+ id="path3"
+ d="M102.200 140.195 C 101.980 140.273,100.958 140.450,99.928 140.589 C 98.567 140.772,97.645 141.217,96.550 142.220 C 95.721 142.979,94.926 143.600,94.781 143.600 C 94.367 143.600,92.000 145.965,92.000 146.379 C 92.000 146.583,91.445 147.347,90.767 148.075 C 88.746 150.246,88.800 148.835,88.804 199.526 C 88.809 252.440,88.728 250.126,90.652 252.283 C 91.396 253.117,92.094 254.070,92.202 254.400 C 92.310 254.730,93.037 255.434,93.818 255.964 C 94.598 256.495,95.663 257.435,96.185 258.055 C 98.009 260.223,96.040 260.154,160.200 260.300 C 229.256 260.458,232.125 260.355,233.563 257.670 C 233.798 257.231,234.628 256.477,235.407 255.995 C 236.187 255.514,237.187 254.410,237.629 253.543 C 238.071 252.676,238.800 251.600,239.248 251.152 C 240.750 249.650,240.829 246.814,240.713 198.600 C 240.592 148.280,240.721 151.291,238.574 148.710 C 238.076 148.110,237.556 147.110,237.419 146.487 C 237.282 145.862,236.684 145.061,236.085 144.699 C 235.488 144.338,234.235 143.333,233.299 142.466 C 232.363 141.600,231.013 140.751,230.299 140.581 C 229.052 140.284,103.020 139.904,102.200 140.195 M230.466 142.277 C 231.052 142.539,231.641 143.098,231.774 143.518 C 231.907 143.938,232.893 144.759,233.964 145.342 C 235.591 146.227,235.956 146.640,236.183 147.850 C 236.332 148.647,236.610 149.591,236.799 149.949 C 238.967 154.051,238.801 149.852,238.787 200.426 C 238.776 240.392,238.696 246.704,238.187 247.376 C 237.864 247.804,237.594 248.434,237.586 248.776 C 237.579 249.119,237.225 250.120,236.800 251.000 C 236.375 251.880,236.021 252.921,236.014 253.314 C 236.005 253.774,235.357 254.304,234.197 254.801 C 233.149 255.250,232.208 255.983,231.949 256.552 C 231.099 258.418,231.741 258.400,164.273 258.400 C 94.832 258.400,98.373 258.498,97.169 256.550 C 96.710 255.808,96.107 255.200,95.829 255.200 C 95.054 255.200,93.751 253.916,93.401 252.808 C 93.229 252.262,92.571 251.334,91.940 250.744 C 90.014 248.945,89.999 248.545,90.010 199.645 C 90.020 151.390,90.024 151.267,91.919 149.613 C 92.560 149.054,93.221 148.147,93.389 147.598 C 93.802 146.248,94.776 145.200,95.616 145.200 C 95.997 145.200,96.914 144.583,97.654 143.830 C 98.394 143.076,99.630 142.280,100.400 142.062 C 102.567 141.447,229.079 141.657,230.466 142.277 "
+ stroke="none"
+ fill="#949c9c"
+ fillRule="evenodd"></path>
+ <path
+ id="path4"
+ d="M35.200 0.984 C 35.200 1.947,35.121 1.971,31.700 2.084 L 28.200 2.200 28.077 3.900 L 27.954 5.600 25.403 5.600 C 21.914 5.600,20.903 6.043,20.590 7.712 C 20.367 8.902,20.142 9.103,18.669 9.430 C 17.102 9.777,16.988 9.898,16.800 11.400 C 16.605 12.956,16.554 13.003,14.922 13.122 C 13.260 13.243,13.243 13.260,13.122 14.922 C 13.003 16.554,12.956 16.605,11.400 16.800 C 9.898 16.988,9.777 17.102,9.430 18.669 C 9.103 20.142,8.902 20.367,7.712 20.590 C 6.043 20.903,5.600 21.914,5.600 25.403 L 5.600 27.954 3.900 28.077 L 2.200 28.200 2.084 31.700 C 1.971 35.121,1.947 35.200,0.984 35.200 L 0.000 35.200 0.000 200.000 L 0.000 364.800 0.984 364.800 C 1.947 364.800,1.971 364.879,2.084 368.300 L 2.200 371.800 3.900 372.177 L 5.600 372.554 5.600 374.851 C 5.600 378.083,6.072 379.102,7.712 379.410 C 8.902 379.633,9.103 379.858,9.430 381.331 C 9.777 382.898,9.898 383.012,11.400 383.200 C 12.953 383.394,13.004 383.449,13.121 385.059 C 13.247 386.786,13.757 387.181,15.876 387.195 C 16.598 387.199,16.773 387.463,16.876 388.700 C 16.992 390.104,17.107 390.224,18.669 390.570 C 20.142 390.897,20.367 391.098,20.590 392.288 C 20.903 393.957,21.914 394.400,25.403 394.400 L 27.954 394.400 28.077 396.100 L 28.200 397.800 31.700 397.916 C 35.121 398.029,35.200 398.053,35.200 399.016 L 35.200 400.000 200.000 400.000 L 364.800 400.000 364.800 399.016 C 364.800 398.053,364.879 398.029,368.300 397.916 L 371.800 397.800 372.177 396.100 L 372.554 394.400 375.103 394.400 C 378.233 394.400,379.094 393.974,379.414 392.265 C 379.633 391.101,379.865 390.896,381.331 390.570 C 382.893 390.224,383.008 390.104,383.124 388.700 C 383.241 387.288,383.327 387.200,384.596 387.200 C 386.308 387.200,387.200 386.308,387.200 384.596 C 387.200 383.327,387.288 383.241,388.700 383.124 C 390.104 383.008,390.224 382.893,390.570 381.331 C 390.896 379.865,391.101 379.633,392.265 379.414 C 393.974 379.094,394.400 378.233,394.400 375.103 L 394.400 372.554 396.100 372.177 L 397.800 371.800 397.916 368.300 C 398.029 364.879,398.053 364.800,399.016 364.800 L 400.000 364.800 400.000 200.000 L 400.000 35.200 399.016 35.200 C 398.053 35.200,398.029 35.121,397.916 31.700 L 397.800 28.200 396.100 28.077 L 394.400 27.954 394.400 25.403 C 394.400 21.914,393.957 20.903,392.288 20.590 C 391.098 20.367,390.897 20.142,390.570 18.669 C 390.224 17.107,390.104 16.992,388.700 16.876 C 387.463 16.773,387.199 16.598,387.195 15.876 C 387.181 13.757,386.786 13.247,385.059 13.121 C 383.452 13.004,383.396 12.953,383.275 11.480 C 383.121 9.617,382.265 9.200,378.597 9.200 L 376.046 9.200 375.923 7.500 C 375.802 5.821,375.779 5.798,374.173 5.681 C 372.616 5.566,372.529 5.488,372.173 3.881 L 371.800 2.200 368.300 2.084 C 364.879 1.971,364.800 1.947,364.800 0.984 L 364.800 0.000 200.000 0.000 L 35.200 0.000 35.200 0.984 M224.918 137.663 C 225.394 137.918,225.998 138.341,226.260 138.603 C 226.522 138.865,227.786 139.194,229.068 139.333 C 233.008 139.763,234.411 140.311,234.859 141.598 C 235.110 142.318,235.696 142.895,236.441 143.154 C 237.232 143.430,237.852 144.075,238.312 145.101 C 238.690 145.944,239.630 147.197,240.400 147.884 L 241.800 149.134 241.800 200.335 L 241.800 251.536 240.830 252.568 C 240.297 253.135,239.622 253.600,239.330 253.600 C 239.039 253.600,238.800 253.876,238.800 254.214 C 238.800 255.226,237.635 256.688,236.432 257.187 C 235.812 257.444,235.107 258.087,234.866 258.616 C 234.281 259.898,232.411 260.620,228.925 260.910 C 227.174 261.056,225.616 261.433,224.942 261.875 C 223.251 262.983,102.535 263.008,101.311 261.901 C 100.887 261.516,99.743 261.044,98.770 260.851 C 96.289 260.360,94.801 259.708,94.795 259.110 C 94.792 258.829,94.178 258.204,93.430 257.719 C 92.682 257.235,91.559 256.159,90.935 255.328 C 90.311 254.498,89.350 253.425,88.800 252.944 L 87.800 252.069 87.693 201.219 C 87.579 147.532,87.556 148.251,89.467 147.000 C 90.140 146.560,90.984 145.525,91.344 144.700 C 91.703 143.875,92.181 143.200,92.406 143.200 C 92.630 143.200,93.434 142.562,94.191 141.782 C 95.594 140.337,98.679 139.200,101.196 139.200 C 101.832 139.200,102.475 139.002,102.624 138.760 C 103.575 137.222,103.193 137.232,164.726 137.216 C 208.933 137.204,224.273 137.318,224.918 137.663 M308.162 152.107 C 309.021 152.598,310.281 153.692,310.962 154.537 L 312.200 156.074 312.322 197.737 C 312.469 247.711,312.714 243.696,309.338 246.578 L 306.736 248.800 303.981 248.800 C 301.366 248.800,301.156 248.729,299.827 247.400 C 299.057 246.630,298.233 246.000,297.997 246.000 C 297.174 246.000,292.400 244.329,292.400 244.041 C 292.400 243.256,290.693 242.085,289.201 241.847 C 287.095 241.510,284.400 240.158,284.400 239.438 C 284.400 239.096,283.242 238.578,281.300 238.052 C 278.976 237.422,277.950 236.919,277.200 236.040 C 276.610 235.349,275.626 234.760,274.800 234.604 C 272.827 234.231,270.324 233.017,269.504 232.034 C 269.121 231.575,268.457 231.200,268.028 231.200 C 267.598 231.200,267.148 231.040,267.027 230.844 C 266.906 230.649,266.340 230.371,265.769 230.228 C 263.915 229.763,262.801 228.210,262.178 225.222 C 261.860 223.699,261.420 221.979,261.200 221.401 C 260.406 219.312,260.707 180.702,261.546 176.994 C 262.647 172.127,263.906 170.578,267.546 169.609 C 268.506 169.354,269.759 168.678,270.329 168.107 C 271.323 167.114,274.726 165.605,275.994 165.596 C 276.327 165.593,277.201 164.973,277.936 164.216 C 278.929 163.194,279.852 162.717,281.536 162.358 C 282.944 162.058,284.254 161.463,285.000 160.786 C 286.569 159.361,287.523 158.894,289.909 158.382 C 291.307 158.082,292.120 157.635,292.706 156.841 C 293.257 156.096,294.179 155.556,295.467 155.223 C 298.498 154.440,299.589 153.951,300.177 153.111 C 301.487 151.241,305.719 150.709,308.162 152.107 "
+ stroke="none"
+ fill="#141c24"
+ fillRule="evenodd"></path>
+ </g>
+ </svg>
+ <span className="ml-2 text-sm"> Daily.co Video</span>
+ </div>
+ )}
{location.type === LocationType.Zoom && (
<div className="flex items-center flex-grow">
<svg
@@ -542,7 +589,7 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
<label
htmlFor="schedulingType"
className="flex mt-2 text-sm font-medium text-neutral-700">
- <UsersIcon className="text-neutral-500 h-5 w-5 mr-2" /> Scheduling Type
+ <UsersIcon className="w-5 h-5 mr-2 text-neutral-500" /> Scheduling Type
</label>
</div>
<RadioArea.Select
@@ -555,7 +602,7 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
<div className="block sm:flex">
<div className="mb-4 min-w-44 sm:mb-0">
<label htmlFor="users" className="flex mt-2 text-sm font-medium text-neutral-700">
- <UserAddIcon className="text-neutral-500 h-5 w-5 mr-2" /> Attendees
+ <UserAddIcon className="w-5 h-5 mr-2 text-neutral-500" /> Attendees
</label>
</div>
<div className="w-full space-y-2">
@@ -752,7 +799,7 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
<select
id=""
name="periodDaysType"
- className="block w-full py-2 pl-3 pr-10 text-base border-gray-300 rounded-sm focus:outline-none focus:ring-primary-500 focus:border-primary-500 sm:text-sm"
+ className="block w-full py-2 pl-3 pr-10 text-base border-gray-300 rounded-sm focus:outline-none focus:ring-primary-500 focus:border-primary-500 sm:text-sm"
defaultValue={
eventType.periodCountCalendarDays ? "1" : "0"
}>
@@ -807,17 +854,17 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
<>
<hr className="border-neutral-200" />
<div className="block sm:flex">
- <div className="min-w-44 mb-4 sm:mb-0">
+ <div className="mb-4 min-w-44 sm:mb-0">
<label
htmlFor="payment"
- className="text-sm flex font-medium text-neutral-700 mt-2">
+ className="flex mt-2 text-sm font-medium text-neutral-700">
Payment
</label>
</div>
<div className="flex flex-col">
<div className="w-full">
- <div className="block sm:flex items-center">
+ <div className="items-center block sm:flex">
<div className="w-full">
<div className="relative flex items-start">
<div className="flex items-center h-5">
@@ -826,7 +873,7 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
id="requirePayment"
name="requirePayment"
type="checkbox"
- className="focus:ring-primary-500 h-4 w-4 text-primary-600 border-gray-300 rounded"
+ className="w-4 h-4 border-gray-300 rounded focus:ring-primary-500 text-primary-600"
defaultChecked={requirePayment}
/>
</div>
@@ -849,22 +896,22 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
</div>
{requirePayment && (
<div className="w-full">
- <div className="block sm:flex items-center">
+ <div className="items-center block sm:flex">
<div className="w-full">
- <div className="mt-1 relative rounded-sm shadow-sm">
+ <div className="relative mt-1 rounded-sm shadow-sm">
<input
type="number"
name="price"
id="price"
step="0.01"
required
- className="focus:ring-primary-500 focus:border-primary-500 block w-full pl-2 pr-12 sm:text-sm border-gray-300 rounded-sm"
+ className="block w-full pl-2 pr-12 border-gray-300 rounded-sm focus:ring-primary-500 focus:border-primary-500 sm:text-sm"
placeholder="Price"
defaultValue={
eventType.price > 0 ? eventType.price / 100.0 : undefined
}
/>
- <div className="absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none">
+ <div className="absolute inset-y-0 right-0 flex items-center pr-3 pointer-events-none">
<span className="text-gray-500 sm:text-sm" id="duration">
{new Intl.NumberFormat("en", {
style: "currency",
@@ -1179,6 +1226,7 @@ export const getServerSideProps = async (context: GetServerSidePropsContext) =>
const locationOptions: OptionTypeBase[] = [
{ value: LocationType.InPerson, label: "Link or In-person meeting" },
{ value: LocationType.Phone, label: "Phone call" },
+ { value: LocationType.Zoom, label: "Zoom Video", disabled: true },
];
if (hasIntegration(integrations, "zoom_video")) {
@@ -1188,6 +1236,11 @@ export const getServerSideProps = async (context: GetServerSidePropsContext) =>
if (hasIntegration(integrations, "google_calendar")) {
locationOptions.push({ value: LocationType.GoogleMeet, label: "Google Meet" });
}
+ const hasDailyIntegration = process.env.DAILY_API_KEY;
+ if (hasDailyIntegration) {
+ locationOptions.push({ value: LocationType.Daily, label: "Daily.co Video" });
+ }
+
const currency =
(credentials.find((integration) => integration.type === "stripe_payment")?.key as unknown as StripeData)
?.default_currency || "usd";
diff --git a/prisma/migrations/20210908220336_add_daily_data_table/migration.sql b/prisma/migrations/20210908220336_add_daily_data_table/migration.sql
new file mode 100644
index 00000000000..ed36c926f0b
--- /dev/null
+++ b/prisma/migrations/20210908220336_add_daily_data_table/migration.sql
@@ -0,0 +1,15 @@
+-- CreateTable
+CREATE TABLE "DailyEventReference" (
+ "id" SERIAL NOT NULL,
+ "dailyurl" TEXT NOT NULL DEFAULT E'dailycallurl',
+ "dailytoken" TEXT NOT NULL DEFAULT E'dailytoken',
+ "bookingId" INTEGER,
+
+ PRIMARY KEY ("id")
+);
+
+-- CreateIndex
+CREATE UNIQUE INDEX "DailyEventReference_bookingId_unique" ON "DailyEventReference"("bookingId");
+
+-- AddForeignKey
+ALTER TABLE "DailyEventReference" ADD FOREIGN KEY ("bookingId") REFERENCES "Booking"("id") ON DELETE SET NULL ON UPDATE CASCADE;
diff --git a/prisma/schema.prisma b/prisma/schema.prisma
index ff3aea7b2b5..ffe55f7ccbf 100644
--- a/prisma/schema.prisma
+++ b/prisma/schema.prisma
@@ -162,6 +162,14 @@ enum BookingStatus {
PENDING @map("pending")
}
+model DailyEventReference {
+ id Int @id @default(autoincrement())
+ dailyurl String @default("dailycallurl")
+ dailytoken String @default("dailytoken")
+ booking Booking? @relation(fields: [bookingId], references: [id])
+ bookingId Int?
+}
+
model Booking {
id Int @id @default(autoincrement())
uid String @unique
@@ -179,6 +187,8 @@ model Booking {
attendees Attendee[]
location String?
+ dailyRef DailyEventReference?
+
createdAt DateTime @default(now())
updatedAt DateTime?
confirmed Boolean @default(true)
diff --git a/yarn.lock b/yarn.lock
index f005a4fe9f9..592bb7e2ecf 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -282,15 +282,17 @@
dependencies:
regenerator-runtime "^0.13.4"
-"@babel/runtime@^7.10.5", "@babel/runtime@^7.12.0", "@babel/runtime@^7.12.5", "@babel/runtime@^7.13.10", "@babel/runtime@^7.13.17", "@babel/runtime@^7.14.0", "@babel/runtime@^7.14.5", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.7", "@babel/runtime@^7.9.0":
+"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.5", "@babel/runtime@^7.12.0", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.13.10", "@babel/runtime@^7.13.17", "@babel/runtime@^7.14.0", "@babel/runtime@^7.14.5", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.7", "@babel/runtime@^7.9.0":
version "7.15.4"
- resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.15.4.tgz"
+ resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.15.4.tgz#fd17d16bfdf878e6dd02d19753a39fa8a8d9c84a"
+ integrity sha512-99catp6bHCaxr4sJ/DbTGgHS4+Rs2RVd2g7iOap6SLGPDknRK9ztKNsE/Fg6QhSeh1FGE5f6gHGQmvvn3I3xhw==
dependencies:
regenerator-runtime "^0.13.4"
"@babel/template@^7.12.13", "@babel/template@^7.15.4", "@babel/template@^7.3.3":
version "7.15.4"
- resolved "https://registry.npmjs.org/@babel/template/-/template-7.15.4.tgz"
+ resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.15.4.tgz#51898d35dcf3faa670c4ee6afcfd517ee139f194"
+ integrity sha512-UgBAfEa1oGuYgDIPM2G+aHa4Nlo9Lh6mGD2bDBGMTbYnc38vulXPuC1MGjYILIEmlwl6Rd+BPR9ee3gm20CBtg==
dependencies:
"@babel/code-frame" "^7.14.5"
"@babel/parser" "^7.15.4"
@@ -391,6 +393,17 @@
debug "^3.1.0"
lodash.once "^4.1.1"
+"@daily-co/daily-js@^0.16.0":
+ version "0.16.0"
+ resolved "https://registry.yarnpkg.com/@daily-co/daily-js/-/daily-js-0.16.0.tgz#9020104bb88de62dcc1966e713da65844243b9ab"
+ integrity sha512-DBWzbZs2IR7uYqfbABva1Ms3f/oX85dnQnCpVbGbexTN63LPIGknFSQp31ZYED88qcG+YJNydywBTb+ApNiNXA==
+ dependencies:
+ "@babel/runtime" "^7.12.5"
+ bowser "^2.8.1"
+ events "^3.1.0"
+ fast-equals "^1.6.3"
+ lodash "^4.17.15"
+
"@emotion/cache@^11.4.0":
version "11.4.0"
resolved "https://registry.npmjs.org/@emotion/cache/-/cache-11.4.0.tgz"
@@ -2478,6 +2491,11 @@ bn.js@^5.0.0, bn.js@^5.1.1:
version "5.2.0"
resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.0.tgz"
+bowser@^2.8.1:
+ version "2.11.0"
+ resolved "https://registry.yarnpkg.com/bowser/-/bowser-2.11.0.tgz#5ca3c35757a7aa5771500c70a73a9f91ef420a8f"
+ integrity sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA==
+
brace-expansion@^1.1.7:
version "1.1.11"
resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz"
@@ -3703,7 +3721,7 @@ eventemitter2@^6.4.3:
version "6.4.4"
resolved "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.4.tgz"
-events@^3.0.0:
+events@^3.0.0, events@^3.1.0:
version "3.3.0"
resolved "https://registry.npmjs.org/events/-/events-3.3.0.tgz"
@@ -3811,6 +3829,11 @@ fast-diff@^1.1.2:
version "1.2.0"
resolved "https://registry.npmjs.org/fast-diff/-/fast-diff-1.2.0.tgz"
+fast-equals@^1.6.3:
+ version "1.6.3"
+ resolved "https://registry.yarnpkg.com/fast-equals/-/fast-equals-1.6.3.tgz#84839a1ce20627c463e1892f2ae316380c81b459"
+ integrity sha512-4WKW0AL5+WEqO0zWavAfYGY1qwLsBgE//DN4TTcVEN2UlINgkv9b3vm2iHicoenWKSX9mKWmGOsU/iI5IST7pQ==
+
fast-glob@^3.1.1, fast-glob@^3.2.7:
version "3.2.7"
resolved "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.7.tgz"
@@ -4359,6 +4382,18 @@ highlight.js@^10.7.1:
version "10.7.3"
resolved "https://registry.npmjs.org/highlight.js/-/highlight.js-10.7.3.tgz"
+history@^4.9.0:
+ version "4.10.1"
+ resolved "https://registry.yarnpkg.com/history/-/history-4.10.1.tgz#33371a65e3a83b267434e2b3f3b1b4c58aad4cf3"
+ integrity sha512-36nwAD620w12kuzPAsyINPWJqlNbij+hpK1k9XRloDtym8mxzGYl2c17LnV6IAGB2Dmg4tEa7G7DlawS0+qjew==
+ dependencies:
+ "@babel/runtime" "^7.1.2"
+ loose-envify "^1.2.0"
+ resolve-pathname "^3.0.0"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+ value-equal "^1.0.1"
+
hmac-drbg@^1.0.1:
version "1.0.1"
resolved "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz"
@@ -4367,7 +4402,7 @@ hmac-drbg@^1.0.1:
minimalistic-assert "^1.0.0"
minimalistic-crypto-utils "^1.0.1"
-hoist-non-react-statics@^3.2.0, hoist-non-react-statics@^3.3.0, hoist-non-react-statics@^3.3.1, hoist-non-react-statics@^3.3.2:
+hoist-non-react-statics@^3.1.0, hoist-non-react-statics@^3.2.0, hoist-non-react-statics@^3.3.0, hoist-non-react-statics@^3.3.1, hoist-non-react-statics@^3.3.2:
version "3.3.2"
resolved "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz"
dependencies:
@@ -4826,6 +4861,11 @@ is-windows@^1.0.2:
resolved "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d"
integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==
+ version "0.0.1"
+ resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf"
+ integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=
+
isarray@^1.0.0, isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz"
@@ -5795,9 +5835,10 @@ lodash.truncate@^4.4.2:
version "4.4.2"
resolved "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz"
[email protected], [email protected], lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.7.0:
[email protected], [email protected], lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.7.0:
version "4.17.21"
- resolved "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz"
+ resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c"
+ integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==
log-symbols@^4.0.0, log-symbols@^4.1.0:
version "4.1.0"
@@ -5815,7 +5856,7 @@ log-update@^4.0.0:
slice-ansi "^4.0.0"
wrap-ansi "^6.2.0"
-loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0:
+loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.2.0, loose-envify@^1.3.1, loose-envify@^1.4.0:
version "1.4.0"
resolved "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz"
dependencies:
@@ -5949,6 +5990,14 @@ min-document@^2.19.0:
dependencies:
dom-walk "^0.1.0"
+mini-create-react-context@^0.4.0:
+ version "0.4.1"
+ resolved "https://registry.yarnpkg.com/mini-create-react-context/-/mini-create-react-context-0.4.1.tgz#072171561bfdc922da08a60c2197a497cc2d1d5e"
+ integrity sha512-YWCYEmd5CQeHGSAKrYvXgmzzkrvssZcuuQDDeqkT+PziKGMgE+0MCCtcKbROzocGBG1meBLl2FotlRwf4gAzbQ==
+ dependencies:
+ "@babel/runtime" "^7.12.1"
+ tiny-warning "^1.0.3"
+
mini-svg-data-uri@^1.2.3:
version "1.3.3"
resolved "https://registry.npmjs.org/mini-svg-data-uri/-/mini-svg-data-uri-1.3.3.tgz"
@@ -6613,6 +6662,13 @@ path-parse@^1.0.6:
version "1.0.7"
resolved "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz"
+path-to-regexp@^1.7.0:
+ version "1.8.0"
+ resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.8.0.tgz#887b3ba9d84393e87a0a0b9f4cb756198b53548a"
+ integrity sha512-n43JRhlUKUAlibEJhPeir1ncUID16QnEjNpwzNdO3Lm4ywrBpBZ5oLD0I6br9evr1Y9JTqwRtAh7JLoOzAQdVA==
+ dependencies:
+ isarray "0.0.1"
+
path-type@^3.0.0:
version "3.0.0"
resolved "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f"
@@ -7140,7 +7196,7 @@ [email protected], react-is@^17.0.1:
version "17.0.2"
resolved "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz"
-react-is@^16.7.0, react-is@^16.8.1:
+react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.1:
version "16.13.1"
resolved "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz"
@@ -7188,6 +7244,35 @@ react-remove-scroll@^2.4.0:
use-callback-ref "^1.2.3"
use-sidecar "^1.0.1"
+react-router-dom@^5.2.0:
+ version "5.3.0"
+ resolved "https://registry.yarnpkg.com/react-router-dom/-/react-router-dom-5.3.0.tgz#da1bfb535a0e89a712a93b97dd76f47ad1f32363"
+ integrity sha512-ObVBLjUZsphUUMVycibxgMdh5jJ1e3o+KpAZBVeHcNQZ4W+uUGGWsokurzlF4YOldQYRQL4y6yFRWM4m3svmuQ==
+ dependencies:
+ "@babel/runtime" "^7.12.13"
+ history "^4.9.0"
+ loose-envify "^1.3.1"
+ prop-types "^15.6.2"
+ react-router "5.2.1"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+
+ version "5.2.1"
+ resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.2.1.tgz#4d2e4e9d5ae9425091845b8dbc6d9d276239774d"
+ integrity sha512-lIboRiOtDLFdg1VTemMwud9vRVuOCZmUIT/7lUoZiSpPODiiH1UQlfXy+vPLC/7IWdFYnhRwAyNqA/+I7wnvKQ==
+ dependencies:
+ "@babel/runtime" "^7.12.13"
+ history "^4.9.0"
+ hoist-non-react-statics "^3.1.0"
+ loose-envify "^1.3.1"
+ mini-create-react-context "^0.4.0"
+ path-to-regexp "^1.7.0"
+ prop-types "^15.6.2"
+ react-is "^16.6.0"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+
react-select@^4.3.1:
version "4.3.1"
resolved "https://registry.npmjs.org/react-select/-/react-select-4.3.1.tgz"
@@ -7371,6 +7456,11 @@ resolve-from@^5.0.0:
version "5.0.0"
resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz"
+resolve-pathname@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/resolve-pathname/-/resolve-pathname-3.0.0.tgz#99d02224d3cf263689becbb393bc560313025dcd"
+ integrity sha512-C7rARubxI8bXFNB/hqcp/4iUeIXJhJZvFPFPiSPRnhU5UPxzMFIl+2E6yY6c4k9giDJAhtV+enfA+G89N6Csng==
+
resolve@^1.10.0, resolve@^1.20.0:
version "1.20.0"
resolved "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz"
@@ -8063,6 +8153,16 @@ timm@^1.6.1:
resolved "https://registry.npmjs.org/timm/-/timm-1.7.1.tgz#96bab60c7d45b5a10a8a4d0f0117c6b7e5aff76f"
integrity sha512-IjZc9KIotudix8bMaBW6QvMuq64BrJWFs1+4V0lXwWGQZwH+LnX87doAYhem4caOEusRP9/g6jVDQmZ8XOk1nw==
+tiny-invariant@^1.0.2:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/tiny-invariant/-/tiny-invariant-1.1.0.tgz#634c5f8efdc27714b7f386c35e6760991d230875"
+ integrity sha512-ytxQvrb1cPc9WBEI/HSeYYoGD0kWnGEOR8RY6KomWLBVhqz0RgTwVO9dLrGz7dC+nN9llyI7OKAgRq8Vq4ZBSw==
+
+tiny-warning@^1.0.0, tiny-warning@^1.0.3:
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754"
+ integrity sha512-lBN9zLN/oAf68o3zNXYrdCt1kP8WsiGW8Oo2ka41b2IM5JL/S1CTyX1rW0mb/zSuJun0ZUrDxx4sqvYS2FWzPA==
+
tinycolor2@^1.4.1:
version "1.4.2"
resolved "https://registry.npmjs.org/tinycolor2/-/tinycolor2-1.4.2.tgz#3f6a4d1071ad07676d7fa472e1fac40a719d8803"
@@ -8430,6 +8530,11 @@ validate-npm-package-license@^3.0.1:
spdx-correct "^3.0.0"
spdx-expression-parse "^3.0.0"
+value-equal@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/value-equal/-/value-equal-1.0.1.tgz#1e0b794c734c5c0cade179c437d356d931a34d6c"
+ integrity sha512-NOJ6JZCAWr0zlxZt+xqCHNTEKOsrks2HQd4MqhP1qy4z1SkbEP467eNx6TgDKXMvUOb+OENfJCZwM+16n7fRfw==
+
version "1.10.0"
resolved "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz"