Repository navigation
feat(dncl): keep only blocks that can be written in japanese in the palette (#2629) - #2639
Open
smalruby3-editor-bot[bot] wants to merge 2 commits into
Open
smalruby3-editor-bot[bot] wants to merge 2 commits into
smalruby3-editor-bot[bot] wants to merge 2 commits into
Conversation
…alette Drop show/hide of variables and lists, delete, delete all, insert and item # of list from the Japanese palette, also in the Variables flyout (the callbacks use the same list now). A test puts each palette block alone, writes it in the Japanese and turns it back (#2629). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
🤖 autopilot status
Linked issue #2629. Maintained by autopilot (single writer); do not edit. |
|
🚀 Preview deployed (stg API): https://preview.smalruby.app/topic-autopilot-2629-fe3e7b75/ |
…nese palette The spec still said all variable and list blocks are in the palette. Also check that the dynamic palette has none of the blocks the japanese cannot write (review of #2629). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
|
🤖 敵対的レビュー(round 1): 指摘 6 件(Must 1 / Question 2 / FYI 3) Must
Question
FYI
直してほしい指摘は、モニターの「AI に直してもらう」で指示を書くか、Request changes で ID を指定してから |
This branch was successfully 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
日本語モードのコードタブのパレットを、日本語で書けて、日本語から元のブロックに戻せるブロックだけにそろえる(
docs/dncl/policy.mdの「誤りの出ない作り」)。#2623 の残り。Changes Made
dncl-block-filter.js: 日本語にならないブロックを外した。変数・リストの「表示する」「隠す」、リストの「〜番目を削除する」「すべて削除する」「〜番目に挿入する」「〜の番号」(Ruby → 日本語で「日本語タブでは書けない命令」の誤りになっていた)。blocks.jsx: 「変数」「ブロック定義」は flyout を開くたびにカテゴリコールバックが作るので、これまで日本語モードでも絞られていなかった。日本語モードではコールバックもDNCL_ALLOWED_BLOCKSで絞る(getDynamicCategoryAllowedIds。新しいマーカーDNCL dynamic category filtering)。docs/dncl/README.mdの「関連ブロック」に、残すブロックの表と出さないものを書いた。マーカー一覧も更新。AI が決めたこと
operator_mathop)は残した。はじめの選択の「絶対値」と「切り下げ」「切り上げ」「平方根」は日本語にあるが、sinなどに変えると誤りになる。日本語モードだけ選択肢を減らす仕組みが無いため。別案: ブロックごと外す/選択肢を絞る仕組みを足す。〜ずつ増やしながら繰り返すになり(これまでの仕様)、日本語から戻すと変数と「〜まで繰り返す」のブロックになる。誤りにはならず、日本語は何度通っても同じ。Test Coverage
test/unit/lib/dncl/dncl-palette-blocks.test.js: パレット(toolbox XML とカテゴリコールバックの絞り込み)のブロックが表と同じであること、1 つずつブロック → Ruby → 日本語で誤りが無く日本語から同じブロックに戻ること、出さないブロックが日本語にならないこと。dncl-block-filter.test.jsに外したブロックの確かめを追加。make-toolbox-xml-dncl-extensions.test.js、bin/lint-changed。Related Issues
Closes #2629
🤖 Generated with Claude Code