Greater-London-Authority / ldn-viz-tools

https://greater-london-authority.github.io/ldn-viz-tools/
1 stars 0 forks source link

Move CheckboxGroup and RadioGroup to their own package #297

Closed PaulioRandall closed 1 month ago

PaulioRandall commented 1 month ago

Is your feature request related to a problem? Please describe.

Currently the <Checkbox> and <CheckboxGroup> components are in the same package within a combined set if stories (https://greater-london-authority.github.io/ldn-viz-tools/?path=/docs/ui-checkbox--documentation). There's two issues with this:

  1. Incorrect properties showing for Storybook documentation and will likely make improvements harder due to lack of separation of concerns (https://greater-london-authority.github.io/ldn-viz-tools/?path=/story/ui-checkbox--checkbox-group-story).
  2. <CheckboxGroup> does not show up within the Storybook sidebar so it's as if it doesn't exist. Only digging into the <Checkbox> component docs reveals the details (https://greater-london-authority.github.io/ldn-viz-tools/?path=/docs/ui-introduction--documentation).

These issues apply to <RadioGroup> as well.

Describe the solution you'd like

Move <CheckboxGroup> and <RadioGroup> to their own packages with there own stories.

Describe alternatives you've considered

Updating the existing stories and documentation. This might solve the first issue but not the second. It also doesn't help with separation of concerns.