diff --git a/www/content/docs.md b/www/content/docs.md index bf0113cb..49a39b00 100644 --- a/www/content/docs.md +++ b/www/content/docs.md @@ -1140,8 +1140,8 @@ You can see all available extensions on the [Extensions](/extensions) page. The fastest way to install htmx extensions created by others is to load them via a CDN. Remember to always include the core htmx library before the extensions and [enable the extension](#enabling-extensions). For example, if you would like to use the [response-targets](/extensions/response-targets) extension, you can add this to your head tag: ```HTML
- - + + ... diff --git a/www/static/node_modules/chai-dom/chai-dom.js b/www/static/node_modules/chai-dom/chai-dom.js index 53e2000d..d471888e 100644 --- a/www/static/node_modules/chai-dom/chai-dom.js +++ b/www/static/node_modules/chai-dom/chai-dom.js @@ -350,7 +350,8 @@ chai.Assertion.addProperty('displayed', function() { var el = flag(this, 'object'), - actual = el.getRootNode({ composed: true }) === document ? window.getComputedStyle(el).display : el.style.display + isAttached = el.getRootNode ? el.getRootNode({ composed: true }) === document : document.body.contains(el), + actual = isAttached ? window.getComputedStyle(el).display : el.style.display this.assert( actual !== 'none' @@ -362,7 +363,8 @@ chai.Assertion.addProperty('visible', function() { var el = flag(this, 'object'), - actual = document.body.contains(el) ? window.getComputedStyle(el).visibility : el.style.visibility + isAttached = el.getRootNode ? el.getRootNode({ composed: true }) === document : document.body.contains(el), + actual = isAttached ? window.getComputedStyle(el).visibility : el.style.visibility this.assert( actual !== 'hidden' && actual !== 'collapse'