html.Details how to format text

How do we format text using html.Summary inside html.Details for Dash? I tried to nest an html.Markdown inside html.Summary, but the text would be on a newline compared to the collapsible arrow. Is there a way to format the text on the same line?