Documentation
CraftingScreen
176×166 panel with a 3×3 crafting grid, 26×26 result slot and arrow.
Full-screen previewPreview pages are excluded from search indexes
合成
64
Composition
These are the composable components; the Block only places them at vanilla coordinates.
Code
import { CraftingScreen } from "./index";
/**
* CraftingScreen 预览用例(规格 §6.2):木板 ×4 → 工作台
*/
export function CraftingScreenDemo() {
return (
<CraftingScreen
craftItems={[
{ count: 1, icon: "oak-planks" },
{ count: 1, icon: "oak-planks" },
null,
{ count: 1, icon: "oak-planks" },
{ count: 1, icon: "oak-planks" },
null,
null,
null,
null,
]}
craftResult={{ count: 1, icon: "crafting-table", tooltip: "工作台" }}
hotbarItems={[{ count: 64, icon: "stone-block" }]}
selectedIndex={0}
title="合成"
/>
);
}