updated trait
Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
parent
886577e945
commit
4f68f67a6b
@ -47,7 +47,7 @@ open class Badge: View {
|
|||||||
//--------------------------------------------------
|
//--------------------------------------------------
|
||||||
/// Label used to render text
|
/// Label used to render text
|
||||||
open var label = Label().with {
|
open var label = Label().with {
|
||||||
$0.isAccessibilityElement = false
|
$0.isAccessibilityElement = false
|
||||||
$0.lineBreakMode = .byTruncatingTail
|
$0.lineBreakMode = .byTruncatingTail
|
||||||
$0.setContentCompressionResistancePriority(.required, for: .vertical)
|
$0.setContentCompressionResistancePriority(.required, for: .vertical)
|
||||||
$0.setContentHuggingPriority(.defaultHigh, for: .vertical)
|
$0.setContentHuggingPriority(.defaultHigh, for: .vertical)
|
||||||
@ -133,6 +133,8 @@ open class Badge: View {
|
|||||||
open override func setup() {
|
open override func setup() {
|
||||||
super.setup()
|
super.setup()
|
||||||
isAccessibilityElement = true
|
isAccessibilityElement = true
|
||||||
|
accessibilityTraits = .staticText
|
||||||
|
|
||||||
layer.cornerRadius = 2
|
layer.cornerRadius = 2
|
||||||
|
|
||||||
addSubview(label)
|
addSubview(label)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user