@riebeckite/plugin-series 0.0.20 → 0.0.22

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 (3) hide show
  1. package/README.md +6 -28
  2. package/README_ja.md +6 -27
  3. package/package.json +3 -3
package/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # @riebeckite/plugin-series
2
2
 
3
+ <!-- Generated from docs/docs/plugins/series.md. Edit the canonical documentation in docs/docs/plugins and run `pnpm docs:sync`. -->
4
+
3
5
  Ordered multi-part posts ("series") for Riebeckite. At build time, notes that
4
6
  share a series name get the same generated navigation listing every part in
5
7
  order, with the current part marked and previous/next links.
@@ -65,32 +67,9 @@ the numbered parts, using `date`/`created`/`published`, then `title`, then
65
67
  | `positionLabel` | `boolean` | `false` | Add a `Part N of M` label for the current note. |
66
68
  | `basePath` | `string` | `"/series"` | Base path for the generated pages. An empty string disables them. |
67
69
 
68
- ## Output
69
-
70
- Each note in a series of two or more parts gets the following block appended to
71
- its HTML:
72
-
73
- ```html
74
- <nav class="rb-series" data-series="Build a thing"
75
- aria-label="Series navigation">
76
- <p class="rb-series__title">
77
- <a class="rb-series__link" href="/build-a-thing">Build a thing</a>
78
- </p>
79
- <ol class="rb-series__list">
80
- <li class="rb-series__item">
81
- <a class="rb-series__link" href="/part-1" data-series-order="1">Part 1</a>
82
- </li>
83
- <li class="rb-series__item">
84
- <a class="rb-series__link" href="/part-2" data-series-order="2"
85
- aria-current="page">Part 2</a>
86
- </li>
87
- </ol>
88
- <div class="rb-series__nav">
89
- <a class="rb-series__prev" rel="prev" href="/part-1">&larr; Part 1</a>
90
- <a class="rb-series__next" rel="next" href="/part-3">Part 3 &rarr;</a>
91
- </div>
92
- </nav>
93
- ```
70
+ ## Display
71
+
72
+ Each note in a series of two or more parts receives live series navigation after its article. The links and current position are calculated from the frontmatter shown above.
94
73
 
95
74
  All text and attributes are escaped. The injected HTML is written back to both
96
75
  the manifest entry and the processed content object so the page route, feeds,
@@ -171,5 +150,4 @@ matched with `.rb-series__item a[aria-current="page"]`.
171
150
 
172
151
  ## See also
173
152
 
174
- - [Plugin guide](../../../docs/docs/reference/plugin-api.md)
175
-
153
+ - [Plugin guide](https://github.com/Rerurate514/riebeckite/blob/main/docs/docs/reference/plugin-api.md)
package/README_ja.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # @riebeckite/plugin-series
2
2
 
3
+ <!-- Generated from docs/docs/plugins/series.ja.md. Edit the canonical documentation in docs/docs/plugins and run `pnpm docs:sync`. -->
4
+
3
5
  連載記事(シリーズ)を順番どおりに並べ、各記事へ共通のナビゲーションを差し込むプラグインです。ビルド時に、同じシリーズ名を持つノートをまとめて、目次・現在位置・前後の記事リンクを生成します。
4
6
 
5
7
  [English](./README.md)
@@ -54,31 +56,9 @@ series_order: 2
54
56
  | `positionLabel` | `boolean` | `false` | 現在の記事に「Part N of M」を付ける。 |
55
57
  | `basePath` | `string` | `"/series"` | 生成するページの基準パス。空文字にすると生成しない。 |
56
58
 
57
- ## 出力
58
-
59
- 2 件以上あるシリーズの各ノートには、次のブロックが HTML の末尾に追加されます。
60
-
61
- ```html
62
- <nav class="rb-series" data-series="何かを作る"
63
- aria-label="Series navigation">
64
- <p class="rb-series__title">
65
- <a class="rb-series__link" href="/part-1">何かを作る</a>
66
- </p>
67
- <ol class="rb-series__list">
68
- <li class="rb-series__item">
69
- <a class="rb-series__link" href="/part-1" data-series-order="1">導入編</a>
70
- </li>
71
- <li class="rb-series__item">
72
- <a class="rb-series__link" href="/part-2" data-series-order="2"
73
- aria-current="page">実装編</a>
74
- </li>
75
- </ol>
76
- <div class="rb-series__nav">
77
- <a class="rb-series__prev" rel="prev" href="/part-1">&larr; 導入編</a>
78
- <a class="rb-series__next" rel="next" href="/part-3">仕上げ編 &rarr;</a>
79
- </div>
80
- </nav>
81
- ```
59
+ ## 表示
60
+
61
+ 2 件以上あるシリーズの各ノートには、記事の下にシリーズナビゲーションが実際に描画されます。リンクと現在位置は、上の frontmatter から計算します。
82
62
 
83
63
  テキストと属性はすべてエスケープします。生成した HTML は manifest の entry と処理済みコンテンツの両方へ書き戻すため、ページのルート表示・フィード・検索でも同じマークアップになります。
84
64
 
@@ -144,5 +124,4 @@ const html = renderSeriesIndex(manifest, "何かを作る");
144
124
 
145
125
  ## 関連
146
126
 
147
- - [プラグインガイド](../../../docs/docs/reference/plugin-api.ja.md)
148
-
127
+ - [プラグインガイド](https://github.com/Rerurate514/riebeckite/blob/main/docs/docs/reference/plugin-api.ja.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riebeckite/plugin-series",
3
- "version": "0.0.20",
3
+ "version": "0.0.22",
4
4
  "license": "Apache-2.0",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -15,11 +15,11 @@
15
15
  "./style.css": "./style.css"
16
16
  },
17
17
  "dependencies": {
18
- "@riebeckite/core": "0.0.20"
18
+ "@riebeckite/core": "0.0.22"
19
19
  },
20
20
  "devDependencies": {
21
21
  "tsx": "^4.22.4",
22
- "@riebeckite/test": "0.0.20"
22
+ "@riebeckite/test": "0.0.22"
23
23
  },
24
24
  "publishConfig": {
25
25
  "access": "public"