Skip to content

Commit

Permalink
adding alignment to pillbar (#521)
Browse files Browse the repository at this point in the history
Co-authored-by: PraveenKumar <[email protected]>
  • Loading branch information
praveen970 and PraveenKumar authored Sep 22, 2023
1 parent a0e9585 commit ad3ca0e
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@ fun PillButton(
* @param modifier
* @param style
* @param showBackground
* @param pillAlignment
* @param pillButtonTokens
* @param pillBarTokens
*/
Expand All @@ -240,6 +241,7 @@ fun PillBar(
modifier: Modifier = Modifier,
style: FluentStyle = FluentStyle.Neutral,
showBackground: Boolean = false,
pillAlignment: Alignment.Horizontal = Alignment.CenterHorizontally,
pillButtonTokens: PillButtonTokens? = null,
pillBarTokens: PillBarTokens? = null
) {
Expand All @@ -261,7 +263,7 @@ fun PillBar(
.background(if (showBackground) token.backgroundBrush(pillBarInfo) else SolidColor(Color.Unspecified))
.focusable(enabled = false),
contentPadding = PaddingValues(horizontal = 16.dp),
horizontalArrangement = Arrangement.spacedBy(8.dp, Alignment.CenterHorizontally),
horizontalArrangement = Arrangement.spacedBy(8.dp, pillAlignment),
state = lazyListState
) {
metadataList.forEachIndexed { index, pillMetadata ->
Expand Down

0 comments on commit ad3ca0e

Please sign in to comment.