Azure-Samples/active-directory-b2c-advanced-policies

UserInputType should include "Email"

ChaseFlorell opened this issue · 1 comments

When we create a ClaimType for an email address, we should be able to define the UserInputType as Email so that we can have the correct keyboard on screen when using a mobile device.

Proposal

  <xs:simpleType name="UserInputType">
    <xs:annotation>
      <xs:documentation>
        Represents the type of input controls that should be available to the user when manually entering claim data.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="TextBox"/>
      <xs:enumeration value="DateTimeDropdown"/>
      <xs:enumeration value="RadioSingleSelect"/>
      <xs:enumeration value="DropdownSingleSelect"/>
      <xs:enumeration value="CheckboxMultiSelect"/>
      <xs:enumeration value="Password"/>
      <xs:enumeration value="Readonly"/>
      <xs:enumeration value="Button"/>
     <!-- ADD THIS -->
      <xs:enumeration value="Email"/>
    </xs:restriction>
  </xs:simpleType>

Use Like This

<ClaimType Id="signInName">
  <DisplayName>Email Address</DisplayName>
  <DataType>string</DataType>
  <UserHelpText/>
  <UserInputType>Email</UserInputType>
</ClaimType>

Generates an email input field.

<input type="email">

Allowing the browser to display the correct keyboard on mobile devices.

put this on the wrong repo