// tslint:disable
import { AtomXFControl } from "web-atoms-core/dist/xf/controls/AtomXFControl";
import { AtomBridge } from "web-atoms-core/dist/core/AtomBridge";
import ComboBoxSampleViewModel from "../../../../view-models/combo-box/ComboBoxSampleViewModel";
import AtomComboBox from "@web-atoms/xf-controls/dist/AtomComboBox";
declare var UMD: any;
const __moduleName = this.filename;
export default class Root extends AtomXFControl {
public static readonly _$_url = __moduleName ;
public mAtomComboBox;
constructor(app: any, e?: any) {
super(app, e || AtomBridge.instance.create("Xamarin.Forms.ContentPage"));
}
protected create(): void {
super.create();
const mAtomComboBox = new AtomComboBox(this.app);
this.mAtomComboBox = mAtomComboBox.element;
this.loadXaml(`
`);
const e1 = this.find("e1");
this.setLocalValue(e1, "viewModel", this.resolve(ComboBoxSampleViewModel) );
mAtomComboBox.setLocalValue(this.mAtomComboBox, "itemTemplate", () => new (Root_mAtomComboBox_Creator(this))(this.app));
mAtomComboBox.setPrimitiveValue(this.mAtomComboBox, "itemsSource", (fe) => this.viewModel.search(fe) );
mAtomComboBox.setPrimitiveValue(this.mAtomComboBox, "valueFunc", (item) => item.value );
}
}
function Root_mAtomComboBox_Creator(__creator: any): any {
return class Root_mAtomComboBox extends AtomXFControl {
constructor(app: any, e?: any) {
super(app, e || AtomBridge.instance.create("Xamarin.Forms.Label"));
}
protected create(): void {
super.create();
this.loadXaml(` `);
const e1 = this.find("e1");
this.bind(e1, "Text", [["data","label"]], false , null );
}
}
;
}