refactor(nav): do not auto-add pascal case css class

Previously a css class generated from the JS class name, was
automatically being added to the page element. However, the JS class
name returned is not consistent among all browsers. Instead of
automatically applying a css classname, we now recommend adding a
`selector` to each page component.
This commit is contained in:
Adam Bradley
2016-09-26 00:40:10 +01:00
parent 1bf85c4d76
commit d8ecf16feb
5 changed files with 6 additions and 21 deletions

View File

@ -1,7 +1,6 @@
import { Component, ComponentFactoryResolver, ElementRef, HostListener, Renderer, ViewChild, ViewContainerRef } from '@angular/core';
import { Config } from '../../config/config';
import { pascalCaseToDashCase } from '../../util/util';
import { Key } from '../../util/key';
import { NavParams } from '../../navigation/nav-params';
import { ViewController } from '../../navigation/view-controller';
@ -78,7 +77,6 @@ export class PopoverCmp {
const componentRef = this._viewport.createComponent(componentFactory, this._viewport.length, this._viewport.parentInjector, []);
this._viewCtrl._setInstance(componentRef.instance);
this._setCssClass(componentRef, pascalCaseToDashCase(component.name));
this._enabled = true;
}
}