リファレンス
地図・場所・クイズの要素
import { … } from "@johnmorrisdotca/chizu/element";
最小化と gzip 圧縮をしたサイズは 6247.2 kB(読み込むものをすべて含み、esbuild で計測)
リファレンスの説明と例は英語です。見出しと目次は日本語です。
Browser elements for maps, located places and seeded geography questions. Importing this entry is safe on a server.
エクスポート
| 名前 | 種類 | 概要 |
|---|---|---|
CHIZU_ELEMENT_OPTION_KEYS | 定数 | Real host option keys, kept complete by TypeScript and checked by the builder's coverage gate. |
ChizuElementOptions | 型 | Options that require host code rather than an HTML attribute. |
ChizuLocator | クラス | <chizu-locator>: locate a feature's id or a latitude,longitude pair, without contacting a geocoding service. |
ChizuMapElement | クラス | <chizu-map>: a map with highlights, labels, five-shade figures and keyboard selection. |
ChizuQuiz | クラス | <chizu-quiz>: repeatable questions from a seed, native answer events and no persisted score. |
defineLocator | 関数 | Register <chizu-locator> or a host's own tag; an existing definition is preserved. |
defineMap | 関数 | Register <chizu-map> or a host's own tag; an existing definition is preserved. |
defineQuiz | 関数 | Register <chizu-quiz> or a host's own tag; an existing definition is preserved. |
loadElementMap | 関数 | Load a built-in map by world, country-<ISO> or divisions-<ISO>. |
readMapColors | 関数 | Parse region colours, including native CSS colours with commas inside rgb()/hsl(). |
readMapData | 関数 | Parse finite choropleth figures; invalid JSON and nested or non-numeric values are rejected. |
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。