Persistent marker #859
Replies: 4 comments 4 replies
-
The way I have achieved this is through an invisible |
Beta Was this translation helpful? Give feedback.
-
I figured out why we can't update the The problem is that Is this a bug or, am I doing something wrong?
|
Beta Was this translation helpful? Give feedback.
-
Hello! As such, this is a feature that isn't yet available. It was requested in #356. Once it's been introduced, there will be a dedicated API that helps achieve this behavior easily. In the meantime, you can use
This workaround sounds good, @Tyler-Lopez.
Yes, this works, @cristianboicu01.
The latter. You should use something like this: persistentMarkers = rememberExtraLambda(marker, persistentMarkerIndex) { marker at persistentMarkerIndex } It will then update as expected.
This works, but the approach I suggested above is preferable. Updates regarding the introduction of this feature will be shared under #356. Note that there's a recomposition issue related to strong skipping mode in version @Praveen-Android, you asked for our input here a while ago, so I wanted to tag you. |
Beta Was this translation helpful? Give feedback.
-
@Gowsky is it possible to get a rough timeline for possible release of this dedicated API for markers? It would just help to know if we can wait for this or if we should dedicate effort in workarounds. |
Beta Was this translation helpful? Give feedback.
-
Question
I would like to have a single marker, which I can drag along the line chart and it will not disappear after I release it. How can I achieve this kind of behaviour?
The only problem right now is that I cannot figure out a way on how to keep the marker visible on the last point it was dragged to.
Thank you!
Vico version(s)
last
UI framework(s)
Jetpack Compose
Beta Was this translation helpful? Give feedback.
All reactions