diff options
Diffstat (limited to 'src/viewmodel/address.rs')
-rw-r--r-- | src/viewmodel/address.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/viewmodel/address.rs b/src/viewmodel/address.rs index 6fd3173..26e168a 100644 --- a/src/viewmodel/address.rs +++ b/src/viewmodel/address.rs @@ -29,6 +29,7 @@ impl VCardPropertyInputObject<AddressView> for Address { } } fn get_input_fields(&self, link: &ComponentLink<AddressView>) -> Vec<VCardPropertyInputField> { + let typ = String::from("text"); vec![ VCardPropertyInputField::Text{ label: "Post Office Box".to_string(), @@ -36,6 +37,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdatePostOfficeBox(e.value)), value: self.post_office_box.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Extension".to_string(), @@ -43,6 +45,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateExtension(e.value)), value: self.extension.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Street".to_string(), @@ -50,6 +53,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateStreet(e.value)), value: self.street.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Locality".to_string(), @@ -57,6 +61,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateLocality(e.value)), value: self.locality.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Region".to_string(), @@ -64,6 +69,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateRegion(e.value)), value: self.region.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Code".to_string(), @@ -71,6 +77,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateCode(e.value)), value: self.code.clone(), + typ: typ.clone(), }, VCardPropertyInputField::Text{ label: "Country".to_string(), @@ -78,6 +85,7 @@ impl VCardPropertyInputObject<AddressView> for Address { placeholder: None, oninput: link.callback(|e: InputData| Msg::UpdateCountry(e.value)), value: self.country.clone(), + typ, }, VCardPropertyInputField::CheckBox{ label: "Work".to_string(), |