Add transformators and decorators to modules#338
Conversation
osenan
left a comment
There was a problem hiding this comment.
Hi, great that you achieved decorators and transformators in a single PR.
Minor comments:
We need to run devtools::document() so we update documentation. Let's try to fix failing checks as well.
We need to add check for the transformator as well.
I think it is ambitious and time saving to create all decorators and transformators on a single PR. However, if there is a lot of back and forth trying to fix here and there it might be better to create specific PR for more challenging modules. For the moment:
- In the example app, If I change the transformators row number limit, it does not show more the plot. It happens in all modules
Can you check if the problem is in the example or in the transformator implementation?
In addition, in the example app there are modules that fail:
- Patient Profile (error)
- Swimlane Plot: I cannot see the plot, it seems an issue with the decorator?
- Spider Plot: I cannot see the plot, it seems an issue with the decorator?
- Waterfall Plot: I cannot see the plot, it seems an issue with the decorator?
- Butterfly Plot: I cannot see the plot, it seems an issue with the decorator?
In the other modules the decorators seem to work.
Please check if the big issues mentioned are problems only in the example app or in the implementation
| #' decorators for the module `plot` output. See [decorate_module_section] for which | ||
| #' object types are supported per module. | ||
| #' | ||
| #' @return the [teal::module()] object. |
There was a problem hiding this comment.
I think we need to add an entry for "#' @Transformators" here as well
| plot_width[1], | ||
| lower = plot_width[2], upper = plot_width[3], null.ok = TRUE, .var.name = "plot_width" | ||
| ) | ||
| teal::assert_decorators(decorators, "plot") |
There was a problem hiding this comment.
I think we should also assess the class of the transformator object here:
| teal::assert_decorators(decorators, "plot") | |
| checkmate::assert_class(transformators, "teal_transform_module") | |
| teal::assert_decorators(decorators, "plot") |
We should apply it to all modules
Closes #333