Skip to content

Commit 49ce553

Browse files
committed
Make the icons show and make some other minor improvements
A bug that `NavButton` is called redundantly in `TopAppBarScaffold` in `jsMain` is fixed.
1 parent 2e3d994 commit 49ce553

File tree

3 files changed

+3
-2
lines changed
  • compose-multiplatform-material/src/jsMain/kotlin/com/huanshankeji/compose/material
  • demo/src

3 files changed

+3
-2
lines changed

compose-multiplatform-material/src/jsMain/kotlin/com/huanshankeji/compose/material/Components.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ actual fun TopAppBarScaffold(
7272
TopAppBar {
7373
Row {
7474
Section(align = MDCTopAppBarSectionAlign.Start) {
75-
navigationIcon?.let { NavButton { NavigationIconScope(this@Section).it() } }
75+
navigationIcon?.let { NavigationIconScope(this@Section).it() }
7676
Title { title() }
7777
}
7878
Section(

demo/src/commonMain/kotlin/com/huanshankeji/compose/material/demo/Composables.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import com.huanshankeji.compose.material.icon.MaterialIcons
99
@Composable
1010
fun App() {
1111
TopAppBarScaffold({
12-
Text("Demo")
12+
Text("Compose Multiplatform Material demo")
1313
}, {
1414
MaterialIconNavButton({}, MaterialIcons.Menu)
1515
}, {

demo/src/jsMain/resources/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
66
<meta charset="UTF-8">
77
<title>Compose Multiplatform Material demo</title>
8+
<link href="https://fonts.googleapis.com/css?family=Material+Icons&display=block" rel="stylesheet">
89
</head>
910

1011
<body>

0 commit comments

Comments
 (0)