VisibleMarker型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A marker the range lets through: the marker, its place in the list, the id it answers to, its moment in milliseconds and how strongly it is drawn.
インポート
import type { VisibleMarker } from "@johnmorrisdotca/hoshi-stars/chart";
定義
interface VisibleMarker {
marker: SkyMarker;
index: number;
id: string;
time: number | undefined;
opacity: number;
}
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
marker | SkyMarker | |
index | number | |
id | string | |
time | number | undefined | Milliseconds since 1970; |
opacity | number | 1 in the middle of the range; down to 0.2 at an edge when the range has a |
例
import { visibleMarkers, type VisibleMarker } from "@johnmorrisdotca/hoshi-stars/chart";
const [first]: VisibleMarker[] = visibleMarkers([{ ra: 84, dec: 0, date: "2026-11-08" }]);
console.log(first?.id, first?.opacity);
// m0 1m0 1出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。