mirror of
https://github.com/lubosz/overte.git
synced 2025-04-25 01:03:59 +02:00
Remove dead code and cleanup JS styling for entity properties redesign
This commit is contained in:
parent
8c9015b224
commit
aecbccc058
2 changed files with 6 additions and 45 deletions
|
@ -1411,29 +1411,6 @@ th#entity-hasScript {
|
|||
display: inline-block;
|
||||
}
|
||||
|
||||
/*
|
||||
#properties-base #div-property-locked {
|
||||
position: absolute;
|
||||
top: 6px;
|
||||
right: 140px;
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
#properties-base #div-property-visible {
|
||||
position: absolute;
|
||||
top: 26px;
|
||||
right: 20px;
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
#properties-base #div-property-locked label,
|
||||
#properties-base #div-property-visible label {
|
||||
background-position-y: 1px;
|
||||
}
|
||||
*/
|
||||
|
||||
#properties-base .checkbox label span {
|
||||
font-family: HiFi-Glyphs;
|
||||
font-size: 20px;
|
||||
|
|
|
@ -1116,7 +1116,6 @@ const GROUPS = [
|
|||
},
|
||||
{
|
||||
label: "Clone Lifetime",
|
||||
indentedLabel: true,
|
||||
type: "number",
|
||||
unit: "s",
|
||||
propertyID: "cloneLifetime",
|
||||
|
@ -1124,21 +1123,18 @@ const GROUPS = [
|
|||
},
|
||||
{
|
||||
label: "Clone Limit",
|
||||
indentedLabel: true,
|
||||
type: "number",
|
||||
propertyID: "cloneLimit",
|
||||
showPropertyRule: { "cloneable": "true" },
|
||||
},
|
||||
{
|
||||
label: "Clone Dynamic",
|
||||
indentedLabel: true,
|
||||
type: "bool",
|
||||
propertyID: "cloneDynamic",
|
||||
showPropertyRule: { "cloneable": "true" },
|
||||
},
|
||||
{
|
||||
label: "Clone Avatar Entity",
|
||||
indentedLabel: true,
|
||||
type: "bool",
|
||||
propertyID: "cloneAvatarEntity",
|
||||
showPropertyRule: { "cloneable": "true" },
|
||||
|
@ -1417,7 +1413,7 @@ var createAppTooltip = new CreateAppTooltip();
|
|||
let currentSpaceMode = PROPERTY_SPACE_MODE.LOCAL;
|
||||
|
||||
function createElementFromHTML(htmlString) {
|
||||
var elTemplate = document.createElement('template');
|
||||
let elTemplate = document.createElement('template');
|
||||
elTemplate.innerHTML = htmlString.trim();
|
||||
return elTemplate.content.firstChild;
|
||||
}
|
||||
|
@ -1916,11 +1912,6 @@ function createVec3Property(property, elProperty) {
|
|||
|
||||
elProperty.className = propertyData.vec3Type + " fstuple";
|
||||
|
||||
//let elTuple = document.createElement('div');
|
||||
//elTuple.className = "tuple";
|
||||
|
||||
//elProperty.appendChild(elTuple);
|
||||
|
||||
let elInputX = createTupleNumberInput(elProperty, elementID, propertyData.subLabels[VECTOR_ELEMENTS.X_INPUT],
|
||||
propertyData.min, propertyData.max, propertyData.step);
|
||||
let elInputY = createTupleNumberInput(elProperty, elementID, propertyData.subLabels[VECTOR_ELEMENTS.Y_INPUT],
|
||||
|
@ -2089,9 +2080,7 @@ function createIconProperty(property, elProperty) {
|
|||
|
||||
elProperty.appendChild(elSpan);
|
||||
|
||||
let elResult = [];
|
||||
elResult[ICON_ELEMENTS.ICON] = elSpan;
|
||||
return elResult;
|
||||
return elSpan;
|
||||
}
|
||||
|
||||
function createTextureProperty(property, elProperty) {
|
||||
|
@ -2154,9 +2143,6 @@ function createButtonsProperty(property, elProperty, elLabel) {
|
|||
elProperty.className = "text";
|
||||
|
||||
let hasLabel = propertyData.label !== undefined;
|
||||
if (hasLabel) {
|
||||
}
|
||||
|
||||
if (propertyData.buttons !== undefined) {
|
||||
addButtons(elProperty, elementID, propertyData.buttons, hasLabel);
|
||||
}
|
||||
|
@ -2803,9 +2789,7 @@ function createProperty(propertyData, propertyElementID, propertyName, propertyI
|
|||
break;
|
||||
}
|
||||
case 'icon': {
|
||||
let elIcon = createIconProperty(property, elProperty);
|
||||
property.elSpan = elIcon[ICON_ELEMENTS.ICON];
|
||||
property.elLabel = elIcon[ICON_ELEMENTS.LABEL];
|
||||
property.elSpan = createIconProperty(property, elProperty);
|
||||
break;
|
||||
}
|
||||
case 'texture': {
|
||||
|
@ -2824,7 +2808,7 @@ function createProperty(propertyData, propertyElementID, propertyName, propertyI
|
|||
}
|
||||
default: {
|
||||
console.log("EntityProperties - Unknown property type " +
|
||||
propertyType + " set to property " + propertyID);
|
||||
propertyType + " set to property " + propertyID);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -2930,9 +2914,9 @@ function loaded() {
|
|||
let elProperty = createElementFromHTML('<div style="width: 100%;"></div>');
|
||||
elContainer.appendChild(elProperty);
|
||||
|
||||
if (propertyType == 'triple') {
|
||||
if (propertyType === 'triple') {
|
||||
elProperty.className = 'flex-row';
|
||||
for (var i = 0; i < propertyData.properties.length; ++i) {
|
||||
for (let i = 0; i < propertyData.properties.length; ++i) {
|
||||
let innerPropertyData = propertyData.properties[i];
|
||||
|
||||
let elWrapper = createElementFromHTML('<div class="flex-column flex-center triple-item"><div></div></div>');
|
||||
|
|
Loading…
Reference in a new issue