@@ -26,80 +26,6 @@ type ActionConfigProps = {
2626 disabled : boolean ;
2727} ;
2828
29- // Find Issues fields component (kept hardcoded - Linear plugin incomplete)
30- function FindIssuesFields ( {
31- config,
32- onUpdateConfig,
33- disabled,
34- } : {
35- config : Record < string , unknown > ;
36- onUpdateConfig : ( key : string , value : string ) => void ;
37- disabled : boolean ;
38- } ) {
39- return (
40- < >
41- < div className = "space-y-2" >
42- < Label className = "ml-1" htmlFor = "linearAssigneeId" >
43- Assignee (User ID)
44- </ Label >
45- < TemplateBadgeInput
46- disabled = { disabled }
47- id = "linearAssigneeId"
48- onChange = { ( value ) => onUpdateConfig ( "linearAssigneeId" , value ) }
49- placeholder = "user-id-123 or {{NodeName.userId}}"
50- value = { ( config ?. linearAssigneeId as string ) || "" }
51- />
52- </ div >
53- < div className = "space-y-2" >
54- < Label className = "ml-1" htmlFor = "linearTeamId" >
55- Team ID (optional)
56- </ Label >
57- < TemplateBadgeInput
58- disabled = { disabled }
59- id = "linearTeamId"
60- onChange = { ( value ) => onUpdateConfig ( "linearTeamId" , value ) }
61- placeholder = "team-id-456 or {{NodeName.teamId}}"
62- value = { ( config ?. linearTeamId as string ) || "" }
63- />
64- </ div >
65- < div className = "space-y-2" >
66- < Label className = "ml-1" htmlFor = "linearStatus" >
67- Status (optional)
68- </ Label >
69- < Select
70- disabled = { disabled }
71- onValueChange = { ( value ) => onUpdateConfig ( "linearStatus" , value ) }
72- value = { ( config ?. linearStatus as string ) || "any" }
73- >
74- < SelectTrigger className = "w-full" id = "linearStatus" >
75- < SelectValue placeholder = "Any status" />
76- </ SelectTrigger >
77- < SelectContent >
78- < SelectItem value = "any" > Any</ SelectItem >
79- < SelectItem value = "backlog" > Backlog</ SelectItem >
80- < SelectItem value = "todo" > Todo</ SelectItem >
81- < SelectItem value = "in_progress" > In Progress</ SelectItem >
82- < SelectItem value = "done" > Done</ SelectItem >
83- < SelectItem value = "canceled" > Canceled</ SelectItem >
84- </ SelectContent >
85- </ Select >
86- </ div >
87- < div className = "space-y-2" >
88- < Label className = "ml-1" htmlFor = "linearLabel" >
89- Label (optional)
90- </ Label >
91- < TemplateBadgeInput
92- disabled = { disabled }
93- id = "linearLabel"
94- onChange = { ( value ) => onUpdateConfig ( "linearLabel" , value ) }
95- placeholder = "bug, feature, etc. or {{NodeName.label}}"
96- value = { ( config ?. linearLabel as string ) || "" }
97- />
98- </ div >
99- </ >
100- ) ;
101- }
102-
10329// Database Query fields component
10430function DatabaseQueryFields ( {
10531 config,
@@ -435,25 +361,14 @@ export function ActionConfig({
435361 />
436362 ) }
437363
438- { /* Find Issues - kept hardcoded (Linear plugin incomplete) */ }
439- { config ?. actionType === "Find Issues" && (
440- < FindIssuesFields
364+ { /* Plugin actions - dynamic config fields */ }
365+ { pluginAction && ! SYSTEM_ACTIONS . includes ( actionType ) && (
366+ < pluginAction . configFields
441367 config = { config }
442368 disabled = { disabled }
443- onUpdateConfig = { onUpdateConfig }
369+ onUpdateConfig = { handlePluginUpdateConfig }
444370 />
445371 ) }
446-
447- { /* Plugin actions - dynamic config fields */ }
448- { pluginAction &&
449- ! SYSTEM_ACTIONS . includes ( actionType ) &&
450- actionType !== "Find Issues" && (
451- < pluginAction . configFields
452- config = { config }
453- disabled = { disabled }
454- onUpdateConfig = { handlePluginUpdateConfig }
455- />
456- ) }
457372 </ >
458373 ) ;
459374}
0 commit comments