#612 --global-se-spin-input-width to handle numberspinbox width changes
parent
9d56df3c8c
commit
b905f4ac4c
|
@ -9,8 +9,7 @@ template.innerHTML = `
|
|||
padding: 3px;
|
||||
}
|
||||
div.imginside {
|
||||
--se-spin-input-width: var(--global-se-spin-input-width);
|
||||
width: var(--se-spin-input-width);
|
||||
width: var(--global-se-spin-input-width);
|
||||
}
|
||||
img {
|
||||
position: relative;
|
||||
|
@ -73,7 +72,7 @@ export class SESpinInput extends HTMLElement {
|
|||
* @returns {any} observed
|
||||
*/
|
||||
static get observedAttributes () {
|
||||
return [ 'value', 'label', 'src', 'size', 'min', 'max', 'step', 'width' ];
|
||||
return [ 'value', 'label', 'src', 'size', 'min', 'max', 'step' ];
|
||||
}
|
||||
/**
|
||||
* @function attributeChangedCallback
|
||||
|
@ -90,9 +89,6 @@ export class SESpinInput extends HTMLElement {
|
|||
this.$label.remove();
|
||||
this.$div.classList.add('imginside');
|
||||
break;
|
||||
case 'width':
|
||||
this.$div.style.setProperty('--se-spin-input-width', newValue + 'px');
|
||||
break;
|
||||
case 'size':
|
||||
// access to the underlying input box
|
||||
this.$input.shadowRoot.getElementById('input').size = newValue;
|
||||
|
|
Loading…
Reference in New Issue