File tree 4 files changed +10
-6
lines changed
4 files changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -48,11 +48,9 @@ const classes = {
48
48
color : OpossumColors . middleBlue ,
49
49
} ,
50
50
tooltip : tooltipStyle ,
51
- openCloseFolderIcons : {
52
- margin : '0px' ,
53
- padding : '0px' ,
54
- width : '16px' ,
55
- height : '20px' ,
51
+ preferredIcon : {
52
+ ...baseIcon ,
53
+ color : OpossumColors . mediumOrange ,
56
54
} ,
57
55
} ;
58
56
@@ -296,7 +294,7 @@ export function PreferredIcon(props: IconProps): ReactElement {
296
294
< StarIcon
297
295
aria-label = { 'Preferred icon' }
298
296
sx = { getSxFromPropsAndClasses ( {
299
- styleClass : classes . nonClickableIcon ,
297
+ styleClass : classes . preferredIcon ,
300
298
sxProps : props . sx ,
301
299
} ) }
302
300
/>
Original file line number Diff line number Diff line change @@ -137,6 +137,7 @@ export function PackageCard(props: PackageCardProps): ReactElement | null {
137
137
excludeFromNotice : props . displayPackageInfo . excludeFromNotice ,
138
138
needsReview : Boolean ( props . displayPackageInfo . needsReview ) ,
139
139
followUp : Boolean ( props . displayPackageInfo . followUp ) ,
140
+ isPreferred : Boolean ( props . displayPackageInfo . preferred ) ,
140
141
isContextMenuOpen,
141
142
criticality : props . cardConfig . isExternalAttribution
142
143
? props . displayPackageInfo . criticality
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ import {
11
11
FollowUpIcon ,
12
12
NeedsReviewIcon ,
13
13
PreSelectedIcon ,
14
+ PreferredIcon ,
14
15
} from '../Icons/Icons' ;
15
16
import { OpossumColors } from '../../shared-styles' ;
16
17
import { DisplayPackageInfo } from '../../../shared/shared-types' ;
@@ -78,6 +79,9 @@ export function getRightIcons(
78
79
< PreSelectedIcon key = { getKey ( 'pre-selected-icon' , cardId ) } /> ,
79
80
) ;
80
81
}
82
+ if ( cardConfig . isPreferred ) {
83
+ rightIcons . push ( < PreferredIcon key = { getKey ( 'preferred-icon' , cardId ) } /> ) ;
84
+ }
81
85
82
86
return rightIcons ;
83
87
}
Original file line number Diff line number Diff line change @@ -65,6 +65,7 @@ export interface ListCardConfig {
65
65
isMarkedForReplacement ?: boolean ;
66
66
isResolved ?: boolean ;
67
67
isPreSelected ?: boolean ;
68
+ isPreferred ?: boolean ;
68
69
excludeFromNotice ?: boolean ;
69
70
firstParty ?: boolean ;
70
71
needsReview ?: boolean ;
You can’t perform that action at this time.
0 commit comments