mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-01 15:03:57 +08:00
Refactor and optimize various components and files
- Removed deprecated `ccw-contentPattern-optimization-summary.md` and related files. - Updated `A2UIPopupCard.tsx` to clarify comments on interaction handling. - Enhanced `QueueListColumn.tsx` and `QueuePanel.tsx` to handle potential undefined values for `config`. - Added `useEffect` in `QueuePanel.tsx` to load scheduler state on mount. - Improved `SchedulerPanel.tsx` to handle potential undefined values for `sessionPool`. - Introduced auto-initialization logic in `queueSchedulerStore.ts` to prevent multiple initialization calls. - Updated `A2UIWebSocketHandler.ts` to refine selection handling logic. - Enhanced `hooks-routes.ts` to support multi-question surfaces. - Added submit and cancel buttons in `ask-question.ts` for better user interaction. - Deleted `codex_prompt.md` and `contentPattern-library-options.md` as part of cleanup. - Removed `status-reference.md` to streamline documentation.
This commit is contained in:
@@ -409,12 +409,37 @@ function generateQuestionSurface(question: Question, surfaceId: string, timeoutM
|
||||
component: {
|
||||
TextField: {
|
||||
value: question.defaultValue ? { literalString: String(question.defaultValue) } : undefined,
|
||||
onChange: { actionId: 'answer', parameters: { questionId: question.id } },
|
||||
onChange: { actionId: 'input-change', parameters: { questionId: question.id } },
|
||||
placeholder: question.placeholder || 'Enter your answer',
|
||||
type: 'text',
|
||||
},
|
||||
},
|
||||
});
|
||||
// Add Submit/Cancel buttons for input type
|
||||
components.push({
|
||||
id: 'submit-btn',
|
||||
component: {
|
||||
Button: {
|
||||
onClick: { actionId: 'submit', parameters: { questionId: question.id } },
|
||||
content: {
|
||||
Text: { text: { literalString: 'Submit' } },
|
||||
},
|
||||
variant: 'primary',
|
||||
},
|
||||
},
|
||||
});
|
||||
components.push({
|
||||
id: 'cancel-btn',
|
||||
component: {
|
||||
Button: {
|
||||
onClick: { actionId: 'cancel', parameters: { questionId: question.id } },
|
||||
content: {
|
||||
Text: { text: { literalString: 'Cancel' } },
|
||||
},
|
||||
variant: 'secondary',
|
||||
},
|
||||
},
|
||||
});
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user