sunny-html-editor 1.2.0 → 1.2.1

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 CHANGED
@@ -118,6 +118,7 @@ Excel/PDF出力に必要なライブラリは**使用時に自動で読み込ま
118
118
 
119
119
  ## バージョン履歴
120
120
 
121
+ - **1.2.1** - h1の「_」区切り改行対応
121
122
  - **1.2.0** - Markdown変換機能追加(`data-markdown`属性対応)
122
123
  - **1.1.0** - ツールバー・コンテキストメニュー自動生成、外部ライブラリ遅延読み込み
123
124
  - **1.0.3** - nullチェック強化
package/html-editor.js CHANGED
@@ -190,7 +190,7 @@ function convertMarkdownToHtml(md) {
190
190
  if (/^#\s+/.test(line) && !/^##/.test(line)) {
191
191
  line = line.replace(/^#\s+(.+)$/, function(match, title) {
192
192
  docTitle = title;
193
- var displayTitle = title.replace(/\s*-\s*/g, '<br>');
193
+ var displayTitle = title.replace(/\s*[-_]\s*/g, '<br>');
194
194
  return '<h1>' + displayTitle + '</h1>';
195
195
  });
196
196
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sunny-html-editor",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "軽量WYSIWYGエディタ - 既存のHTMLに編集機能を後付けで追加、Markdown変換対応",
5
5
  "main": "html-editor.js",
6
6
  "files": [