updated sample

Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
Matt Bruce 2022-08-16 16:11:20 -05:00
parent 239d6f66e3
commit b69db764b5
2 changed files with 4 additions and 17 deletions

View File

@ -47,13 +47,6 @@ class CheckboxViewController: ModelViewController<DefaultCheckboxModel>, Storyb
var defaultModel = DefaultCheckboxModel()
defaultModel.labelText = "Terms and conditions"
defaultModel.childText = "I agree to Verizon's terms and conditions click here"
defaultModel.childTextAttributes = [
LabelAttributeUnderline(location: 11, length: 10),
LabelAttributeStrikeThrough(location: 22, length: 5),
LabelAttributeColor(location: 31, length: 10, color: UIColor.blue.hexString!),
LabelAttributeActionModel(location: 31, length: 10){ print("clicked on the word 'conditions'") },
LabelAttributeFont(location: 2, length: 5, style: .BoldTitleLarge, color: UIColor.red.hexString!)
]
defaultModel.errorText = "Error Text"
model = defaultModel

View File

@ -50,19 +50,13 @@ class RadioButtonViewController: ModelViewController<DefaultRadioButtonGroupMod
var defaultModel = DefaultRadioButtonGroupModel()
var model1 = DefaultRadioButtonModel()
model1.value = "model 1 Value"
model1.labelText = "Terms and conditions"
model1.childText = "I agree to Verizon's terms and conditions click here"
model1.childTextAttributes = [
LabelAttributeUnderline(location: 11, length: 10),
LabelAttributeStrikeThrough(location: 22, length: 5),
LabelAttributeColor(location: 31, length: 10, color: UIColor.blue.hexString!),
LabelAttributeActionModel(location: 31, length: 10){ print("clicked on the word 'conditions'") },
LabelAttributeFont(location: 2, length: 5, style: .BoldTitleLarge, color: UIColor.red.hexString!)
]
model1.labelText = "iPhone 11 Bundle 1"
model1.childText = "Apple iPhone 11 - 64 GB\nOtterbox Case Red\nScreen Protector"
var model2 = DefaultRadioButtonModel()
model2.value = "model 2 Value"
model2.childText = "Radio Sample 2"
model2.labelText = "iPhone 11 Bundle 2"
model2.childText = "Apple iPhone 11 - 128 GB\nOtterbox Case Black\nScreen Protector"
defaultModel.selectors = [model1, model2]
model = defaultModel