static bool isValidId(String idAttr) { return RegExp(r'^[a-zA-Z0-9_\-:.]{1,500}$', caseSensitive: false) .hasMatch(idAttr); }