Outcome
Card accepts an enabled parameter and handles disabled opacity and click blocking internally.
Problem
Card is a wrapper with no concept of a disabled state; callers must manually apply disabled opacity and suppress interactions, leading to inconsistent implementations across the codebase.
Context
Current behaviour: there is no enabled parameter on Card, so consumers replicate disabled logic themselves.
Source file: spark/src/main/kotlin/com/adevinta/spark/components/card/Card.kt
Scope
- Add an
enabled: Boolean = true parameter to Card.
- Apply disabled visual (reduced opacity) and block clicks when
enabled = false.
Acceptance criteria
- Setting
enabled = false on Card renders it at the disabled opacity and ignores click events.
- A screenshot test covers the disabled visual state.
- A UI test confirms clicks are suppressed when disabled.
Evidence
Outcome
Cardaccepts anenabledparameter and handles disabled opacity and click blocking internally.Problem
Cardis a wrapper with no concept of a disabled state; callers must manually apply disabled opacity and suppress interactions, leading to inconsistent implementations across the codebase.Context
Current behaviour: there is no
enabledparameter onCard, so consumers replicate disabled logic themselves.Source file: spark/src/main/kotlin/com/adevinta/spark/components/card/Card.kt
Scope
enabled: Boolean = trueparameter toCard.enabled = false.Acceptance criteria
enabled = falseonCardrenders it at the disabled opacity and ignores click events.Evidence
enabledparameter