@cosense-toolbox/style 0.1.0-beta.4 → 0.1.0-beta.6
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.
- package/README.md +8 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
> **beta.** class 名はまだ変わりえます。安定するまではバージョン固定での利用を推奨します。
|
|
4
4
|
|
|
5
|
-
[`@cosense-toolbox/parser`](../parser) の `toHtml`
|
|
6
|
-
CSS 1
|
|
5
|
+
[`@cosense-toolbox/parser`](../parser) の `toHtml` が出力する HTML に適用する、既定のスタイルシートです。
|
|
6
|
+
CSS ファイル1枚だけで構成されているため、独自の見た目を使う場合はインストールする必要はありません。
|
|
7
|
+
|
|
8
|
+
**ドキュメント → <https://cosense-toolbox.qaynam.dev/style/>**
|
|
7
9
|
|
|
8
10
|
```sh
|
|
9
|
-
npm i @cosense-toolbox/style
|
|
11
|
+
npm i @cosense-toolbox/style
|
|
10
12
|
```
|
|
11
13
|
|
|
12
14
|
```ts
|
|
@@ -17,8 +19,8 @@ import "@cosense-toolbox/style"
|
|
|
17
19
|
> (`.line > .text > 1 文字ごとの .char-index`) に当てたもので `toHtml` の出力には当たらないため、
|
|
18
20
|
> 見た目を寄せた別実装として書き起こしたものです。
|
|
19
21
|
|
|
20
|
-
Tailwind CSS
|
|
21
|
-
`class="cosense"`
|
|
22
|
+
Tailwind CSS を使う場合は、この CSS の代わりに [`@cosense-toolbox/tailwind`](../tailwind) を利用できます。
|
|
23
|
+
`class="cosense"` を付けた要素の中に同じスタイルが適用されます。
|
|
22
24
|
|
|
23
25
|
## 前提
|
|
24
26
|
|
|
@@ -75,7 +77,7 @@ CSS 変数を定義するだけでよい。定義した変数が最優先にな
|
|
|
75
77
|
Cosense と同じく、字下げの右端に中点を出す。`toHtml` の既定の出力には中点にあたる要素が
|
|
76
78
|
無いので `.line[data-indent]::before` で描いている。
|
|
77
79
|
|
|
78
|
-
`toHtml(page, { showPads: true })` でCosense Web と同じ `.indent-mark` / `.pad` / `.dot` を
|
|
80
|
+
`toHtml(page, { showPads: true })` で Cosense Web と同じ `.indent-mark` / `.pad` / `.dot` を
|
|
79
81
|
書き出した場合は、擬似要素を止めて要素側のスタイルを使う。どちらでも見た目は同じ。
|
|
80
82
|
|
|
81
83
|
## コードブロックの行番号
|