refactor: NodeSettings.tsx の分割(2500行超の巨大コンポーネント)#125
Conversation
2571行の巨大コンポーネントを3つのファイルに分割: - FormFieldRenderer.tsx: フォームフィールドの描画ロジック(各入力タイプ別の描画) - GlobalSettingsOverride.tsx: グローバル設定オーバーライドのUI - NodeSettings.tsx: オーケストレーター(簡素化) 機能変更なし。既存のexport(PromptSection, Expression型)はre-exportで互換性維持。 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (3)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
概要
NodeSettings.tsx(2571行)を3つのファイルに分割し、保守性を向上させました。FormFieldRenderer.tsx(1235行): 各フォームフィールドタイプの描画ロジック(text, number, select, checkbox, password, animation-file, model-file, prompt-builder, expression-list, png-expression-map 等)GlobalSettingsOverride.tsx(97行): グローバル設定オーバーライドのバナーUI・展開フィールド表示NodeSettings.tsx(1392行): ノード設定スキーマ定義 + オーケストレーター(簡素化)変更の詳細
PasswordField,InputListField,ExpressionListField,PngExpressionMapFieldコンポーネントをFormFieldRenderer.tsxに移動renderFieldのswitch文ロジックをFormFieldRendererコンポーネントとして抽出GLOBAL_SETTINGS_MAPと グローバル設定バナー/オーバーライドUIをGlobalSettingsOverride.tsxに移動PromptSectionとExpression型はNodeSettings.tsxからre-exportし、既存のimport元(Canvas.tsx)の互換性を維持テスト計画
tsc --noEmit)パスCanvas.tsxのPromptSectionimport が正常動作client-page.tsxのNodeSettingsdefault import が正常動作closes #102
🤖 Generated with Claude Code