# NavDisplay

Artifact: [androidx.navigation3:navigation3-ui](https://developer.android.com/jetpack/androidx/releases/navigation3) [View Source](https://cs.android.com/search?q=file:androidx/navigation3/ui/NavDisplay.kt+class:androidx.navigation3.ui.NavDisplay) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/navigation3#1.0.0) Common/AllAndroid/JVM
- Cmn

  ```
  object NavDisplay
  ```

*** ** * ** ***

Object that indicates the features that can be handled by the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay`

## Summary

| ### Nested types |
|---|
| `object https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay.PopTransitionKey : https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavMetadataKey<https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform>` The key for `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` of how the content should be animated when popping from backstack. |
| `object https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay.PredictivePopTransitionKey : https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavMetadataKey<https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?>` The key for `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` of how the content should be animated when popping from backstack using a Predictive back gesture. |
| `object https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay.TransitionKey : https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavMetadataKey<https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform>` The key for `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` of how the content should be animated when adding to the backstack. |

| ### Public functions |
|---|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html>` | `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#popTransitionSpec(kotlin.Function1)(popTransitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?)` Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` that, when popping from backstack, the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html>` | `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#predictivePopTransitionSpec(kotlin.Function2)( predictivePopTransitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform? )` Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` that, when popping from backstack using a Predictive back gesture, the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html>` | `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#transitionSpec(kotlin.Function1)(transitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?)` Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` of how the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`. | Cmn |

## Public functions

### popTransitionSpec

Cmn Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/navigation3#1.0.0)

```
fun popTransitionSpec(popTransitionSpec: AnimatedContentTransitionScope<Scene<*>>.() -> ContentTransform?): Map<String, Any>
```

Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` that, when popping from backstack, the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`.

**IMPORTANT** `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` only looks at the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to determine the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#popTransitionSpec(kotlin.Function1)`, it is the responsibility of the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to decide which `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#popTransitionSpec(kotlin.Function1)` to return, whether that be from the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or something custom.

| Parameters |
|---|---|
| `popTransitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?` | the `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform` to be used when popping from backstack. If this is null, the transition will fallback to the transition set on the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` |

### predictivePopTransitionSpec

Cmn Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/navigation3#1.0.0)

```
fun predictivePopTransitionSpec(
    predictivePopTransitionSpec: AnimatedContentTransitionScope<Scene<*>>.(Int) -> ContentTransform?
): Map<String, Any>
```

Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` that, when popping from backstack using a Predictive back gesture, the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`.

**IMPORTANT** `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` only looks at the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to determine the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#predictivePopTransitionSpec(kotlin.Function2)`, it is the responsibility of the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to decide which `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#predictivePopTransitionSpec(kotlin.Function2)` to return, whether that be from the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or something custom.

| Parameters |
|---|---|
| `predictivePopTransitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?` | the `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform` to be used when popping from backStack with predictive back gesture. If this is null, the transition will fallback to the transition set on the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` |

### transitionSpec

Cmn Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/navigation3#1.0.0)

```
fun transitionSpec(transitionSpec: AnimatedContentTransitionScope<Scene<*>>.() -> ContentTransform?): Map<String, Any>
```

Function to be called on the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to notify the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` of how the content should be animated using the provided `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform`.

**IMPORTANT** `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` only looks at the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to determine the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#transitionSpec(kotlin.Function1)`, it is the responsibility of the `https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene#metadata()` to decide which `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay#transitionSpec(kotlin.Function1)` to return, whether that be from the `https://developer.android.com/reference/kotlin/androidx/navigation3/runtime/NavEntry#metadata()` or something custom.

| Parameters |
|---|---|
| `transitionSpec: https://developer.android.com/reference/kotlin/androidx/compose/animation/AnimatedContentTransitionScope<https://developer.android.com/reference/kotlin/androidx/navigation3/scene/Scene<*>>.() -> https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform?` | the `https://developer.android.com/reference/kotlin/androidx/compose/animation/ContentTransform` to be used when adding to the backstack. If this is null, the transition will fallback to the transition set on the `https://developer.android.com/reference/kotlin/androidx/navigation3/ui/NavDisplay` |