New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: wrong locale in attendee email ics #8945
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
📦 Next.js Bundle Analysis for @calcom/webThis analysis was generated by the Next.js Bundle Analysis action. 🤖 One Page Changed SizeThe following page changed size from the code in this PR compared to its base branch:
DetailsOnly the gzipped size is provided here based on an expert tip. First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If Any third party scripts you have added directly to your app using the The "Budget %" column shows what percentage of your performance budget the First Load total takes up. For example, if your budget was 100kb, and a given page's first load size was 10kb, it would be 10% of your budget. You can also see how much this has increased or decreased compared to the base branch of your PR. If this percentage has increased by 20% or more, there will be a red status indicator applied, indicating that special attention should be given to this. If you see "+/- <0.01%" it means that there was a change in bundle size, but it is a trivial enough amount that it can be ignored. |
Current Playwright Test Results Summary✅ 98 Passing - Run may still be in progress, this comment will be updated as current testing workflow or job completes... (Last updated on 05/22/2023 06:14:03am UTC) Run DetailsRunning Workflow PR Update on Github Actions Commit: 6c4203f Started: 05/22/2023 06:02:22am UTC
|
Test Case | Last 7 days Failures | Last 7 days Flakes |
---|---|---|
Event Types tests user -- old-booker can add new event type
Retry 1 • Initial Attempt |
0% (0)0 / 244 runsfailed over last 7 days |
1.23% (3)3 / 244 runsflaked over last 7 days |
📄 apps/web/playwright/booking-seats.e2e.ts • 2 Flakes
Top 1 Common Error Messages
|
2 Test Cases Affected |
Test Case Results
Test Case | Last 7 days Failures | Last 7 days Flakes |
---|---|---|
Booking with Seats -- new-booker Reschedule for booking with seats -- old-booker Should reschedule booking with seats and if everyone rescheduled it should be deleted
Retry 1 • Initial Attempt |
0% (0)0 / 248 runsfailed over last 7 days |
84.27% (209)209 / 248 runsflaked over last 7 days |
Booking with Seats -- old-booker Reschedule for booking with seats -- old-booker Should reschedule booking with seats and if everyone rescheduled it should be deleted
Retry 1 • Initial Attempt |
0% (0)0 / 248 runsfailed over last 7 days |
19.35% (48)48 / 248 runsflaked over last 7 days |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@G3root Can you fix the type error? Besides that, it looks good 👍
@CarinaWolli pushed some changes |
@@ -91,7 +91,7 @@ ${this.t("request_reschedule_subtitle", { | |||
})}, | |||
${this.getWhen()} | |||
${this.t("need_to_reschedule_or_cancel")} | |||
${getManageLink(this.calEvent)} | |||
${getManageLink(this.calEvent, this.calEvent.organizer.language.translate)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be the language of the attendee here?
Also, I tried to test it, and the whole request to reschedule email for the attendee was in the organizer's language. But this doesn't need to be fixed in this PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as per the current implementation i need to pass an instance of translate. should i keep this as it is and do a follow up PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's use this.t
as in the lines above. And then we still need a follow-up as this email is sent to the attendee but I think the organizer language is used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some comments
@@ -112,7 +112,7 @@ ${this.t( | |||
)} | |||
${this.t(subtitle)} | |||
|
|||
${getRichDescription(this.calEvent)} | |||
${getRichDescription(this.calEvent, this.attendee.language.translate)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
${getRichDescription(this.calEvent, this.attendee.language.translate)} | |
${getRichDescription(this.calEvent, this.t)} |
@@ -91,7 +91,7 @@ ${this.t("request_reschedule_subtitle", { | |||
})}, | |||
${this.getWhen()} | |||
${this.t("need_to_reschedule_or_cancel")} | |||
${getManageLink(this.calEvent)} | |||
${getManageLink(this.calEvent, this.calEvent.organizer.language.translate)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As per @CarinaWolli comment. Let's use the short notation here.
${getManageLink(this.calEvent, this.calEvent.organizer.language.translate)} | |
${getManageLink(this.calEvent, this.t)} |
@zomars @CarinaWolli pushed some changes to address the requested changes |
@@ -176,38 +177,40 @@ export const getRescheduleLink = (calEvent: CalendarEvent): string => { | |||
return `${WEBAPP_URL}/reschedule/${seatUid ? seatUid : Uid}`; | |||
}; | |||
|
|||
export const getRichDescription = (calEvent: CalendarEvent /*, attendee?: Person*/) => { | |||
export const getRichDescription = (calEvent: CalendarEvent, t_?: TFunction /*, attendee?: Person*/) => { | |||
const t = t_ ?? calEvent.organizer.language.translate; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would recommend making t_ required here so that from everywhere we are passing the language explicitly and it would avoid accidental use of organizer language for attendee if it's not passed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. I have just one suggestion
What does this PR do?
fixes the issue as mentioned in #8893
Type of change