ProfileScreen constructor

const ProfileScreen({
  1. Key? key,
  2. String screenTitle = "Profile",
  3. bool showLabels = true,
  4. ThemeGroupType labelType = ThemeGroupType.MOP,
  5. Emphasis labelEmphasis = Emphasis.NONE,
  6. TextAlign labelTextAlign = TextAlign.start,
  7. bool? showIcons,
  8. ThemeGroupType prefixIconType = ThemeGroupType.MOM,
  9. Emphasis prefixIconEmphasis = Emphasis.NONE,
  10. ThemeGroupType textType = ThemeGroupType.POM,
  11. Emphasis textEmphasis = Emphasis.HIGH,
  12. TextAlign textAlign = TextAlign.start,
  13. ThemeGroupType textFieldBackgroundType = ThemeGroupType.MOP,
  14. ThemeGroupType valueTextType = ThemeGroupType.MOP,
  15. Emphasis valueTextEmphasis = Emphasis.HIGH,
  16. TextAlign valueTextAlign = TextAlign.start,
  17. bool? showHints,
  18. ThemeGroupType hintTextType = ThemeGroupType.MOM,
  19. Emphasis hintTextEmphasis = Emphasis.NONE,
  20. String email = "",
  21. bool showEmail = true,
  22. bool canEditEmail = true,
  23. bool obscureEmail = false,
  24. ValueChanged<String>? onEmailChangedCallback,
  25. String emailLabel = "Email",
  26. bool? showEmailLabel,
  27. String emailHint = "Email",
  28. bool? showEmailHint,
  29. IconData? emailIcon = Icons.email,
  30. bool? showEmailIcon,
  31. bool validateEmail = true,
  32. String invalidEmailText = "Email is required",
  33. String password = "",
  34. bool showPassword = true,
  35. bool canEditPassword = true,
  36. bool obscurePassword = false,
  37. ValueChanged<String>? onPasswordChangedCallback,
  38. String passwordLabel = "Password",
  39. bool? showPasswordLabel,
  40. String passwordHint = "Password",
  41. bool? showPasswordHint,
  42. IconData? passwordIcon = Icons.password,
  43. bool? showPasswordIcon,
  44. bool validatePassword = true,
  45. String invalidPasswordText = "Enter a password 6+ chars long",
  46. int passwordMinimumLength = 6,
  47. String firstName = "",
  48. bool showFirstName = true,
  49. bool canEditFirstName = true,
  50. bool obscureFirstName = false,
  51. ValueChanged<String>? onFirstNameChangedCallback,
  52. String firstNameLabel = "First Name",
  53. bool? showFirstNameLabel,
  54. String firstNameHint = "First Name",
  55. bool? showFirstNameHint,
  56. IconData? firstNameIcon,
  57. bool? showFirstNameIcon,
  58. bool validateFirstName = true,
  59. String invalidFirstNameText = "First name is required",
  60. String lastName = "",
  61. bool showLastName = true,
  62. bool canEditLastName = true,
  63. bool obscureLastName = false,
  64. ValueChanged<String>? onLastNameChangedCallback,
  65. String lastNameLabel = "Last Name",
  66. bool? showLastNameLabel,
  67. String lastNameHint = "Last Name",
  68. bool? showLastNameHint,
  69. IconData? lastNameIcon,
  70. bool? showLastNameIcon,
  71. bool validateLastName = true,
  72. String invalidLastNameText = "Last name is required",
  73. String tagline = "",
  74. bool showTagline = true,
  75. bool canEditTagline = true,
  76. bool obscureTagline = false,
  77. ValueChanged<String>? onTaglineChangedCallback,
  78. String taglineLabel = "Tagline",
  79. bool? showTaglineLabel,
  80. String taglineHint = "Tagline",
  81. bool? showTaglineHint,
  82. IconData? taglineIcon,
  83. bool? showTaglineIcon,
  84. String pronouns = "",
  85. bool showPronouns = true,
  86. bool canEditPronouns = true,
  87. bool obscurePronouns = false,
  88. ValueChanged<String>? onPronounsChangedCallback,
  89. String pronounsLabel = "Pronouns",
  90. bool? showPronounsLabel,
  91. String pronounsHint = "Pronouns",
  92. bool? showPronounsHint,
  93. IconData? pronounsIcon,
  94. bool? showPronounsIcon,
  95. String organization = "",
  96. bool showOrganization = true,
  97. bool canEditOrganization = true,
  98. bool obscureOrganization = false,
  99. ValueChanged<String>? onOrganizationChangedCallback,
  100. String organizationLabel = "Organization",
  101. bool? showOrganizationLabel,
  102. String organizationHint = "Organization",
  103. bool? showOrganizationHint,
  104. IconData? organizationIcon,
  105. bool? showOrganizationIcon,
  106. String address = "",
  107. bool showAddress = true,
  108. bool canEditAddress = true,
  109. bool obscureAddress = false,
  110. ValueChanged<String>? onAddressChangedCallback,
  111. String addressLabel = "Address",
  112. bool? showAddressLabel,
  113. String addressHint = "Address",
  114. bool? showAddressHint,
  115. IconData? addressIcon,
  116. bool? showAddressIcon,
  117. String city = "",
  118. bool showCity = true,
  119. bool canEditCity = true,
  120. bool obscureCity = false,
  121. ValueChanged<String>? onCityChangedCallback,
  122. String cityLabel = "City",
  123. bool? showCityLabel,
  124. String cityHint = "City",
  125. bool? showCityHint,
  126. IconData? cityIcon,
  127. bool? showCityIcon,
  128. String state = "",
  129. bool showState = true,
  130. bool canEditState = true,
  131. bool obscureState = false,
  132. ValueChanged<String>? onStateChangedCallback,
  133. String stateLabel = "State",
  134. bool? showStateLabel,
  135. String stateHint = "State",
  136. bool? showStateHint,
  137. IconData? stateIcon,
  138. bool? showStateIcon,
  139. String zip = "",
  140. bool showZip = true,
  141. bool canEditZip = true,
  142. bool obscureZip = false,
  143. ValueChanged<String>? onZipChangedCallback,
  144. String zipLabel = "Zip",
  145. bool? showZipLabel,
  146. String zipHint = "Zip",
  147. bool? showZipHint,
  148. IconData? zipIcon,
  149. bool? showZipIcon,
  150. bool validateZip = true,
  151. String invalidZipText = "Zip is required",
  152. String logoutText = "Logout",
  153. VoidCallback? onTapLogout,
  154. String editText = "Edit",
  155. VoidCallback? onTapEdit,
  156. String saveText = "Save",
  157. VoidCallback? onTapSave,
  158. String deleteAccount = "Delete",
  159. VoidCallback? onTapDeleteAccount,
  160. bool doShowLoginRegisterButtons = true,
  161. EdgeInsets padding = const EdgeInsets.symmetric(vertical: 0.0, horizontal: paddingMini),
  162. bool isHeaderSticky = true,
  163. bool isFooterSticky = true,
  164. bool isFooterVertical = false,
  165. EdgeInsets headerPadding = const EdgeInsets.all(paddingMini),
  166. EdgeInsets footerPadding = const EdgeInsets.all(paddingMini),
  167. bool centerForm = true,
  168. bool isEditMode = false,
})

