Don't show the settings/details icons on the landing page #153
This commit is contained in:
parent
6dacca19a7
commit
4ebcddc040
@ -1,3 +1,8 @@
|
|||||||
|
:root
|
||||||
|
{
|
||||||
|
--ov_only_on_model_display: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
@font-face
|
@font-face
|
||||||
{
|
{
|
||||||
font-family: Quicksand;
|
font-family: Quicksand;
|
||||||
@ -28,6 +33,11 @@ img
|
|||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.only_on_model
|
||||||
|
{
|
||||||
|
display: var(--ov_only_on_model_display);
|
||||||
|
}
|
||||||
|
|
||||||
@media (hover)
|
@media (hover)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|||||||
@ -18,29 +18,17 @@ OV.GetMaterialName = function (originalName)
|
|||||||
|
|
||||||
OV.IsHoverEnabled = function ()
|
OV.IsHoverEnabled = function ()
|
||||||
{
|
{
|
||||||
if (window.matchMedia ('(hover : hover)').matches) {
|
return window.matchMedia ('(hover: hover)').matches;
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
OV.IsSmallWidth = function ()
|
OV.IsSmallWidth = function ()
|
||||||
{
|
{
|
||||||
if (window.matchMedia ('(max-width : 700px)').matches) {
|
return window.matchMedia ('(max-width: 700px)').matches;
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
OV.IsSmallHeight = function ()
|
OV.IsSmallHeight = function ()
|
||||||
{
|
{
|
||||||
if (window.matchMedia ('(max-height : 700px)').matches) {
|
return window.matchMedia ('(max-height: 700px)').matches;
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
OV.InstallTooltip = function (item, text)
|
OV.InstallTooltip = function (item, text)
|
||||||
|
|||||||
@ -84,18 +84,33 @@ OV.Website = class
|
|||||||
this.viewer.Resize (contentWidth, contentHeight);
|
this.viewer.Resize (contentWidth, contentHeight);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
HasLoadedModel ()
|
||||||
|
{
|
||||||
|
return this.model !== null;
|
||||||
|
}
|
||||||
|
|
||||||
SetUIState (uiState)
|
SetUIState (uiState)
|
||||||
{
|
{
|
||||||
|
function ShowOnlyOnModelElements (show)
|
||||||
|
{
|
||||||
|
let root = document.querySelector (':root');
|
||||||
|
root.style.setProperty ('--ov_only_on_model_display', show ? 'inherit' : 'none');
|
||||||
|
}
|
||||||
|
|
||||||
if (uiState === OV.WebsiteUIState.Intro) {
|
if (uiState === OV.WebsiteUIState.Intro) {
|
||||||
this.parameters.introDiv.show ();
|
this.parameters.introDiv.show ();
|
||||||
this.parameters.mainDiv.hide ();
|
this.parameters.mainDiv.hide ();
|
||||||
|
ShowOnlyOnModelElements (false);
|
||||||
} else if (uiState === OV.WebsiteUIState.Model) {
|
} else if (uiState === OV.WebsiteUIState.Model) {
|
||||||
this.parameters.introDiv.hide ();
|
this.parameters.introDiv.hide ();
|
||||||
this.parameters.mainDiv.show ();
|
this.parameters.mainDiv.show ();
|
||||||
|
ShowOnlyOnModelElements (true);
|
||||||
} else if (uiState === OV.WebsiteUIState.Loading) {
|
} else if (uiState === OV.WebsiteUIState.Loading) {
|
||||||
this.parameters.introDiv.hide ();
|
this.parameters.introDiv.hide ();
|
||||||
this.parameters.mainDiv.hide ();
|
this.parameters.mainDiv.hide ();
|
||||||
|
ShowOnlyOnModelElements (false);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.Resize ();
|
this.Resize ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user