mirror of
https://github.com/luxfi/safe-ios.git
synced 2026-10-30 15:19:20 +00:00
36 lines
885 B
Swift
36 lines
885 B
Swift
//
|
|
// AccountInfoView.swift
|
|
// Multisig
|
|
//
|
|
// Created by Moaaz on 1/20/21.
|
|
// Copyright © 2021 Gnosis Ltd. All rights reserved.
|
|
//
|
|
|
|
import UIKit
|
|
|
|
class AccountInfoView: UINibView {
|
|
@IBOutlet private weak var identiconView: UIImageView!
|
|
@IBOutlet weak var nameLabel: UILabel!
|
|
@IBOutlet weak var addressInfoView: AddressInfoView!
|
|
|
|
private(set) var address: Address!
|
|
private(set) var label: String?
|
|
|
|
override func commonInit() {
|
|
super.commonInit()
|
|
nameLabel.setStyle(.headline)
|
|
}
|
|
|
|
func set(_ name: String?) {
|
|
nameLabel.text = name
|
|
}
|
|
|
|
func setAddress(_ address: Address, label: String? = nil, prefix: String?) {
|
|
self.address = address
|
|
self.label = label
|
|
|
|
identiconView.setAddress(self.address.hexadecimal)
|
|
addressInfoView.setAddress(address, showIdenticon: false, prefix: prefix)
|
|
}
|
|
}
|