fix(ivy): introduce host-specific styling instructions (#29292)

This patch is the first of a few patches which separates the
styling logic between template bindings (e.g. <div [style])
from host bindings (e.g. @HostBinding('style')). This patch
in particular introduces a series of host-specific styling
instructions and changes the existing set of template styling
instructions not to accept directives. The underyling code (which
communicates with the styling algorithm) still works as it did
before.

This PR also separates the styling instruction code into a separate
file and moves over all other instructions into an dedicated
instructions directory.

PR Close #29292
This commit is contained in:
Matias Niemelä
2019-03-15 13:45:08 -07:00
parent d5e3f2c64b
commit 8714daf276
23 changed files with 736 additions and 432 deletions

View File

@ -72,7 +72,6 @@ export const angularCoreEnv: {[name: string]: Function} = {
'ɵinterpolation7': r3.interpolation7,
'ɵinterpolation8': r3.interpolation8,
'ɵinterpolationV': r3.interpolationV,
'ɵelementClassProp': r3.elementClassProp,
'ɵlistener': r3.listener,
'ɵload': r3.load,
'ɵprojection': r3.projection,
@ -94,11 +93,17 @@ export const angularCoreEnv: {[name: string]: Function} = {
'ɵcontentQuery': r3.contentQuery,
'ɵloadContentQuery': r3.loadContentQuery,
'ɵreference': r3.reference,
'ɵelementStyling': r3.elementStyling,
'ɵelementHostAttrs': r3.elementHostAttrs,
'ɵelementStyling': r3.elementStyling,
'ɵelementStylingMap': r3.elementStylingMap,
'ɵelementStyleProp': r3.elementStyleProp,
'ɵelementStylingApply': r3.elementStylingApply,
'ɵelementClassProp': r3.elementClassProp,
'ɵelementHostStyling': r3.elementHostStyling,
'ɵelementHostStylingMap': r3.elementHostStylingMap,
'ɵelementHostStyleProp': r3.elementHostStyleProp,
'ɵelementHostStylingApply': r3.elementHostStylingApply,
'ɵelementHostClassProp': r3.elementHostClassProp,
'ɵflushHooksUpTo': r3.flushHooksUpTo,
'ɵtemplate': r3.template,
'ɵtext': r3.text,