mirror of
https://github.com/Polymer/polymer.git
synced 2025-02-25 18:55:30 -06:00
Lint and type fixes
This commit is contained in:
@@ -78,6 +78,15 @@ Polymer_PropertiesChanged.prototype._enableProperties = function(){};
|
||||
Polymer_PropertiesChanged.prototype._flushProperties = function(){};
|
||||
/**
|
||||
* @param {!Object} currentProps Bag of all current accessor values
|
||||
* @param {!Object} changedProps Bag of properties changed since the last
|
||||
call to `_propertiesChanged`
|
||||
* @param {!Object} oldProps Bag of previous values for each property
|
||||
in `changedProps`
|
||||
* @return {boolean}
|
||||
*/
|
||||
Polymer_PropertiesChanged.prototype._shouldPropertiesChange = function(currentProps, changedProps, oldProps){};
|
||||
/**
|
||||
* @param {!Object} currentProps Bag of all current accessor values
|
||||
* @param {!Object} changedProps Bag of properties changed since the last
|
||||
call to `_propertiesChanged`
|
||||
* @param {!Object} oldProps Bag of previous values for each property
|
||||
|
||||
@@ -353,7 +353,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
||||
* in `changedProps`
|
||||
* @return {boolean} true if changedProps is truthy
|
||||
*/
|
||||
_shouldPropertiesChange(props, changedProps, old) {
|
||||
_shouldPropertiesChange(currentProps, changedProps, oldProps) { // eslint-disable-line no-unused-vars
|
||||
return changedProps;
|
||||
}
|
||||
|
||||
|
||||
@@ -160,8 +160,7 @@ suite('properties-changed', function() {
|
||||
done();
|
||||
});
|
||||
});
|
||||
})
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
15
types/lib/mixins/properties-changed.d.ts
vendored
15
types/lib/mixins/properties-changed.d.ts
vendored
@@ -182,6 +182,21 @@ declare namespace Polymer {
|
||||
*/
|
||||
_flushProperties(): void;
|
||||
|
||||
/**
|
||||
* Called in `_flushProperties` to determine if `_propertiesChanged`
|
||||
* should be called. The default implementation returns true if
|
||||
* properties are pending. Override to customize when
|
||||
* `_propertiesChanged` is called.
|
||||
*
|
||||
* @param currentProps Bag of all current accessor values
|
||||
* @param changedProps Bag of properties changed since the last
|
||||
* call to `_propertiesChanged`
|
||||
* @param oldProps Bag of previous values for each property
|
||||
* in `changedProps`
|
||||
* @returns true if changedProps is truthy
|
||||
*/
|
||||
_shouldPropertiesChange(currentProps: object, changedProps: object, oldProps: object): boolean;
|
||||
|
||||
/**
|
||||
* Callback called when any properties with accessors created via
|
||||
* `_createPropertyAccessor` have been set.
|
||||
|
||||
Reference in New Issue
Block a user