nkbt/react-collapse

Is the component still maintained + proposed feature additions

Opened this issue · 1 comments

Hey, there.

Thanks for creating this package. I find it super useful in a lot of cases and I'm interested in creating some pull requests for changes that I would find useful for some of my use cases:

  • Defining a component type to render as via a prop, for example using an "as" prop to specify that it should be rendered as a span with a block display CSS property set when rendering within a table to satisfy valid DOM nesting rules (e.g. since a div shouldn't be rendered within a table).

  • Custom classes for the base component, such as setting the component rendered under ReactCollapse to fill the width of the parent. The initialStyle property with accepted props height and overflow are not sufficient in these cases.

I am willing to implement these changes, however it seems that there are pull requests from 2022 that have not been merged which suggests a lack of activity for this library. I am happy to build out these features but if there is no interest in further maintenance (and therefore these PRs not being reviewed), then I may opt for a custom solution instead.

If you could let me know your perspective on this @nkbt that would be appreciated!

nkbt commented
  1. It is possible to specify custom classes with theme prop
  2. I used to allow custom elements in prev versions. There are so many edge cases that it is not feasible.

For tables just put collapse inside td and it will be ok. I could not find better way that is also robust.

I am actively using this lib still and it works well.

Prs not merged because they break one thing or another or add unwanted functionality so I do not want to merge them

thank you