Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttachmentManager tintcolor is readonly, provide a setter for it #41

Open
naterock101 opened this issue Feb 2, 2023 · 0 comments
Open

Comments

@naterock101
Copy link

in order to customize the attachment manger we need to make the tintColor property assignable. Right now the backgorund color for the delete button will always be blue.

if we want to change it such as:

let manager = AttachmentManager()
manager.tintColor = UIColor.green

we get an error: Cannot assign to property: 'tintColor' is a get-only property"

a solution could look like:

open var tintColor: UIColor {
    get {
        if #available(iOS 13, *) {
            return .link
        } else {
            return .systemBlue
        }
    }
    set {
        // Implementation to set the value of tintColor
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant