Skip to the content

Kyuubuキューブ

Turn CSS 3D cubes by touch, keys or notation, reproduce a scramble from a seed, and follow a solve one named step at a time.

Kyuubu (キューブ) is the Japanese spelling of cube. About the name

Contents

Reference · React components

KyuubuMovesfunction

THE MOVES AS A REACT COMPONENT: a thin wrapper round mountMoveList. Give it the runs of moves and the one just made, and it marks that one and scrolls it into view; onPick hears a press or a key. The runs are drawn again only when what they say changes.

Import it

import { KyuubuMoves } from "@johnmorrisdotca/kyuubu/react";

Definition

function KyuubuMoves({ ref, className, style, groups, current, locale, label, onPick, }: KyuubuMovesProps): React.JSX.Element

Parameters

NameTypeDescription
optionsKyuubuMovesProps

Options for this call; omitted fields retain their documented defaults.

Returns

React.JSX.Element

A React host element that mounts and maintains the move list in the browser.

Examples

import { KyuubuMoves } from "@johnmorrisdotca/kyuubu/react";

import { createElement } from "react";
console.log(createElement(KyuubuMoves, { groups: [{ label: "Solve", items: ["R", "R'"] }], current: 0 }).props.current);
0

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/kyuubu 1.14.1.