@smilodon/core 1.9.1 → 1.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -6077,6 +6077,10 @@
6077
6077
  continue;
6078
6078
  const sourceValue = source[key];
6079
6079
  const targetValue = result[key];
6080
+ // Optional adapter props are commonly forwarded as undefined. Preserve
6081
+ // the existing/default config in that case instead of erasing a section.
6082
+ if (sourceValue === undefined)
6083
+ continue;
6080
6084
  if (sourceValue && typeof sourceValue === 'object' && !Array.isArray(sourceValue)) {
6081
6085
  result[key] = this._mergeConfig(targetValue && typeof targetValue === 'object' ? targetValue : {}, sourceValue);
6082
6086
  }
@@ -6118,8 +6122,9 @@
6118
6122
  const hasSomethingToClear = (clearSelection && hasSelection) || (clearSearch && hasSearch);
6119
6123
  const hideWhenEmpty = this._config.clearControl.hideWhenEmpty !== false;
6120
6124
  const visible = enabled && (!hideWhenEmpty || hasSomethingToClear);
6121
- this._inputContainer.classList.toggle('has-clear-control', enabled);
6122
- this._arrowContainer.classList.toggle('with-clear-control', enabled);
6125
+ // Reserve the action area only while the clear control is actually visible.
6126
+ this._inputContainer.classList.toggle('has-clear-control', visible);
6127
+ this._arrowContainer.classList.toggle('with-clear-control', visible);
6123
6128
  this._clearControl.hidden = !visible;
6124
6129
  this._clearControl.disabled = !hasSomethingToClear;
6125
6130
  this._clearControl.setAttribute('aria-hidden', String(!visible));