Skip to content

Commit

Permalink
Merge pull request #18 from mori-atsushi/v.0.1.0-alpha02
Browse files Browse the repository at this point in the history
Prepare v0.1.0 alpha02
  • Loading branch information
mori-atsushi authored May 6, 2023
2 parents 03da479 + c88ab92 commit d4e3a38
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## InsetsX [🚧 Work in progress 🚧]
[![](https://img.shields.io/badge/Kotlin-Multiplatform-%237f52ff?logo=kotlin)](https://kotlinlang.org/docs/multiplatform.html)
[![](https://img.shields.io/maven-central/v/com.moriatsushi.insetsx/insetsx)](https://mvnrepository.com/artifact/com.moriatsushi.insetsx/insetsx)
[![](https://img.shields.io/github/license/mori-atsushi/insetsx)](https://github.com/mori-atsushi/insetsx/blob/main/LISENCE)
[![](https://img.shields.io/github/license/mori-atsushi/insetsx)](https://github.com/mori-atsushi/insetsx/blob/main/LICENSE)

<img src="https://user-images.githubusercontent.com/13435109/236607484-22248c02-65de-4954-97a3-349907a2343e.png" width="720px"/>

Expand Down Expand Up @@ -35,10 +35,15 @@ Please note that the package name is different.
```kotlin
import androidx.compose.foundation.layout.windowInsetsPadding
import androidx.compose.foundation.layout.WindowInsets
import androidx.compose.ui.Modifier
import com.moriatsushi.insetsx.systemBars
import com.moriatsushi.insetsx.systemBarsPadding

val modifier = Modifier
val modifier1 = Modifier
.windowInsetsPadding(WindowInsets.systemBars)

val modifier2 = Modifier
.systemBarsPadding()
```

## APIs
Expand All @@ -50,5 +55,10 @@ WindowInsets.navigationBars|navigation bar|bottom of SafeArea
WindowInsets.statusBars|status bar|top and horizontal of SafeArea
WindowInsets.ime *1|software keyboard|software keyboard
WindowInsets.safeDrawing *1|system bars + software keyboard|SafeArea + software keyboard
Modifier.systemBarsPadding()|status bar + navigation bar|SafeArea
Modifier.navigationBarsPadding()|navigation bar|bottom of SafeArea
Modifier.statusBarsPadding()|status bar|top and horizontal of SafeArea
Modifier.imePadding() *1|software keyboard|software keyboard
Modifier.safeDrawingPadding() *1|system bars + software keyboard|SafeArea + software keyboard

*1 is experimental
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ org.jetbrains.compose.experimental.uikit.enabled=true
SONATYPE_HOST=S01
RELEASE_SIGNING_ENABLED=true
GROUP=com.moriatsushi.insetsx
VERSION_NAME=0.1.0-alpha01
VERSION_NAME=0.1.0-alpha02

POM_NAME=InsetsX
POM_DESCRIPTION=WindowInsets utility for compose multiplatform
Expand Down

0 comments on commit d4e3a38

Please sign in to comment.