Hulian UIv0.93.5413 components0 components
  • Start
  • Components
  • Blocks
  • Pages
  • Demos
  • Changelog
ChineseEnglish
  • ComponentsComponents
  • ThemeTheme

Collections

  • QuestionCard
  • Table
  • Book3D
  • ProTable
  • PricingTable
  • JsonViewer
  • EditableTable
  • List
  • Descriptions
  • RowActions
  • Tree
  • Card
  • Carousel
  • Video
  • Audio
  • BentoGrid
  • Image
  • MagicCard
  • AnimatedList
  • Marquee
  • Sortable
  • Kanban
  • DesignCanvas
  • LayerTree
  • StageDraw
  • SlideDeck
  • PresenterView
  • ComponentPicker
  • EventStream
  • QueueLane
  • DocumentSheet
  • Novel reader
  • Scheduler
  • Org classroom
  • Danmaku
  • LiveChat
  • LivePlayer
  • LogViewer
  • FileTree
  • CodeReviewThread
  • VirtualList
  • InfiniteScroll
  • LogoLoop
  • BounceCards
  • CardSwap
  • ChromaGrid
  • CircularGallery
  • DomeGallery
  • FlyingPosters
  • InfiniteMenu
  • MagicBento
  • ScrollStack
  • ProfileCard
  • TiltedCard
  • PixelCard
  • DecayCard
  • ReflectiveCard
  • Folder

Charts and Diagrams

  • Flow
  • Diagram
  • Paper
  • SequenceDiagram
  • Sankey
  • Sparkline
  • Funnel
  • Treemap
  • Gantt
  • Heatmap
  • ContributionGraph
  • Legend
  • Chart
  • WorldMap

Information

  • ImageViewer
  • LiveProductCard
  • DiffStat
  • ScoreRing
  • ScoreScale
  • Badge
  • Dot
  • StatusDot
  • Chip
  • FilterChip
  • Coupon
  • Tag
  • Annotation
  • Avatar
  • AvatarCircles
  • User
  • QRCode
  • Comment
  • RelativeTime
  • GitCommit
  • DeployStatus
  • ShieldBadge
  • AwardBadge
  • CreditCard
  • IconTile

Metrics

  • Stat
  • Statistic
  • Meter
  • Timeline
  • NumberTicker

Placeholders

  • Empty
  • Skeleton
  • Watermark

MagicBento

magic-bento

Builds a bento card grid with a pointer spotlight, glowing borders, and optional tilt.

Usage

Basic usage

Input card data, radial spotlight + stroke light appear when the cursor moves into the card; colSpan controls the bento layout of different sizes across columns.

Insights

Data Insights

Track user behavior and funnels

Overview

Overview Panel

Centralized data view

Teamwork

Teamwork

Seamless real-time collaboration

Efficiency

Automation

Streamline repetitive workflows

Protection

Security Protection

Enterprise-level permissions and auditing

tsx
<MagicBento
  items={[
    { label: "Insights", title: "Data Insights", description: "Tracking user behavior and funnel", colSpan: 2 },
    { label: "Overview", title: "Overview Panel", description: "Centralized Data View" },
    { label: "Teamwork", title: "Team collaboration", description: "Seamless real-time collaboration" },
  ]}
/>

3D Tilt

enableTilt Makes the card slightly tilt along with the cursor position, enhancing stereo feedback.

Insights

Data Insights

Track user behavior and funnels

Overview

Overview Panel

Centralized data view

Teamwork

Teamwork

Seamless real-time collaboration

Efficiency

Automation

Streamline repetitive workflows

Protection

Security Protection

Enterprise-level permissions and auditing

tsx
<MagicBento items={items} enableTilt />

Customized glow color

glowColor To feed the halo/stroke light, you must use token with the prefix --color-; spotlightRadius to adjust the focus range.

Insights

Data Insights

Track user behavior and funnels

Overview

Overview Panel

Centralized data view

Teamwork

Teamwork

Seamless real-time collaboration

Efficiency

Automation

Streamline repetitive workflows

