@riebeckite/plugin-map 0.0.27 → 0.0.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README_ja.md +5 -5
  2. package/package.json +2 -2
package/README_ja.md CHANGED
@@ -80,7 +80,7 @@ map:
80
80
  - `div.rr-map__static`: 常に利用できるフォールバック。`p.rr-map__place`、`ul.rr-map__markers` → `a.rr-map__link`(OpenStreetMap リンク)、任意の `img.rr-map__image`、`p.rr-map__attribution` を含みます
81
81
  - `details.rr-map__fallback`: 元のブロック本文を折りたたんで表示
82
82
 
83
- `initMap` は `[data-rr-map="pending"]` を探し、Leaflet を遅延して読み込み、タイルレイヤーとマーカーを描画して `data-rr-map="rendered"` にします(このとき静的フォールバックは非表示になります)。失敗した場合は `data-rr-map="error"` になり、`details` を開き、静的フォールバックは表示されたままです。
83
+ `initMap` は `[data-rr-map="pending"]` を探し、Leaflet を遅延して読み込みます。タイルレイヤーとマーカーを描画して `data-rr-map="rendered"` にします(このとき静的フォールバックは非表示になります)。失敗した場合は `data-rr-map="error"` になり、`details` を開き、静的フォールバックは表示されたままです。
84
84
 
85
85
  座標も `center` もないブロックは置き換えず、通常のコードブロックのまま残し、`source: "@riebeckite/plugin-map"` を持つ診断を出します。
86
86
 
@@ -98,12 +98,12 @@ map:
98
98
  | `attribution` | OpenStreetMap の帰属表示 | プロバイダが要求する帰属表示の HTML |
99
99
  | `fallback` | `true` | 元の本文を表示する `details` を描画する |
100
100
  | `staticFallback` | `true` | 静的フォールバックのブロックを描画する |
101
- | `staticImageUrl` | — | 静的画像 URL テンプレート(`{lat}`/`{lng}`/`{zoom}`/`{width}`/`{height}`) |
101
+ | `staticImageUrl` | なし | 静的画像 URL テンプレート(`{lat}`/`{lng}`/`{zoom}`/`{width}`/`{height}`) |
102
102
  | `frontmatterKey` | `"map"` | 座標を読む frontmatter プロパティ |
103
103
 
104
104
  ## タイルと帰属表示
105
105
 
106
- 既定はキー不要の [OpenStreetMap 標準タイル](https://tile.openstreetmap.org/) です。小規模なサイトには十分ですが、OpenStreetMap の[タイル利用ポリシー](https://operations.osmfoundation.org/policies/tiles/)は識別可能な referrer を前提とし、大量アクセスを禁止しています。一定のトラフィックがあるサイトは `tileUrl` を自前のタイルサーバーや商用プロバイダに向けてください。
106
+ 既定はキー不要の [OpenStreetMap 標準タイル](https://tile.openstreetmap.org/) です。小規模なサイトには十分ですが、OpenStreetMap の[タイル利用ポリシー](https://operations.osmfoundation.org/policies/tiles/)は。識別可能な referrer を前提とし、大量アクセスを禁止しています。一定のトラフィックがあるサイトは `tileUrl` を自前のタイルサーバーや商用プロバイダに向けてください。
107
107
 
108
108
  帰属表示は省略できません。`attribution` は Leaflet に渡され、静的フォールバックにも(プレーンテキストで)描画されます。プロバイダが要求するクレジットを常に表示してください。
109
109
 
@@ -111,9 +111,9 @@ map:
111
111
 
112
112
  ## クライアント側の描画
113
113
 
114
- Leaflet(`leaflet.js` と `leaflet.css`)は、`[data-rr-map="pending"]` の figure が 1 つ以上あるときだけ jsDelivr から取得します。ライブラリを遅延して読み込むため、地図のないページは何も負担せず、地図のあるページも JavaScript を無効にしていたり CDN に到達できなかったりする場合は静的フォールバックが表示されます。
114
+ `[data-rr-map="pending"]` の figure が 1 つ以上あるときだけ取得します。取得元は jsDelivr で、Leaflet(`leaflet.js` と `leaflet.css`)です。ライブラリを遅延して読み込むため、地図のないページは何も負担しません。地図のあるページでも、JavaScript を無効にしていたり CDN に到達できなかったりする場合があります。その場合は静的フォールバックが表示されます。
115
115
 
116
- `initMap(options?)` は `tileUrl`、`attribution`、`minZoom`、`maxZoom`、`leafletScriptUrl`、`leafletStyleUrl`、および事前読み込み済みの `runtime`(テストで偽の Leaflet を注入する用途)を受け取ります。
116
+ `initMap(options?)` が受け取るオプションは次のとおりです。`tileUrl`、`attribution`、`minZoom`、`maxZoom`、`leafletScriptUrl`、`leafletStyleUrl`。さらに、事前読み込み済みの `runtime` も指定できます(テストで偽の Leaflet を注入する用途)。
117
117
 
118
118
  ## 出力のフック
119
119
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riebeckite/plugin-map",
3
- "version": "0.0.27",
3
+ "version": "0.0.28",
4
4
  "license": "Apache-2.0",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -21,7 +21,7 @@
21
21
  "./style.css": "./style.css"
22
22
  },
23
23
  "dependencies": {
24
- "@riebeckite/core": "0.0.27"
24
+ "@riebeckite/core": "0.0.28"
25
25
  },
26
26
  "publishConfig": {
27
27
  "access": "public"