- 
                Notifications
    You must be signed in to change notification settings 
- Fork 748
Support initial selection in Plotly plots #6747
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| The latest updates on your projects. Learn more about Vercel for GitHub. 
 | 
b8f494f    to
    07740e4      
    Compare
  
    There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the enthusiasm! However, before filing PRs, we request that contributors align with us in the issue on whether we're receptive to the PR, as well as the approach.
In this case, your PR adds a new public API, which requires serious consideration and discussion from the team, because new APIs add complexity and maintenance burden.
Instead of discussing these topics at the code stage, we request our contributors to discuss with us when filing an issue. You should have seen a sentence to this effect in the issue template; sorry if it wasn't sufficiently clear.
| 
 I'm not sure what you mean. Which new public API is this PR adding? | 
| 
 
 Sorry, misread the PR reading it quickly! | 
07740e4    to
    e2d1d40      
    Compare
  
    Does not initialize the selected items!
Having not found a more elegant solution, we iterate over the figure's data to create the initial values in the marimo wrapper side.
e2d1d40    to
    3cd5b99      
    Compare
  
    | 
 @yairchu we likely are missing tests for  | 
📝 Summary
Fixes #6746 for Plotly (Altair issue unchanged)
🔍 Description of Changes
mo.ui.plotlysupports plots having an initial selection made by Plotly'aadd_selectionmethod.📋 Checklist
tests/_plugins/ui/_impl/test_altair_chart.py. If there is one I'll gladly add a test