@@ -246,6 +246,7 @@ export const StakeholderGroups: React.FC = () => {
246
246
</ Title >
247
247
< EmptyStateBody >
248
248
{ t ( "composed.noDataStateBody" , {
249
+ how : t ( "terms.add" ) ,
249
250
what : t ( "terms.stakeholderGroup" ) . toLowerCase ( ) ,
250
251
} ) }
251
252
</ EmptyStateBody >
@@ -254,6 +255,7 @@ export const StakeholderGroups: React.FC = () => {
254
255
numRenderedColumns = { numRenderedColumns }
255
256
>
256
257
{ currentPageItems ?. map ( ( stakeholderGroup , rowIndex ) => {
258
+ const hasStakeholders = stakeholderGroup . stakeholders ?. length ;
257
259
return (
258
260
< Tbody
259
261
key = { stakeholderGroup . id }
@@ -297,20 +299,37 @@ export const StakeholderGroups: React.FC = () => {
297
299
className = { spacing . pyLg }
298
300
>
299
301
< ExpandableRowContent >
300
- < DescriptionList >
301
- < DescriptionListGroup >
302
- < DescriptionListTerm >
303
- { t ( "terms.member(s)" ) }
304
- </ DescriptionListTerm >
305
- { ! ! stakeholderGroup . stakeholders ?. length && (
306
- < DescriptionListDescription >
307
- { stakeholderGroup . stakeholders
308
- ?. map ( ( f ) => f . name )
309
- . join ( ", " ) }
310
- </ DescriptionListDescription >
311
- ) }
312
- </ DescriptionListGroup >
313
- </ DescriptionList >
302
+ { hasStakeholders ? (
303
+ < DescriptionList >
304
+ < DescriptionListGroup >
305
+ < DescriptionListTerm >
306
+ { t ( "terms.member(s)" ) }
307
+ </ DescriptionListTerm >
308
+ { ! ! stakeholderGroup . stakeholders ?. length && (
309
+ < DescriptionListDescription >
310
+ { stakeholderGroup . stakeholders
311
+ ?. map ( ( f ) => f . name )
312
+ . join ( ", " ) }
313
+ </ DescriptionListDescription >
314
+ ) }
315
+ </ DescriptionListGroup >
316
+ </ DescriptionList >
317
+ ) : (
318
+ < EmptyState variant = "sm" >
319
+ < EmptyStateIcon icon = { CubesIcon } />
320
+ < Title headingLevel = "h2" size = "lg" >
321
+ { t ( "composed.noDataStateTitle" , {
322
+ what : t ( "terms.stakeholder" ) . toLowerCase ( ) ,
323
+ } ) }
324
+ </ Title >
325
+ < EmptyStateBody >
326
+ { t ( "composed.noDataStateBody" , {
327
+ how : t ( "terms.add" ) ,
328
+ what : t ( "terms.stakeholder" ) . toLowerCase ( ) ,
329
+ } ) }
330
+ </ EmptyStateBody >
331
+ </ EmptyState >
332
+ ) }
314
333
</ ExpandableRowContent >
315
334
</ Td >
316
335
</ Tr >
0 commit comments