Skip to content

Commit 4cc6c33

Browse files
committed
Align signatures of attributeChangedCallback
1 parent 3dd189c commit 4cc6c33

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

lib/elements/dom-bind.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,13 @@ export class DomBind extends domBindBase {
6464

6565
/**
6666
* @override
67+
* @param {string} name Name of attribute that changed
68+
* @param {?string} old Old attribute value
69+
* @param {?string} value New attribute value
70+
* @param {?string} namespace Attribute namespace.
6771
* @return {void}
6872
*/
69-
attributeChangedCallback() {
73+
attributeChangedCallback(name, old, value, namespace) {
7074
// assumes only one observed attribute
7175
this.mutableData = true;
7276
}

lib/mixins/disable-upgrade-mixin.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,8 @@ export const DisableUpgradeMixin = dedupingMixin((base) => {
6767
* @param {string} name Attribute name.
6868
* @param {?string} old The previous value for the attribute.
6969
* @param {?string} value The new value for the attribute.
70-
* @param {?string=} namespace The XML namespace for the attribute.
71-
* @return {undefined}
70+
* @param {?string} namespace The XML namespace for the attribute.
71+
* @return {void}
7272
*/
7373
attributeChangedCallback(name, old, value, namespace) {
7474
if (name == DISABLED_ATTR) {

lib/mixins/properties-changed.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ export const PropertiesChanged = dedupingMixin(
426426
* @param {string} name Name of attribute that changed
427427
* @param {?string} old Old attribute value
428428
* @param {?string} value New attribute value
429-
* @param {?string=} namespace Attribute namespace.
429+
* @param {?string} namespace Attribute namespace.
430430
* @return {void}
431431
* @suppress {missingProperties} Super may or may not implement the callback
432432
* @override

0 commit comments

Comments
 (0)