import DOMPurify from 'dompurify'; import { useState } from 'preact/hooks'; import useSettings from '../hooks/useSettings'; const Settings = () => { const { cookie, setPermissions, banner, setModal } = useSettings(); const [cookieProxy, setCookieProxy] = useState(cookie); // Prevent the injection of unwanted HTML tags in the banner description const allowedTags = [ 'b', 'i', 'em', 'strong', 'p', 'ul', 'li', 'ol', 'span', 'h2', 'h3', 'h4', 'h5', 'h6', 'a', 'div', ]; const allowedAttributes = ['href', 'target']; return (
{description}