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.

finalize ios ddl landing page

Steven Tey522888f1af57
diff --git a/apps/web/app/deeplink/[domain]/[key]/action-buttons.tsx b/apps/web/app/deeplink/[domain]/[key]/action-buttons.tsx
index 0ba7c24b4a..0efdedcf7e 100644
--- a/apps/web/app/deeplink/[domain]/[key]/action-buttons.tsx
+++ b/apps/web/app/deeplink/[domain]/[key]/action-buttons.tsx
@@ -1,31 +1,24 @@
"use client";
import { EdgeLinkProps } from "@/lib/planetscale";
-import { Button, IOSAppStore } from "@dub/ui";
-import { useState } from "react";
+import { Button, IOSAppStore, useCopyToClipboard } from "@dub/ui";
export function DeepLinkActionButtons({ link }: { link: EdgeLinkProps }) {
- const [copied, setCopied] = useState(false);
+ const [_copied, copyToClipboard] = useCopyToClipboard();
const handleClick = async ({ withCopy }: { withCopy?: boolean } = {}) => {
if (withCopy) {
- try {
- await navigator.clipboard.writeText(link.shortLink);
- setCopied(true);
- setTimeout(() => setCopied(false), 2000);
- } catch (err) {
- console.error("Failed to copy:", err);
- }
+ copyToClipboard(link.shortLink);
}
window.location.href = link.ios || link.url;
};
return (
- <div className="flex flex-col items-center gap-5">
+ <div className="flex flex-col items-center gap-4">
<Button
text="Get the App"
- className="h-12 w-full rounded-xl bg-neutral-900 text-white hover:bg-neutral-800"
+ className="h-12 w-full rounded-xl bg-neutral-900 text-white"
variant="primary"
onClick={() => handleClick({ withCopy: true })}
icon={<IOSAppStore className="size-6" />}
@@ -33,7 +26,7 @@ export function DeepLinkActionButtons({ link }: { link: EdgeLinkProps }) {
<button
onClick={() => handleClick()}
- className="text-base font-medium text-neutral-700 hover:text-neutral-900"
+ className="text-sm text-neutral-500"
>
Get the App without copying
</button>
diff --git a/apps/web/app/deeplink/[domain]/[key]/page.tsx b/apps/web/app/deeplink/[domain]/[key]/page.tsx
index d517a896ff..2863de6d22 100644
--- a/apps/web/app/deeplink/[domain]/[key]/page.tsx
+++ b/apps/web/app/deeplink/[domain]/[key]/page.tsx
@@ -1,7 +1,7 @@
import { getLinkViaEdge } from "@/lib/planetscale";
-import { Grid, LinkLogo, Wordmark } from "@dub/ui";
+import { Grid, Wordmark } from "@dub/ui";
import { ArrowRight, Copy, IOSAppStore, MobilePhone } from "@dub/ui/icons";
-import { cn, getApexDomain } from "@dub/utils";
+import { cn, getApexDomain, GOOGLE_FAVICON_URL } from "@dub/utils";
import Link from "next/link";
import { notFound } from "next/navigation";
import { DeepLinkActionButtons } from "./action-buttons";
@@ -63,7 +63,7 @@ export default async function DeepLinkPage({
<div className="relative z-10 flex flex-1 flex-col px-8 py-8">
<div className="flex justify-center">
<Link
- href="https://dub.co"
+ href="https://dub.co/docs/concepts/deep-links/quickstart"
target="_blank"
className="flex items-center gap-1 whitespace-nowrap text-sm font-medium text-neutral-900"
>
@@ -73,20 +73,20 @@ export default async function DeepLinkPage({
<div className="flex flex-1 flex-col justify-center gap-12">
<div className="flex flex-col items-center gap-y-6">
- <div className="flex flex-col items-center gap-4">
- <LinkLogo
- apexDomain={getApexDomain(link.url)}
- className="size-20 shrink-0"
+ <div className="inline-flex items-center gap-2 rounded-full bg-white p-1.5 shadow-lg shadow-black/10 ring-1 ring-neutral-200">
+ <img
+ src={`${GOOGLE_FAVICON_URL}${getApexDomain(link.url)}`}
+ className="size-8 shrink-0 overflow-visible rounded-full p-px"
/>
- <div className="text-xl font-semibold text-neutral-900">
+ <div className="pr-1.5 text-lg font-semibold text-neutral-900">
{getApexDomain(link.url)}
</div>
</div>
<div className="flex h-40 w-full max-w-xs flex-col gap-6 rounded-xl border border-neutral-300 px-10 py-8">
<p className="text-center text-sm font-normal leading-5 text-neutral-700">
- Clicking below will copy this page, and open it after you
- install the app.
+ Clicking below will copy this page and open it after you install
+ the app.
</p>
<div className="flex items-center justify-center gap-3">