shimCssForNode method
void
shimCssForNode(
- NodeReference nodeReference,
- int nodeIndex,
- CompileIdentifierMetadata nodeType
Implementation
void shimCssForNode(
NodeReference nodeReference,
int nodeIndex,
CompileIdentifierMetadata nodeType,
) {
if (isRootNodeOfHost(nodeIndex)) return;
if (component.template!.encapsulation == ViewEncapsulation.emulated) {
// Set ng_content class for CSS shim.
var shimMethod = nodeType != Identifiers.element
? 'addShimC'
: 'addShimE';
o.Expression shimClassExpr = o.InvokeMemberMethodExpr(shimMethod, [
nodeReference.toReadExpr(),
]);
_createMethod.addStmt(shimClassExpr.toStmt());
}
}