diff --git a/VDS/Components/Toggle/Toggle.swift b/VDS/Components/Toggle/Toggle.swift index 5e43393d..17c74373 100644 --- a/VDS/Components/Toggle/Toggle.swift +++ b/VDS/Components/Toggle/Toggle.swift @@ -136,6 +136,8 @@ open class ToggleBase: Control, Accessable, DataTrackable, BinaryColorable { // MARK: - Public Properties //-------------------------------------------------- open var isOn: Bool = false { didSet { didChange() }} + + open var isAnimated: Bool = true { didSet { didChange() }} open var showText: Bool = false { didSet { didChange() }} @@ -200,7 +202,7 @@ open class ToggleBase: Control, Accessable, DataTrackable, BinaryColorable { let toggleColor = toggleColorConfiguration.getColor(self) let knobColor = knobColorConfiguration.getColor(self) - if disabled { + if disabled || !isAnimated { toggleView.backgroundColor = toggleColor knobView.backgroundColor = knobColor constrainKnob()