var __extends = (this && this.__extends) || (function () {
    var extendStatics = Object.setPrototypeOf ||
        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
    return function (d, b) {
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
///<reference path="./lib/leaf.d.ts"/>
var R;
(function (R) {
    var ComposerEntryPage = (function (_super) {
        __extends(ComposerEntryPage, _super);
        function ComposerEntryPage() {
            var _this = _super.call(this, function () {
                var _e = this._e.bind(this);
                var _t = this._t.bind(this);
                return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "composer-entry-page-41424f page" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("widget", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "searcher" }] }, "data-widget": { "name": "data-widget", "templates": [{ "type": "raw", "content": "./widgetSearcher" }] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "previewer" }] } }, [_t({ "templates": [{ "type": "raw", "content": "    \n    " }] }), _e("widget", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "previewed-widget" }] }, "data-name": { "name": "data-name", "templates": [{ "type": "raw", "content": "widgetPreview" }] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n  " }] })]), _t({ "templates": [{ "type": "raw", "content": "\n" }] })]);
            }, "ComposerEntryPage", []) || this;
            _this.TestDatas = ComposerEntryPage.TestDatas;
            _this.BindedLists = ComposerEntryPage.BindedLists;
            _this.BindedWidgets = ComposerEntryPage.BindedWidgets;
            _this.InitialData = ComposerEntryPage.InitialData;
            _this.path = ComposerEntryPage.path;
            _this.GeneratedConstructor = ComposerEntryPage;
            _this.R = R;
            if (ComposerEntryPage.InitialData) {
                _this.renderRecursive(ComposerEntryPage.InitialData);
            }
            return _this;
        }
        return ComposerEntryPage;
    }(Leaf.GeneratedWidget));
    ComposerEntryPage.TestDatas = [];
    ComposerEntryPage.BindedLists = [];
    ComposerEntryPage.BindedWidgets = [{ "path": "/widgetSearcher", "name": "widgetSearcher" }, { "path": null, "name": "widgetPreview" }];
    ComposerEntryPage.path = "/composerEntryPage";
    ComposerEntryPage.InitialData = null;
    R.ComposerEntryPage = ComposerEntryPage;
    ComposerEntryPage["prototype"].name = "ComposerEntryPage";
    var RecursiveTest = (function (_super) {
        __extends(RecursiveTest, _super);
        function RecursiveTest() {
            var _this = _super.call(this, function () {
                var _e = this._e.bind(this);
                var _t = this._t.bind(this);
                return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "recursive-test-ebf981" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("span", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "debug" }] } }, [_t({ "templates": [{ "type": "raw", "content": "content" }] })]), _t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "indent" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n    " }] }), _e("widget", { "data-name": { "name": "data-name", "templates": [{ "type": "raw", "content": "child" }] }, "data-widget": { "name": "data-widget", "templates": [{ "type": "raw", "content": "recursiveTest" }] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n  " }] })]), _t({ "templates": [{ "type": "raw", "content": "\n" }] })]);
            }, "RecursiveTest", []) || this;
            _this.TestDatas = RecursiveTest.TestDatas;
            _this.BindedLists = RecursiveTest.BindedLists;
            _this.BindedWidgets = RecursiveTest.BindedWidgets;
            _this.InitialData = RecursiveTest.InitialData;
            _this.path = RecursiveTest.path;
            _this.GeneratedConstructor = RecursiveTest;
            _this.R = R;
            if (RecursiveTest.InitialData) {
                _this.renderRecursive(RecursiveTest.InitialData);
            }
            return _this;
        }
        return RecursiveTest;
    }(Leaf.GeneratedWidget));
    RecursiveTest.TestDatas = [];
    RecursiveTest.BindedLists = [];
    RecursiveTest.BindedWidgets = [{ "path": "/recursiveTest", "name": "child" }];
    RecursiveTest.path = "/recursiveTest";
    RecursiveTest.InitialData = null;
    R.RecursiveTest = RecursiveTest;
    RecursiveTest["prototype"].name = "RecursiveTest";
    var UseCustomInput = (function (_super) {
        __extends(UseCustomInput, _super);
        function UseCustomInput() {
            var _this = _super.call(this, function () {
                var _e = this._e.bind(this);
                var _t = this._t.bind(this);
                return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "use-custom-input-82ce8e" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n  below is the input:\n  " }] }), _e("custom-input", {}, [_t({ "templates": [{ "type": "raw", "content": "FieldName" }] })]), _t({ "templates": [{ "type": "raw", "content": "\n" }] })]);
            }, "UseCustomInput", []) || this;
            _this.TestDatas = UseCustomInput.TestDatas;
            _this.BindedLists = UseCustomInput.BindedLists;
            _this.BindedWidgets = UseCustomInput.BindedWidgets;
            _this.InitialData = UseCustomInput.InitialData;
            _this.path = UseCustomInput.path;
            _this.GeneratedConstructor = UseCustomInput;
            _this.R = R;
            if (UseCustomInput.InitialData) {
                _this.renderRecursive(UseCustomInput.InitialData);
            }
            return _this;
        }
        return UseCustomInput;
    }(Leaf.GeneratedWidget));
    UseCustomInput.TestDatas = [];
    UseCustomInput.BindedLists = [];
    UseCustomInput.BindedWidgets = [];
    UseCustomInput.path = "/useCustomInput";
    UseCustomInput.InitialData = null;
    R.UseCustomInput = UseCustomInput;
    UseCustomInput["prototype"].name = "UseCustomInput";
    var WidgetSearcher = (function (_super) {
        __extends(WidgetSearcher, _super);
        function WidgetSearcher() {
            var _this = _super.call(this, function () {
                var _e = this._e.bind(this);
                var _t = this._t.bind(this);
                return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "widget-searcher-d2b3be widget-searcher " }, { "type": "value", "content": "empty", "reverse": false }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("input", { "type": { "name": "type", "templates": [{ "type": "raw", "content": "text" }] }, "data-id": { "name": "data-id", "templates": [{ "type": "raw", "content": "input" }] }, "placeholder": { "name": "placeholder", "templates": [{ "type": "raw", "content": "Search widget:" }] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "results " }, { "type": "value", "content": "open", "reverse": false }] }, "data-list": { "name": "data-list", "templates": [{ "type": "raw", "content": "widgetList" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n    " }] }), _t({ "templates": [{ "type": "raw", "content": "\n  " }] })]), _t({ "templates": [{ "type": "raw", "content": "\n" }] })]);
            }, "WidgetSearcher", ["open", "empty"]) || this;
            _this.TestDatas = WidgetSearcher.TestDatas;
            _this.BindedLists = WidgetSearcher.BindedLists;
            _this.BindedWidgets = WidgetSearcher.BindedWidgets;
            _this.InitialData = WidgetSearcher.InitialData;
            _this.path = WidgetSearcher.path;
            _this.GeneratedConstructor = WidgetSearcher;
            _this.R = R;
            if (WidgetSearcher.InitialData) {
                _this.renderRecursive(WidgetSearcher.InitialData);
            }
            return _this;
        }
        return WidgetSearcher;
    }(Leaf.GeneratedWidget));
    WidgetSearcher.TestDatas = [{ "name": "test-1", "content": "", "json": { "empty": false, "open": true, "widgetList": [{ "widgetPath": "/path1" }, { "widgetPath": "/path2" }, { "widgetPath": "/pathQAQ" }] } }];
    WidgetSearcher.BindedLists = [{ "name": "widgetList", "type": "inline", "reference": "/widgetSearcher/widgetListItem" }];
    WidgetSearcher.BindedWidgets = [];
    WidgetSearcher.path = "/widgetSearcher";
    WidgetSearcher.InitialData = null;
    R.WidgetSearcher = WidgetSearcher;
    WidgetSearcher["prototype"].name = "WidgetSearcher";
    (function (WidgetSearcher) {
        var WidgetListItem = (function (_super) {
            __extends(WidgetListItem, _super);
            function WidgetListItem() {
                var _this = _super.call(this, function () {
                    var _e = this._e.bind(this);
                    var _t = this._t.bind(this);
                    return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "widget-list-item-90e7a1 widget-list-item" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n        " }, { "type": "value", "content": "widgetPath", "reverse": false }, { "type": "raw", "content": "\n      " }] })]);
                }, "WidgetListItem", ["widgetPath"]) || this;
                _this.TestDatas = WidgetListItem.TestDatas;
                _this.BindedLists = WidgetListItem.BindedLists;
                _this.BindedWidgets = WidgetListItem.BindedWidgets;
                _this.InitialData = WidgetListItem.InitialData;
                _this.path = WidgetListItem.path;
                _this.GeneratedConstructor = WidgetListItem;
                _this.R = R;
                if (WidgetListItem.InitialData) {
                    _this.renderRecursive(WidgetListItem.InitialData);
                }
                return _this;
            }
            return WidgetListItem;
        }(Leaf.GeneratedWidget));
        WidgetListItem.TestDatas = [{ "name": "test-1", "content": "", "json": { "widgetPath": "testPathInline" } }];
        WidgetListItem.BindedLists = [];
        WidgetListItem.BindedWidgets = [];
        WidgetListItem.path = "/widgetSearcher/widgetListItem";
        WidgetListItem.InitialData = null;
        WidgetSearcher.WidgetListItem = WidgetListItem;
        WidgetListItem["prototype"].name = "WidgetListItem";
    })(WidgetSearcher = R.WidgetSearcher || (R.WidgetSearcher = {}));
    var Widget;
    (function (Widget) {
        var CustomInput = (function (_super) {
            __extends(CustomInput, _super);
            function CustomInput() {
                var _this = _super.call(this, function () {
                    var _e = this._e.bind(this);
                    var _t = this._t.bind(this);
                    return _e("div", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "custom-input-4cb97d" }] } }, [_t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("slot", { "class": { "name": "class", "templates": [{ "type": "raw", "content": "name" }] }, "data-slot": { "name": "data-slot", "templates": [{ "type": "raw", "content": "name" }] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n  " }] }), _e("input", { "type": { "name": "type", "templates": [{ "type": "raw", "content": "text" }] }, "value": { "name": "value", "templates": [] } }, []), _t({ "templates": [{ "type": "raw", "content": "\n" }] })]);
                }, "CustomInput", []) || this;
                _this.TestDatas = CustomInput.TestDatas;
                _this.BindedLists = CustomInput.BindedLists;
                _this.BindedWidgets = CustomInput.BindedWidgets;
                _this.InitialData = CustomInput.InitialData;
                _this.path = CustomInput.path;
                _this.GeneratedConstructor = CustomInput;
                _this.R = R;
                if (CustomInput.InitialData) {
                    _this.renderRecursive(CustomInput.InitialData);
                }
                return _this;
            }
            return CustomInput;
        }(Leaf.GeneratedWidget));
        CustomInput.TestDatas = [];
        CustomInput.BindedLists = [];
        CustomInput.BindedWidgets = [];
        CustomInput.path = "/widget/customInput";
        CustomInput.InitialData = null;
        Widget.CustomInput = CustomInput;
        CustomInput["prototype"].name = "CustomInput";
    })(Widget = R.Widget || (R.Widget = {}));
    R.widgets = ["/composerEntryPage", "/recursiveTest", "/useCustomInput", "/widgetSearcher", "/widgetSearcher/widgetListItem", "/widget/customInput"];
})(R || (R = {}));
window["R"] = R;
