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

Book3D

book-3d

Displays a book cover with perspective depth and interactive 3D tilt.

Usage

Basic usage

Pass title / subtitle Ready-to-use brand gradient cover; thickness is revealed when still, and can be corrected when hovering.

Hulianhulianui
tsx
<Book3D title="Hulian" subtitle="hulianui" />

Customized cover gradient

coverColor Give the cover gradient starting and ending colors.

CSSConversion
tsx
<Book3D
  title="CSS"
  subtitle="Convert"
  coverColor={{ from: "#f7b733", to: "#e0992b" }}
/>

Corner ribbon

ribbon + ribbonTone Attach a ribbon (danger / brand / success) to the upper right corner of the cover.

N°1HTML5
tsx
<Book3D
  title="HTML"
  subtitle="5"
  ribbon="N°1"
  ribbonTone="danger"
  coverColor={{ from: "#e0654a", to: "#c14a32" }}
/>

Bookshelf Arrangement

Multiple books side by side, hover over to correct each one.

NEWCSSConversionJSFUNCTIONTSTYPES
tsx
<div className="flex flex-wrap gap-8">
  <Book3D title="CSS" subtitle="Convert" ribbon="NEW" coverColor={{ from: "#f7b733", to: "#e0992b" }} />
  <Book3D title="JS" subtitle="FUNCTION" coverColor={{ from: "#5aa6e0", to: "#3f7fc0" }} />
  <Book3D title="TS" subtitle="TYPES" ribbonTone="brand" />
</div>

When to use

Use Book3D for a dimensional book in a portfolio, bookshelf, or cover wall. It is decorative rather than tabular: use Table or PricingTable for data, and List for a regular grid.

Import

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

Props

NameTypeDefaultDescription
coverstring-Cover image URL, taking precedence over coverColor.
logostring-Product logo or app icon centered on the cover.
coverColor{ from: string; to: string }Brand gradientCover gradient.
spineColorstring"#efe9dd"Light paper color used for the spine and page block.
thicknessstring"2.25rem"Spine thickness as a CSS length.
ribbonstring-Corner ribbon such as "NEW" or "N°1".
ribbonTone"brand" | "danger" | "success""danger"Ribbon tone.
hrefstring-Makes the whole book a link.
targetstring-Link target when href is present.
classNamestring-Root class name.

Events

EventTypeDescription
onClick() => voidMakes the book a button when href is absent.

Slots

SlotTypeDescription
title*ReactNodeMain cover title.
subtitleReactNodeCover subtitle.
insideReactNodeInside-page content revealed when the front cover opens on hover.

Usage notes

  • cover overrides coverColor when both are supplied.
  • The hover opening is CSS-only and automatically degrades under reduced motion; do not wrap it in another JavaScript animation.
  • href and onClick are alternatives: href renders an anchor, otherwise onClick renders a button.

Related

Table · ProTable · PricingTable · JsonViewer · EditableTable · List

Playground

NEWCSSConversion
<Book3D title="CSS" subtitle="Conversion" ribbon="NEW" ribbonTone="danger" coverColor={{ from: "#f7b733", to: "#e0992b" }} />
PreviousTableData DisplayNextProTable

On this page

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