deepraj21

Glass Toast

Component

About

An imperative toast notification system rendered on a frosted glass surface, with stacking, swipe-to-dismiss and promise-based loading states.

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

Code

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

Usage.tsx

"use client";

import { GlassToaster, toast } from "@/components/ui/glass-toast";

export default function GlassToastDemo() {
  return (
    <div className="flex min-h-[420px] w-full items-center justify-center bg-background text-foreground">
      <GlassToaster position="top-center" closeButton />
      <button
        type="button"
        onClick={() =>
          toast.success("Saved", { description: "Your changes are live." })
        }
        className="cursor-pointer rounded-full bg-foreground px-4 py-2 text-sm font-medium text-background transition-transform active:scale-95"
      >
        Show toast
      </button>
    </div>
  );
}

Dependencies

More by deepraj21

View all
  • Glass Message

    Glass Message

    5
  • Glass Sidebar

    Glass Sidebar

    3
  • Glass QR Code

    Glass QR Code

    2
  • Glass Toolbar

    Glass Toolbar

    2
  • Glass Select

    Glass Select

    2
  • Glass Dock

    Glass Dock

    2
  • Glass Date Picker

    Glass Date Picker

    2
  • Glass Input

    Glass Input

    1