import { html } from "lit";
import { renderButton } from "../../button.js";
import { renderHeading } from "../../heading.js";
import { getQuestionPart } from "./get-question-part.js";
const renderQuestion = ({ props })=>(children)=>{
        const buttonProps = {
            style: 'text-neutral',
            part: getQuestionPart('button', props.expanded),
            onClick: props.onClick,
            class: 'flex items-center px-4',
            ariaExpanded: props.expanded ? 'true' : 'false',
            ariaControls: props.ariaControls
        };
        const headingProps = {
            level: props.headingLevel ? props.headingLevel + 1 : 0,
            class: 'py-4 text-left text-xl font-bold',
            part: getQuestionPart('text', props.expanded)
        };
        return renderButton({
            props: buttonProps
        })(html`${children}${renderHeading({
            props: headingProps
        })(html`${props.question}`)}`);
    };
export { renderQuestion };