Implementation

const ProfileScreen({
  super.key,

  this.screenTitle = "Profile",

  this.showLabels = true,
  this.labelType = ThemeGroupType.MOP,
  this.labelEmphasis = Emphasis.NONE,
  this.labelTextAlign = TextAlign.start,

  this.showIcons,
  this.prefixIconType = ThemeGroupType.MOM,
  this.prefixIconEmphasis = Emphasis.NONE,

  this.textType = ThemeGroupType.POM,
  this.textEmphasis = Emphasis.HIGH,
  this.textAlign = TextAlign.start,
  this.textFieldBackgroundType = ThemeGroupType.MOP,

  this.valueTextType = ThemeGroupType.MOP,
  this.valueTextEmphasis = Emphasis.HIGH,
  this.valueTextAlign = TextAlign.start,

  this.showHints,
  this.hintTextType = ThemeGroupType.MOM,
  this.hintTextEmphasis = Emphasis.NONE,
  // this.hintTextAlign = TextAlign.start,

  this.email = "",
  this.showEmail = true,
  this.canEditEmail = true,
  this.obscureEmail = false,
  this.onEmailChangedCallback,
  this.emailLabel = "Email",
  this.showEmailLabel,
  this.emailHint = "Email",
  this.showEmailHint,
  this.emailIcon = Icons.email,
  this.showEmailIcon,
  this.validateEmail = true,
  this.invalidEmailText = "Email is required",

  this.password = "",
  this.showPassword = true,
  this.canEditPassword = true,
  this.obscurePassword = false,
  this.onPasswordChangedCallback,
  this.passwordLabel = "Password",
  this.showPasswordLabel,
  this.passwordHint = "Password",
  this.showPasswordHint,
  this.passwordIcon = Icons.password,
  this.showPasswordIcon,
  this.validatePassword = true,
  this.invalidPasswordText = "Enter a password 6+ chars long",
  this.passwordMinimumLength = 6,

  this.firstName = "",
  this.showFirstName = true,
  this.canEditFirstName = true,
  this.obscureFirstName = false,
  this.onFirstNameChangedCallback,
  this.firstNameLabel = "First Name",
  this.showFirstNameLabel,
  this.firstNameHint = "First Name",
  this.showFirstNameHint,
  this.firstNameIcon,
  this.showFirstNameIcon,
  this.validateFirstName = true,
  this.invalidFirstNameText = "First name is required",

  this.lastName = "",
  this.showLastName = true,
  this.canEditLastName = true,
  this.obscureLastName = false,
  this.onLastNameChangedCallback,
  this.lastNameLabel = "Last Name",
  this.showLastNameLabel,
  this.lastNameHint = "Last Name",
  this.showLastNameHint,
  this.lastNameIcon,
  this.showLastNameIcon,
  this.validateLastName = true,
  this.invalidLastNameText = "Last name is required",

  this.tagline = "",
  this.showTagline = true,
  this.canEditTagline = true,
  this.obscureTagline = false,
  this.onTaglineChangedCallback,
  this.taglineLabel = "Tagline",
  this.showTaglineLabel,
  this.taglineHint = "Tagline",
  this.showTaglineHint,
  this.taglineIcon,
  this.showTaglineIcon,

  this.pronouns = "",
  this.showPronouns = true,
  this.canEditPronouns = true,
  this.obscurePronouns = false,
  this.onPronounsChangedCallback,
  this.pronounsLabel = "Pronouns",
  this.showPronounsLabel,
  this.pronounsHint = "Pronouns",
  this.showPronounsHint,
  this.pronounsIcon,
  this.showPronounsIcon,

  this.organization = "",
  this.showOrganization = true,
  this.canEditOrganization = true,
  this.obscureOrganization = false,
  this.onOrganizationChangedCallback,
  this.organizationLabel = "Organization",
  this.showOrganizationLabel,
  this.organizationHint = "Organization",
  this.showOrganizationHint,
  this.organizationIcon,
  this.showOrganizationIcon,

  this.address = "",
  this.showAddress = true,
  this.canEditAddress = true,
  this.obscureAddress = false,
  this.onAddressChangedCallback,
  this.addressLabel = "Address",
  this.showAddressLabel,
  this.addressHint = "Address",
  this.showAddressHint,
  this.addressIcon,
  this.showAddressIcon,

  this.city = "",
  this.showCity = true,
  this.canEditCity = true,
  this.obscureCity = false,
  this.onCityChangedCallback,
  this.cityLabel = "City",
  this.showCityLabel,
  this.cityHint = "City",
  this.showCityHint,
  this.cityIcon,
  this.showCityIcon,

  this.state = "",
  this.showState = true,
  this.canEditState = true,
  this.obscureState = false,
  this.onStateChangedCallback,
  this.stateLabel = "State",
  this.showStateLabel,
  this.stateHint = "State",
  this.showStateHint,
  this.stateIcon,
  this.showStateIcon,

  this.zip = "",
  this.showZip = true,
  this.canEditZip = true,
  this.obscureZip = false,
  this.onZipChangedCallback,
  this.zipLabel = "Zip",
  this.showZipLabel,
  this.zipHint = "Zip",
  this.showZipHint,
  this.zipIcon,
  this.showZipIcon,
  this.validateZip = true,
  this.invalidZipText = "Zip is required",

  this.logoutText = "Logout",
  this.onTapLogout,

  this.editText = "Edit",
  this.onTapEdit,

  this.saveText = "Save",
  this.onTapSave,

  this.deleteAccount = "Delete",
  this.onTapDeleteAccount,

  this.doShowLoginRegisterButtons = true,
  this.padding = const EdgeInsets.symmetric(vertical: 0.0, horizontal: paddingMini),
  this.isHeaderSticky = true,
  this.isFooterSticky = true,
  this.isFooterVertical = false,
  this.headerPadding = const EdgeInsets.all(paddingMini),
  this.footerPadding = const EdgeInsets.all(paddingMini),
  this.centerForm = true,
  this.isEditMode = false
});