@@ -585,6 +585,8 @@ export class Directive extends Injectable {
585585 */
586586 events : List < string > ;
587587
588+ // TODO(vicb): doc
589+
588590 /**
589591 * Specifies which DOM hostListeners a directive listens to.
590592 *
@@ -643,9 +645,6 @@ export class Directive extends Injectable {
643645 * 'change' event.
644646 *
645647 */
646- hostListeners : StringMap < string , string > ;
647-
648-
649648 /**
650649 * Specifies which DOM properties a directives updates.
651650 *
@@ -667,8 +666,6 @@ export class Directive extends Injectable {
667666 * the host element.
668667 * ```
669668 */
670- hostProperties : StringMap < string , string > ;
671-
672669 /**
673670 * Specifies static attributes that should be propagated to a host element. Attributes specified
674671 * in `hostAttributes`
@@ -691,8 +688,6 @@ export class Directive extends Injectable {
691688 * will ensure that this element will get the "button" role.
692689 * ```
693690 */
694- hostAttributes : StringMap < string , string > ;
695-
696691 /**
697692 * Specifies which DOM methods a directive can invoke.
698693 *
@@ -719,7 +714,8 @@ export class Directive extends Injectable {
719714 * element.
720715 * ```
721716 */
722- hostActions : StringMap < string , string > ;
717+
718+ host : StringMap < string , string > ;
723719
724720 /**
725721 * Specifies which lifecycle should be notified to the directive.
@@ -795,16 +791,13 @@ export class Directive extends Injectable {
795791 exportAs : string ;
796792
797793 constructor ( {
798- selector, properties, events, hostListeners , hostProperties , hostAttributes ,
799- hostActions , lifecycle , hostInjector , exportAs , compileChildren = true ,
794+ selector, properties, events, host , lifecycle , hostInjector , exportAs ,
795+ compileChildren = true ,
800796 } : {
801797 selector ?: string ,
802798 properties ?: List < string > ,
803799 events ?: List < string > ,
804- hostListeners ?: StringMap < string , string > ,
805- hostProperties ?: StringMap < string , string > ,
806- hostAttributes ?: StringMap < string , string > ,
807- hostActions ?: StringMap < string , string > ,
800+ host ?: StringMap < string , string > ,
808801 lifecycle ?: List < LifecycleEvent > ,
809802 hostInjector ?: List < any > ,
810803 exportAs ?: string ,
@@ -814,10 +807,7 @@ export class Directive extends Injectable {
814807 this . selector = selector ;
815808 this . properties = properties ;
816809 this . events = events ;
817- this . hostListeners = hostListeners ;
818- this . hostProperties = hostProperties ;
819- this . hostAttributes = hostAttributes ;
820- this . hostActions = hostActions ;
810+ this . host = host ;
821811 this . exportAs = exportAs ;
822812 this . lifecycle = lifecycle ;
823813 this . compileChildren = compileChildren ;
@@ -1022,16 +1012,12 @@ export class Component extends Directive {
10221012 */
10231013 viewInjector : List < any > ;
10241014
1025- constructor ( { selector, properties, events, hostListeners, hostProperties, hostAttributes,
1026- hostActions, exportAs, appInjector, lifecycle, hostInjector, viewInjector,
1027- changeDetection = DEFAULT , compileChildren = true } : {
1015+ constructor ( { selector, properties, events, host, exportAs, appInjector, lifecycle, hostInjector,
1016+ viewInjector, changeDetection = DEFAULT , compileChildren = true } : {
10281017 selector ?: string ,
10291018 properties ?: List < string > ,
10301019 events ?: List < string > ,
1031- hostListeners ?: StringMap < string , string > ,
1032- hostProperties ?: StringMap < string , string > ,
1033- hostAttributes ?: StringMap < string , string > ,
1034- hostActions ?: StringMap < string , string > ,
1020+ host ?: StringMap < string , string > ,
10351021 exportAs ?: string ,
10361022 appInjector ?: List < any > ,
10371023 lifecycle ?: List < LifecycleEvent > ,
@@ -1044,10 +1030,7 @@ export class Component extends Directive {
10441030 selector : selector ,
10451031 properties : properties ,
10461032 events : events ,
1047- hostListeners : hostListeners ,
1048- hostProperties : hostProperties ,
1049- hostAttributes : hostAttributes ,
1050- hostActions : hostActions ,
1033+ host : host ,
10511034 exportAs : exportAs ,
10521035 hostInjector : hostInjector ,
10531036 lifecycle : lifecycle ,
0 commit comments