Skip to content

fix: use LOGO_DARK constant for generic OG image instead of hardcoded value#27705

Merged
hbjORbj merged 8 commits intomainfrom
devin/1770380961-fix-generic-og-logo
Feb 6, 2026
Merged

fix: use LOGO_DARK constant for generic OG image instead of hardcoded value#27705
hbjORbj merged 8 commits intomainfrom
devin/1770380961-fix-generic-og-logo

Conversation

@hbjORbj
Copy link
Copy Markdown
Contributor

@hbjORbj hbjORbj commented Feb 6, 2026

What does this PR do?

Self-hosted Cal.com instances display the default Cal.com logo on OG images for "generic" type pages (login, etc.) because the generic entry in OG_ASSETS hardcoded "cal-logo-word-black.svg" as a raw string instead of referencing a constant.

This PR:

  1. Introduces a new LOGO_DARK constant in packages/lib/constants.ts pointing to /cal-logo-word-black.svg — preserving the darker logo for generic OG images on light backgrounds.
  2. Updates generic in OG_ASSETS to use LOGO_DARK ?? LOGO instead of the hardcoded string, so the file reference is a discoverable, replaceable constant.
  3. Adds 11 unit tests for the OgImages module covering getOGImageVersion, constructMeetingImage, constructAppImage, constructGenericImage, and branding consistency.

Logo strategy per OG type:

Type Logo constant Default file Background
meeting LOGO calcom-logo-white-word.svg dark
app LOGO calcom-logo-white-word.svg light
generic LOGO_DARK ?? LOGO cal-logo-word-black.svg light

Self-hosters who want full branding consistency should replace both calcom-logo-white-word.svg and cal-logo-word-black.svg.

Visual Demo

To demonstrate the fix, cal-logo-word-black.svg (the file referenced by LOGO_DARK) was replaced with a custom logo to simulate a self-hosted instance.

Default generic OG image (no custom logo):

Default generic OG

After replacing cal-logo-word-black.svg with custom logo — generic OG picks up the change:

Generic OG with custom logo

Meeting OG remains unaffected (uses LOGO, not LOGO_DARK):

Meeting OG still uses LOGO

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • I have updated the developer docs in /docs if this PR makes changes that would require a documentation change. N/A
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

@paragon-review
Copy link
Copy Markdown

paragon-review bot commented Feb 6, 2026

Paragon Review Unavailable

Hi @hbjORbj! You are not toggled active by your team. Reach out to your admin.

@devin-ai-integration
Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR that start with 'DevinAI' or '@devin'.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@pull-request-size pull-request-size bot added size/L and removed size/XS labels Feb 6, 2026
@github-actions github-actions bot added the 🐛 bug Something isn't working label Feb 6, 2026
@devin-ai-integration devin-ai-integration bot changed the title fix: use LOGO constant for generic OG image instead of hardcoded value fix: use LOGO_DARK constant for generic OG image instead of hardcoded value Feb 6, 2026
@hbjORbj hbjORbj marked this pull request as ready for review February 6, 2026 14:01
@hbjORbj hbjORbj enabled auto-merge (squash) February 6, 2026 14:01
@graphite-app graphite-app bot requested a review from a team February 6, 2026 14:01
@graphite-app graphite-app bot added foundation core area: core, team members only labels Feb 6, 2026
@hbjORbj hbjORbj requested a review from a team February 6, 2026 14:02
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 3 files

@hbjORbj hbjORbj merged commit a8ede77 into main Feb 6, 2026
56 of 57 checks passed
@hbjORbj hbjORbj deleted the devin/1770380961-fix-generic-og-logo branch February 6, 2026 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐛 bug Something isn't working core area: core, team members only foundation ready-for-e2e size/L

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] OG Image for "generic" type ignores custom LOGO constant, always shows Cal.com logo

2 participants