Prevent backgrounds from showing up when displaying symbol icons. Fixes #2523
This commit is contained in:
parent
64bb2e58e9
commit
6d9dcecd81
|
@ -25,9 +25,11 @@ final class IconImage {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
let image: RSImage
|
let image: RSImage
|
||||||
|
let isSymbol: Bool
|
||||||
|
|
||||||
init(_ image: RSImage) {
|
init(_ image: RSImage, isSymbol: Bool = false) {
|
||||||
self.image = image
|
self.image = image
|
||||||
|
self.isSymbol = isSymbol
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -126,7 +126,7 @@ struct AppAssets {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var masterFolderImage: IconImage = {
|
static var masterFolderImage: IconImage = {
|
||||||
return IconImage(UIImage(systemName: "folder.fill")!)
|
return IconImage(UIImage(systemName: "folder.fill")!, isSymbol: true)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var moreImage: UIImage = {
|
static var moreImage: UIImage = {
|
||||||
|
@ -158,7 +158,7 @@ struct AppAssets {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var searchFeedImage: IconImage = {
|
static var searchFeedImage: IconImage = {
|
||||||
return IconImage(UIImage(systemName: "magnifyingglass")!)
|
return IconImage(UIImage(systemName: "magnifyingglass")!, isSymbol: true)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var secondaryAccentColor: UIColor = {
|
static var secondaryAccentColor: UIColor = {
|
||||||
|
@ -190,7 +190,7 @@ struct AppAssets {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var starredFeedImage: IconImage = {
|
static var starredFeedImage: IconImage = {
|
||||||
return IconImage(UIImage(systemName: "star.fill")!)
|
return IconImage(UIImage(systemName: "star.fill")!, isSymbol: true)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var tickMarkColor: UIColor = {
|
static var tickMarkColor: UIColor = {
|
||||||
|
@ -203,7 +203,7 @@ struct AppAssets {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var todayFeedImage: IconImage = {
|
static var todayFeedImage: IconImage = {
|
||||||
return IconImage(UIImage(systemName: "sun.max.fill")!)
|
return IconImage(UIImage(systemName: "sun.max.fill")!, isSymbol: true)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var trashImage: UIImage = {
|
static var trashImage: UIImage = {
|
||||||
|
@ -211,7 +211,7 @@ struct AppAssets {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var unreadFeedImage: IconImage = {
|
static var unreadFeedImage: IconImage = {
|
||||||
return IconImage(UIImage(systemName: "largecircle.fill.circle")!)
|
return IconImage(UIImage(systemName: "largecircle.fill.circle")!, isSymbol: true)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
static var vibrantTextColor: UIColor = {
|
static var vibrantTextColor: UIColor = {
|
||||||
|
|
|
@ -52,7 +52,7 @@ final class IconView: UIView {
|
||||||
}
|
}
|
||||||
|
|
||||||
private var isSymbolImage: Bool {
|
private var isSymbolImage: Bool {
|
||||||
return imageView.image?.isSymbolImage ?? false
|
return iconImage?.isSymbol ?? false
|
||||||
}
|
}
|
||||||
|
|
||||||
override init(frame: CGRect) {
|
override init(frame: CGRect) {
|
||||||
|
|
Loading…
Reference in New Issue