diff --git a/public/demo/bim_0.html b/public/demo/bim_0.html index ebdf10b..f4f505f 100644 --- a/public/demo/bim_0.html +++ b/public/demo/bim_0.html @@ -3,7 +3,7 @@ - + --> diff --git a/public/demo/dxf_0.html b/public/demo/dxf_0.html index 66c9c63..7e689ea 100644 --- a/public/demo/dxf_0.html +++ b/public/demo/dxf_0.html @@ -6,7 +6,7 @@ - + --> diff --git a/src/pages/examples/index.css b/src/pages/examples/index.css index 8071ba7..8cab5e3 100644 --- a/src/pages/examples/index.css +++ b/src/pages/examples/index.css @@ -55,10 +55,10 @@ background: lightblue; } -.examples .content-container.open { +/* .examples .content-container.open { opacity: 0.4; pointer-events: none; -} +} */ .examples .content-container iframe { width: 100%; @@ -66,7 +66,7 @@ overflow: hidden; } -.examples .content-overlay { +/* .examples .content-overlay { position: absolute; z-index: 7; padding: 0; @@ -81,7 +81,7 @@ .examples .content-overlay.open { pointer-events: all; -} +} */ .examples .page-title { position: absolute; diff --git a/src/pages/examples/index.tsx b/src/pages/examples/index.tsx index a606ec2..91033d0 100644 --- a/src/pages/examples/index.tsx +++ b/src/pages/examples/index.tsx @@ -27,9 +27,12 @@ function Examples() { iframeRef.current = document.createElement("iframe") as HTMLIFrameElement; preview.appendChild(iframeRef.current); if(code) { - iframeRef.current.contentWindow?.document.open(); - iframeRef.current.contentWindow?.document.write(code); - iframeRef.current.contentWindow?.document.close(); + const doc = iframeRef.current.contentWindow?.document; + if (doc) { + doc.open(); + doc.write(code); + doc.close(); + } } } @@ -83,7 +86,7 @@ function Examples() { {!collapsed ? : }
{title}
-
+ {/*
*/}