简体   繁体   中英

Forge Viewer Autodesk

i am new to forge and desperate. I have seen this example. How can I make the Forge Toolbar transparent, see below…?

enter image description here

In the picture you provided, the light-theme is used.
You can set it like this:
viewer.setTheme('light-theme');
More info: https://forge.autodesk.com/blog/dark-light-mode-viewer

The rest you can do by modifying the style of the various components. You can investigate in the browser's Developer Console what is being used by them: 在此处输入图像描述

From that you can see the you can simply add the following to your own css file to override the background color and shadow of those controls:

.adsk-viewing-viewer.light-theme .adsk-control-group {
  box-shadow: none;
  background-color: transparent;
}

Here is the result:
在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM