setAttribute method

  1. @override
void setAttribute(
  1. String qualifiedName,
  2. String val
)
override

Implementation

@override
void setAttribute(String qualifiedName, String val) {
  super.setAttribute(qualifiedName, val);
  switch (qualifiedName) {
    case 'width': width = attributeToProperty<int>(val); break;
    case 'height': height = attributeToProperty<int>(val); break;
    case 'rows': rows = attributeToProperty<int>(val); break;
    case 'cols': cols = attributeToProperty<int>(val); break;
    case 'value': defaultValue = attributeToProperty<String>(val); break;
    case 'autocomplete': autocomplete = attributeToProperty<String>(val); break;
    case 'autofocus': autofocus = attributeToProperty<bool>(val); break;
    case 'required': required = attributeToProperty<bool>(val); break;
    case 'readonly': readOnly = attributeToProperty<bool>(val); break;
    case 'name': name = attributeToProperty<String>(val); break;
    case 'disabled': disabled = attributeToProperty<bool>(val); break;
    case 'minlength': minLength = attributeToProperty<int>(val); break;
    case 'maxlength': maxLength = attributeToProperty<int>(val); break;
    case 'placeholder': placeholder = attributeToProperty<String>(val); break;
    case 'inputmode': inputMode = attributeToProperty<String>(val); break;
  }
}