|
|
|
@ -32,6 +32,9 @@ struct TokenViewCellViewModel { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
var amount: String { |
|
|
|
|
if self.isStormBird { |
|
|
|
|
return self.token.balance.count.toString() + " tickets" |
|
|
|
|
} |
|
|
|
|
return shortFormatter.string(from: BigInt(token.value) ?? BigInt(), decimals: token.decimals) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -79,10 +82,15 @@ struct TokenViewCellViewModel { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
var placeHolder: UIImage? { |
|
|
|
|
return R.image.ethereumToken() |
|
|
|
|
return self.isStormBird ? R.image.stormbirdToken() : R.image.ethereumToken() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
var imageUrl: URL? { |
|
|
|
|
return ticker?.imageURL |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
var isStormBird: Bool { |
|
|
|
|
return token.isStormBird |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|