We have a use case for a customized annotation that can carry more information than the standard @ShowkaseComposable. To avoid needing to specify another annotation on preview functions that has that information, this adds a compiler flag to allow a custom annotation to be used instead of the standard annotation.
Additionally, there are specific terms we use for the fields in the annotation and we'd like to customize those as well. This adds compiler flags to allow for overriding the name, group and styleName fields. It also allows for multiple fields to be defined in a priority order where the first non-empty field is used. For us, this allows us to separate test-specific previews from previews used as a canonical style in our design system.
We have a use case for a customized annotation that can carry more information than the standard
@ShowkaseComposable
. To avoid needing to specify another annotation on preview functions that has that information, this adds a compiler flag to allow a custom annotation to be used instead of the standard annotation.Additionally, there are specific terms we use for the fields in the annotation and we'd like to customize those as well. This adds compiler flags to allow for overriding the
name
,group
andstyleName
fields. It also allows for multiple fields to be defined in a priority order where the first non-empty field is used. For us, this allows us to separate test-specific previews from previews used as a canonical style in our design system.