@vaadin/component-base
Advanced tools
Comparing version 24.7.0-alpha1 to 24.7.0-alpha2
{ | ||
"name": "@vaadin/component-base", | ||
"version": "24.7.0-alpha1", | ||
"version": "24.7.0-alpha2", | ||
"publishConfig": { | ||
@@ -41,7 +41,7 @@ "access": "public" | ||
"devDependencies": { | ||
"@vaadin/chai-plugins": "24.7.0-alpha1", | ||
"@vaadin/chai-plugins": "24.7.0-alpha2", | ||
"@vaadin/testing-helpers": "^1.0.0", | ||
"sinon": "^18.0.0" | ||
}, | ||
"gitHead": "04be941c9a7b659871c97f31b9cc3ffd7528087b" | ||
"gitHead": "e2523f9b4abc5a9586fb758166f823dc40c399dd" | ||
} |
@@ -16,3 +16,3 @@ /** | ||
export function defineCustomElement(CustomElement, version = '24.7.0-alpha1') { | ||
export function defineCustomElement(CustomElement, version = '24.7.0-alpha2') { | ||
Object.defineProperty(CustomElement, 'version', { | ||
@@ -19,0 +19,0 @@ get() { |
@@ -7,2 +7,3 @@ /** | ||
import { dedupeMixin } from '@open-wc/dedupe-mixin'; | ||
import { notEqual } from 'lit'; | ||
import { get, set } from './path-utils.js'; | ||
@@ -105,8 +106,11 @@ | ||
const oldValue = this[name]; | ||
this[key] = value; | ||
this.requestUpdate(name, oldValue, options); | ||
// Enforce synchronous update | ||
if (this.hasUpdated) { | ||
this.performUpdate(); | ||
if (notEqual(value, oldValue)) { | ||
this[key] = value; | ||
this.requestUpdate(name, oldValue, options); | ||
// Enforce synchronous update | ||
if (this.hasUpdated) { | ||
this.performUpdate(); | ||
} | ||
} | ||
@@ -120,3 +124,3 @@ }, | ||
if (options.readOnly) { | ||
const setter = defaultDescriptor.set; | ||
const setter = result.set; | ||
@@ -127,6 +131,2 @@ this.addCheckedInitializer((instance) => { | ||
setter.call(instance, value); | ||
if (options.sync) { | ||
this.performUpdate(); | ||
} | ||
}; | ||
@@ -136,3 +136,3 @@ }); | ||
result = { | ||
get: defaultDescriptor.get, | ||
get: result.get, | ||
set() { | ||
@@ -203,2 +203,8 @@ // Do nothing, property is read-only. | ||
static get polylitConfig() { | ||
return { | ||
asyncFirstRender: false, | ||
}; | ||
} | ||
constructor() { | ||
@@ -223,2 +229,7 @@ super(); | ||
} | ||
const { polylitConfig } = this.constructor; | ||
if (!this.hasUpdated && !polylitConfig.asyncFirstRender) { | ||
this.performUpdate(); | ||
} | ||
} | ||
@@ -225,0 +236,0 @@ |
@@ -11,2 +11,6 @@ /** | ||
entries.forEach((entry) => { | ||
if (!entry.target.isConnected) { | ||
return; | ||
} | ||
// Notify child resizables, if any | ||
@@ -13,0 +17,0 @@ if (entry.target.resizables) { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
221779
6540