Skip to content

Conversation

@CodeShakingSheep
Copy link
Contributor

What does this PR do?

This PR allows self-hosted instances to set custom URLs for Terms and Privacy Policy by introducing two new .env vars NEXT_PUBLIC_WEBSITE_PRIVACY_POLICY_URL and NEXT_PUBLIC_WEBSITE_TERMS_URL. The custom URLs will then be displayed on the signup page as well as on the event booking form.

Signup page before
image
This was set to ${WEBSITE_URL}/terms (note the URL in the bottom left corner of the screenshot). While this page exists for the Cal.com platform it doesn't exist in the case of self-hosted instances which just led to a HTTP 404 error. See screenshot for terms URL (same applied to the privacy policy URL).
image

Signup page after (with custom URLs)
image
Note the link to custom terms in the bottom left corner when hovering over the terms link. Same applies to privacy policy link.

Signup page after (without custom URLs - fall back to Cal.com terms and privacy policy)
image
Note the link to Cal.com's terms in the bottom left corner when hovering over the terms link. Same applies to privacy policy link.

Event booking form before
image
There was no reference to terms and privacy policy at all (was removed in #13966).

Event booking form after (with custom URLs)
image
Note the link to custom terms in the bottom left corner when hovering over the terms link. Same applies to privacy policy link.

Event booking form after (without custom URLs - fall back to Cal.com terms and privacy policy)
image
Note the link to Cal.com's terms in the bottom left corner when hovering over the terms link. Same applies to privacy policy link.

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • I have added a Docs issue here if this PR makes changes that would require a documentation change. If N/A, write N/A here and check the checkbox.
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

How should this be tested?

Set the .env vars NEXT_PUBLIC_WEBSITE_PRIVACY_POLICY_URL and NEXT_PUBLIC_WEBSITE_TERMS_URL to any URL. Then visit

On both pages hover over the Termsand Privacy links and verify that they point to the URLs you set in .env (NEXT_PUBLIC_WEBSITE_PRIVACY_POLICY_URL and NEXT_PUBLIC_WEBSITE_TERMS_URL).

@vercel
Copy link

vercel bot commented Aug 25, 2024

@CodeShakingSheep is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to authorize it.

@graphite-app graphite-app bot added the community Created by Linear-GitHub Sync label Aug 25, 2024
@graphite-app graphite-app bot requested a review from a team August 25, 2024 14:40
@CLAassistant
Copy link

CLAassistant commented Aug 25, 2024

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot added booking-page area: booking page, public booking page, booker Low priority Created by Linear-GitHub Sync ✨ feature New feature or request labels Aug 25, 2024
@graphite-app
Copy link

graphite-app bot commented Aug 25, 2024

Graphite Automations

"Add consumer team as reviewer" took an action on this PR • (08/25/24)

1 reviewer was added to this PR based on Keith Williams's automation.

"Add community label" took an action on this PR • (08/25/24)

1 label was added to this PR based on Keith Williams's automation.

Copy link
Contributor

@anikdhabal anikdhabal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice works @CodeShakingSheep , left commnets

Copy link
Contributor

@anikdhabal anikdhabal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!!

@github-actions
Copy link
Contributor

github-actions bot commented Aug 25, 2024

E2E results are ready!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

booking-page area: booking page, public booking page, booker community Created by Linear-GitHub Sync ❗️ .env changes contains changes to env variables ✨ feature New feature or request Low priority Created by Linear-GitHub Sync ready-for-e2e self-hosting

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CAL-3913] Privacy Link Change

4 participants