Stablev0.1.0payment

TaiwanPaymentButton

本土支付按鈕

LINE Pay / JKO Pay 品牌規範按鈕,支援金額顯示、載入狀態、三種尺寸。

Branded payment buttons for Taiwan local payment providers including LINE Pay and JKO Pay with proper brand colors and loading states.

Installation

CLI

npx taiwan-ui add taiwan-payment-button

npm package

npm install @taiwan-ui/react

Live Demo

Props API

PropTypeDefault
provider*"linepay" | "jkopay" | "streetpay"
amountnumber
onClick*(provider: PaymentProvider) => void
loadingbooleanfalse
disabledbooleanfalse
size"sm" | "md" | "lg""md"
fullWidthbooleanfalse

Playground

Props

支付供應商

新台幣金額

顯示載入動畫

停用按鈕

按鈕尺寸

全寬按鈕

Generated code
import TaiwanPaymentButton from "@/components/taiwan/TaiwanPaymentButton";

export default function Example() {
  return (
    <TaiwanPaymentButton
  size="md"
/>
  );
}

Code Examples

import TaiwanPaymentButton from "@/components/taiwan/TaiwanPaymentButton";

export default function Checkout() {
  return (
    <TaiwanPaymentButton
      provider="linepay"
      amount={1250}
      onClick={(provider) => console.log(`Pay with ${provider}`)}
    />
  );
}
LINE PayJKO Pay3 尺寸branded

Related Components