Guillaume B
11/25/2025, 9:13 AMnav3 and I have a question regarding the scene strategy. Do we have a way for the composables to be aware of the strategy ? Meaning I have a composable that is marked as a detail pane, and I want to modify a bit the ui when that composable is displayed within the scene (vs when it's displayed full screen, not as a detail pane)Ian Lake
11/25/2025, 10:01 AMGuillaume B
11/25/2025, 10:12 AMfun PaneScaffoldDirective.isWithinScene(partitionCount: Int) =
this.maxHorizontalPartitions >= partitionCount
val windowAdaptiveInfo = currentWindowAdaptiveInfo()
val directive = calculatePaneScaffoldDirective(windowAdaptiveInfo)
val withinScene = directive.isWithinScene(2)Ian Lake
11/25/2025, 10:15 AMGuillaume B
11/25/2025, 10:16 AMGuillaume B
11/25/2025, 10:19 AMStylianos Gakis
11/25/2025, 10:31 AMGuillaume B
11/25/2025, 10:34 AMval listDetailStrategy = rememberListDetailSceneStrategy<NavKey>()Guillaume B
11/25/2025, 10:37 AMval LocalWithinScene = compositionLocalOf{ false }Alex Vanyo
11/25/2025, 6:17 PMLocalScene: CompositionLocal<Scene<T>> where you could pull out information about a Scene (assuming the scene supports it)Alex Vanyo
11/25/2025, 6:20 PMOut of curiosity, is there a way for the Scene to propagate this information down without composition locals?It'd be hard, to do it explicitly you'd need to have a way to pass through an extra argument while keeping type-safety through all of the wrapping. A
CompositionLocal is probably a simpler cross-cutting mechanism, especially if it is a piece of information that may or may not be available