リファレンス
距離で見る空 (10・50・100・500・1,000光年より近い星や銀河を層に分けて、距離の帯ごとに色分けします。距離がはっきりしないものは別にし、推測で置くことはしません)
import { … } from "@johnmorrisdotca/hoshi-stars/distance";
最小化と gzip 圧縮をしたサイズは 1.2 kB(読み込むものをすべて含み、esbuild で計測)
リファレンスの説明と例は英語です。見出しと目次は日本語です。
エクスポート
| 名前 | 種類 | 概要 |
|---|---|---|
bandOf | 関数 | The band of a distance: 0 under 10 light-years, 1 under 50, 2 under 100, 3 under 500, 4 under 1,000 and 5 beyond (a distance of exactly the edge is in the nearer band). |
Certainty | 型 | How well a distance is known: good (under 5%), fair (5% to 20%) or rough (over 20%, or no error stated). |
CERTAINTY_LIMITS | 定数 | The relative errors that divide a distance's certainty, the same as QUALITY_LIMITS of the constellation in 3D: a parallax known to under 5% is good, to 20% is fair, and worse (or with no error stated) is rough. |
certaintyOf | 関数 | The certainty of a parallax known to a relative error (the error over the parallax): good under 5%, fair up to 20%, rough over it. |
deepSkyInput | 関数 | A deep-sky object with a galaxy's distance (galaxyDistance of /deep-sky) as a thing with a distance. |
DISTANCE_ATTRIBUTE | 定数 | The attribute a page offers for the limit, as a settings panel sets it: distance-limit. |
DISTANCE_LIMITS | 定数 | The limits the sky map steps through, in light-years: 10, 50, 100, 500 and 1,000. |
DistanceInput | 型 | Something with a place on the sky and perhaps a distance, as layersByDistance takes it. |
DistanceLayers | 型 | What layersByDistance gives back. |
LayeredThing | 型 | A thing in a layer: where it is, how far, and which band it is in. |
LayerKind | 型 | The kind of thing in a layer: a bright star of the Yale catalogue, a nearby star of the Yale parallax catalogue (/nearby), or a deep-sky object with a distance (a galaxy). |
layersByDistance | 関数 | The things out to a limit, each in the band of its distance. |
limitAtSlider | 関数 | The limit at a slider's position, 0 to 1, on a scale where each step is the same ratio (4 light-years to 3 million). |
limitFromText | 関数 | The limit from the attribute distance-limit (and the address's dist), read as text: a number of light-years, or all. |
limitText | 関数 | A limit as the text the address keeps: all, or the light-years rounded (to the step where it is a step, else to 2 significant figures). |
nearbyInput | 関数 | A nearby star (/nearby) as a thing with a distance. |
SLIDER_RANGE | 定数 | The nearest and farthest limits a free slider reaches, in light-years: from Alpha Centauri's neighbourhood to past the Andromeda Galaxy; beyond the last is all. |
sliderOfLimit | 関数 | Where a limit sits on the slider, 0 to 1; all is 1 and a limit under the slider's start is 0. |
starInput | 関数 | A bright star of the Yale catalogue as a thing with a distance, from its parallax and its error. |
stepLimit | 関数 | The next limit up or down the steps (10, 50, 100, 500, 1,000, then all). |
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。