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.

UX improvements for bounty submissions

Steven Tey71761625ec99
diff --git a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/[bountyId]/bounty-submission-details-sheet.tsx b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/[bountyId]/bounty-submission-details-sheet.tsx
index 0f460c3130..50207a5d8c 100644
--- a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/[bountyId]/bounty-submission-details-sheet.tsx
+++ b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/[bountyId]/bounty-submission-details-sheet.tsx
@@ -323,9 +323,9 @@ function BountySubmissionDetailsSheetContent({
URLs
</h2>
<div className="mt-2 flex flex-col gap-2">
- {submission.urls?.map((url) => (
+ {submission.urls?.map((url, idx) => (
<div className="relative" key={url}>
- <div className="border-border-subtle block w-full rounded-lg border px-3 py-2 pr-12">
+ <div className="border-border-subtle block w-full rounded-lg border px-3 py-2 pl-10 pr-12">
<a
href={url}
target="_blank"
@@ -335,6 +335,11 @@ function BountySubmissionDetailsSheetContent({
{url}
</a>
</div>
+ <div className="absolute inset-y-0 left-0 flex items-center pl-2.5">
+ <div className="flex size-6 items-center justify-center rounded-full bg-neutral-100 text-xs font-medium text-neutral-600">
+ {idx + 1}
+ </div>
+ </div>
<div className="absolute inset-y-0 right-0 flex items-center pr-2.5">
<CopyButton
value={url}
diff --git a/apps/web/ui/partners/bounties/claim-bounty-modal.tsx b/apps/web/ui/partners/bounties/claim-bounty-modal.tsx
index 4400a9f8f7..32c71a1bf1 100644
--- a/apps/web/ui/partners/bounties/claim-bounty-modal.tsx
+++ b/apps/web/ui/partners/bounties/claim-bounty-modal.tsx
@@ -514,12 +514,16 @@ function ClaimBountyModalContent({ bounty }: ClaimBountyModalProps) {
<div>
<label
htmlFor="slug"
- className="flex items-center space-x-2"
+ className="flex items-center justify-between"
>
<h2 className="text-sm font-medium text-neutral-900">
URLs
{urlRequired && " (at least 1 required)"}
</h2>
+ <span className="text-xs font-medium text-neutral-500">
+ {urls.filter((u) => u.url).length} /{" "}
+ {BOUNTY_MAX_SUBMISSION_URLS}
+ </span>
</label>
<div className={cn("mt-2 flex flex-col gap-2")}>
{urls.map(({ id, url }, idx) => (