Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Fix formatted text not respecting theme in bounties embed (#3796)

Pedro Ladeirad0e39df56d4e
diff --git a/apps/web/app/(ee)/app.dub.co/embed/referrals/bounties/detail.tsx b/apps/web/app/(ee)/app.dub.co/embed/referrals/bounties/detail.tsx
index 1846ec8313..2c560f23a8 100644
--- a/apps/web/app/(ee)/app.dub.co/embed/referrals/bounties/detail.tsx
+++ b/apps/web/app/(ee)/app.dub.co/embed/referrals/bounties/detail.tsx
@@ -186,7 +186,7 @@ export function EmbedBountyDetail({
<div className="flex flex-col gap-6 text-sm">
<BountySubmissionRequirements bounty={bounty} />
<BountyRewardCriteria bounty={bounty} />
- <BountyDescription bounty={bounty} />
+ <BountyDescription bounty={bounty} embed />
</div>
</div>
diff --git a/apps/web/app/(ee)/app.dub.co/embed/referrals/faq.tsx b/apps/web/app/(ee)/app.dub.co/embed/referrals/faq.tsx
index dfbe104f96..d08c0b3da2 100644
--- a/apps/web/app/(ee)/app.dub.co/embed/referrals/faq.tsx
+++ b/apps/web/app/(ee)/app.dub.co/embed/referrals/faq.tsx
@@ -62,7 +62,7 @@ export function ReferralsEmbedFAQ() {
<h3 className="text-left text-sm sm:text-base">{item.title}</h3>
</AccordionTrigger>
<AccordionContent>
- <BlockMarkdown className="text-content-subtle py-2 text-left text-sm sm:text-base">
+ <BlockMarkdown className="text-content-subtle dark:prose-invert dark:prose-a:text-neutral-400 dark:hover:prose-a:text-neutral-300 dark:marker:prose-ul:text-neutral-400 py-2 text-left text-sm sm:text-base">
{item.content}
</BlockMarkdown>
</AccordionContent>
diff --git a/apps/web/ui/partners/bounties/bounty-description.tsx b/apps/web/ui/partners/bounties/bounty-description.tsx
index 82d51ff91e..75c96fcf82 100644
--- a/apps/web/ui/partners/bounties/bounty-description.tsx
+++ b/apps/web/ui/partners/bounties/bounty-description.tsx
@@ -3,7 +3,13 @@ import { Markdown } from "@/ui/shared/markdown";
import { PROSE_STYLES } from "@dub/ui";
import { cn } from "@dub/utils";
-export function BountyDescription({ bounty }: { bounty: PartnerBountyProps }) {
+export function BountyDescription({
+ bounty,
+ embed,
+}: {
+ bounty: PartnerBountyProps;
+ embed?: boolean;
+}) {
const description = bounty.description?.trim();
if (!description) {
@@ -21,6 +27,7 @@ export function BountyDescription({ bounty }: { bounty: PartnerBountyProps }) {
className={cn(
PROSE_STYLES.default,
"text-content-subtle text-sm font-normal",
+ embed && "dark:prose-invert dark:prose-a:text-neutral-100",
)}
>
{description}