chore(list-item): update previews to add an edge-to-edge disabled preview - #1468
Conversation
🟢 Netlify deploy for commit 31da0c1 succeededDeploy preview: https://6a6cd21445d97375ebc93ef2--ouds-android.netlify.app |
|
|
||
| @Composable | ||
| internal fun PreviewOudsNavigationListItemWithEdgeToEdgeDisabled(theme: OudsThemeContract) = OudsPreview(theme = theme) { | ||
| PreviewEnumEntries<OudsControlState>(maxEnumEntriesInEachRow = 1) { |
There was a problem hiding this comment.
The enum should be OudsListItemState instead of OudsControlState. That explains why new snapshots don't take the state into account.
| import androidx.compose.runtime.setValue | ||
| import androidx.compose.ui.res.stringResource | ||
| import com.orange.ouds.app.R | ||
| import com.orange.ouds.app.ui.components.listitem.BaseListItemDemoState.IconTint |
There was a problem hiding this comment.
This import can be removed because there are some occurrences of BaseListItemDemoState.IconTint that are greyed out in the file.
Same comment for ListItemDemoState.
| ) | ||
| CustomizationFilterChips( | ||
| applyTopPadding = true, | ||
| label = stringResource(R.string.app_components_listItem_iconTint_tech), |
There was a problem hiding this comment.
Should we also update the title of other filter chips where there are only two values (Tinted and Untinted) to app_components_listItem_iconTint_tech instead of app_components_common_icon_tech?
| if (iconSize != OudsListItemDefaults.IconSize) { | ||
| typedArgument(sizeParameterName, iconSize) | ||
| } | ||
| if (iconTint != BaseListItemDemoState.IconTint.Tinted) { |
There was a problem hiding this comment.
The painter argument should also be updated according to the value of iconTint.
To do this we can reuse the iconArgument method from ComponentCode.kt, but we need the updated version from #1479 to be able to set the size parameter.
No description provided.