Repository navigation
fix(dncl): keep full-width characters inside strings and comments (#2621) - #2627
Merged
smalruby3-editor-bot[bot] merged 5 commits intoNov 29, 2026
Merged
Conversation
The auto-correct no longer changes what is written in a string ("...", '...', and 「...」 in
the Japanese tab), in both the Japanese tab and the Ruby tab. Full-width and smart quotes
are read as the ends of a string, so an IME-typed "こんにちは!" keeps its !.
The "also replace inside strings" setting is removed; an old saved value is ignored.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
🤖 autopilot status
Linked issue #2621. Maintained by autopilot (single writer); do not edit. |
…opic/autopilot-2621
|
🚀 Preview deployed (stg API): https://preview.smalruby.app/topic-autopilot-2621-84f67de7/ |
The code in a #{} of a double-quoted Ruby string is code, so it is made half-width again
("#{x + 1}" -> "#{x + 1}"), as it was before strings were kept.
A string now ends at the end of its line in the Ruby tab too: while a quote is being typed
(an IME ” has no closing pair), the strings on the lines below were read as code and changed.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…opic/autopilot-2621
…ine end A \ at the end of a line skipped the newline, so the string went on to the next line and the text of the strings below was read as code and made half-width. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
|
🤖 敵対的レビュー(round 1): 指摘 6 件(Must 2 / Question 1 / FYI 3) Must
Question
FYI
直してほしい指摘は、モニターの「AI に直してもらう」で指示を書くか、Request changes で ID を指定してから |
smalruby3-editor-bot
Bot
merged commit Nov 29, 2026
d94b371
into
topic/japanese-mode-1731
11 checks passed
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
日本語タブとルビータブの自動置換が、文字列の中の全角も半角にしていた(
表示する("こんにちは!ABC")→"こんにちは!ABC")。自動置換は、文字列("…"'…'、日本語タブでは「…」も)とコメントの中を変えないようにした。docs/dncl/README.mdの「文字列とコメントの中は書いたとおりに残す」と合う。Changes Made
src/lib/auto-correct.jsreplaceInStringsが既定でオンだった)。"'とスマートクォート(“”‘’)も文字列の囲みとして読む。同じ種類(ダブル / シングル)の引用符なら、半角でも全角でも文字列を閉じる。IME でputs("こんにちは!")と打っても!が残り、囲みだけが"になる。isEscapedを消した。auto-correct-modal.jsx、ja.js/ja-Hira.jsのキー。en.jsにはこのキーが無かった)。localStorage に前の値が残っていても読まない。docs/ruby-editor/README.mdの自動置換の説明と、docs/dncl/README.mdの記述。Test Coverage
test/unit/lib/auto-correct.test.js: 文字列を残す("'「」、全角やスマートクォートの囲み、引用符の種類が混ざったとき、前に保存した設定)テストを足し、文字列の中を置換していた期待値を直した。test/integration/auto-correct.test.js(中身は純粋関数のテスト): 期待値を直した。test/unit/containers/ruby-tab/auto-correct-apply.test.jsを流し、bin/lint-changedを通した。Closes #2621
🤖 Generated with Claude Code