StackPlace型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
Where one card of a stack lies, as the stack's layout says: how far it is nudged across and down, in card widths, and how far it is turned.
インポート
import type { StackPlace } from "@johnmorrisdotca/fuda-cards";
定義
interface StackPlace {
x: number;
y: number;
rotate: number;
}
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
x | number | Across, in card widths from where a square card lies. |
y | number | Down, in card widths. |
rotate | number | Turn in degrees. |
例
import { stackLayout, type StackPlace } from "@johnmorrisdotca/fuda-cards";
const place: StackPlace = stackLayout(5, { seed: 3 })[0];
console.log(Object.keys(place)); // [ 'x', 'y', 'rotate' ][ 'x', 'y', 'rotate' ]出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。