Protection

Security Protection

Enterprise-level permissions and auditing

tsx
<MagicBento
  items={items}
  glowColor="var(--color-chart-2)"
  spotlightRadius={420}
/>

Close interaction

disableAnimations renders a static mesh (equivalent to reduced-motion) without any cursor feedback.

Insights

Data Insights

Track user behavior and funnels

Overview

Overview Panel

Centralized data view

Teamwork

Teamwork

Seamless real-time collaboration

Efficiency

Automation

Streamline repetitive workflows

Protection

Security Protection

Enterprise-level permissions and auditing

tsx
<MagicBento items={items} disableAnimations />

When to use

Use MagicBento for a landing-page or dashboard hero containing differently sized feature cards with spotlight and border effects. Use TiltedCard for one tilting card, or PixelCard for a pixel-wave hover effect.

Import

ts
import { MagicBento } from "@hulianui/ui"

Props

NameTypeDefaultDescription
itemsMagicBentoItem[]Built-in examplesCard data; omission renders built-in preview cards.
columnsnumber4Number of grid columns, before item spans are applied.
glowColorstringvar(--color-primary)Spotlight and border color. Use a real --color- token or any CSS color.
spotlightRadiusnumber280Spotlight radius in pixels.
enableSpotlightbooleantrueEnables the pointer-following radial spotlight.
enableBorderGlowbooleantrueBrightens borders near the pointer.
enableTiltbooleanfalseEnables subtle 3D pointer tilt.
disableAnimationsbooleanfalseDisables all animation and interaction, equivalent to reduced motion.
classNamestring-Class name forwarded to the grid root.
styleCSSProperties-Inline styles forwarded to the grid root.

MagicBentoItem

NameTypeDefaultDescription
labelReactNode-Small card label at the top, such as "Insights".
titleReactNode-Card title.
descriptionReactNode-Card body copy.
childrenReactNode-Replaces the default label, title, and description layout with custom card content.
colSpannumber1Grid column span, used to build bento layouts of mixed sizes.
rowSpannumber1Grid row span.

Usage notes

  • [[hulian-token-color-var-needs-color-prefix]]: use var(--color-primary) or var(--color-chart-2). Bare var(--primary) does not resolve under Tailwind v4.
  • Keep colSpan and rowSpan within the configured grid; a span larger than columns overflows.
  • Reduced motion or disableAnimations produces a static grid.
  • Built-in descriptions are Chinese: "\u8ffd\u8e2a\u7528\u6237\u884c\u4e3a" (“Track user behavior”), "\u96c6\u4e2d\u5f0f\u6570\u636e\u89c6\u56fe" (“Centralized data view”), "\u65e0\u7f1d\u534f\u4f5c" (“Seamless collaboration”), "\u7cbe\u7b80\u5de5\u4f5c\u6d41" (“Streamlined workflows”), "\u8fde\u63a5\u5e38\u7528\u5de5\u5177" (“Connect common tools”), and "\u4f01\u4e1a\u7ea7\u9632\u62a4" (“Enterprise-grade protection”). Pass items for production copy.

Related

Table · Book3D · ProTable · PricingTable · JsonViewer · EditableTable

Playground

Insights

Data Insights

Track user behavior and funnels

Overview

Overview Panel

Centralized data view

Teamwork

Teamwork

Seamless real-time collaboration

Efficiency

Automation

Streamline repetitive workflows

Protection

Security Protection

Enterprise-level permissions and auditing

<MagicBento
  columns={4}
  spotlightRadius={280}
  enableSpotlight={true}
  enableBorderGlow={true}
  enableTilt={false}
  disableAnimations={false}
  items={[
    { label: "Insights", title: "Data Insights", description: "Track User Behavior", colSpan: 2 },
    { label: "Overview", title: "Overview Panel", description: "Centralized Data View" },
    // …
  ]}
/>
PreviousInfiniteMenuData DisplayNextScrollStack

On this page

  • Usage
  • Documentation
    • When to use
    • Import
    • Props
    • Usage notes
    • Related
  • Playground