2024-02-08 15:47:25 +08:00
|
|
|
import React from "react";
|
2024-02-11 22:19:24 +08:00
|
|
|
import { sendGAEvent } from "@next/third-parties/google";
|
2024-02-12 20:55:14 +08:00
|
|
|
//i18n
|
|
|
|
import { useTranslation } from "@/app/i18n/client";
|
2024-02-08 15:47:25 +08:00
|
|
|
// BuyVipButton 组件
|
2024-02-12 20:55:14 +08:00
|
|
|
function BuyVipButton({ lng }: { lng: string }) {
|
|
|
|
//i18n
|
|
|
|
const { t } = useTranslation(lng);
|
2024-02-08 15:47:25 +08:00
|
|
|
// 这是购买VIP的目标URL
|
2024-02-12 13:28:16 +08:00
|
|
|
const targetUrl = "https://store.paperai.life";
|
2024-02-08 15:47:25 +08:00
|
|
|
return (
|
|
|
|
<a href={targetUrl} target="_blank" className="no-underline">
|
2024-02-11 22:19:24 +08:00
|
|
|
<button
|
|
|
|
className="bg-gold text-white font-semibold text-lg py-2 px-4 rounded cursor-pointer border-none shadow-md transition duration-300 ease-in-out transform hover:scale-110"
|
|
|
|
onClick={() =>
|
|
|
|
sendGAEvent({ event: "buyVipButtonClicked", value: "buy vip" })
|
|
|
|
}
|
|
|
|
>
|
2024-02-12 20:55:14 +08:00
|
|
|
{t(
|
|
|
|
"Buy VIP TO UNLOCK Cloud Sync and Edit Mutiple Papers Simultaneously"
|
|
|
|
)}
|
2024-02-08 15:47:25 +08:00
|
|
|
</button>
|
|
|
|
</a>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
export default BuyVipButton;
|