Turn on hyphen auto for word breaks.

Before, if a word like "Continue" has to be broken into separate lines,
there was no hyphen. This turn on hyphenation.

Bug: 329786214
Test: See bug for screenshots.
Change-Id: Ide788ff263f11ee2faea77101d40597343352f63
diff --git a/packages/CredentialManager/src/com/android/credentialmanager/common/ui/Texts.kt b/packages/CredentialManager/src/com/android/credentialmanager/common/ui/Texts.kt
index 9111e61..68c2244 100644
--- a/packages/CredentialManager/src/com/android/credentialmanager/common/ui/Texts.kt
+++ b/packages/CredentialManager/src/com/android/credentialmanager/common/ui/Texts.kt
@@ -23,6 +23,7 @@
 import androidx.compose.ui.Modifier
 import androidx.compose.ui.graphics.Color
 import androidx.compose.ui.text.TextLayoutResult
+import androidx.compose.ui.text.style.Hyphens
 import androidx.compose.ui.text.style.TextAlign
 import androidx.compose.ui.text.style.TextOverflow
 import com.android.compose.theme.LocalAndroidColorScheme
@@ -39,7 +40,7 @@
         text = text,
         color = LocalAndroidColorScheme.current.onSurface,
         textAlign = TextAlign.Center,
-        style = MaterialTheme.typography.headlineSmall,
+        style = MaterialTheme.typography.headlineSmall.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -52,7 +53,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = LocalAndroidColorScheme.current.onSurfaceVariant,
-        style = MaterialTheme.typography.bodyMedium,
+        style = MaterialTheme.typography.bodyMedium.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -70,7 +71,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = LocalAndroidColorScheme.current.onSurfaceVariant,
-        style = MaterialTheme.typography.bodySmall,
+        style = MaterialTheme.typography.bodySmall.copy(hyphens = Hyphens.Auto),
         overflow = TextOverflow.Ellipsis,
         maxLines = if (enforceOneLine) 1 else Int.MAX_VALUE,
         onTextLayout = onTextLayout,
@@ -86,7 +87,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = LocalAndroidColorScheme.current.onSurface,
-        style = MaterialTheme.typography.titleLarge,
+        style = MaterialTheme.typography.titleLarge.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -104,7 +105,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = LocalAndroidColorScheme.current.onSurface,
-        style = MaterialTheme.typography.titleSmall,
+        style = MaterialTheme.typography.titleSmall.copy(hyphens = Hyphens.Auto),
         overflow = TextOverflow.Ellipsis,
         maxLines = if (enforceOneLine) 1 else Int.MAX_VALUE,
         onTextLayout = onTextLayout,
@@ -120,7 +121,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = color,
-        style = MaterialTheme.typography.titleSmall,
+        style = MaterialTheme.typography.titleSmall.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -133,7 +134,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = MaterialTheme.colorScheme.inverseOnSurface,
-        style = MaterialTheme.typography.bodyMedium,
+        style = MaterialTheme.typography.bodyMedium.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -146,7 +147,7 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         color = MaterialTheme.colorScheme.inversePrimary,
-        style = MaterialTheme.typography.labelLarge,
+        style = MaterialTheme.typography.labelLarge.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -160,7 +161,7 @@
         text = text,
         textAlign = TextAlign.Center,
         color = LocalAndroidColorScheme.current.onSurfaceVariant,
-        style = MaterialTheme.typography.labelLarge,
+        style = MaterialTheme.typography.labelLarge.copy(hyphens = Hyphens.Auto),
     )
 }
 
@@ -173,6 +174,6 @@
         modifier = modifier.wrapContentSize(),
         text = text,
         textAlign = TextAlign.Center,
-        style = MaterialTheme.typography.labelLarge,
+        style = MaterialTheme.typography.labelLarge.copy(hyphens = Hyphens.Auto),
     )
 }
\ No newline at end of file