grasscnGitHub

Card

Original popup surface with composable world-setting sections.

Preview

World Settings
Change your world options.
Loading example...
To run this copied example, install these items using the linked CLI or manual instructions:

Usage

The example controls the installed Input and saves through Button. CardTitle is a div, so supply an actual heading when the card starts a document section. CardAction is available for a header-side action; keep editable content in CardContent and actions in CardFooter.

Composition

Install Input and Button as separate items when reproducing this composition. CardHeader, CardContent and CardFooter inherit Card scale; arbitrary section layout and rich content are web adaptations around the popup surface.

Installation

Loading registry address

Component source

This is the component implementation. Its supporting styles, helpers and resources are also required. See complete manual installation.

Component implementationcomponents/ui/card.tsx · tsx
"use client";

import * as React from "react";

import { minecraftCardSprite } from "./minecraft-card-sprite";
import { MinecraftCardText, CardScaleContext } from "./minecraft-card-text";
import { minecraftClasses as cn, minecraftStyle } from "./minecraft-render";
import { MinecraftSurface } from "./minecraft-surface";

import "./minecraft-card.css";

interface CardScaleStyle extends React.CSSProperties {

Interactive playground

World Settings
Change your world options.
Edit your world namePopup panel