Savva Sicevs

Swap Ticket

Component 28

About

A token swap widget for DEX and crypto wallet apps, with an editable amount, a flip button, a token picker and slippage settings. Part of ssych ui: https://ssych.com/library/swap-ticket

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Swap Ticket to your project and fits it to your theme.

Code

How Swap Ticket is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { useEffect } from "react"
import { SwapTicket } from "@/components/ui/swap-ticket"

export default function DemoOne() {
  // open the preview dark by default; the sandbox theme toggle still works
  useEffect(() => { document.documentElement.classList.add("dark") }, [])
  return (
    <div className="flex min-h-[520px] w-full items-center justify-center p-6">
      <div className="w-full max-w-[360px]">
        <SwapTicket />
      </div>
    </div>
  )
}

Dependencies

More by Savva Sicevs

View all
  • Price Target Fan

    Price Target Fan

    198
  • Candle Chart

    Candle Chart

    179
  • Market Snapshot

    Market Snapshot

    125
  • Returns Calendar

    Returns Calendar

    98
  • Range Navigator

    Range Navigator

    94
  • SMA Chart

    SMA Chart

    93
  • Market Watchlist

    Market Watchlist

    93
  • Sectors Donut

    Sectors Donut

    68

Explore more

Part of ssych ui — browse the full library on 21st.dev.