Fixed errors VC

This commit is contained in:
Daniel Barbero Martin 2020-01-21 10:33:07 +01:00
parent 578400aa92
commit 8672629dd6
8 changed files with 25 additions and 42 deletions

View File

@ -102,15 +102,6 @@ final class Label extends Item
// Retrieve global - common inputs.
$values = parent::getDefaultGeneralValues($values);
// Default values.
if (isset($values['width']) === false) {
$values['width'] = 100;
}
if (isset($values['height']) === false) {
$values['height'] = 100;
}
return $values;
}

View File

@ -401,15 +401,6 @@ final class SimpleValue extends Item
// Retrieve global - common inputs.
$values = parent::getDefaultGeneralValues($values);
// Default values.
if (isset($values['width']) === false) {
$values['width'] = 100;
}
if (isset($values['height']) === false) {
$values['height'] = 100;
}
return $values;
}

View File

@ -681,6 +681,17 @@ li#li-timeZone-item > select:not(:first-child) {
justify-content: center;
}
div.label,
div.simple-value {
display: inline-table;
min-width: -webkit-fit-content;
min-width: -moz-fit-content;
min-width: fit-content;
min-height: -webkit-fit-content;
min-height: -moz-fit-content;
min-height: fit-content;
}
/* Styles for the solid icons */
.fa {

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -113,28 +113,11 @@ export default class SimpleValue extends Item<SimpleValueProps> {
return element;
}
protected resizeElement(width: number, height: number): void {
console.log("estamos dentro del resize");
if (
this.elementRef.firstElementChild !== null &&
this.elementRef.firstElementChild.firstElementChild !== null
) {
console.log(this.elementRef.firstElementChild.firstElementChild);
console.log(
this.elementRef.firstElementChild.firstElementChild.getBoundingClientRect()
);
}
super.resizeElement(width, height);
}
/**
* @override Item.createLabelDomElement
* Create a new label for the visual console item.
* @return Item label.
*/
protected createLabelDomElement(): HTMLElement {
* Generate a element size
* using the current size and the default values.
* @return The size.
*/ protected createLabelDomElement(): HTMLElement {
const element = document.createElement("div");
element.className = "visual-console-item-label";
// Always return an empty label.

View File

@ -506,3 +506,10 @@ li#li-timeZone-item > select:not(:first-child) {
align-items: center;
justify-content: center;
}
div.label,
div.simple-value {
display: inline-table;
min-width: fit-content;
min-height: fit-content;
}