CardFaceOptions型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
How a face is drawn. Every field may be left out.
インポート
import type { CardFaceOptions } from "@johnmorrisdotca/toranpu/card-faces";
定義
type CardFaceOptions = {
design?: "plain" | "four-colour" | CardDesign | (string & {});
width?: number;
title?: string;
language?: Language;
};
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
design (省略可) | "plain" | "four-colour" | CardDesign | (string & {}) | undefined |
|
width (省略可) | number | undefined | The width to draw at, in pixels; the height is 1.4 times it. Unless said, the drawing fills what holds it. |
title (省略可) | string | undefined | What a screen reader says. Unless said, the card's name in |
language (省略可) | Language | undefined | The language of the card's name, and of a joker's corner word: |
例
import type { CardFaceOptions } from "@johnmorrisdotca/toranpu/card-faces";
const value: CardFaceOptions = { design: "four-colour", width: 80, language: "ja" };
console.log(value.design);four-colour出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。