You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Snackbar, SnackbarHost, SnackbarHostState
(androidx.compose.material3.SnackbarKt) — also needed by Scaffold's snackbarHost slot in Bind Scaffold and use it in the sample #12
Bind each via the same shape as the existing facades. Most of these
have stripped overloads (color-bearing @JvmInline value class params),
so they'll need raw-JNI bridges + declarative [ComposeDefaults]
attributes. Verify mangled names with javap against Xamarin.AndroidX.Compose.Material3Android 1.4.0.3.
State holder: Snackbar needs SnackbarHostState. Check whether SnackbarHostState is plain enough to use the bound C# constructor or
needs the same JNI-bridge treatment as DatePickerState / TimePickerState from PR #9.
Sample
Wrap the per-tab content in a Scaffold (depends on #12) with:
A CenterAlignedTopAppBar showing the current tab name as title
The existing NavigationBar as bottomBar
Replace the home-grown NavigationBar tab switcher with the proper TabRow + Tab API on at least one tab to demonstrate it
Add a Snackbar triggered by a button on the Buttons tab
Why
The Compose app-structure components — what most apps build their
chrome out of — are entirely missing:
TopAppBar,CenterAlignedTopAppBar,MediumTopAppBar,LargeTopAppBar(androidx.compose.material3.AppBarKt)TabRow,ScrollableTabRow,PrimaryTabRow,SecondaryTabRow,Tab,LeadingIconTab(androidx.compose.material3.TabRowKt+TabKt)Snackbar,SnackbarHost,SnackbarHostState(
androidx.compose.material3.SnackbarKt) — also needed byScaffold'ssnackbarHostslot in Bind Scaffold and use it in the sample #12Badge,BadgedBox(androidx.compose.material3.BadgeKt)ListItem(androidx.compose.material3.ListItemKt)What
Bind each via the same shape as the existing facades. Most of these
have stripped overloads (color-bearing
@JvmInline value classparams),so they'll need raw-JNI bridges + declarative
[ComposeDefaults]attributes. Verify mangled names with
javapagainstXamarin.AndroidX.Compose.Material3Android1.4.0.3.State holder:
SnackbarneedsSnackbarHostState. Check whetherSnackbarHostStateis plain enough to use the bound C# constructor orneeds the same JNI-bridge treatment as
DatePickerState/TimePickerStatefrom PR #9.Sample
Wrap the per-tab content in a
Scaffold(depends on #12) with:CenterAlignedTopAppBarshowing the current tab name as titleNavigationBarasbottomBarNavigationBartab switcher with the properTabRow+TabAPI on at least one tab to demonstrate itSnackbartriggered by a button on the Buttons tab