-
|
I am creating a modal with multiple collapsible, each with settings for filtering a searching functionality. Now among those filters are some which need a dropdown list where a user can select an item, but when I use dropdown inside collapsible, the dropdown-content component doesn't render. Anyone who can help? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
|
That combination is challenging and here's the issue:
I'm trying to fix this limit in daisyUI
|
Beta Was this translation helpful? Give feedback.
-
|
@saadeghi thank you so much for the fast reply and the code example, that's exactly what I needed. Also, thanks for creating such a great library, me and my colleagues love it :D |
Beta Was this translation helpful? Give feedback.
-
|
Setting class CollapsibleSubsection extends Component {
onClickCollapse(ev) {
this.collapseContentRef.current.style.overflowY = this.collapseInputRef.current.checked ? 'visible' : 'hidden';
ev.target.blur();
}
collapseInputRef = createRef(null);
collapseContentRef = createRef(null);
render({propComponent, prop, nameSuffix}, state) {
// nameSuffix is useful for input[type=radio]
return html`
<div class="collapse collapse-arrow join-item !overflow-visible !isolation-auto">
<input ref="${this.collapseInputRef}" type="checkbox" name="variant-accordion-${nameSuffix}" onClick="${this.onClickCollapse.bind(this)}" />
<div class="collapse-title bg-base-100/90"><${AbSubtitle}>${prop.name}</${AbSubtitle}></div>
<div ref="${this.collapseContentRef}" class="collapse-content text-base bg-base-100 border-base-300 border">
<${propComponent} subsection_items="${prop.children}" subsection="${prop}" />
</div>
</div>
`;
}
}Now it works, however I am still unsure about all possible scenarios. CSS became too much magical in recent 10 years. |
Beta Was this translation helpful? Give feedback.
That combination is challenging and here's the issue:
collapseandcollapse-contenthaveoverflow:hiddenbeca…