【发布时间】:2015-08-06 05:03:48
【问题描述】:
我试图弄清楚为什么 WebGL 动画下面的 HTML 内容不能被点击或交互。
请参阅example。
目前包含动画的div设置为:
.webgl-glitch {
position: absolute;
z-index: 2;
overflow: hidden;
opacity: 0.5;
}
..否则根本不会显示。
我尝试设置 z-index: 1;标题/容器 div 上的属性,但这似乎没有帮助。
这是标题的 HTML 部分,包括动画 div:
<!-- Begin Header animation -->
<div class="webgl-glitch"></div>
<!-- End Header animation -->
<header id="principalheader" class="centerContainer aligncenter fullScreen tintBackground stonebackground" style="z-index:1">
<div>
<div class="container">
<!-- Site logo-->
<a href="#" class="logo"><img alt="KUBO" src="img/logo.png"></a>
<!-- Site Principal slogan-->
<h1>Digital Exploration for the the digital age</h1>
<!-- Site Resume-->
<div class="row">
<div class="hidden-xs col-md-10 col-md-offset-1">
<h2>CRAFT experiences that <strong>defy</strong> expectations<br/>
CREATE from the the twin <strong>virtues</strong> of inspiration and innovation<br/>
BEAUTY in simplicity and complexity <strong>combined</strong> for the best of both worlds</h2>
</div>
<div class="col-md-10 col-md-offset-1">
<a class="fa fa-angle-down" href="#" data-scrollto="#about"></a>
</div>
</div>
</div>
</div>
</header>
我注意到的另一件事是,如果我将 .web-glitch 动画 div 包装在 HTML5 画布元素中,它也根本不显示?为什么会这样?
目前我在 CSS 中画布上的唯一属性是 width: 100%;
【问题讨论】:
标签: javascript css html