From 980642e72c537d73d7c5d90eb00e43b7f2d4db46 Mon Sep 17 00:00:00 2001 From: Matt Bruce Date: Tue, 30 Aug 2022 17:09:37 -0500 Subject: [PATCH] pulled in protocol method Signed-off-by: Matt Bruce --- .../RadioSwatch/RadioSwatchModel.swift | 42 +++++++++---------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/VDS/Components/RadioSwatch/RadioSwatchModel.swift b/VDS/Components/RadioSwatch/RadioSwatchModel.swift index 265725be..b9858e90 100644 --- a/VDS/Components/RadioSwatch/RadioSwatchModel.swift +++ b/VDS/Components/RadioSwatch/RadioSwatchModel.swift @@ -16,28 +16,28 @@ public protocol RadioSwatchModel: Modelable, FormFieldable, DataTrackable, Acces var strikethrough: Bool { get set } } +public func == (lhs: any RadioSwatchModel, rhs: any RadioSwatchModel) -> Bool { + return lhs.selected == rhs.selected && + lhs.fillImage == rhs.fillImage && + lhs.primaryColor == rhs.primaryColor && + lhs.secondaryColor == rhs.secondaryColor && + lhs.secondaryColor == rhs.secondaryColor && + lhs.strikethrough == rhs.strikethrough && + lhs.inputId == rhs.inputId && + lhs.value == rhs.value && + lhs.surface == rhs.surface && + lhs.disabled == rhs.disabled && + lhs.dataAnalyticsTrack == rhs.dataAnalyticsTrack && + lhs.dataClickStream == rhs.dataClickStream && + lhs.accessibilityHintEnabled == rhs.accessibilityHintEnabled && + lhs.accessibilityHintDisabled == rhs.accessibilityHintDisabled && + lhs.accessibilityValueEnabled == rhs.accessibilityValueEnabled && + lhs.accessibilityValueDisabled == rhs.accessibilityValueDisabled && + lhs.accessibilityLabelEnabled == rhs.accessibilityLabelEnabled && + lhs.accessibilityLabelDisabled == rhs.accessibilityLabelDisabled +} + public struct DefaultRadioSwatchModel: RadioSwatchModel { - public static func == (lhs: DefaultRadioSwatchModel, rhs: DefaultRadioSwatchModel) -> Bool { - return lhs.selected == rhs.selected && - lhs.fillImage == rhs.fillImage && - lhs.primaryColor == rhs.primaryColor && - lhs.secondaryColor == rhs.secondaryColor && - lhs.secondaryColor == rhs.secondaryColor && - lhs.strikethrough == rhs.strikethrough && - lhs.inputId == rhs.inputId && - lhs.value == rhs.value && - lhs.surface == rhs.surface && - lhs.disabled == rhs.disabled && - lhs.dataAnalyticsTrack == rhs.dataAnalyticsTrack && - lhs.dataClickStream == rhs.dataClickStream && - lhs.accessibilityHintEnabled == rhs.accessibilityHintEnabled && - lhs.accessibilityHintDisabled == rhs.accessibilityHintDisabled && - lhs.accessibilityValueEnabled == rhs.accessibilityValueEnabled && - lhs.accessibilityValueDisabled == rhs.accessibilityValueDisabled && - lhs.accessibilityLabelEnabled == rhs.accessibilityLabelEnabled && - lhs.accessibilityLabelDisabled == rhs.accessibilityLabelDisabled - } - public var selected: Bool = false