Skip to content

Add support for List and Enum parameters #59

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

Merged
merged 1 commit into from
Apr 19, 2025

Conversation

popovanton0
Copy link
Contributor

@popovanton0 popovanton0 commented Apr 18, 2025

storytale-list-parameter.mp4

On Android
storytale-list-parameter-android


In this PR I added 2 new parameter functions: for arbitrary lists and for enums.

See their usage in the examples here: PrimaryButton.story.kt.

In the future, it will be possible to create many list-based pickers, such as for:

  • icons
  • text styles
  • colors
  • shapes
  • etc

Also, API introduced in this PR allows users to create custom pickers for their data types, such as

  • component styles
  • sizes

I have manually tested these changes on android, desktop and web.

BTW community already expressed the need for enum selection 🙂

Copy link
Collaborator

@whitescent whitescent left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for providing more comprehensive parameter support!

@whitescent whitescent merged commit 9f0d46a into Kotlin:main Apr 19, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants