Componentdata0.53 KB gzipZero dependencies

Empty Col Span

Empty table cell placeholder with floating icon animation.

Preview

Live Preview
Open ↗

Installation

Tokens guide →

Add to your project via CLI (zero dependencies, code you own):

npx bigbullui add empty-col-span

Or install the full npm package:

npm install bigbullui

Usage

tsx3 lines
import { EmptyColSpan } from "@/components/ui/empty-col-span"; <EmptyColSpan />

Source code

empty-col-span.tsx + 1 helper

Zero third-party dependencies (2 local files shown in tabs below).

tsxempty-col-span.tsx27 lines
"use client"; import * as React from "react";import { cn } from "./lib/utils"; export interface EmptyColSpanProps extends React.HTMLAttributes<HTMLTableCellElement> {  colSpan?: number;  message?: string;  icon?: React.ReactNode;} /** Empty column span table cell placeholder for empty states. */export function EmptyColSpan({ colSpan = 1, message = "Veri yok", icon, className, ...props }: EmptyColSpanProps) {  return (    <td colSpan={colSpan} className={cn("px-4 py-10 text-center", className)} {...props}>      <div className="flex flex-col items-center gap-2 text-muted-foreground">        {icon ?? (          <span className="flex size-10 items-center justify-center rounded-full border border-dashed border-border motion-reduce:animate-none!" style={{ animation: "ecFloat 2.5s ease-in-out infinite" }} aria-hidden="true">            <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="1.5" strokeLinecap="round"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z" /><path d="M14 2v6h6" /></svg>          </span>        )}        <span className="font-mono text-[10px] uppercase tracking-[0.15em]">{message}</span>      </div>    </td>  );} 

Props

Interactive Prop Playground

Tweak parsed AST props below to generate ready-to-paste JSX.

tsx3 lines
import { EmptyColSpan } from "@/components/ui/empty-col-span"; <EmptyColSpan />
PropTypeDescription
colSpannumberConfigures col span. (Default: 1)
messagestringConfigures message. (Default: "Veri yok")
iconReact.ReactNodeCustom icon node rendered alongside the label.