How to remove fullscreen styles in A-Frame, reduce canvas size, or scroll a page with A-Frame scene?

你说的曾经没有我的故事 提交于 2019-12-07 04:51:16

问题


A-Frame is locking the scroll in the page where I am using it. When I open a page with my A-Frame scene, it takes up 100% page width and height and I cannot scroll. Is there a class I have to remove?


回答1:


You can use the embedded component to remove fullscreen styles and make it embeddable within a web page. https://aframe.io/docs/0.8.0/components/embedded.html

<a-scene embedded> 
  <!-- scene stuff -->
</a-scene>

Then you are free the style <a-scene> how you wish

a-scene { display: block; width: 50%; }


来源:https://stackoverflow.com/questions/39754553/how-to-remove-fullscreen-styles-in-a-frame-reduce-canvas-size-or-scroll-a-page

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!