Scheduling infrastructure for absolutely everyone.
fix: typos in apps/web (#19194)
luzpaz15334ff20bc9
diff --git a/apps/web/components/layouts/_README.md b/apps/web/components/layouts/_README.mdindex 2291c3d14b3..b486d7e7666 100644--- a/apps/web/components/layouts/_README.md+++ b/apps/web/components/layouts/_README.md@@ -1,4 +1,4 @@-We don't have many layouts currently however, if they are relevant to a features - please put them in their relvant component folder+We don't have many layouts currently however, if they are relevant to a features - please put them in their relevant component folderin `web/components` if you believe they will be reused in other apps please place them in `packages/features/[feature]`Thanks Sean 🔥diff --git a/apps/web/getNextjsOrgRewriteConfig.js b/apps/web/getNextjsOrgRewriteConfig.jsindex ffb87f5e339..188a35514c2 100644--- a/apps/web/getNextjsOrgRewriteConfig.js+++ b/apps/web/getNextjsOrgRewriteConfig.js@@ -9,7 +9,7 @@ const orgSlugCaptureGroupName = "orgSlug";*/const getLeftMostSubdomain = (url) => {if (!url.startsWith("http:") && !url.startsWith("https:")) {- // Make it a valid URL. Mabe we can simply return null and opt-out from orgs support till the use a URL scheme.+ // Make it a valid URL. Maybe we can simply return null and opt-out from orgs support till the use a URL scheme.url = `https://${url}`;}const _url = new URL(url);diff --git a/apps/web/lib/app-providers-app-dir.tsx b/apps/web/lib/app-providers-app-dir.tsxindex 8e7367e0580..b6b8ebf9b20 100644--- a/apps/web/lib/app-providers-app-dir.tsx+++ b/apps/web/lib/app-providers-app-dir.tsx@@ -177,7 +177,7 @@ const CalcomThemeProvider = (props: CalcomThemeProps) => {* - There is a side effect of so many factors in `storageKey` that many localStorage keys will be created if a user goes through all these scenarios(e.g like booking a lot of different users)* - Some might recommend disabling localStorage persistence but that doesn't give good UX as then we would default to light theme always for a few seconds before switching to dark theme(if that's the user's preference).* - We can't disable [`storage`](https://developer.mozilla.org/en-US/docs/Web/API/Window/storage_event) event handling as well because changing theme in one tab won't change the theme without refresh in other tabs. That's again a bad UX- * - Theme flickering becomes infinitely ongoing in case of embeds because of the browser's delay in processing `storage` event within iframes. Consider two embeds simulatenously opened with pages A and B. Note the timeline and keep in mind that it happened+ * - Theme flickering becomes infinitely ongoing in case of embeds because of the browser's delay in processing `storage` event within iframes. Consider two embeds simultaneously opened with pages A and B. Note the timeline and keep in mind that it happened* because 'setItem(A)' and 'Receives storageEvent(A)' allowed executing setItem(B) in b/w because of the delay.* - t1 -> setItem(A) & Fires storageEvent(A) - On Page A) - Current State(A)* - t2 -> setItem(B) & Fires storageEvent(B) - On Page B) - Current State(B)diff --git a/apps/web/lib/app-providers.tsx b/apps/web/lib/app-providers.tsxindex 47466943731..b7dd650e2df 100644--- a/apps/web/lib/app-providers.tsx+++ b/apps/web/lib/app-providers.tsx@@ -190,7 +190,7 @@ const CalcomThemeProvider = (props: CalcomThemeProps) => {* - There is a side effect of so many factors in `storageKey` that many localStorage keys will be created if a user goes through all these scenarios(e.g like booking a lot of different users)* - Some might recommend disabling localStorage persistence but that doesn't give good UX as then we would default to light theme always for a few seconds before switching to dark theme(if that's the user's preference).* - We can't disable [`storage`](https://developer.mozilla.org/en-US/docs/Web/API/Window/storage_event) event handling as well because changing theme in one tab won't change the theme without refresh in other tabs. That's again a bad UX- * - Theme flickering becomes infinitely ongoing in case of embeds because of the browser's delay in processing `storage` event within iframes. Consider two embeds simulatenously opened with pages A and B. Note the timeline and keep in mind that it happened+ * - Theme flickering becomes infinitely ongoing in case of embeds because of the browser's delay in processing `storage` event within iframes. Consider two embeds simultaneously opened with pages A and B. Note the timeline and keep in mind that it happened* because 'setItem(A)' and 'Receives storageEvent(A)' allowed executing setItem(B) in b/w because of the delay.* - t1 -> setItem(A) & Fires storageEvent(A) - On Page A) - Current State(A)* - t2 -> setItem(B) & Fires storageEvent(B) - On Page B) - Current State(B)diff --git a/apps/web/lib/buildNonce.ts b/apps/web/lib/buildNonce.tsindex 211371dbc7c..1ceb721d917 100644--- a/apps/web/lib/buildNonce.ts+++ b/apps/web/lib/buildNonce.ts@@ -17,7 +17,7 @@ export const buildNonce = (uint8array: Uint8Array): string => {// for each random byte, we take:// a) only the last 6 bits (so we map them to the base64 alphabet)// b) for the last byte, we are interested in two bits- // explaination:+ // explanation:// 16*8 bits = 128 bits of information (order: left->right)// 22*6 bits = 132 bits (order: left->right)// thus the last byte has 4 redundant (least-significant, right-most) bitsdiff --git a/apps/web/lib/video/[uid]/getServerSideProps.ts b/apps/web/lib/video/[uid]/getServerSideProps.tsindex be979a7b54f..6047acf9834 100644--- a/apps/web/lib/video/[uid]/getServerSideProps.ts+++ b/apps/web/lib/video/[uid]/getServerSideProps.ts@@ -106,7 +106,7 @@ export async function getServerSideProps(context: GetServerSidePropsContext) {bookRef.meetingPassword = guestMeetingPassword;});}- // Only for backward compatibility and setting user id in particpants for organizer+ // Only for backward compatibility and setting user id in participants for organizerelse {const meetingPassword = await setEnableRecordingUIAndUserIdForOrganizer(oldVideoReference.id,diff --git a/apps/web/modules/auth/verify-email-change-view.tsx b/apps/web/modules/auth/verify-email-change-view.tsxindex ac98c665972..4d036821ce1 100644--- a/apps/web/modules/auth/verify-email-change-view.tsx+++ b/apps/web/modules/auth/verify-email-change-view.tsx@@ -34,7 +34,7 @@ function VerifyEmailChange(props: PageProps) {showToast(t("verify_email_change_failure_toast"), "error");}}- // We only need this to run on inital mount. These props can't and won't change due to it being fetched serveside.+ // We only need this to run on initial mount. These props can't and won't change due to it being fetched serverside.// eslint-disable-next-line react-hooks/exhaustive-deps}, []);diff --git a/apps/web/modules/settings/my-account/profile-view.tsx b/apps/web/modules/settings/my-account/profile-view.tsxindex e4d5e619e7d..5b252bc1201 100644--- a/apps/web/modules/settings/my-account/profile-view.tsx+++ b/apps/web/modules/settings/my-account/profile-view.tsx@@ -724,8 +724,8 @@ const ProfileForm = ({</div></div>)}- {/* // For Non-Cal indentities, we merge the values from DB and the user logging in,- so essentially there is no point in allowing them to disconnect, since when they log in they will get logged into the same account */}+ {/* // For Non-Cal identities, we merge the values from DB and the user logging in,+ so essentially there's no point in allowing them to disconnect, since when they log in they will get logged into the same account */}{!isCALIdentityProvider && user.email !== user.identityProviderEmail && (<div className="mt-6"><Label>Connected accounts</Label>diff --git a/apps/web/modules/signup-view.tsx b/apps/web/modules/signup-view.tsxindex f00a7fb0c0a..db6af1ce789 100644--- a/apps/web/modules/signup-view.tsx+++ b/apps/web/modules/signup-view.tsx@@ -44,7 +44,7 @@ import { Button, PasswordField, TextField, Form, Alert, CheckboxField, Icon, shoimport type { getServerSideProps } from "@lib/signup/getServerSideProps";const signupSchema = apiSignupSchema.extend({- apiError: z.string().optional(), // Needed to display API errors doesnt get passed to the API+ apiError: z.string().optional(), // Needed to display API errors doesn't get passed to the APIcfToken: z.string().optional(),});diff --git a/apps/web/pages/_document.tsx b/apps/web/pages/_document.tsxindex 6bbf4792dbd..2a561cf72f2 100644--- a/apps/web/pages/_document.tsx+++ b/apps/web/pages/_document.tsx@@ -14,7 +14,7 @@ function setHeader(ctx: NextPageContext, name: string, value: string) {try {ctx.res?.setHeader(name, value);} catch (e) {- // Getting "Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client" when revalidate calendar chache+ // Getting "Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client" when revalidate calendar cacheconsole.log(`Error setting header ${name}=${value} for ${ctx.asPath || "unknown asPath"}`, e);}}diff --git a/apps/web/pages/api/auth/verify-email.ts b/apps/web/pages/api/auth/verify-email.tsindex b900cf842b2..99dd4ef1c69 100644--- a/apps/web/pages/api/auth/verify-email.ts+++ b/apps/web/pages/api/auth/verify-email.ts@@ -88,7 +88,7 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)const userMetadataParsed = userMetadata.parse(user.metadata);// Attach the new email and verifyif (userMetadataParsed?.emailChangeWaitingForVerification) {- // Ensure this email isnt in use+ // Ensure this email isn't in useconst existingUser = await prisma.user.findUnique({where: { email: userMetadataParsed?.emailChangeWaitingForVerification },select: {diff --git a/apps/web/pages/api/teams/googleworkspace/add.ts b/apps/web/pages/api/teams/googleworkspace/add.tsindex fd4f9790585..cc220e83eaa 100644--- a/apps/web/pages/api/teams/googleworkspace/add.ts+++ b/apps/web/pages/api/teams/googleworkspace/add.ts@@ -18,7 +18,7 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)if (!client_secret || typeof client_secret !== "string")return res.status(400).json({ message: "Google client_secret missing." });- // use differnt callback to normal calendar connection+ // use different callback to normal calendar connectionconst redirect_uri = `${WEBAPP_URL}/api/teams/googleworkspace/callback`;const oAuth2Client = new OAuth2Client(client_id, client_secret, redirect_uri);diff --git a/apps/web/server/lib/setup/getServerSideProps.tsx b/apps/web/server/lib/setup/getServerSideProps.tsxindex b13b91205c3..1813c7985ab 100644--- a/apps/web/server/lib/setup/getServerSideProps.tsx+++ b/apps/web/server/lib/setup/getServerSideProps.tsx@@ -26,7 +26,7 @@ export async function getServerSideProps(context: GetServerSidePropsContext) {select: { licenseKey: true },});- // Check existant CALCOM_LICENSE_KEY env var and acccount for it+ // Check existent CALCOM_LICENSE_KEY env var and account for itif (!!process.env.CALCOM_LICENSE_KEY && !deploymentKey?.licenseKey) {await prisma.deployment.upsert({where: { id: 1 },diff --git a/apps/web/styles/raqb.css b/apps/web/styles/raqb.cssindex 1fdfd583117..6922627a1df 100644--- a/apps/web/styles/raqb.css+++ b/apps/web/styles/raqb.css@@ -11,18 +11,18 @@/* hide connectors */.cal-query-builder .group-or-rule::before,.cal-query-builder .group-or-rule::after {- /* !important to ensure that styles added by react-query-awesome-builder are overriden */+ /* !important to ensure that styles added by react-query-awesome-builder are overridden */content: unset !important;}.cal-query-builder .group--children {- /* !important to ensure that styles added by react-query-awesome-builder are overriden */+ /* !important to ensure that styles added by react-query-awesome-builder are overridden */padding-left: 0 !important;}/* Hide "and" for between numbers */.cal-query-builder .widget--sep {- /* !important to ensure that styles added by react-query-awesome-builder are overriden */+ /* !important to ensure that styles added by react-query-awesome-builder are overridden */display: none !important;}@@ -61,7 +61,7 @@display: flex;align-items: center;margin-right: 8px;- /* !important to ensure that styles added by react-query-awesome-builder are overriden */+ /* !important to ensure that styles added by react-query-awesome-builder are overridden */opacity: 1 !important;}diff --git a/apps/web/test/lib/checkBookingLimits.test.ts b/apps/web/test/lib/checkBookingLimits.test.tsindex 89c11fc80c2..c2e9ff0054d 100644--- a/apps/web/test/lib/checkBookingLimits.test.ts+++ b/apps/web/test/lib/checkBookingLimits.test.ts@@ -62,7 +62,7 @@ describe("Check Booking Limits Tests", () => {)).resolves.toBeTruthy();});- it("Should handle mutiple limits correctly", async () => {+ it("Should handle multiple limits correctly", async () => {prismaMock.booking.count.mockResolvedValue(1);expect(checkBookingLimit({diff --git a/apps/web/test/lib/getSchedule.test.ts b/apps/web/test/lib/getSchedule.test.tsindex 10f626fe569..0b57e66ce28 100644--- a/apps/web/test/lib/getSchedule.test.ts+++ b/apps/web/test/lib/getSchedule.test.ts@@ -1737,7 +1737,7 @@ describe("getSchedule", () => {[// `04:00:00.000Z`, // <- This slot should be occupied by the Pending Requires Confirmation booking blocking this slot`04:15:00.000Z`,- `05:00:00.000Z`, // <- This slot should be availble to book as this event type (id: 3) has requires confirmation without blocking the slo+ `05:00:00.000Z`, // <- This slot should be available to book as this event type (id: 3) has requires confirmation without blocking the slot`05:45:00.000Z`,`06:30:00.000Z`,`07:15:00.000Z`,@@ -2157,13 +2157,13 @@ describe("getSchedule", () => {});describe("Round robin event", async () => {- test("correctly get slots for event with round robin hosts choosen schedule (non-default)", async () => {+ test("correctly get slots for event with round robin hosts chosen schedule (non-default)", async () => {vi.setSystemTime("2024-05-21T00:00:13Z");const plus1DateString = "2024-05-22";const plus2DateString = "2024-05-23";- // An event with no common schedule and hosts choosen schedule (non-default schedule)+ // An event with no common schedule and hosts chosen schedule (non-default schedule)await createBookingScenario({eventTypes: [{@@ -2217,7 +2217,7 @@ describe("getSchedule", () => {},});- // expect only slots of IstEveningShift , as this is the choosen schedule for hosts+ // expect only slots of IstEveningShift , as this is the chosen schedule for hostsexpect(scheduleWithHostChoosenSch).toHaveTimeSlots([`11:30:00.000Z`, `12:30:00.000Z`, `13:30:00.000Z`, `14:30:00.000Z`, `15:30:00.000Z`],{@@ -2225,7 +2225,7 @@ describe("getSchedule", () => {});});- test("correctly get slots for event with commom schedule", async () => {+ test("correctly get slots for event with common schedule", async () => {vi.setSystemTime("2024-05-21T00:00:13Z");const plus1DateString = "2024-05-22";diff --git a/apps/web/test/utils/bookingScenario/expects.ts b/apps/web/test/utils/bookingScenario/expects.tsindex 901b2c7687d..7d36ffcef8d 100644--- a/apps/web/test/utils/bookingScenario/expects.ts+++ b/apps/web/test/utils/bookingScenario/expects.ts@@ -698,7 +698,7 @@ export function expectSuccessfulRoundRobinReschedulingEmails({}) {if (newOrganizer !== prevOrganizer) {vi.waitFor(() => {- // new organizer should recieve scheduling emails+ // new organizer should receive scheduling emailsexpect(emails).toHaveEmail({heading: "new_event_scheduled",@@ -709,7 +709,7 @@ export function expectSuccessfulRoundRobinReschedulingEmails({});vi.waitFor(() => {- // old organizer should recieve cancelled emails+ // old organizer should receive cancelled emailsexpect(emails).toHaveEmail({heading: "event_request_cancelled",@@ -720,7 +720,7 @@ export function expectSuccessfulRoundRobinReschedulingEmails({});} else {vi.waitFor(() => {- // organizer should recieve rescheduled emails+ // organizer should receive rescheduled emailsexpect(emails).toHaveEmail({heading: "event_has_been_rescheduled",