compose-hig
1.1.0indexediOS-style UI components and controls with improved SwipeBox, fixed date-picker scrolling, disabled bottom-sheet content scaling, dialog-for-popup behavior, automated releases and live web demo.
iOS-style UI components and controls with improved SwipeBox, fixed date-picker scrolling, disabled bottom-sheet content scaling, dialog-for-popup behavior, automated releases and live web demo.
A modern, highly customizable Compose Multiplatform library implementing Apple's Human Interface Guidelines (HIG) with Liquid Glass visuals, native haptic feedback dynamics, and smooth spring physics.
Forked and expanded from alexzhirkevich/compose-cupertino and slanos/compose-cupertino.
https://github.com/user-attachments/assets/ef0b2afd-030b-4aae-aa70-e0dfa2bfdd03
If Compose content briefly disappears or flickers while presenting native iOS UI such as a
dropdown menu, alert, or action sheet, disable parallel rendering in the root
ComposeUIViewController:
import androidx.compose.ui.ExperimentalComposeUiApi
import androidx.compose.ui.window.ComposeUIViewController
@OptIn(ExperimentalComposeUiApi::class)
fun MainViewController() = ComposeUIViewController(
configure = {
parallelRendering = false
}
) {
App()
}
This keeps Compose rendering synchronized with UIKit presentation transitions. It may reduce some rendering performance because Compose no longer encodes rendering commands on a dedicated thread, so apply it when native UI transitions exhibit flickering.
Try the WasmJS interactive web showcase deployed via GitHub Pages:
👉 https://ienground.github.io/compose-hig/
This package is published to Maven Central Repository.
Declare the dependency in libs.versions.toml:
[versions]
hig = "1.3.1"
[libraries]
hig = { group = "zone.ien.hig", name = "hig", version.ref = "hig" }
hig-adaptive = { group = "zone.ien.hig", name = "hig-adaptive", version.ref = "hig" }
hig-native = { group = "zone.ien.hig", name = "hig-native", version.ref = "hig" }
In build.gradle.kts:
kotlin {
sourceSets {
commonMain.dependencies {
implementation(libs.hig)
// Optional adaptive / native extensions
implementation(libs.hig.adaptive)
}
}
}
val backdrop = rememberDefaultBackdrop()
CupertinoLiquidButton(
onClick = { /* handle action */ },
backdrop = backdrop,
) {
Text("Liquid Glass Button")
}
var selectedIndex by remember { mutableStateOf(0) }
CupertinoSegmentedControl(
selectedTabIndex = selectedIndex,
) {
CupertinoSegmentedControlTab(
isSelected = selectedIndex == 0,
onClick = { selectedIndex = 0 }
) {
Text("First")
}
CupertinoSegmentedControlTab(
isSelected = selectedIndex == 1,
onClick = { selectedIndex = 1 }
) {
Text("Second")
}
}
CupertinoSwipeBox(
actionItemBuilder = {
end {
CupertinoSwipeBoxItem(
color = CupertinoColors.systemRed,
icon = CupertinoIcons.Default.Trash,
label = "Delete",
onClick = { /* handle delete */ }
)
}
}
) {
Text("Swipe left to reveal actions", modifier = Modifier.padding(16.dp))
}
LazyColumn {
section(
title = { Text("SECTION HEADER") },
caption = { Text("Section description footer text.") }
) {
item {
Text("Row Item 1", modifier = Modifier.padding(16.dp))
}
item {
Text("Row Item 2", modifier = Modifier.padding(16.dp))
}
}
}
Compared to the previous library, we have made efforts to update many components from the Human Interface Guidelines to match the latest design, but there is still work in progress. Please help complete the library with your contributions!
Copyright (c) Compose Cupertino project open source contributors.
Copyright (c) Scott Lanoue.
Copyright (c) IENGROUND of IENLAB.
Licensed under the Apache License, Version (the );
you may use except compliance the License.
You may obtain a copy of the License at
http:
Unless applicable law agreed to writing, software
distributed under the License distributed an BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express implied.
See the License the specific language governing permissions
limitations under the License.
Contributions are welcome! Please ensure copyright headers are included when submitting Pull Requests.
CupertinoLiquidButton, CupertinoLiquidAlertDialogCupertinoSegmentedControl with spring drag animations, dynamic indicator width, and haptic feedback.CupertinoSwipeBox with DSL action builders (start & end), full-swipe auto-trigger, and spring response.CupertinoSection, LazyListScope.section, and stickySection with iOS grouped inset styling.CupertinoPicker, CupertinoDatePicker, CupertinoTimePicker, and CupertinoDateTimePicker.CupertinoTopAppBar, CupertinoNavigationBar, CupertinoBottomSheet, CupertinoBottomSheetScaffold, CupertinoScaffold.CupertinoSwitch, CupertinoCheckbox, CupertinoTextField, CupertinoSearchTextField.CupertinoIcons (Outlined & Filled) removing unnecessary dependencies on heavy icon packs.Surfaced from shared tags and platforms — no rankings paid for.