@@ -64,29 +64,56 @@ export const WorkspaceActions: FC<WorkspaceActionsProps> = ({
64
64
65
65
// A mapping of button type to the corresponding React component
66
66
const buttonMapping : ButtonMapping = {
67
- [ ButtonTypesEnum . update ] : < UpdateButton handleAction = { handleUpdate } /> ,
67
+ [ ButtonTypesEnum . update ] : (
68
+ < UpdateButton handleAction = { handleUpdate } key = { ButtonTypesEnum . update } />
69
+ ) ,
68
70
[ ButtonTypesEnum . updating ] : (
69
- < ActionLoadingButton label = { t ( "actionButton.updating" ) } />
71
+ < ActionLoadingButton
72
+ label = { t ( "actionButton.updating" ) }
73
+ key = { ButtonTypesEnum . updating }
74
+ />
75
+ ) ,
76
+ [ ButtonTypesEnum . start ] : (
77
+ < StartButton handleAction = { handleStart } key = { ButtonTypesEnum . start } />
70
78
) ,
71
- [ ButtonTypesEnum . start ] : < StartButton handleAction = { handleStart } /> ,
72
79
[ ButtonTypesEnum . starting ] : (
73
- < ActionLoadingButton label = { t ( "actionButton.starting" ) } />
80
+ < ActionLoadingButton
81
+ label = { t ( "actionButton.starting" ) }
82
+ key = { ButtonTypesEnum . starting }
83
+ />
84
+ ) ,
85
+ [ ButtonTypesEnum . stop ] : (
86
+ < StopButton handleAction = { handleStop } key = { ButtonTypesEnum . stop } />
74
87
) ,
75
- [ ButtonTypesEnum . stop ] : < StopButton handleAction = { handleStop } /> ,
76
88
[ ButtonTypesEnum . stopping ] : (
77
- < ActionLoadingButton label = { t ( "actionButton.stopping" ) } />
89
+ < ActionLoadingButton
90
+ label = { t ( "actionButton.stopping" ) }
91
+ key = { ButtonTypesEnum . stopping }
92
+ />
78
93
) ,
79
94
[ ButtonTypesEnum . deleting ] : (
80
- < ActionLoadingButton label = { t ( "actionButton.deleting" ) } />
95
+ < ActionLoadingButton
96
+ label = { t ( "actionButton.deleting" ) }
97
+ key = { ButtonTypesEnum . deleting }
98
+ />
81
99
) ,
82
100
[ ButtonTypesEnum . canceling ] : (
83
- < DisabledButton label = { t ( "disabledButton.canceling" ) } />
101
+ < DisabledButton
102
+ label = { t ( "disabledButton.canceling" ) }
103
+ key = { ButtonTypesEnum . canceling }
104
+ />
84
105
) ,
85
106
[ ButtonTypesEnum . deleted ] : (
86
- < DisabledButton label = { t ( "disabledButton.deleted" ) } />
107
+ < DisabledButton
108
+ label = { t ( "disabledButton.deleted" ) }
109
+ key = { ButtonTypesEnum . deleted }
110
+ />
87
111
) ,
88
112
[ ButtonTypesEnum . pending ] : (
89
- < ActionLoadingButton label = { t ( "disabledButton.pending" ) } />
113
+ < ActionLoadingButton
114
+ label = { t ( "disabledButton.pending" ) }
115
+ key = { ButtonTypesEnum . pending }
116
+ />
90
117
) ,
91
118
}
92
119
0 commit comments