diff --git a/modules/angular2/src/platform/browser/browser_adapter.dart b/modules/angular2/src/platform/browser/browser_adapter.dart index 551a7dc7be..d867f11d4a 100644 --- a/modules/angular2/src/platform/browser/browser_adapter.dart +++ b/modules/angular2/src/platform/browser/browser_adapter.dart @@ -321,16 +321,16 @@ class BrowserDomAdapter extends GenericBrowserDomAdapter { List getElementsByTagName(Element element, String name) => element.querySelectorAll(name); List classList(Element element) => element.classes.toList(); - void addClass(Element element, String classname) { - element.classes.add(classname); + void addClass(Element element, String className) { + element.classes.add(className); } - void removeClass(Element element, String classname) { - element.classes.remove(classname); + void removeClass(Element element, String className) { + element.classes.remove(className); } - bool hasClass(Element element, String classname) => - element.classes.contains(classname); + bool hasClass(Element element, String className) => + element.classes.contains(className); void setStyle(Element element, String styleName, String styleValue) { element.style.setProperty(styleName, styleValue); diff --git a/modules/angular2/src/platform/browser/browser_adapter.ts b/modules/angular2/src/platform/browser/browser_adapter.ts index 5aa9403d22..986c90e2ec 100644 --- a/modules/angular2/src/platform/browser/browser_adapter.ts +++ b/modules/angular2/src/platform/browser/browser_adapter.ts @@ -199,11 +199,11 @@ export class BrowserDomAdapter extends GenericBrowserDomAdapter { return element.getElementsByTagName(name); } classList(element): any[] { return Array.prototype.slice.call(element.classList, 0); } - addClass(element, classname: string) { element.classList.add(classname); } - removeClass(element, classname: string) { element.classList.remove(classname); } - hasClass(element, classname: string): boolean { return element.classList.contains(classname); } - setStyle(element, stylename: string, stylevalue: string) { - element.style[stylename] = stylevalue; + addClass(element, className: string) { element.classList.add(className); } + removeClass(element, className: string) { element.classList.remove(className); } + hasClass(element, className: string): boolean { return element.classList.contains(className); } + setStyle(element, styleName: string, styleValue: string) { + element.style[styleName] = styleValue; } removeStyle(element, stylename: string) { element.style[stylename] = null; } getStyle(element, stylename: string): string { return element.style[stylename]; } diff --git a/modules/angular2/src/platform/dom/dom_adapter.ts b/modules/angular2/src/platform/dom/dom_adapter.ts index 8577e31632..50049a52a0 100644 --- a/modules/angular2/src/platform/dom/dom_adapter.ts +++ b/modules/angular2/src/platform/dom/dom_adapter.ts @@ -83,9 +83,9 @@ export abstract class DomAdapter { abstract getElementsByClassName(element, name: string): HTMLElement[]; abstract getElementsByTagName(element, name: string): HTMLElement[]; abstract classList(element): any[]; - abstract addClass(element, classname: string); - abstract removeClass(element, classname: string); - abstract hasClass(element, classname: string): boolean; + abstract addClass(element, className: string); + abstract removeClass(element, className: string); + abstract hasClass(element, className: string): boolean; abstract setStyle(element, styleName: string, styleValue: string); abstract removeStyle(element, styleName: string); abstract getStyle(element, styleName: string): string; diff --git a/modules/angular2/src/platform/server/abstract_html_adapter.dart b/modules/angular2/src/platform/server/abstract_html_adapter.dart index 1481546fdf..7b136601a6 100644 --- a/modules/angular2/src/platform/server/abstract_html_adapter.dart +++ b/modules/angular2/src/platform/server/abstract_html_adapter.dart @@ -253,15 +253,15 @@ abstract class AbstractHtml5LibAdapter implements DomAdapter { List classList(element) => element.classes.toList(); - addClass(element, String classname) { - element.classes.add(classname); + addClass(element, String className) { + element.classes.add(className); } - removeClass(element, String classname) { + removeClass(element, String className) { throw 'not implemented'; } - hasClass(element, String classname) => element.classes.contains(classname); + hasClass(element, String className) => element.classes.contains(className); setStyle(element, String styleName, String styleValue) { throw 'not implemented'; diff --git a/modules/angular2/src/platform/server/parse5_adapter.ts b/modules/angular2/src/platform/server/parse5_adapter.ts index bf5886e549..9621e04f82 100644 --- a/modules/angular2/src/platform/server/parse5_adapter.ts +++ b/modules/angular2/src/platform/server/parse5_adapter.ts @@ -352,24 +352,24 @@ export class Parse5DomAdapter extends DomAdapter { } return classAttrValue ? classAttrValue.trim().split(/\s+/g) : []; } - addClass(element, classname: string) { + addClass(element, className: string) { var classList = this.classList(element); - var index = classList.indexOf(classname); + var index = classList.indexOf(className); if (index == -1) { - classList.push(classname); + classList.push(className); element.attribs["class"] = element.className = classList.join(" "); } } - removeClass(element, classname: string) { + removeClass(element, className: string) { var classList = this.classList(element); - var index = classList.indexOf(classname); + var index = classList.indexOf(className); if (index > -1) { classList.splice(index, 1); element.attribs["class"] = element.className = classList.join(" "); } } - hasClass(element, classname: string): boolean { - return ListWrapper.contains(this.classList(element), classname); + hasClass(element, className: string): boolean { + return ListWrapper.contains(this.classList(element), className); } hasStyle(element, styleName: string, styleValue: string = null): boolean { var value = this.getStyle(element, styleName) || '';