Browse Source
- Apply window insets for UI containers - Update the screenshot - Align gradle.properties with other examples - Add jetsnack to all example verification scriptspull/4755/head
Oleksandr Karpovich
7 months ago
committed by
GitHub
16 changed files with 46 additions and 65 deletions
@ -1,12 +1,12 @@ |
|||||||
package com.example.jetsnack.ui.home |
package com.example.jetsnack.ui.home |
||||||
|
|
||||||
import androidx.compose.foundation.layout.WindowInsets |
import androidx.compose.foundation.layout.WindowInsets |
||||||
|
import androidx.compose.foundation.layout.add |
||||||
|
import androidx.compose.foundation.layout.statusBars |
||||||
import androidx.compose.runtime.Composable |
import androidx.compose.runtime.Composable |
||||||
import androidx.compose.ui.unit.dp |
import androidx.compose.ui.unit.dp |
||||||
|
|
||||||
@Composable |
@Composable |
||||||
actual fun snackCollectionListItemWindowInsets(): WindowInsets { |
actual fun snackCollectionListItemWindowInsets(): WindowInsets { |
||||||
// TODO: implement |
return WindowInsets.statusBars.add(WindowInsets(top = 56.dp)) |
||||||
// WindowInsets.statusBars.add(WindowInsets(top = 56.dp)) |
|
||||||
return WindowInsets(top = 56.dp) |
|
||||||
} |
} |
@ -1,11 +1,21 @@ |
|||||||
package com.example.jetsnack.ui.snackdetail |
package com.example.jetsnack.ui.snackdetail |
||||||
|
|
||||||
|
import androidx.compose.foundation.layout.WindowInsets |
||||||
|
import androidx.compose.foundation.layout.navigationBars |
||||||
|
import androidx.compose.foundation.layout.statusBars |
||||||
|
import androidx.compose.foundation.layout.systemBars |
||||||
|
import androidx.compose.foundation.layout.windowInsetsPadding |
||||||
|
import androidx.compose.runtime.Composable |
||||||
import androidx.compose.ui.Modifier |
import androidx.compose.ui.Modifier |
||||||
|
|
||||||
actual fun Modifier.jetSnackNavigationBarsPadding(): Modifier = this |
@Composable |
||||||
// .navigationBarsPadding() |
actual fun Modifier.jetSnackNavigationBarsPadding(): Modifier = |
||||||
|
this.windowInsetsPadding(WindowInsets.navigationBars) |
||||||
|
|
||||||
actual fun Modifier.jetSnackStatusBarsPadding(): Modifier = this |
@Composable |
||||||
// statusBarsPadding() |
actual fun Modifier.jetSnackStatusBarsPadding(): Modifier = |
||||||
actual fun Modifier.jetSnackSystemBarsPadding(): Modifier = this |
this.windowInsetsPadding(WindowInsets.statusBars) |
||||||
// Modifier.systemBarsPadding() |
|
||||||
|
@Composable |
||||||
|
actual fun Modifier.jetSnackSystemBarsPadding(): Modifier = |
||||||
|
this.windowInsetsPadding(WindowInsets.systemBars) |
After Width: | Height: | Size: 2.8 MiB |
@ -1,5 +0,0 @@ |
|||||||
import { instantiate } from './jetsnackwasmapp.uninstantiated.mjs'; |
|
||||||
|
|
||||||
await wasmSetup; |
|
||||||
|
|
||||||
instantiate({ skia: Module['asm'] }); |
|
@ -1,7 +0,0 @@ |
|||||||
config.entry = { |
|
||||||
main: [require('path').resolve(__dirname, "kotlin/load.mjs")] |
|
||||||
}; |
|
||||||
|
|
||||||
config.resolve ?? (config.resolve = {}); |
|
||||||
config.resolve.alias ?? (config.resolve.alias = {}); |
|
||||||
config.resolve.alias.skia = false; |
|
Loading…
Reference in new issue