本文へ移動

Hoshi Stars星

肉眼で見える星の名前・色・距離、88星座の線と境界、メシエ天体、そしてそれらを描くための7種類の図法を使えます。

「星」(ほし) は、夜空に光って見えるものです。 名前について(英語)

目次

リファレンス

88星座それぞれの絵 (明るい版と暗い版)

import { … } from "@johnmorrisdotca/hoshi-stars/thumbnails";

最小化と gzip 圧縮をしたサイズは 142.0 kB(読み込むものをすべて含み、esbuild で計測)

リファレンスの説明と例は英語です。見出しと目次は日本語です。

エクスポート

名前種類概要
constellationThumbnail関数The picture of one IAU constellation: its boundary (dashed, with a faint wash), its stick figure, its bright stars, and the neighbouring constellations' boundaries and stars faint round it.
figureThumbnail関数The picture of a figure of a sky culture (a Chinese asterism, a traditional Japanese figure), drawn the way a constellation's is, so every sky makes one set: the same square, the same room round the figure, the neighbouring constellations' boundaries and stars faint behind it, the same line and star sizes.
FigureThumbnailInput型What to draw for a figure of a sky culture: its name for the picture's <title>, the stars it joins and the lines between them.
paddedOutline関数A soft outline round some stars: their convex hull grown by a margin with rounded corners, as a closed ring of positions.
THUMBNAIL_UNITS定数The side of the drawing in its own units; every picture is square.
ThumbnailInput型What to draw: the region to frame, the lines of the figure, and which stars belong to it.
ThumbnailOptions型How to draw a picture.
thumbnailSvg関数One picture, drawn from outlines, lines and stars you supply: the outlines are framed in a square with room round them, the stars that belong to the figure are drawn in full and every other star in the frame faint, with the faint boundaries of the neighbours behind them.
ThumbnailTheme型The two looks of a picture: dark is a night sky, light is ink on paper.

ソースを見るGitHub で編集@johnmorrisdotca/hoshi-stars 0.47.0 のソースから作成しました。

この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。