function ToggleDetailsElements( e, parent )
{
	e.preventDefault();

	if( !parent )
	{
		return;
	}

	const elements = parent.querySelectorAll( 'details' );
	let state = true;

	// Figure out if any of the elements are currently open
	// If at least one is open, we will close all of them
	for( const el of elements )
	{
		if( el.open )
		{
			state = false;
			break;
		}
	}

	for( const el of elements )
	{
		el.open = state;
	}
}
@param {MouseEvent} e
@param {HTMLElement|undefined} parent