Skip to content

Commit

Permalink
Update shield icon as per design
Browse files Browse the repository at this point in the history
  • Loading branch information
BillCarsonFr committed Jul 18, 2024
1 parent fde64d4 commit 6b920b4
Showing 1 changed file with 13 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -272,11 +272,19 @@ struct TimelineItemBubbledStylerView<Content: View>: View {
.frame(maxWidth: 250, alignment: .leading)
.font(.compound.bodyXS)
} icon: {
CompoundIcon(\.keyOffSolid, size: .xSmall, relativeTo: .compound.bodyXS)
.foregroundColor(shield.color == ShieldColor.RED ? .compound.iconCriticalPrimary : .compound.iconSecondary)
.alignmentGuide(VerticalAlignment.top) { dimensions in
dimensions[.top]
}
if shield.color == ShieldColor.RED {
CompoundIcon(\.error, size: .xSmall, relativeTo: .compound.bodyXS)
.foregroundColor(.compound.iconCriticalPrimary)
.alignmentGuide(VerticalAlignment.top) { dimensions in
dimensions[.top]
}
} else {
CompoundIcon(\.infoSolid, size: .xSmall, relativeTo: .compound.bodyXS)
.foregroundColor(.compound.iconSecondary)
.alignmentGuide(VerticalAlignment.top) { dimensions in
dimensions[.top]
}
}
}
.labelStyle(.custom(spacing: 4, alignment: .top))
.padding(4)
Expand Down

0 comments on commit 6b920b4

Please sign in to comment.