SpacePreset型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A named distance for zoomFor: the Earth, the Moon, the Sun, the inner planets, the whole solar system, or a planet with its nearer moons (Jupiter-moons: the zoom that shows them, when a body painter that draws moons is set).
インポート
import type { SpacePreset } from "@johnmorrisdotca/chikyu-earth/space/element";
定義
type SpacePreset = "earth" | "moon" | "sun" | "inner" | "solar-system" | `${Exclude<PlanetName, "Mercury" | "Venus">}-moons`;
例
import type { ChikyuSpace, SpacePreset } from "@johnmorrisdotca/chikyu-earth/space/element";
const zoomTo = (space: ChikyuSpace, preset: SpacePreset): number => space.zoomFor(preset);
console.log(typeof zoomTo);この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。