Skip to content

Commit

Permalink
Move key navigation to new module (#1269)
Browse files Browse the repository at this point in the history
Co-authored-by: Ashley Davies <[email protected]>
  • Loading branch information
ashdavies and ashdavies authored Oct 24, 2024
1 parent a52d0d2 commit 44fdad8
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 1 deletion.
1 change: 1 addition & 0 deletions app-launcher/desktop/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ kotlin {
commonMain.dependencies {
implementation(projects.appLauncher.common)
implementation(projects.httpClient)
implementation(projects.keyNavigation)
implementation(projects.platformSupport)

implementation(libs.ajalt.clikt)
Expand Down
10 changes: 10 additions & 0 deletions key-navigation/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
plugins {
id("io.ashdavies.compose")
id("io.ashdavies.kotlin")
}

kotlin {
sourceSets.commonMain.dependencies {
implementation(libs.slack.circuit.foundation)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import com.slack.circuit.backstack.NavDecoration
import com.slack.circuit.foundation.NavigatorDefaults
import kotlinx.collections.immutable.ImmutableList

internal class KeyNavigationDecoration(
public class KeyNavigationDecoration(
private val decoration: NavDecoration = NavigatorDefaults.DefaultDecoration,
private val predicate: (KeyEvent) -> Boolean = { it.key == Key.Escape },
private val onBackInvoked: () -> Unit,
Expand Down
1 change: 1 addition & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ include(
":http-client",
":http-common",
":identity-manager",
":key-navigation",
":kotlin-gb",
":map-routes",
":maps-routing",
Expand Down

0 comments on commit 44fdad8

Please sign in to comment.