Regex conditions on the Hide macroThe hide macro provides a convenient way to hide content based on a parameter. This is useful in many situations including when used as part of a run body to conditionally display data based on user input. The new support allows for more conditions to control the conditional display and rendering: - showIf - a comma separated list of regex:value pairs. Content will be shown if all values match their corresponding regex condition. This overrides the hide parameter if specified.
- hideIf - a comma separated list of regex:value pairs. Content will be hidden if all values match their corresponding regex condition. This overrides the hide and showIf parameters when specified.
- renderIf - a comma separated list of regex:valuepairs. Content will be rendered if all values match their corresponding regex condition. This overrides the render parameter when specified. Note that content is rendered when it is not hidden no matter the setting of the render and renderIf parameters.
A literal parameter defaults to true so that all the regex strings are treated as simple strings to make things simple for most examples. With literal as false, then the full power of regex expressions can be used. |