Find and open <details> with similar keywords
I have a page with a loooot of nested <details> and <summary>. I want the user to be able to search through the page and based on the searchterm open every detail and their parent to show results that matches. Maybe focus in on the first one or the one with best match. Is it even possible to close down every other details tag that does not match? To make every detail and summary tag more searchable, i would want to add hashtags that would ease the search. Is this best done with a child <p hidden> for every details tag or something com pletely different? JS is not my strong suit. I havent had the time to learn it yet. This project is for a school related project. Any help would be appreciated. Im not sure what else to write, but ask me anything if this is not clear enough.