n');
      button.innerHTML = 'close';

      button.addEventListener('click', () => {
        dialog.close();
      })

      dialogOverlayNode.appendChild(button);
    }
  });
});
          </code></pre>
        </details>
        <hr />
        <button id="closeOnButtonClick">open</button><br />
      </div>

      <div class="demo">
        <h3>Rendered with lit-html:</h3>
        <details>
          <summary>Show code</summary>
          <pre><code class="language-javascript">
import { dialog } from '@