Skip to content

Commit fcddd8d

Browse files
committed
feat(rule): add textlint-rule-ja-unnatural-alphabet
fix #19
1 parent 330092f commit fcddd8d

File tree

4 files changed

+22
-2
lines changed

4 files changed

+22
-2
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ textlint --preset ja-technical-writing README.md
6262
* [同一の単語を間違えて連続しているのをチェックする](#%E5%90%8C%E4%B8%80%E3%81%AE%E5%8D%98%E8%AA%9E%E3%82%92%E9%96%93%E9%81%95%E3%81%88%E3%81%A6%E9%80%A3%E7%B6%9A%E3%81%97%E3%81%A6%E3%81%84%E3%82%8B%E3%81%AE%E3%82%92%E3%83%81%E3%82%A7%E3%83%83%E3%82%AF%E3%81%99%E3%82%8B)
6363
* [よくある日本語の誤用をチェックする](#%E3%82%88%E3%81%8F%E3%81%82%E3%82%8B%E6%97%A5%E6%9C%AC%E8%AA%9E%E3%81%AE%E8%AA%A4%E7%94%A8%E3%82%92%E3%83%81%E3%82%A7%E3%83%83%E3%82%AF%E3%81%99%E3%82%8B)
6464
* [冗長な表現をチェックする](#%E5%86%97%E9%95%B7%E3%81%AA%E8%A1%A8%E7%8F%BE%E3%82%92%E3%83%81%E3%82%A7%E3%83%83%E3%82%AF%E3%81%99%E3%82%8B)
65+
* [入力ミスで発生する不自然なアルファベットをチェックする](#%E5%85%A5%E5%8A%9B%E3%83%9F%E3%82%B9%E3%81%A7%E7%99%BA%E7%94%9F%E3%81%99%E3%82%8B%E4%B8%8D%E8%87%AA%E7%84%B6%E3%81%AA%E3%82%A2%E3%83%AB%E3%83%95%E3%82%A1%E3%83%99%E3%83%83%E3%83%88%E3%82%92%E3%83%81%E3%82%A7%E3%83%83%E3%82%AF%E3%81%99%E3%82%8B)
6566
- [Changelog](#changelog)
6667
- [Semantic Versioning Policy](#semantic-versioning-policy)
6768
- [ルールの利用者](#%E3%83%AB%E3%83%BC%E3%83%AB%E3%81%AE%E5%88%A9%E7%94%A8%E8%80%85)
@@ -245,6 +246,11 @@ textlint --preset ja-technical-writing README.md
245246

246247
"ja-no-redundant-expression": true
247248

249+
### 入力ミスで発生する不自然なアルファベットをチェックする
250+
> https://github.com/textlint-ja/textlint-rule-ja-unnatural-alphabet
251+
252+
"ja-unnatural-alphabet": true
253+
248254
## Changelog
249255

250256
See [Releases page](https://github.com/textlint-ja/textlint-rule-preset-ja-technical-writing/releases).

lib/textlint-rule-preset-ja-technical-writing.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ module.exports = {
2222
"ja-no-weak-phrase": interopRequire("textlint-rule-ja-no-weak-phrase"),
2323
"ja-no-successive-word": interopRequire("textlint-rule-ja-no-successive-word"),
2424
"ja-no-abusage": interopRequire("textlint-rule-ja-no-abusage"),
25-
"ja-no-redundant-expression": interopRequire("textlint-rule-ja-no-redundant-expression")
25+
"ja-no-redundant-expression": interopRequire("textlint-rule-ja-no-redundant-expression"),
26+
"ja-unnatural-alphabet": interopRequire("textlint-rule-ja-unnatural-alphabet")
2627
},
2728
rulesConfig: {
2829
// # 1文の長さは100文字以下とする
@@ -114,6 +115,9 @@ module.exports = {
114115
"ja-no-abusage": true,
115116
// # 冗長な表現をチェックする
116117
// https://github.com/textlint-ja/textlint-rule-ja-no-redundant-expression
117-
"ja-no-redundant-expression": true
118+
"ja-no-redundant-expression": true,
119+
// # 入力ミスで発生する不自然なアルファベットをチェックする
120+
// https://github.com/textlint-ja/textlint-rule-ja-unnatural-alphabet
121+
"ja-unnatural-alphabet": true
118122
}
119123
};

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
"textlint-rule-ja-no-redundant-expression": "^3.0.1",
4242
"textlint-rule-ja-no-successive-word": "^1.1.0",
4343
"textlint-rule-ja-no-weak-phrase": "^1.0.2",
44+
"textlint-rule-ja-unnatural-alphabet": "2.0.1",
4445
"textlint-rule-max-comma": "^1.0.2",
4546
"textlint-rule-max-kanji-continuous-len": "^1.1.0",
4647
"textlint-rule-max-ten": "^2.0.1",

yarn.lock

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1740,6 +1740,15 @@ textlint-rule-ja-no-weak-phrase@^1.0.2:
17401740
morpheme-match "^1.0.1"
17411741
morpheme-match-all "^1.1.0"
17421742

1743+
textlint-rule-ja-unnatural-alphabet@2.0.1:
1744+
version "2.0.1"
1745+
resolved "https://registry.npmjs.org/textlint-rule-ja-unnatural-alphabet/-/textlint-rule-ja-unnatural-alphabet-2.0.1.tgz#fa95591312834a7788dbc6880e2f7a7e68633c00"
1746+
integrity sha512-n93V8qh6OKdh8OB6yLT+9Xl8DSoZ7gWi51tWdhlLEPIWgBm18nLMgm6Ck+nVc3eENOdRcQURWUpCGotI8wTemA==
1747+
dependencies:
1748+
"@textlint/regexp-string-matcher" "^1.0.2"
1749+
match-index "^1.0.1"
1750+
regx "^1.0.4"
1751+
17431752
textlint-rule-max-comma@^1.0.2:
17441753
version "1.0.4"
17451754
resolved "https://registry.yarnpkg.com/textlint-rule-max-comma/-/textlint-rule-max-comma-1.0.4.tgz#f555c97e0d3039ca7da06cfd1afad0e5f5899a37"

0 commit comments

Comments
 (0)