|
8 | 8 |
|
9 | 9 | import {ConstantPool} from '../../constant_pool'; |
10 | 10 | import * as core from '../../core'; |
11 | | -import {CssSelector} from '../../directive_matching'; |
12 | 11 | import * as o from '../../output/output_ast'; |
13 | 12 | import {ParseError, ParseSourceSpan} from '../../parse_util'; |
14 | 13 | import {ShadowCss} from '../../shadow_css'; |
@@ -194,28 +193,6 @@ export function compileComponentFromMetadata( |
194 | 193 | const definitionMap = baseDirectiveFields(meta, constantPool, bindingParser); |
195 | 194 | addFeatures(definitionMap, meta); |
196 | 195 |
|
197 | | - const selector = meta.selector && CssSelector.parse(meta.selector); |
198 | | - const firstSelector = selector && selector[0]; |
199 | | - |
200 | | - // e.g. `attr: ["class", ".my.app"]` |
201 | | - // This is optional an only included if the first selector of a component specifies attributes. |
202 | | - if (firstSelector) { |
203 | | - const selectorAttributes = firstSelector.getAttrs(); |
204 | | - if (selectorAttributes.length) { |
205 | | - definitionMap.set( |
206 | | - 'attrs', |
207 | | - constantPool.getConstLiteral( |
208 | | - o.literalArr( |
209 | | - selectorAttributes.map((value) => |
210 | | - value != null ? o.literal(value) : o.literal(undefined), |
211 | | - ), |
212 | | - ), |
213 | | - /* forceShared */ true, |
214 | | - ), |
215 | | - ); |
216 | | - } |
217 | | - } |
218 | | - |
219 | 196 | // e.g. `template: function MyComponent_Template(_ctx, _cm) {...}` |
220 | 197 | const templateTypeName = meta.name; |
221 | 198 |
|
|
0 commit comments