Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 36d3d1ed authored by Qinmei Du's avatar Qinmei Du Committed by Android (Google) Code Review
Browse files

Merge "Change the create passkey subtitle to <Passkey - subtitle>"

parents c624e454 e3536fc1
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -34,6 +34,7 @@
  <string name="passkey">passkey</string>
  <string name="password">password</string>
  <string name="sign_ins">sign-ins</string>
  <string name="passkey_before_subtitle">Passkey</string>
  <string name="another_device">Another device</string>
  <string name="other_password_manager">Other password managers</string>
  <!-- TODO: Check the wording here. -->
+36 −18
Original line number Diff line number Diff line
@@ -576,19 +576,36 @@ fun PrimaryCreateOptionRow(
    label = {
      Column() {
        // TODO: Add the function to hide/view password when the type is create password
        if (requestDisplayInfo.type == TYPE_PUBLIC_KEY_CREDENTIAL ||
          requestDisplayInfo.type == TYPE_PASSWORD_CREDENTIAL) {
        when (requestDisplayInfo.type) {
            TYPE_PUBLIC_KEY_CREDENTIAL -> {
              Text(
                text = requestDisplayInfo.title,
                style = MaterialTheme.typography.titleLarge,
                modifier = Modifier.padding(top = 16.dp)
              )
              Text(
                text = if (requestDisplayInfo.subtitle != null) {
                  stringResource(
                    R.string.passkey_before_subtitle) + " - " + requestDisplayInfo.subtitle
                } else {stringResource(R.string.passkey_before_subtitle)},
                style = MaterialTheme.typography.bodyMedium,
                modifier = Modifier.padding(bottom = 16.dp)
              )
            }
            TYPE_PASSWORD_CREDENTIAL -> {
              Text(
                text = requestDisplayInfo.title,
                style = MaterialTheme.typography.titleLarge,
                modifier = Modifier.padding(top = 16.dp)
              )
              Text(
            text = requestDisplayInfo.subtitle,
                // This subtitle would never be null for create password
                text = requestDisplayInfo.subtitle ?: "",
                style = MaterialTheme.typography.bodyMedium,
                modifier = Modifier.padding(bottom = 16.dp)
              )
        } else {
            }
            else -> {
              Text(
                text = requestDisplayInfo.title,
                style = MaterialTheme.typography.titleLarge,
@@ -597,6 +614,7 @@ fun PrimaryCreateOptionRow(
            }
        }
      }
    }
  )
}

+1 −1
Original line number Diff line number Diff line
@@ -73,7 +73,7 @@ class RemoteInfo(

data class RequestDisplayInfo(
  val title: String,
  val subtitle: String,
  val subtitle: String?,
  val type: String,
  val appDomainName: String,
  val typeIcon: Drawable,