Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
🐛 Keep the Powered by wordmark loading from the page origin (#3470)
Luke Vellaef38c37d487d
diff --git a/apps/web/src/features/poll/components/poll-footer.tsx b/apps/web/src/features/poll/components/poll-footer.tsxindex e1460f065..59779105b 100644--- a/apps/web/src/features/poll/components/poll-footer.tsx+++ b/apps/web/src/features/poll/components/poll-footer.tsx@@ -9,6 +9,8 @@ import { DEFAULT_APP_NAME } from "@/features/branding/constants";import { usePoll } from "@/features/poll/client";import { Trans } from "@/i18n/client";+const LOGO_MASK = "url(/static/logo.svg) center / contain no-repeat";+/*** Footer for the participant-facing poll surfaces: the invite page, and the* admin page which previews it.@@ -79,10 +81,13 @@ function PoweredByLink({ className }: { className: string }) {}}><Trans i18nKey="poweredBy" defaults="Powered by" />- {/* The wordmark is masked so it inherits the pill's text color in both themes */}+ {/* The wordmark is masked so it inherits the pill's text color in both+ themes. The mask sits in an inline style because a url() in the+ stylesheet resolves against the asset host, not this page's origin. */}<spanaria-hidden="true"- className="h-3.5 w-[75px] bg-foreground [mask:url(/static/logo.svg)_no-repeat_center/contain]"+ className="h-3.5 w-[75px] bg-foreground"+ style={{ mask: LOGO_MASK, WebkitMask: LOGO_MASK }}/><span className="sr-only"> {DEFAULT_APP_NAME}</span></Link>diff --git a/apps/web/src/features/poll/vote/components/powered-by-link.tsx b/apps/web/src/features/poll/vote/components/powered-by-link.tsxindex d70396a88..c9113a266 100644--- a/apps/web/src/features/poll/vote/components/powered-by-link.tsx+++ b/apps/web/src/features/poll/vote/components/powered-by-link.tsx@@ -4,6 +4,8 @@ import { Link } from "@/components/link";import { DEFAULT_APP_NAME } from "@/features/branding/constants";import { Trans } from "@/i18n/client";+const LOGO_MASK = "url(/static/logo.svg) center / contain no-repeat";+/** The attribution pill. Client only because the click is tracked. */export function PoweredByLink({pollId,@@ -28,10 +30,13 @@ export function PoweredByLink({}}><Trans i18nKey="poweredBy" defaults="Powered by" />- {/* The wordmark is masked so it inherits the pill's text color in both themes */}+ {/* The wordmark is masked so it inherits the pill's text color in both+ themes. The mask sits in an inline style because a url() in the+ stylesheet resolves against the asset host, not this page's origin. */}<spanaria-hidden="true"- className="h-3.5 w-[75px] bg-foreground [mask:url(/static/logo.svg)_no-repeat_center/contain]"+ className="h-3.5 w-[75px] bg-foreground"+ style={{ mask: LOGO_MASK, WebkitMask: LOGO_MASK }}/><span className="sr-only"> {DEFAULT_APP_NAME}</span></Link>