fix: Enabled annotation support for Dart
This commit is contained in:
parent
cbd429640f
commit
6c8da62c1b
|
@ -1,12 +1,15 @@
|
|||
import {Directive} from './directive';
|
||||
import {ABSTRACT, CONST} from 'facade/lang';
|
||||
|
||||
export class Component extends Directive {
|
||||
@CONST()
|
||||
constructor({
|
||||
selector,
|
||||
lightDomServices,
|
||||
implementsTypes,
|
||||
template,
|
||||
elementServices,
|
||||
componentServices,
|
||||
implementsTypes
|
||||
componentServices
|
||||
}:{
|
||||
selector:String,
|
||||
template:TemplateConfig,
|
||||
|
@ -16,7 +19,13 @@ export class Component extends Directive {
|
|||
implementsTypes:Array<Type>
|
||||
})
|
||||
{
|
||||
// super({selector, lightDomServices, implementsTypes});
|
||||
super({
|
||||
selector: selector,
|
||||
lightDomServices: lightDomServices,
|
||||
implementsTypes: implementsTypes});
|
||||
this.template = template;
|
||||
this.elementServices = elementServices;
|
||||
this.componentServices = componentServices;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -62,4 +71,4 @@ CompA ShadowDOM:
|
|||
|
||||
CompB SHadowDOM:
|
||||
<div></div>
|
||||
*/
|
||||
*/
|
||||
|
|
|
@ -1,21 +1,23 @@
|
|||
// import {Type} from 'facade/lang';
|
||||
// import {ElementServicesFunction} from './facade';
|
||||
import {ABSTRACT} from 'facade/lang';
|
||||
import {ABSTRACT, CONST} from 'facade/lang';
|
||||
|
||||
|
||||
@ABSTRACT()
|
||||
export class Directive {
|
||||
constructor({
|
||||
@CONST()
|
||||
constructor({
|
||||
selector,
|
||||
lightDomServices,
|
||||
implementsTypes
|
||||
}/*:{
|
||||
}:{
|
||||
selector:String,
|
||||
lightDomServices:ElementServicesFunction,
|
||||
implementsTypes:Array<Type>
|
||||
}*/)
|
||||
})
|
||||
{
|
||||
this.selector = selector;
|
||||
this.lightDomServices = lightDomServices;
|
||||
this.selector = selector;
|
||||
}
|
||||
this.implementsTypes = implementsTypes;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,16 +1,23 @@
|
|||
import {ABSTRACT, CONST} from 'facade/lang';
|
||||
// import {Type, List} from 'facade/lang';
|
||||
|
||||
export class TemplateConfig {
|
||||
@CONST()
|
||||
constructor({
|
||||
url,
|
||||
directives,
|
||||
formatters,
|
||||
source
|
||||
}/*: {
|
||||
}: {
|
||||
url: String,
|
||||
directives: List<Type>,
|
||||
formatters: List<Type>,
|
||||
source: List<TemplateConfig>
|
||||
}*/)
|
||||
{}
|
||||
}
|
||||
})
|
||||
{
|
||||
this.url = url;
|
||||
this.directives = directives;
|
||||
this.formatters = formatters;
|
||||
this.source = source;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue